]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ANALYSIS/AliESDv0KineCuts.cxx
Protection against div by 0 added.
[u/mrichter/AliRoot.git] / ANALYSIS / AliESDv0KineCuts.cxx
1 /**************************************************************************\r
2  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *\r
3  *                                                                        *\r
4  * Author: The ALICE Off-line Project.                                    *\r
5  * Contributors are mentioned in the code where appropriate.              *\r
6  *                                                                        *\r
7  * Permission to use, copy, modify and distribute this software and its   *\r
8  * documentation strictly for non-commercial purposes is hereby granted   *\r
9  * without fee, provided that the above copyright notice appears in all   *\r
10  * copies and that both the copyright notice and this permission notice   *\r
11  * appear in the supporting documentation. The authors make no claims     *\r
12  * about the suitability of this software for any purpose. It is          *\r
13  * provided "as is" without express or implied warranty.                  *\r
14  **************************************************************************/\r
15 \r
16 /*\r
17  * author: M.Kalisky@gsi.de\r
18  * 08/Dec/2010\r
19  *\r
20  * Description: This class allows with purely kinematical cuts\r
21  * to select clean samples of electrons, pions and protons from the\r
22  * V0 online finder ESD V0 candidates for PID and dectector resonse\r
23  * studies.\r
24  */\r
25 \r
26 #include <TVector3.h>\r
27 #include <TDatabasePDG.h>\r
28 \r
29 #include "AliESDv0.h"\r
30 #include "AliESDtrack.h"\r
31 #include "AliESDEvent.h"\r
32 #include "AliVEvent.h"\r
33 #include "AliLog.h"\r
34 #include "AliKFParticle.h"\r
35 #include "AliVTrack.h"\r
36 #include "AliKFVertex.h"\r
37 \r
38 #include "AliESDv0KineCuts.h"\r
39 \r
40 ClassImp(AliESDv0KineCuts)\r
41 \r
42 //____________________________________________________________________\r
43 AliESDv0KineCuts::AliESDv0KineCuts() :\r
44   fEvent(0x0)\r
45   , fPrimaryVertex(0x0)\r
46   , fType(0)\r
47   , fMode(0)\r
48   , fTPCNcls(1)\r
49   , fTPCrefit(kTRUE)\r
50   , fTPCchi2perCls(4.0)\r
51   , fTPCclsRatio(0.6)\r
52   , fNoKinks(kTRUE)\r
53   , fGcutChi2NDF(10)\r
54   , fGcutInvMass(0.05)\r
55   , fK0cutChi2NDF(10)\r
56   , fLcutChi2NDF(10)\r
57   , fUseExternalVertex(kFALSE)\r
58   , fDeleteVertex(kFALSE)\r
59 {\r
60   //\r
61   // Default constructor\r
62   //\r
63 \r
64   // default single track cuts\r
65   fTPCNcls = 1;                // minimal number of the TPC clusters\r
66   fTPCrefit = kTRUE;           // TPC refit\r
67   fTPCchi2perCls = 4.0;        // chi2 per TPC cluster\r
68   fTPCclsRatio = 0.6;          // minimal foun/findable TPC cluster ratio\r
69   fNoKinks = kTRUE;            // kinks - no [kTRUE] or do not care [kFalse]\r
70 \r
71 \r
72   // default gamma cuts values\r
73   fGcutChi2NDF = 10;           // Chi2NF cut value for the AliKFparticle gamma\r
74   fGcutCosPoint[0] = 0;        // cos of the pointing angle [min, max]\r
75   fGcutCosPoint[1] = 0.02;     // cos of the pointing angle [min, max]\r
76   fGcutDCA[0] = 0.;            // DCA between the daughter tracks [min, max]\r
77   fGcutDCA[1] = 0.25;          // DCA between the daughter tracks [min, max]\r
78   fGcutVertexR[0] = 3.;        // radius of the conversion point [min, max]\r
79   fGcutVertexR[1] = 90.;       // radius of the conversion point [min, max]\r
80   fGcutPsiPair[0] = 0.;        // value of the psi pair cut [min, max]\r
81   fGcutPsiPair[1] = 0.05;      // value of the psi pair cut [min, max]\r
82   fGcutInvMass = 0.05;         // upper value on the gamma invariant mass\r
83   // default K0 cuts\r
84   fK0cutChi2NDF = 10;          // Chi2NF cut value for the AliKFparticle K0\r
85   fK0cutCosPoint[0] = 0.;      // cos of the pointing angle [min, max]\r
86   fK0cutCosPoint[1] = 0.02;    // cos of the pointing angle [min, max]\r
87   fK0cutDCA[0] = 0.;           // DCA between the daughter tracks [min, max]\r
88   fK0cutDCA[1] = 0.2;          // DCA between the daughter tracks [min, max]\r
89   fK0cutVertexR[0] = 2.0;      // radius of the decay point [min, max]\r
90   fK0cutVertexR[1] = 30.0;     // radius of the decay point [min, max]\r
91   fK0cutInvMass[0] = 0.486;    // invariant mass window\r
92   fK0cutInvMass[1] = 0.508;    // invariant mass window\r
93   // Lambda & anti-Lambda cut values\r
94   fLcutChi2NDF = 10;           // Chi2NF cut value for the AliKFparticle K0\r
95   fLcutCosPoint[0] = 0.;       // cos of the pointing angle [min, max]\r
96   fLcutCosPoint[1] = 0.02;     // cos of the pointing angle [min, max]\r
97   fLcutDCA[0] = 0.;            // DCA between the daughter tracks [min, max]\r
98   fLcutDCA[1] = 0.2;           // DCA between the daughter tracks [min, max]\r
99   fLcutVertexR[0] = 2.0;       // radius of the decay point [min, max]\r
100   fLcutVertexR[1] = 40.0;      // radius of the decay point [min, max]\r
101   fLcutInvMass[0] = 1.11;      // invariant mass window\r
102   fLcutInvMass[1] = 1.12;      // invariant mass window\r
103     \r
104 }\r
105 //____________________________________________________________________\r
106 AliESDv0KineCuts::~AliESDv0KineCuts(){\r
107   //\r
108   // Destructor\r
109   //\r
110 \r
111 \r
112 }\r
113 //____________________________________________________________________\r
114 AliESDv0KineCuts::AliESDv0KineCuts(const AliESDv0KineCuts &ref):\r
115   TObject(ref)\r
116   , fEvent(0x0)\r
117   , fPrimaryVertex(0x0)\r
118   , fType(0)\r
119   , fMode(0)\r
120   , fTPCNcls(1)\r
121   , fTPCrefit(kTRUE)\r
122   , fTPCchi2perCls(4.0)\r
123   , fTPCclsRatio(0.6)\r
124   , fNoKinks(kTRUE)\r
125   , fGcutChi2NDF(10)\r
126   , fGcutInvMass(0.05)\r
127   , fK0cutChi2NDF(10)\r
128   , fLcutChi2NDF(10)\r
129   , fUseExternalVertex(kFALSE)\r
130   , fDeleteVertex(kFALSE)\r
131 {\r
132   //\r
133   // Copy operator\r
134   //\r
135 \r
136   ref.Copy(*this);\r
137 }\r
138 //____________________________________________________________________\r
139 AliESDv0KineCuts &AliESDv0KineCuts::operator=(const AliESDv0KineCuts &ref){\r
140   //\r
141   // assignment operator\r
142   //\r
143   if(this != &ref)\r
144     ref.Copy(*this);\r
145   return *this; \r
146 }\r
147 //____________________________________________________________________\r
148 void AliESDv0KineCuts::Copy(TObject &ref) const {\r
149   //\r
150   // Performs the copying of the object\r
151   //\r
152 \r
153   TObject::Copy(ref);\r
154 \r
155   AliESDv0KineCuts &target = dynamic_cast<AliESDv0KineCuts &>(ref);\r
156 \r
157   // default single track cuts\r
158   target.fTPCNcls = fTPCNcls;\r
159   target.fTPCrefit = fTPCrefit;\r
160   target.fTPCchi2perCls = fTPCchi2perCls;\r
161   target.fTPCclsRatio = fTPCclsRatio;\r
162   target.fNoKinks = fNoKinks;\r
163   target.fUseExternalVertex = fUseExternalVertex;  //added december 2nd 2011\r
164   target.fDeleteVertex = fDeleteVertex;  //added december 2nd 2011\r
165 \r
166   // default gamma cuts values\r
167   target.fGcutChi2NDF = fGcutChi2NDF;\r
168   memcpy(target.fGcutCosPoint, fGcutCosPoint, sizeof(Float_t) * 2);\r
169   memcpy(target.fGcutDCA, fGcutDCA, sizeof(Float_t) * 2); \r
170   memcpy(target.fGcutVertexR, fGcutVertexR, sizeof(Float_t) * 2);\r
171   memcpy(target.fGcutPsiPair, fGcutPsiPair, sizeof(Float_t) * 2);\r
172   target.fGcutInvMass = fGcutInvMass;\r
173   // default K0 cuts\r
174   target.fK0cutChi2NDF = fK0cutChi2NDF;\r
175   memcpy(target.fK0cutCosPoint, fK0cutCosPoint, sizeof(Float_t) * 2);\r
176   memcpy(target.fK0cutDCA, fK0cutDCA, sizeof(Float_t) * 2);\r
177   memcpy(target.fK0cutVertexR, fK0cutVertexR, sizeof(Float_t) * 2);\r
178   memcpy(target.fK0cutInvMass, fK0cutInvMass, sizeof(Float_t) * 2);\r
179   // Lambda & anti-Lambda cut values\r
180   target.fLcutChi2NDF = fLcutChi2NDF;\r
181   memcpy(target.fLcutCosPoint, fLcutCosPoint, sizeof(Float_t) * 2);\r
182   memcpy(target.fLcutDCA, fLcutDCA, sizeof(Float_t) * 2);\r
183   memcpy(target.fLcutVertexR, fLcutVertexR, sizeof(Float_t) * 2);\r
184   memcpy(target.fLcutInvMass, fLcutInvMass, sizeof(Float_t) * 2);\r
185   \r
186 }\r
187 //____________________________________________________________________\r
188 Bool_t  AliESDv0KineCuts::ProcessV0(AliESDv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN) const \r
189 {\r
190   //\r
191   // main user function\r
192   //\r
193 \r
194   if(!v0) return kFALSE;\r
195   if(!fEvent){\r
196     AliErrorClass("No valid Event pointer available, provide it first");\r
197     return kFALSE;\r
198   }\r
199 \r
200   if(!V0CutsCommon(v0)) return kFALSE;\r
201 \r
202   const Int_t id = PreselectV0(v0);\r
203 \r
204   if(!SingleTrackCuts(v0)) return kFALSE;\r
205 \r
206   switch(id){\r
207   case kUndef:\r
208     return kFALSE;\r
209   case kGamma:\r
210     return CaseGamma(v0, pdgV0, pdgP, pdgN);\r
211   case kK0:\r
212     return CaseK0(v0, pdgV0, pdgP, pdgN);\r
213   case kLambda:\r
214     return CaseLambda(v0, pdgV0, pdgP, pdgN, 0);\r
215   case kALambda:\r
216     return CaseLambda(v0, pdgV0, pdgP, pdgN, 1);\r
217   default:\r
218     return kFALSE; \r
219   }\r
220 \r
221   return kFALSE;\r
222 }\r
223 //____________________________________________________________________\r
224 Bool_t  AliESDv0KineCuts::ProcessV0(AliESDv0* const v0, Int_t &pdgP, Int_t &pdgN) const \r
225 {\r
226   //\r
227   // main user function, simplified if the V0 identity is not necessary\r
228   //\r
229 \r
230   if(!v0) return kFALSE;\r
231   if(!fEvent){\r
232     AliErrorClass("No valid Event pointer available, provide it first");\r
233     return kFALSE;\r
234   }\r
235 \r
236   Int_t idV0 = -1;\r
237   return ProcessV0(v0, idV0, pdgP, pdgN);\r
238 \r
239 }\r
240 //____________________________________________________________________\r
241 Int_t AliESDv0KineCuts::PreselectV0(AliESDv0* const v0) const \r
242 {\r
243   //\r
244   // Make a preselection (exclusive) of the V0 cadidates based on\r
245   // Armenteros plot\r
246   // the armenteros cut values are currently fixed and user is not able to set them via\r
247   // set funcions. The reason is that these cuts are optimized and furneter changes should \r
248   // not be necessary. To prove otherwise please study in detail before changing the values\r
249   //\r
250  \r
251   Float_t ap[2] = {-1., -1.};\r
252   Armenteros(v0, ap);\r
253   // for clarity\r
254   const Float_t alpha = ap[0];\r
255   const Float_t qt = ap[1];\r
256 \r
257   // selection cuts \r
258   // - the reagions for different candidates must not overlap \r
259 \r
260   // Gamma cuts\r
261   const Double_t cutAlphaG = 0.35; \r
262   const Double_t cutQTG = 0.05;\r
263   const Double_t cutAlphaG2[2] = {0.6, 0.8};\r
264   const Double_t cutQTG2 = 0.04;\r
265 \r
266   // K0 cuts\r
267   const Float_t cutQTK0[2] = {0.1075, 0.215};\r
268   const Float_t cutAPK0[2] = {0.199, 0.8};   // parameters for curved QT cut\r
269   \r
270   // Lambda & A-Lambda cuts\r
271   const Float_t cutQTL = 0.03;\r
272   const Float_t cutAlphaL[2] = {0.35, 0.7};\r
273   const Float_t cutAlphaAL[2] = {-0.7,  -0.35};\r
274   const Float_t cutAPL[3] = {0.107, -0.69, 0.5};  // parameters fir curved QT cut\r
275 \r
276 \r
277   if(kPurity == fMode){\r
278   // Check for Gamma candidates\r
279     if(qt < cutQTG){\r
280       if( (TMath::Abs(alpha) < cutAlphaG) ) return kGamma;\r
281     }\r
282     // additional region - should help high pT gammas\r
283     if(qt < cutQTG2){\r
284       if( (TMath::Abs(alpha) > cutAlphaG2[0]) &&  (TMath::Abs(alpha) < cutAlphaG2[1]) ) return kGamma;\r
285     }\r
286   }\r
287   if(kEffGamma == fMode){\r
288     if(qt < cutQTG) return kGamma;\r
289   }\r
290 \r
291   \r
292   // Check for K0 candidates\r
293   Float_t q = cutAPK0[0] * TMath::Sqrt(TMath::Abs(1 - alpha*alpha/(cutAPK0[1]*cutAPK0[1])));\r
294   if( (qt > cutQTK0[0]) && (qt < cutQTK0[1]) && (qt > q) ){\r
295     return kK0;\r
296   }\r
297 \r
298   // Check for Lambda candidates\r
299   q = cutAPL[0] * TMath::Sqrt(TMath::Abs(1 - ( (alpha + cutAPL[1]) * (alpha + cutAPL[1]) ) / (cutAPL[2]*cutAPL[2]) ));\r
300   if( (alpha > cutAlphaL[0]) && (alpha < cutAlphaL[1]) && (qt > cutQTL) && (qt < q)  ){\r
301     return kLambda;\r
302   }\r
303 \r
304   // Check for A-Lambda candidates\r
305   q = cutAPL[0] * TMath::Sqrt(TMath::Abs(1 - ( (alpha - cutAPL[1]) * (alpha - cutAPL[1]) ) / (cutAPL[2]*cutAPL[2]) ));\r
306   if( (alpha > cutAlphaAL[0]) && (alpha < cutAlphaAL[1]) && (qt > cutQTL) && (qt < q)  ){\r
307     return kALambda;\r
308   }\r
309   \r
310   return kUndef;\r
311 }\r
312 //____________________________________________________________________\r
313 Bool_t  AliESDv0KineCuts::SingleTrackCuts(AliESDv0 * const v0) const \r
314 {\r
315   //\r
316   // apply single track cuts\r
317   // correct sign not relevat here\r
318   //\r
319 \r
320   if(!v0) return kFALSE;\r
321   \r
322   Int_t pIndex = 0, nIndex = 0;\r
323   pIndex = v0->GetPindex();\r
324   nIndex = v0->GetNindex();\r
325   AliESDtrack* d[2];\r
326   d[0] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(pIndex));\r
327   d[1] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(nIndex));\r
328   \r
329   for(Int_t i=0; i<2; ++i){\r
330     if(!d[i]) return kFALSE;\r
331     \r
332     // status word\r
333     ULong_t status = d[i]->GetStatus();\r
334 \r
335     // No. of TPC clusters leave to the users\r
336     if(d[i]->GetTPCNcls() < 1) return kFALSE;\r
337 \r
338     // TPC refit\r
339     if(!(status & AliESDtrack::kTPCrefit)) return kFALSE;\r
340   \r
341     // Chi2 per TPC cluster\r
342     Int_t nTPCclusters = d[i]->GetTPCNcls();\r
343     Float_t chi2perTPCcluster = d[i]->GetTPCchi2()/Float_t(nTPCclusters);\r
344     if(chi2perTPCcluster > 4) return kFALSE;\r
345 \r
346     // TPC cluster ratio\r
347     Float_t cRatioTPC = d[i]->GetTPCNclsF() > 0. ? static_cast<Float_t>(d[i]->GetTPCNcls())/static_cast<Float_t> (d[i]->GetTPCNclsF()) : 1.;\r
348     if(cRatioTPC < 0.6) return kFALSE;\r
349     \r
350     // kinks\r
351     if(d[i]->GetKinkIndex(0) != 0) return kFALSE;\r
352     \r
353   }\r
354 \r
355   return kTRUE;\r
356 }\r
357 //____________________________________________________________________\r
358 Bool_t AliESDv0KineCuts::CaseGamma(AliESDv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN) const \r
359 {\r
360   //\r
361   // process the gamma conversion candidate\r
362   //\r
363 \r
364   if(!v0) return kFALSE;\r
365 \r
366   AliVTrack* daughter[2];\r
367   Int_t pIndex = 0, nIndex = 0;\r
368 \r
369   Bool_t sign = CheckSigns(v0);\r
370   if(sign){\r
371     pIndex = v0->GetPindex();\r
372     nIndex = v0->GetNindex();\r
373   }\r
374   else{\r
375     pIndex = v0->GetNindex();\r
376     nIndex = v0->GetPindex();    \r
377   }\r
378   daughter[0] = dynamic_cast<AliVTrack *>(fEvent->GetTrack(pIndex));\r
379   daughter[1] = dynamic_cast<AliVTrack *>(fEvent->GetTrack(nIndex));\r
380   if(!daughter[0] || !daughter[1]) return kFALSE;\r
381 \r
382   AliKFParticle *kfMother = CreateMotherParticle(daughter[0], daughter[1], TMath::Abs(kElectron), TMath::Abs(kElectron));\r
383   if(!kfMother) return kFALSE;\r
384 \r
385   AliESDtrack* d[2];\r
386   d[0] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(pIndex));\r
387   d[1] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(nIndex));\r
388 \r
389   Float_t iMass = v0->GetEffMass(0, 0);\r
390 \r
391   // cos pointing angle\r
392   Double_t cosPoint = v0->GetV0CosineOfPointingAngle();\r
393   cosPoint = TMath::ACos(cosPoint);\r
394 \r
395   // DCA between daughters\r
396   Double_t dca = v0->GetDcaV0Daughters();\r
397 \r
398   // Production vertex\r
399   Double_t x, y, z; \r
400   v0->GetXYZ(x,y,z);\r
401   Double_t r = TMath::Sqrt(x*x + y*y);\r
402 \r
403   Double_t xy[2];\r
404   Double_t r2 = -1.;\r
405   if ( GetConvPosXY(d[0], d[1], xy) ){\r
406     r2 = TMath::Sqrt(xy[0]*xy[0] + xy[1]*xy[1]);\r
407   }\r
408 \r
409   // psi pair \r
410   Double_t psiPair = PsiPair(v0);\r
411   \r
412   // V0 chi2/ndf\r
413   Double_t chi2ndf = kfMother->GetChi2()/kfMother->GetNDF();\r
414 \r
415   if(kfMother) delete kfMother; \r
416   \r
417   // apply the cuts\r
418 \r
419   if(iMass > fGcutInvMass) return kFALSE;\r
420 \r
421   if(chi2ndf > fGcutChi2NDF) return kFALSE;\r
422 \r
423   if(cosPoint < fGcutCosPoint[0] || cosPoint > fGcutCosPoint[1]) return kFALSE;\r
424 \r
425   if(dca < fGcutDCA[0] || dca > fGcutDCA[1]) return kFALSE;\r
426 \r
427   if(r < fGcutVertexR[0] || r > fGcutVertexR[1]) return kFALSE;\r
428 \r
429   if(psiPair < fGcutPsiPair[0] || psiPair > fGcutPsiPair[1]) return kFALSE;\r
430   \r
431   // all cuts passed\r
432 \r
433   pdgV0 = 22;\r
434   if(sign){\r
435     pdgP = -11;\r
436     pdgN = 11;\r
437   }\r
438   else{\r
439     pdgP = 11;\r
440     pdgN = -11;\r
441   }\r
442 \r
443   return kTRUE;\r
444 }\r
445 //____________________________________________________________________\r
446 Bool_t  AliESDv0KineCuts::CaseK0(AliESDv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN) const {\r
447   //\r
448   // process the K0 candidate\r
449   //\r
450 \r
451   if(!v0) return kFALSE;\r
452   \r
453   AliVTrack* daughter[2];\r
454   Int_t pIndex = 0, nIndex = 0;\r
455   Bool_t sign = CheckSigns(v0);\r
456   if(sign){\r
457     pIndex = v0->GetPindex();\r
458     nIndex = v0->GetNindex();\r
459   }\r
460   else{\r
461     pIndex = v0->GetNindex();\r
462     nIndex = v0->GetPindex();    \r
463   }\r
464  \r
465   daughter[0] = dynamic_cast<AliVTrack *>(fEvent->GetTrack(pIndex));\r
466   daughter[1] = dynamic_cast<AliVTrack *>(fEvent->GetTrack(nIndex));\r
467   if(!daughter[0] || !daughter[1]) return kFALSE;\r
468 \r
469   AliKFParticle *kfMother = CreateMotherParticle(daughter[0], daughter[1], TMath::Abs(kPiPlus), TMath::Abs(kPiPlus));\r
470   if(!kfMother) return kFALSE;\r
471 \r
472   AliESDtrack* d[2];\r
473   d[0] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(pIndex));\r
474   d[1] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(nIndex));\r
475 \r
476   Float_t iMass = v0->GetEffMass(2, 2);\r
477 \r
478   // cos pointing angle\r
479   Double_t cosPoint = v0->GetV0CosineOfPointingAngle();\r
480   cosPoint = TMath::ACos(cosPoint);\r
481 \r
482   // DCA between daughters\r
483   Double_t dca = v0->GetDcaV0Daughters();\r
484 \r
485   // Production vertex\r
486   Double_t x, y, z; \r
487   v0->GetXYZ(x,y,z);\r
488 \r
489   Double_t r = TMath::Sqrt(x*x + y*y);  \r
490 \r
491   // V0 chi2/ndf\r
492   Double_t chi2ndf = kfMother->GetChi2()/kfMother->GetNDF();\r
493   \r
494   if(kfMother) delete kfMother; \r
495 \r
496   //\r
497   // apply the cuts\r
498   //\r
499   if(iMass < fK0cutInvMass[0] || iMass > fK0cutInvMass[1]) return kFALSE;\r
500 \r
501   if(chi2ndf > fK0cutChi2NDF) return kFALSE;\r
502 \r
503   if(cosPoint < fK0cutCosPoint[0] || cosPoint > fK0cutCosPoint[1]) return kFALSE;\r
504 \r
505   if(dca < fK0cutDCA[0] || dca > fK0cutDCA[1]) return kFALSE;\r
506 \r
507   if(r < fK0cutVertexR[0] || r > fK0cutVertexR[1]) return kFALSE;\r
508 \r
509   // all cuts passed\r
510   pdgV0 = 310;\r
511   if(sign){\r
512     pdgP = 211;\r
513     pdgN = -211;\r
514   }\r
515   else{\r
516     pdgP = -211;\r
517     pdgN = 211;\r
518   }\r
519 \r
520   return kTRUE;\r
521 }\r
522 //____________________________________________________________________\r
523 Bool_t  AliESDv0KineCuts::CaseLambda(AliESDv0* const v0, Int_t &pdgV0, Int_t &pdgP, Int_t &pdgN, Int_t id) const {\r
524   //\r
525   // process teh Lambda and Anti-Lambda candidate\r
526   //\r
527   \r
528   if(!v0) return kFALSE;\r
529 \r
530     const Double_t cL0mass=TDatabasePDG::Instance()->GetParticle(kLambda0)->Mass();  // PDG lambda mass\r
531 \r
532   AliVTrack* daughter[2];\r
533   Int_t pIndex = 0, nIndex = 0;\r
534   Float_t mMass[2] = {-1., -1.};\r
535   Bool_t sign = CheckSigns(v0);\r
536   if(sign){\r
537     pIndex = v0->GetPindex();\r
538     nIndex = v0->GetNindex();\r
539     mMass[0] = v0->GetEffMass(4, 2);\r
540     mMass[1] = v0->GetEffMass(2, 4);\r
541   }\r
542   else{\r
543     pIndex = v0->GetNindex();\r
544     nIndex = v0->GetPindex();    \r
545     mMass[0] = v0->GetEffMass(2, 4);\r
546     mMass[1] = v0->GetEffMass(4, 2);\r
547   }\r
548  \r
549   daughter[0] = dynamic_cast<AliVTrack *>(fEvent->GetTrack(pIndex));\r
550   daughter[1] = dynamic_cast<AliVTrack *>(fEvent->GetTrack(nIndex));\r
551   if(!daughter[0] || !daughter[1]) return kFALSE;\r
552 \r
553   AliKFParticle *kfMother[2] = {0x0, 0x0};\r
554   // Lambda\r
555   kfMother[0] = CreateMotherParticle(daughter[0], daughter[1], TMath::Abs(kProton), TMath::Abs(kPiPlus));\r
556   if(!kfMother[0]) return kFALSE;\r
557   \r
558   // Anti-Lambda\r
559   kfMother[1] = CreateMotherParticle(daughter[0], daughter[1], TMath::Abs(kPiPlus), TMath::Abs(kProton));\r
560   if(!kfMother[1]) return kFALSE;\r
561 \r
562   Float_t dMass[2] = {TMath::Abs(mMass[0] - cL0mass), TMath::Abs(mMass[1] - cL0mass)};\r
563   \r
564   AliESDtrack* d[2];\r
565   d[0] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(pIndex));\r
566   d[1] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(nIndex));\r
567   if(!d[0] || !d[1])    return kFALSE;\r
568   \r
569   Float_t p[2] = {d[0]->GetP(), d[1]->GetP()}; \r
570 \r
571   // check the 3 lambda - antilambda variables\r
572   Int_t check[2] = {-1, -1};   // 0 : lambda, 1 : antilambda\r
573   // 1) momentum of the daughter particles - proton is expected to have higher momentum than pion\r
574   check[0] = (p[0] > p[1]) ? 0 : 1;\r
575   // 2) mass of the mother particle\r
576   check[1] = (dMass[0] < dMass[1]) ? 0 : 1;\r
577  \r
578   // require positive correlation of (1) and (2)\r
579   if(check[0] != check[1]){\r
580     if(kfMother[0]) delete kfMother[0]; \r
581     if(kfMother[1]) delete kfMother[1]; \r
582     return kFALSE;\r
583   }\r
584 \r
585   // now that the check[0] == check[1]\r
586   const Int_t type = check[0];\r
587 \r
588   // require that the input armenteros preselection agree:\r
589   if(type != id) return kFALSE;\r
590 \r
591   Float_t iMass =0.;\r
592   if(sign){\r
593     iMass = (type == 0) ? v0->GetEffMass(4, 2) : v0->GetEffMass(2, 4);\r
594   }\r
595   else{\r
596     iMass = (type == 0) ? v0->GetEffMass(2, 4) : v0->GetEffMass(4, 2);\r
597   }\r
598 \r
599   // cos pointing angle\r
600   Double_t cosPoint = v0->GetV0CosineOfPointingAngle();\r
601   cosPoint = TMath::ACos(cosPoint);\r
602 \r
603   // DCA between daughters\r
604   Double_t dca = v0->GetDcaV0Daughters();\r
605   \r
606   // Production vertex\r
607   Double_t x, y, z; \r
608   v0->GetXYZ(x,y,z);\r
609   Double_t r = TMath::Sqrt(x*x + y*y);\r
610 \r
611   // proton - pion indices\r
612   Int_t ix[2] = {0, 1};\r
613   if(1 == type){\r
614     ix[0] = 1;\r
615     ix[1] = 0;\r
616   }\r
617 \r
618   // V0 chi2/ndf\r
619   Double_t chi2ndf = kfMother[type]->GetChi2()/kfMother[type]->GetNDF();\r
620 \r
621   if(kfMother[0]) delete kfMother[0]; \r
622   if(kfMother[1]) delete kfMother[1]; \r
623 \r
624   //\r
625   // apply the cuts\r
626   //\r
627 \r
628   if(iMass < fLcutInvMass[0] || iMass > fLcutInvMass[1]) return kFALSE;\r
629 \r
630   if(chi2ndf > fLcutChi2NDF) return kFALSE;\r
631 \r
632   if(cosPoint < fLcutCosPoint[0] || cosPoint > fLcutCosPoint[1]) return kFALSE;\r
633 \r
634   if(dca < fLcutDCA[0] || dca > fLcutDCA[1]) return kFALSE;\r
635 \r
636   if(r < fLcutVertexR[0] || r > fLcutVertexR[1]) return kFALSE;\r
637 \r
638   // all cuts passed\r
639 \r
640   if(0 == type){\r
641     pdgV0 = 3122;\r
642     if(sign){\r
643       pdgP = 2212;\r
644       pdgN = -211;\r
645     }\r
646     else{\r
647       pdgP = -211;\r
648       pdgN = 2212;\r
649     }\r
650   }\r
651   else{\r
652     pdgV0 = -3122;\r
653     if(sign){\r
654       pdgP = 211;\r
655       pdgN = -2212;\r
656     }\r
657     else{\r
658       pdgP = -2212;\r
659       pdgN = 211;\r
660     }\r
661   }\r
662 \r
663   return kTRUE;\r
664 }\r
665 //____________________________________________________________________\r
666 Bool_t  AliESDv0KineCuts::V0CutsCommon(const AliESDv0 * const v0) const \r
667 {\r
668   //\r
669   // V0 cuts common to all V0s\r
670   //\r
671 \r
672   AliESDtrack* dN, *dP; \r
673  \r
674   dP = dynamic_cast<AliESDtrack *>(fEvent->GetTrack(v0->GetPindex()));\r
675   dN = dynamic_cast<AliESDtrack *>(fEvent->GetTrack(v0->GetNindex())); \r
676   \r
677   if(!dN || !dP) return kFALSE;\r
678 \r
679   Int_t qP = dP->Charge();\r
680   Int_t qN = dN->Charge();\r
681 \r
682   if((qP*qN) != -1) return kFALSE;\r
683 \r
684   return kTRUE;\r
685 }\r
686 //____________________________________________________________________\r
687 void AliESDv0KineCuts::Armenteros(AliESDv0* const v0, Float_t val[2]) const \r
688 {\r
689   //\r
690   // computes the Armenteros variables for given V0\r
691   // fills the histogram\r
692   // returns the values via "val"\r
693   //\r
694   \r
695   Double_t mn[3] = {0,0,0};\r
696   Double_t mp[3] = {0,0,0};  \r
697   Double_t mm[3] = {0,0,0};  \r
698 \r
699   if(CheckSigns(v0)){\r
700     v0->GetNPxPyPz(mn[0],mn[1],mn[2]); //reconstructed cartesian momentum components of negative daughter\r
701     v0->GetPPxPyPz(mp[0],mp[1],mp[2]); //reconstructed cartesian momentum components of positive daughter\r
702   }\r
703   else{\r
704     v0->GetPPxPyPz(mn[0],mn[1],mn[2]); //reconstructed cartesian momentum components of negative daughter\r
705     v0->GetNPxPyPz(mp[0],mp[1],mp[2]); //reconstructed cartesian momentum components of positive daughter\r
706   }\r
707   v0->GetPxPyPz(mm[0],mm[1],mm[2]); //reconstructed cartesian momentum components of mother\r
708 \r
709   TVector3 vecN(mn[0],mn[1],mn[2]);\r
710   TVector3 vecP(mp[0],mp[1],mp[2]);\r
711   TVector3 vecM(mm[0],mm[1],mm[2]);\r
712   \r
713   Double_t thetaP = acos((vecP * vecM)/(vecP.Mag() * vecM.Mag()));\r
714   Double_t thetaN = acos((vecN * vecM)/(vecN.Mag() * vecM.Mag()));\r
715   \r
716   Double_t alfa = ((vecP.Mag())*cos(thetaP)-(vecN.Mag())*cos(thetaN))/\r
717     ((vecP.Mag())*cos(thetaP)+(vecN.Mag())*cos(thetaN)) ;\r
718   Double_t qt = vecP.Mag()*sin(thetaP);\r
719 \r
720   val[0] = alfa;\r
721   val[1] = qt;\r
722 }\r
723 //____________________________________________________________________\r
724 Bool_t AliESDv0KineCuts::CheckSigns(AliESDv0* const v0) const \r
725 {\r
726   //\r
727   // check wheter the sign was correctly applied to \r
728   // V0 daughter tracks\r
729   //\r
730   \r
731   Bool_t correct = kFALSE;\r
732 \r
733   Int_t pIndex = 0, nIndex = 0;\r
734   pIndex = v0->GetPindex();\r
735   nIndex = v0->GetNindex();\r
736   \r
737   AliESDtrack* d[2];\r
738   d[0] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(pIndex));\r
739   d[1] = dynamic_cast<AliESDtrack*>(fEvent->GetTrack(nIndex));\r
740 \r
741   Int_t sign[2];\r
742   sign[0] = (int)d[0]->GetSign();\r
743   sign[1] = (int)d[1]->GetSign();\r
744   \r
745   if(-1 == sign[0] && 1 == sign[1]){\r
746     correct = kFALSE;\r
747   }\r
748   else{\r
749     correct = kTRUE;\r
750   }\r
751   \r
752   return correct;\r
753 }\r
754 //________________________________________________________________\r
755 Double_t AliESDv0KineCuts::PsiPair(AliESDv0* const v0) const \r
756 {\r
757   //\r
758   // Angle between daughter momentum plane and plane \r
759   // \r
760 \r
761   if(!fEvent) return -1.;\r
762 \r
763   Float_t magField = fEvent->GetMagneticField();\r
764 \r
765   Int_t pIndex = -1;\r
766   Int_t nIndex = -1;\r
767   if(CheckSigns(v0)){\r
768     pIndex = v0->GetPindex();\r
769     nIndex = v0->GetNindex();\r
770   }\r
771   else{\r
772     pIndex = v0->GetNindex();\r
773     nIndex = v0->GetPindex();    \r
774   }\r
775  \r
776 \r
777   AliESDtrack* daughter[2];\r
778 \r
779   daughter[0] = dynamic_cast<AliESDtrack *>(fEvent->GetTrack(pIndex));\r
780   daughter[1] = dynamic_cast<AliESDtrack *>(fEvent->GetTrack(nIndex));\r
781 \r
782   Double_t x, y, z;\r
783   v0->GetXYZ(x,y,z);//Reconstructed coordinates of V0; to be replaced by Markus Rammler's method in case of conversions!\r
784   \r
785   Double_t mn[3] = {0,0,0};\r
786   Double_t mp[3] = {0,0,0};\r
787   \r
788 \r
789   v0->GetNPxPyPz(mn[0],mn[1],mn[2]);//reconstructed cartesian momentum components of negative daughter;\r
790   v0->GetPPxPyPz(mp[0],mp[1],mp[2]);//reconstructed cartesian momentum components of positive daughter; \r
791 \r
792 \r
793   Double_t deltat = 1.;\r
794   deltat = TMath::ATan(mp[2]/(TMath::Sqrt(mp[0]*mp[0] + mp[1]*mp[1])+1.e-13)) -  TMath::ATan(mn[2]/(TMath::Sqrt(mn[0]*mn[0] + mn[1]*mn[1])+1.e-13));//difference of angles of the two daughter tracks with z-axis\r
795 \r
796   Double_t radiussum = TMath::Sqrt(x*x + y*y) + 50;//radius to which tracks shall be propagated\r
797 \r
798   Double_t momPosProp[3];\r
799   Double_t momNegProp[3];\r
800     \r
801   AliExternalTrackParam pt(*daughter[0]), nt(*daughter[1]);\r
802     \r
803   Double_t psiPair = 4.;\r
804 \r
805   if(nt.PropagateTo(radiussum,magField) == 0)//propagate tracks to the outside\r
806     psiPair =  -5.;\r
807   if(pt.PropagateTo(radiussum,magField) == 0)\r
808     psiPair = -5.;\r
809   pt.GetPxPyPz(momPosProp);//Get momentum vectors of tracks after propagation\r
810   nt.GetPxPyPz(momNegProp);\r
811   \r
812   Double_t pEle =\r
813     TMath::Sqrt(momNegProp[0]*momNegProp[0]+momNegProp[1]*momNegProp[1]+momNegProp[2]*momNegProp[2]);//absolute momentum value of negative daughter\r
814   Double_t pPos =\r
815     TMath::Sqrt(momPosProp[0]*momPosProp[0]+momPosProp[1]*momPosProp[1]+momPosProp[2]*momPosProp[2]);//absolute momentum value of positive daughter\r
816     \r
817   Double_t scalarproduct =\r
818     momPosProp[0]*momNegProp[0]+momPosProp[1]*momNegProp[1]+momPosProp[2]*momNegProp[2];//scalar product of propagated positive and negative daughters' momenta\r
819     \r
820   Double_t chipair = TMath::ACos(scalarproduct/(pEle*pPos));//Angle between propagated daughter tracks\r
821 \r
822   psiPair =  TMath::Abs(TMath::ASin(deltat/chipair));  \r
823 \r
824   return psiPair; \r
825 }\r
826 //___________________________________________________________________\r
827 Bool_t  AliESDv0KineCuts::GetConvPosXY(AliESDtrack * const ptrack, AliESDtrack * const ntrack, Double_t convpos[2]) const\r
828 {\r
829   //\r
830   // recalculate the gamma conversion XY postition\r
831   //\r
832 \r
833   const Double_t b = fEvent->GetMagneticField();\r
834 \r
835   Double_t helixcenterpos[2];\r
836   GetHelixCenter(ptrack,b,ptrack->Charge(),helixcenterpos);\r
837 \r
838   Double_t helixcenterneg[2];\r
839   GetHelixCenter(ntrack,b,ntrack->Charge(),helixcenterneg);\r
840 \r
841   Double_t  poshelix[6];\r
842   ptrack->GetHelixParameters(poshelix,b);\r
843   Double_t posradius = TMath::Abs(1./poshelix[4]);\r
844 \r
845   Double_t  neghelix[6];\r
846   ntrack->GetHelixParameters(neghelix,b);\r
847   Double_t negradius = TMath::Abs(1./neghelix[4]);\r
848 \r
849   Double_t xpos = helixcenterpos[0];\r
850   Double_t ypos = helixcenterpos[1];\r
851   Double_t xneg = helixcenterneg[0];\r
852   Double_t yneg = helixcenterneg[1];\r
853 \r
854   convpos[0] = (xpos*negradius + xneg*posradius)/(negradius+posradius);\r
855   convpos[1] = (ypos*negradius+  yneg*posradius)/(negradius+posradius);\r
856 \r
857   return 1;\r
858 }\r
859 //___________________________________________________________________\r
860 Bool_t  AliESDv0KineCuts::GetHelixCenter(AliESDtrack * const track, Double_t b,Int_t charge, Double_t center[2]) const\r
861 {\r
862   //\r
863   // computes the center of the track helix\r
864   //\r
865   \r
866   Double_t pi = TMath::Pi();\r
867   \r
868   Double_t  helix[6];\r
869   track->GetHelixParameters(helix,b);\r
870   \r
871   Double_t xpos =  helix[5];\r
872   Double_t ypos =  helix[0];\r
873   Double_t radius = TMath::Abs(1./helix[4]);\r
874   Double_t phi = helix[2];\r
875 \r
876   if(phi < 0){\r
877     phi = phi + 2*pi;\r
878   }\r
879 \r
880   phi -= pi/2.;\r
881   Double_t xpoint =  radius * TMath::Cos(phi);\r
882   Double_t ypoint =  radius * TMath::Sin(phi);\r
883 \r
884   if(b<0){\r
885     if(charge > 0){\r
886       xpoint = - xpoint;\r
887       ypoint = - ypoint;\r
888     }\r
889     /* avoid self assignment\r
890     if(charge < 0){\r
891       xpoint =  xpoint;\r
892       ypoint =  ypoint;\r
893     }\r
894     */\r
895   }\r
896   if(b>0){\r
897     /* avoid self assignment\r
898     if(charge > 0){\r
899       xpoint =  xpoint;\r
900       ypoint =  ypoint;\r
901     }\r
902     */\r
903     if(charge < 0){\r
904       xpoint = - xpoint;\r
905       ypoint = - ypoint;\r
906     }\r
907   }\r
908   center[0] =  xpos + xpoint;\r
909   center[1] =  ypos + ypoint;\r
910 \r
911   return 1;\r
912 }\r
913 //___________________________________________________________________\r
914 AliKFParticle *AliESDv0KineCuts::CreateMotherParticle(const AliVTrack* const pdaughter, const AliVTrack* const ndaughter, Int_t pspec, Int_t nspec) const\r
915 {\r
916   //\r
917   // Creates a mother particle\r
918   //\r
919   AliKFParticle pkfdaughter(*pdaughter, pspec);\r
920   AliKFParticle nkfdaughter(*ndaughter, nspec);\r
921   \r
922   \r
923   // Create the mother particle \r
924   AliKFParticle *m = new AliKFParticle(pkfdaughter, nkfdaughter);\r
925   m->SetField(fEvent->GetMagneticField());\r
926   if(TMath::Abs(kElectron) == pspec && TMath::Abs(kElectron) == nspec) m->SetMassConstraint(0, 0.001);\r
927   else if(TMath::Abs(kPiPlus) == pspec && TMath::Abs(kPiPlus) == nspec) m->SetMassConstraint(TDatabasePDG::Instance()->GetParticle(kK0Short)->Mass(), 0.);\r
928   else if(TMath::Abs(kProton) == pspec && TMath::Abs(kPiPlus) == nspec) m->SetMassConstraint(TDatabasePDG::Instance()->GetParticle(kLambda0)->Mass(), 0.);\r
929   else if(TMath::Abs(kPiPlus) == pspec && TMath::Abs(kProton) == nspec) m->SetMassConstraint(TDatabasePDG::Instance()->GetParticle(kLambda0)->Mass(), 0.);\r
930   else{\r
931     AliErrorClass("Wrong daughter ID - mass constraint can not be set");\r
932   }\r
933 \r
934   AliKFVertex improvedVertex = *fPrimaryVertex;\r
935   improvedVertex += *m;\r
936   m->SetProductionVertex(improvedVertex);\r
937   \r
938   // update 15/06/2010\r
939   // mother particle will not be added to primary vertex but only to its copy \r
940   // as this confilcts with calling\r
941   // m->SetPrimaryVertex() function and\r
942   // subsequently removing the mother particle afterwards\r
943   // Source: Sergey Gorbunov\r
944 \r
945   return m;\r
946 }\r
947 //____________________________________________________________________\r
948 void  AliESDv0KineCuts::SetEvent(AliESDEvent* const event){\r
949   //\r
950   // direct setter of ESD event\r
951   //\r
952   fEvent = event;\r
953   if(!fEvent){\r
954     AliErrorClass("Invalid input event pointer");\r
955     return;\r
956   }\r
957 if (fUseExternalVertex) return;\r
958 else{\r
959         if(fPrimaryVertex && fDeleteVertex){\r
960                 delete  fPrimaryVertex;\r
961                 fPrimaryVertex=0x0;\r
962                 }\r
963         fPrimaryVertex = new AliKFVertex(*(fEvent->GetPrimaryVertex()));\r
964         fDeleteVertex=kTRUE;\r
965         }\r
966 \r
967 \r
968 \r
969 }\r
970 //____________________________________________________________________\r
971 void  AliESDv0KineCuts::SetEvent(AliVEvent* const event){\r
972   //\r
973   // direct setter of ESD event\r
974   //\r
975 \r
976   fEvent = dynamic_cast<AliESDEvent*>(event);\r
977   if(!fEvent){\r
978     AliErrorClass("Invalid input event pointer");\r
979     return;\r
980   }\r
981   \r
982   if (fUseExternalVertex) return;\r
983   else{\r
984     if(fPrimaryVertex && fDeleteVertex){\r
985       delete    fPrimaryVertex;\r
986       fPrimaryVertex=0x0;\r
987       }\r
988     fPrimaryVertex = new AliKFVertex(*(fEvent->GetPrimaryVertex()));\r
989     fDeleteVertex=kTRUE;\r
990   }\r
991 }\r
992 \r
993 \r
994 //________________________________________________________________\r
995 void     AliESDv0KineCuts::UseExternalVertex(Bool_t use_external){\r
996         //\r
997         // Reenable primary Vertex from ESD event\r
998         //\r
999         if (use_external) fUseExternalVertex =kTRUE;\r
1000         else fUseExternalVertex =kFALSE;\r
1001 }\r
1002 \r
1003 \r
1004 \r
1005 \r
1006 //________________________________________________________________\r
1007 void AliESDv0KineCuts::SetPrimaryVertex(AliKFVertex* const v){\r
1008   //\r
1009   // set the primary vertex of the event\r
1010   //\r
1011         if(fPrimaryVertex && fDeleteVertex){   \r
1012                 delete  fPrimaryVertex;\r
1013                 fPrimaryVertex =0x0;\r
1014                 fDeleteVertex = kFALSE;\r
1015                 }  \r
1016   fUseExternalVertex=kTRUE; \r
1017   fPrimaryVertex = v; // set primary Vertex\r
1018   if(!fPrimaryVertex){\r
1019     AliErrorClass("Failed to initialize the primary vertex");\r
1020     return;\r
1021   }\r
1022 }\r
1023 //___________________________________________________________________\r
1024 void AliESDv0KineCuts::SetMode(Int_t mode, Int_t type){\r
1025   //\r
1026   // this function allows the user to select (prior running the 'ProcessV0' function)\r
1027   // to select different approaches to V0 selection - the 'mode'\r
1028   // - and -\r
1029   // different systems (pp, PbPb) - 'type' \r
1030   //\r
1031   // To see the cut values for different modes please refer to the\r
1032   // function SetCuts()\r
1033   //\r
1034   // Important notice: based on the parameters particular sets of cuts will\r
1035   // be activated for teh V0 selection. If some additional changes to single\r
1036   // cuts are needed please us the SetXXXcut function (see the header file)\r
1037   // \r
1038 \r
1039   switch(mode){\r
1040   case kPurity:\r
1041     fMode = kPurity;  // used to obtain highest purity possible - the efficiency may be low\r
1042     break;\r
1043   case kEffGamma:\r
1044     fMode = kEffGamma; // used to obtain highes efficiency possible - the purity may be worse\r
1045     break;\r
1046   default:\r
1047     AliError("V0 selection mode not recognozed, setting 'kPurity'");\r
1048     fMode = kPurity;\r
1049   }\r
1050 \r
1051   switch(type){\r
1052   case kPP:\r
1053     fType = kPP;  // cuts optimized for low multiplicity \r
1054     break;\r
1055   case kPbPb:\r
1056     fType = kPbPb;  // cuts optimized for high multiplicity\r
1057     break;\r
1058   }\r
1059   \r
1060   // setup the cut values for selected mode & type\r
1061   SetCuts();\r
1062 \r
1063 }\r
1064 //___________________________________________________________________\r
1065 void AliESDv0KineCuts::SetMode(Int_t mode, const char* type){\r
1066   //\r
1067   // overloaded function - please see above\r
1068   // \r
1069   \r
1070   Int_t t = -1;\r
1071 \r
1072   if(!strcmp("pp", type)) t = kPP;\r
1073   else if(!(strcmp("PbPb", type))) t = kPbPb;\r
1074   else{\r
1075     AliError("data type not recognized, setting 'pp'");\r
1076     t = kPP;    \r
1077   }\r
1078 \r
1079   SetMode(mode, t);\r
1080 \r
1081 }\r
1082 //___________________________________________________________________\r
1083 void AliESDv0KineCuts::SetCuts(){\r
1084   //\r
1085   // this funciton sets the default cut values based on the selected\r
1086   // fMode and fType.\r
1087   // please note that only the cuts that have different values than the default\r
1088   // cuts are updated here\r
1089   //\r
1090   \r
1091   // last update: 14/02/2011\r
1092   // as a very preliminary  - the only change to default cuts is to apply\r
1093   // less restricting gamma conversion selection in PreselectV0() function\r
1094   \r
1095 \r
1096   \r
1097 }\r