Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:29:27

0001 #include "SimCalorimetry/EcalSimAlgos/interface/ESShape.h"
0002 #include <cmath>
0003 
0004 ESShape::ESShape() {}
0005 
0006 double ESShape::operator()(double time_) const {
0007   if (time_ > 0.00001) {
0008     double wc = 0.07291;
0009     double n = 1.798;  // n-1 (in fact)
0010     double v1 = pow(wc / n * time_, n);
0011     double v2 = exp(n - wc * time_);
0012     double v = v1 * v2;
0013 
0014     return v;
0015   } else {
0016     return 0.0;
0017   }
0018 }
0019 
0020 double ESShape::timeToRise() const { return 0.0; }
0021 
0022 /*
0023 double ESShape::derivative (double time_) const
0024 {
0025   if (time_>0.00001) {
0026     double xf = A_*omegac_*time_;
0027     return (Qcf_/norm_)*pow(xf,M_-1.)*exp(-omegac_*time_);
0028   } 
0029   else {
0030     return 0.0;
0031   }
0032 }
0033 */