CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_0/src/CalibCalorimetry/CastorCalib/interface/CastorPulseShapes.h

Go to the documentation of this file.
00001 #ifndef CALIBCALORIMETRY_CASTORALGOS_CASTORPULSESHAPES_H
00002 #define CALIBCALORIMETRY_CASTORALGOS_CASTORPULSESHAPES_H 1
00003 
00004 #include <vector>
00005 
00010 class CastorPulseShapes {
00011 public:
00012   CastorPulseShapes();
00013 
00014   class Shape {
00015   public:
00016     Shape();
00017     void setNBin(int n);
00018     void setShapeBin(int i, float f);
00019     float getTpeak() const { return tpeak_; }
00020     float operator()(double time) const;
00021     float at(double time) const;
00022     float integrate(double tmin, double tmax) const;
00023   private:
00024     std::vector<float> shape_;
00025     int nbin_;
00026     float tpeak_;
00027   };
00028 
00029   const Shape& castorShape() const { return castorShape_; }
00030 
00031 private:
00032   Shape castorShape_;
00033   void computeCastorShape(Shape& s);
00034 };
00035 #endif