]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ITS/AliITSResidualsAnalysis.h
Splitting the variables used to accumulate the sums from the ones used to fill the...
[u/mrichter/AliRoot.git] / ITS / AliITSResidualsAnalysis.h
CommitLineData
146f76de 1#ifndef ALIITSRESIDUALSANALYSIS_H
2#define ALIITSRESIDUALSANALYSIS_H
3
4/* Copyright(c) 1998-2008, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7
8//*************************************************************************
9// AliITSResidualAnalysis: class which deals with the analysis of the *
10// tracks residuals in the ITS *
11// More comments will come with the development of the interfaces and *
12// functionalities of the class. *
13//*************************************************************************
14
15#include "AliAlignmentTracks.h"
16
17class TObject;
18class TCanvas;
19class TH1F;
20class TH2F;
21class TArrayI;
22
23class AliTrackPointArray;
24class AliTrackResiduals;
25class AliAlignObj;
26
27class AliITSResidualsAnalysis : public AliAlignmentTracks {
28
29
30 public:
31
32 AliITSResidualsAnalysis();
33 AliITSResidualsAnalysis(const TString aliTrackPoints,const TString geom);
34 AliITSResidualsAnalysis(const TArrayI *volIDs);
146f76de 35 ~AliITSResidualsAnalysis();
36
37
146f76de 38
39 void ListVolUsed(TTree *pointsTree,TArrayI ***arrayIndex,Int_t **lastIndex);
40 void ListVolUsed(){if(!fIsIndexBuilt)return;ListVolUsed(fPointsTree,fArrayIndex,fLastIndex);};
41
42 void InitHistograms(const TArrayI *volIDs);
bad3394b 43 void FillResidualsH(AliTrackPointArray *trackClust,AliTrackPointArray *trackFitPoints) const;
146f76de 44 void DrawHists() const;
bad3394b 45 Bool_t SaveHists(Int_t minNpoints=10,TString outname="ResidualsAnalysisTree.root") const;
46
146f76de 47 void FillVolumeCorrelationHists(Int_t ivol,Int_t volIDalignable,Int_t volIDpoint,Bool_t used) const;
48 Bool_t SetBinning(const TArrayI *volids,Float_t *phiBin,Float_t *zBin);
49 Float_t** CheckSingleLayer(const TArrayI *volids);
bad3394b 50 TArrayI* GetITSLayersVolids(Int_t layers[6]) const;
51 TArrayI* GetSPDSectorsVolids(Int_t sectors[10]) const;
52 Int_t WhichSector(Int_t module) const;
146f76de 53 Int_t GetBinPhiZ(const Int_t volID,Int_t *binz) const;
54 void GetTrackDirClusterCov(AliTrackPoint *point,Double_t &phi,Double_t &lambda,Double_t &lambda2,Double_t &alpha,Double_t &xovery,Double_t &zovery) const;
bad3394b 55 void CalculateResiduals(const TArrayI *volids,const TArrayI *volidsfit,AliGeomManager::ELayerID layerRangeMin,AliGeomManager::ELayerID layerRangeMax,TString outname="ResidualsAnalysisTree.root");
56 void ProcessVolumes(Int_t fit=0,TArrayI *volIDs=0,TArrayI *volIDsFit=0,TString misalignmentFile="",TString outname="ResidualsAnalysisTree.root",Int_t minPoints=2);
146f76de 57 TString GetFileNameTrackPoints() const { return fAliTrackPoints; };
58 TString GetFileNameGeometry() const { return fGeom; };
59 void SetFileNameTrackPoints(TString name) { fAliTrackPoints=name; };
60 void SetFileNameGeometry(TString name) { fGeom=name; };
61
146f76de 62 enum ModulePhiZ{
3dbc7836 63 kPhiSPD1=20,
64 kZSPD1=4,
65 kPhiSPD2=40,
66 kZSPD2=4,
67 kPhiSDD1=14,
68 kZSDD1=6,
69 kPhiSDD2=22,
70 kZSDD2=8,
71 kPhiSSD1=34,
72 kZSSD1=22,
73 kPhiSSD2=38,
74 kZSSD2=25
146f76de 75 };
76
146f76de 77 protected:
78
79 Int_t fnHist; // number of histogram = number of alignable volumes considered
80 Int_t fnPhi; // coordinate of the volume (Phi)
81 Int_t fnZ; // coordinate of the volume (Z)
82 Int_t **fvolidsToBin; // array with volID and bin
83 Int_t *fLastVolVolid; // Last Vol Volid
84 Double_t ***fCoordToBinTable; // array with coordinate and bin
85 TH1F **fVolResHistRPHI; // Histogram of Residuals along Global rphi
86 TH1F **fResHistZ; // Histogram of Residuals along Global Z
bad3394b 87 TH1F **fResHistX; // Histogram of Residuals along Global X
88 TH1F **fResHistXLocsddL; // Histogram of Residuals along Local X
89 // SDD left side of module
90 TH1F **fResHistXLocsddR; // Histogram of Residuals along Local X
91 // SDD right side of module
92 TH1F **fHistCoordGlobY; // Histogram of the Y coordinate in Global Reference
146f76de 93 TH1F **fPullHistRPHI; // Misc Histogram ...
94 TH1F **fPullHistZ; // Misc Histogram ...
95 TH1F **fTrackDirPhi; // Misc Histogram ...
96 TH1F **fTrackDirLambda; // Misc Histogram ...
97 TH1F **fTrackDirLambda2; // Misc Histogram ...
98 TH1F **fTrackDirAlpha; // Misc Histogram ...
99 TH1F *fTrackDirPhiAll; // Misc Histogram ...
100 TH1F *fTrackDirLambdaAll; // Misc Histogram ...
101 TH1F *fTrackDirLambda2All; // Misc Histogram ...
102 TH1F *fTrackDirAlphaAll; // Misc Histogram ...
103 TH2F **fTrackDir; // Misc Histogram ...
104 TH2F *fTrackDirAll; // Misc Histogram ...
105 TH2F *fTrackDir2All; // Misc Histogram ...
106 TH2F *fTrackDirXZAll; // Misc Histogram ...
107 TH1F **fResHistGlob; // Histogram of Residuals
108 TH2F **fhistCorrVol; // Misc Histogram ...
109 TH2F *fVolNTracks; // Histogram to see how many tracks pass through a given module
110 TH2F *fhEmpty; // Histogram to get/set the binning
111 TH2F *fhistVolNptsUsed; // Histogram with the numer of points used per volume
112 TH2F *fhistVolUsed; // Histogram with the numer of volumes udes
113 TH2F *fSigmaVolZ; // Histogram with the sigma vs volume Z
114 Bool_t fsingleLayer; // Tag for single layer
115 Bool_t fWriteHist; // Tag for histograms
116 TArrayI *fpTrackVolIDs; // array that gives the volID for the i^(th) entry
117 TArrayI **fVolVolids; // array with the volumes to analyze
118 TArrayI **fVolUsed; // array with the volumes to use
119 Bool_t fRealignObjFileIsOpen; // indicator- if the file fRealignObjFilename is opened
120 TClonesArray *fClonesArray; // pointer to the TClonesArray with the final AliAlignObjParams
121 TString fAliTrackPoints; // Filename with the AliTrackPoints
122 TString fGeom; // Filename with the Geometry
123
bad3394b 124 ClassDef(AliITSResidualsAnalysis,2) // Residuals analysis for the ITS
146f76de 125
126 };
127
128#endif
129