CMS 3D CMS Logo

List of all members | Public Member Functions
CSCIndexerStartup Class Reference

#include <CSCIndexerStartup.h>

Inheritance diagram for CSCIndexerStartup:
CSCIndexerBase

Public Member Functions

int dbIndex (const CSCDetId &id, int &channel) const override
 
std::pair< CSCDetId, IndexTypedetIdFromChipIndex (IndexType ichi) const override
 
GasGainIndexType detIdFromGasGainIndex (IndexType igg) const override
 
std::pair< CSCDetId, IndexTypedetIdFromStripChannelIndex (LongIndexType ichi) const override
 
std::string name () const override
 
 ~CSCIndexerStartup () override
 
maxIndexMethods
LongIndexType maxStripChannelIndex () const override
 
IndexType maxChipIndex () const override
 
IndexType maxGasGainIndex () const override
 
nonIndexCountingMethods
IndexType onlineRingsInStation (IndexType is) const override
 
IndexType stripChannelsPerOfflineLayer (IndexType is, IndexType ir) const override
 
IndexType stripChannelsPerOnlineLayer (IndexType is, IndexType ir) const override
 
IndexType chipsPerOnlineLayer (IndexType is, IndexType ir) const override
 
stripIndexMethods
IndexType stripChannelsPerLayer (IndexType is, IndexType ir) const override
 
LongIndexType stripChannelStart (IndexType ie, IndexType is, IndexType ir) const override
 
chipIndexMethods
IndexType chipsPerLayer (IndexType is, IndexType ir) const override
 
IndexType chipStart (IndexType ie, IndexType is, IndexType ir) const override
 
gasGainIndexMethods
IndexType sectorStart (IndexType ie, IndexType is, IndexType ir) const override
 
- Public Member Functions inherited from CSCIndexerBase
IndexType chamberLabelFromChamberIndex (IndexType) const
 
 CSCIndexerBase ()
 
virtual ~CSCIndexerBase ()
 
IndexType maxChamberIndex () const
 
IndexType maxLayerIndex () const
 
IndexType ringsInStation (IndexType is) const
 
IndexType offlineRingsInStation (IndexType is) const
 
IndexType chambersInRingOfStation (IndexType is, IndexType ir) const
 
IndexType sectorsPerOnlineLayer (IndexType is, IndexType ir) const
 
IndexType startChamberIndexInEndcap (IndexType ie, IndexType is, IndexType ir) const
 
IndexType chamberIndex (IndexType ie, IndexType is, IndexType ir, IndexType ic) const
 
IndexType chamberIndex (const CSCDetId &id) const
 
IndexType layerIndex (IndexType ie, IndexType is, IndexType ir, IndexType ic, IndexType il) const
 
IndexType layerIndex (const CSCDetId &id) const
 
LongIndexType stripChannelIndex (IndexType ie, IndexType is, IndexType ir, IndexType ic, IndexType il, IndexType istrip) const
 
LongIndexType stripChannelIndex (const CSCDetId &id, IndexType istrip) const
 
IndexType chipIndex (IndexType ie, IndexType is, IndexType ir, IndexType ic, IndexType il, IndexType ichip) const
 
IndexType chipIndex (const CSCDetId &id, IndexType ichip) const
 
IndexType chipIndex (IndexType istrip) const
 
IndexType hvSegmentsPerLayer (IndexType is, IndexType ir) const
 
IndexType hvSegmentIndex (IndexType is, IndexType ir, IndexType iwire) const
 
IndexType sectorsPerLayer (IndexType is, IndexType ir) const
 
IndexType gasGainIndex (IndexType ie, IndexType is, IndexType ir, IndexType ic, IndexType il, IndexType ihvsegment, IndexType ichip) const
 
IndexType gasGainIndex (const CSCDetId &id, IndexType istrip, IndexType iwire) const
 
IndexType gasGainIndex (IndexType ihvsegment, IndexType ichip, const CSCDetId &id) const
 
