CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
CSCStripConditions Class Referenceabstract

#include <CSCStripConditions.h>

Inheritance diagram for CSCStripConditions:
CSCConfigurableStripConditions CSCDbStripConditions

Public Types

typedef math::ErrorD< 8 >::type CSCCorrelatedNoiseMatrix
 
typedef CorrelatedNoisifier< CSCCorrelatedNoiseMatrixCSCCorrelatedNoisifier
 

Public Member Functions

float analogNoise (const CSCDetId &detId, int channel) const
 calculated from pedestalSigma & gain More...
 
virtual void crosstalk (const CSCDetId &detId, int channel, double stripLength, bool leftRight, float &capacitive, float &resistive) const =0
 
 CSCStripConditions ()
 
virtual float gain (const CSCDetId &detId, int channel) const =0
 
virtual float gainSigma (const CSCDetId &detId, int channel) const =0
 
virtual void initializeEvent (const edm::EventSetup &es)
 
virtual bool isInBadChamber (const CSCDetId &id) const
 is supplied layer/chamber flagged as bad? (default impl. is no) More...
 
void noisify (const CSCDetId &detId, CSCAnalogSignal &signal, CLHEP::HepRandomEngine *)
 superimposes noise, in fC, on the signal More...
 
virtual float pedestal (const CSCDetId &detId, int channel) const =0
 in ADC counts More...
 
virtual float pedestalSigma (const CSCDetId &detId, int channel) const =0
 
virtual float smearedGain (const CSCDetId &detId, int channel, CLHEP::HepRandomEngine *) const
 
virtual ~CSCStripConditions ()
 

Protected Member Functions

virtual void fetchNoisifier (const CSCDetId &detId, int istrip)=0
 

Protected Attributes

CSCCorrelatedNoisifiertheNoisifier
 

Detailed Description

Definition at line 13 of file CSCStripConditions.h.

Member Typedef Documentation

◆ CSCCorrelatedNoiseMatrix

Definition at line 15 of file CSCStripConditions.h.

◆ CSCCorrelatedNoisifier

Definition at line 16 of file CSCStripConditions.h.

Constructor & Destructor Documentation

◆ CSCStripConditions()

CSCStripConditions::CSCStripConditions ( )

Definition at line 12 of file CSCStripConditions.cc.

12 : theNoisifier(nullptr) {}
CSCCorrelatedNoisifier * theNoisifier

◆ ~CSCStripConditions()

CSCStripConditions::~CSCStripConditions ( )
virtual

Definition at line 14 of file CSCStripConditions.cc.

14 {}

Member Function Documentation

◆ analogNoise()

float CSCStripConditions::analogNoise ( const CSCDetId detId,
int  channel 
) const

calculated from pedestalSigma & gain

Definition at line 35 of file CSCStripConditions.cc.

References hcalRecHitTable_cff::detId, gain(), pedestalSigma(), and mathSSE::sqrt().

35  {
36  return sqrt(2) * pedestalSigma(detId, channel) / gain(detId, channel);
37 }
virtual float pedestalSigma(const CSCDetId &detId, int channel) const =0
T sqrt(T t)
Definition: SSEVec.h:19
virtual float gain(const CSCDetId &detId, int channel) const =0

◆ crosstalk()

virtual void CSCStripConditions::crosstalk ( const CSCDetId detId,
int  channel,
double  stripLength,
bool  leftRight,
float &  capacitive,
float &  resistive 
) const
pure virtual

◆ fetchNoisifier()

virtual void CSCStripConditions::fetchNoisifier ( const CSCDetId detId,
int  istrip 
)
protectedpure virtual

Implemented in CSCDbStripConditions, and CSCConfigurableStripConditions.

Referenced by noisify().

◆ gain()

virtual float CSCStripConditions::gain ( const CSCDetId detId,
int  channel 
) const
pure virtual

channels count from 1 gain is the ratio that takes us from fC to ADC. Nominally around 2

Implemented in CSCDbStripConditions, and CSCConfigurableStripConditions.

Referenced by analogNoise(), noisify(), and smearedGain().

◆ gainSigma()

virtual float CSCStripConditions::gainSigma ( const CSCDetId detId,
int  channel 
) const
pure virtual

◆ initializeEvent()

virtual void CSCStripConditions::initializeEvent ( const edm::EventSetup es)
inlinevirtual

Reimplemented in CSCDbStripConditions.

Definition at line 24 of file CSCStripConditions.h.

Referenced by CSCDigiProducer::produce().

24 {}

◆ isInBadChamber()

virtual bool CSCStripConditions::isInBadChamber ( const CSCDetId id) const
inlinevirtual

is supplied layer/chamber flagged as bad? (default impl. is no)

Reimplemented in CSCDbStripConditions.

Definition at line 47 of file CSCStripConditions.h.

Referenced by CSCDigitizer::doAction().

47 { return false; }

◆ noisify()

void CSCStripConditions::noisify ( const CSCDetId detId,
CSCAnalogSignal signal,
CLHEP::HepRandomEngine *  engine 
)

superimposes noise, in fC, on the signal

Definition at line 20 of file CSCStripConditions.cc.

References hcalRecHitTable_cff::detId, fetchNoisifier(), gain(), CSCAnalogSignal::getElement(), CSCAnalogSignal::getTimeOffset(), CorrelatedNoisifier< M >::noisify(), muonCSCDigis_cfi::nScaBins, CSCAnalogSignal::superimpose(), and theNoisifier.

Referenced by CSCStripElectronicsSim::makeNoiseSignal().

20  {
21  const int nScaBins = 8;
22  const float scaBinSize = 50.;
23  int channel = signal.getElement();
24  std::vector<float> binValues(nScaBins, 0.);
25  // use a temporary signal, in case we have to rebin
26  CSCAnalogSignal tmpSignal(channel, scaBinSize, binValues, 0., signal.getTimeOffset());
27 
28  fetchNoisifier(detId, channel);
29  theNoisifier->noisify(tmpSignal, engine);
30  // noise matrix is in ADC counts. onvert to fC
31  tmpSignal *= 1. / gain(detId, channel);
32  signal.superimpose(tmpSignal);
33 }
virtual void fetchNoisifier(const CSCDetId &detId, int istrip)=0
void noisify(T &frame, CLHEP::HepRandomEngine *, const VecDou *rangau=nullptr) const
void superimpose(const CSCAnalogSignal &signal2)
virtual float gain(const CSCDetId &detId, int channel) const =0
float getTimeOffset() const
CSCCorrelatedNoisifier * theNoisifier
int getElement() const
constructor from time and amp shape

◆ pedestal()

virtual float CSCStripConditions::pedestal ( const CSCDetId detId,
int  channel 
) const
pure virtual

◆ pedestalSigma()

virtual float CSCStripConditions::pedestalSigma ( const CSCDetId detId,
int  channel 
) const
pure virtual

◆ smearedGain()

float CSCStripConditions::smearedGain ( const CSCDetId detId,
int  channel,
CLHEP::HepRandomEngine *  engine 
) const
virtual

Definition at line 16 of file CSCStripConditions.cc.

References hcalRecHitTable_cff::detId, gain(), and gainSigma().

Referenced by CSCStripElectronicsSim::createDigi().

16  {
17  return CLHEP::RandGaussQ::shoot(engine, gain(detId, channel), gainSigma(detId, channel));
18 }
virtual float gain(const CSCDetId &detId, int channel) const =0
virtual float gainSigma(const CSCDetId &detId, int channel) const =0

Member Data Documentation

◆ theNoisifier

CSCCorrelatedNoisifier* CSCStripConditions::theNoisifier
protected