1 #ifndef AliTPCCALIBTRACKS_H
2 #define AliTPCCALIBTRACKS_H
5 ///////////////////////////////////////////////////////////////////////////////
7 // Class to analyse tracks for calibration //
8 // to be used as a component in AliTPCSelectorTracks //
9 // In the constructor you have to specify name and title //
10 // to get the Object out of a file. //
11 // The parameter 'clusterParam', a AliTPCClusterParam object //
12 // (needed for TPC cluster error and shape parameterization) //
13 // Normally you get this object out of the file 'TPCClusterParam.root' //
14 // In the parameter 'cuts' the cuts are specified, that decide //
15 // weather a track will be accepted for calibration or not. //
18 ///////////////////////////////////////////////////////////////////////////////
22 #include <AliTPCcalibBase.h>
30 class TTreeSRedirector;
32 class AliTPCClusterParam;
33 class TTreeSRedirector;
37 class AliTPCclusterMI;
38 class AliTPCcalibTracksCuts;
39 class AliTPCCalPadRegion;
48 class AliTPCcalibTracks : public AliTPCcalibBase {
50 AliTPCcalibTracks(); // default constructor
51 AliTPCcalibTracks(const AliTPCcalibTracks&calibTracks); // copy constructor
52 AliTPCcalibTracks(const Text_t *name, const Text_t *title, AliTPCClusterParam *clusterParam, AliTPCcalibTracksCuts* cuts, Int_t logLevel = 0);
53 AliTPCcalibTracks & operator=(const AliTPCcalibTracks& calibTracks);
55 virtual ~AliTPCcalibTracks(); // destructor
57 virtual void Process(AliTPCseed *track); // to be called by the Selector
58 void Process(AliESDEvent *event) {AliTPCcalibBase::Process(event);};
59 void Process(AliESDtrack *track, Int_t runNo=-1){AliTPCcalibBase::Process(track,runNo);};
60 virtual Long64_t Merge(TCollection *li);
61 void MakeResPlotsQTree(Int_t minEntries = 100, const char* pathName = "plots");
62 static void MakeQPosNormAll(TTree * chain, AliTPCClusterParam * param, Int_t maxPoints=1000000);
63 void MakeReport(Int_t stat, const char* pathName = "plots"); // calls all functions that procude pictures, results are written to pathName, stat is the minimal statistic threshold
67 Int_t AcceptTrack(AliTPCseed * track);
68 void FillResolutionHistoLocal(AliTPCseed * track); // the MAIN-FUNCTION, called for each track to fill the histograms, called by Process(...)
69 static TH2D* MakeDiff(TH2D * hfit, TF2 * func);
71 static AliTPCcalibTracks* TestMerge(AliTPCcalibTracks *ct, AliTPCClusterParam *clusterParam, Int_t nCalTracks = 50);
73 void SetStyle() const;
74 void Draw(Option_t* opt); // draw some exemplaric histograms for fast result-check
75 void MakeAmpPlots(Int_t stat, const char* pathName = "plots");
76 void MakeDeltaPlots(const char* pathName = "plots");
77 void MakeChargeVsDriftLengthPlotsOld(const char* pathName = "plots");
78 void MakeChargeVsDriftLengthPlots(const char* pathName = "plots");
79 void FitResolutionNew(const char* pathName = "plots");
80 void FitRMSNew(const char* pathName = "plots");
82 TObjArray* GetfArrayAmpRow() {return fArrayAmpRow;}
83 TObjArray* GetfArrayAmp() {return fArrayAmp;}
84 TObjArray* GetfArrayQDY() {return fArrayQDY;}
85 TObjArray* GetfArrayQDZ() {return fArrayQDZ;}
86 TObjArray* GetfArrayQRMSY() {return fArrayQRMSY;}
87 TObjArray* GetfArrayQRMSZ() {return fArrayQRMSZ;}
88 TObjArray* GetfArrayChargeVsDriftlength() {return fArrayChargeVsDriftlength;}
89 TH1F* GetfDeltaY() {return fDeltaY;}
90 TH1F* GetfDeltaZ() {return fDeltaZ;}
91 TObjArray* GetfResolY() {return fResolY;}
92 TObjArray* GetfResolZ() {return fResolZ;}
93 TObjArray* GetfRMSY() {return fRMSY;}
94 TObjArray* GetfRMSZ() {return fRMSZ;}
95 TH1I* GetfHclus() {return fHclus;}
96 TH1I* GetfRejectedTracksHisto() {return fRejectedTracksHisto;}
97 TH1I* GetfHclusterPerPadrow() {return fHclusterPerPadrow;}
98 TH1I* GetfHclusterPerPadrowRaw() {return fHclusterPerPadrowRaw;}
99 TH2I* GetfClusterCutHisto() {return fClusterCutHisto;}
100 AliTPCCalPad* GetfCalPadClusterPerPad() {return fCalPadClusterPerPad; }
101 AliTPCCalPad* GetfCalPadClusterPerPadRaw() {return fCalPadClusterPerPadRaw;}
102 AliTPCCalPadRegion* GetCalPadRegionchargeVsDriftlength() {return fcalPadRegionChargeVsDriftlength;}
103 AliTPCcalibTracksCuts* GetCuts() {return fCuts;}
108 static Int_t GetBin(Float_t q, Int_t pad);
109 static Int_t GetBin(Int_t iq, Int_t pad);
110 static Float_t GetQ(Int_t bin);
111 static Float_t GetPad(Int_t bin);
112 void FillResolutionHistoLocalDebugPart(AliTPCseed *track, AliTPCclusterMI *cluster0, Int_t irow, Float_t angley, Float_t anglez, Int_t nclFound, Int_t kDelta);
113 AliTPCClusterParam *fClusterParam; // pointer to cluster parameterization
115 TObjArray *fArrayAmpRow; // array with amplitudes versus row for given sector
116 TObjArray *fArrayAmp; // array with amplitude for sectors
117 TObjArray *fArrayQDY; // q binned delta Y histograms
118 TObjArray *fArrayQDZ; // q binned delta Z histograms
119 TObjArray *fArrayQRMSY; // q binned delta Y histograms
120 TObjArray *fArrayQRMSZ; // q binned delta Z histograms
121 TObjArray *fArrayChargeVsDriftlength; // array of arrays of TProfiles with charge vs. driftlength for each padsize and sector
122 AliTPCCalPadRegion *fcalPadRegionChargeVsDriftlength; // CalPadRegion, one TProfile for charge vs. driftlength for each padsize and sector
123 TH1F *fDeltaY; // integrated delta y histo
124 TH1F *fDeltaZ; // integrated delta z histo
125 TObjArray *fResolY; // array of resolution histograms Y
126 TObjArray *fResolZ; // array of resolution histograms Z
127 TObjArray *fRMSY; // array of RMS histograms Y
128 TObjArray *fRMSZ; // array of RMS histograms Z
129 AliTPCcalibTracksCuts *fCuts; // object with cuts, that is passed to the constructor
130 TH1I *fHclus; // number of clusters per track
131 TH1I *fRejectedTracksHisto; // histogram of rejecteced tracks, the number coresponds to the failed cut
132 TH1I *fHclusterPerPadrow; // histogram showing the number of clusters per padRow
133 TH1I *fHclusterPerPadrowRaw;// histogram showing the number of clusters per padRow before cuts on clusters are applied
134 TH2I *fClusterCutHisto; // histogram showing in which padRow the clusters were cutted by which criterium
135 AliTPCCalPad *fCalPadClusterPerPad; // AliTPCCalPad showing the number of clusters per Pad
136 AliTPCCalPad *fCalPadClusterPerPadRaw; // AliTPCCalPad showing the number of clusters per Pad before cuts on clusters are applied
137 ClassDef(AliTPCcalibTracks,1)