#ifndef __HPARTICLECUTRANGE_H__ #define __HPARTICLECUTRANGE_H__ #include "TString.h" #include "TNamed.h" #include "TCutG.h" #include class HParticleCutRange : public TNamed { private: UInt_t fmaxCut; // how many version can be used at max public : Double_t flow; // lower cut Double_t fup ; // upper cut Int_t fCutNumber; // a unique cut number to handle this cut std::vectorfctFail; // count evaluation == kFALSE std::vectorfctCall; // count all call to the evaluation UInt_t fmaxVersion; // how many version have been used TCutG* fCut; // graph cut object Bool_t fbInverseCut; // default kFALSE , kTRUE will invert selection HParticleCutRange(TString name, Int_t num,Double_t l=-1e30,Double_t u=1e30); ~HParticleCutRange(); void setMaxCut(UInt_t max=4); void setInverse(Bool_t inv) { fbInverseCut = inv;} void set(Double_t l=-1e30,Double_t u=1e30) { flow = l; fup = u; } Bool_t eval(Double_t var,UInt_t version = 0); Bool_t evalG(Double_t var,Double_t var2,UInt_t version = 0); void print(); void resetCounter(); Float_t getCutRate(UInt_t version=0); UInt_t getNCall(UInt_t version=0); UInt_t getNFail(UInt_t version=0); ClassDef(HParticleCutRange,1) }; #endif