]>
Commit | Line | Data |
---|---|---|
c2adb927 | 1 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * |
2 | * See cxx source for full Copyright notice */ | |
3 | /* | |
4 | * plesae see source file for more details | |
5 | */ | |
6 | #ifndef ALIAODV0KINECUTS_H | |
7 | #define ALIAODV0KINECUTS_H | |
8 | ||
9 | #include <TObject.h> | |
10 | #include <TArrayI.h> | |
11 | ||
12 | class AliAODv0; | |
13 | class AliAODEvent; | |
14 | class AliVEvent; | |
15 | class AliAODTrack; | |
16 | class AliVTrack; | |
17 | class AliKFParticle; | |
18 | class AliKFVertex; | |
19 | ||
20 | class AliAODv0KineCuts : public TObject{ | |
21 | public: | |
22 | enum{ // Reconstructed V0 | |
23 | kUndef = -1, | |
24 | kGamma = 0, | |
25 | kK0 = 1, | |
26 | kLambda = 2, | |
27 | kALambda = 3 | |
28 | }; | |
29 | enum{ // data types | |
30 | kPP = 0, | |
31 | kPbPb = 1, // not yet implemented | |
32 | }; | |
33 | enum{ // operation modes | |
34 | kPurity = 0, // purely kinematical selection | |
35 | kEffGamma = 1 // !!! involves TPC dEdx or nSimga cuts !!! | |
36 | }; | |
37 | ||
38 | AliAODv0KineCuts(); | |
39 | virtual ~AliAODv0KineCuts(); | |
40 | ||
41 | AliAODv0KineCuts(const AliAODv0KineCuts &ref); | |
42 | AliAODv0KineCuts &operator=(const AliAODv0KineCuts &ref); | |
43 | ||
44 | // main selection function - called once per V0 candidate | |
45 | Bool_t ProcessV0(AliAODv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN) const; | |
46 | Bool_t ProcessV0(AliAODv0* const v0, Int_t &pdgP, Int_t &pdgN) const; | |
47 | ||
48 | // must be called by the user | |
49 | void SetEvent(AliAODEvent* const event); | |
50 | void SetEvent(AliVEvent* const event); | |
51 | void SetPrimaryVertex(AliKFVertex* const v); | |
52 | ||
53 | // user can select an operation modes [see .cxx for details] | |
54 | void SetMode(Int_t mode, Int_t type); | |
55 | void SetMode(Int_t mode, const char* type); | |
56 | void UseExternalVertex(Bool_t use_external=kTRUE); | |
57 | AliKFParticle *CreateMotherParticle(const AliVTrack* const pdaughter, const AliVTrack* const ndaughter, Int_t pspec, Int_t nspec) const; | |
58 | void SetCuts(); // setup cuts for selected fMode and fType, see source file for details | |
59 | // | |
60 | // setter functions for V0 cut values | |
61 | // for default values see the constructor | |
62 | // see the default contructor for comments | |
63 | // | |
64 | ||
65 | // single track cuts | |
66 | void SetNTPCclusters(Int_t n) { fTPCNcls = n; }; | |
67 | void SetTPCrefit(Bool_t r = kTRUE) { fTPCrefit = r; }; | |
68 | void SetTPCclusterratio(Float_t r) { fTPCclsRatio = r; }; | |
69 | void SetNoKinks(Bool_t k = kTRUE) { fNoKinks = k; }; | |
70 | ||
71 | // gamma cuts | |
72 | void SetGammaCutChi2NDF(Float_t val) { fGcutChi2NDF = val; }; | |
73 | void SetGammaCutCosPoint(Float_t * const val) { | |
74 | fGcutCosPoint[0] = val[0]; | |
75 | fGcutCosPoint[1] = val[1]; | |
76 | }; | |
77 | void SetGammaCutDCA(Float_t * const val){ | |
78 | fGcutDCA[0] = val[0]; | |
79 | fGcutDCA[1] = val[1]; | |
80 | }; | |
81 | void SetGammaCutVertexR(Float_t * const val){ | |
82 | fGcutVertexR[0] = val[0]; | |
83 | fGcutVertexR[1] = val[1]; | |
84 | }; | |
85 | void SetGammaCutPsiPair(Float_t * const val){ | |
86 | fGcutPsiPair[0] = val[0]; | |
87 | fGcutPsiPair[1] = val[1]; | |
88 | }; | |
89 | void SetGammaCutInvMass(Float_t val){ | |
90 | fGcutInvMass = val; | |
91 | }; | |
92 | // K0 cuts | |
93 | void SetK0CutChi2NDF(Float_t val) { fK0cutChi2NDF = val; }; | |
94 | void SetK0CutCosPoint(Float_t * const val) { | |
95 | fK0cutCosPoint[0] = val[0]; | |
96 | fK0cutCosPoint[1] = val[1]; | |
97 | }; | |
98 | void SetK0CutDCA(Float_t * const val){ | |
99 | fK0cutDCA[0] = val[0]; | |
100 | fK0cutDCA[1] = val[1]; | |
101 | }; | |
102 | void SetK0CutVertexR(Float_t * const val){ | |
103 | fK0cutVertexR[0] = val[0]; | |
104 | fK0cutVertexR[1] = val[1]; | |
105 | }; | |
106 | void SetK0CutInvMass(Float_t * const val){ | |
107 | fK0cutInvMass[0] = val[0]; | |
108 | fK0cutInvMass[1] = val[1]; | |
109 | }; | |
110 | // lambda & anti-lambda cuts | |
111 | void SetLambdaCutChi2NDF(Float_t val) { fLcutChi2NDF = val; }; | |
112 | void SetLambdaCutCosPoint(Float_t * const val) { | |
113 | fLcutCosPoint[0] = val[0]; | |
114 | fLcutCosPoint[1] = val[1]; | |
115 | }; | |
116 | void SetLambdaCutDCA(Float_t * const val){ | |
117 | fLcutDCA[0] = val[0]; | |
118 | fLcutDCA[1] = val[1]; | |
119 | }; | |
120 | void SetLambdaCutVertexR(Float_t * const val){ | |
121 | fLcutVertexR[0] = val[0]; | |
122 | fLcutVertexR[1] = val[1]; | |
123 | }; | |
124 | void SetLambdaCutInvMass(Float_t * const val){ | |
125 | fLcutInvMass[0] = val[0]; | |
126 | fLcutInvMass[1] = val[1]; | |
127 | }; | |
128 | ||
129 | ||
130 | Int_t PreselectV0(AliAODv0* const v0) const; | |
131 | ||
132 | Bool_t CaseGamma(AliAODv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN) const; | |
133 | Bool_t CaseK0(AliAODv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN) const; | |
134 | Bool_t CaseLambda(AliAODv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN, Int_t id) const; | |
135 | ||
136 | Bool_t V0CutsCommon(const AliAODv0 * const v0) const; | |
137 | Bool_t SingleTrackCuts(AliAODv0 * const v0) const; | |
138 | Bool_t CheckSigns(AliAODv0* const v0) const; | |
139 | ||
140 | Double_t PsiPair(AliAODv0* const v0) const; | |
141 | Bool_t GetConvPosXY(AliAODTrack * const ptrack, AliAODTrack * const ntrack, Double_t convpos[2]) const; | |
142 | Bool_t GetHelixCenter(AliAODTrack * const track, Double_t b, Int_t charge, Double_t center[2]) const; | |
143 | ||
144 | protected: | |
145 | void Copy(TObject &ref) const; | |
146 | ||
147 | private: | |
148 | Bool_t GammaEffCuts(AliAODv0 * const v0); // set of cuts optimized for high gamma efficiency | |
149 | Bool_t IsKinkMother(const AliAODTrack * const track) const; | |
150 | Bool_t IsKinkDaughter(const AliAODTrack * const track) const; | |
151 | ||
152 | private: | |
153 | AliAODEvent *fEvent; // current event | |
154 | AliKFVertex *fPrimaryVertex; // primary vertex | |
155 | ||
156 | Int_t fType; // data type: p-p or Pb-Pb | |
157 | Int_t fMode; // current operation mode | |
158 | ||
159 | // single track cuts | |
160 | Int_t fTPCNcls; // number of TPC clusters | |
161 | Bool_t fTPCrefit; // TPC refit - yes [kTRUE] or do not care [kFALSE] | |
162 | Float_t fTPCclsRatio; // min. TPC cluster ratio | |
163 | Bool_t fNoKinks; // kinks - no [kTRUE] or do not care [kFalse] | |
164 | TArrayI fKinkMotherList; // Kink mothers | |
165 | Int_t fNumberKinkMothers; // Number of kink mothers | |
166 | ||
167 | // gamma cut values | |
168 | Float_t fGcutChi2NDF; // Chi2NF cut value for the AliKFparticle gamma | |
169 | Float_t fGcutCosPoint[2]; // cos of the pointing angle [min, max] | |
170 | Float_t fGcutDCA[2]; // DCA between the daughter tracks [min, max] | |
171 | Float_t fGcutVertexR[2]; // radius of the conversion point [min, max] | |
172 | Float_t fGcutPsiPair[2]; // value of the psi pair cut [min, max] | |
173 | Float_t fGcutInvMass; // upper value on the gamma invariant mass | |
174 | // K0 cut values | |
175 | Float_t fK0cutChi2NDF; // Chi2NF cut value for the AliKFparticle K0 | |
176 | Float_t fK0cutCosPoint[2]; // cos of the pointing angle [min, max] | |
177 | Float_t fK0cutDCA[2]; // DCA between the daughter tracks [min, max] | |
178 | Float_t fK0cutVertexR[2]; // radius of the decay point [min, max] | |
179 | Float_t fK0cutInvMass[2]; // invariant mass window | |
180 | // Lambda & anti-Lambda cut values | |
181 | Float_t fLcutChi2NDF; // Chi2NF cut value for the AliKFparticle K0 | |
182 | Float_t fLcutCosPoint[2]; // cos of the pointing angle [min, max] | |
183 | Float_t fLcutDCA[2]; // DCA between the daughter tracks [min, max] | |
184 | Float_t fLcutVertexR[2]; // radius of the decay point [min, max] | |
185 | Float_t fLcutInvMass[2]; // invariant mass window | |
186 | Bool_t fUseExternalVertex; // Is kTRUE if Vertex is set via SetPrimaryVertex() | |
187 | Bool_t fDeleteVertex; // Is kTRUE if Vertex has been created in SetEvent() function | |
188 | ||
189 | ClassDef(AliAODv0KineCuts, 0); | |
190 | ||
191 | }; | |
192 | ||
193 | #endif |