#include <CSCBaseElectronicsSim.h>
Public Types | |
typedef std::map< int, CSCAnalogSignal, std::less< int > > | CSCSignalMap |
typedef edm::DetSet< StripDigiSimLink > | DigiSimLinks |
Public Member Functions | |
const DigiSimLinks & | digiSimLinks () const |
void | setLayerId (const CSCDetId &id) |
for standalone apps who don't calculate it from the geometry More... | |
void | simulate (const CSCLayer *layer, const std::vector< CSCDetectorHit > &inputHits, CLHEP::HepRandomEngine *) |
virtual | ~CSCBaseElectronicsSim () |
Protected Types | |
enum | { NONE, CONSERVATIVE, RADICAL } |
typedef std::multimap< int, CSCDetectorHit, std::less< int > > | DetectorHitMap |
Protected Member Functions | |
CSCAnalogSignal & | add (const CSCAnalogSignal &, CLHEP::HepRandomEngine *) |
virtual void | addLinks (int channelIndex) |
void | addNoise (CLHEP::HepRandomEngine *) |
CSCAnalogSignal | amplifySignal (const CSCDetectorHit &) |
double | averageTimeOfFlight (const DetId &detId) const |
virtual float | calculateAmpResponse (float t) const =0 |
virtual int | channelIndex (int channel) const |
lets users map channels to different indices for links More... | |
void | combineAnalogSignals (const std::vector< CSCAnalogSignal > &) |
CSCBaseElectronicsSim (const edm::ParameterSet &p) | |
void | fillAmpResponse () |
CSCAnalogSignal & | find (int element, CLHEP::HepRandomEngine *) |
virtual void | initParameters ()=0 |
CSCDetId | layerId () const |
the CSCDetId corresponding to the current layer More... | |
virtual CSCAnalogSignal | makeNoiseSignal (int element, CLHEP::HepRandomEngine *) |
virtual int | readoutElement (int element) const =0 |
void | setLayer (const CSCLayer *layer) |
void | setNoise (float rmsNoise, float noiseSigmaThreshold) |
void | setSignalTimeRange (double startTime, double stopTime) |
virtual float | signalDelay (int element, float pos) const |
Protected Attributes | |
bool | doNoise_ |
int | nElements |
CSCAnalogSignal | theAmpResponse |
float | theBunchSpacing |
std::vector< double > | theBunchTimingOffsets |
DetectorHitMap | theDetectorHitMap |
DigiSimLinks | theDigiSimLinks |
const CSCLayer * | theLayer |
const CSCLayerGeometry * | theLayerGeometry |
CSCDetId | theLayerId |
bool | theNoiseWasAdded |
int | theNumberOfSamples |
int | theOffsetOfBxZero |
float | thePeakTimeSigma |
float | theSamplingTime |
int | theShapingTime |
CSCSignalMap | theSignalMap |
std::vector< double > | theSignalPropagationSpeed |
float | theSignalStartTime |
float | theSignalStopTime |
const CSCChamberSpecs * | theSpecs |
std::vector< double > | theTimingCalibrationError |
Commonalities between CSCStripElectronicsSim and CSCWireElectronicsSim.
It has three non-virtual functions, so that's enough to deserve a new class. And since it has virtual functions it needs a virtual dtor.
Definition at line 37 of file CSCBaseElectronicsSim.h.
typedef std::map<int, CSCAnalogSignal, std::less<int> > CSCBaseElectronicsSim::CSCSignalMap |
Definition at line 39 of file CSCBaseElectronicsSim.h.
|
protected |
Definition at line 158 of file CSCBaseElectronicsSim.h.
Definition at line 40 of file CSCBaseElectronicsSim.h.
|
protected |
|
virtual |
Definition at line 38 of file CSCBaseElectronicsSim.cc.
|
protected |
Definition at line 15 of file CSCBaseElectronicsSim.cc.
References theBunchTimingOffsets.
|
protected |
Definition at line 151 of file CSCBaseElectronicsSim.cc.
References find(), CSCAnalogSignal::getElement(), and CSCAnalogSignal::superimpose().
Referenced by counter.Counter::register(), and simulate().
|
protectedvirtual |
creates links from Digi to SimTrack disabled for now
Definition at line 167 of file CSCBaseElectronicsSim.cc.
References ALCARECOTkAlJpsiMuMu_cff::charge, PSimHit::eventId(), edm::DetSet< T >::push_back(), theDetectorHitMap, and theDigiSimLinks.
Referenced by CSCStripElectronicsSim::createDigi(), and CSCWireElectronicsSim::fillDigis().
|
protected |
Definition at line 119 of file CSCBaseElectronicsSim.cc.
References makeNoiseSignal(), theNoiseWasAdded, thePeakTimeSigma, theSignalMap, and hgcalLayerClusters_cff::timeOffset.
Referenced by simulate().
|
protected |
Definition at line 98 of file CSCBaseElectronicsSim.cc.
References channelIndex(), CSCDetectorHit::getCharge(), CSCDetectorHit::getElement(), CSCDetectorHit::getPosition(), CSCDetectorHit::getTime(), readoutElement(), signalDelay(), theAmpResponse, and theDetectorHitMap.
Referenced by simulate().
|
protected |
the average time-of-flight from the interaction point to the given detector
|
protectedpure virtual |
Implemented in CSCStripElectronicsSim, and CSCWireElectronicsSim.
Referenced by fillAmpResponse().
|
inlineprotectedvirtual |
lets users map channels to different indices for links
Reimplemented in CSCWireElectronicsSim.
Definition at line 101 of file CSCBaseElectronicsSim.h.
Referenced by amplifySignal(), and CSCStripElectronicsSim::createDigi().
|
protected |
|
inline |
Definition at line 46 of file CSCBaseElectronicsSim.h.
Referenced by CSCDigitizer::doAction().
|
protected |
Definition at line 83 of file CSCBaseElectronicsSim.cc.
References calculateAmpResponse(), mps_fire::i, LogTrace, theAmpResponse, theNumberOfSamples, and theSamplingTime.
Referenced by CSCStripElectronicsSim::CSCStripElectronicsSim(), and CSCWireElectronicsSim::CSCWireElectronicsSim().
|
protected |
Definition at line 131 of file CSCBaseElectronicsSim.cc.
References LogTrace, makeNoiseSignal(), nElements, theNoiseWasAdded, theNumberOfSamples, theSamplingTime, theSignalMap, and theSignalStartTime.
Referenced by add(), CSCStripElectronicsSim::addCrosstalk(), CSCStripElectronicsSim::fillStripDigis(), and CSCStripElectronicsSim::runComparator().
|
protectedpure virtual |
Implemented in CSCStripElectronicsSim, and CSCWireElectronicsSim.
Referenced by setLayer().
|
inlineprotected |
the CSCDetId corresponding to the current layer
Definition at line 104 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::addCrosstalk(), CSCStripElectronicsSim::createDigi(), CSCWireElectronicsSim::fillDigis(), CSCStripElectronicsSim::fillDigis(), CSCStripElectronicsSim::fillStripDigis(), CSCStripElectronicsSim::makeNoiseSignal(), and simulate().
|
protectedvirtual |
Reimplemented in CSCStripElectronicsSim.
Definition at line 113 of file CSCBaseElectronicsSim.cc.
References theNumberOfSamples, theSamplingTime, and theSignalStartTime.
Referenced by addNoise(), and find().
|
protectedpure virtual |
Implemented in CSCStripElectronicsSim, and CSCWireElectronicsSim.
Referenced by amplifySignal(), and simulate().
|
protected |
Definition at line 73 of file CSCBaseElectronicsSim.cc.
References CSCLayer::chamber(), GeomDet::geographicalId(), CSCLayer::geometry(), initParameters(), DetId::rawId(), CSCChamber::specs(), theLayer, theLayerGeometry, theLayerId, and theSpecs.
Referenced by CSCStripElectronicsSim::fillMissingLayer(), and simulate().
|
inline |
for standalone apps who don't calculate it from the geometry
Definition at line 51 of file CSCBaseElectronicsSim.h.
References triggerObjects_cff::id, AlCaHLTBitMon_ParallelJobs::p, and protons_cff::t.
|
protected |
|
inlineprotected |
How long before & after the bunch crossing to simulate shortening the time can save CPU
Definition at line 77 of file CSCBaseElectronicsSim.h.
References PVValHelper::add(), and spr::find().
|
protectedvirtual |
how long, in ns, it takes a signal at pos to propagate to the readout edge. This may be negative, since the timing may be calibrated to the center of the detector
Definition at line 158 of file CSCBaseElectronicsSim.cc.
References CSCChamberSpecs::chamberType(), SoftLeptonByDistance_cfi::distance, PixelCPEClusterRepair_cfi::speed, theSignalPropagationSpeed, and theSpecs.
Referenced by amplifySignal().
void CSCBaseElectronicsSim::simulate | ( | const CSCLayer * | layer, |
const std::vector< CSCDetectorHit > & | inputHits, | ||
CLHEP::HepRandomEngine * | engine | ||
) |
Definition at line 40 of file CSCBaseElectronicsSim.cc.
References add(), addNoise(), amplifySignal(), doNoise_, AlCaHLTBitMon_QueryRunRegistry::getElement(), mps_fire::i, layerId(), readoutElement(), setLayer(), theDetectorHitMap, theDigiSimLinks, theNoiseWasAdded, and theSignalMap.
Referenced by CSCDigitizer::doAction().
|
protected |
Definition at line 155 of file CSCBaseElectronicsSim.h.
Referenced by CSCWireElectronicsSim::fillDigis(), CSCStripElectronicsSim::makeNoiseSignal(), and simulate().
|
protected |
Definition at line 130 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::addCrosstalk(), CSCStripElectronicsSim::channelsToRead(), find(), CSCWireElectronicsSim::initParameters(), CSCStripElectronicsSim::initParameters(), CSCStripElectronicsSim::runComparator(), and CSCStripElectronicsSim::selfTest().
|
protected |
Definition at line 119 of file CSCBaseElectronicsSim.h.
Referenced by amplifySignal(), and fillAmpResponse().
|
protected |
Definition at line 122 of file CSCBaseElectronicsSim.h.
Referenced by CSCWireElectronicsSim::fillDigis(), and CSCStripElectronicsSim::runComparator().
|
protected |
Definition at line 137 of file CSCBaseElectronicsSim.h.
Referenced by CSCBaseElectronicsSim(), CSCWireElectronicsSim::fillDigis(), and CSCStripElectronicsSim::initParameters().
|
protected |
Definition at line 159 of file CSCBaseElectronicsSim.h.
Referenced by addLinks(), amplifySignal(), CSCStripElectronicsSim::getKeyStripsFromMC(), and simulate().
|
protected |
Definition at line 160 of file CSCBaseElectronicsSim.h.
Referenced by addLinks(), and simulate().
|
protected |
Definition at line 115 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::initParameters(), setLayer(), and CSCWireElectronicsSim::timeOfFlightCalibration().
|
protected |
Definition at line 114 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::addCrosstalk(), CSCWireElectronicsSim::initParameters(), CSCStripElectronicsSim::initParameters(), CSCWireElectronicsSim::readoutElement(), CSCStripElectronicsSim::readoutElement(), setLayer(), and CSCWireElectronicsSim::timeOfFlightCalibration().
|
protected |
Definition at line 116 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::fillMissingLayer(), and setLayer().
|
protected |
Definition at line 127 of file CSCBaseElectronicsSim.h.
Referenced by addNoise(), find(), and simulate().
|
protected |
Definition at line 147 of file CSCBaseElectronicsSim.h.
Referenced by fillAmpResponse(), find(), CSCStripElectronicsSim::initParameters(), CSCStripElectronicsSim::makeNoiseSignal(), and makeNoiseSignal().
|
protected |
Definition at line 150 of file CSCBaseElectronicsSim.h.
Referenced by CSCWireElectronicsSim::fillDigis(), CSCStripElectronicsSim::getKeyStrips(), and CSCStripElectronicsSim::runComparator().
|
protected |
Definition at line 134 of file CSCBaseElectronicsSim.h.
Referenced by addNoise().
|
protected |
Definition at line 144 of file CSCBaseElectronicsSim.h.
Referenced by fillAmpResponse(), CSCWireElectronicsSim::fillDigis(), find(), CSCStripElectronicsSim::initParameters(), CSCStripElectronicsSim::makeNoiseSignal(), and makeNoiseSignal().
|
protected |
Definition at line 133 of file CSCBaseElectronicsSim.h.
Referenced by CSCWireElectronicsSim::initParameters(), and CSCStripElectronicsSim::initParameters().
|
protected |
Definition at line 118 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::addCrosstalk(), addNoise(), CSCWireElectronicsSim::fillDigis(), CSCStripElectronicsSim::fillMissingLayer(), find(), CSCStripElectronicsSim::runComparator(), and simulate().
|
protected |
Speed (cm/ns) that it takes for the signal to get from the element to the readout. Actually negative in strips, due to reflection effects.
Definition at line 153 of file CSCBaseElectronicsSim.h.
Referenced by signalDelay().
|
protected |
Definition at line 140 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::createDigi(), CSCWireElectronicsSim::fillDigis(), find(), CSCStripElectronicsSim::initParameters(), CSCStripElectronicsSim::makeNoiseSignal(), makeNoiseSignal(), and CSCStripElectronicsSim::runComparator().
|
protected |
Definition at line 141 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::initParameters(), and CSCStripElectronicsSim::runComparator().
|
protected |
Definition at line 113 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::createDigi(), CSCWireElectronicsSim::fillDigis(), CSCWireElectronicsSim::initParameters(), CSCStripElectronicsSim::initParameters(), setLayer(), and signalDelay().
|
protected |
Definition at line 154 of file CSCBaseElectronicsSim.h.
Referenced by CSCStripElectronicsSim::createDigi(), and CSCWireElectronicsSim::fillDigis().