]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TRD/AliTRDrecoParam.h
aa0ea48e333880b1d8efcb6426bc4731341f3c18
[u/mrichter/AliRoot.git] / TRD / AliTRDrecoParam.h
1 #ifndef ALITRDRECOPARAM_H
2 #define ALITRDRECOPARAM_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 ////////////////////////////////////////////////////////////////////////////
9 //                                                                        //
10 //  Parameter class for the TRD reconstruction                            //
11 //                                                                        //
12 ////////////////////////////////////////////////////////////////////////////
13
14 #ifndef ALIDETECTORRECOPARAM_H
15 #include "AliDetectorRecoParam.h"
16 #endif
17
18 class AliTRDrecoParam : public AliDetectorRecoParam
19 {
20 public:
21   AliTRDrecoParam();
22   AliTRDrecoParam(const AliTRDrecoParam &rec);
23   ~AliTRDrecoParam() { }
24
25   Double_t GetChi2Y() const                 { return fkChi2Y;    }
26   Double_t GetChi2Z() const                 { return fkChi2Z;    }
27   Double_t GetFindableClusters() const      { return fkFindable; }
28   Double_t GetMaxTheta() const              { return fkMaxTheta; }
29   Double_t GetMaxPhi() const                { return fkMaxPhi;   }
30   Double_t GetPlaneQualityThreshold() const { return fkPlaneQualityThreshold; }
31   Double_t GetRoad0y() const                { return fkRoad0y;   }
32   Double_t GetRoad0z() const                { return fkRoad0z;   }
33   Double_t GetRoad1y() const                { return fkRoad1y;   }
34   Double_t GetRoad1z() const                { return fkRoad1z;   }
35   Double_t GetRoad2y() const                { return fkRoad2y;   }
36   Double_t GetRoad2z() const                { return fkRoad2z;   }
37   Double_t GetTrackLikelihood() const       { return fkTrackLikelihood;       }
38   inline void GetSysCovMatrix(Double_t *sys) const;  
39   Double_t GetMinMaxCutSigma() const        { return fMinMaxCutSigma;     };
40   Double_t GetMinLeftRightCutSigma() const  { return fMinLeftRightCutSigma;  };
41   Double_t GetClusMaxThresh() const         { return fClusMaxThresh;   };
42   Double_t GetClusSigThresh() const         { return fClusSigThresh;   };
43   Int_t    GetTCnexp() const                { return fTCnexp;          };
44   Int_t     GetNumberOfPresamples()  const {return fNumberOfPresamples;}
45   Int_t    GetNumberOfPostsamples() const {return fNumberOfPostsamples;}
46
47         
48   static   AliTRDrecoParam *GetLowFluxParam();
49   static   AliTRDrecoParam *GetHighFluxParam();
50   static   AliTRDrecoParam *GetCosmicTestParam();
51
52   Bool_t   IsClusterSharing() const         { return TestBit(kClusterSharing);}
53   Bool_t   IsLUT() const                    { return TestBit(kLUT);}
54   Bool_t   IsTailCancelation() const        { return TestBit(kTC);}
55   Bool_t   IsVertexConstrained() const      { return TestBit(kVertexConstrained); }
56   Bool_t   HasImproveTracklets() const       { return TestBit(kImproveTracklet); }
57
58
59   void     SetFindableClusters(Double_t r) {fkFindable = r;}
60   void     SetChi2Y(Double_t chi2) {fkChi2Y = chi2;}
61   void     SetChi2Z(Double_t chi2) {fkChi2Z = chi2;}
62   void     SetClusterSharing(Bool_t share = kTRUE)            { SetBit(kClusterSharing, share);}
63   void     SetImproveTracklets(Bool_t improve = kTRUE)         { SetBit(kImproveTracklet, improve);}
64   void     SetVertexConstrained(Bool_t vc = kTRUE)            { SetBit(kVertexConstrained, vc); }
65   void     SetLUT(Bool_t lut = kTRUE)                         { SetBit(kLUT, lut);};
66   void     SetMinMaxCutSigma(Float_t minMaxCutSigma)          { fMinMaxCutSigma   = minMaxCutSigma; }
67   void     SetMinLeftRightCutSigma(Float_t minLeftRightCutSigma) { fMinLeftRightCutSigma   = minLeftRightCutSigma; };
68   void     SetClusMaxThresh(Float_t thresh)                   { fClusMaxThresh   = thresh; };
69   void     SetClusSigThresh(Float_t thresh)                   { fClusSigThresh   = thresh; };
70   void     SetTailCancelation(Bool_t tc = kTRUE)              { SetBit(kTC, tc);  };
71   void     SetNexponential(Int_t nexp)                        { fTCnexp          = nexp;   };
72   inline void SetSysCovMatrix(Double_t *sys);
73   void     SetNumberOfPresamples(Int_t n)                     { fNumberOfPresamples = n;}
74   void     SetNumberOfPostsamples(Int_t n)                    { fNumberOfPostsamples = n;}
75
76 private:
77   enum{
78     kTC                = BIT(14) // tail cancelation
79    ,kLUT               = BIT(15) // look up table for cluster position determination 
80    ,kClusterSharing    = BIT(16) // Toggle cluster sharing
81    ,kVertexConstrained = BIT(17) // Perform vertex constrained fit
82    ,kImproveTracklet   = BIT(18) // Improve tracklet in the SA TRD track finder 
83   };
84
85   Double_t  fkMaxTheta;              // Maximum theta
86   Double_t  fkMaxPhi;                // Maximum phi
87
88   Double_t  fkRoad0y;                // Road for middle cluster
89   Double_t  fkRoad0z;                // Road for middle cluster
90
91   Double_t  fkRoad1y;                // Road in y for seeded cluster
92   Double_t  fkRoad1z;                // Road in z for seeded cluster
93
94   Double_t  fkRoad2y;                // Road in y for extrapolated cluster
95   Double_t  fkRoad2z;                // Road in z for extrapolated cluster
96   
97   Double_t  fkPlaneQualityThreshold; // Quality threshold
98   Double_t  fkFindable;              // Ratio of clusters from a track in one chamber which are at minimum supposed to be found.
99   Double_t  fkChi2Z;                 // Max chi2 on the z direction for seeding clusters fit
100   Double_t  fkChi2Y;                 // Max chi2 on the y direction for seeding clusters Rieman fit
101   Double_t  fkTrackLikelihood;       // Track likelihood for tracklets Rieman fit
102   
103   Double_t  fSysCovMatrix[5];        // Systematic uncertainty from calibration and alignment for each tracklet
104
105   // Clusterization parameter
106   Double_t  fMinMaxCutSigma;         // Threshold sigma noise pad middle
107   Double_t  fMinLeftRightCutSigma;   // Threshold sigma noise sum pad
108   Double_t  fClusMaxThresh;          // Threshold value for cluster maximum
109   Double_t  fClusSigThresh;          // Threshold value for cluster signal
110   Int_t     fTCnexp;                 // Number of exponentials, digital filter
111   
112   // ADC parameter
113   Int_t     fNumberOfPresamples;     // number of presamples 
114   Int_t     fNumberOfPostsamples;     // number of postsamples 
115
116   ClassDef(AliTRDrecoParam, 4)       // Reconstruction parameters for TRD detector
117
118 };
119
120 //___________________________________________________
121 inline void AliTRDrecoParam::GetSysCovMatrix(Double_t *sys) const
122 {
123   if(!sys) return;
124   memcpy(sys, fSysCovMatrix, 5*sizeof(Double_t));
125 }
126
127 //___________________________________________________
128 inline void AliTRDrecoParam::SetSysCovMatrix(Double_t *sys)
129 {
130   if(!sys) return;
131   memcpy(fSysCovMatrix, sys, 5*sizeof(Double_t));
132 }
133
134
135
136 #endif