next up previous index
Next: GEOM050 The GEANT Up: GEOM020 ` MANY' Previous: Divisions along arbitrary

Logic and algorithm

In GTMEDI, all the ' MANY' volumes for which the point is found inside (and not in any of its daughters) is put in a stack saving also its branch of the tree. The point is considered to be in the deepest level ' MANY'. Each time the point is also found in an intermediate ' ONLY' volume the stack is cleared (to insure boolean subtraction). In GTNEXT, if stepping inside a ' MANY' volume, not ONLY its daughters and its own boundaries are checked, but also the daughters and the boundaries of all the others ' MANY' in the list have to be checked. This is not yet enough: the logic requires that the boundaries of all the possible overlapping volumes are checked, so it is also necessary for each ` MANY' volume of the list to go up to the first ' ONLY' mother in the tree repeating the same procedure. This allows also boolean intersection. Obviously, volumes already checked are not checked again.

GEOM050


Janne Saarela
Mon Apr 3 12:46:29 METDST 1995