Numbering in GRETINA

Here, we try to summarize the various numbering schemes with the GRETINA system; both geometry related and electronics related.  The majority of this is summarized in this project document.  The take-home message here -- book-keeping with GRETINA is critical!

Geometry within GRETINA - Hole Numbers in the Array

There are 30 mounting positions for the full 4pi GRETA array; the GRETINA frame uses the hole-numbering convention envisioned for GRETA, with available hole numbers from 1-30, though with the current GRETINA frame, not all hole numbers are accessible (21 holes can be populated in total for the GRETINA hemispheres).  The hole numbers, and theta/phi positions relative are summarized in the table below.  Note the coordinate system convention: z-axis is beam; x-axis is gravity (pointing down), and y-axis is defined by right-hand-rule.

Within each mounting hole, a quad can be mounted in only orientation, thus fixing the positions of the four individual crystals in each hole position.  The crystal-specific angles (to the front center of each crystal; (0, 0, 0) in the crystal coordinate frame) are summarized on pg. 4 of the numbering document.  

Okay -- but how do I know the hole number?

Aside from the fact that you hopefully know when analyzing an experiment where the GRETINA quads were mounted, the hole number information is encoded in the mode3 (raw) and mode2 (decomp) data streams.  The extraction of the hole number is summarized below.

Mode2 (Decomp) Data:

    In the mode2 data struct, the variable "crystal_id" can be decoded to get the hole number.  "crystal_id/4" gives the hole number, while "crystal_id%4" gives the crystal number within that hole (i.e. from 0-3, or 1-4 depending on how you want to count). 

Mode3 (Raw) Data:

    In the mode3, it's a little harder to get at the hole number; the value is encoded as part of hdr[1] (see data structure description).  The equivalent of "crystal_id" from mode2 is derived as "hdr[1] >> 6".  As above, the hole number is then "crystal_id/4", while "crystal_id%4" gives the crystal number within that hole (i.e. from 0-3, or 1-4 depending on how you want to count). 

Electronics within GRETINA - Segment Ordering in the Electronics

For Q3-Q8 (and hopefully beyond) the connection between the electronics channel a segment is plugged into and the segment number is fairly straight forward.  Q1 and Q2 were early, so they're quirky.  Back to that later. 

First things first -- segment numbering in general.

Segment have two labeling schemes- segment number from 0-35 (or 1-36) and the layer-column scheme.  The layer-column scheme uses greek letters to denote layers (α, β, γ, δ, ε, φ) from the front of the crystal to the back, and numbers to denote wedges (1-6, where 1 is always on the inside of the quad overall, and numbering is counterclockwise when looking from the front of the detector.  See the picture below.

Here is the connection between the segment number and layer-column schemes:

In the GRETINA electronics, each crystal (40 signals = 36 segments + 4 copies of the CC) occupies one electronics bank, consisting of an IOC, and 4 x 10-channel digitizers.  The convention is to think of the electronics channels for a given bank as channels 0-39, in order.  Signals are connected with the first 9 channels on each board as segment and the tenth channel as a copy of the CC.  The mapping of electronics channel to segment # is as follows.  Note the differences in Q1 and Q2 (certain positions only) compared to ALL other quads.