]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TPC/Base/AliTPCPointCorrection.h
composition of the Alluminum alloy that constitutes the ITS-TPC support rings updated...
[u/mrichter/AliRoot.git] / TPC / Base / AliTPCPointCorrection.h
1 #ifndef ALITPCPOINTCORRECTION_H
2 #define ALITPCPOINTCORRECTION_H
3
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice                               */
6
7 #include "TNamed.h"
8 #include "TArrayD.h"
9 #include "TObjArray.h"
10 #include "TVectorD.h"
11
12  
13 class AliTPCPointCorrection:public TNamed {
14 public:
15   AliTPCPointCorrection(); 
16   AliTPCPointCorrection(const Text_t *name, const Text_t *title);
17   virtual ~AliTPCPointCorrection();
18   //  
19   TVectorD * GetParamOutR(Int_t sector) {return (TVectorD*)fParamsOutR.At(sector);}
20   TVectorD * GetParamOutZ(Int_t sector) {return (TVectorD*)fParamsOutZ.At(sector);}
21   //
22   Double_t      GetDrOut(Bool_t isGlobal, Bool_t type, Double_t cx, Double_t cy, Double_t cz, Int_t sector);
23   Double_t      GetDzOut(Bool_t isGlobal, Bool_t type, Double_t cx, Double_t cy, Double_t cz, Int_t sector);
24
25   static Double_t      SGetDrOut(Bool_t isGlobal, Bool_t type, Double_t cx, Double_t cy, Double_t cz, Int_t sector);
26   static Double_t      SGetDzOut(Bool_t isGlobal, Bool_t type, Double_t cx, Double_t cy, Double_t cz, Int_t sector);
27   
28   static AliTPCPointCorrection* Instance();
29   void SetInstance(AliTPCPointCorrection*param){fgInstance = param;}
30   //
31   Double_t CorrectionOutR0(Bool_t isGlobal, Bool_t type, Double_t cx, Double_t cy, Double_t cz, Int_t sector);
32   Double_t CorrectionOutZ0(Bool_t isGlobal, Bool_t type, Double_t cx, Double_t cy, Double_t cz, Int_t sector);
33   
34   Double_t RPhiCOGCorrection(Int_t sector, Int_t padrow, Float_t pad, Float_t cy, Float_t y, Float_t z, Float_t ky, Float_t qMax, Float_t threhsold);
35   Double_t SRPhiCOGCorrection(Int_t sector, Int_t padrow, Float_t pad, Float_t cy, Float_t y, Float_t z, Float_t ky,  Float_t qMax, Float_t threhsold);
36   //
37   Double_t GetEdgeQ0(Int_t sector, Int_t padrow, Float_t y);
38   static   Double_t SGetEdgeQ0(Int_t sector, Int_t padrow, Float_t y);
39   //
40   // IROC -OROC+Quadrant alignment
41   //
42   void     AddCorrectionSector(TObjArray & sideAPar, TObjArray &sideCPar, TObjArray & sideACov, TObjArray &sideCCov, Bool_t reset);
43   Double_t GetCorrectionSector(Int_t coord, Int_t sector, Double_t lx, Double_t ly, Double_t lz, Int_t quadrant =-1); 
44   static Double_t SGetCorrectionSector(Int_t coord, Int_t sector, Double_t lx, Double_t ly, Double_t lz, Int_t quadrant=-1); 
45   //
46   // Global alignment
47   //
48   Double_t GetCorrection(Int_t coord, Int_t sector, Double_t lx, Double_t ly, Double_t lz);
49   static Double_t SGetCorrection(Int_t coord, Int_t sector, Double_t lx, Double_t ly, Double_t lz);
50 public: 
51   //
52   // Correction out
53   //
54   TObjArray   fParamsOutR;       // Parameters  for radial distortion  - outer field cage
55   TObjArray   fParamsOutZ;       // Parameters  for z      distortion  - outer field cage
56   Int_t       fParamOutRVersion;  // version of the parameterization
57   TObjArray   fErrorsOutR;       // Parameters  for radial distortion  - outer field cage
58   TObjArray   fErrorsOutZ;       // Parameters  for z      distortion  - outer field cage
59   Int_t       fParamOutZVersion;  // version of the parameterization
60   //
61   //  Edge rfi
62   // 
63   //
64   // Alignment part
65   //
66   Double_t fXIO;               // OROC-IROC boundary
67   Double_t fXmiddle;           // center of the TPC sector local X
68   Double_t fXquadrant;         // x quadrant
69   //
70   // IROC OROC alignment
71   //
72   TObjArray fArraySectorIntParam; // array of sector alignment parameters
73   TObjArray fArraySectorIntCovar; // array of sector alignment covariances 
74   //
75   // Kalman filter for global alignment
76   //
77   TMatrixD  *fSectorParam;     // Kalman parameter   
78   TMatrixD  *fSectorCovar;     // Kalman covariance  
79   //
80   //
81   //
82 private:
83
84   AliTPCPointCorrection(const AliTPCPointCorrection&); 
85   AliTPCPointCorrection& operator=(const AliTPCPointCorrection&); 
86   static AliTPCPointCorrection*   fgInstance; //! Instance of this class (singleton implementation)
87   ClassDef(AliTPCPointCorrection, 3); 
88 };
89
90 #endif
91
92