CMS 3D CMS Logo

CSCFrontRearLUT.cc
Go to the documentation of this file.
2 
3 unsigned CSCFrontRearLUT::getFRBit(int sector, int subsector, int station, int cscid) {
4  unsigned dc = 0, sector_type = 0;
5  unsigned fr_table[16][6] = {{0, 1, 1, 0, 1, 0},
6  {1, 0, 0, 1, 0, 1},
7  {0, 1, 1, 0, 1, 0},
8  {0, 0, 1, 1, 1, 0},
9  {1, 1, 0, 0, 0, 1},
10  {0, 0, 1, 1, 1, 0},
11  {1, 1, 0, 0, dc, dc},
12  {0, 0, 1, 1, dc, dc},
13  {1, 1, 0, 0, dc, dc},
14  {dc, dc, dc, dc, 1, 0}, // cscid 10-12 are me1a
15  {dc, dc, dc, dc, 0, 1},
16  {dc, dc, dc, dc, 1, 0},
17  {dc, dc, dc, dc, dc, dc},
18  {dc, dc, dc, dc, dc, dc},
19  {dc, dc, dc, dc, dc, dc},
20  {dc, dc, dc, dc, dc, dc}};
21 
22  switch (station) {
23  case 1:
24  sector_type = 4 + subsector;
25  break;
26  case 2:
27  sector_type = 1 - (sector % 2);
28  break;
29  case 3:
30  sector_type = 3 - (sector % 2);
31  break;
32  case 4:
33  sector_type = 3 - (sector % 2);
34  break;
35  //default:
36  //std::cout << "+++ Error: unforeseen station " << stn << "in GetFRBit +++"; // replace with message logger or exception
37  }
38  return fr_table[cscid - 1][sector_type];
39 }
relativeConstraints.station
station
Definition: relativeConstraints.py:67
CSCFrontRearLUT.h
CSCFrontRearLUT::getFRBit
static unsigned getFRBit(int sector, int subsector, int station, int cscid)
Definition: CSCFrontRearLUT.cc:3