c04c80e6 |
1 | /************************************************************************** |
2 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * |
3 | * * |
4 | * Author: The ALICE Off-line Project. * |
5 | * Contributors are mentioned in the code where appropriate. * |
6 | * * |
7 | * Permission to use, copy, modify and distribute this software and its * |
8 | * documentation strictly for non-commercial purposes is hereby granted * |
9 | * without fee, provided that the above copyright notice appears in all * |
10 | * copies and that both the copyright notice and this permission notice * |
11 | * appear in the supporting documentation. The authors make no claims * |
12 | * about the suitability of this software for any purpose. It is * |
13 | * provided "as is" without express or implied warranty. * |
14 | **************************************************************************/ |
15 | // |
16 | // Class for the V0 cuts - tuned to obtain clean eletron, pion and proton samples. |
17 | // NOT suitable for V0 analysis |
18 | // |
c2690925 |
19 | #ifndef ALIHFEV0CUTS_H |
20 | #define ALIHFEV0CUTS_H |
21 | |
c04c80e6 |
22 | #include "AliHFEcollection.h" |
23 | |
24 | class TList; |
25 | |
26 | class AliMCParticle; |
27 | class AliVEvent; |
28 | class AliMCEvent; |
c2690925 |
29 | class AliESDtrack; |
c04c80e6 |
30 | class AliESDv0; |
31 | class AliKFVertex; |
32 | class AliKFParticle; |
33 | class AliVTrack; |
34 | |
35 | class AliHFEV0cuts : public TObject { |
36 | public: |
e156c3bb |
37 | enum{ |
38 | kBitQA = 1, |
39 | kBitQAmc = 2 |
40 | }; |
3a72645a |
41 | enum{ // Reconstructed V0 |
42 | kUndef = 0, |
43 | kRecoGamma = 1, |
44 | kRecoK0 = 2, |
45 | kRecoPhi = 3, |
46 | kRecoLambda = 4, |
47 | kRecoALambda = -4 |
48 | |
49 | }; |
50 | enum{ // Identified Daughter particles |
51 | kRecoElectron = 0, |
52 | kRecoPionK0 = 1, |
53 | kRecoPionL = 2, |
54 | kRecoKaon = 3, |
55 | kRecoProton = 4 |
56 | }; |
c04c80e6 |
57 | AliHFEV0cuts(); |
58 | ~AliHFEV0cuts(); |
59 | AliHFEV0cuts(const AliHFEV0cuts &ref); |
60 | AliHFEV0cuts &operator=(const AliHFEV0cuts &ref); |
61 | |
62 | void Init(const char* name); |
63 | |
2e486d84 |
64 | //void RunQA(); |
c04c80e6 |
65 | void SetMCEvent(AliMCEvent* const mce) { fMCEvent = mce; }; |
66 | void SetInputEvent(AliVEvent* const e) { fInputEvent = e; }; |
67 | void SetPrimaryVertex(AliKFVertex* const v) { fPrimaryVertex = v; }; |
68 | |
e156c3bb |
69 | TList* GetList() { |
70 | CLRBIT(fDestBits, kBitQA); |
71 | return fQA->GetList(); |
72 | }; |
73 | TList* GetListMC() { |
74 | CLRBIT(fDestBits, kBitQAmc); |
75 | return fQAmc->GetList(); |
76 | }; |
c04c80e6 |
77 | |
78 | Bool_t TrackCutsCommon(AliESDtrack* track); |
79 | Bool_t V0CutsCommon(AliESDv0 *v0); |
80 | Bool_t GammaCuts(AliESDv0 *v0); |
81 | Bool_t K0Cuts(AliESDv0 *v0); |
82 | Bool_t LambdaCuts(AliESDv0 *v0, Bool_t &isLambda); |
83 | |
e156c3bb |
84 | void Armenteros(const AliESDv0 *v0, Float_t val[2]); |
c04c80e6 |
85 | |
e156c3bb |
86 | Double_t OpenAngle(AliESDv0 const *v0);//opening angle between V0 daughters; close to zero for conversions |
87 | Double_t PsiPair(const AliESDv0 *v0); |
c04c80e6 |
88 | |
e156c3bb |
89 | Bool_t CheckSigns(AliESDv0 const *v0); |
3a72645a |
90 | Bool_t GetConvPosXY(AliESDtrack * const ptrack, AliESDtrack * const ntrack, Double_t convpos[2]); |
91 | Bool_t GetHelixCenter(AliESDtrack * const track, Double_t b,Int_t charge, Double_t center[2]); |
92 | |
93 | |
94 | // MC stuff |
95 | void SetCurrentV0id(Int_t id) { fCurrentV0id = id; }; |
96 | void SetDaughtersID(Int_t d[2]) {fPdaughterPDG = d[0]; fNdaughterPDG = d[1]; }; |
c04c80e6 |
97 | |
e156c3bb |
98 | AliKFParticle *CreateMotherParticle(AliVTrack const *pdaughter, AliVTrack const *ndaughter, Int_t pspec, Int_t nspec); |
c04c80e6 |
99 | |
100 | private: |
101 | void Copy(TObject &ref) const; |
102 | |
103 | private: |
104 | |
105 | AliHFEcollection *fQA; // store QA cut histograms |
3a72645a |
106 | AliHFEcollection *fQAmc; // store |
c04c80e6 |
107 | AliMCEvent *fMCEvent; // MC event |
108 | AliVEvent *fInputEvent; // Input Event |
109 | AliKFVertex *fPrimaryVertex; // primary vertex |
110 | |
3a72645a |
111 | Int_t fCurrentV0id; // MC flagged V0 |
112 | Int_t fPdaughterPDG; // MC id of the positive daugeter |
113 | Int_t fNdaughterPDG; // MC id of the negative daugeter |
114 | |
e156c3bb |
115 | UInt_t fDestBits; // status bits for destructor |
116 | |
c04c80e6 |
117 | ClassDef(AliHFEV0cuts, 1) |
118 | }; |
119 | |
120 | |
121 | #endif |