libTPCbase.pkg TPCbaseLinkDef.h -
[u/mrichter/AliRoot.git] / TPC / AliTPCkalmanFit.h
CommitLineData
0bfb86a0 1#ifndef ALITPCKALMANFIT_H
2#define ALITPCKALMANFIT_H
3
4
5
6#include "TNamed.h"
7#include "TMatrixD.h"
8#include "TVectorD.h"
9#include "TObjArray.h"
10class TTreeSRedirector;
11class AliTrackPointArray;
12class AliTrackPoint;
13class TFormula;
14class TBits;
15class THnSparse;
16//
17
18class AliTPCkalmanFit: public TNamed{
19public:
20 AliTPCkalmanFit();
21 void Init();
22 void InitTransformation();
0e9efcbe 23 void Add(const AliTPCkalmanFit * kalman);
24
0bfb86a0 25 void AddCalibration(AliTPCTransformation * calib);
0e9efcbe 26 AliTPCTransformation * GetTransformation(Int_t i){return (fCalibration)? (AliTPCTransformation *)fCalibration->At(i):0;}
27 //
28 void SetStatus(const char * name, Bool_t setOn, Bool_t isOr=kTRUE);
0bfb86a0 29 //
30 void FitTrackLinear(AliTrackPointArray& points, Int_t step=1, TTreeSRedirector *debug=0);
31 void DumpTrackLinear(AliTrackPointArray& points, TTreeSRedirector *debug);
32 void UpdateLinear(AliTrackPoint &point, TTreeSRedirector *debug=0);
33
34 void Propagate(TTreeSRedirector *debug=0);
35 void PropagateTime(Int_t time);
0e9efcbe 36 void Update(const AliTPCkalmanFit * kalman);
0bfb86a0 37
38 static AliTrackPointArray * MakePointArrayLinear(Double_t alpha, Double_t y0, Double_t z0, Double_t ky, Double_t kz, Double_t err=0.02);
39 void ApplyCalibration(AliTrackPointArray *array, Double_t csign);
40 Bool_t CheckCovariance(TMatrixD &covar, Float_t maxEl);
0e9efcbe 41
42 Bool_t DumpCorelation(Double_t threshold, const char *mask=0);
43 Bool_t DumpCalib(const char *mask=0);
0bfb86a0 44 //
45 Double_t GetTPCDeltaXYZ(Int_t coord, Int_t volID, Double_t x, Double_t y, Double_t z);
46 static Double_t SGetTPCDeltaXYZ(Int_t coord, Int_t volID, Double_t x, Double_t y, Double_t z);
47 AliTPCkalmanFit *Test(Int_t ntracks);
48 public:
49 //
50 // Calibration parameters
51 //
52 TObjArray *fCalibration; // array of calibrations
53 TMatrixD *fCalibParam; // calibration parameters
54 TMatrixD *fCalibCovar; // calibration parameters
55 //
56 // Linear track
57 //
58 TMatrixD *fLinearParam; // linear parameters
59 TMatrixD *fLinearCovar; // linear covariance
60 THnSparse *fLinearTrackDelta[8]; // linear tracks matching residuals - delta
61 THnSparse *fLinearTrackPull[8]; // linear tracks matching residuals - pull
62 //
63 //
64 //
65 Int_t fLastTimeStamp; // last time stamp - used for propagation of parameters
66 //static AliTPCkalmanFit* Instance();
67 void SetInstance(AliTPCkalmanFit*param){fgInstance = param;}
68 static AliTPCkalmanFit* fgInstance; //! Instance of this class (singleton implementation)
69 private:
70 Double_t fCurrentAlpha; //! current rotation frame
71 Double_t fCA; //! cosine of current angle
72 Double_t fSA; //! sinus of current angle
73// AliTPCkalmanFit& operator=(const AliTPCkalmanFit&){;}// not implemented
74// AliTPCkalmanFit(const AliTPCkalmanFit&){;} //not implemented
75 ClassDef(AliTPCkalmanFit,1);
76};
77
78
79
80#endif
81