1 #ifndef ALIDALITZELECTRONCUTS_H
2 #define ALIDALITZELECTRONCUTS_H
4 // Class handling all kinds of selection cuts for electrons
6 // Authors: Svein Lindal, Daniel Lohner *
9 #include "AliAODpidUtil.h"
10 //#include "AliConversionPhotonBase.h"
11 //#include "AliAODConversionMother.h"
12 #include "AliAODTrack.h"
13 #include "AliESDtrack.h"
14 #include "AliVTrack.h"
15 #include "AliAODTrack.h"
17 #include "AliAnalysisCuts.h"
18 #include "AliESDtrackCuts.h"
23 class AliConversionPhotonBase;
29 class AliAnalysisCuts;
32 class AliAnalysisManager;
37 class AliDalitzElectronCuts : public AliAnalysisCuts {
47 kpiMinMomdedxSigmaTPCCut,
48 kpiMaxMomdedxSigmaTPCCut,
49 kLowPRejectionSigmaCut,
55 kRejectSharedElecGamma,
74 Bool_t SetCutIds(TString cutString);
76 Bool_t SetCut(cutIds cutID, Int_t cut);
77 Bool_t UpdateCutString(cutIds cutID, Int_t value);
78 static const char * fgkCutNames[kNCuts];
81 Bool_t InitializeCutsFromCutString(const TString analysisCutSelection);
84 AliDalitzElectronCuts(const char *name="ElectronCuts", const char * title="Electron Cuts");
85 virtual ~AliDalitzElectronCuts(); //virtual destructor
87 virtual Bool_t IsSelected(TObject* /*obj*/){return kTRUE;}
88 virtual Bool_t IsSelected(TList* /*list*/) {return kTRUE;}
90 TString GetCutNumber();
93 Bool_t ElectronIsSelectedMC(Int_t labelParticle,AliStack *fMCStack);
94 Bool_t TrackIsSelected(AliESDtrack* lTrack);
95 Bool_t ElectronIsSelected(AliESDtrack* lTrack);
96 void InitAODpidUtil(Int_t type);
97 static AliDalitzElectronCuts * GetStandardCuts2010PbPb();
98 static AliDalitzElectronCuts * GetStandardCuts2010pp();
99 Bool_t InitPIDResponse();
101 void SetPIDResponse(AliPIDResponse * pidResponse) {fPIDResponse = pidResponse;}
102 AliPIDResponse * GetPIDResponse() { return fPIDResponse;}
106 void InitCutHistograms(TString name="",Bool_t preCut = kTRUE,TString cutName="");
107 void SetFillCutHistograms(TString name="",Bool_t preCut = kTRUE,TString cutName=""){if(!fHistograms){InitCutHistograms(name,preCut,cutName);};}
108 TList *GetCutHistograms(){return fHistograms;}
110 static AliVTrack * GetTrack(AliVEvent * event, Int_t label);
115 Bool_t dEdxCuts(AliVTrack * track);
116 Bool_t PIDProbabilityCut(AliConversionPhotonBase *photon, AliVEvent * event);
117 Bool_t RejectSharedElecGamma(TList *photons, Int_t indexEle);
118 Bool_t IsFromGammaConversion( Double_t psiPair, Double_t deltaPhi );
122 //Double_t GetPsiPair( const AliESDtrack *trackPos, const AliESDtrack *trackNeg );
124 Bool_t SetTPCdEdxCutPionLine(Int_t pidedxSigmaCut);
125 Bool_t SetTPCdEdxCutElectronLine(Int_t ededxSigmaCut);
126 Bool_t SetITSdEdxCutElectronLine(Int_t ededxSigmaCut);
127 Bool_t SetMinMomPiondEdxTPCCut(Int_t piMomdedxSigmaCut);
128 Bool_t SetMaxMomPiondEdxTPCCut(Int_t piMomdedxSigmaCut);
129 Bool_t SetITSClusterCut(Int_t clsITSCut);
130 Bool_t SetTPCClusterCut(Int_t clsTPCCut);
131 Bool_t SetEtaCut(Int_t etaCut);
132 Bool_t SetPtCut(Int_t ptCut);
133 Bool_t SetDCACut(Int_t dcaCut);
134 void SetEtaShift(Double_t etaShift){fEtaShift = etaShift;}
135 Bool_t SetMinMomPiondEdxCut(Int_t piMinMomdedxSigmaCut);
136 Bool_t SetMaxMomPiondEdxCut(Int_t piMaxMomdedxSigmaCut);
137 Bool_t SetLowPRejectionCuts(Int_t LowPRejectionSigmaCut);
138 Bool_t SetTOFElectronPIDCut(Int_t TOFelectronPID);
139 Bool_t SetPsiPairCut(Int_t psiCut);
140 Bool_t SetRejectSharedElecGamma(Int_t RCut);
141 Bool_t SetBackgroundScheme(Int_t BackgroundScheme);
142 Bool_t SetNumberOfRotations(Int_t NumberOfRotations);
143 Bool_t SetMassCut(Int_t massCut);
147 Double_t GetEtaCut(){ return fEtaCut;}
148 Double_t GetPsiPairCut(){ return fPsiPairCut; }
149 Double_t DoRejectSharedElecGamma(){ return fDoRejectSharedElecGamma;}
150 Double_t DoPsiPairCut(){return fDoPsiPairCut;}
151 Bool_t UseTrackMultiplicity(){ return fUseTrackMultiplicityForBG;}
152 Int_t GetBKGMethod(){ return fBKGMethod; }
153 Int_t NumberOfRotationEvents(){return fnumberOfRotationEventsForBG;}
154 Bool_t DoMassCut(){return fDoMassCut;}
155 Double_t GetMassCut(){return fMassCut;}
162 AliPIDResponse *fPIDResponse;
163 AliESDtrackCuts *fesdTrackCuts;
165 Double_t fEtaCut; //eta cutç
169 Double_t fRadiusCut; // radius cut
170 Double_t fPsiPairCut;
171 Double_t fDeltaPhiCutMin;
172 Double_t fDeltaPhiCutMax;
173 Double_t fMinClsTPC; // minimum clusters in the TPC
174 Double_t fMinClsTPCToF; // minimum clusters to findable clusters
175 Bool_t fDodEdxSigmaITSCut; // flag to use the dEdxCut ITS based on sigmas
176 Bool_t fDodEdxSigmaTPCCut; // flag to use the dEdxCut TPC based on sigmas
177 Bool_t fDoTOFsigmaCut; // flag to use TOF pid cut RRnewTOF
178 Bool_t fDoRejectSharedElecGamma; //Reject electrons from the gammas with Radius < RadiusCut
179 Bool_t fDoPsiPairCut; // PsiPair Cut
180 Double_t fPIDnSigmaAboveElectronLineITS; // sigma cut
181 Double_t fPIDnSigmaBelowElectronLineITS; // sigma cut
182 Double_t fPIDnSigmaAboveElectronLineTPC; // sigma cut
183 Double_t fPIDnSigmaBelowElectronLineTPC; // sigma cut
184 Double_t fPIDnSigmaAbovePionLineTPC;
185 Double_t fPIDnSigmaAbovePionLineTPCHighPt;
186 Double_t fTofPIDnSigmaAboveElectronLine; // sigma cut RRnewTOF
187 Double_t fTofPIDnSigmaBelowElectronLine; // sigma cut RRnewTOF
188 Double_t fPIDMinPnSigmaAbovePionLineTPC; // sigma cut
189 Double_t fPIDMaxPnSigmaAbovePionLineTPC; // sigma cut
190 Double_t fDoKaonRejectionLowP; // Kaon rejection at low p
191 Double_t fDoProtonRejectionLowP; // Proton rejection at low p
192 Double_t fDoPionRejectionLowP; // Pion rejection at low p
193 Double_t fPIDnSigmaAtLowPAroundKaonLine; // sigma cut
194 Double_t fPIDnSigmaAtLowPAroundProtonLine; // sigma cut
195 Double_t fPIDnSigmaAtLowPAroundPionLine; // sigma cut
196 Double_t fPIDMinPKaonRejectionLowP; // Momentum limit to apply kaon rejection
197 Double_t fPIDMinPProtonRejectionLowP; // Momentum limit to apply proton rejection
198 Double_t fPIDMinPPionRejectionLowP; // Momentum limit to apply proton rejection
200 Bool_t fUseCorrectedTPCClsInfo; // flag to use corrected tpc cl info
201 Bool_t fUseTOFpid; // flag to use tof pid
202 Bool_t fRequireTOF; //flg to analyze only tracks with TOF signal
203 Bool_t fUseTrackMultiplicityForBG; // use multiplicity
205 Int_t fnumberOfRotationEventsForBG;
211 TObjString *fCutString; // cut number used for analysis
212 TH1F *hCutIndex; // bookkeeping for cuts
213 TH1F *hdEdxCuts; // bookkeeping for dEdx cuts
214 TH2F *hITSdEdxbefore; // ITS dEdx before cuts
216 TH2F *hTPCdEdxbefore; // TPC dEdx before cuts
217 TH2F *hTPCdEdxafter; // TPC dEdx after cuts
218 TH2F *hTPCdEdxSignalbefore; //TPC dEdx signal before
219 TH2F *hTPCdEdxSignalafter; //TPC dEdx signal after
220 TH2F *hTOFbefore; // TOF after cuts
221 TH2F *hTOFafter; // TOF after cuts
222 TH1F *hTrackDCAxybefore;
223 TH1F *hTrackDCAxyafter;
224 TH1F *hTrackDCAzbefore;
225 TH1F *hTrackDCAzafter;
231 AliDalitzElectronCuts(const AliDalitzElectronCuts&); // not implemented
232 AliDalitzElectronCuts& operator=(const AliDalitzElectronCuts&); // not implemented
235 ClassDef(AliDalitzElectronCuts,2)
239 inline void AliDalitzElectronCuts::InitAODpidUtil(Int_t type) {
240 if (!fPIDResponse) fPIDResponse = new AliAODpidUtil();
241 Double_t alephParameters[5];
243 alephParameters[0] = 2.15898e+00/50.;
244 alephParameters[1] = 1.75295e+01;
245 alephParameters[2] = 3.40030e-09;
246 alephParameters[3] = 1.96178e+00;
247 alephParameters[4] = 3.91720e+00;
248 fPIDResponse->GetTOFResponse().SetTimeResolution(80.);
252 alephParameters[0] = 0.0283086/0.97;
253 alephParameters[1] = 2.63394e+01;
254 alephParameters[2] = 5.04114e-11;
255 alephParameters[3] = 2.12543e+00;
256 alephParameters[4] = 4.88663e+00;
257 fPIDResponse->GetTOFResponse().SetTimeResolution(130.);
258 fPIDResponse->GetTPCResponse().SetMip(50.);
261 fPIDResponse->GetTPCResponse().SetBetheBlochParameters(
262 alephParameters[0],alephParameters[1],alephParameters[2],
263 alephParameters[3],alephParameters[4]);
265 fPIDResponse->GetTPCResponse().SetSigma(3.79301e-03, 2.21280e+04);