]>
Commit | Line | Data |
---|---|---|
51ad6848 | 1 | #ifndef ALIEXTERNALTRACKPARAM_H |
2 | #define ALIEXTERNALTRACKPARAM_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
7 | ||
49d13e89 | 8 | /***************************************************************************** |
9 | * "External" track parametrisation class * | |
10 | * * | |
11 | * external param0: local Y-coordinate of a track (cm) * | |
12 | * external param1: local Z-coordinate of a track (cm) * | |
13 | * external param2: local sine of the track momentum azimuthal angle * | |
14 | * external param3: tangent of the track momentum dip angle * | |
15 | * external param4: 1/pt (1/(GeV/c)) * | |
16 | * * | |
17 | * The parameters are estimated at an exact position x in a local coord. * | |
18 | * system rotated by angle alpha with respect to the global coord.system. * | |
19 | * Origin: I.Belikov, CERN, Jouri.Belikov@cern.ch * | |
20 | *****************************************************************************/ | |
a5e407e9 | 21 | #include "TObject.h" |
a5e407e9 | 22 | |
49d13e89 | 23 | const Double_t kB2C=0.299792458e-3; |
24 | const Double_t kAlmost1=0.999; | |
25 | const Double_t kAlmost0=1e-33; | |
26 | const Double_t kVeryBig=1./kAlmost0; | |
27 | ||
51ad6848 | 28 | class AliKalmanTrack; |
29 | ||
a5e407e9 | 30 | class AliExternalTrackParam: public TObject { |
51ad6848 | 31 | public: |
32 | AliExternalTrackParam(); | |
33 | AliExternalTrackParam(Double_t x, Double_t alpha, | |
34 | const Double_t param[5], const Double_t covar[15]); | |
35 | AliExternalTrackParam(const AliKalmanTrack& track); | |
ac3eaff4 | 36 | |
c9ec41e8 | 37 | void Reset(); |
38 | void Set(const AliKalmanTrack& track); | |
39 | ||
49d13e89 | 40 | const Double_t *GetParameter() const {return fP;} |
41 | const Double_t *GetCovariance() const {return fC;} | |
c9ec41e8 | 42 | virtual Double_t GetX() const {return fX;} |
43 | virtual Double_t GetAlpha() const {return fAlpha;} | |
44 | Double_t GetSign() const {return (fP[4]>0) ? 1 : -1;} | |
45 | Double_t GetP() const; | |
49d13e89 | 46 | Double_t GetD(Double_t b, Double_t xv, Double_t yv) const; |
47 | Double_t GetLinearD(Double_t xv, Double_t yv) const; | |
48 | Double_t GetPredictedChi2(Double_t p[2],Double_t cov[3]) const; | |
49 | Bool_t Update(Double_t p[2],Double_t cov[3]); | |
50 | Bool_t Rotate(Double_t alpha); | |
51 | Bool_t PropagateTo(Double_t x, Double_t b); | |
52 | Bool_t Propagate(Double_t alpha, Double_t x, Double_t b) { | |
53 | if (Rotate(alpha)) | |
54 | if (PropagateTo(x,b)) return kTRUE; | |
55 | return kFALSE; | |
56 | } | |
57 | ||
c9ec41e8 | 58 | Bool_t GetPxPyPz(Double_t *p) const; |
59 | Bool_t GetXYZ(Double_t *p) const; | |
60 | Bool_t GetCovarianceXYZPxPyPz(Double_t cv[21]) const; | |
61 | Bool_t GetPxPyPzAt(Double_t x, Double_t b, Double_t p[3]) const; | |
62 | Bool_t GetXYZAt(Double_t x, Double_t b, Double_t r[3]) const; | |
63 | ||
64 | void Print(Option_t* option = "") const; | |
65 | ||
66 | private: | |
49d13e89 | 67 | Double_t fX; // X coordinate for the point of parametrisation |
68 | Double_t fAlpha; // Local <-->global coor.system rotation angle | |
69 | Double_t fP[5]; // The track parameters | |
70 | Double_t fC[15]; // The track parameter covariance matrix | |
c9ec41e8 | 71 | |
72 | ClassDef(AliExternalTrackParam, 4) | |
51ad6848 | 73 | }; |
74 | ||
75 | #endif |