]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWGLF/RESONANCES/AliRsnCutKaonForPhi2010PP.h
Update for centrality patch flag
[u/mrichter/AliRoot.git] / PWGLF / RESONANCES / AliRsnCutKaonForPhi2010PP.h
CommitLineData
4e4fb2f6 1#ifndef ALIRSNCUTKAONFORPHI2010PP_H
2#define ALIRSNCUTKAONFORPHI2010PP_H
110620ce 3
4//
4e4fb2f6 5// This cut implements all the checks done to accept a track as a Kaon
61f275d1 6// for the pp analysis using 2010 runs.
4e4fb2f6 7// It is based on standard cuts on track quality and nsigma cuts
8// with respect to the TPC and TOF signals for the PID.
110620ce 9//
10
11#include "AliVTrack.h"
12#include "AliRsnCut.h"
13#include "AliRsnCutTrackQuality.h"
14
15class AliRsnCutKaonForPhi2010PP : public AliRsnCut {
16
17public:
18
19 AliRsnCutKaonForPhi2010PP(const char *name = "");
de767d44 20 AliRsnCutKaonForPhi2010PP(const AliRsnCutKaonForPhi2010PP &copy);
61f275d1 21 AliRsnCutKaonForPhi2010PP &operator=(const AliRsnCutKaonForPhi2010PP &copy);
4e4fb2f6 22 virtual ~AliRsnCutKaonForPhi2010PP() { }
61f275d1 23
110620ce 24 void SetTPCNSigmaLow (Double_t v) {fNSigmaTPCLow = v;}
25 void SetTPCNSigmaHigh(Double_t v) {fNSigmaTPCHigh = v;}
26 void SetTPCLimit(Double_t v) {fLimitTPC = v;}
27 void SetTOFNSigma(Double_t v) {fNSigmaTOF = v;}
61f275d1 28
110620ce 29 virtual Bool_t IsSelected(TObject *obj);
de767d44 30 void InitMyPID(Bool_t isMC, Bool_t isESD);
61f275d1 31
110620ce 32 AliRsnCutTrackQuality *CutQuality() {return &fCutQuality;}
de767d44 33 AliPIDResponse *MyPID() {return fMyPID;}
110620ce 34
35private:
36
4e4fb2f6 37 Bool_t MatchTOF(const AliVTrack *vtrack);
61f275d1 38
110620ce 39 Double_t fNSigmaTPCLow; // TPC: nsigma cut below limit
40 Double_t fNSigmaTPCHigh; // TPC: nsigma cut above limit
61f275d1 41 Double_t fLimitTPC; // TPC: momentum limit
110620ce 42 Double_t fNSigmaTOF; // TOF: nsigma cut (unique)
43
de767d44 44 AliPIDResponse *fMyPID; // PID response object to be configured manyally
110620ce 45 AliRsnCutTrackQuality fCutQuality; // track quality cut
46
47 ClassDef(AliRsnCutKaonForPhi2010PP,1)
48
49};
50
51//__________________________________________________________________________________________________
4e4fb2f6 52inline Bool_t AliRsnCutKaonForPhi2010PP::MatchTOF(const AliVTrack *vtrack)
110620ce 53{
54//
55// Checks if the track has matched the TOF detector
56//
57
58 if (!vtrack) {
59 AliWarning("NULL argument: impossible to check status");
60 return kFALSE;
61 }
62
63 Bool_t isTOFout = ((vtrack->GetStatus() & AliESDtrack::kTOFout) != 0);
64 Bool_t isTIME = ((vtrack->GetStatus() & AliESDtrack::kTIME) != 0);
65
66 return (isTOFout && isTIME);
67}
68
69#endif