]>
Commit | Line | Data |
---|---|---|
e4f2f73d | 1 | #ifndef ALITRDSEEDV1_H |
2 | #define ALITRDSEEDV1_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
e44586fb | 4 | * See cxx source for full Copyright notice */ |
e4f2f73d | 5 | |
6 | /* $Id$ */ | |
7 | ||
8 | //////////////////////////////////////////////////////////////////////////// | |
9 | // // | |
10 | // The TRD track seed // | |
11 | // // | |
12 | //////////////////////////////////////////////////////////////////////////// | |
13 | ||
14 | #ifndef ALITRDSEED_H | |
15 | #include "AliTRDseed.h" | |
16 | #endif | |
17 | ||
0906e73e | 18 | #ifndef ALIPID_H |
19 | #include "AliPID.h" | |
20 | #endif | |
21 | ||
e4f2f73d | 22 | #ifndef ALIRIEMAN_H |
23 | #include "AliRieman.h" | |
24 | #endif | |
25 | ||
26 | class TTreeSRedirector; | |
27 | ||
28 | class AliRieman; | |
29 | ||
eb38ed55 | 30 | class AliTRDtrackingChamber; |
e4f2f73d | 31 | class AliTRDcluster; |
f3d3af1b | 32 | class AliTRDtrackV1; |
3a039a31 | 33 | class AliTRDReconstructor; |
e4f2f73d | 34 | class AliTRDseedV1 : public AliTRDseed |
35 | { | |
fbb2ea06 | 36 | |
0906e73e | 37 | public: |
38 | ||
e44586fb | 39 | enum { |
40 | knSlices = 10 | |
41 | }; | |
2e2915e7 | 42 | // bits from 0-13 are reserved by ROOT (see TObject.h) |
e44586fb | 43 | enum AliTRDtrackletStatus { |
2e2915e7 | 44 | kOwner = BIT(14) |
45 | , kRowCross = BIT(15) | |
e44586fb | 46 | }; |
47 | ||
48 | AliTRDseedV1(Int_t plane = -1); | |
49 | ~AliTRDseedV1(); | |
50 | AliTRDseedV1(const AliTRDseedV1 &ref); | |
51 | AliTRDseedV1& operator=(const AliTRDseedV1 &ref); | |
52 | ||
53 | Bool_t AttachClustersIter(AliTRDtrackingChamber *chamber, Float_t quality, Bool_t kZcorr = kFALSE | |
54 | , AliTRDcluster *c=0x0); | |
55 | Bool_t AttachClusters(AliTRDtrackingChamber *chamber, Bool_t kZcorr = kFALSE); | |
56 | void CookdEdx(Int_t nslices); | |
57 | void Draw(Option_t* o = ""); | |
58 | Bool_t Fit(); | |
59 | ||
60 | Bool_t Init(AliTRDtrackV1 *track); | |
61 | inline void Init(const AliRieman *fit); | |
62 | Bool_t IsOwner() const { return TestBit(kOwner);} | |
63 | Bool_t IsRowCross() const { return TestBit(kRowCross);} | |
64 | ||
65 | inline Float_t GetChi2Z(const Float_t z = 999.) const; | |
66 | inline Float_t GetChi2Y(const Float_t y = 999.) const; | |
67 | void GetCovAt(Double_t x, Double_t *cov) const; | |
68 | Double_t* GetCrossXYZ() { return &fCross[0];} | |
69 | Double_t GetCrossSz2() const { return fCross[3];} | |
70 | Float_t* GetdEdx() {return &fdEdx[0];} | |
71 | Float_t GetdQdl(Int_t ic) const; | |
72 | Double_t GetMomentum() const {return fMom;} | |
73 | Int_t GetN() const {return fN2;} | |
74 | Float_t GetQuality(Bool_t kZcorr) const; | |
75 | Int_t GetPlane() const { return fPlane; } | |
76 | Double_t* GetProbability(); | |
77 | Double_t GetSnp() const { return fSnp;} | |
78 | Double_t GetTgl() const { return fTgl;} | |
79 | Double_t GetYat(Double_t x) const { return fYfitR[0] + fYfitR[1] * (x - fX0);} | |
80 | Double_t GetZat(Double_t x) const { return fZfitR[0] + fZfitR[1] * (x - fX0);} | |
81 | ||
82 | void Print(Option_t *o = "") const; | |
83 | ||
84 | void SetMomentum(Double_t mom) {fMom = mom;} | |
29b87567 | 85 | void SetOwner(); |
e44586fb | 86 | void SetPlane(Int_t p) { fPlane = p; } |
87 | void SetSnp(Double_t snp) {fSnp = snp;} | |
88 | void SetTgl(Double_t tgl) {fTgl = tgl;} | |
3a039a31 | 89 | void SetReconstructor(const AliTRDReconstructor *rec) {fReconstructor = rec;} |
e44586fb | 90 | protected: |
e4f2f73d | 91 | |
e44586fb | 92 | void Copy(TObject &ref) const; |
e4f2f73d | 93 | |
e44586fb | 94 | private: |
3a039a31 | 95 | const AliTRDReconstructor *fReconstructor; |
e44586fb | 96 | Int_t fPlane; // TRD plane |
97 | Float_t fMom; // Momentum estimate for tracklet [GeV/c] | |
98 | Float_t fSnp; // sin of track with respect to x direction in XY plane | |
99 | Float_t fTgl; // tg of track with respect to x direction in XZ plane | |
100 | Float_t fdX; // length of time bin | |
101 | Float_t fdEdx[knSlices]; // dE/dx measurements for tracklet | |
102 | Double_t fCross[4]; // spatial parameters of the pad row crossing | |
103 | Double_t fProb[AliPID::kSPECIES]; // PID probabilities | |
e4f2f73d | 104 | |
e44586fb | 105 | ClassDef(AliTRDseedV1, 1) // New TRD seed |
e4f2f73d | 106 | |
107 | }; | |
108 | ||
109 | //____________________________________________________________ | |
110 | inline Float_t AliTRDseedV1::GetChi2Z(const Float_t z) const | |
111 | { | |
e44586fb | 112 | Float_t z1 = (z == 999.) ? fMeanz : z; |
113 | Float_t chi = fZref[0] - z1; | |
114 | return chi*chi; | |
e4f2f73d | 115 | } |
116 | ||
117 | //____________________________________________________________ | |
118 | inline Float_t AliTRDseedV1::GetChi2Y(const Float_t y) const | |
119 | { | |
e44586fb | 120 | Float_t y1 = (y == 999.) ? fYfitR[0] : y; |
121 | Float_t chi = fYref[0] - y1; | |
122 | return chi*chi; | |
e4f2f73d | 123 | } |
124 | ||
125 | //____________________________________________________________ | |
0906e73e | 126 | inline void AliTRDseedV1::Init(const AliRieman *rieman) |
e4f2f73d | 127 | { |
e44586fb | 128 | fZref[0] = rieman->GetZat(fX0); |
129 | fZref[1] = rieman->GetDZat(fX0); | |
130 | fYref[0] = rieman->GetYat(fX0); | |
131 | fYref[1] = rieman->GetDYat(fX0); | |
e4f2f73d | 132 | } |
133 | ||
134 | #endif | |
135 | ||
47d5d320 | 136 | |
6e49cfdb | 137 |