CSCDetId detIdFromChamberIndex (IndexType ici) const
 
CSCDetId detIdFromLayerIndex (IndexType ili) const
 

Additional Inherited Members

- Public Types inherited from CSCIndexerBase
typedef std::tuple< CSCDetId, IndexType, IndexTypeGasGainIndexType
 
typedef uint16_t IndexType
 
typedef uint32_t LongIndexType
 
- Protected Member Functions inherited from CSCIndexerBase
CSCDetId detIdFromChamberLabel (IndexType ie, IndexType icl) const
 
- Protected Attributes inherited from CSCIndexerBase
std::vector< IndexTypechamberLabel_
 

Detailed Description

Concrete CSCIndexer class appropriate for CSC Conditions Data access for CMS startup (2008-2013) in which most ME4/2 chambers do not exist and the 48 ME1/1A strips are ganged into 16 channels.
The conditions data are stored in an order based on the hadrware channel order so this class has to jump through hoops in order to map between that order and a CSCDetID order offline.

See documentation in base class CSCIndexerBase for more information.

Warning
This class is hard-wired for the CSC system at start-up of CMS in
  1. with rings ME11, ME12, ME13, ME21, ME22, ME31, ME32, ME41 totalling 234 chambers per endcap. But ME42 is appended (to permit simulation studies), so the chamber order is
    +z ME11, ME12, ME13, ME21, ME22, ME31, ME32, ME41,
    -z ME11, ME12, ME13, ME21, ME22, ME31, ME32, ME41,
    +z ME42, -z ME42

    CSCIndexerBase::stripChannelIndex returns
    1-217728 (CSCs 2008), 217729-252288 (ME42) (and ME1a channels are always channels 65-80 of 1-80 in ME11)

    CSCIndexerBase::chipIndex returns
    1-13608 (CSCs 2008), 13609-15768 (ME42)

    CSCIndexerBase::gasGainIndex returns
    1-45144 (CSCs 2008), 45145-55944 (ME42)

This uses magic numbers galore!!
EVERY LABEL COUNTS FROM ONE NOT ZERO.

Definition at line 38 of file CSCIndexerStartup.h.

Constructor & Destructor Documentation

◆ ~CSCIndexerStartup()

CSCIndexerStartup::~CSCIndexerStartup ( )
override

Definition at line 4 of file CSCIndexerStartup.cc.

4 {}

Member Function Documentation

◆ chipsPerLayer()

