test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EcalShapeBase.h
Go to the documentation of this file.
1 #ifndef EcalSimAlgos_EcalShapeBase_h
2 #define EcalSimAlgos_EcalShapeBase_h
3 
4 #include<vector>
5 //#include<stdexcept>
7 
12 class EcalShapeBase : public CaloVShape
13 {
14  public:
15 
16  typedef std::vector<double> DVec ;
17 
18  EcalShapeBase( bool aSaveDerivative ) ;
19 
20  virtual ~EcalShapeBase() ;
21 
22  double operator() ( double aTime ) const ;
23 
24  double timeOfThr() const ;
25  double timeOfMax() const ;
26  virtual double timeToRise() const ;
27 
28  virtual double threshold() const = 0 ;
29 
30  double derivative ( double time ) const ; // appears to not be used anywhere
31 
32  enum { kReadoutTimeInterval = 25 , // in nsec
33  kNBinsPerNSec = 10 , // granularity of internal array
36  kNBinsStored = k1NSecBinsTotal*kNBinsPerNSec
37  } ;
38 
39  static const double qNSecPerBin ;
40 
41  protected:
42 
43  unsigned int timeIndex( double aTime ) const ;
44 
45  void buildMe() ;
46 
47  virtual void fillShape( DVec& aVec ) const = 0 ;
48 
49  private:
50 
53  unsigned int m_indexOfMax ;
54  double m_timeOfMax ;
57 };
58 
59 
60 
61 #endif
62 
DVec * m_derivPtr
Definition: EcalShapeBase.h:56
double operator()(double aTime) const
double derivative(double time) const
Electronic response of the preamp.
Definition: CaloVShape.h:11
static const double qNSecPerBin
Definition: EcalShapeBase.h:39
EcalShapeBase(bool aSaveDerivative)
virtual double threshold() const =0
std::vector< double > DVec
Definition: EcalShapeBase.h:16
unsigned int timeIndex(double aTime) const
double m_firstTimeOverThreshold
Definition: EcalShapeBase.h:52
virtual void fillShape(DVec &aVec) const =0
unsigned int m_indexOfMax
Definition: EcalShapeBase.h:53
double timeOfThr() const
double m_timeOfMax
Definition: EcalShapeBase.h:54
unsigned int m_firstIndexOverThreshold
Definition: EcalShapeBase.h:51
virtual ~EcalShapeBase()
virtual double timeToRise() const
double timeOfMax() const