Friday, April 22, 2011

Release version 1.2.0 of Tonatiuh

We just released version 1.2.0 of Tonatiuh. This new release version of Tonatiuh is a relatively major release of the program. It changes:
  • the way the surface from which the primary rays are cast into the concentrating geometry is defined, and
  • the way the ray intersections are stored into the photon map.
In previous versions of Tonatiuh, the surface from which the primary rays are cast into the concentrating system was defined by the user, who had the option to select the shape of the surface between a flat rectangle and a flat circular disk, and to define the position and dimensions of the selected shape.

The attempt made in Tonatiuh's version 1.1.5 to assist the user in defining the appropriate dimensions of the selected primary ray casting surface was relatively ill-conceived. In certain circumstances, it resulted in errors in the way primary rays were casts. Furthermore, it did not facilitate the automation of Tonatiuh runs at different sun positions.

In this new release of the Tonatiuh, the primary ray casting surface is always a flat rectangle whose size and position is defined by the program. The way this primary ray casting surface is sized and positioned is simple. For a given Sun position, the bounding box of the concentrating system in the Sun's coordinate frame is obtained, and the primary ray casting surface defined as the side of this bounding box that is perpendicular to the main direction of the Sun rays and is closer to the Sun.

Depending of the Sun position and of the geometry of the solar concentrating system, there may be cases in which the size of the primary ray casting surface may be too large in relation to the region of that surface from which the rays have real chances of intersecting the concentrating system. To cope with those cases in an efficient way, a scheme has been designed and implemented in this new version of Tonatiuh so that no primary rays are cast from regions of the primary ray casting surface from which no primary casted ray will intersect the concentrating geometry. This scheme consist in:

  • Pixelizing the primary ray casting surface,
  • Projecting into the primary ray casting surface and along the main direction of the Sun rays, the bounding boxes of each of the surfaces that form the solar concentrating system.
  • Marking the pixels of the pixelized primary ray casting surface that are shadowed by the bounding boxes projections.
  • Casting primary rays to the concentrating systems only from those regions of the primary casting surface that correspond to regions of the marked pixels.
  • The refinement of this scheme, to further improve ray casting efficiency, will be one of the goals of next releases of Tonatiuh.

As stated before, this new version of the program, in addition to change the way the primary ray casting surface is shaped, sized and positioned, also changes the way the ray - surface intersections are stored in the photon map. The purpose of this change is to discriminate in which side of the surface the ray - surface intersection has taken place. The lack of this discrimination in previous versions of Tonatiuh led to the necessity of having to use two surfaces instead of one in those cases in which was likely that a surface will receive rays from both sides. Thus, this new functionality will simplify the way concentrating geometries are modeled in Tonatiuh.

No comments: