|
||||
File indexing completed on 2024-09-07 04:37:38
0001 #ifndef CSCRecHitD_CSCFindPeakTime_h 0002 #define CSCRecHitD_CSCFindPeakTime_h 0003 /** This is CSCFindPeakTime 0004 * 0005 * Used to provide improved estimate of SCA peak time. 0006 * 0007 */ 0008 0009 #include "FWCore/ParameterSet/interface/ParameterSet.h" 0010 #include <vector> 0011 0012 class CSCFindPeakTime { 0013 public: 0014 explicit CSCFindPeakTime(const edm::ParameterSet& ps); 0015 0016 ~CSCFindPeakTime() {} 0017 0018 /// Basic result of this class 0019 float peakTime(int tmax, const float* adc, float t_peak); 0020 0021 /// Weighted average of time bins 0022 float averageTime(int tmax, const float* adc); 0023 0024 /// Parabolic fit to three time bins centered on maximum 0025 float parabolaFitTime(int tmax, const float* adc); 0026 0027 /** 0028 * Based on RecoLocalMuon/CSCStandAlone/interface/PulseTime.h by S. Durkin, 0029 * and ported by D. Fortin. Comments updated by Tim Cox Apr 2009. 0030 * 0031 * The SCA pulse shape should be representable by a function <BR> 0032 * N*(p0^2/256/exp(-4)) * (t-t0)^4 * exp( -p0*(t-t0) ) 0033 * 0034 * Rather than do a full fit with varying peak time too, assume the 0035 * peak time is fixed to 133 nsec w.r.t. start time, t0, and fit for t0. 0036 * The fit uses a binary search in t0, and at each step calculates the overall normalization factor 0037 * between the function and the SCA pulse height as a least-squares fit over the 4 time bins 0038 * tmax -1, tmax, tmax+1, tmax+2 0039 * 0040 * Note: t0peak =4/p0 = 133 nsec, and adc[0] is arbitrarily defined a time of 0.0 nsec. 0041 * 0042 */ 0043 float fivePoleFitTime(int tmax, const float* adc, float t_peak); 0044 0045 /** 0046 * Integrated charge after fivePoleFitTime 0047 */ 0048 //@@ Needs work and interface fixes!! 0049 void fivePoleFitCharge( 0050 int tmax, const float* adc, const float& t_zero, const float& t_peak, std::vector<float>& adcsFit); 0051 0052 private: 0053 bool useAverageTime; 0054 bool useParabolaFit; 0055 bool useFivePoleFit; 0056 }; 0057 0058 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.2.1 LXR engine. The LXR team |