#include <BesEmcWaveform.hh>
◆ BesEmcWaveform() [1/4]
BesEmcWaveform::BesEmcWaveform |
( |
| ) |
|
Definition at line 21 of file BesEmcWaveform.cc.
22{
24
25
37 m_flag = -1;
38 m_highPrecision = m_highRange/((G4double)(1<<m_bitNb));
39 m_midPrecision = m_midRange/((G4double)(1<<m_bitNb));
40 m_lowPrecision = m_lowRange/((G4double)(1<<m_bitNb));
42
45}
static BesEmcParameter & GetInstance()
G4double GetNonuniformity()
G4double GetPhotonsPerMeV()
◆ BesEmcWaveform() [2/4]
BesEmcWaveform::BesEmcWaveform |
( |
G4long |
size, |
|
|
G4double |
tau, |
|
|
G4double |
sampleTime |
|
) |
| |
Definition at line 47 of file BesEmcWaveform.cc.
48 :m_tau(tau),m_sampleTime(sampleTime)
49{
50 if(size>0){
54 while(init!=
emcWave) *--init=0.0;
55 }
56 else{
57 G4Exception("Invalid size");
58 }
59}
◆ ~BesEmcWaveform() [1/2]
BesEmcWaveform::~BesEmcWaveform |
( |
| ) |
|
|
virtual |
◆ BesEmcWaveform() [3/4]
BesEmcWaveform::BesEmcWaveform |
( |
| ) |
|
◆ BesEmcWaveform() [4/4]
BesEmcWaveform::BesEmcWaveform |
( |
G4long |
, |
|
|
G4double |
, |
|
|
G4double |
|
|
) |
| |
◆ ~BesEmcWaveform() [2/2]
virtual BesEmcWaveform::~BesEmcWaveform |
( |
| ) |
|
|
virtual |
◆ addElecNoise() [1/2]
void BesEmcWaveform::addElecNoise |
( |
G4double |
width, |
|
|
G4double |
coherentNoise |
|
) |
| |
◆ addElecNoise() [2/2]
void BesEmcWaveform::addElecNoise |
( |
G4double |
, |
|
|
G4double |
|
|
) |
| |
◆ digitize() [1/2]
void BesEmcWaveform::digitize |
( |
| ) |
|
Definition at line 159 of file BesEmcWaveform.cc.
160{
161 G4double oneBitResolution;
162 oneBitResolution = m_midRange*2/((G4double)(1<<m_bitNb));
164
166 {
169 G4cout<<
"---In BesEmcWaveform: Over measurement!--- energy="<<
energy<<G4endl;
170 else if(
energy > m_midRange)
171 {
172 m_flag = 2;
173 emcWave[i] = (G4double)((G4long)(
emcWave[i]/m_highPrecision))*m_highPrecision;
174 }
175 else if(
energy > m_lowRange)
176 {
177 m_flag = 1;
178 emcWave[i] = (G4double)((G4long)(
emcWave[i]/m_midPrecision))*m_midPrecision;
179 }
180 else
181 {
182 m_flag = 0;
183 emcWave[i] = (G4double)((G4long)(
emcWave[i]/m_lowPrecision))*m_lowPrecision;
184 }
185 }
186}
************Class m_ypar INTEGER m_KeyWgt INTEGER m_nphot INTEGER m_KeyGPS INTEGER m_IsBeamPolarized INTEGER m_EvtGenInterface DOUBLE PRECISION m_Emin DOUBLE PRECISION m_sphot DOUBLE PRECISION m_Xenph DOUBLE PRECISION m_q2 DOUBLE PRECISION m_PolBeam2 DOUBLE PRECISION m_xErrPb *COMMON c_KK2f $ !CMS energy average $ !Spin Polarization vector first beam $ !Spin Polarization vector second beam $ !Beam energy spread[GeV] $ !minimum hadronization energy[GeV] $ !input READ never touch them !$ !debug facility $ !maximum weight $ !inverse alfaQED $ !minimum real photon energy
Referenced by BesEmcDigitizer::AddNoise5x5(), BesEmcDigitizer::AddNoiseAll(), and BesEmcDigitizer::Digitize().
◆ digitize() [2/2]
void BesEmcWaveform::digitize |
( |
| ) |
|
◆ GetBitNb() [1/2]
G4int BesEmcWaveform::GetBitNb |
( |
| ) |
const |
|
inline |
◆ GetBitNb() [2/2]
G4int BesEmcWaveform::GetBitNb |
( |
| ) |
const |
|
inline |
◆ GetGainFlag() [1/2]
G4int BesEmcWaveform::GetGainFlag |
( |
| ) |
const |
|
inline |
◆ GetGainFlag() [2/2]
G4int BesEmcWaveform::GetGainFlag |
( |
| ) |
const |
|
inline |
◆ GetNonuniformity() [1/2]
G4double BesEmcWaveform::GetNonuniformity |
( |
| ) |
const |
|
inline |
◆ GetNonuniformity() [2/2]
G4double BesEmcWaveform::GetNonuniformity |
( |
| ) |
const |
|
inline |
◆ GetPeakTime() [1/2]
G4double BesEmcWaveform::GetPeakTime |
( |
| ) |
const |
|
inline |
◆ GetPeakTime() [2/2]
G4double BesEmcWaveform::GetPeakTime |
( |
| ) |
const |
|
inline |
◆ GetPhotonsPerMeV() [1/2]
G4double BesEmcWaveform::GetPhotonsPerMeV |
( |
| ) |
const |
|
inline |
◆ GetPhotonsPerMeV() [2/2]
G4double BesEmcWaveform::GetPhotonsPerMeV |
( |
| ) |
const |
|
inline |
◆ GetSampleTime() [1/2]
G4double BesEmcWaveform::GetSampleTime |
( |
| ) |
const |
|
inline |
◆ GetSampleTime() [2/2]
G4double BesEmcWaveform::GetSampleTime |
( |
| ) |
const |
|
inline |
◆ GetTau() [1/2]
G4double BesEmcWaveform::GetTau |
( |
| ) |
const |
|
inline |
◆ GetTau() [2/2]
G4double BesEmcWaveform::GetTau |
( |
| ) |
const |
|
inline |
◆ GetTimeOffset() [1/2]
G4double BesEmcWaveform::GetTimeOffset |
( |
| ) |
const |
|
inline |
◆ GetTimeOffset() [2/2]
G4double BesEmcWaveform::GetTimeOffset |
( |
| ) |
const |
|
inline |
◆ GetWave() [1/2]
G4double * BesEmcWaveform::GetWave |
( |
| ) |
const |
|
inline |
◆ GetWave() [2/2]
G4double * BesEmcWaveform::GetWave |
( |
| ) |
const |
|
inline |
◆ length() [1/2]
G4long BesEmcWaveform::length |
( |
| ) |
const |
|
inline |
◆ length() [2/2]
G4long BesEmcWaveform::length |
( |
| ) |
const |
|
inline |
◆ makeWaveform() [1/2]
void BesEmcWaveform::makeWaveform |
( |
G4double |
energy, |
|
|
G4double |
time |
|
) |
| |
Definition at line 128 of file BesEmcWaveform.cc.
129{
130 G4double amplitude;
131 if(m_photonsPerMeV==0)
132 {
134 }
135 else
136 {
137 G4double photons =
energy*m_photonsPerMeV;
138 if(photons>0) {
139 G4double photonStatFactor = RandGauss::shoot(photons, sqrt(photons))/photons;
140 amplitude =
energy*photonStatFactor;
141 } else {
142 amplitude = 0;
143 }
144 }
145
146 G4double tempTime;
147 tempTime = 0;
148
149 G4double peak = m_peakTime*m_peakTime*m_peakTime*m_peakTime*
exp(-m_peakTime/m_tau)/24;
150
152 {
153 tempTime = i*m_sampleTime + m_timeOffset -
time;
154 if(tempTime>0)
155 emcWave[i] += amplitude*tempTime*tempTime*tempTime*tempTime*
exp(-tempTime/m_tau)/(24*peak);
156 }
157}
EvtComplex exp(const EvtComplex &c)
Referenced by updateWaveform().
◆ makeWaveform() [2/2]
void BesEmcWaveform::makeWaveform |
( |
G4double |
energy, |
|
|
G4double |
time |
|
) |
| |
◆ max() [1/2]
G4double BesEmcWaveform::max |
( |
G4long & |
binOfMax | ) |
const |
◆ max() [2/2]
G4double BesEmcWaveform::max |
( |
G4long & |
binOfMax | ) |
const |
◆ operator*=() [1/2]
◆ operator*=() [2/2]
virtual BesEmcWaveform & BesEmcWaveform::operator*= |
( |
const G4double & |
| ) |
|
|
virtual |
◆ operator+=() [1/2]
◆ operator+=() [2/2]
◆ operator/=() [1/2]
◆ operator/=() [2/2]
virtual BesEmcWaveform & BesEmcWaveform::operator/= |
( |
const G4double & |
| ) |
|
|
virtual |
◆ operator=() [1/2]
Definition at line 86 of file BesEmcWaveform.cc.
87{
88 if (this != &assign) {
93 }
94 return *this;
95}
◆ operator=() [2/2]
◆ operator[]() [1/2]
G4double & BesEmcWaveform::operator[] |
( |
G4long |
index | ) |
const |
|
inline |
◆ operator[]() [2/2]
G4double & BesEmcWaveform::operator[] |
( |
G4long |
| ) |
const |
|
inline |
◆ print() [1/2]
void BesEmcWaveform::print |
( |
| ) |
|
Definition at line 188 of file BesEmcWaveform.cc.
189{
190 G4cout<<"New Wave!"<<G4endl;
193 G4cout<<G4endl;
194}
◆ print() [2/2]
void BesEmcWaveform::print |
( |
| ) |
|
◆ updateWaveform() [1/4]
void BesEmcWaveform::updateWaveform |
( |
BesEmcDigi * |
digi | ) |
|
◆ updateWaveform() [2/4]
void BesEmcWaveform::updateWaveform |
( |
BesEmcDigi * |
| ) |
|
◆ updateWaveform() [3/4]
void BesEmcWaveform::updateWaveform |
( |
BesEmcHit * |
hit | ) |
|
◆ updateWaveform() [4/4]
void BesEmcWaveform::updateWaveform |
( |
BesEmcHit * |
| ) |
|
◆ array_size
G4long BesEmcWaveform::array_size |
|
protected |
Definition at line 88 of file InstallArea/include/EmcSim/EmcSim/BesEmcWaveform.hh.
Referenced by addElecNoise(), BesEmcWaveform(), digitize(), length(), makeWaveform(), max(), operator*=(), operator+=(), operator/=(), operator=(), operator[](), and print().
◆ emcWave
G4double * BesEmcWaveform::emcWave |
|
protected |
Definition at line 87 of file InstallArea/include/EmcSim/EmcSim/BesEmcWaveform.hh.
Referenced by addElecNoise(), BesEmcWaveform(), digitize(), GetWave(), makeWaveform(), max(), operator*=(), operator+=(), operator/=(), operator=(), operator[](), print(), and ~BesEmcWaveform().
The documentation for this class was generated from the following files: