shaper for HF More...
#include <HFShape.h>
Public Member Functions | |
HFShape () | |
HFShape (const HFShape &d) | |
virtual double | operator() (double time) const |
virtual double | timeToRise () const |
virtual | ~HFShape () |
Private Member Functions | |
void | computeShapeHF () |
Private Attributes | |
int | nbin_ |
std::vector< float > | nt_ |
HFShape::HFShape | ( | ) |
Definition at line 4 of file HFShape.cc.
References computeShapeHF().
: nbin_(256), nt_(nbin_, 0.) { computeShapeHF(); }
HFShape::HFShape | ( | const HFShape & | d | ) |
Definition at line 12 of file HFShape.cc.
: CaloVShape(d), nbin_(d.nbin_), nt_(d.nt_) { }
void HFShape::computeShapeHF | ( | ) | [private] |
Definition at line 25 of file HFShape.cc.
References funct::exp(), j, reco::ParticleMasses::k0, nbin_, lumiNorm::norm, nt_, p1, p2, and p4.
Referenced by HFShape().
{ // cout << endl << " ===== computeShapeHF !!! " << endl << endl; const float k0=0.7956; // shape parameters const float p2=1.355; const float p4=2.327; const float p1=4.3; // position parameter int j; float norm,r0,sigma0; // HF SHAPE norm = 0.0; for( j = 0; j < 25 && j < nbin_; j++){ r0 = j-p1; if (r0<0) sigma0 = p2; else sigma0 = p2*p4; r0 = r0/sigma0; if(r0 < k0) nt_[j] = exp(-0.5*r0*r0); else nt_[j] = exp(0.5*k0*k0-k0*r0); norm += nt_[j]; } // normalize pulse area to 1.0 for( j = 0; j < 25 && j < nbin_; j++){ nt_[j] /= norm; } }
double HFShape::operator() | ( | double | time | ) | const [virtual] |
Implements CaloVShape.
Definition at line 56 of file HFShape.cc.
double HFShape::timeToRise | ( | ) | const [virtual] |
int HFShape::nbin_ [private] |
Definition at line 32 of file HFShape.h.
Referenced by computeShapeHF(), and operator()().
std::vector<float> HFShape::nt_ [private] |
Definition at line 33 of file HFShape.h.
Referenced by computeShapeHF(), and operator()().