]> git.uio.no Git - u/mrichter/AliRoot.git/blob - STEER/AliKalmanTrack.h
Code clean-up (F.Carminati)
[u/mrichter/AliRoot.git] / STEER / AliKalmanTrack.h
1 #ifndef ALIKALMANTRACK_H
2 #define ALIKALMANTRACK_H
3
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice                               */
6
7 //-------------------------------------------------------------------------
8 //                          Class AliKalmanTrack
9 //
10 //         Origin: Iouri Belikov, CERN, Jouri.Belikov@cern.ch 
11 //-------------------------------------------------------------------------
12
13 #include <TObject.h>
14
15 class AliCluster;
16
17 class AliKalmanTrack : public TObject {
18 public:
19   AliKalmanTrack();
20   AliKalmanTrack(const AliKalmanTrack &t);
21
22   virtual ~AliKalmanTrack(){};
23   void SetLabel(Int_t lab) {fLab=lab;}
24
25   Bool_t   IsSortable() const {return kTRUE;}
26   Int_t    GetLabel()   const {return fLab;}
27   Double_t GetChi2()    const {return fChi2;}
28   Double_t GetMass()    const {return fMass;}
29   Int_t    GetNumberOfClusters() const {return fN;}
30   virtual Int_t GetClusterIndex(Int_t) const { //reserved for AliTracker
31     Warning("GetClusterIndex(Int_t)","Method must be overloaded !\n");
32     return 0;
33   } 
34
35   virtual Int_t Compare(const TObject *) const {return 0;} 
36
37   virtual void GetExternalParameters(Double_t &/*xr*/, Double_t /*x*/[5]) const {}
38   virtual void GetExternalCovariance(Double_t /*cov*/[15]) const {}
39
40   virtual Double_t GetPredictedChi2(const AliCluster *) const {return 0.;}
41   virtual 
42     Int_t PropagateTo(Double_t /*xr*/, Double_t /*x0*/, Double_t /*rho*/) {return 0;}
43   virtual Int_t Update(const AliCluster*, Double_t /*chi2*/, UInt_t) {return 0;}
44
45   static void SetConvConst(Double_t cc) {fConvConst=cc;}
46   Double_t GetConvConst() const {return fConvConst;}
47
48   static void SetMagneticField(Double_t f) {// f - Magnetic field in T
49     fConvConst=100/0.299792458/f;
50   }
51   Double_t GetMagneticField() const {return 100/0.299792458/fConvConst;}
52
53 protected:
54   void SetChi2(Double_t chi2) {fChi2=chi2;} 
55   void SetMass(Double_t mass) {fMass=mass;}
56   void SetNumberOfClusters(Int_t n) {fN=n;} 
57
58 private: 
59   Int_t fLab;             // track label
60   Double_t fChi2;         // total chi2 value for this track
61   Double_t fMass;         // mass hypothesis
62   Int_t fN;               // number of associated clusters
63
64   static Double_t fConvConst; //conversion constant cm -> GeV/c
65
66   ClassDef(AliKalmanTrack,1)    // Reconstructed track
67 };
68
69 #endif
70
71