Obsolete - removed
[u/mrichter/AliRoot.git] / TPC / AliComplexCluster.h
1 #ifndef ALICOMPLEXCLUSTER_H
2 #define ALICOMPLEXCLUSTER_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
8 #include "TObject.h"
9 #include "TMath.h"
10 #include "AliTPCclusterMI.h"
11
12 class AliComplexCluster : public TObject {
13 public:
14   friend class AliTPC;
15   friend class AliTPCClusterFinder;
16   friend class AliClusters;
17
18   AliComplexCluster() {
19     fTracks[0]=fTracks[1]=fTracks[2]=0; 
20     fX=fY=fQ=fSigmaX2=fSigmaY2=fSigmaXY=fArea=fMax=0.;
21   }
22   virtual ~AliComplexCluster() {;}
23   Bool_t    IsSortable() const;
24   Int_t Compare(const TObject *o) const;
25 private:
26   Int_t     fTracks[3];//labels of overlapped tracks
27   Float_t   fX ;       //Y of cluster
28   Float_t   fY ;       //Z of cluster
29   Float_t   fQ ;       //Q of cluster (in ADC counts)
30   Float_t   fSigmaX2;  //Sigma Y square of cluster
31   Float_t   fSigmaY2;  //Sigma Z square of cluster
32   Float_t   fSigmaXY;  //      XY moment 
33   Float_t   fArea;     //area of cluster
34   Float_t   fMax;     //amplitude at maximum 
35
36   ClassDef(AliComplexCluster,1)
37     // Cluster manager
38 };
39
40
41
42 class AliTPCTrackerPoint  {  
43  public:
44   Char_t   fIsShared;     // indicate sharing of the point between several tracks
45
46   AliTPCTrackerPoint(){fTX=0; fTY=0; fTZ=0; fTAngleZ=0; fTAngleY=0; fIsShared = 0;}
47   Float_t  GetX() const  {return (fTX*0.01);}
48   Float_t  GetZ() const {return (fTZ*0.01);}
49   Float_t  GetY() const {return (fTY*0.01);}
50   Float_t  GetAngleZ() const  {return (Float_t(fTAngleZ)*0.02);}
51   Float_t  GetAngleY() const {return (Float_t(fTAngleY)*0.02);}
52   //
53   void     SetX(Float_t x)  { fTX = Short_t(TMath::Nint(x*100.));} 
54   void     SetY(Float_t y)  { fTY = Short_t(TMath::Nint(y*100.));} 
55   void     SetZ(Float_t z)  { fTZ = Short_t(TMath::Nint(z*100.));} 
56   void     SetAngleZ(Float_t anglez) {fTAngleZ = Char_t(TMath::Nint(anglez*50.));}
57   void     SetAngleY(Float_t angley) {fTAngleY = Char_t(TMath::Nint(angley*50.));}
58   Float_t  GetSigmaZ() const {return (fSigmaZ*0.02);}
59   Float_t  GetSigmaY() const {return (fSigmaY*0.02);}  
60   Float_t  GetErrZ()   const {return (fErrZ*0.005);}
61   Float_t  GetErrY()   const {return (fErrY*0.005);}
62   void     SetErrZ(Float_t errz) {fErrZ = UChar_t(TMath::Nint(errz*200.));}
63   void     SetErrY(Float_t erry) {fErrY = UChar_t(TMath::Nint(erry*200.));}
64
65   void     SetSigmaZ(Float_t sigmaz) {fSigmaZ = UChar_t(TMath::Nint(sigmaz*50.));}
66   void     SetSigmaY(Float_t sigmay) {fSigmaY = UChar_t(TMath::Nint(sigmay*50.));}
67   //
68  private:
69   Short_t   fTX;        // x position of the cluster  in cm - 10 mum prec
70   Short_t   fTZ;        // current prolongation in Z  in cm - 10 mum prec.
71   Short_t   fTY;        // current prolongation in Y  in cm - 10 mum prec.
72   Char_t    fTAngleZ;    // angle 
73   Char_t    fTAngleY;    // angle 
74   UShort_t  fSigmaZ;     // shape  Z - normalised shape - normaliziation 1 - precision 2 percent
75   UShort_t  fSigmaY;     // shape  Y - normalised shape - normaliziation 1 - precision 2 percent
76   UShort_t  fErrZ;       // z error estimate - in  mm - 50 mum precision 
77   UShort_t  fErrY;       // y error estimate - in  mm - 50 mum precision 
78
79   ClassDef(AliTPCTrackerPoint,1)  
80 };
81
82 class AliTPCClusterPoint  {
83  public:
84   AliTPCClusterPoint(){fCZ=fCY=fSigmaZ=fSigmaY=fQ=fMax=fCType=0;}
85   inline Float_t  GetZ() const    {return (fCZ*0.01);}
86   inline Float_t  GetY() const   {return (fCY*0.01);}
87   inline Float_t  GetSigmaZ() const {return (fSigmaZ*0.02);}
88   inline Float_t  GetSigmaY() const {return (fSigmaY*0.02);}  
89   inline Int_t  GetType() const  {return fCType;}
90   inline Int_t  GetMax()  const {return fMax;}
91   inline Float_t  GetQ()  const {return fQ;}
92
93   //
94   void     SetY(Float_t y){ fCY = Short_t(TMath::Nint(y*100.));} 
95   void     SetZ(Float_t z){ fCZ = Short_t(TMath::Nint(z*100.));} 
96   void     SetSigmaZ(Float_t sigmaz) {fSigmaZ = UChar_t(TMath::Nint(sigmaz*50.));}
97   void     SetSigmaY(Float_t sigmay) {fSigmaY = UChar_t(TMath::Nint(sigmay*50.));}
98   void     SetQ(Float_t q) {fQ = UShort_t(q);}
99   void     SetMax(Float_t max) {fMax = UShort_t(max);}
100   void     SetType(Char_t type) {fCType = type;}
101  private:
102   Short_t  fCZ;       // current cluster position Z in cm - 100 mum precision
103   Short_t  fCY;       // current cluster position Y in cm - 100 mum precision
104   UChar_t  fSigmaZ;   // shape  Z - normalised shape - normaliziation 1 - precision 2 percent
105   UChar_t  fSigmaY;   // shape  Y - normalised shape - normaliziation 1 - precision 2 percent
106   UShort_t fQ;        // total charge in cluster 
107   UShort_t fMax;      // charge at maximum  
108   Char_t   fCType;    // type of the cluster
109
110   //
111   ClassDef(AliTPCClusterPoint,1)  
112 };
113
114
115 class AliTPCExactPoint : public TObject{
116  public:
117   AliTPCExactPoint(){fEZ=fEY=fEAngleZ=fEAngleY=fEAmp=fEPrim=fTrackID=0;}
118  private:
119   Float_t fEZ;       // current "exact" position according simulation
120   Float_t fEY;       // current "exact" position according simulation
121   Float_t fEX;       // x poistion of the cluster
122   Float_t fEAngleZ;  // angle Z
123   Float_t fEAngleY;  // angle Y
124   Float_t fEAmp;     // total charge deposited in row
125   Float_t fEPrim;    // primary charge deposited in row
126   Int_t   fTrackID;  // id of the track
127   Int_t   fRow;      // row
128   Int_t   fSec;      //sector
129   friend class AliTPCtrackerMI;
130   ClassDef(AliTPCExactPoint,1)  
131 };
132
133
134 class AliTPCTrackPoint: public TObject{
135  public:
136   friend class AliTPCtrackerMI;
137   AliTPCTrackPoint(){}
138   // AliTPCClusterPoint & GetCPoint(){return fCPoint;}
139   AliTPCTrackerPoint & GetTPoint(){return fTPoint;}
140   AliTPCclusterMI & GetCPoint(){return fCPoint;}  
141  private:
142   //  AliTPCClusterPoint fCPoint; 
143   //Char_t fIsShared;
144   AliTPCTrackerPoint fTPoint;  // track point
145   AliTPCclusterMI    fCPoint;  // cluster point
146   ClassDef(AliTPCTrackPoint,1)  
147 };
148
149 class AliTPCTrackPoint2: public AliTPCTrackPoint{
150  public:
151   friend class AliTPCtrackerMI;
152   AliTPCTrackPoint2(){}
153  private: 
154   Float_t fGX;    //global poition of the point
155   Float_t fGY;    //global poition of the point
156   Float_t fGZ;    //global poition of the point
157   //
158   Float_t fDY;    //distortion of the clusters from the global helix (3 point interpolation)
159   Float_t fDZ;    //distortion of the clusters from the global helix (3 point interpolation)
160   //
161   Float_t fDYU;  //derivation in y up
162   Float_t fDYD;  //distortion of y down
163   //
164   Float_t fDZU;  //derivation in y up
165   Float_t fDZD;  //distortion of y down
166   //
167   Float_t fDDY;  //derivation in y,z up-down
168   Float_t fDDZ;  //derivation in y,z up-down
169   //
170   Int_t   fID;            //id of the corresponding track
171   Int_t   fLab;           //MC label of the track
172   ClassDef(AliTPCTrackPoint2,1)  
173 };
174
175
176
177
178 class AliTPCTrackPointRef: public AliTPCTrackPoint{
179  public:
180   friend class AliTPCtrackerMI;
181   AliTPCExactPoint & GetExactPoint(){return fEPoint;}
182   AliTPCExactPoint & GetNearestPoint(){return fNPoint;}  
183  private:
184   AliTPCExactPoint fEPoint; //exact point belonging to track
185   AliTPCExactPoint fNPoint; //nearest point  
186   ClassDef(AliTPCTrackPointRef,1)  
187 };
188
189
190 #endif //ALICOMPLEXCLUSTER_H