1 #ifndef ALIRSNCUTDAUGHTERD0_H
2 #define ALIRSNCUTDAUGHTERD0_H
5 // Cuts for selecting good pion candidates for D0 analysis
6 // with the data samples from pp/PbPb/pPb runs in 2010/2011/2012/2013.
7 // Applies track quality selection plus PID selection,
8 // with different tolerance ranges depending on the momentum.
11 #include "AliVTrack.h"
12 #include "AliRsnCut.h"
13 #include "AliRsnCutTrackQuality.h"
15 class AliRsnCutDaughterD0 : public AliRsnCut {
19 AliRsnCutDaughterD0(const char *name = "", AliPID::EParticleType pid = AliPID::kPion);
20 AliRsnCutDaughterD0(const AliRsnCutDaughterD0 ©);
21 AliRsnCutDaughterD0 &operator=(const AliRsnCutDaughterD0 ©);
22 virtual ~AliRsnCutDaughterD0() { }
24 void SetNoPID(Bool_t yn = kTRUE) {fNoPID = yn;}
26 void SetPID(AliPID::EParticleType type) {fPID = type;}
28 void SetTPCPionPIDCut(Double_t value) {fPionTPCPIDCut = value;}
29 void SetTPCKaonPIDCut(Double_t value) {fKaonTPCPIDCut = value;}
31 void SetTOFPionPIDCut(Double_t value) {fPionTOFPIDCut = value;}
32 void SetTOFKaonPIDCut(Double_t value) {fKaonTOFPIDCut = value;}
34 AliRsnCutTrackQuality *CutQuality() {return &fCutQuality;}
35 Bool_t MatchTOF(const AliVTrack *vtrack);
36 virtual Bool_t IsSelected(TObject *obj);
39 Bool_t fNoPID; // flag to switch off PID check
40 AliPID::EParticleType fPID; // PID for track
41 AliRsnCutTrackQuality fCutQuality; // track quality cut
44 Double_t fPionTPCPIDCut; // TPC nsigmas for pions
45 Double_t fKaonTPCPIDCut; // TPC nsigmas for kaons
46 Double_t fPionTOFPIDCut; // TOF nsigmas for pions
47 Double_t fKaonTOFPIDCut; // TOF nsigmas for kaons
49 ClassDef(AliRsnCutDaughterD0,1) // cut definitions for D0
52 //__________________________________________________________________________________________________
53 inline Bool_t AliRsnCutDaughterD0::MatchTOF(const AliVTrack *vtrack)
56 // Checks if the track has matched the TOF detector
60 AliWarning("NULL argument: impossible to check status");
64 if (!(vtrack->GetStatus() & AliESDtrack::kTOFout)) return kFALSE;
65 if (!(vtrack->GetStatus() & AliESDtrack::kTIME )) return kFALSE;