IndexType CSCIndexerStartup::chipsPerLayer ( IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Number of Buckeye chips indices per layer in a chamber in offline ring 'ir' of station 'is'.

Station label range 1-4, Ring label range 1-4 (4=ME1a)

Warning
: the ME1a CFEB is just the last 1 of the 5 total in each layer of an ME11 chamber. So, the input of ir=4 is will just return the same 5 total chips per whole ME11.

Considers ME42 as standard 5 chip per layer chambers.

Implements CSCIndexerBase.

Definition at line 160 of file CSCIndexerStartup.h.

Referenced by detIdFromGasGainIndex().

160  {
161  const IndexType nCinL[16] = {5, 5, 4, 5, 5, 5, 0, 0, 5, 5, 0, 0, 5, 5, 0, 0};
162  return nCinL[(is - 1) * 4 + ir - 1];
163  }
uint16_t IndexType

◆ chipsPerOnlineLayer()

IndexType CSCIndexerStartup::chipsPerOnlineLayer ( IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Number of Buckeye chips per layer in an online chamber in ring 'ir' of station 'is'. Works for ME1a (ring 4 of ME1) too.

'Online' ME11 for the startup is considered as a single chamber with 5 chips

Implements CSCIndexerBase.

Definition at line 97 of file CSCIndexerStartup.h.

97  {
98  const IndexType nCinL[16] = {5, 5, 4, 5, 5, 5, 0, 0, 5, 5, 0, 0, 5, 5, 0, 0};
99  return nCinL[(is - 1) * 4 + ir - 1];
100  }
uint16_t IndexType

◆ chipStart()

IndexType CSCIndexerStartup::chipStart ( IndexType  ie,
IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Linear index for 1st Buckeye chip in offline ring 'ir' of station 'is' in endcap 'ie'.

Endcap label range 1-2, Station label range 1-4, Ring label range 1-3.

Warning
: while ME1a chip is the last 1 of the 5 chips total in each layer of an ME11 chamber, here the ME1a input ir=4 defaults to the ME1b start index (ir=4 <=> ir=1).

Implements CSCIndexerBase.

Definition at line 175 of file CSCIndexerStartup.h.

175  {
176  // These are in the ranges 1-13608 (CSCs 2008) and 13609-15768 (ME42).
177  // There are 1-6804 chips per endcap (CSCs 2008) and 1080 channels per
178  // endcap (ME42). Start of -z channels (CSCs 2008) is 6804 + 1 = 6805 Start
179  // of +z (ME42) is 13608 + 1 = 13609 Start of -z (ME42) is 13608 + 1 + 1080
180  // = 14689
181  const IndexType nStart[32] = {1, 1081, 2161, 1, 3025, 3565, 0, 0, 4645, 5185, 0, 0, 6265, 13609, 0, 0,
182  6805, 7885, 8965, 6805, 9829, 10369, 0, 0, 11449, 11989, 0, 0, 13069, 14689, 0, 0};
183  return nStart[(ie - 1) * 16 + (is - 1) * 4 + ir - 1];
184  }
uint16_t IndexType

◆ dbIndex()

int CSCIndexerStartup::dbIndex ( const CSCDetId id,
int &  channel 
) const
overridevirtual

Build index used internally in online CSC conditions databases (the 'Igor Index')

This is the decimal integer ie*100000 + is*10000 + ir*1000 + ic*10 + il
(ie=1-2, is=1-4, ir=1-4, ic=1-36, il=1-6)
Channels 1-16 in ME1A (is=1, ir=4) are reset to channels 65-80 of ME11.

Implements CSCIndexerBase.

Definition at line 114 of file CSCIndexerStartup.cc.

114  {
115  int ec = id.endcap();
116  int st = id.station();
117  int rg = id.ring();
118  int ch = id.chamber();
119  int la = id.layer();
120 
121  // The channels of ME1A are channels 65-80 of ME11
122  if (st == 1 && rg == 4) {
123  rg = 1;
124  if (channel <= 16)
125  channel += 64; // no trapping for any bizarreness
126  }
127  return ec * 100000 + st * 10000 + rg * 1000 + ch * 10 + la;
128 }

◆ detIdFromChipIndex()

std::pair< CSCDetId, CSCIndexerBase::IndexType > CSCIndexerStartup::detIdFromChipIndex ( IndexType  ichi) const
overridevirtual

CSCDetId + chip within chamber from conditions data chip index.

Warning
This function changes meaning with ganged and unganged ME1/1a. If ME1/1a is ganged then an ME1/1a chip index returns ME1/1b CSCDetId + chip=5.
If ME1/1a is unganged then an ME1/1a chip index returns ME1/1a CSCDetId + chip# in range 1-3.

Implements CSCIndexerBase.

Definition at line 60 of file CSCIndexerStartup.cc.

References CSCIndexerBase::detIdFromLayerIndex().

60  {
61  const LongIndexType lastnonme42 = 13608; // chips in 2008 installed chambers
62  const LongIndexType lastplusznonme42 = 6804; // = 13608/2
63  const LongIndexType firstme13 = 2161; // First channel of ME13
64  const LongIndexType lastme13 = 3024; // Last channel of ME13
65 
66  const IndexType lastnonme42layer = 2808;
67  const IndexType lastplusznonme42layer = 1404; // = 2808/2
68  const IndexType firstme13layer = 433; // = 72*6 + 1 (ME13 chambers are 72-108 in range 1-234)
69  const IndexType lastme13layer = 648; // = 108*6
70 
71  // All chambers but ME13 have 5 chips/layer
72  IndexType nchipPerLayer = 5;
73 
74  // Set endcap to +z. This should work for ME42 channels too, since we don't
75  // need to calculate its endcap explicitly.
76  IndexType ie = 1;
77 
78  LongIndexType istart = 0;
79  IndexType layerOffset = 0;
80 
81  if (ici <= lastnonme42) // Chambers as of 2008 Installation
82  {
83  if (ici > lastplusznonme42) {
84  ie = 2;
85  ici -= lastplusznonme42;
86  }
87  if (ici > lastme13) // after ME13
88  {
89  istart = lastme13;
90  layerOffset = lastme13layer;
91  } else if (ici >= firstme13) // ME13
92  {
93  istart = firstme13 - 1;
94  layerOffset = firstme13layer - 1;
95  nchipPerLayer = 4;
96  }
97  } else // ME42 chambers
98  {
99  istart = lastnonme42;
100  layerOffset = lastnonme42layer;
101  }
102 
103  ici -= istart; // remove earlier group(s)
104  IndexType ichip = (ici - 1) % nchipPerLayer + 1;
105  IndexType ili = (ici - 1) / nchipPerLayer + 1;
106  ili += layerOffset; // add appropriate offset for earlier group(s)
107  if (ie != 1)
108  ili += lastplusznonme42layer; // add offset to -z endcap; ME42 doesn't need
109  // this.
110 
111  return std::pair<CSCDetId, IndexType>(detIdFromLayerIndex(ili), ichip);
112 }
uint32_t LongIndexType
CSCDetId detIdFromLayerIndex(IndexType ili) const
uint16_t IndexType

◆ detIdFromGasGainIndex()

CSCIndexerBase::GasGainIndexType CSCIndexerStartup::detIdFromGasGainIndex ( IndexType  igg) const
overridevirtual

CSCDetId + HV segment + chip within chamber from conditions data gas gain index.

Warning
This function changes meaning with ganged and unganged ME1/1a. If ME1/1a is ganged then an ME1/1a gas gain index returns ME1/1b CSCDetId + HVsegment=1 + chip=5.
If ME1/1a is unganged then an ME1/1a gas gain index returns ME1/1a CSCDetId + HVsegment=1 + chip# in range 1-3.

Implements CSCIndexerBase.

Definition at line 130 of file CSCIndexerStartup.cc.

References relativeConstraints::chamber, chipsPerLayer(), l1ctLayer2EG_cff::id, createfilelist::int, nano_mu_digi_cff::layer, CSCIndexerBase::sectorsPerLayer(), and pfDeepBoostedJetPreprocessParams_cfi::upper_bound.

130  {
131  const int n_types = 18;
132  const IndexType type_starts[n_types] = {1,
133  1081,
134  4321,
135  6913,
136  8533,
137  13933,
138  15553,
139  20953,
140  22573,
141  23653,
142  26893,
143  29485,
144  31105,
145  36505,
146  38125,
147  43525,
148  45145,
149  50545};
150  //+1/1 +1/2 +1/3 +2/1 +2/2 +3/1 +3/2 +4/1 -1/1 -1/2 -1/3 -2/1
151  //-2/2 -3/1 -3/2 -4/1 +4/2 -4/2
152 
153  const int endcaps[n_types] = {1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2};
154  const int stations[n_types] = {1, 1, 1, 2, 2, 3, 3, 4, 1, 1, 1, 2, 2, 3, 3, 4, 4, 4};
155  const int rings[n_types] = {1, 2, 3, 1, 2, 1, 2, 1, 1, 2, 3, 1, 2, 1, 2, 1, 2, 2};
156 
157  // determine chamber type
158  std::vector<IndexType> v_type_starts(type_starts, type_starts + n_types);
159  int type = int(std::upper_bound(v_type_starts.begin(), v_type_starts.end(), igg) - v_type_starts.begin()) - 1;
160 
161  // determine factors for #HVsectors and #chips
162  int sectors_per_layer = sectorsPerLayer(stations[type], rings[type]);
163  int chips_per_layer = chipsPerLayer(stations[type], rings[type]);
164 
165  IndexType igg_chamber_etc = igg - type_starts[type] + 1;
166 
167  IndexType igg_chamber_and_layer = (igg_chamber_etc - 1) / sectors_per_layer + 1;
168 
169  // extract chamber & layer
170  int chamber = (igg_chamber_and_layer - 1) / 6 + 1;
171  int layer = (igg_chamber_and_layer - 1) % 6 + 1;
172 
173  IndexType igg_hvseg_etc = (igg_chamber_etc - 1) % sectors_per_layer + 1;
174 
175  // extract HVsegment and chip numbers
176  IndexType hvsegment = (igg_hvseg_etc - 1) / chips_per_layer + 1;
177  IndexType chip = (igg_hvseg_etc - 1) % chips_per_layer + 1;
178 
179  CSCDetId id(endcaps[type], stations[type], rings[type], chamber, layer);
180  return std::make_tuple(id, hvsegment, chip);
181 }
uint16_t IndexType
IndexType sectorsPerLayer(IndexType is, IndexType ir) const
IndexType chipsPerLayer(IndexType is, IndexType ir) const override

◆ detIdFromStripChannelIndex()

std::pair< CSCDetId, CSCIndexerBase::IndexType > CSCIndexerStartup::detIdFromStripChannelIndex ( LongIndexType  ichi) const
overridevirtual

Decode CSCDetId from various indexes and labels

Implements CSCIndexerBase.

Definition at line 6 of file CSCIndexerStartup.cc.

References CSCIndexerBase::detIdFromLayerIndex().

6  {
7  const LongIndexType lastnonme42 = 217728; // channels in 2008 installed chambers
8  const LongIndexType lastplusznonme42 = 108864; // = 217728/2
9  const LongIndexType firstme13 = 34561; // First channel of ME13
10  const LongIndexType lastme13 = 48384; // Last channel of ME13
11 
12  const IndexType lastnonme42layer = 2808;
13  const IndexType lastplusznonme42layer = 1404; // = 2808/2
14  const IndexType firstme13layer = 433; // = 72*6 + 1 (ME13 chambers are 72-108 in range 1-234)
15  const IndexType lastme13layer = 648; // = 108*6
16 
17  // All chambers but ME13 have 80 channels
18  IndexType nchan = 80;
19 
20  // Set endcap to +z. This should work for ME42 channels too, since we don't
21  // need to calculate its endcap explicitly.
22  IndexType ie = 1;
23 
24  LongIndexType istart = 0;
25  IndexType layerOffset = 0;
26 
27  if (isi <= lastnonme42) // Chambers as of 2008 Installation
28  {
29  if (isi > lastplusznonme42) {
30  ie = 2;
31  isi -= lastplusznonme42;
32  }
33  if (isi > lastme13) // after ME13
34  {
35  istart = lastme13;
36  layerOffset = lastme13layer;
37  } else if (isi >= firstme13) // ME13
38  {
39  istart = firstme13 - 1;
40  layerOffset = firstme13layer - 1;
41  nchan = 64;
42  }
43  } else // ME42 chambers
44  {
45  istart = lastnonme42;
46  layerOffset = lastnonme42layer;
47  }
48 
49  isi -= istart; // remove earlier group(s)
50  IndexType ichan = (isi - 1) % nchan + 1;
51  IndexType ili = (isi - 1) / nchan + 1;
52  ili += layerOffset; // add appropriate offset for earlier group(s)
53  if (ie != 1)
54  ili += lastplusznonme42layer; // add offset to -z endcap; ME42 doesn't need
55  // this.
56 
57  return std::pair<CSCDetId, IndexType>(detIdFromLayerIndex(ili), ichan);
58 }
uint32_t LongIndexType
CSCDetId detIdFromLayerIndex(IndexType ili) const
uint16_t IndexType

◆ maxChipIndex()

IndexType CSCIndexerStartup::maxChipIndex ( ) const
inlineoverridevirtual

Implements CSCIndexerBase.

Definition at line 47 of file CSCIndexerStartup.h.

47 { return 15768; }

◆ maxGasGainIndex()

IndexType CSCIndexerStartup::maxGasGainIndex ( ) const
inlineoverridevirtual

Implements CSCIndexerBase.

Definition at line 48 of file CSCIndexerStartup.h.

48 { return 55944; }

◆ maxStripChannelIndex()

LongIndexType CSCIndexerStartup::maxStripChannelIndex ( ) const
inlineoverridevirtual

Implements CSCIndexerBase.

Definition at line 46 of file CSCIndexerStartup.h.

46 { return 252288; }

◆ name()

std::string CSCIndexerStartup::name ( ) const
inlineoverridevirtual

Reimplemented from CSCIndexerBase.

Definition at line 42 of file CSCIndexerStartup.h.

Referenced by config.CFG::__str__(), validation.Sample::digest(), and VIDSelectorBase.VIDSelectorBase::initialize().

42 { return "CSCIndexerStartup"; }

◆ onlineRingsInStation()

IndexType CSCIndexerStartup::onlineRingsInStation ( IndexType  is) const
inlineoverridevirtual

How many online rings are there in station 'is'=1, 2, 3, 4 ?

Warning
: ME1a + ME1b are considered as single ME1/1 'online' rings for the startup

Implements CSCIndexerBase.

Definition at line 59 of file CSCIndexerStartup.h.

59  {
60  const IndexType nrings[5] = {0, 3, 2, 2, 2};
61  return nrings[is];
62  }
uint16_t IndexType

◆ sectorStart()

IndexType CSCIndexerStartup::sectorStart ( IndexType  ie,
IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Linear index for 1st Gas gain sector in ring 'ir' of station 'is' in endcap 'ie'.

Endcap label range 1-2, Station label range 1-4, Ring label range 1-4 (4=ME1a)

Warning
: ME1a chip is the last 1 of the 5 chips total in each layer of an ME11 chamber, and an input ir=4 in this case would give the same result as ir=1

Implements CSCIndexerBase.

Definition at line 200 of file CSCIndexerStartup.h.

200  {
201  // There are 36 chambers * 6 layers * 5 CFEB's * 1 HV segment = 1080
202  // gas-gain sectors in ME1/1 There are 36*6*5*3 = 3240 gas-gain sectors in
203  // ME1/2 There are 36*6*4*3 = 2592 gas-gain sectors in ME1/3 There are
204  // 18*6*5*3 = 1620 gas-gain sectors in ME[2-4]/1 There are 36*6*5*5 = 5400
205  // gas-gain sectors in ME[2-4]/2 Start of -z channels (CSCs 2008) is 22572 +
206  // 1 = 22573 Start of +z (ME42) is 45144 + 1 = 45145 Start of -z (ME42) is
207  // 45144 + 1 + 5400 = 50545
208  const IndexType nStart[32] = {1, 1081, 4321,
209  1, // ME+1/1,ME+1/2,ME+1/3,ME+1/4
210  6913, 8533, 0,
211  0, // ME+2/1,ME+2/2,
212  13933, 15553, 0,
213  0, // ME+3/1,ME+3/2,
214  20953, 45145, 0,
215  0, // ME+4/1,ME+4/2,ME+4/3 (note, ME+4/2 index follows ME-4/1...)
216  22573, 23653, 26893,
217  22573, // ME-1/1,ME-1/2,ME-1/3, ME-1/4
218  29485, 31105, 0,
219  0, // ME-2/1,ME-2/2,ME-2/3
220  36505, 38125, 0,
221  0, // ME-3/1,ME-3/2,ME-3/3
222  43525, 50545, 0,
223  0}; // ME-4/1,ME-4/2,ME-4/3 (note, ME-4/2 index follows ME+4/2...)
224  return nStart[(ie - 1) * 16 + (is - 1) * 4 + ir - 1];
225  }
uint16_t IndexType

◆ stripChannelsPerLayer()

IndexType CSCIndexerStartup::stripChannelsPerLayer ( IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Number of strip channel indices for a layer in a chamber defined by station number 'is' and ring number 'ir'.

Station label range 1-4, Ring label range 1-4 (4=ME1a)

This depends on the ordering of the channels in the database. In startup scenario there are 80 indices allocated per ME1/1 layer with 1-64 belonging to ME1b and 65-80 belonging to ME1a. So the ME1/a database indices are mapped to extend the ME1/b index ranges, which is how the raw hardware channels numbering is implemented.

Implements CSCIndexerBase.

Definition at line 118 of file CSCIndexerStartup.h.

118  {
119  const IndexType nSCinC[16] = {80, 80, 64, 80, 80, 80, 0, 0, 80, 80, 0, 0, 80, 80, 0, 0};
120  return nSCinC[(is - 1) * 4 + ir - 1];
121  }
uint16_t IndexType

◆ stripChannelsPerOfflineLayer()

IndexType CSCIndexerStartup::stripChannelsPerOfflineLayer ( IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Number of strip readout channels per layer in an offline chamber with ring 'ir' and station 'is'. Works for ME1a (ring 4 of ME1) too.

Assume ME1a has 16 ganged readout channels.

Implements CSCIndexerBase.

Definition at line 71 of file CSCIndexerStartup.h.

71  {
72  const IndexType nSC[16] = {64, 80, 64, 16, 80, 80, 0, 0, 80, 80, 0, 0, 80, 80, 0, 0};
73  return nSC[(is - 1) * 4 + ir - 1];
74  }
uint16_t IndexType

◆ stripChannelsPerOnlineLayer()

IndexType CSCIndexerStartup::stripChannelsPerOnlineLayer ( IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Number of strip readout channels per layer in an online chamber with ring 'ir' and station 'is'. Works for ME1a (ring 4 of ME1) too.

Assume ME1a has 16 ganged readout channels. Online chamber has 64+16=80 channels.

Implements CSCIndexerBase.

Definition at line 84 of file CSCIndexerStartup.h.

84  {
85  const IndexType nSC[16] = {80, 80, 64, 80, 80, 80, 0, 0, 80, 80, 0, 0, 80, 80, 0, 0};
86  return nSC[(is - 1) * 4 + ir - 1];
87  }
uint16_t IndexType

◆ stripChannelStart()

LongIndexType CSCIndexerStartup::stripChannelStart ( IndexType  ie,
IndexType  is,
IndexType  ir 
) const
inlineoverridevirtual

Linear index for 1st strip channel in ring 'ir' of station 'is' in endcap 'ie'.

Endcap label range 1-2, Station label range 1-4, Ring label range 1-4.

WARNING: while ME1a channels are the last 16 of the 80 total in each layer of an ME11 chamber, their start index here defaults to the start index of ME1a.

Implements CSCIndexerBase.

Definition at line 133 of file CSCIndexerStartup.h.

133  {
134  // These are in the ranges 1-217728 (CSCs 2008) and 217729-252288 (ME42).
135  // There are 1-108884 channels per endcap (CSCs 2008) and 17280 channels per
136  // endcap (ME42). Start of -z channels (CSCs 2008) is 108864 + 1 = 108865
137  // Start of +z (ME42) is 217728 + 1 = 217729
138  // Start of -z (ME42) is 217728 + 1 + 17280 = 235009
139  const LongIndexType nStart[32] = {1, 17281, 34561, 1, 48385, 57025, 0, 0, 74305, 82945, 0,
140  0, 100225, 217729, 0, 0, 108865, 126145, 143425, 108865, 157249, 165889,
141  0, 0, 183169, 191809, 0, 0, 209089, 235009, 0, 0};
142  return nStart[(ie - 1) * 16 + (is - 1) * 4 + ir - 1];
143  }
uint32_t LongIndexType