Changes for the kink finder. Coding conventions (M.Ivanov)
[u/mrichter/AliRoot.git] / STEER / AliESDComparisonMI.h
CommitLineData
ae7d73d2 1
2class AliESDComparisonDraw: public AliComparisonDraw{
3public:
4 AliESDComparisonDraw(){fTree = 0;}
5 void SetIO(const char *fname = "cmpESDTracks.root");
6 ClassDef(AliESDComparisonDraw,1)
7};
8ClassImp(AliESDComparisonDraw)
9
10
11/////////////////////////////////////////////////////////////////////////
12class AliESDRecInfo: public TObject {
13
14public:
15 AliESDRecInfo(){}
16 ~AliESDRecInfo(){}
51ad6848 17 void UpdatePoints(AliESDtrack* track);
ae7d73d2 18 void Update(AliMCInfo* info,AliTPCParam * par, Bool_t reconstructed);
51ad6848 19 Float_t fTPCPoints[4]; //start , biggest end points + max density
ae7d73d2 20 Double_t fTPCinR0[5]; //generated position of the track at inner tpc - radius [3] and fi [4]
21 Double_t fTPCinR1[5]; //reconstructed postion of the track - radius [3] and fi [
22 Double_t fTPCinP0[5]; //generated position of the track at inner tpc
23 Double_t fTPCinP1[5]; //reconstructed postion of the track
24 Double_t fTPCAngle0[2]; // generated angle
25 Double_t fTPCAngle1[2]; //refconstructed angle
26 Double_t fTPCDelta[5]; // deltas
27 Double_t fTPCPools[5]; // pools
28 Double_t fITSinR0[5]; //generated position of the track at inner tpc
29 Double_t fITSinR1[5]; //reconstructed postion of the track
30 Double_t fITSinP0[5]; //generated position of the track at inner tpc
31 Double_t fITSinP1[5]; //reconstructed postion of the track
32 Double_t fITSAngle0[2]; // generated angle
33 Double_t fITSAngle1[2]; //refconstructed angle
34 Double_t fITSDelta[5]; // deltas
35 Double_t fITSPools[5]; // pools
36 AliESDtrack fESDTrack; // tpc track
51ad6848 37 AliITStrackMI fITStrack; //its track
ae7d73d2 38 AliTRDtrack fTRDtrack; //its track
51ad6848 39 Float_t fBestTOFmatch; //best matching between times
ae7d73d2 40 Float_t fTRLocalCoord[3]; //local coordinates of the track ref.
41 Int_t fReconstructed; //flag if track was reconstructed
42 Int_t fFake; // fake track
43 Int_t fMultiple; // number of reconstructions
44 Bool_t fTPCOn; // TPC refitted inward
51ad6848 45 Int_t fStatus[4]; // status -0 not found - 1 -only in - 2 -in-out -3 -in -out-refit
ae7d73d2 46 Bool_t fITSOn; // ITS refitted inward
47 Bool_t fTRDOn; // ITS refitted inward
48 Float_t fDeltaP; //delta of momenta
51ad6848 49 Double_t fSign;
50 Int_t fLabels[2];
ae7d73d2 51 void Reset();
52 ClassDef(AliESDRecInfo,1) // container for
53};
54ClassImp(AliESDRecInfo)
55
56void AliESDRecInfo::Reset()
57{
58 fMultiple =0;
59 fFake =0;
60 fReconstructed=0;
61}
62
63
64/////////////////////////////////////////////////////////
65/////////////////////////////////////////////////////////
66/////////////////////////////////////////////////////////
67
68
69class AliESDRecV0Info: public TObject {
70public:
71 void Update(Float_t vertex[3]);
72 AliESDRecInfo fT1; //track1
73 AliESDRecInfo fT2; //track2
74 Double_t fDist1; //info about closest distance according closest MC - linear DCA
75 Double_t fDist2; //info about closest distance parabolic DCA
76 Double_t fInvMass; //reconstructed invariant mass -
77 //
78 Double_t fPdr[3]; //momentum at vertex daughter - according approx at DCA
79 Double_t fXr[3]; //rec. position according helix
80 //
51ad6848 81 Double_t fMinR; // minimum radius in rphi intersection
82 Double_t fDistMinR; // distance at minimal radius
ae7d73d2 83 Double_t fPm[3]; //momentum at the vertex mother
84 Double_t fAngle[3]; //three angles
85 Double_t fRr; // rec position of the vertex
86 Int_t fLab[2]; //MC label of the partecle
87 Float_t fPointAngleFi; //point angle fi
88 Float_t fPointAngleTh; //point angle theta
89 Float_t fPointAngle; //point angle full
51ad6848 90 Int_t fV0Status; // status of the kink
91 AliESDV0MI fV0tpc; // Vo information from reconsturction according TPC
92 AliESDV0MI fV0its; // Vo information from reconsturction according ITS
93 AliESDV0MI fV0rec; // V0 information form the reconstruction
94 Int_t fMultiple;
95 Int_t fV0Multiple;
96 Int_t fRecStatus; // status form the reconstuction
ae7d73d2 97 ClassDef(AliESDRecV0Info,1) // container for
98};
99
100ClassImp(AliESDRecV0Info)
101
102
51ad6848 103class AliESDRecKinkInfo: public TObject {
104public:
105 void Update();
106 AliESDRecInfo fT1; //track1
107 AliESDRecInfo fT2; //track2
108 AliESDkink fKink; //kink
109 Double_t fDist1; //info about closest distance according closest MC - linear DCA
110 Double_t fDist2; //info about closest distance parabolic DCA
111 Double_t fInvMass; //reconstructed invariant mass -
112 //
113 Double_t fPdr[3]; //momentum at vertex daughter - according approx at DCA
114 Double_t fXr[3]; //rec. position according helix
115 //
116 Double_t fPm[3]; //momentum at the vertex mother
117 Double_t fAngle[3]; //three angles
118 Double_t fRr; // rec position of the vertex
119 Double_t fMinR; // minimum radius in rphi intersection
120 Double_t fDistMinR; // distance at minimal radius
121 Int_t fLab[2]; //MC label of the partecle
122 Float_t fPointAngleFi; //point angle fi
123 Float_t fPointAngleTh; //point angle theta
124 Float_t fPointAngle; //point angle full
125 Int_t fStatus; //status -tracks
126 Int_t fRecStatus; //kink -status- 0 - not found 1-good - fake
127 Int_t fMultiple;
128 Int_t fKinkMultiple;
129 ClassDef(AliESDRecKinkInfo,1) // container for
130};
131
132ClassImp(AliESDRecKinkInfo)
133
134
ae7d73d2 135
136////////////////////////////////////////////////////////////////////////
137//
138// Start of implementation of the class ESDCmpTr
139//
140////////////////////////////////////////////////////////////////////////
141
142class ESDCmpTr {
143
144public:
145 ESDCmpTr();
146 ESDCmpTr(const char* fnGenTracks,
147 const char* fnCmpRes ="cmpTracks.root",
148 const char* fnGalice ="galice.root", Int_t direction=0,
149 Int_t nEvents=1, Int_t firstEvent=0);
150 virtual ~ESDCmpTr();
151 void Reset();
152 Int_t Exec();
153 Int_t Exec(Int_t nEvents, Int_t firstEventNr);
154 Int_t SetIO();
155 Int_t SetIO(Int_t eventNr );
156 void CreateTreeCmp();
157 void CloseOutputFile();
158 Bool_t ConnectGenTree();
159 Int_t TreeGenLoop(Int_t eventNr);
160 Int_t TreeTLoop();
51ad6848 161 Int_t BuildKinkInfo0(Int_t eventNr); // build kink info 0
162 Int_t BuildV0Info(Int_t eventNr); // build kink info 0
ae7d73d2 163 void SetFirstEventNr(Int_t i) {fFirstEventNr = i;}
164 void SetNEvents(Int_t i) {fNEvents = i;}
165 void SetDebug(Int_t level) {fDebug = level;}
166
167// tmp method, should go to TrackReferenceESD
168 static TVector3 TR2Local(AliTrackReference *trackRef,
169 AliTPCParam *paramTPC);
170
171private:
172
173 Int_t fEventNr; //! current event number
174 Int_t fNEvents; //! number of events to process
175 Int_t fFirstEventNr; //! first event to process
176 //
177 char fFnCmp[1000]; //! output file name with cmp tracks
178 TFile *fFileCmp; //! output file with cmp tracks
179 TTree *fTreeCmp; //! output tree with cmp tracks
51ad6848 180 TTree *fTreeCmpKinks; //! output tree with cmp Kinks
181 TTree *fTreeCmpV0; //! output tree with cmp V0
ae7d73d2 182 //
183 char fFnGenTracks[1000]; //! input file name with gen tracks
184 TFile *fFileGenTracks;
185 TTree *fTreeGenTracks;
51ad6848 186 TTree *fTreeGenKinks; // tree with gen kinks
187 TTree *fTreeGenV0; // tree with gen V0
ae7d73d2 188 //
189 //
190 Int_t fDirection;
191 //
192 AliRunLoader * fLoader; //! pointer to the run loader
193 //TTree *fTreeRecTracks; //! tree with reconstructed tracks
194 //
195 Int_t *fIndexRecTracks; //! index of particle label in the TreeT_ESD
196 Int_t *fFakeRecTracks; //! number of fake tracks
197 Int_t *fMultiRecTracks; //! number of multiple reconstructions
198 //
51ad6848 199 Int_t *fIndexRecKinks; //! index of particle label in treeesd
200 Int_t *fMultiRecKinks; //! number of multiple reconstructions
201 Int_t *fSignedKinks; //! indicator that kink was not fake
202 //
203 Int_t *fIndexRecV0; //! index of particle label in treeesd
204 Int_t *fMultiRecV0; //! number of multiple reconstructions
205 Int_t *fSignedV0; //! indicator that kink was not fake
206 //
207 TObjArray *fRecArray; // container with rec infos
ae7d73d2 208 AliESD *fEvent; //!event
ae7d73d2 209 //
210 AliTPCParam* fParamTPC; //! AliTPCParam
211 Int_t fNParticles; //! number of particles in the input tree genTracks
212 Int_t fDebug; //! debug flag
213 Int_t fNextTreeGenEntryToRead; //! last entry already read from genTracks tree
51ad6848 214 Int_t fNextKinkToRead; //! last entry already read from genKinks tree
215 Int_t fNextV0ToRead; //! last entry already read from genV0 tree
ae7d73d2 216 //
217 AliMCInfo* fMCInfo; //! MC information writen per particle
51ad6848 218 AliGenKinkInfo* fGenKinkInfo; //! MC information writen per Kink
219 AliGenV0Info* fGenV0Info; //! MC information writen per Kink
ae7d73d2 220 AliESDRecInfo* fRecInfo; //! Rec. information writen per particle
51ad6848 221 AliESDRecKinkInfo* fRecKinkInfo; //! reconstructed kink info
222 AliESDRecV0Info* fRecV0Info; //! reconstructed kink info
ae7d73d2 223 //
224
225 ClassDef(ESDCmpTr,1) // class which creates and fills tree with ESDGenTrack objects
226};
227ClassImp(ESDCmpTr)
228
229
230