CMS 3D CMS Logo

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

#include <CSCStripHit.h>

Public Types

typedef std::vector< int > ChannelContainer
 
typedef std::vector< float > StripHitADCContainer
 

Public Member Functions

CSCStripHitclone () const
 Required for storage in RangeMap. More...
 
int closestMaximum () const
 Number of strips to the closest other maximum. More...
 
CSCDetId cscDetId () const
 Strip Hit is in this DetId. More...
 
 CSCStripHit ()
 
 CSCStripHit (const CSCDetId &id, const float &sHitPos, const int &tmax, const ChannelContainer &strips, const StripHitADCContainer &s_adc, const StripHitADCContainer &s_adcRaw, const int &numberOfConsecutiveStrips, const int &closestMaximum, const short int &deadStrip)
 
short int deadStrip () const
 is a neighbouring string a dead strip? More...
 
int numberOfConsecutiveStrips () const
 Number of consecutive strips with charge. More...
 
void print () const
 Print content of the striphit including L1A. More...
 
const StripHitADCContainers_adc () const
 L1A. More...
 
const StripHitADCContainers_adcRaw () const
 the raw ADC counts for each of the strip within cluster More...
 
float sHitPos () const
 Strip hit position (centroid) More...
 
const ChannelContainerstrips () const
 L1A. More...
 
const ChannelContainerstripsl1a () const
 L1A. More...
 
const ChannelContainerstripsTotal () const
 The strips used in cluster to produce strip hit (total content) More...
 
int tmax () const
 Strip hit maximum time bin. More...
 
 ~CSCStripHit ()
 

Private Attributes

int theClosestMaximum
 
int theConsecutiveStrips
 
short int theDeadStrip
 
CSCDetId theDetId
 
StripHitADCContainer theStripHitADCs
 L1A. More...
 
float theStripHitPosition
 
StripHitADCContainer theStripHitRawADCs
 
int theStripHitTmax
 
ChannelContainer theStrips
 
ChannelContainer theStripsHighBits
 L1A. More...
 
ChannelContainer theStripsLowBits
 

Detailed Description

A (1-dim) hit reconstructed from strip data alone

Definition at line 16 of file CSCStripHit.h.

Member Typedef Documentation

◆ ChannelContainer

typedef std::vector<int> CSCStripHit::ChannelContainer

Definition at line 19 of file CSCStripHit.h.

◆ StripHitADCContainer

typedef std::vector<float> CSCStripHit::StripHitADCContainer

Definition at line 18 of file CSCStripHit.h.

Constructor & Destructor Documentation

◆ CSCStripHit() [1/2]

CSCStripHit::CSCStripHit ( )
inline

Definition at line 21 of file CSCStripHit.h.

Referenced by clone().

21 {}

◆ CSCStripHit() [2/2]

CSCStripHit::CSCStripHit ( const CSCDetId id,
const float &  sHitPos,
const int &  tmax,
const ChannelContainer strips,
const StripHitADCContainer s_adc,
const StripHitADCContainer s_adcRaw,
const int &  numberOfConsecutiveStrips,
const int &  closestMaximum,
const short int &  deadStrip 
)

Extract the 2 lowest bytes for strip number

Extract the 2 highest bytes for L1A phase

Definition at line 4 of file CSCStripHit.cc.

References mps_fire::i, createfilelist::int, theStrips, theStripsHighBits, and theStripsLowBits.

13  : theDetId(id),
23  theStripsLowBits.clear();
24  for (int i = 0; i < (int)theStrips.size(); i++) {
25  theStripsLowBits.push_back(theStrips[i] & 0x000000FF);
26  }
28  theStripsHighBits.clear();
29  for (int i = 0; i < (int)theStrips.size(); i++) {
30  theStripsHighBits.push_back(theStrips[i] & 0x0000FF00);
31  }
32 }
const StripHitADCContainer & s_adc() const
L1A.
Definition: CSCStripHit.h:56
StripHitADCContainer theStripHitRawADCs
Definition: CSCStripHit.h:81
const ChannelContainer & strips() const
L1A.
Definition: CSCStripHit.h:50
ChannelContainer theStripsLowBits
Definition: CSCStripHit.h:78
int numberOfConsecutiveStrips() const
Number of consecutive strips with charge.
Definition: CSCStripHit.h:62
int theConsecutiveStrips
Definition: CSCStripHit.h:82
ChannelContainer theStrips
Definition: CSCStripHit.h:77
float sHitPos() const
Strip hit position (centroid)
Definition: CSCStripHit.h:41
CSCDetId theDetId
Definition: CSCStripHit.h:74
short int deadStrip() const
is a neighbouring string a dead strip?
Definition: CSCStripHit.h:68
ChannelContainer theStripsHighBits
L1A.
Definition: CSCStripHit.h:79
const StripHitADCContainer & s_adcRaw() const
the raw ADC counts for each of the strip within cluster
Definition: CSCStripHit.h:59
short int theDeadStrip
Definition: CSCStripHit.h:84
int closestMaximum() const
Number of strips to the closest other maximum.
Definition: CSCStripHit.h:65
float theStripHitPosition
Definition: CSCStripHit.h:75
int tmax() const
Strip hit maximum time bin.
Definition: CSCStripHit.h:44
StripHitADCContainer theStripHitADCs
L1A.
Definition: CSCStripHit.h:80
int theStripHitTmax
Definition: CSCStripHit.h:76
int theClosestMaximum
Definition: CSCStripHit.h:83

