CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
CSCMotherboardLUTME11 Class Reference

#include <CSCUpgradeMotherboardLUT.h>

Public Member Functions

 CSCMotherboardLUTME11 ()
 
bool doesALCTCrossCLCT (const CSCALCTDigi &a, const CSCCLCTDigi &c, int theEndcap, bool gangedME1a=false) const
 
bool doesWiregroupCrossStrip (int wg, int keystrip, int theEndcap, bool gangedME1a=false) const
 
 ~CSCMotherboardLUTME11 ()
 

Private Attributes

std::vector< std::vector< double > > lut_wg_vs_hs_me1a
 
std::vector< std::vector< double > > lut_wg_vs_hs_me1ag
 
std::vector< std::vector< double > > lut_wg_vs_hs_me1b
 

Detailed Description

Definition at line 15 of file CSCUpgradeMotherboardLUT.h.

Constructor & Destructor Documentation

CSCMotherboardLUTME11::CSCMotherboardLUTME11 ( )

Definition at line 3 of file CSCUpgradeMotherboardLUT.cc.

References lut_wg_vs_hs_me1a, lut_wg_vs_hs_me1ag, and lut_wg_vs_hs_me1b.

3  {
4  // Keep in mind that ME1A is considered an extension of ME1B
5  // This means that ME1A half-strips start at 128 and end at 223
6  lut_wg_vs_hs_me1a = {{128, 223}, {128, 223}, {128, 223}, {128, 223}, {128, 223}, {128, 223}, {128, 223}, {128, 223},
7  {128, 223}, {128, 223}, {128, 223}, {128, 223}, {128, 205}, {128, 189}, {128, 167}, {128, 150},
8  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
9  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
10  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
11  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}};
12  // When the half-strips are triple-ganged, (Run-1)
13  // ME1A half-strips go from 128 to 159
14  lut_wg_vs_hs_me1ag = {{128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159},
15  {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 159}, {128, 150},
16  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
17  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
18  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
19  {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}};
20  // ME1B half-strips start at 0 and end at 127
21  lut_wg_vs_hs_me1b = {{-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1}, {-1, -1},
22  {-1, -1}, {-1, -1}, {100, 127}, {73, 127}, {47, 127}, {22, 127}, {0, 127}, {0, 127},
23  {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127},
24  {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127},
25  {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 127},
26  {0, 127}, {0, 127}, {0, 127}, {0, 127}, {0, 105}, {0, 93}, {0, 78}, {0, 63}};
27 }
std::vector< std::vector< double > > lut_wg_vs_hs_me1ag
std::vector< std::vector< double > > lut_wg_vs_hs_me1a
std::vector< std::vector< double > > lut_wg_vs_hs_me1b
CSCMotherboardLUTME11::~CSCMotherboardLUTME11 ( )
inline

Member Function Documentation

bool CSCMotherboardLUTME11::doesALCTCrossCLCT ( const CSCALCTDigi a,
const CSCCLCTDigi c,
int  theEndcap,
bool  gangedME1a = false 
) const

Definition at line 29 of file CSCUpgradeMotherboardLUT.cc.

References doesWiregroupCrossStrip(), CSCCLCTDigi::getKeyStrip(), CSCALCTDigi::getKeyWG(), CSCALCTDigi::isValid(), and CSCCLCTDigi::isValid().

Referenced by ~CSCMotherboardLUTME11().

32  {
33  if (!c.isValid() || !a.isValid())
34  return false;
35  int key_hs = c.getKeyStrip();
36  int key_wg = a.getKeyWG();
37  return doesWiregroupCrossStrip(key_wg, key_hs, theEndcap, gangedME1a);
38 }
bool isValid() const
check ALCT validity (1 - valid ALCT)
Definition: CSCALCTDigi.h:32
bool isValid() const
check CLCT validity (1 - valid CLCT)
Definition: CSCCLCTDigi.h:35
int getKeyStrip() const
Definition: CSCCLCTDigi.h:94
bool doesWiregroupCrossStrip(int wg, int keystrip, int theEndcap, bool gangedME1a=false) const
int getKeyWG() const
return key wire group
Definition: CSCALCTDigi.h:59
bool CSCMotherboardLUTME11::doesWiregroupCrossStrip ( int  wg,
int  keystrip,
int  theEndcap,
bool  gangedME1a = false 
) const

Definition at line 40 of file CSCUpgradeMotherboardLUT.cc.

References lut_wg_vs_hs_me1a, lut_wg_vs_hs_me1ag, lut_wg_vs_hs_me1b, CSCConstants::MAX_HALF_STRIP_ME1A_GANGED, CSCConstants::MAX_HALF_STRIP_ME1A_UNGANGED, and CSCConstants::MAX_HALF_STRIP_ME1B.

Referenced by doesALCTCrossCLCT(), and ~CSCMotherboardLUTME11().

40  {
41  // ME1/a half-strip starts at 128
42  if (key_hs > CSCConstants::MAX_HALF_STRIP_ME1B) {
43  if (!gangedME1a) {
44  // wrap around ME11 HS number for -z endcap
45  if (theEndcap == 2) {
46  // first subtract 128
48  // flip the HS
50  // then add 128 again
52  }
53  if (key_hs >= lut_wg_vs_hs_me1a[key_wg][0] && key_hs <= lut_wg_vs_hs_me1a[key_wg][1])
54  return true;
55  return false;
56  } else {
57  // wrap around ME11 HS number for -z endcap
58  if (theEndcap == 2) {
59  // first subtract 128
61  // flip the HS
63  // then add 128 again
65  }
66  if (key_hs >= lut_wg_vs_hs_me1ag[key_wg][0] && key_hs <= lut_wg_vs_hs_me1ag[key_wg][1])
67  return true;
68  return false;
69  }
70  }
71  // ME1/b half-strip ends at 127
72  if (key_hs <= CSCConstants::MAX_HALF_STRIP_ME1B) {
73  if (theEndcap == 2)
74  key_hs = CSCConstants::MAX_HALF_STRIP_ME1B - key_hs;
75  if (key_hs >= lut_wg_vs_hs_me1b[key_wg][0] && key_hs <= lut_wg_vs_hs_me1b[key_wg][1])
76  return true;
77  }
78  return false;
79 }
std::vector< std::vector< double > > lut_wg_vs_hs_me1ag
std::vector< std::vector< double > > lut_wg_vs_hs_me1a
std::vector< std::vector< double > > lut_wg_vs_hs_me1b

Member Data Documentation

std::vector<std::vector<double> > CSCMotherboardLUTME11::lut_wg_vs_hs_me1a
private

Definition at line 27 of file CSCUpgradeMotherboardLUT.h.

Referenced by CSCMotherboardLUTME11(), and doesWiregroupCrossStrip().

std::vector<std::vector<double> > CSCMotherboardLUTME11::lut_wg_vs_hs_me1ag
private

Definition at line 28 of file CSCUpgradeMotherboardLUT.h.

Referenced by CSCMotherboardLUTME11(), and doesWiregroupCrossStrip().

std::vector<std::vector<double> > CSCMotherboardLUTME11::lut_wg_vs_hs_me1b
private

Definition at line 32 of file CSCUpgradeMotherboardLUT.h.

Referenced by CSCMotherboardLUTME11(), and doesWiregroupCrossStrip().