Drawing the Geometrical Tree

+-------------+                                               +----------##
| Geant 3.15  |               GEANT User's Guide              | DRAW210  ##
+-------------+                                               +----------##
                                   

Author(s) : P.Zanarini, S.Giani Submitted: 15.01.84 Origin : Same Revised: 26.05.92

The logical geometrical tree is a hierarchical representation of the overall structure of the detector, based on the mother-daughter relationship among the various objects composing it. The GDTREE routine (correspoonding to the DTREE interactive command) allows the drawing of the logical tree, displaying the name, the multiplicity and other information about the volumes.

          +----------------------------------------------------+
          |CALL GDTREE (CHNAME,LEVMAX,ISEL) |
          +----------------------------------------------------+
                                  

Draws the tree of the volume data structure starting from the volume CHNAME, for LEVMAX depth levels; a continuation link line is drawn for those elements at the last level on the picture but having descendants. For every node, as many red arrows as the number of existing levels below it are plotted on the link; vice versa, as many green arrows as the number of existing levels before it are also plotted. When running GEANT interactively, control can be given to the mouse after issuing the DTREE command. This allows the display of various volume parameters and the navigation of the geometrical tree by clicking the mouse buttons. The size of the picture and the dimensions of each element and arrows are computed automatically. It is still possible to call GDTREE in batch mode just giving the third parameter ISEL.

CHNAME
(CHARACTER*4) volume name.
LEVMAX
(INTEGER) depth levels (if 0 all levels are taken) is default is 3.
ISEL
(INTEGER) ued to select options in the picture of the tree:
0
only the node name is drawn.
xxxxx1
multiplicity is added. each node that has been positioned several times (by GSPOS or GSPOSP) has a multiplicity number preceded by the symbol '*'. each node that has been obtained by division mechanism (by GSDVN, GSDVT, etc.) has a multiplicity number preceded by the symbol #.
xxxx1x
ONLY information is added. volumes that are MANY will be drawn as three square nodes, one overlapping the others but slightly shifted. Note: if CHNAME itself is MANY it will not be recognised as such, because this information is stored in its mother which is unknown.
xxx1xx
DET information is added; if a volumes is a detector it is drawn as a square node with another one slightly larger around it.
xx1xxx
SEEN information is added; if a volume is not seen (either because of its SEEN attribute or because of its ascendantss SEEN attributes affecting the whole tree path) its square node is drawn by using dashed lines.
x1xxxx
a little picture of the volume is added above each node.

Here follows an example of use of GDTREE:

Interactive use

In an interactive session, control can be given to the mouse:

  1. clicking on the left button when the cursor is inside a volume pave will generate a DSPEC command for that volume;
  2. clicking the same button when the cursor is on a red arrow will perform a DTREE for the volume preceding the arrow, displaying a number of levels which depends on the which arrow has been selected; th
  3. selecting in the same way the i green arrow preceding a given volume will perform a DTREE for its mother-volume staying i levels before;
  4. clicking the right button of the mouse will return the control to the command mode.

When running with the X-windows software, the drawing of the specification (DSPEC) appears in a different window to speed up the scanning of the tree. Iterating this procedure it is possible to analyse very easily and quickly any kind of geometry. This drawing tree capability can be very useful when tuning the detector geometry. See the interactive section [XINT] for examples.