00001
00002
00004 #ifndef __TriggerSelect__
00005 #define __TriggerSelect__
00006
00007 #include "ReadTriggers.h"
00008 #include "TH1.h"
00009 #include "TH2.h"
00010
00011 using namespace std;
00012
00018 class TriggerSelect{
00019
00020 public:
00021
00035 TriggerSelect(const int aVerbose=0);
00036
00043 TriggerSelect(ReadTriggers *aTriggers, const int aVerbose=0);
00044
00048 virtual ~TriggerSelect(void);
00056 void ResetSelection(void);
00057
00064 void SetTimeSelection(const int aResolution, const double aMin, const double aMax);
00065
00070 void SetTimeResolution(const int aResolution);
00071
00076 void SetTimeMin(const double aMin);
00077
00082 void SetTimeMax(const double aMax);
00083
00089 void SetTimeRange(const double aMin, const double aMax);
00090
00097 void SetFrequencySelection(const int aResolution, const double aMin, const double aMax);
00098
00103 void SetFrequencyResolution(const int aResolution);
00104
00109 void SetFrequencyMin(const double aMin);
00110
00115 void SetFrequencyMax(const double aMax);
00116
00122 void SetFrequencyRange(const double aMin, const double aMax);
00123
00130 void SetQSelection(const int aResolution, const double aMin, const double aMax);
00131
00136 void SetQResolution(const int aResolution);
00137
00142 void SetQMin(const double aMin);
00143
00148 void SetQMax(const double aMax);
00149
00155 void SetQRange(const double aMin, const double aMax);
00156
00163 void SetSNRSelection(const int aResolution, const double aMin, const double aMax);
00164
00169 void SetSNRResolution(const int aResolution);
00170
00175 void SetSNRMin(const double aMin);
00176
00181 void SetSNRMax(const double aMax);
00182
00188 void SetSNRRange(const double aMin, const double aMax);
00189
00190
00194 inline double GetTimeMin(void){ return tmin; };
00195
00199 inline double GetTimeMax(void){ return tmax; };
00200
00204 inline double GetTimeRange(void){ return tmax-tmin; };
00205
00209 inline int GetTimeResolution(void){ return ntbins; };
00210
00214 inline double GetFrequencyMin(void){ return fmin; };
00215
00219 inline double GetFrequencyMax(void){ return fmax; };
00220
00224 inline double GetFrequencyRange(void){ return fmax-fmin; };
00225
00229 inline int GetFrequencyResolution(void){ return nfbins; };
00230
00234 inline double GetQMin(void){ return qmin; };
00235
00239 inline double GetQMax(void){ return qmax; };
00240
00244 inline double GetQRange(void){ return qmax-qmin; };
00245
00249 inline int GetQResolution(void){ return nqbins; };
00250
00254 inline double GetSNRMin(void){ return smin; };
00255
00259 inline double GetSNRMax(void){ return smax; };
00260
00264 inline double GetSNRRange(void){ return smax-smin; };
00265
00269 inline int GetSNRResolution(void){ return nsbins; };
00270
00271
00279 TH1D* GetTH1D(const string aParameter);
00280
00289 TH2D* GetTH2D(const string aParameterX, const string aParameterY);
00290
00294 void PrintSelection(void);
00295
00296 private:
00297
00298 int Verbose;
00299
00300
00301 void MakeTbins(void);
00302 double tmin, tmin_0;
00303 double tmax, tmax_0;
00304 int ntbins, ntbins_0;
00305 double *tbins;
00306
00307
00308 void MakeFbins(void);
00309 double fmin, fmin_0;
00310 double fmax, fmax_0;
00311 int nfbins, nfbins_0;
00312 double *fbins;
00313
00314
00315 void MakeQbins(void);
00316 double qmin, qmin_0;
00317 double qmax, qmax_0;
00318 int nqbins, nqbins_0;
00319 double *qbins;
00320
00321
00322 void MakeSbins(void);
00323 double smin, smin_0;
00324 double smax, smax_0;
00325 int nsbins, nsbins_0;
00326 double *sbins;
00327
00328 ClassDef(TriggerSelect,0)
00329 };
00330
00331 #endif
00332
00333