AliPhysics  cc5d4fb (cc5d4fb)
Go to the documentation of this file.
4 #include "AliAODpidUtil.h"
7 #include "AliAODTrack.h"
8 #include "AliESDtrack.h"
9 #include "AliVTrack.h"
10 #include "AliAODTrack.h"
11 #include "AliMCEvent.h"
12 #include "AliAnalysisCuts.h"
13 #include "TH1F.h"
14 #include "TF1.h"
15 #include "TProfile.h"
16 #include "AliAnalysisUtils.h"
17 #include "AliAnalysisManager.h"
20 class AliESDEvent;
21 class AliAODEvent;
23 class AliPIDResponse;
24 class AliKFVertex;
25 class TH1F;
26 class TH2F;
27 class TF1;
28 class TProfile;
29 class AliAnalysisCuts;
30 class iostream;
31 class TList;
32 class AliAnalysisManager;
33 class AliAODMCParticle;
76 class AliConversionPhotonCuts : public AliAnalysisCuts {
78  public:
79  enum cutIds {
107  };
109  enum photonCuts {
120  };
123  Bool_t SetCutIds(TString cutString);
125  Bool_t SetCut(cutIds cutID, Int_t cut);
128  static const char * fgkCutNames[kNCuts];
130  Double_t GetCosineOfPointingAngle(const AliConversionPhotonBase * photon, AliVEvent * event) const;
131  Bool_t InitializeCutsFromCutString(const TString analysisCutSelection);
133  void SetPreSelectionCutFlag(Bool_t preSelFlag){fPreSelCut = preSelFlag;}
135  AliConversionPhotonCuts(const char *name="V0Cuts", const char * title="V0 Cuts");
139  virtual ~AliConversionPhotonCuts(); //virtual destructor
145  void SetPIDResponse(AliPIDResponse * pidResponse) {fPIDResponse = pidResponse;}
146  AliPIDResponse * GetPIDResponse() { return fPIDResponse;}
149  virtual Bool_t IsSelected(TObject* /*obj*/){return kTRUE;}
150  virtual Bool_t IsSelected(TList* /*list*/) {return kTRUE;}
154  Float_t GetKappaTPC(AliConversionPhotonBase *gamma, AliVEvent *event);
156  // Cut Selection
157  Bool_t PhotonIsSelected(AliConversionPhotonBase * photon, AliVEvent * event);
158  Bool_t PhotonIsSelectedMC(TParticle *particle,AliMCEvent *mcEvent,Bool_t checkForConvertedGamma=kTRUE);
159  Bool_t PhotonIsSelectedAODMC(AliAODMCParticle *particle,TClonesArray *aodmcArray,Bool_t checkForConvertedGamma=kTRUE);
160  //Bool_t ElectronIsSelectedMC(TParticle *particle,AliMCEvent *mcEvent);
161  Bool_t TracksAreSelected(AliVTrack * negTrack, AliVTrack * posTrack);
162  //Bool_t MesonIsSelected(AliAODConversionMother *pi0,Bool_t IsSignal=kTRUE);
163  //Bool_t MesonIsSelectedMC(TParticle *fMCMother,AliMCEvent *mcEvent, Bool_t bMCDaughtersInAcceptance=kFALSE);
165  void PrintCuts();
166  void PrintCutsWithValues();
168  void SetLightOutput( Bool_t flag ){fDoLightOutput = flag; return;}
169  void InitCutHistograms(TString name="",Bool_t preCut = kTRUE);
170  void SetFillCutHistograms(TString name="",Bool_t preCut = kTRUE){if(!fHistograms){InitCutHistograms(name,preCut);};}
172  void FillPhotonCutIndex(Int_t photoncut){if(fHistoCutIndex)fHistoCutIndex->Fill(photoncut);}
176  void SetV0ReaderName(TString name){fV0ReaderName = name; return;}
177  void SetProcessAODCheck(Bool_t flag){fProcessAODCheck = flag; return;}
179  AliVTrack * GetTrack(AliVEvent * event, Int_t label);
180  AliESDtrack *GetESDTrack(AliESDEvent * event, Int_t label);
183  Bool_t SpecificTrackCuts(AliAODTrack * negTrack, AliAODTrack * posTrack,Int_t &cutIndex);
184  Bool_t SpecificTrackCuts(AliESDtrack * negTrack, AliESDtrack * posTrack,Int_t &cutIndex);
186  Bool_t AcceptanceCut(TParticle *particle, TParticle * ePos,TParticle* eNeg);
188  // Bool_t dEdxCuts(AliVTrack * track);
189  Bool_t dEdxCuts(AliVTrack * track, AliConversionPhotonBase * photon);
190  Bool_t KappaCuts(AliConversionPhotonBase * photon,AliVEvent *event);
192  Bool_t AsymmetryCut(AliConversionPhotonBase *photon,AliVEvent *event);
193  Bool_t PIDProbabilityCut(AliConversionPhotonBase *photon, AliVEvent * event);
195  if(onfly == fUseOnFlyV0Finder) return kTRUE;
196  else return kFALSE;
197  }
198  Bool_t PhotonCuts(AliConversionPhotonBase *photon,AliVEvent *event);
199  Bool_t CorrectedTPCClusterCut(AliConversionPhotonBase *photon, AliVEvent * event);
200  Bool_t PsiPairCut(const AliConversionPhotonBase * photon) const;
201  Bool_t CosinePAngleCut(const AliConversionPhotonBase * photon, AliVEvent * event) const;
203  Bool_t RejectToCloseV0s(AliAODConversionPhoton* photon, TList *photons, Int_t nV0);
206  Bool_t InPlaneOutOfPlaneCut(Double_t photonPhi, Double_t eventPlaneAngle = -100, Bool_t fill = kTRUE);
209  // Set Individual Cuts
210  Bool_t SetRCut(Int_t RCut);
211  Bool_t SetV0Finder(Int_t v0FinderType);
212  Bool_t SetChi2GammaCut(Int_t chi2GammaCut);
213  Bool_t SetTPCdEdxCutPionLine(Int_t pidedxSigmaCut);
214  Bool_t SetTPCdEdxCutElectronLine(Int_t ededxSigmaCut);
215  Bool_t SetSinglePtCut(Int_t singlePtCut);
216  Bool_t SetTPCClusterCut(Int_t clsTPCCut);
217  Bool_t SetEtaCut(Int_t etaCut);
218  Bool_t SetEtaForPhiCut(Int_t etaPhiCut);
219  Bool_t SetMinPhiSectorCut(Int_t minPhiCut);
220  Bool_t SetMaxPhiSectorCut(Int_t maxPhiCut);
221  Bool_t SetMinMomPiondEdxCut(Int_t piMinMomdedxSigmaCut);
222  Bool_t SetMaxMomPiondEdxCut(Int_t piMaxMomdedxSigmaCut);
223  Bool_t SetLowPRejectionCuts(Int_t LowPRejectionSigmaCut);
224  Bool_t SetQtMaxCut(Int_t QtMaxCut);
225  Bool_t SetTOFElectronPIDCut(Int_t TOFelectronPID);
226  Bool_t SetTRDElectronCut(Int_t TRDElectronCut);
227  Bool_t SetPhotonAsymmetryCut(Int_t doPhotonAsymmetryCut);
228  Bool_t SetCosPAngleCut(Int_t cosCut);
229  Bool_t SetPsiPairCut(Int_t psiCut);
230  Bool_t SetSharedElectronCut(Int_t sharedElec);
231  Bool_t SetToCloseV0sCut(Int_t toClose);
232  Bool_t SetDCARPhotonPrimVtxCut(Int_t DCARPhotonPrimVtx);
233  Bool_t SetDCAZPhotonPrimVtxCut(Int_t DCAZPhotonPrimVtx);
234  Bool_t SetInPlaneOutOfPlane(Int_t inOutPlane);
235  Bool_t SetKappaTPCCut(Int_t kappaCut);
236  void SetIsHeavyIon(Int_t isHeavyIon){fIsHeavyIon=isHeavyIon;}
237  Int_t GetFirstTPCRow(Double_t radius);
239  Bool_t SetITSElectronPIDCut(Int_t ITSelectronPID);
240  Bool_t SetTRDElectronPIDCut(Int_t TRDelectronPID);
242  // Request Flags
259  protected:
261  AliPIDResponse* fPIDResponse;
266  //cuts
335  TRandom3 fRandom;
337  Int_t* fElectronLabelArray; //[fElectronArraySize]
344  TObjString* fCutString;
361  // Histograms
393  TH2F** fHistoEleMapMean; //[fnRBins]
394  TH2F** fHistoEleMapWidth; //[fnRBins]
395  TH2F** fHistoPosMapMean; //[fnRBins]
396  TH2F** fHistoPosMapWidth; //[fnRBins]
398  private:
400  ClassDef(AliConversionPhotonCuts,18)
402 };
404 #endif
Int_t charge
Double_t fTofPIDnSigmaAboveElectronLine
sigma cut RRnewTOF
Double_t fMinRDC
Min R for Double Counting Cut.
Bool_t SetDCARPhotonPrimVtxCut(Int_t DCARPhotonPrimVtx)
const char * filename
Definition: TestFCM.C:1
TH2F * fHistoTOFSigafter
TOF Sigma after cuts.
Bool_t SetQtMaxCut(Int_t QtMaxCut)
Float_t fMaxPhiCut
phi sector cut
Bool_t fPreSelCut
Flag for preselection cut used in V0Reader.
Double_t fMinPPhotonAsymmetryCut
Min Momentum for Asymmetry Cut.
TH2F * fHistoAcceptanceCuts
bookkeeping for acceptance cuts
#define P(T, U, S)
Double_t fPIDTRDEfficiency
required electron efficiency for TRD PID
double Double_t
Definition: External.C:58
TH2F * fHistodEdxCuts
bookkeeping for dEdx cuts
virtual Bool_t IsSelected(TObject *)
Bool_t RejectSharedElectronV0s(AliAODConversionPhoton *photon, Int_t nV0, Int_t nV0s)
Double_t fOpenAngle
Opening Angle for Double Counting Cut.
TH2F * fHistoPhotonCuts
bookkeeping for photon specific cuts
Double_t fPIDnSigmaAbovePionLine
sigma cut
Definition: External.C:236
Bool_t fDodEdxSigmaCut
flag to use the dEdxCut based on sigmas
TObjString * fCutString
cut number used for analysis
Double_t fMinClsTPC
minimum clusters in the TPC
const char * title
Definition: MakeQAPdf.C:27
Int_t GetFirstTPCRow(Double_t radius)
static const char * fgkCutNames[kNCuts]
Bool_t InitializeElecDeDxPostCalibration(TString filename)
Double_t fDCAZPrimVtxCut
cut value for the maximum distance in Z between the photon & the primary vertex [cm] ...
Bool_t fSwitchToKappa
switches from standard dEdx nSigma TPC cuts to Kappa TPC
void FillV0EtaBeforedEdxCuts(Float_t v0Eta)
TH1F * fHistoCutIndex
bookkeeping for cuts
Bool_t PIDProbabilityCut(AliConversionPhotonBase *photon, AliVEvent *event)
Bool_t SetLowPRejectionCuts(Int_t LowPRejectionSigmaCut)
TH2F * fHistoTPCdEdxSigafter
TPC Sigm dEdx after cuts.
Double_t fMinPhotonAsymmetry
Asymmetry Cut.
Double_t fTRDPIDAboveCut
TRD cut range.
Float_t fEtaForPhiCutMin
eta cut for phi sector selection
void SetProcessAODCheck(Bool_t flag)
Bool_t SetSinglePtCut(Int_t singlePtCut)
Bool_t fMaterialBudgetWeightsInitialized
weights for conversions photons due due deviating material budget in MC compared to data ...
TH2F * fHistoTPCdEdxafter
TPC dEdx after cuts.
Double_t fDeltaR
Delta R for Double Counting Cut.
virtual Bool_t IsSelected(TList *)
Int_t fInPlaneOutOfPlane
In-Plane Out-Of Plane Analysis.
TH2F * fHistoArmenterosafter
armenteros podolanski plot after cuts
AliPIDResponse * fPIDResponse
PID response.
Bool_t AsymmetryCut(AliConversionPhotonBase *photon, AliVEvent *event)
Double_t fPIDMinPPionRejectionLowP
Momentum limit to apply proton rejection.
TH2F * fHistoPsiPairDeltaPhiafter
TOF Sigma after cuts.
TH2F * fHistoArmenterosbefore
armenteros podolanski plot before cuts
Bool_t SetToCloseV0sCut(Int_t toClose)
void InitCutHistograms(TString name="", Bool_t preCut=kTRUE)
TH2F * fHistoTOFbefore
TOF before cuts.
Bool_t SetTOFElectronPIDCut(Int_t TOFelectronPID)
Bool_t fDoShrinkTPCAcceptance
Flag for shrinking the TPC acceptance due to different reasons.
Bool_t PhotonIsSelectedAODMC(AliAODMCParticle *particle, TClonesArray *aodmcArray, Bool_t checkForConvertedGamma=kTRUE)
AliConversionPhotonCuts(const char *name="V0Cuts", const char *title="V0 Cuts")
Float_t fMinPhiCut
phi sector cut
TH1F * fHistoInvMassafter
e+e- inv mass distribution after cuts
AliConversionPhotonCuts & operator=(const AliConversionPhotonCuts &)
Bool_t SetMinPhiSectorCut(Int_t minPhiCut)
void FillElectonLabelArray(AliAODConversionPhoton *photon, Int_t nV0)
Double_t fSinglePtCut2
second pt cut for electron/positron if asymmetric cut is chosen
Double_t GetCorrectedElectronTPCResponse(Short_t charge, Double_t nsig, Double_t P, Double_t Eta, Double_t R)
AliESDtrack * GetESDTrack(AliESDEvent *event, Int_t label)
TH2F * fHistoITSSigafter
ITS Sigma after cuts.
static AliConversionPhotonCuts * GetStandardCuts2010PbPb()
Double_t fDoKaonRejectionLowP
Kaon rejection at low p.
Int_t fElectronArraySize
Size of electron array.
TH2F * fHistoTOFSigbefore
TOF Sigma before cuts.
Int_t fIsHeavyIon
flag for pp (0), PbPb (1), pPb (2)
Bool_t RejectToCloseV0s(AliAODConversionPhoton *photon, TList *photons, Int_t nV0)
Bool_t InPlaneOutOfPlaneCut(Double_t photonPhi, Double_t eventPlaneAngle=-100, Bool_t fill=kTRUE)
Bool_t fElecDeDxPostCalibrationInitialized
flag to check that initialization worked
Bool_t PhotonCuts(AliConversionPhotonBase *photon, AliVEvent *event)
Bool_t SetChi2GammaCut(Int_t chi2GammaCut)
int Int_t
Definition: External.C:63
Bool_t SetCut(cutIds cutID, Int_t cut)
Double_t fDoPionRejectionLowP
Pion rejection at low p.
void SetDoElecDeDxPostCalibration(Bool_t k=kTRUE)
TH1F * fHistoInvMassbefore
e+e- inv mass distribution before cuts
TH1F * fHistoEventPlanePhi
EventPlaneAngle Minus Photon Angle.
float Float_t
Definition: External.C:68
Bool_t fUseITSpid
flag to use tof pid
TH1F * fHistoEtaDistV0sAfterdEdxCuts
eta-distribution of all V0s after Finder selection after dEdx cuts
Float_t fConversionPointYArray
Array with conversion Point y.
Double_t fTRDPIDBelowCut
TRD cut range.
Double_t fPIDMaxPnSigmaAbovePionLine
sigma cut
Double_t fITSPIDnSigmaAboveElectronLine
sigma cut RRnewTOF
Double_t fDCARPrimVtxCut
cut value for the maximum distance in R between the photon & the primary vertex [cm] ...
Bool_t SetITSElectronPIDCut(Int_t ITSelectronPID)
Bool_t SetPhotonAsymmetryCut(Int_t doPhotonAsymmetryCut)
TH2F * fHistoITSSigbefore
ITS Sigma before cuts.
Double_t fPIDnSigmaAtLowPAroundKaonLine
sigma cut
Bool_t SetKappaTPCCut(Int_t kappaCut)
Double_t fPIDnSigmaAtLowPAroundPionLine
sigma cut
Bool_t fDoTOFsigmaCut
flag to use TOF pid cut RRnewTOF
Bool_t SetDCAZPhotonPrimVtxCut(Int_t DCAZPhotonPrimVtx)
Bool_t SetMinMomPiondEdxCut(Int_t piMinMomdedxSigmaCut)
Double_t fPIDMinPnSigmaAbovePionLine
sigma cut
Double_t fPIDnSigmaBelowElectronLine
sigma cut
Bool_t PhotonIsSelectedMC(TParticle *particle, AliMCEvent *mcEvent, Bool_t checkForConvertedGamma=kTRUE)
Class handling all kinds of selection cuts for Gamma Conversion analysis.
Bool_t fDoPhotonAsymmetryCut
flag to use the PhotonAsymetryCut
TString fV0ReaderName
Name of the V0 reader.
TH2F * fHistoAsymmetryafter
asymmetry plot after cuts
Bool_t fDoPhotonPDependentAsymCut
flag to use the PhotonAsymetryCut with P dependent cut
TProfile * fProfileContainingMaterialBudgetWeights
Bool_t InitializeCutsFromCutString(const TString analysisCutSelection)
Bool_t SetCosPAngleCut(Int_t cosCut)
void SetV0ReaderName(TString name)
Bool_t SetEtaForPhiCut(Int_t etaPhiCut)
Bool_t SetTPCClusterCut(Int_t clsTPCCut)
Bool_t InitializeMaterialBudgetWeights(Int_t flag, TString filename)
Bool_t fUseTOFpid
flag to use tof pid
short Short_t
Definition: External.C:23
void SetPIDResponse(AliPIDResponse *pidResponse)
Float_t GetMaterialBudgetCorrectingWeightForTrueGamma(AliAODConversionPhoton *gamma)
TList * fHistograms
List of QA histograms.
Bool_t fDoQtGammaSelection
Select gammas using qtMax.
Float_t fKappaMinCut
maximum Kappa cut
TH2F * fHistoTPCdEdxbefore
TPC dEdx before cuts.
Bool_t fProcessAODCheck
Flag for processing check for AOD to be contained in AliAODs.root and AliAODGammaConversion.root.
TH2F * fHistoKappaafter
Kappa vs photon pt after cuts.
Float_t fKappaMaxCut
maximum Kappa cut
Bool_t SetTRDElectronCut(Int_t TRDElectronCut)
void FillPhotonCutIndex(Int_t photoncut)
Double_t fSinglePtCut
pt cut for electron/positron
Bool_t SetPsiPairCut(Int_t psiCut)
TH2F * fHistoTPCdEdxSigbefore
TPC Sigma dEdx before cuts.
Bool_t SpecificTrackCuts(AliAODTrack *negTrack, AliAODTrack *posTrack, Int_t &cutIndex)
Cut functions.
Double_t fQtMax
Maximum Qt from Armenteros to select Gammas.
Double_t fTofPIDnSigmaBelowElectronLine
sigma cut RRnewTOF
Float_t fOpeningAngle
min opening angle for meson
UChar_t DeterminePhotonQualityAOD(AliAODConversionPhoton *, AliVEvent *)
Bool_t SelectV0Finder(Bool_t onfly)
TH1F * fHistoEtaDistV0s
eta-distribution of all V0s after Finder selection
Bool_t fDo2DQt
Select gammas using ellipse cut.
void SetFillCutHistograms(TString name="", Bool_t preCut=kTRUE)
void FillV0EtaAfterdEdxCuts(Float_t v0Eta)
Bool_t AcceptanceCuts(AliConversionPhotonBase *photon)
Bool_t fDoDoubleCountingCut
Flag to reject double counting.
Double_t fMinClsTPCToF
minimum clusters to findable clusters
Float_t GetKappaTPC(AliConversionPhotonBase *gamma, AliVEvent *event)
AliVTrack * GetTrack(AliVEvent *event, Int_t label)
Bool_t CosinePAngleCut(const AliConversionPhotonBase *photon, AliVEvent *event) const
void SetPreSelectionCutFlag(Bool_t preSelFlag)
void SetDodEdxSigmaCut(Bool_t k=kTRUE)
void SetSwitchToKappaInsteadOfNSigdEdxTPC(Bool_t k=kTRUE)
Int_t fUseOnFlyV0FinderSameSign
int to set same sign pairing
Double_t fPIDnSigmaAbovePionLineHighPt
sigma cut
Double_t fPIDMinPProtonRejectionLowP
Momentum limit to apply proton rejection.
Float_t fConversionPointXArray
Array with conversion Point x.
static AliConversionPhotonCuts * GetStandardCuts2010pp()
Bool_t SetMaxMomPiondEdxCut(Int_t piMaxMomdedxSigmaCut)
Double_t fPIDnSigmaAtLowPAroundProtonLine
sigma cut
Bool_t PsiPairCut(const AliConversionPhotonBase *photon) const
Double_t fMaxPtPIDITS
max pt for ITS PID
Bool_t SetTPCdEdxCutElectronLine(Int_t ededxSigmaCut)
bool Bool_t
Definition: External.C:53
Bool_t dEdxCuts(AliVTrack *track, AliConversionPhotonBase *photon)
void SetIsHeavyIon(Int_t isHeavyIon)
Bool_t fUseCorrectedTPCClsInfo
flag to use corrected tpc cl info
Double_t fPIDnSigmaAboveElectronLine
sigma cut
Bool_t TracksAreSelected(AliVTrack *negTrack, AliVTrack *posTrack)
Bool_t KappaCuts(AliConversionPhotonBase *photon, AliVEvent *event)
Bool_t SetInPlaneOutOfPlane(Int_t inOutPlane)
Bool_t SetMaxPhiSectorCut(Int_t maxPhiCut)
Bool_t fDoTRDPID
flag to use TRD pid
Bool_t SetSharedElectronCut(Int_t sharedElec)
Double_t fITSPIDnSigmaBelowElectronLine
sigma cut RRnewTOF
Bool_t SetV0Finder(Int_t v0FinderType)
Bool_t AcceptanceCut(TParticle *particle, TParticle *ePos, TParticle *eNeg)
Bool_t SetCutIds(TString cutString)
Bool_t SetTRDElectronPIDCut(Int_t TRDelectronPID)
Bool_t fDoLightOutput
switch for running light output, kFALSE -> normal mode, kTRUE -> light mode
Bool_t fDoAsymPtCut
Flag for setting asymmetric pT cut on electron/positron.
TH1F * fHistoTrackCuts
bookkeeping for track cuts
Double_t GetCosineOfPointingAngle(const AliConversionPhotonBase *photon, AliVEvent *event) const
Bool_t ArmenterosQtCut(AliConversionPhotonBase *photon)
Bool_t CorrectedTPCClusterCut(AliConversionPhotonBase *photon, AliVEvent *event)
Float_t fEtaForPhiCutMax
eta cut for phi sector selection
Double_t fDoProtonRejectionLowP
Proton rejection at low p.
Double_t fPIDMinPKaonRejectionLowP
Momentum limit to apply kaon rejection.
Bool_t PhotonIsSelected(AliConversionPhotonBase *photon, AliVEvent *event)
Float_t fConversionPointZArray
Array with conversion Point z.
Bool_t SetTPCdEdxCutPionLine(Int_t pidedxSigmaCut)
TH2F * fHistoAsymmetrybefore
asymmetry plot after cuts
Bool_t PhiSectorCut(AliConversionPhotonBase *photon)