78 double ampl=0;
int maxI = -1;
double maxA = -1e10;
float ta=0;
80 for (
int i=ifirst;
i<tool.
size() &&
i<
n+ifirst;
i++) {
81 int capid=digi[
i].capid();
94 if(maxI==0 || maxI==(tool.
size()-1)) {
95 LogDebug(
"HCAL Pulse") <<
"HcalSimpleRecAlgo::reconstruct :"
96 <<
" Invalid max amplitude position, "
97 <<
" max Amplitude: "<< maxI
99 <<
" last: "<<(tool.
size()-1)
102 int capid=digi[maxI-1].capid();
104 capid=digi[maxI+1].capid();
109 if (maxA<minA) minA=maxA;
110 if (t2<minA) minA=t2;
111 if (minA<0) { maxA-=minA; t0-=minA; t2-=minA; }
113 float wpksamp = (t0 + maxA + t2);
114 if (wpksamp!=0) wpksamp=(maxA + 2.0*t2) / wpksamp;
116 if (corr!=0 && pulseCorrect ) {
146 int ieta = cell.
ieta();
147 int iphi = cell.iphi();
148 ampl *=
eCorr(ieta,iphi,ampl);
157 return RecHit(digi.id(),ampl,
time);
double respcorrgain(int fCapId) const
get response corrected gain for capid=0..3
double getCorrection(double fc_ampl) const
double pedestal(int fCapId) const
get pedestal for capid=0..3
const T & max(const T &a, const T &b)
int ieta() const
get the cell ieta
static float leakCorr(double energy)
Leak correction.
static float timeshift_ns_hbheho(float wpksamp)
static float eCorr(int ieta, int iphi, double ampl)
Ugly hack to apply energy corrections to some HB- cells.
int size() const
get the size
double timecorr() const
get time correction factor
virtual void adc2fC(const HBHEDataFrame &df, CaloSamples &lf) const =0
static double delay(double fC, BiasSetting bias=Medium)
Returns the amount (ns) by which a pulse of the given number of fC will be delayed by the timeslew ef...