]>
Commit | Line | Data |
---|---|---|
9fd4b54e | 1 | #ifndef ALIANALYSISTASKBFPSI_H\r |
2 | #define ALIANALYSISTASKBFPSI_H\r | |
0879e280 | 3 | \r |
4 | // Analysis task for the BF vs Psi code\r | |
5 | // Authors: Panos Cristakoglou@cern.ch\r | |
6 | \r | |
7 | class TList;\r | |
8 | class TH1F;\r | |
9 | class TH2F;\r | |
10 | class TF1;\r | |
11 | \r | |
12 | class AliBalancePsi;\r | |
13 | class AliESDtrackCuts;\r | |
f06d59b3 | 14 | class AliEventPoolManager;\r |
15 | \r | |
0879e280 | 16 | \r |
17 | #include "AliAnalysisTaskSE.h"\r | |
18 | #include "AliBalancePsi.h"\r | |
19 | \r | |
20 | #include "AliPID.h" \r | |
21 | #include "AliPIDResponse.h"\r | |
22 | #include "AliPIDCombined.h"\r | |
23 | \r | |
24 | \r | |
25 | class AliAnalysisTaskBFPsi : public AliAnalysisTaskSE {\r | |
26 | public:\r | |
27 | AliAnalysisTaskBFPsi(const char *name = "AliAnalysisTaskBFPsi");\r | |
28 | virtual ~AliAnalysisTaskBFPsi(); \r | |
29 | \r | |
30 | \r | |
31 | virtual void UserCreateOutputObjects();\r | |
32 | virtual void UserExec(Option_t *option);\r | |
33 | virtual void FinishTaskOutput();\r | |
34 | virtual void Terminate(Option_t *);\r | |
35 | \r | |
36 | void SetAnalysisObject(AliBalancePsi *const analysis) {\r | |
37 | fBalance = analysis;\r | |
38 | }\r | |
39 | void SetShufflingObject(AliBalancePsi *const analysisShuffled) {\r | |
40 | fRunShuffling = kTRUE;\r | |
41 | fShuffledBalance = analysisShuffled;\r | |
42 | }\r | |
f06d59b3 | 43 | void SetMixingObject(AliBalancePsi *const analysisMixed) {\r |
44 | fRunMixing = kTRUE;\r | |
45 | fMixedBalance = analysisMixed;\r | |
46 | }\r | |
47 | void SetMixingTracks(Int_t tracks) { fMixingTracks = tracks; }\r | |
0879e280 | 48 | void SetAnalysisCutObject(AliESDtrackCuts *const trackCuts) {\r |
49 | fESDtrackCuts = trackCuts;}\r | |
50 | void SetVertexDiamond(Double_t vx, Double_t vy, Double_t vz) {\r | |
51 | fVxMax = vx;\r | |
52 | fVyMax = vy;\r | |
53 | fVzMax = vz;\r | |
54 | }\r | |
55 | \r | |
56 | //==============AOD analysis==============//\r | |
57 | void SetAODtrackCutBit(Int_t bit){\r | |
58 | nAODtrackCutBit = bit;\r | |
59 | }\r | |
60 | \r | |
61 | void SetKinematicsCutsAOD(Double_t ptmin, Double_t ptmax, Double_t etamin, Double_t etamax){\r | |
9fd4b54e | 62 | fPtMin = ptmin; fPtMax = ptmax;\r |
63 | fEtaMin = etamin; fEtaMax = etamax;\r | |
0879e280 | 64 | }\r |
65 | \r | |
66 | void SetExtraDCACutsAOD(Double_t DCAxy, Double_t DCAz){\r | |
67 | fDCAxyCut = DCAxy;\r | |
68 | fDCAzCut = DCAz;\r | |
69 | }\r | |
70 | \r | |
71 | void SetExtraTPCCutsAOD(Double_t maxTPCchi2, Int_t minNClustersTPC){\r | |
72 | fTPCchi2Cut = maxTPCchi2;\r | |
73 | fNClustersTPCCut = minNClustersTPC;\r | |
74 | }\r | |
75 | \r | |
76 | //==============MC analysis==============//\r | |
77 | void SetKinematicsCutsMC(Double_t ptmin, Double_t ptmax,\r | |
78 | Double_t etamin, Double_t etamax){\r | |
79 | fPtMin = ptmin; fPtMax = ptmax;\r | |
80 | fEtaMin = etamin; fEtaMax = etamax;\r | |
81 | }\r | |
82 | void UseFlowAfterBurner(TF1 *gDifferentialV2) {\r | |
83 | fDifferentialV2 = gDifferentialV2;\r | |
84 | fUseFlowAfterBurner = kTRUE;\r | |
85 | }\r | |
86 | void ExcludeResonancesInMC() {fExcludeResonancesInMC = kTRUE;}\r | |
87 | \r | |
88 | void SetPDGCode(Int_t gPdgCode) {\r | |
89 | fUseMCPdgCode = kTRUE;\r | |
90 | fPDGCodeToBeAnalyzed = gPdgCode;\r | |
91 | }\r | |
92 | \r | |
93 | //Centrality\r | |
94 | void SetCentralityEstimator(const char* centralityEstimator) {fCentralityEstimator = centralityEstimator;}\r | |
9fd4b54e | 95 | const char* GetCentralityEstimator(void) const {return fCentralityEstimator;}\r |
0879e280 | 96 | void SetCentralityPercentileRange(Double_t min, Double_t max) { \r |
97 | fUseCentrality = kTRUE;\r | |
98 | fCentralityPercentileMin=min;\r | |
99 | fCentralityPercentileMax=max;\r | |
100 | }\r | |
101 | void SetImpactParameterRange(Double_t min, Double_t max) { \r | |
102 | fUseCentrality = kTRUE;\r | |
103 | fImpactParameterMin=min;\r | |
104 | fImpactParameterMax=max;\r | |
105 | }\r | |
106 | \r | |
107 | //multiplicity\r | |
108 | void SetMultiplicityRange(Int_t min, Int_t max) {\r | |
109 | fUseMultiplicity = kTRUE;\r | |
110 | fNumberOfAcceptedTracksMin = min;\r | |
111 | fNumberOfAcceptedTracksMax = max;}\r | |
112 | \r | |
113 | void UseOfflineTrigger() {fUseOfflineTrigger = kTRUE;}\r | |
114 | \r | |
115 | //Acceptance filter\r | |
116 | void SetAcceptanceParameterization(TF1 *parameterization) {\r | |
117 | fAcceptanceParameterization = parameterization;}\r | |
118 | \r | |
119 | //pid\r | |
120 | enum kDetectorUsedForPID { kTPCpid, kTOFpid, kTPCTOF }; // default TPC & TOF pid (via GetTPCpid & GetTOFpid) \r | |
121 | enum kParticleOfInterest { kMuon, kElectron, kPion, kKaon, kProton }; \r | |
122 | \r | |
123 | void SetUseBayesianPID(Double_t gMinProbabilityValue) {\r | |
124 | fUsePID = kTRUE; fUsePIDnSigma = kFALSE; fUsePIDPropabilities = kTRUE;\r | |
125 | fMinAcceptedPIDProbability = gMinProbabilityValue; }\r | |
126 | \r | |
127 | void SetUseNSigmaPID(Double_t gMaxNSigma) {\r | |
128 | fUsePID = kTRUE; fUsePIDPropabilities = kFALSE; fUsePIDnSigma = kTRUE;\r | |
129 | fPIDNSigma = gMaxNSigma; }\r | |
130 | \r | |
131 | void SetParticleOfInterest(kParticleOfInterest poi) {\r | |
132 | fParticleOfInterest = poi;}\r | |
133 | void SetDetectorUsedForPID(kDetectorUsedForPID detConfig) {\r | |
134 | fPidDetectorConfig = detConfig;}\r | |
135 | \r | |
136 | private:\r | |
f06d59b3 | 137 | Double_t IsEventAccepted(AliVEvent* event);\r |
138 | Double_t GetEventPlane(AliVEvent* event);\r | |
139 | TObjArray* GetAcceptedTracks(AliVEvent* event, Double_t fCentrality, Double_t gReactionPlane);\r | |
140 | TObjArray* GetShuffledTracks(TObjArray* tracks);\r | |
141 | \r | |
0879e280 | 142 | AliBalancePsi *fBalance; //BF object\r |
143 | Bool_t fRunShuffling;//run shuffling or not\r | |
144 | AliBalancePsi *fShuffledBalance; //BF object (shuffled)\r | |
f06d59b3 | 145 | Bool_t fRunMixing;//run mixing or not\r |
146 | Int_t fMixingTracks;\r | |
147 | AliBalancePsi *fMixedBalance; //TriggeredBF object (mixed)\r | |
148 | AliEventPoolManager* fPoolMgr; //! event pool manager\r | |
149 | \r | |
0879e280 | 150 | TList *fList; //fList object\r |
151 | TList *fListBF; //fList object\r | |
152 | TList *fListBFS; //fList object\r | |
f06d59b3 | 153 | TList *fListBFM; //fList object\r |
0879e280 | 154 | TList *fHistListPIDQA; //! list of histograms\r |
155 | \r | |
6b046844 | 156 | TH2F *fHistEventStats; //event stats\r |
0879e280 | 157 | TH2F *fHistCentStats; //centrality stats\r |
158 | TH1F *fHistTriggerStats; //trigger stats\r | |
159 | TH1F *fHistTrackStats; //Track filter bit stats\r | |
160 | TH1F *fHistVx; //x coordinate of the primary vertex\r | |
161 | TH1F *fHistVy; //y coordinate of the primary vertex\r | |
6b046844 | 162 | TH2F *fHistVz; //z coordinate of the primary vertex\r |
0879e280 | 163 | \r |
6b046844 | 164 | TH2F *fHistEventPlane; //event plane distribution\r |
0879e280 | 165 | \r |
9fd4b54e | 166 | TH2F *fHistClus;//number of clusters (QA histogram)\r |
167 | TH2F *fHistDCA;//DCA (QA histogram)\r | |
168 | TH2F *fHistChi2;//track chi2 (QA histogram)\r | |
169 | TH2F *fHistPt;//transverse momentum (QA histogram)\r | |
170 | TH2F *fHistEta;//pseudorapidity (QA histogram)\r | |
171 | TH2F *fHistRapidity;//rapidity (QA histogram)\r | |
172 | TH2F *fHistPhi;//phi (QA histogram)\r | |
173 | TH2F *fHistPhiBefore;//phi before v2 afterburner (QA histogram)\r | |
174 | TH2F *fHistPhiAfter;//phi after v2 afterburner (QA histogram)\r | |
175 | TH2F *fHistPhiPos;//phi for positive particles (QA histogram)\r | |
176 | TH2F *fHistPhiNeg;//phi for negative particles (QA histogram)\r | |
177 | TH2F *fHistV0M;//V0 multiplicities (QA histogram)\r | |
178 | TH2F *fHistRefTracks;//reference track multiplicities (QA histogram)\r | |
0879e280 | 179 | \r |
180 | //============PID============//\r | |
9fd4b54e | 181 | TH2D *fHistdEdxVsPTPCbeforePID;//TPC dEdx vs momentum before PID cuts (QA histogram)\r |
182 | TH2D *fHistBetavsPTOFbeforePID;//beta vs momentum before PID cuts (QA histogram)\r | |
183 | TH2D *fHistProbTPCvsPtbeforePID; //TPC probability vs pT before PID cuts (QA histogram)\r | |
184 | TH2D *fHistProbTOFvsPtbeforePID;//TOF probability vs pT before PID cuts (QA histogram)\r | |
185 | TH2D *fHistProbTPCTOFvsPtbeforePID;//TOF/TPC probability vs pT before PID cuts (QA histogram)\r | |
186 | TH2D *fHistNSigmaTPCvsPtbeforePID;//TPC nsigma vs pT before PID cuts (QA histogram)\r | |
187 | TH2D *fHistNSigmaTOFvsPtbeforePID;//TOF nsigma vs pT before PID cuts (QA histogram)\r | |
188 | TH2D *fHistdEdxVsPTPCafterPID;//TPC dEdx vs momentum after PID cuts (QA histogram)\r | |
189 | TH2D *fHistBetavsPTOFafterPID;//beta vs momentum after PID cuts (QA histogram)\r | |
190 | TH2D *fHistProbTPCvsPtafterPID; //TPC probability vs pT after PID cuts (QA histogram)\r | |
191 | TH2D *fHistProbTOFvsPtafterPID;//TOF probability vs pT after PID cuts (QA histogram)\r | |
192 | TH2D *fHistProbTPCTOFvsPtafterPID;//TOF/TPC probability vs pT after PID cuts (QA histogram)\r | |
193 | TH2D *fHistNSigmaTPCvsPtafterPID;//TPC nsigma vs pT after PID cuts (QA histogram)\r | |
194 | TH2D *fHistNSigmaTOFvsPtafterPID;//TOF nsigma vs pT after PID cuts (QA histogram)\r | |
0879e280 | 195 | \r |
196 | AliPIDResponse *fPIDResponse; //! PID response object\r | |
197 | AliPIDCombined *fPIDCombined; //! combined PID object\r | |
198 | \r | |
9fd4b54e | 199 | kParticleOfInterest fParticleOfInterest;//analyzed particle\r |
200 | kDetectorUsedForPID fPidDetectorConfig;//used detector for PID\r | |
201 | \r | |
202 | Bool_t fUsePID; //flag to use PID \r | |
203 | Bool_t fUsePIDnSigma;//flag to use nsigma method for PID\r | |
204 | Bool_t fUsePIDPropabilities;//flag to use probability method for PID\r | |
205 | Double_t fPIDNSigma;//nsigma cut for PID\r | |
206 | Double_t fMinAcceptedPIDProbability;//probability cut for PID\r | |
0879e280 | 207 | //============PID============//\r |
208 | \r | |
209 | AliESDtrackCuts *fESDtrackCuts; //ESD track cuts\r | |
210 | \r | |
211 | TString fCentralityEstimator; //"V0M","TRK","TKL","ZDC","FMD"\r | |
212 | Bool_t fUseCentrality;//use the centrality (PbPb) or not (pp)\r | |
213 | Double_t fCentralityPercentileMin;//centrality percentile min\r | |
214 | Double_t fCentralityPercentileMax;//centrality percentile max\r | |
215 | Double_t fImpactParameterMin;//impact parameter min (used for MC)\r | |
216 | Double_t fImpactParameterMax;//impact parameter max (used for MC)\r | |
217 | \r | |
218 | Bool_t fUseMultiplicity;//use the multiplicity cuts\r | |
219 | Int_t fNumberOfAcceptedTracksMin;//min. number of number of accepted tracks (used for the multiplicity dependence study - pp)\r | |
220 | Int_t fNumberOfAcceptedTracksMax;//max. number of number of accepted tracks (used for the multiplicity dependence study - pp)\r | |
6b046844 | 221 | TH2F *fHistNumberOfAcceptedTracks;//hisot to store the number of accepted tracks\r |
0879e280 | 222 | \r |
223 | Bool_t fUseOfflineTrigger;//Usage of the offline trigger selection\r | |
224 | \r | |
225 | Double_t fVxMax;//vxmax\r | |
226 | Double_t fVyMax;//vymax\r | |
227 | Double_t fVzMax;//vzmax\r | |
228 | \r | |
229 | Int_t nAODtrackCutBit;//track cut bit from track selection (only used for AODs)\r | |
230 | \r | |
231 | Double_t fPtMin;//only used for AODs\r | |
232 | Double_t fPtMax;//only used for AODs\r | |
233 | Double_t fEtaMin;//only used for AODs\r | |
234 | Double_t fEtaMax;//only used for AODs\r | |
235 | \r | |
236 | Double_t fDCAxyCut;//only used for AODs\r | |
237 | Double_t fDCAzCut;//only used for AODs\r | |
238 | \r | |
239 | Double_t fTPCchi2Cut;//only used for AODs\r | |
240 | Int_t fNClustersTPCCut;//only used for AODs\r | |
241 | \r | |
242 | TF1 *fAcceptanceParameterization;//acceptance filter used for MC\r | |
243 | \r | |
244 | TF1 *fDifferentialV2;//pt-differential v2 (from real data)\r | |
245 | Bool_t fUseFlowAfterBurner;//Usage of a flow after burner\r | |
246 | \r | |
247 | Bool_t fExcludeResonancesInMC;//flag to exclude the resonances' decay products from the MC analysis\r | |
248 | Bool_t fUseMCPdgCode; //Boolean to analyze a set of particles in MC\r | |
249 | Int_t fPDGCodeToBeAnalyzed; //Analyze a set of particles in MC\r | |
250 | \r | |
251 | \r | |
252 | \r | |
253 | AliAnalysisTaskBFPsi(const AliAnalysisTaskBFPsi&); // not implemented\r | |
254 | AliAnalysisTaskBFPsi& operator=(const AliAnalysisTaskBFPsi&); // not implemented\r | |
255 | \r | |
256 | ClassDef(AliAnalysisTaskBFPsi, 5); // example of analysis\r | |
257 | };\r | |
258 | \r | |
f06d59b3 | 259 | \r |
260 | \r | |
0879e280 | 261 | #endif\r |