#include <ESElectronicsSimFast.h>
Definition at line 16 of file ESElectronicsSimFast.h.
ESElectronicsSimFast::ESElectronicsSimFast |
( |
bool |
addNoise, |
|
|
bool |
PreMix1 |
|
) |
| |
ESElectronicsSimFast::~ESElectronicsSimFast |
( |
| ) |
|
void ESElectronicsSimFast::analogToDigital |
( |
CLHEP::HepRandomEngine * |
engine, |
|
|
ESSamples & |
cs, |
|
|
ESDataFrame & |
df, |
|
|
bool |
isNoise = false |
|
) |
| const |
Definition at line 44 of file ESElectronicsSimFast.cc.
References ecalMGPA::adc(), assert(), ESCondObjectContainer< T >::end(), ESCondObjectContainer< T >::find(), ESCondObjectContainer< T >::getMap(), i, CaloTSamplesBase< Ttype >::id(), m_addNoise, m_mips, m_MIPToGeV, m_peds, m_PreMix1, MAXADC, MINADC, ESDataFrame::setSample(), ESDataFrame::setSize(), and CaloTSamplesBase< Ttype >::size().
60 const double baseline ( (
double) it_ped->getMean() ) ;
61 const double sigma ( isNoise ? 0. : (
double) it_ped->getRms() ) ;
62 const double MIPADC ( isNoise ? 0. : (
double) (*it_mip) ) ;
63 const double ADCGeV ( isNoise ? 1. : MIPADC/
m_MIPToGeV ) ;
67 for(
unsigned int i ( 0 ) ;
i !=
cs.size(); ++
i )
69 const double noi ( isNoise || (!
m_addNoise) ? 0 :
70 sigma*CLHEP::RandGaussQ::shoot(engine, 0, 1) ) ;
74 else signal =
cs[
i]*ADCGeV ;
89 if( 0.5 < signal - adc ) ++
adc ;
int adc(sample_type sample)
get the ADC sample (12 bits)
auto_ptr< ClusterSequence > cs
const ESIntercalibConstants * m_mips
const_iterator end() const
const self & getMap() const
const_iterator find(uint32_t rawId) const
void setSample(int i, const ESSample &sam)
const ESPedestals * m_peds
std::vector< Item >::const_iterator const_iterator
void ESElectronicsSimFast::newEvent |
( |
| ) |
|
|
inline |
void ESElectronicsSimFast::setMIPToGeV |
( |
double |
MIPToGeV | ) |
|
void ESElectronicsSimFast::setPedestals |
( |
const ESPedestals * |
peds | ) |
|
bool ESElectronicsSimFast::m_addNoise |
|
private |
double ESElectronicsSimFast::m_MIPToGeV |
|
private |
bool ESElectronicsSimFast::m_PreMix1 |
|
private |