1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
18 #include <Riostream.h>
23 #include "AliTracker.h"
24 #include "AliESDtrack.h"
26 #include "AliTRDgeometry.h"
27 #include "AliTRDcluster.h"
28 #include "AliTRDtrack.h"
29 #include "AliTRDtracklet.h"
33 ///////////////////////////////////////////////////////////////////////////////
35 // Represents a reconstructed TRD track //
36 // Local TRD Kalman track //
38 ///////////////////////////////////////////////////////////////////////////////
40 //_____________________________________________________________________________
41 AliTRDtrack::AliTRDtrack()
59 // AliTRDtrack default constructor
62 for (Int_t i = 0; i < kNplane; i++) {
63 for (Int_t j = 0; j < kNslice; j++) {
64 fdEdxPlane[i][j] = 0.0;
69 for (UInt_t i = 0; i < kMAXCLUSTERSPERTRACK; i++) {
75 for (Int_t i = 0; i < 3; i++) {
81 //_____________________________________________________________________________
82 AliTRDtrack::AliTRDtrack(const AliTRDcluster *c, Int_t index
83 , const Double_t p[5], const Double_t cov[15]
84 , Double_t x, Double_t alpha)
102 // The main AliTRDtrack constructor.
105 Double_t cnv = 1.0/(GetBz() * kB2C);
107 Double_t pp[5] = { p[0]
113 Double_t c22 = x*x*cov[14] - 2*x*cov[12] + cov[5];
114 Double_t c32 = x*cov[13] - cov[8];
115 Double_t c20 = x*cov[10] - cov[3];
116 Double_t c21 = x*cov[11] - cov[4];
117 Double_t c42 = x*cov[14] - cov[12];
119 Double_t cc[15] = { cov[0 ]
122 , cov[6 ], cov[7 ], c32, cov[9 ]
123 , cov[10]*cnv, cov[11]*cnv, c42*cnv, cov[13]*cnv, cov[14]*cnv*cnv };
126 SetNumberOfClusters(1);
129 for (Int_t i = 0; i < kNplane; i++) {
130 for (Int_t j = 0; j < kNslice; j++) {
131 fdEdxPlane[i][j] = 0.0;
133 fTimBinPlane[i] = -1;
136 Double_t q = TMath::Abs(c->GetQ());
137 Double_t s = GetSnp();
138 Double_t t = GetTgl();
140 q *= TMath::Sqrt((1-s*s)/(1+t*t));
145 for (UInt_t i = 1; i < kMAXCLUSTERSPERTRACK; i++) {
151 for (Int_t i = 0; i < 3;i++) {
157 //_____________________________________________________________________________
158 AliTRDtrack::AliTRDtrack(const AliTRDtrack &t)
160 ,fSeedLab(t.GetSeedLabel())
163 ,fStopped(t.fStopped)
166 ,fNRotate(t.fNRotate)
168 ,fNExpected(t.fNExpected)
170 ,fNExpectedLast(t.fNExpectedLast)
172 ,fChi2Last(t.fChi2Last)
179 for (Int_t i = 0; i < kNplane; i++) {
180 for (Int_t j = 0; j < kNslice; j++) {
181 fdEdxPlane[i][j] = t.fdEdxPlane[i][j];
183 fTimBinPlane[i] = t.fTimBinPlane[i];
184 fTracklets[i] = t.fTracklets[i];
187 Int_t n = t.GetNumberOfClusters();
188 SetNumberOfClusters(n);
190 for (Int_t i = 0; i < n; i++) {
191 fIndex[i] = t.fIndex[i];
192 fIndexBackup[i] = t.fIndex[i];
193 fdQdl[i] = t.fdQdl[i];
196 for (UInt_t i = n; i < kMAXCLUSTERSPERTRACK; i++) {
202 for (Int_t i = 0; i < 3;i++) {
203 fBudget[i] = t.fBudget[i];
208 //_____________________________________________________________________________
209 AliTRDtrack::AliTRDtrack(const AliKalmanTrack &t, Double_t /*alpha*/)
212 ,fdEdx(t.GetPIDsignal())
227 // Constructor from AliTPCtrack or AliITStrack
230 SetLabel(t.GetLabel());
232 SetMass(t.GetMass());
233 SetNumberOfClusters(0);
235 for (Int_t i = 0; i < kNplane; i++) {
236 for (Int_t j = 0; j < kNslice; j++) {
237 fdEdxPlane[i][j] = 0.0;
239 fTimBinPlane[i] = -1;
242 for (UInt_t i = 0; i < kMAXCLUSTERSPERTRACK; i++) {
248 for (Int_t i = 0; i < 3; i++) {
254 //_____________________________________________________________________________
255 AliTRDtrack::AliTRDtrack(const AliESDtrack &t)
258 ,fdEdx(t.GetTRDsignal())
273 // Constructor from AliESDtrack
276 SetLabel(t.GetLabel());
278 SetMass(t.GetMass());
279 SetNumberOfClusters(t.GetTRDclusters(fIndex));
281 Int_t ncl = t.GetTRDclusters(fIndexBackup);
282 for (UInt_t i = ncl; i < kMAXCLUSTERSPERTRACK; i++) {
287 for (Int_t i = 0; i < kNplane; i++) {
288 for (Int_t j = 0; j < kNslice; j++) {
289 fdEdxPlane[i][j] = t.GetTRDsignals(i,j);
291 fTimBinPlane[i] = t.GetTRDTimBin(i);
294 const AliExternalTrackParam *par = &t;
295 if (t.GetStatus() & AliESDtrack::kTRDbackup) {
296 par = t.GetOuterParam();
298 AliError("No backup info!");
302 Set(par->GetX(),par->GetAlpha(),par->GetParameter(),par->GetCovariance());
305 for (UInt_t i = 0; i < kMAXCLUSTERSPERTRACK; i++) {
309 for (Int_t i = 0; i < 3; i++) {
313 if ((t.GetStatus() & AliESDtrack::kTIME) == 0) {
319 t.GetIntegratedTimes(times);
320 SetIntegratedTimes(times);
321 SetIntegratedLength(t.GetIntegratedLength());
325 //____________________________________________________________________________
326 AliTRDtrack::~AliTRDtrack()
339 //____________________________________________________________________________
340 Float_t AliTRDtrack::StatusForTOF()
343 // Defines the status of the TOF extrapolation
346 // Definition of res ????
347 Float_t res = (0.2 + 0.8 * (fN / (fNExpected + 5.0)))
348 * (0.4 + 0.6 * fTracklets[5].GetN() / 20.0);
349 res *= (0.25 + 0.8 * 40.0 / (40.0 + fBudget[2]));
352 // This part of the function is never reached ????
353 // What defines these parameters ????
355 if (GetNumberOfClusters() < 20) return 0;
357 (fChi2/(Float_t(fN)) < 3)) return 3; // Gold
359 (fChi2Last/(Float_t(fNLast)) < 3)) return 3; // Gold
361 (fChi2Last/(Float_t(fNLast)) < 2)) return 3; // Gold
362 if ((fNLast/(fNExpectedLast+3.0) > 0.8) &&
363 (fChi2Last/Float_t(fNLast) < 5) &&
364 (fNLast > 20)) return 2; // Silber
366 (((fNLast+1.0)/(fNExpectedLast+1.0)) > 0.8) &&
367 (fChi2Last/(fNLast-5.0) < 6)) return 1;
373 //_____________________________________________________________________________
374 Int_t AliTRDtrack::Compare(const TObject *o) const
377 // Compares tracks according to their Y2 or curvature
380 AliTRDtrack *t = (AliTRDtrack *) o;
382 Double_t co = TMath::Abs(t->GetC());
383 Double_t c = TMath::Abs(GetC());
395 //_____________________________________________________________________________
396 void AliTRDtrack::CookdEdx(Double_t low, Double_t up)
399 // Calculates the truncated dE/dx within the "low" and "up" cuts.
404 // Array to sort the dEdx values according to amplitude
405 Float_t sorted[kMAXCLUSTERSPERTRACK];
407 // Number of clusters used for dedx
410 // Require at least 10 clusters for a dedx measurement
416 // Lower and upper bound
417 Int_t nl = Int_t(low * nc);
418 Int_t nu = Int_t( up * nc);
420 // Can fdQdl be negative ????
421 for (i = 0; i < nc; i++) {
422 sorted[i] = TMath::Abs(fdQdl[i]);
425 // Sort the dedx values by amplitude
426 Int_t *index = new Int_t[nc];
427 TMath::Sort(nc,sorted,index,kFALSE);
429 // Sum up the truncated charge between nl and nu
431 for (i = nl; i <= nu; i++) {
432 dedx += sorted[index[i]];
434 dedx /= (nu - nl + 1.0);
439 //_____________________________________________________________________________
440 Bool_t AliTRDtrack::PropagateTo(Double_t xk, Double_t x0, Double_t rho)
443 // Propagates a track of particle with mass=pm to a reference plane
444 // defined by x=xk through media of density=rho and radiationLength=x0
451 Double_t oldX = GetX();
452 Double_t oldY = GetY();
453 Double_t oldZ = GetZ();
455 Double_t bz = GetBz();
457 if (!AliExternalTrackParam::PropagateTo(xk,bz)) {
464 Double_t d = TMath::Sqrt((x-oldX)*(x-oldX)
466 + (z-oldZ)*(z-oldZ));
468 if (IsStartedTimeIntegral()) {
470 Double_t crv = GetC();
471 if (TMath::Abs(l2*crv) > 0.0001) {
472 // Make correction for curvature if neccesary
473 l2 = 0.5 * TMath::Sqrt((x-oldX)*(x-oldX) + (y-oldY)*(y-oldY));
474 l2 = 2.0 * TMath::ASin(l2 * crv) / crv;
475 l2 = TMath::Sqrt(l2*l2 + (z-oldZ)*(z-oldZ));
481 Double_t ll = (oldX < xk) ? -d : d;
482 if (!AliExternalTrackParam::CorrectForMaterial(ll*rho/x0,x0,GetMass())) {
488 // Energy losses************************
489 Double_t p2 = (1.0 + GetTgl()*GetTgl()) / (Get1Pt()*Get1Pt());
490 Double_t beta2 = p2 / (p2 + GetMass()*GetMass());
491 if (beta2<1.0e-10 || (5940.0 * beta2/(1.0 - beta2 + 1.0e-10) - beta2) < 0.0) {
495 Double_t dE = 0.153e-3 / beta2
496 * (log(5940.0 * beta2/(1.0 - beta2 + 1.0e-10)) - beta2)
498 Float_t budget = d * rho;
499 fBudget[0] += budget;
502 // Suspicious part - think about it ?
503 Double_t kinE = TMath::Sqrt(p2);
504 if (dE > 0.8*kinE) dE = 0.8 * kinE; //
505 if (dE < 0) dE = 0.0; // Not valid region for Bethe bloch
512 Double_t sigmade = 0.07 * TMath::Sqrt(TMath::Abs(dE)); // Energy loss fluctuation
513 Double_t sigmac2 = sigmade*sigmade*fC*fC*(p2+GetMass()*GetMass())/(p2*p2);
515 fCee += fX*fX * sigmac2;
524 //_____________________________________________________________________________
525 Bool_t AliTRDtrack::Update(const AliTRDcluster *c, Double_t chisq, Int_t index
529 // Assignes found cluster to the track and updates track information
532 Bool_t fNoTilt = kTRUE;
533 if (TMath::Abs(h01) > 0.003) {
537 // Add angular effect to the error contribution - MI
538 Float_t tangent2 = GetSnp()*GetSnp();
539 if (tangent2 < 0.90000) {
540 tangent2 = tangent2 / (1.0 - tangent2);
542 //Float_t errang = tangent2 * 0.04;
544 Double_t p[2] = {c->GetY(), c->GetZ() };
545 //Double_t cov[3] = {c->GetSigmaY2()+errang, 0.0, c->GetSigmaZ2()*100.0 };
546 Double_t sy2 = c->GetSigmaY2() * 4.0;
547 Double_t sz2 = c->GetSigmaZ2() * 4.0;
548 Double_t cov[3] = {sy2 + h01*h01*sz2, h01*(sy2-sz2), sz2 + h01*h01*sy2 };
550 if (!AliExternalTrackParam::Update(p,cov)) {
554 Int_t n = GetNumberOfClusters();
556 SetNumberOfClusters(n+1);
558 SetChi2(GetChi2()+chisq);
564 //_____________________________________________________________________________
565 Int_t AliTRDtrack::UpdateMI(const AliTRDcluster *c, Double_t chisq, Int_t index
566 , Double_t h01, Int_t /*plane*/)
569 // Assignes found cluster to the track and updates track information
572 Bool_t fNoTilt = kTRUE;
573 if (TMath::Abs(h01) > 0.003) {
577 // Add angular effect to the error contribution and make correction - MI
578 Double_t tangent2 = GetSnp()*GetSnp();
579 if (tangent2 < 0.90000){
580 tangent2 = tangent2 / (1.0-tangent2);
582 Double_t tangent = TMath::Sqrt(tangent2);
588 // Is the following still needed ????
591 // Double_t correction = 0*plane;
593 Double_t errang = tangent2*0.04; //
594 Double_t errsys =0.025*0.025*20; //systematic error part
597 if (c->GetNPads()==4) extend=2;
599 //if (c->GetNPads()==5) extend=3;
600 //if (c->GetNPads()==6) extend=3;
601 //if (c->GetQ()<15) return 1;
606 correction = corrector->GetCorrection(plane,c->GetLocalTimeBin(),tangent);
607 if (TMath::Abs(correction)>0){
609 errang = corrector->GetSigma(plane,c->GetLocalTimeBin(),tangent);
611 errang += tangent2*0.04;
616 //Double_t padlength = TMath::Sqrt(c->GetSigmaZ2()*12.);
619 Double_t dy=c->GetY() - GetY(), dz=c->GetZ() - GetZ();
620 printf("%e %e %e %e\n",dy,dz,padlength/2,h01);
624 Double_t p[2] = { c->GetY(), c->GetZ() };
625 //Double_t cov[3]={ (c->GetSigmaY2()+errang+errsys)*extend, 0.0, c->GetSigmaZ2()*10000.0 };
626 Double_t sy2 = c->GetSigmaY2() * 4.0;
627 Double_t sz2 = c->GetSigmaZ2() * 4.0;
628 Double_t cov[3] = { sy2 + h01*h01*sz2, h01*(sy2-sz2), sz2 + h01*h01*sy2 };
630 if (!AliExternalTrackParam::Update(p,cov)) {
634 Int_t n = GetNumberOfClusters();
636 SetNumberOfClusters(n+1);
637 SetChi2(GetChi2() + chisq);
643 // //_____________________________________________________________________________
644 // Int_t AliTRDtrack::UpdateMI(const AliTRDtracklet &tracklet)
647 // // Assignes found tracklet to the track and updates track information
649 // // Can this be removed ????
652 // Double_t r00=(tracklet.GetTrackletSigma2()), r01=0., r11= 10000.;
653 // r00+=fCyy; r01+=fCzy; r11+=fCzz;
655 // Double_t det=r00*r11 - r01*r01;
656 // Double_t tmp=r00; r00=r11/det; r11=tmp/det; r01=-r01/det;
659 // Double_t dy=tracklet.GetY() - fY, dz=tracklet.GetZ() - fZ;
662 // Double_t s00 = tracklet.GetTrackletSigma2(); // error pad
663 // Double_t s11 = 100000; // error pad-row
664 // Float_t h01 = tracklet.GetTilt();
666 // // r00 = fCyy + 2*fCzy*h01 + fCzz*h01*h01+s00;
667 // r00 = fCyy + fCzz*h01*h01+s00;
668 // // r01 = fCzy + fCzz*h01;
671 // det = r00*r11 - r01*r01;
673 // tmp=r00; r00=r11/det; r11=tmp/det; r01=-r01/det;
675 // Double_t k00=fCyy*r00+fCzy*r01, k01=fCyy*r01+fCzy*r11;
676 // Double_t k10=fCzy*r00+fCzz*r01, k11=fCzy*r01+fCzz*r11;
677 // Double_t k20=fCey*r00+fCez*r01, k21=fCey*r01+fCez*r11;
678 // Double_t k30=fCty*r00+fCtz*r01, k31=fCty*r01+fCtz*r11;
679 // Double_t k40=fCcy*r00+fCcz*r01, k41=fCcy*r01+fCcz*r11;
682 // // k00=fCyy*r00+fCzy*(r01+h01*r00),k01=fCyy*r01+fCzy*(r11+h01*r01);
683 // // k10=fCzy*r00+fCzz*(r01+h01*r00),k11=fCzy*r01+fCzz*(r11+h01*r01);
684 // // k20=fCey*r00+fCez*(r01+h01*r00),k21=fCey*r01+fCez*(r11+h01*r01);
685 // // k30=fCty*r00+fCtz*(r01+h01*r00),k31=fCty*r01+fCtz*(r11+h01*r01);
686 // // k40=fCcy*r00+fCcz*(r01+h01*r00),k41=fCcy*r01+fCcz*(r11+h01*r01);
688 // //Update measurement
689 // Double_t cur=fC + k40*dy + k41*dz, eta=fE + k20*dy + k21*dz;
690 // // cur=fC + k40*dy + k41*dz; eta=fE + k20*dy + k21*dz;
691 // if (TMath::Abs(cur*fX-eta) >= 0.90000) {
692 // //Int_t n=GetNumberOfClusters();
693 // // if (n>4) cerr<<n<<" AliTRDtrack warning: Filtering failed !\n";
703 // fY += k00*dy + k01*dz;
704 // fZ += k10*dy + k11*dz;
706 // fT += k30*dy + k31*dz;
710 // //Update covariance
713 // Double_t oldyy = fCyy, oldzz = fCzz; //, oldee=fCee, oldcc =fCcc;
714 // Double_t oldzy = fCzy, oldey = fCey, oldty=fCty, oldcy =fCcy;
715 // Double_t oldez = fCez, oldtz = fCtz, oldcz=fCcz;
716 // //Double_t oldte = fCte, oldce = fCce;
717 // //Double_t oldct = fCct;
719 // fCyy-=k00*oldyy+k01*oldzy;
720 // fCzy-=k10*oldyy+k11*oldzy;
721 // fCey-=k20*oldyy+k21*oldzy;
722 // fCty-=k30*oldyy+k31*oldzy;
723 // fCcy-=k40*oldyy+k41*oldzy;
725 // fCzz-=k10*oldzy+k11*oldzz;
726 // fCez-=k20*oldzy+k21*oldzz;
727 // fCtz-=k30*oldzy+k31*oldzz;
728 // fCcz-=k40*oldzy+k41*oldzz;
730 // fCee-=k20*oldey+k21*oldez;
731 // fCte-=k30*oldey+k31*oldez;
732 // fCce-=k40*oldey+k41*oldez;
734 // fCtt-=k30*oldty+k31*oldtz;
735 // fCct-=k40*oldty+k41*oldtz;
737 // fCcc-=k40*oldcy+k41*oldcz;
740 // //Int_t n=GetNumberOfClusters();
741 // //fIndex[n]=index;
742 // //SetNumberOfClusters(n+1);
744 // //SetChi2(GetChi2()+chisq);
745 // // cerr<<"in update: fIndex["<<fN<<"] = "<<index<<endl;
751 //_____________________________________________________________________________
752 Bool_t AliTRDtrack::Rotate(Double_t alpha, Bool_t absolute)
755 // Rotates track parameters in R*phi plane
756 // if absolute rotation alpha is in global system
757 // otherwise alpha rotation is relative to the current rotation angle
767 return AliExternalTrackParam::Rotate(GetAlpha()+alpha);
771 //_____________________________________________________________________________
772 Double_t AliTRDtrack::GetPredictedChi2(const AliTRDcluster *c, Double_t h01) const
775 // Returns the track chi2
778 Double_t p[2] = { c->GetY(), c->GetZ() };
779 Double_t sy2 = c->GetSigmaY2() * 4.0;
780 Double_t sz2 = c->GetSigmaZ2() * 4.0;
781 Double_t cov[3] = { sy2 + h01*h01*sz2, h01*(sy2-sz2), sz2 + h01*h01*sy2 };
783 return AliExternalTrackParam::GetPredictedChi2(p,cov);
786 // Can the following be removed ????
789 Bool_t fNoTilt = kTRUE;
790 if(TMath::Abs(h01) > 0.003) fNoTilt = kFALSE;
792 return (c->GetY() - GetY())*(c->GetY() - GetY())/c->GetSigmaY2();
796 Double_t chi2, dy, r00, r01, r11;
804 Double_t padlength = TMath::Sqrt(c->GetSigmaZ2()*12);
806 r00=c->GetSigmaY2(); r01=0.; r11=c->GetSigmaZ2();
807 r00+=fCyy; r01+=fCzy; r11+=fCzz;
809 Double_t det=r00*r11 - r01*r01;
810 if (TMath::Abs(det) < 1.e-10) {
811 Int_t n=GetNumberOfClusters();
812 if (n>4) cerr<<n<<" AliTRDtrack warning: Singular matrix !\n";
815 Double_t tmp=r00; r00=r11; r11=tmp; r01=-r01;
816 Double_t dy=c->GetY() - fY, dz=c->GetZ() - fZ;
817 Double_t tiltdz = dz;
818 if (TMath::Abs(tiltdz)>padlength/2.) {
819 tiltdz = TMath::Sign(padlength/2,dz);
824 chi2 = (dy*r00*dy + 2*r01*dy*dz + dz*r11*dz)/det;
832 //_____________________________________________________________________________
833 void AliTRDtrack::MakeBackupTrack()
836 // Creates a backup track
842 fBackupTrack = new AliTRDtrack(*this);
846 //_____________________________________________________________________________
847 Int_t AliTRDtrack::GetProlongation(Double_t xk, Double_t &y, Double_t &z)
850 // Find a prolongation at given x
851 // Return 0 if it does not exist
854 Double_t bz = GetBz();
856 if (!AliExternalTrackParam::GetYAt(xk,bz,y)) {
859 if (!AliExternalTrackParam::GetZAt(xk,bz,z)) {
867 //_____________________________________________________________________________
868 Int_t AliTRDtrack::PropagateToX(Double_t xr, Double_t step)
871 // Propagate track to given x position
872 // Works inside of the 20 degree segmentation (local cooordinate frame for TRD , TPC, TOF)
874 // Material budget from geo manager
882 const Double_t kAlphac = TMath::Pi()/9.0;
883 const Double_t kTalphac = TMath::Tan(kAlphac*0.5);
885 // Critical alpha - cross sector indication
886 Double_t dir = (GetX()>xr) ? -1.0 : 1.0;
889 for (Double_t x = GetX()+dir*step; dir*x < dir*xr; x += dir*step) {
892 GetProlongation(x,y,z);
893 xyz1[0] = x * TMath::Cos(GetAlpha()) + y * TMath::Sin(GetAlpha());
894 xyz1[1] = x * TMath::Sin(GetAlpha()) - y * TMath::Cos(GetAlpha());
897 AliKalmanTrack::MeanMaterialBudget(xyz0,xyz1,param);
899 if ((param[0] > 0) &&
901 PropagateTo(x,param[1],param[0]);
904 if (GetY() > GetX()*kTalphac) {
907 if (GetY() < -GetX()*kTalphac) {
919 //_____________________________________________________________________________
920 Int_t AliTRDtrack::PropagateToR(Double_t r,Double_t step)
923 // Propagate track to the radial position
924 // Rotation always connected to the last track position
932 Double_t radius = TMath::Sqrt(GetX()*GetX() + GetY()*GetY());
934 Double_t dir = (radius>r) ? -1.0 : 1.0;
936 for (Double_t x = radius+dir*step; dir*x < dir*r; x += dir*step) {
939 Double_t alpha = TMath::ATan2(xyz0[1],xyz0[0]);
942 GetProlongation(x,y,z);
943 xyz1[0] = x * TMath::Cos(alpha) + y * TMath::Sin(alpha);
944 xyz1[1] = x * TMath::Sin(alpha) - y * TMath::Cos(alpha);
947 AliKalmanTrack::MeanMaterialBudget(xyz0,xyz1,param);
949 param[1] = 100000000;
951 PropagateTo(x,param[1],param[0]);
956 Double_t alpha = TMath::ATan2(xyz0[1],xyz0[0]);
959 GetProlongation(r,y,z);
960 xyz1[0] = r * TMath::Cos(alpha) + y * TMath::Sin(alpha);
961 xyz1[1] = r * TMath::Sin(alpha) - y * TMath::Cos(alpha);
964 AliKalmanTrack::MeanMaterialBudget(xyz0,xyz1,param);
967 param[1] = 100000000;
969 PropagateTo(r,param[1],param[0]);
975 //_____________________________________________________________________________
976 Int_t AliTRDtrack::GetSector() const
979 // Return the current sector
982 return Int_t(TVector2::Phi_0_2pi(GetAlpha()) / AliTRDgeometry::GetAlpha())
983 % AliTRDgeometry::kNsect;
987 //_____________________________________________________________________________
988 void AliTRDtrack::SetSampledEdx(Float_t q, Int_t i)
991 // The sampled energy loss
994 Double_t s = GetSnp();
995 Double_t t = GetTgl();
996 q *= TMath::Sqrt((1.0 - s*s) / (1.0 + t*t));
1001 //_____________________________________________________________________________
1002 void AliTRDtrack::SetSampledEdx(Float_t q)
1005 // The sampled energy loss
1008 Double_t s = GetSnp();
1009 Double_t t = GetTgl();
1010 q *= TMath::Sqrt((1.0 - s*s) / (1.0 + t*t));
1016 //_____________________________________________________________________________
1017 Double_t AliTRDtrack::GetBz() const
1020 // Returns Bz component of the magnetic field (kG)
1023 if (AliTracker::UniformField()) {
1024 return AliTracker::GetBz();
1029 return AliTracker::GetBz(r);