How HaloSim works

How HaloSim Works: A Detailed Explanation

Have you ever wondered how atmospheric optics simulations like HaloSim work? In this article, we will delve into the inner workings of HaloSim and provide a thorough understanding of its ray tracing engine and simulation process.

The Ray Tracing Engine

HaloSim employs a powerful ray tracing engine that utilizes precise mathematical descriptions of cloud ice crystals. Each crystal is defined by specifying all its faces, and HaloSim reads the constants defining these faces and their normal vectors from individual crystal shape files. This detailed information forms the foundation of the simulation.

Crystal Orientation and Axial Dispersion

To initiate a simulation, HaloSim combines the elevation of the sun with data from files on crystal orientation and axial dispersion. These data determine the range of angles that the crystal can make with respect to the sun and the horizon. By incorporating these parameters, HaloSim ensures accurate representation of real-life atmospheric phenomena.

Tracing the Rays

Once the simulation starts, HaloSim traces each ray by assigning random values to each angle and position within their selected range. The ray is then set on its path towards the virtual crystal. At each face encountered, HaloSim calculates the Fresnel reflection and refraction probabilities to determine the fate of the ray. If the ray is reflected, its direction is computed, and it becomes part of the simulation. If transmitted, it continues to be traced through the crystal. The process repeats as the ray may encounter multiple internal reflections before finally emerging.

Contribution to Pixel Brightness

When a ray exits the crystal, HaloSim computes its direction and assigns it to one pixel of the simulation. The brightness of a pixel is determined by the number of rays that reach it. Therefore, by repeating the ray tracing process for millions of rays, HaloSim accurately generates a comprehensive simulation. This approach, known as Monte-Carlo calculation, draws inspiration from the proceedings in a casino.

Ray Filters and Selection Criteria

HaloSim offers the option to activate ray filters, which test the interaction of each ray with each crystal face against user-defined selection criteria. Only rays that meet all the specified criteria contribute to the simulation. This feature allows users to fine-tune the simulation and focus on specific aspects of atmospheric optics.

Validation and Reliability

To ensure the accuracy and reliability of HaloSim, extensive validation has been conducted. The predictions generated by HaloSim have been compared against real halo displays and other simulations, primarily those by Walter Tape, a renowned authority in atmospheric halos. This validation process helps build confidence in the capabilities of HaloSim and enhances its usefulness as a research tool.

In conclusion, HaloSim operates through a sophisticated ray tracing engine that utilizes precise mathematical descriptions of cloud ice crystals. By incorporating crystal orientation, axial dispersion, and user-defined selection criteria, HaloSim generates comprehensive simulations of atmospheric optics phenomena. Its accuracy and reliability have been validated through comparisons with real observations and established simulations. With its advanced capabilities, HaloSim serves as a valuable tool for researchers and enthusiasts alike to explore the captivating world of atmospheric optics.

120� parhelion ray path. The program traces a ray until it finally emerges from the crystal or until the user defined maximum number of internal reflections is exceeded.

The ray tracing engine in HaloSim uses exact mathematical descriptions of cloud ice crystals. A crystal is defined by specifying all its faces. When starting a simulation, HaloSim reads the constants defining the planes passing through the faces and their normal vectors from individual crystal shape files.

The elevation of the sun is then used with data from files on the type of crystal orientation and axial dispersion. These data together define limits for the range of angles the crystal can make to the sun and horizon. Then the simulation starts.

To trace a ray, each angle and position is given a random value within its selected range and the ray is started on its path towards the virtual crystal. At the first face encountered the Fresnel reflection and refraction probabilities are calculated to decide the ray's fate. If it is reflected its direction is computed and it forms part of the simulation. If transmitted it is traced onwards through the crystal. Many facets could internally reflect the ray before it finally emerges again and the reflection or transmission computation is repeated each time.

When the ray leaves the crystal its direction is computed and it contributes to one pixel of the simulation. The number of rays that reach a pixel determines the local halo brightness. The ray tracing is repeated for up to several million rays to produce the simulation. The process is called a Monte-Carlo calculation after the proceedings in its casino.

Ray filters, when activated, test the interaction of each ray with each crystal face against user defined selection criteria. Only rays meeting all the criteria contribute to the simulation. When the ray tracing tool is used, the history of each ray is stored as it is traced and a summary of all the faces where it was reflected or refracted is displayed.

The ray tracing method is based on that described by Walter Tape ("Atmospheric Halos", Antarctic Research Series, Vol. 64, American Geophysical Union, Washington, 1994) which enlarges the earlier work of Tr�nkle and Greenler.

Validation: we have validated HaloSim's predictions against real halo displays and other simulations, primarily those of Walter Tape.

Note: this article has been automatically converted from the old site and may not appear as intended. You can find the original article here.

Reference Atmospheric Optics

If you use any of the definitions, information, or data presented on Atmospheric Optics, please copy the link or reference below to properly credit us as the reference source. Thank you!

  • "How HaloSim works". Atmospheric Optics. Accessed on November 26, 2024. https://atoptics.co.uk/blog/how-halosim-works/.

  • "How HaloSim works". Atmospheric Optics, https://atoptics.co.uk/blog/how-halosim-works/. Accessed 26 November, 2024

  • How HaloSim works. Atmospheric Optics. Retrieved from https://atoptics.co.uk/blog/how-halosim-works/.