//# #
//#############################################################
+#include <TBits.h>
+
#include <AliPID.h>
#include <AliAnalysisCuts.h>
#include <AliTRDPIDResponse.h>
class TList;
class AliVTrack;
class TGraph;
-class TH2D;
-class TH3D;
+class THnBase;
class AliPIDResponse;
class AliDielectronVarManager;
class AliDielectronVarCuts;
void AddCut(DetType det, AliPID::EParticleType type, Double_t nSigmaLow, Double_t nSigmaUp, Double_t min, Double_t max, Bool_t exclude, UInt_t pidBitType, TF1 * const funSigma);
void AddCut(DetType det, AliPID::EParticleType type, Double_t nSigmaLow, Double_t nSigmaUp,
AliDielectronVarCuts *varcuts, Bool_t exclude=kFALSE, UInt_t pidBitType=AliDielectronPID::kRequire );
- void AddCut(DetType det, AliPID::EParticleType type, TH3D * const histLow, Double_t nSigmaUp,
- Double_t min=0, Double_t max=0, Bool_t exclude=kFALSE, UInt_t pidBitType=AliDielectronPID::kRequire,
- Int_t var=-1);
- void AddCut(DetType det, AliPID::EParticleType type, TH3D * const histLow, TH3D * const histUp,
- Double_t min=0, Double_t max=0, Bool_t exclude=kFALSE, UInt_t pidBitType=AliDielectronPID::kRequire,
- Int_t var=-1);
-
+
+ void AddCut(DetType det, AliPID::EParticleType type, THnBase * const histLow, Double_t nSigmaUp,
+ Double_t min=0, Double_t max=0, Bool_t exclude=kFALSE,
+ UInt_t pidBitType=AliDielectronPID::kRequire, Int_t var=-1);
+
void SetDefaults(Int_t def);
+ Int_t GetNCuts() { return fNcuts;}
//
//Analysis cuts interface
//const
static TGraph *GetCorrGraphdEdx() { return fgdEdxRunCorr; }
static void SetEtaCorrFunction(TF1 *fun) {fgFunEtaCorr=fun;}
- static void SetCentroidCorrFunction(TF1 *fun, UInt_t varx, UInt_t vary=0, UInt_t varz=0);
- static void SetWidthCorrFunction(TF1 *fun, UInt_t varx, UInt_t vary=0, UInt_t varz=0);
+ static void SetCentroidCorrFunction(TH1 *fun) { fgFunCntrdCorr=fun; }
+ static void SetWidthCorrFunction(TH1 *fun) { fgFunWdthCorr=fun; }
static TF1* GetEtaCorrFunction() { return fgFunEtaCorr; }
- static TF1* GetCentroidCorrFunction() { return fgFunCntrdCorr; }
- static TF1* GetWidthCorrFunction() { return fgFunWdthCorr; }
static Double_t GetEtaCorr(const AliVTrack *track);
static Double_t GetCntrdCorr(const AliVTrack *track) { return (fgFunCntrdCorr ? GetPIDCorr(track,fgFunCntrdCorr) : 0.0); }
static Double_t GetWdthCorr(const AliVTrack *track) { return (fgFunWdthCorr ? GetPIDCorr(track,fgFunWdthCorr) : 1.0); }
- void SetElectronNsigmaCentroidMap(TH2D * const centEtaMap) {fElectronCentroidCentEta = centEtaMap;}
- void SetElectronNsigmaWidthMap(TH2D * const centEtaMap) {fElectronWidthCentEta = centEtaMap;}
-
private:
enum {kNmaxPID=30};
+ TBits *fUsedVars; // list of used variables
DetType fDetType[kNmaxPID]; //detector type of nsigma cut
AliPID::EParticleType fPartType[kNmaxPID]; //particle type
Float_t fNsigmaLow[kNmaxPID]; //lower nsigma bound
static Double_t fgCorrdEdx; //!dEdx correction value for current run. Set if fgFitCorr is set and SetCorrVal(run)
// was called
static TF1 *fgFunEtaCorr; //function for eta correction of electron sigma
- static TF1 *fgFunCntrdCorr; //function for correction of electron sigma (centroid)
- static TF1 *fgFunWdthCorr; //function for correction of electron sigma (width)
+ static TH1 *fgFunCntrdCorr; //function for correction of electron sigma (centroid)
+ static TH1 *fgFunWdthCorr; //function for correction of electron sigma (width)
static TGraph *fgdEdxRunCorr; //run by run correction for dEdx
- static Double_t GetPIDCorr(const AliVTrack *track, TF1 *fun);
-
- TH2D* fElectronCentroidCentEta; //centrality-eta dependence of the electron centroids
- TH2D* fElectronWidthCentEta; //centrality-eta dependence of the electron widths
- TH3D* fHistElectronCutLow[kNmaxPID]; //centrality-eta-pin map for the electron lower cut in units of n-sigma widths centered to zero
- TH3D* fHistElectronCutUp[kNmaxPID]; //centrality-eta-pin map for the electron lower cut in units of n-sigma widths centered to zero
-
+ static Double_t GetPIDCorr(const AliVTrack *track, TH1 *hist);
+
+ THnBase* fMapElectronCutLow[kNmaxPID]; //map for the electron lower cut in units of n-sigma widths 1 centered to zero
Bool_t IsSelectedITS(AliVTrack * const part, Int_t icut);
- Bool_t IsSelectedTPC(AliVTrack * const part, Int_t icut);
+ Bool_t IsSelectedTPC(AliVTrack * const part, Int_t icut, Double_t *values);
Bool_t IsSelectedTRD(AliVTrack * const part, Int_t icut);
Bool_t IsSelectedTRDeleEff(AliVTrack * const part, Int_t icut, AliTRDPIDResponse::ETRDPIDMethod PIDmethod=AliTRDPIDResponse::kLQ1D);
Bool_t IsSelectedTOF(AliVTrack * const part, Int_t icut);
AliDielectronPID(const AliDielectronPID &c);
AliDielectronPID &operator=(const AliDielectronPID &c);
- ClassDef(AliDielectronPID,5) // Dielectron PID
+ ClassDef(AliDielectronPID,7) // Dielectron PID
};
#endif