Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /epic-lfhcal-tbana/NewStructure/waveform_fitting/max_sample_fit_n_integ.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // Gets the magnitude simply from n samples surrounging the ADC_max subtracting equivalently the number of pedestals
0002 
0003 #pragma once
0004 
0005 #include "waveform_fit_base.h"
0006 
0007 #include <vector>
0008 
0009 class max_sample_fit_n_integ : public waveform_fit_base {
0010 public:
0011     max_sample_fit_n_integ();
0012     max_sample_fit_n_integ( int );
0013     ~max_sample_fit_n_integ();
0014 
0015     void fit()                              override;
0016     void fit_with_average_ped(double ped)   override;
0017     int get_pedestal()                      override;
0018     
0019     
0020 private:
0021     int max_sample;           // maximum sample nr
0022     double integ_nSample;     // integral of n sample
0023     double max_sample_value;  // The maximum sample value in the waveform
0024     double pedestal_value;    // The pedestal value, which is the average of the first 10 samples
0025     int nSample               = 3; // neighboring samples to be integrated, this should be uneven!! i.e. 3 or 5
0026 };