4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
7 //----------------------------------------------------------------------------//
9 // Description: class for handling ESD extracted tracks for TOF matching. //
11 //----------------------------------------------------------------------------//
16 #include "AliKalmanTrack.h"
18 #include "AliTOFGeometry.h"
24 class AliTOFtrack : public AliKalmanTrack {
28 AliTOFtrack():AliKalmanTrack(){}
29 AliTOFtrack(const AliTOFtrack& t);
30 AliTOFtrack(const AliESDtrack& t);
31 AliTOFtrack& operator=(const AliTOFtrack &source); // ass. op.
33 Double_t GetAlpha() const {return fAlpha;}
34 Int_t GetSector() const {
35 return Int_t(TVector2::Phi_0_2pi(fAlpha)/AliTOFGeometry::GetAlpha())%AliTOFGeometry::NSectors();}
37 Double_t GetC() const {return fC;}
38 void GetCovariance(Double_t cov[15]) const; // track covariance
39 Double_t GetEta() const {return fE;}
41 void GetExternalCovariance(Double_t cov[15]) const ;// track covariance
42 void GetExternalParameters(Double_t& xr, Double_t x[5]) const ;//track parameters
43 Double_t GetSigmaY2() const {return fCyy;}
44 Double_t GetSigmaZ2() const {return fCzz;}
46 Double_t Get1Pt() const {
47 return (TMath::Sign(1e-9,fC) + fC)*GetLocalConvConst();
49 Double_t GetP() const {
50 return TMath::Abs(GetPt())*sqrt(1.+GetTgl()*GetTgl());
52 Double_t GetPt() const {return 1./Get1Pt();}
53 void GetPxPyPz(Double_t &px, Double_t &py, Double_t &pz) const ;
54 void GetGlobalXYZ(Double_t &x, Double_t &y, Double_t &z) const ;
55 Int_t GetSeedLabel() const { return fSeedLab; }
56 Int_t GetSeedIndex() const { return fSeedInd; }
57 void SetSeedLabel(Int_t lab) { fSeedLab=lab; }
58 void SetSeedIndex(Int_t ind) { fSeedInd=ind; }
59 Double_t GetSnp() const {return fX*fC - fE;}
60 Double_t GetTgl() const {return fT;}
61 Double_t GetX() const {return fX;}
62 Double_t GetY() const {return fY;}
63 Double_t GetZ() const {return fZ;}
65 Int_t Compare(const TObject *o) const;
68 Double_t GetYat(Double_t xk, Bool_t & skip) const;
69 Int_t PropagateTo(Double_t xr, Double_t x0=8.72, Double_t rho=5.86e-3);
70 Int_t PropagateToInnerTOF(Bool_t holes);
71 void ResetCovariance();
72 void ResetCovariance(Float_t mult);
73 Int_t Rotate(Double_t angle);
76 void GetXYZ(Float_t r[3]) const;
78 Int_t Update(const AliCluster */*c*/, Double_t /*chi2*/, UInt_t /*idx*/) {
81 Double_t GetPredictedChi2(const AliCluster */*c*/) const {return 0.;}
83 Int_t fSeedInd; // ESD seed track index
84 Int_t fSeedLab; // track label taken from seeding
85 Double_t fAlpha; // rotation angle
86 Double_t fX; // running local X-coordinate of the track (time bin)
88 Double_t fY; // Y-coordinate of the track
89 Double_t fZ; // Z-coordinate of the track
91 Double_t fT; // tangent of the track momentum dip angle
92 Double_t fC; // track curvature
94 Double_t fCyy; // covariance
95 Double_t fCzy, fCzz; // matrix
96 Double_t fCey, fCez, fCee; // of the
97 Double_t fCty, fCtz, fCte, fCtt; // track
98 Double_t fCcy, fCcz, fCce, fCct, fCcc; // parameters
100 AliTOFGeometry *fTOFgeometry; // pointer to the TOF geometry
104 void GetPropagationParameters(Bool_t holes, Double_t *param);
106 ClassDef(AliTOFtrack,0) // TOF reconstructed tracks
110 inline void AliTOFtrack::GetXYZ(Float_t r[3]) const {
111 //---------------------------------------------------------------------
112 // Returns the position of the track in the global coord. system
113 //---------------------------------------------------------------------
114 Double_t cs=TMath::Cos(fAlpha), sn=TMath::Sin(fAlpha);
115 r[0]=fX*cs - fY*sn; r[1]=fX*sn + fY*cs; r[2]=fZ;