◆ ~CSCStripHit()

CSCStripHit::~CSCStripHit ( )
inline

Definition at line 32 of file CSCStripHit.h.

32 {}

Member Function Documentation

◆ clone()

CSCStripHit* CSCStripHit::clone ( void  ) const
inline

Required for storage in RangeMap.

Definition at line 35 of file CSCStripHit.h.

References CSCStripHit().

35 { return new CSCStripHit(*this); }

◆ closestMaximum()

int CSCStripHit::closestMaximum ( ) const
inline

Number of strips to the closest other maximum.

Definition at line 65 of file CSCStripHit.h.

References theClosestMaximum.

Referenced by CSCXonStrip_MatchGatti::findXOnStrip().

65 { return theClosestMaximum; }
int theClosestMaximum
Definition: CSCStripHit.h:83

◆ cscDetId()

CSCDetId CSCStripHit::cscDetId ( ) const
inline

Strip Hit is in this DetId.

Definition at line 38 of file CSCStripHit.h.

References theDetId.

Referenced by print().

38 { return theDetId; }
CSCDetId theDetId
Definition: CSCStripHit.h:74

◆ deadStrip()

short int CSCStripHit::deadStrip ( ) const
inline

is a neighbouring string a dead strip?

Definition at line 68 of file CSCStripHit.h.

References theDeadStrip.

Referenced by CSCXonStrip_MatchGatti::findXOnStrip(), and CSCMake2DRecHit::hitFromStripAndWire().

68 { return theDeadStrip; };
short int theDeadStrip
Definition: CSCStripHit.h:84

◆ numberOfConsecutiveStrips()

int CSCStripHit::numberOfConsecutiveStrips ( ) const
inline

Number of consecutive strips with charge.

Definition at line 62 of file CSCStripHit.h.

References theConsecutiveStrips.

Referenced by CSCXonStrip_MatchGatti::findXOnStrip().

62 { return theConsecutiveStrips; }
int theConsecutiveStrips
Definition: CSCStripHit.h:82

◆ print()

void CSCStripHit::print ( void  ) const

Print content of the striphit including L1A.

Debug.

L1A

Definition at line 35 of file CSCStripHit.cc.

References gather_cfg::cout, cscDetId(), TauDecayModes::dec, nano_mu_digi_cff::float, mps_fire::i, createfilelist::int, dqmdumpme::k, s_adc(), s_adcRaw(), sHitPos(), strips(), stripsl1a(), and tmax().

35  {
36  std::cout << "CSCStripHit in CSC Detector: " << std::dec << cscDetId() << std::endl;
37  std::cout << " sHitPos: " << sHitPos() << std::endl;
38  std::cout << " TMAX: " << tmax() << std::endl;
39  std::cout << " STRIPS: ";
40  for (int i = 0; i < (int)strips().size(); i++) {
41  std::cout << std::dec << strips()[i] << " ("
42  << "HEX: " << std::hex << strips()[i] << ")"
43  << " ";
44  }
45  std::cout << std::endl;
46 
48  std::cout << " L1APhase: ";
49  for (int i = 0; i < (int)stripsl1a().size(); i++) {
50  //uint16_t L1ABitSet=(strips()[i] & 0xFF00);
51  //std::cout << std::hex << (stripsl1a()[i] >> 15)<< " ";
52 
53  std::cout << "|";
54  for (int k = 0; k < 8; k++) {
55  std::cout << ((stripsl1a()[i] >> (15 - k)) & 0x1) << " ";
56  }
57  std::cout << "| ";
58  }
59  std::cout << std::endl;
60 
61  std::cout << " S_ADC: ";
62  for (int i = 0; i < (float)s_adc().size(); i++) {
63  std::cout << s_adc()[i] << " ";
64  }
65  std::cout << std::endl;
66  std::cout << " S_ADC_RAW: ";
67  for (int i = 0; i < (float)s_adcRaw().size(); i++) {
68  std::cout << s_adcRaw()[i] << " ";
69  }
70  std::cout << std::endl;
71 }
const StripHitADCContainer & s_adc() const
L1A.
Definition: CSCStripHit.h:56
const ChannelContainer & strips() const
L1A.
Definition: CSCStripHit.h:50
const ChannelContainer & stripsl1a() const
L1A.
Definition: CSCStripHit.h:53
float sHitPos() const
Strip hit position (centroid)
Definition: CSCStripHit.h:41
CSCDetId cscDetId() const
Strip Hit is in this DetId.
Definition: CSCStripHit.h:38
const StripHitADCContainer & s_adcRaw() const
the raw ADC counts for each of the strip within cluster
Definition: CSCStripHit.h:59
int tmax() const
Strip hit maximum time bin.
Definition: CSCStripHit.h:44

