Forgotten: in reconstruct to get branchname from RunLoader. Clean of the task is...
[u/mrichter/AliRoot.git] / STEER / AliESDtrack.cxx
CommitLineData
ae982df3 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 **************************************************************************/
ae982df3 15//-----------------------------------------------------------------
16// Implementation of the ESD track class
4427806c 17// ESD = Event Summary Data
ae982df3 18// This is the class to deal with during the phisical analysis of data
4427806c 19// Origin: Iouri Belikov, CERN
20// e-mail: Jouri.Belikov@cern.ch
ae982df3 21//-----------------------------------------------------------------
22
23#include "TMath.h"
24
25#include "AliESDtrack.h"
26#include "AliKalmanTrack.h"
27
28ClassImp(AliESDtrack)
29
30//_______________________________________________________________________
31AliESDtrack::AliESDtrack() :
2bad268c 32fFlags(0),
33fLabel(0),
34fTrackLength(0),
35fStopVertex(0),
36fRalpha(0),
37fRx(0),
a866ac60 38fCalpha(0),
39fCx(0),
67c3dcbe 40fCchi2(1e10),
a866ac60 41fIalpha(0),
42fIx(0),
43fOalpha(0),
44fOx(0),
2bad268c 45fITSchi2(0),
ae982df3 46fITSncls(0),
2bad268c 47fITSsignal(0),
2bad268c 48fTPCchi2(0),
05e445cd 49fTPCncls(0),
a866ac60 50fTPCClusterMap(159),//number of padrows
2bad268c 51fTPCsignal(0),
52fTRDchi2(0),
53fTRDncls(0),
54fTRDsignal(0),
55fTOFchi2(0),
56fTOFindex(0),
4a78b8c5 57fTOFsignal(-1),
58fPHOSsignal(-1),
59fRICHsignal(-1)
ae982df3 60{
61 //
62 // The default ESD constructor
63 //
2bad268c 64 for (Int_t i=0; i<kSPECIES; i++) {
4a78b8c5 65 fTrackTime[i]=0.;
66 fR[i]=1.;
67 fITSr[i]=1.;
68 fTPCr[i]=1.;
69 fTRDr[i]=1.;
70 fTOFr[i]=1.;
4a78b8c5 71 fRICHr[i]=1.;
2bad268c 72 }
ac2f7574 73
74 for (Int_t i=0; i<kSPECIESN; i++)
75 fPHOSr[i]= 1.;
76
4a78b8c5 77 fPHOSpos[0]=fPHOSpos[1]=fPHOSpos[2]=0.;
bb2ceb1f 78 Int_t i;
a866ac60 79 for (i=0; i<5; i++) { fRp[i]=0.; fCp[i]=0.; fIp[i]=0.; fOp[i]=0.;}
80 for (i=0; i<15; i++) { fRc[i]=0.; fCc[i]=0.; fIc[i]=0.; fOc[i]=0.; }
81 for (i=0; i<6; i++) { fITSindex[i]=0; }
82 for (i=0; i<180; i++){ fTPCindex[i]=0; }
83 for (i=0; i<90; i++) { fTRDindex[i]=0; }
6e5b1b04 84 fTPCLabel = 0;
85 fTRDLabel = 0;
86 fITSLabel = 0;
ac2f7574 87
ae982df3 88}
89
90//_______________________________________________________________________
4a78b8c5 91Double_t AliESDtrack::GetMass() const {
4427806c 92 // Returns the mass of the most probable particle type
ae982df3 93 Float_t max=0.;
94 Int_t k=-1;
95 for (Int_t i=0; i<kSPECIES; i++) {
96 if (fR[i]>max) {k=i; max=fR[i];}
97 }
98 if (k==0) return 0.00051;
99 if (k==1) return 0.10566;
100 if (k==2||k==-1) return 0.13957;
101 if (k==3) return 0.49368;
102 if (k==4) return 0.93827;
103 Warning("GetMass()","Undefined mass !");
104 return 0.13957;
105}
106
107//_______________________________________________________________________
ad2f1f2b 108Bool_t AliESDtrack::UpdateTrackParams(AliKalmanTrack *t, ULong_t flags) {
ae982df3 109 //
110 // This function updates track's running parameters
111 //
9b859005 112 SetStatus(flags);
113 fLabel=t->GetLabel();
114
115 if (t->IsStartedTimeIntegral()) {
116 SetStatus(kTIME);
117 Double_t times[10];t->GetIntegratedTimes(times); SetIntegratedTimes(times);
118 SetIntegratedLength(t->GetIntegratedLength());
119 }
120
121 fRalpha=t->GetAlpha();
122 t->GetExternalParameters(fRx,fRp);
123 t->GetExternalCovariance(fRc);
124
ae982df3 125 switch (flags) {
ad2f1f2b 126
9b859005 127 case kITSin: case kITSout: case kITSrefit:
ae982df3 128 fITSncls=t->GetNumberOfClusters();
129 fITSchi2=t->GetChi2();
130 for (Int_t i=0;i<fITSncls;i++) fITSindex[i]=t->GetClusterIndex(i);
131 fITSsignal=t->GetPIDsignal();
6e5b1b04 132 fITSLabel = t->GetLabel();
babd135a 133 fITSFakeRatio = t->GetFakeRatio();
ae982df3 134 break;
ad2f1f2b 135
9b859005 136 case kTPCin: case kTPCrefit:
6e5b1b04 137 fTPCLabel = t->GetLabel();
9b859005 138 fIalpha=fRalpha;
139 fIx=fRx;
140 {
141 Int_t i;
142 for (i=0; i<5; i++) fIp[i]=fRp[i];
143 for (i=0; i<15;i++) fIc[i]=fRc[i];
144 }
145 case kTPCout:
a866ac60 146
ae982df3 147 fTPCncls=t->GetNumberOfClusters();
148 fTPCchi2=t->GetChi2();
a866ac60 149
150 {//prevrow must be declared in separate namespace, otherwise compiler cries:
151 //"jump to case label crosses initialization of `Int_t prevrow'"
152 Int_t prevrow = -1;
6e5b1b04 153 // for (Int_t i=0;i<fTPCncls;i++)
154 for (Int_t i=0;i<160;i++)
a866ac60 155 {
156 fTPCindex[i]=t->GetClusterIndex(i);
157
158 // Piotr's Cluster Map for HBT
159 // ### please change accordingly if cluster array is changing
160 // to "New TPC Tracking" style (with gaps in array)
161 Int_t idx = fTPCindex[i];
162 Int_t sect = (idx&0xff000000)>>24;
163 Int_t row = (idx&0x00ff0000)>>16;
164 if (sect > 18) row +=63; //if it is outer sector, add number of inner sectors
165
166 fTPCClusterMap.SetBitNumber(row,kTRUE);
167
168 //Fill the gap between previous row and this row with 0 bits
169 //In case ### pleas change it as well - just set bit 0 in case there
170 //is no associated clusters for current "i"
171 if (prevrow < 0)
172 {
173 prevrow = row;//if previous bit was not assigned yet == this is the first one
174 }
175 else
176 { //we don't know the order (inner to outer or reverse)
177 //just to be save in case it is going to change
178 Int_t n = 0, m = 0;
179 if (prevrow < row)
180 {
181 n = prevrow;
182 m = row;
183 }
184 else
185 {
186 n = row;
187 m = prevrow;
188 }
189
190 for (Int_t j = n+1; j < m; j++)
191 {
192 fTPCClusterMap.SetBitNumber(j,kFALSE);
193 }
194 prevrow = row;
195 }
196 // End Of Piotr's Cluster Map for HBT
197 }
198 }
ae982df3 199 fTPCsignal=t->GetPIDsignal();
200 {Double_t mass=t->GetMass(); // preliminary mass setting
201 if (mass>0.5) fR[4]=1.; // used by
202 else if (mass<0.4) fR[2]=1.; // the ITS reconstruction
a866ac60 203 else fR[3]=1.;}
204 //
ae982df3 205 break;
9b859005 206
672b5f43 207 case kTRDout:
208 { //requested by the PHOS ("temporary solution")
258fa377 209 Double_t r=460.;
e964f790 210 if (t->PropagateTo(r,30.,0.)) {
211 fOalpha=t->GetAlpha();
212 t->GetExternalParameters(fOx,fOp);
213 t->GetExternalCovariance(fOc);
214 }
672b5f43 215 }
5bc70ad8 216 case kTOFin:
217 break;
218 case kTOFout:
219 break;
672b5f43 220 case kTRDin: case kTRDrefit:
6e5b1b04 221 fTRDLabel = t->GetLabel();
222
79e94bf8 223 fTRDncls=t->GetNumberOfClusters();
224 fTRDchi2=t->GetChi2();
bb2ceb1f 225 for (Int_t i=0;i<fTRDncls;i++) fTRDindex[i]=t->GetClusterIndex(i);
79e94bf8 226 fTRDsignal=t->GetPIDsignal();
227 break;
d0862fea 228 case kTRDStop:
229 break;
ae982df3 230 default:
231 Error("UpdateTrackParams()","Wrong flag !\n");
232 return kFALSE;
233 }
234
ae982df3 235 return kTRUE;
236}
237
67c3dcbe 238//_______________________________________________________________________
239void
240AliESDtrack::SetConstrainedTrackParams(AliKalmanTrack *t, Double_t chi2) {
241 //
242 // This function sets the constrained track parameters
243 //
244 fCalpha=t->GetAlpha();
245 t->GetExternalParameters(fCx,fCp);
246 t->GetExternalCovariance(fCc);
247 fCchi2=chi2;
248}
249
250
ae982df3 251//_______________________________________________________________________
252void AliESDtrack::GetExternalParameters(Double_t &x, Double_t p[5]) const {
253 //---------------------------------------------------------------------
254 // This function returns external representation of the track parameters
255 //---------------------------------------------------------------------
256 x=fRx;
257 for (Int_t i=0; i<5; i++) p[i]=fRp[i];
258}
67c3dcbe 259//_______________________________________________________________________
a866ac60 260void AliESDtrack::GetExternalCovariance(Double_t cov[15]) const {
67c3dcbe 261 //---------------------------------------------------------------------
262 // This function returns external representation of the cov. matrix
263 //---------------------------------------------------------------------
a866ac60 264 for (Int_t i=0; i<15; i++) cov[i]=fRc[i];
67c3dcbe 265}
266
267
268//_______________________________________________________________________
269void
270AliESDtrack::GetConstrainedExternalParameters(Double_t &x, Double_t p[5])const{
271 //---------------------------------------------------------------------
272 // This function returns the constrained external track parameters
273 //---------------------------------------------------------------------
274 x=fCx;
275 for (Int_t i=0; i<5; i++) p[i]=fCp[i];
276}
277//_______________________________________________________________________
278void
279AliESDtrack::GetConstrainedExternalCovariance(Double_t c[15]) const {
280 //---------------------------------------------------------------------
281 // This function returns the constrained external cov. matrix
282 //---------------------------------------------------------------------
283 for (Int_t i=0; i<15; i++) c[i]=fCc[i];
284}
285
ae982df3 286
287Double_t AliESDtrack::GetP() const {
288 //---------------------------------------------------------------------
289 // This function returns the track momentum
290 //---------------------------------------------------------------------
2157f4f2 291 if (TMath::Abs(fRp[4])<=0) return 0;
ae982df3 292 Double_t pt=1./TMath::Abs(fRp[4]);
5bc70ad8 293 return pt*TMath::Sqrt(1.+ fRp[3]*fRp[3]);
ae982df3 294}
295
67c3dcbe 296void AliESDtrack::GetConstrainedPxPyPz(Double_t *p) const {
297 //---------------------------------------------------------------------
298 // This function returns the constrained global track momentum components
299 //---------------------------------------------------------------------
2157f4f2 300 if (TMath::Abs(fCp[4])<=0) {
301 p[0]=p[1]=p[2]=0;
302 return;
303 }
67c3dcbe 304 Double_t phi=TMath::ASin(fCp[2]) + fCalpha;
305 Double_t pt=1./TMath::Abs(fCp[4]);
306 p[0]=pt*TMath::Cos(phi); p[1]=pt*TMath::Sin(phi); p[2]=pt*fCp[3];
307}
308void AliESDtrack::GetConstrainedXYZ(Double_t *xyz) const {
309 //---------------------------------------------------------------------
310 // This function returns the global track position
311 //---------------------------------------------------------------------
312 Double_t phi=TMath::ATan2(fCp[0],fCx) + fCalpha;
313 Double_t r=TMath::Sqrt(fCx*fCx + fCp[0]*fCp[0]);
314 xyz[0]=r*TMath::Cos(phi); xyz[1]=r*TMath::Sin(phi); xyz[2]=fCp[1];
315}
316
ae982df3 317void AliESDtrack::GetPxPyPz(Double_t *p) const {
318 //---------------------------------------------------------------------
319 // This function returns the global track momentum components
320 //---------------------------------------------------------------------
2157f4f2 321 if (TMath::Abs(fRp[4])<=0) {
322 p[0]=p[1]=p[2]=0;
323 return;
324 }
ae982df3 325 Double_t phi=TMath::ASin(fRp[2]) + fRalpha;
326 Double_t pt=1./TMath::Abs(fRp[4]);
327 p[0]=pt*TMath::Cos(phi); p[1]=pt*TMath::Sin(phi); p[2]=pt*fRp[3];
328}
ae982df3 329void AliESDtrack::GetXYZ(Double_t *xyz) const {
330 //---------------------------------------------------------------------
331 // This function returns the global track position
332 //---------------------------------------------------------------------
bb2ceb1f 333 Double_t phi=TMath::ATan2(fRp[0],fRx) + fRalpha;
ae982df3 334 Double_t r=TMath::Sqrt(fRx*fRx + fRp[0]*fRp[0]);
335 xyz[0]=r*TMath::Cos(phi); xyz[1]=r*TMath::Sin(phi); xyz[2]=fRp[1];
336}
337
67c3dcbe 338
9b859005 339void AliESDtrack::GetInnerPxPyPz(Double_t *p) const {
340 //---------------------------------------------------------------------
341 // This function returns the global track momentum components
342 // af the entrance of the TPC
343 //---------------------------------------------------------------------
e964f790 344 if (fIx==0) {p[0]=p[1]=p[2]=0.; return;}
9b859005 345 Double_t phi=TMath::ASin(fIp[2]) + fIalpha;
346 Double_t pt=1./TMath::Abs(fIp[4]);
347 p[0]=pt*TMath::Cos(phi); p[1]=pt*TMath::Sin(phi); p[2]=pt*fIp[3];
348}
349
350void AliESDtrack::GetInnerXYZ(Double_t *xyz) const {
351 //---------------------------------------------------------------------
352 // This function returns the global track position
353 // af the entrance of the TPC
354 //---------------------------------------------------------------------
e964f790 355 if (fIx==0) {xyz[0]=xyz[1]=xyz[2]=0.; return;}
9b859005 356 Double_t phi=TMath::ATan2(fIp[0],fIx) + fIalpha;
357 Double_t r=TMath::Sqrt(fIx*fIx + fIp[0]*fIp[0]);
358 xyz[0]=r*TMath::Cos(phi); xyz[1]=r*TMath::Sin(phi); xyz[2]=fIp[1];
359}
360
a866ac60 361void AliESDtrack::GetInnerExternalParameters(Double_t &x, Double_t p[5]) const
362{
363 //skowron
364 //---------------------------------------------------------------------
365 // This function returns external representation of the track parameters at Inner Layer of TPC
366 //---------------------------------------------------------------------
367 x=fIx;
368 for (Int_t i=0; i<5; i++) p[i]=fIp[i];
369}
370void AliESDtrack::GetInnerExternalCovariance(Double_t cov[15]) const
371{
372 //skowron
373 //---------------------------------------------------------------------
374 // This function returns external representation of the cov. matrix at Inner Layer of TPC
375 //---------------------------------------------------------------------
376 for (Int_t i=0; i<15; i++) cov[i]=fIc[i];
377
378}
379
672b5f43 380void AliESDtrack::GetOuterPxPyPz(Double_t *p) const {
381 //---------------------------------------------------------------------
382 // This function returns the global track momentum components
383 // af the radius of the PHOS
384 //---------------------------------------------------------------------
e964f790 385 if (fOx==0) {p[0]=p[1]=p[2]=0.; return;}
672b5f43 386 Double_t phi=TMath::ASin(fOp[2]) + fOalpha;
387 Double_t pt=1./TMath::Abs(fOp[4]);
388 p[0]=pt*TMath::Cos(phi); p[1]=pt*TMath::Sin(phi); p[2]=pt*fOp[3];
389}
390
391void AliESDtrack::GetOuterXYZ(Double_t *xyz) const {
392 //---------------------------------------------------------------------
393 // This function returns the global track position
394 // af the radius of the PHOS
395 //---------------------------------------------------------------------
e964f790 396 if (fOx==0) {xyz[0]=xyz[1]=xyz[2]=0.; return;}
672b5f43 397 Double_t phi=TMath::ATan2(fOp[0],fOx) + fOalpha;
398 Double_t r=TMath::Sqrt(fOx*fOx + fOp[0]*fOp[0]);
399 xyz[0]=r*TMath::Cos(phi); xyz[1]=r*TMath::Sin(phi); xyz[2]=fOp[1];
400}
401
ae982df3 402//_______________________________________________________________________
403void AliESDtrack::GetIntegratedTimes(Double_t *times) const {
4427806c 404 // Returns the array with integrated times for each particle hypothesis
ae982df3 405 for (Int_t i=0; i<kSPECIES; i++) times[i]=fTrackTime[i];
406}
407
408//_______________________________________________________________________
409void AliESDtrack::SetIntegratedTimes(const Double_t *times) {
4427806c 410 // Sets the array with integrated times for each particle hypotesis
ae982df3 411 for (Int_t i=0; i<kSPECIES; i++) fTrackTime[i]=times[i];
412}
413
c630aafd 414//_______________________________________________________________________
4427806c 415void AliESDtrack::SetITSpid(const Double_t *p) {
416 // Sets values for the probability of each particle type (in ITS)
c630aafd 417 for (Int_t i=0; i<kSPECIES; i++) fITSr[i]=p[i];
418 SetStatus(AliESDtrack::kITSpid);
419}
420
babd135a 421void AliESDtrack::SetITSChi2MIP(const Float_t *chi2mip){
422 for (Int_t i=0; i<6; i++) fITSchi2MIP[i]=chi2mip[i];
423}
c630aafd 424//_______________________________________________________________________
425void AliESDtrack::GetITSpid(Double_t *p) const {
4427806c 426 // Gets the probability of each particle type (in ITS)
c630aafd 427 for (Int_t i=0; i<kSPECIES; i++) p[i]=fITSr[i];
428}
429
ae982df3 430//_______________________________________________________________________
431Int_t AliESDtrack::GetITSclusters(UInt_t *idx) const {
432 //---------------------------------------------------------------------
433 // This function returns indices of the assgined ITS clusters
434 //---------------------------------------------------------------------
435 for (Int_t i=0; i<fITSncls; i++) idx[i]=fITSindex[i];
436 return fITSncls;
437}
438
439//_______________________________________________________________________
05e445cd 440Int_t AliESDtrack::GetTPCclusters(Int_t *idx) const {
ae982df3 441 //---------------------------------------------------------------------
442 // This function returns indices of the assgined ITS clusters
443 //---------------------------------------------------------------------
d1420ddf 444 if (idx!=0)
445 for (Int_t i=0; i<180; i++) idx[i]=fTPCindex[i]; // MI I prefer some constant
ae982df3 446 return fTPCncls;
447}
8c6a71ab 448
449//_______________________________________________________________________
450void AliESDtrack::SetTPCpid(const Double_t *p) {
4427806c 451 // Sets values for the probability of each particle type (in TPC)
8c6a71ab 452 for (Int_t i=0; i<kSPECIES; i++) fTPCr[i]=p[i];
453 SetStatus(AliESDtrack::kTPCpid);
454}
455
456//_______________________________________________________________________
457void AliESDtrack::GetTPCpid(Double_t *p) const {
4427806c 458 // Gets the probability of each particle type (in TPC)
8c6a71ab 459 for (Int_t i=0; i<kSPECIES; i++) p[i]=fTPCr[i];
460}
461
bb2ceb1f 462//_______________________________________________________________________
463Int_t AliESDtrack::GetTRDclusters(UInt_t *idx) const {
464 //---------------------------------------------------------------------
465 // This function returns indices of the assgined TRD clusters
466 //---------------------------------------------------------------------
d1420ddf 467 if (idx!=0)
468 for (Int_t i=0; i<90; i++) idx[i]=fTRDindex[i]; // MI I prefer some constant
bb2ceb1f 469 return fTRDncls;
470}
471
c630aafd 472//_______________________________________________________________________
473void AliESDtrack::SetTRDpid(const Double_t *p) {
4427806c 474 // Sets values for the probability of each particle type (in TRD)
c630aafd 475 for (Int_t i=0; i<kSPECIES; i++) fTRDr[i]=p[i];
476 SetStatus(AliESDtrack::kTRDpid);
477}
478
479//_______________________________________________________________________
480void AliESDtrack::GetTRDpid(Double_t *p) const {
4427806c 481 // Gets the probability of each particle type (in TRD)
c630aafd 482 for (Int_t i=0; i<kSPECIES; i++) p[i]=fTRDr[i];
483}
484
79e94bf8 485//_______________________________________________________________________
486void AliESDtrack::SetTRDpid(Int_t iSpecies, Float_t p)
487{
4427806c 488 // Sets the probability of particle type iSpecies to p (in TRD)
79e94bf8 489 fTRDr[iSpecies] = p;
490}
491
492Float_t AliESDtrack::GetTRDpid(Int_t iSpecies) const
493{
4427806c 494 // Returns the probability of particle type iSpecies (in TRD)
79e94bf8 495 return fTRDr[iSpecies];
496}
497
c630aafd 498//_______________________________________________________________________
499void AliESDtrack::SetTOFpid(const Double_t *p) {
4427806c 500 // Sets the probability of each particle type (in TOF)
c630aafd 501 for (Int_t i=0; i<kSPECIES; i++) fTOFr[i]=p[i];
502 SetStatus(AliESDtrack::kTOFpid);
503}
504
505//_______________________________________________________________________
506void AliESDtrack::GetTOFpid(Double_t *p) const {
4427806c 507 // Gets probabilities of each particle type (in TOF)
c630aafd 508 for (Int_t i=0; i<kSPECIES; i++) p[i]=fTOFr[i];
509}
510
4a78b8c5 511
512
513//_______________________________________________________________________
514void AliESDtrack::SetPHOSpid(const Double_t *p) {
515 // Sets the probability of each particle type (in PHOS)
ac2f7574 516 for (Int_t i=0; i<kSPECIESN; i++) fPHOSr[i]=p[i];
4a78b8c5 517 SetStatus(AliESDtrack::kPHOSpid);
518}
519
520//_______________________________________________________________________
521void AliESDtrack::GetPHOSpid(Double_t *p) const {
522 // Gets probabilities of each particle type (in PHOS)
ac2f7574 523 for (Int_t i=0; i<kSPECIESN; i++) p[i]=fPHOSr[i];
4a78b8c5 524}
525
526
527//_______________________________________________________________________
528void AliESDtrack::SetRICHpid(const Double_t *p) {
529 // Sets the probability of each particle type (in RICH)
530 for (Int_t i=0; i<kSPECIES; i++) fRICHr[i]=p[i];
531 SetStatus(AliESDtrack::kRICHpid);
532}
533
534//_______________________________________________________________________
535void AliESDtrack::GetRICHpid(Double_t *p) const {
536 // Gets probabilities of each particle type (in RICH)
537 for (Int_t i=0; i<kSPECIES; i++) p[i]=fRICHr[i];
538}
539
540
541
8c6a71ab 542//_______________________________________________________________________
543void AliESDtrack::SetESDpid(const Double_t *p) {
4427806c 544 // Sets the probability of each particle type for the ESD track
8c6a71ab 545 for (Int_t i=0; i<kSPECIES; i++) fR[i]=p[i];
546 SetStatus(AliESDtrack::kESDpid);
547}
548
549//_______________________________________________________________________
550void AliESDtrack::GetESDpid(Double_t *p) const {
4427806c 551 // Gets probability of each particle type for the ESD track
8c6a71ab 552 for (Int_t i=0; i<kSPECIES; i++) p[i]=fR[i];
553}
554
ac2f7574 555//_______________________________________________________________________
556void AliESDtrack::Print(Option_t *) const {
557 // Prints info on the track
558
559 Info("Print","Track info") ;
560 Double_t p[kSPECIESN] ;
561 Int_t index = 0 ;
562 if( IsOn(kITSpid) ){
563 printf("From ITS: ") ;
564 GetITSpid(p) ;
565 for(index = 0 ; index < kSPECIES; index++)
566 printf("%f, ", p[index]) ;
567 printf("\n signal = %f\n", GetITSsignal()) ;
568 }
569 if( IsOn(kTPCpid) ){
570 printf("From TPC: ") ;
571 GetTPCpid(p) ;
572 for(index = 0 ; index < kSPECIES; index++)
573 printf("%f, ", p[index]) ;
574 printf("\n signal = %f\n", GetTPCsignal()) ;
575 }
576 if( IsOn(kTRDpid) ){
577 printf("From TRD: ") ;
578 GetTRDpid(p) ;
579 for(index = 0 ; index < kSPECIES; index++)
580 printf("%f, ", p[index]) ;
581 printf("\n signal = %f\n", GetTRDsignal()) ;
582 }
583 if( IsOn(kTOFpid) ){
584 printf("From TOF: ") ;
585 GetTOFpid(p) ;
586 for(index = 0 ; index < kSPECIES; index++)
587 printf("%f, ", p[index]) ;
588 printf("\n signal = %f\n", GetTOFsignal()) ;
589 }
590 if( IsOn(kRICHpid) ){
591 printf("From TOF: ") ;
592 GetRICHpid(p) ;
593 for(index = 0 ; index < kSPECIES; index++)
594 printf("%f, ", p[index]) ;
595 printf("\n signal = %f\n", GetRICHsignal()) ;
596 }
597 if( IsOn(kPHOSpid) ){
598 printf("From PHOS: ") ;
599 GetPHOSpid(p) ;
600 for(index = 0 ; index < kSPECIESN; index++)
601 printf("%f, ", p[index]) ;
602 printf("\n signal = %f\n", GetPHOSsignal()) ;
603 }
604}