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

Definition at line 16 of file CSCStripConditions.h.

Definition at line 17 of file CSCStripConditions.h.

Constructor & Destructor Documentation

CSCStripConditions::CSCStripConditions ( )

Definition at line 17 of file CSCStripConditions.cc.

18  : theNoisifier(nullptr)
19  {}
CSCCorrelatedNoisifier * theNoisifier
CSCStripConditions::~CSCStripConditions ( )
virtual

Definition at line 22 of file CSCStripConditions.cc.

23 {
24 }

Member Function Documentation

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

calculated from pedestalSigma & gain

Definition at line 51 of file CSCStripConditions.cc.

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

52 {
53  return sqrt(2) * pedestalSigma(detId, channel) / gain(detId, channel);
54 }
virtual float gain(const CSCDetId &detId, int channel) const =0
T sqrt(T t)
Definition: SSEVec.h:18
virtual float pedestalSigma(const CSCDetId &detId, int channel) const =0
virtual void CSCStripConditions::crosstalk ( const CSCDetId detId,
int  channel,
double  stripLength,
bool  leftRight,
float &  capacitive,
float &  resistive 
) const
pure virtual
virtual void CSCStripConditions::fetchNoisifier ( const CSCDetId detId,
int  istrip 
)
protectedpure virtual

Implemented in CSCDbStripConditions, and CSCConfigurableStripConditions.

Referenced by noisify().

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().

virtual float CSCStripConditions::gainSigma ( const CSCDetId detId,
int  channel 
) const
pure virtual
virtual void CSCStripConditions::initializeEvent ( const edm::EventSetup es)
inlinevirtual
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 45 of file CSCStripConditions.h.

Referenced by CSCDigitizer::doAction().

45 { return false; }
void CSCStripConditions::noisify ( const CSCDetId detId,
CSCAnalogSignal signal,
CLHEP::HepRandomEngine *  engine 
)

superimposes noise, in fC, on the signal

Definition at line 33 of file CSCStripConditions.cc.

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

Referenced by CSCStripElectronicsSim::makeNoiseSignal().

34 {
35  const int nScaBins = 8;
36  const float scaBinSize = 50.;
37  int channel = signal.getElement();
38  std::vector<float> binValues(nScaBins, 0.);
39  // use a temporary signal, in case we have to rebin
40  CSCAnalogSignal tmpSignal(channel, scaBinSize, binValues,
41  0., signal.getTimeOffset());
42 
43  fetchNoisifier(detId, channel );
44  theNoisifier->noisify(tmpSignal, engine);
45  // noise matrix is in ADC counts. onvert to fC
46  tmpSignal *= 1./gain(detId, channel);
47  signal.superimpose(tmpSignal);
48 }
virtual void fetchNoisifier(const CSCDetId &detId, int istrip)=0
void noisify(T &frame, CLHEP::HepRandomEngine *, const VecDou *rangau=nullptr) const
int getElement() const
constructor from time and amp shape
virtual float gain(const CSCDetId &detId, int channel) const =0
float getTimeOffset() const
void superimpose(const CSCAnalogSignal &signal2)
CSCCorrelatedNoisifier * theNoisifier
virtual float CSCStripConditions::pedestal ( const CSCDetId detId,
int  channel 
) const
pure virtual
virtual float CSCStripConditions::pedestalSigma ( const CSCDetId detId,
int  channel 
) const
pure virtual
float CSCStripConditions::smearedGain ( const CSCDetId detId,
int  channel,
CLHEP::HepRandomEngine *  engine 
) const
virtual

Definition at line 27 of file CSCStripConditions.cc.

References gain(), and gainSigma().

Referenced by CSCStripElectronicsSim::createDigi().

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

Member Data Documentation

CSCCorrelatedNoisifier* CSCStripConditions::theNoisifier
protected