PandaRoot
PndMvdCalcTot.h
Go to the documentation of this file.
1 #ifndef PNDMVDCALCTOT_H
2 #define PNDMVDCALCTOT_H
3 
4 #include "FairLogger.h"
5 #include "TObject.h"
6 #include "TString.h"
7 #include "TRandom.h"
8 #include <iostream>
9 #include <iomanip>
10 
12 
33  public:
36  {
37  ftr = 100.;
38  fa = 60.;
39  fthreshold = 3000;
40  fclockfrequency = 50.;
41  ftimestep = 1. / fclockfrequency * 1000.;
43  LOG(info) << " <PndMvdCalcTot::PndMvdCalcTot()>: default constructor used!";
44  };
45 
47  PndMvdCalcTot(Double_t tr, Double_t a, Double_t threshold, Double_t clockfrequency)
48  {
49  ftr = tr;
50  fa = a;
51  fthreshold = threshold;
52  fclockfrequency = clockfrequency;
53  ftimestep = 1. / fclockfrequency * 1000.;
55  };
56 
59 
60  void SetStartOffset();
61 
62  Double_t GetTot(Double_t fcharge);
63  void SetParameter(Double_t tr, Double_t a, Double_t threshold);
64  Double_t GetPileUpTime(Double_t fcharge); // returns the time the capacitor is loaded and therefore the time the hit MVD is blind for other events
65 
66  private:
67  Double_t fthreshold; // in electrons
68  Double_t ftr; // raising time [ns]
69  Double_t fa; // falling ration [e/ns]
70  Double_t Q, Qt; // max charge, threshold charge
71  Double_t t1e, t2e; // exact time point when signal is over threshold/under threshold again
72  Double_t fclockfrequency; // the frequency the readout chip works with
73  Double_t ftimestep; // one time step of the clock
74  Double_t fstarttime; // absolute point when TOT begins
75  Double_t fstoptime; // absolute point when TOT ends
76  Double_t ftimeoffset; // difference between rising clock edge and when detector gets hit
77 
78  Double_t GetTotWC(); // assumes a clock which results in a quantized TOT
79 
80 };
81 
82 #endif /*MVDCALCTOT_H*/
PndMvdCalcTot(Double_t tr, Double_t a, Double_t threshold, Double_t clockfrequency)
Main constructor.
Definition: PndMvdCalcTot.h:47
Double_t GetPileUpTime(Double_t fcharge)
Double_t GetTot(Double_t fcharge)
void SetParameter(Double_t tr, Double_t a, Double_t threshold)
~PndMvdCalcTot()
Destructor.
Definition: PndMvdCalcTot.h:58
void SetStartOffset()
PndMvdCalcTot()
Default constructor.
Definition: PndMvdCalcTot.h:35
Class to calculate the time over threshold.
Definition: PndMvdCalcTot.h:32