◆ s_adc()

const StripHitADCContainer& CSCStripHit::s_adc ( ) const
inline

L1A.

the ADC counts for each of the strip within cluster

Definition at line 56 of file CSCStripHit.h.

References theStripHitADCs.

Referenced by CSCXonStrip_MatchGatti::findXOnStrip(), CSCMake2DRecHit::hitFromStripAndWire(), and print().

56 { return theStripHitADCs; }
StripHitADCContainer theStripHitADCs
L1A.
Definition: CSCStripHit.h:80

◆ s_adcRaw()

const StripHitADCContainer& CSCStripHit::s_adcRaw ( ) const
inline

the raw ADC counts for each of the strip within cluster

Definition at line 59 of file CSCStripHit.h.

References theStripHitRawADCs.

Referenced by CSCMake2DRecHit::hitFromStripAndWire(), and print().

59 { return theStripHitRawADCs; }
StripHitADCContainer theStripHitRawADCs
Definition: CSCStripHit.h:81

◆ sHitPos()

float CSCStripHit::sHitPos ( ) const
inline

Strip hit position (centroid)

Definition at line 41 of file CSCStripHit.h.

References theStripHitPosition.

Referenced by print().

41 { return theStripHitPosition; }
float theStripHitPosition
Definition: CSCStripHit.h:75

◆ strips()

const ChannelContainer& CSCStripHit::strips ( ) const
inline

L1A.

The strips used in cluster to produce strip hit

Definition at line 50 of file CSCStripHit.h.

References theStripsLowBits.

Referenced by CSCXonStrip_MatchGatti::findXOnStrip(), CSCMake2DRecHit::hitFromStripAndWire(), and print().

50 { return theStripsLowBits; }
ChannelContainer theStripsLowBits
Definition: CSCStripHit.h:78

◆ stripsl1a()

const ChannelContainer& CSCStripHit::stripsl1a ( ) const
inline

L1A.

The L1A phase in strips used to produce strip hit

Definition at line 53 of file CSCStripHit.h.

References theStripsHighBits.

Referenced by CSCMake2DRecHit::hitFromStripAndWire(), and print().

53 { return theStripsHighBits; }
ChannelContainer theStripsHighBits
L1A.
Definition: CSCStripHit.h:79

◆ stripsTotal()

const ChannelContainer& CSCStripHit::stripsTotal ( ) const
inline

The strips used in cluster to produce strip hit (total content)

Definition at line 47 of file CSCStripHit.h.

References theStrips.

Referenced by CSCMake2DRecHit::hitFromStripAndWire().

47 { return theStrips; }
ChannelContainer theStrips
Definition: CSCStripHit.h:77

◆ tmax()

int CSCStripHit::tmax ( ) const
inline

Strip hit maximum time bin.

Definition at line 44 of file CSCStripHit.h.

References theStripHitTmax.

Referenced by CSCXonStrip_MatchGatti::findXOnStrip(), CSCMake2DRecHit::hitFromStripAndWire(), and print().

44 { return theStripHitTmax; }
int theStripHitTmax
Definition: CSCStripHit.h:76

Member Data Documentation

◆ theClosestMaximum

int CSCStripHit::theClosestMaximum
private

Definition at line 83 of file CSCStripHit.h.

Referenced by closestMaximum().

◆ theConsecutiveStrips

int CSCStripHit::theConsecutiveStrips
private

Definition at line 82 of file CSCStripHit.h.

Referenced by numberOfConsecutiveStrips().

◆ theDeadStrip

short int CSCStripHit::theDeadStrip
private

Definition at line 84 of file CSCStripHit.h.

Referenced by deadStrip().

◆ theDetId

CSCDetId CSCStripHit::theDetId
private

Definition at line 74 of file CSCStripHit.h.

Referenced by cscDetId().

◆ theStripHitADCs

StripHitADCContainer CSCStripHit::theStripHitADCs
private

L1A.

Definition at line 80 of file CSCStripHit.h.

Referenced by s_adc().

◆ theStripHitPosition

float CSCStripHit::theStripHitPosition
private

Definition at line 75 of file CSCStripHit.h.

Referenced by sHitPos().

◆ theStripHitRawADCs

StripHitADCContainer CSCStripHit::theStripHitRawADCs
private

Definition at line 81 of file CSCStripHit.h.

Referenced by s_adcRaw().

◆ theStripHitTmax

int CSCStripHit::theStripHitTmax
private

Definition at line 76 of file CSCStripHit.h.

Referenced by tmax().

◆ theStrips

ChannelContainer CSCStripHit::theStrips
private

Definition at line 77 of file CSCStripHit.h.

Referenced by CSCStripHit(), and stripsTotal().

◆ theStripsHighBits

ChannelContainer CSCStripHit::theStripsHighBits
private

L1A.

Definition at line 79 of file CSCStripHit.h.

Referenced by CSCStripHit(), and stripsl1a().

◆ theStripsLowBits

ChannelContainer CSCStripHit::theStripsLowBits
private

Definition at line 78 of file CSCStripHit.h.

Referenced by CSCStripHit(), and strips().