]>
Commit | Line | Data |
---|---|---|
9318a5b4 | 1 | #ifndef ALITPCCALIBALIGN_H |
2 | #define ALITPCCALIBALIGN_H | |
3 | ||
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | //// | |
8 | //// | |
9 | //// | |
10 | ||
11 | #include "TObject.h" | |
12 | #include "TObjArray.h" | |
13 | #include "TLinearFitter.h" | |
e4042305 | 14 | #include "AliTPCcalibBase.h" |
15 | #include "TH1.h" | |
9318a5b4 | 16 | |
17 | class AliExternalTrackParam; | |
e4042305 | 18 | class AliTPCseed; |
8b3c60d8 | 19 | class TGraphErrors; |
9318a5b4 | 20 | |
e4042305 | 21 | class AliTPCcalibAlign:public AliTPCcalibBase { |
9318a5b4 | 22 | public: |
972cf6f2 | 23 | enum HistoType {kY=0, kZ =1, kPhi=2, kTheta=3}; |
8b3c60d8 | 24 | enum FitType{ k6=0, k9=1, k12}; |
9318a5b4 | 25 | AliTPCcalibAlign(); |
e149f26d | 26 | AliTPCcalibAlign(const Text_t *name, const Text_t *title); |
9318a5b4 | 27 | virtual ~AliTPCcalibAlign(); |
e4042305 | 28 | virtual void Process(AliTPCseed *track); |
7eaa723e | 29 | virtual void Analyze(); |
30 | virtual void Terminate(); | |
31 | // | |
32 | virtual void EvalFitters(); | |
8b3c60d8 | 33 | TH1 * GetHisto(HistoType type, Int_t s1, Int_t s2, Bool_t force=kFALSE); |
34 | void MakeTree(const char *fname="alignTree.root"); | |
35 | TGraphErrors * MakeGraph(Int_t sec0, Int_t sec1, Int_t dsec, | |
36 | Int_t i0, Int_t i1, FitType type); | |
e4042305 | 37 | void ProcessTracklets(const AliExternalTrackParam &t1, |
38 | const AliExternalTrackParam &t2, | |
967eae0d | 39 | const AliTPCseed * seed, |
e4042305 | 40 | Int_t s1,Int_t s2); |
972cf6f2 | 41 | inline Int_t GetIndex(Int_t s1,Int_t s2){return 72*s1+s2;} |
42 | // | |
43 | inline TLinearFitter* GetFitter12(Int_t s1,Int_t s2); | |
44 | inline TLinearFitter* GetFitter9(Int_t s1,Int_t s2); | |
45 | inline TLinearFitter* GetFitter6(Int_t s1,Int_t s2); | |
46 | // | |
9318a5b4 | 47 | Bool_t GetTransformation12(Int_t s1,Int_t s2,TMatrixD &a); |
48 | Bool_t GetTransformation9(Int_t s1,Int_t s2,TMatrixD &a); | |
49 | Bool_t GetTransformation6(Int_t s1,Int_t s2,TMatrixD &a); | |
967eae0d | 50 | |
51 | void ProcessDiff(const AliExternalTrackParam &t1, | |
52 | const AliExternalTrackParam &t2, | |
53 | const AliTPCseed *seed, | |
54 | Int_t s1,Int_t s2); | |
55 | ||
972cf6f2 | 56 | // Bool_t GetTransformationCovar12(Int_t s1,Int_t s2,TMatrixD &a, Bool_t norm=kFALSE); |
57 | // Bool_t GetTransformationCovar9(Int_t s1,Int_t s2,TMatrixD &a, Bool_t norm=kFALSE); | |
58 | // Bool_t GetTransformationCovar6(Int_t s1,Int_t s2,TMatrixD &a, Bool_t norm=kFALSE); | |
e4042305 | 59 | |
9318a5b4 | 60 | private: |
972cf6f2 | 61 | void FillHisto(const AliExternalTrackParam &t1, |
62 | const AliExternalTrackParam &t2, | |
63 | Int_t s1,Int_t s2); | |
9318a5b4 | 64 | |
972cf6f2 | 65 | void Process12(const Double_t *t1, const Double_t *t2, |
66 | TLinearFitter *fitter); | |
67 | void Process9(Double_t *t1, Double_t *t2, TLinearFitter *fitter); | |
68 | void Process6(Double_t *t1, Double_t *t2, TLinearFitter *fitter); | |
69 | TLinearFitter* GetOrMakeFitter12(Int_t s1,Int_t s2); | |
70 | TLinearFitter* GetOrMakeFitter9(Int_t s1,Int_t s2); | |
71 | TLinearFitter* GetOrMakeFitter6(Int_t s1,Int_t s2); | |
72 | TObjArray fDphiHistArray; // array of residual histograms phi | |
73 | TObjArray fDthetaHistArray; // array of residual histograms theta | |
74 | TObjArray fDyHistArray; // array of residual histograms y | |
75 | TObjArray fDzHistArray; // array of residual histograms z | |
76 | TObjArray fFitterArray12; // array of fitters | |
77 | TObjArray fFitterArray9; // array of fitters | |
78 | TObjArray fFitterArray6; // array of fitters | |
79 | Int_t fPoints[72*72]; // number of points in the fitter | |
9318a5b4 | 80 | ClassDef(AliTPCcalibAlign,1) |
81 | }; | |
82 | ||
972cf6f2 | 83 | |
84 | TLinearFitter* AliTPCcalibAlign::GetFitter12(Int_t s1,Int_t s2) { | |
85 | return static_cast<TLinearFitter*>(fFitterArray12[GetIndex(s1,s2)]); | |
86 | } | |
87 | TLinearFitter* AliTPCcalibAlign::GetFitter9(Int_t s1,Int_t s2) { | |
88 | return static_cast<TLinearFitter*>(fFitterArray9[GetIndex(s1,s2)]); | |
89 | } | |
90 | TLinearFitter* AliTPCcalibAlign::GetFitter6(Int_t s1,Int_t s2) { | |
91 | return static_cast<TLinearFitter*>(fFitterArray6[GetIndex(s1,s2)]); | |
92 | } | |
93 | ||
94 | ||
95 | ||
96 | ||
97 | ||
9318a5b4 | 98 | #endif |