]>
Commit | Line | Data |
---|---|---|
3af23c82 | 1 | // ************************************************************************* |
2 | // * * | |
3 | // * Task for Fragmentation Function Analysis in PWG4 Jet Task Force Train * | |
4 | // * * | |
5 | // ************************************************************************* | |
656dc810 | 6 | |
7 | ||
8 | /************************************************************************** | |
9 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
10 | * * | |
11 | * Author: The ALICE Off-line Project. * | |
12 | * Contributors are mentioned in the code where appropriate. * | |
13 | * * | |
14 | * Permission to use, copy, modify and distribute this software and its * | |
15 | * documentation strictly for non-commercial purposes is hereby granted * | |
16 | * without fee, provided that the above copyright notice appears in all * | |
17 | * copies and that both the copyright notice and this permission notice * | |
18 | * appear in the supporting documentation. The authors make no claims * | |
19 | * about the suitability of this software for any purpose. It is * | |
20 | * provided "as is" without express or implied warranty. * | |
21 | **************************************************************************/ | |
22 | ||
23 | /* $Id: */ | |
24 | ||
25 | #include "TList.h" | |
26 | #include "TH1F.h" | |
27 | #include "TH2F.h" | |
67e37e80 | 28 | #include "TH3F.h" |
656dc810 | 29 | #include "TString.h" |
3af23c82 | 30 | #include "THnSparse.h" |
ac017ff3 | 31 | #include "TProfile.h" |
32 | #include "TFile.h" | |
33 | #include "TKey.h" | |
67e37e80 | 34 | #include "TRandom3.h" |
656dc810 | 35 | |
36 | #include "AliAODInputHandler.h" | |
37 | #include "AliAODHandler.h" | |
38 | #include "AliESDEvent.h" | |
39 | #include "AliAODMCParticle.h" | |
40 | #include "AliAODJet.h" | |
3af23c82 | 41 | #include "AliAODJetEventBackground.h" |
656dc810 | 42 | #include "AliGenPythiaEventHeader.h" |
5fde4a38 | 43 | #include "AliGenHijingEventHeader.h" |
656dc810 | 44 | #include "AliInputEventHandler.h" |
45 | ||
46 | #include "AliAnalysisHelperJetTasks.h" | |
47 | #include "AliAnalysisManager.h" | |
48 | #include "AliAnalysisTaskSE.h" | |
3e1c1eee | 49 | #include "AliVParticle.h" |
50 | #include "AliVEvent.h" | |
656dc810 | 51 | |
52 | #include "AliAnalysisTaskFragmentationFunction.h" | |
53 | ||
656dc810 | 54 | ClassImp(AliAnalysisTaskFragmentationFunction) |
55 | ||
56 | //____________________________________________________________________________ | |
57 | AliAnalysisTaskFragmentationFunction::AliAnalysisTaskFragmentationFunction() | |
58 | : AliAnalysisTaskSE() | |
59 | ,fESD(0) | |
60 | ,fAOD(0) | |
40445651 | 61 | ,fAODExtension(0) |
62 | ,fNonStdFile("") | |
656dc810 | 63 | ,fBranchRecJets("jets") |
44b235ce | 64 | ,fBranchRecBackJets("") |
742ee86c | 65 | ,fBranchRecBckgClusters("") |
656dc810 | 66 | ,fBranchGenJets("") |
67 | ,fTrackTypeGen(0) | |
68 | ,fJetTypeGen(0) | |
fe343c6b | 69 | ,fJetTypeRecEff(0) |
656dc810 | 70 | ,fFilterMask(0) |
ac017ff3 | 71 | ,fUsePhysicsSelection(kTRUE) |
3af23c82 | 72 | ,fEventClass(0) |
73 | ,fMaxVertexZ(10) | |
656dc810 | 74 | ,fTrackPtCut(0) |
75 | ,fTrackEtaMin(0) | |
76 | ,fTrackEtaMax(0) | |
77 | ,fTrackPhiMin(0) | |
78 | ,fTrackPhiMax(0) | |
79 | ,fJetPtCut(0) | |
80 | ,fJetEtaMin(0) | |
81 | ,fJetEtaMax(0) | |
82 | ,fJetPhiMin(0) | |
83 | ,fJetPhiMax(0) | |
84 | ,fDiJetCut(0) | |
85 | ,fDiJetDeltaPhiCut(0) | |
86 | ,fDiJetPtFractionCut(0) | |
87 | ,fDiJetCDFCut(0) | |
88 | ,fDiJetKindBins(0) | |
89 | ,fFFRadius(0) | |
1da9498b | 90 | ,fFFBckgRadius(0) |
91 | ,fBckgMode(0) | |
67e37e80 | 92 | ,fIJMode(0) |
3af23c82 | 93 | ,fQAMode(0) |
94 | ,fFFMode(0) | |
95 | ,fDJMode(0) | |
96 | ,fEffMode(0) | |
97 | ,fPhiCorrMode(0) | |
742ee86c | 98 | ,fUseRecEffRecJetPtBins(0) |
99 | ,fUseResponseRecJetPtBins(1) | |
c2658535 | 100 | ,fAvgTrials(0) |
656dc810 | 101 | ,fTracksRec(0) |
102 | ,fTracksRecCuts(0) | |
103 | ,fTracksGen(0) | |
fe343c6b | 104 | ,fTracksAODMCCharged(0) |
105 | ,fTracksRecQualityCuts(0) | |
656dc810 | 106 | ,fJetsRec(0) |
107 | ,fJetsRecCuts(0) | |
108 | ,fJetsGen(0) | |
fe343c6b | 109 | ,fJetsRecEff(0) |
67e37e80 | 110 | ,fBckgJetsRec(0) |
111 | ,fBckgJetsRecCuts(0) | |
112 | ,fBckgJetsGen(0) | |
656dc810 | 113 | ,fQATrackHistosRec(0) |
114 | ,fQATrackHistosRecCuts(0) | |
115 | ,fQATrackHistosGen(0) | |
116 | ,fQAJetHistosRec(0) | |
117 | ,fQAJetHistosRecCuts(0) | |
118 | ,fQAJetHistosRecCutsLeading(0) | |
119 | ,fQAJetHistosGen(0) | |
120 | ,fQAJetHistosGenLeading(0) | |
fe343c6b | 121 | ,fQAJetHistosRecEffLeading(0) |
656dc810 | 122 | ,fFFHistosRecCuts(0) |
123 | ,fFFHistosRecLeading(0) | |
124 | ,fFFHistosRecLeadingTrack(0) | |
125 | ,fFFHistosGen(0) | |
126 | ,fFFHistosGenLeading(0) | |
127 | ,fFFHistosGenLeadingTrack(0) | |
128 | ,fIJHistosRecCuts(0) | |
129 | ,fIJHistosRecLeading(0) | |
130 | ,fIJHistosRecLeadingTrack(0) | |
131 | ,fIJHistosGen(0) | |
132 | ,fIJHistosGenLeading(0) | |
133 | ,fIJHistosGenLeadingTrack(0) | |
134 | ,fFFDiJetHistosRecCuts(0) | |
135 | ,fFFDiJetHistosRecLeading(0) | |
136 | ,fFFDiJetHistosRecLeadingTrack(0) | |
137 | ,fFFDiJetHistosGen(0) | |
138 | ,fFFDiJetHistosGenLeading(0) | |
139 | ,fFFDiJetHistosGenLeadingTrack(0) | |
140 | ,fQADiJetHistosRecCuts(0) | |
141 | ,fQADiJetHistosGen(0) | |
3af23c82 | 142 | ,fPhiCorrHistosJetArea(0) |
143 | ,fPhiCorrHistosTransverseArea(0) | |
144 | ,fPhiCorrHistosAwayArea(0) | |
656dc810 | 145 | ,fQATrackHighPtThreshold(0) |
146 | ,fFFNBinsJetPt(0) | |
147 | ,fFFJetPtMin(0) | |
148 | ,fFFJetPtMax(0) | |
149 | ,fFFNBinsPt(0) | |
150 | ,fFFPtMin(0) | |
151 | ,fFFPtMax(0) | |
152 | ,fFFNBinsXi(0) | |
153 | ,fFFXiMin(0) | |
154 | ,fFFXiMax(0) | |
155 | ,fFFNBinsZ(0) | |
156 | ,fFFZMin(0) | |
157 | ,fFFZMax(0) | |
158 | ,fQAJetNBinsPt(0) | |
159 | ,fQAJetPtMin(0) | |
160 | ,fQAJetPtMax(0) | |
161 | ,fQAJetNBinsEta(0) | |
162 | ,fQAJetEtaMin(0) | |
163 | ,fQAJetEtaMax(0) | |
164 | ,fQAJetNBinsPhi(0) | |
165 | ,fQAJetPhiMin(0) | |
166 | ,fQAJetPhiMax(0) | |
167 | ,fQATrackNBinsPt(0) | |
168 | ,fQATrackPtMin(0) | |
169 | ,fQATrackPtMax(0) | |
170 | ,fQATrackNBinsEta(0) | |
171 | ,fQATrackEtaMin(0) | |
172 | ,fQATrackEtaMax(0) | |
173 | ,fQATrackNBinsPhi(0) | |
174 | ,fQATrackPhiMin(0) | |
175 | ,fQATrackPhiMax(0) | |
176 | ,fIJNBinsJetPt(0) | |
177 | ,fIJJetPtMin(0) | |
178 | ,fIJJetPtMax(0) | |
179 | ,fIJNBinsPt(0) | |
180 | ,fIJPtMin(0) | |
181 | ,fIJPtMax(0) | |
182 | ,fIJNBinsZ(0) | |
183 | ,fIJZMin(0) | |
184 | ,fIJZMax(0) | |
185 | ,fIJNBinsCosTheta(0) | |
186 | ,fIJCosThetaMin(0) | |
187 | ,fIJCosThetaMax(0) | |
188 | ,fIJNBinsTheta(0) | |
189 | ,fIJThetaMin(0) | |
190 | ,fIJThetaMax(0) | |
191 | ,fIJNBinsJt(0) | |
192 | ,fIJJtMin(0) | |
193 | ,fIJJtMax(0) | |
194 | ,fDiJetNBinsJetInvMass(0) | |
195 | ,fDiJetJetInvMassMin(0) | |
196 | ,fDiJetJetInvMassMax(0) | |
197 | ,fDiJetNBinsJetPt(0) | |
198 | ,fDiJetJetPtMin(0) | |
199 | ,fDiJetJetPtMax(0) | |
200 | ,fDiJetNBinsPt(0) | |
201 | ,fDiJetPtMin(0) | |
202 | ,fDiJetPtMax(0) | |
203 | ,fDiJetNBinsXi(0) | |
204 | ,fDiJetXiMin(0) | |
205 | ,fDiJetXiMax(0) | |
206 | ,fDiJetNBinsZ(0) | |
207 | ,fDiJetZMin(0) | |
208 | ,fDiJetZMax(0) | |
209 | ,fQADiJetNBinsInvMass(0) | |
210 | ,fQADiJetInvMassMin(0) | |
211 | ,fQADiJetInvMassMax(0) | |
212 | ,fQADiJetNBinsJetPt(0) | |
213 | ,fQADiJetJetPtMin(0) | |
214 | ,fQADiJetJetPtMax(0) | |
215 | ,fQADiJetNBinsDeltaPhi(0) | |
216 | ,fQADiJetDeltaPhiMin(0) | |
217 | ,fQADiJetDeltaPhiMax(0) | |
218 | ,fQADiJetNBinsDeltaEta(0) | |
219 | ,fQADiJetDeltaEtaMin(0) | |
220 | ,fQADiJetDeltaEtaMax(0) | |
221 | ,fQADiJetNBinsDeltaPt(0) | |
222 | ,fQADiJetDeltaPtMin(0) | |
223 | ,fQADiJetDeltaPtMax(0) | |
3af23c82 | 224 | ,fQADiJetNBinsInBal(0) |
225 | ,fQADiJetInBalMin(0) | |
226 | ,fQADiJetInBalMax(0) | |
227 | ,fPhiCorrNBinsPt(0) | |
228 | ,fPhiCorrPtMin(0) | |
229 | ,fPhiCorrPtMax(0) | |
230 | ,fPhiCorrNBinsEta(0) | |
231 | ,fPhiCorrEtaMin(0) | |
232 | ,fPhiCorrEtaMax(0) | |
233 | ,fPhiCorrNBinsPhi(0) | |
234 | ,fPhiCorrPhiMin(0) | |
235 | ,fPhiCorrPhiMax(0) | |
656dc810 | 236 | ,fCommonHistList(0) |
237 | ,fh1EvtSelection(0) | |
238 | ,fh1VertexNContributors(0) | |
239 | ,fh1VertexZ(0) | |
240 | ,fh1EvtMult(0) | |
3af23c82 | 241 | ,fh1EvtCent(0) |
3170a3f8 | 242 | ,fh2TrackPtVsDCAXY(0) |
243 | ,fh2TrackPtVsDCAZ(0) | |
ac017ff3 | 244 | ,fh1Xsec(0) |
245 | ,fh1Trials(0) | |
246 | ,fh1PtHard(0) | |
247 | ,fh1PtHardTrials(0) | |
656dc810 | 248 | ,fh1nRecJetsCuts(0) |
249 | ,fh1nGenJets(0) | |
fe343c6b | 250 | ,fh1nRecEffJets(0) |
67e37e80 | 251 | ,fh1nRecBckgJetsCuts(0) |
252 | ,fh1nGenBckgJets(0) | |
cb76764e | 253 | ,fh2PtRecVsGenPrim(0) |
254 | ,fQATrackHistosRecEffGen(0) | |
255 | ,fQATrackHistosRecEffRec(0) | |
256 | ,fFFHistosRecEffGen(0) | |
3af23c82 | 257 | ,fFFHistosRecEffRec(0) |
258 | ,fhnResponseSinglePt(0) | |
259 | ,fhnResponseJetTrackPt(0) | |
260 | ,fhnResponseJetZ(0) | |
261 | ,fhnResponseJetXi(0) | |
1da9498b | 262 | // Background |
263 | ,fh1OutLeadingMult(0) | |
742ee86c | 264 | ,fh1OutLeadingStatMult(0) |
1da9498b | 265 | ,fh1PerpMult(0) |
3af23c82 | 266 | ,fh1ASideMult(0) |
267 | ,fh1ASideWindowMult(0) | |
268 | ,fh1PerpWindowMult(0) | |
1da9498b | 269 | ,fh1Out2JetsMult(0) |
270 | ,fh1Out3JetsMult(0) | |
742ee86c | 271 | ,fh1MedianClustersMult(0) |
272 | ,fh1OutClustersMult(0) | |
67e37e80 | 273 | ,fQABckgHisto0RecCuts(0) |
274 | ,fQABckgHisto0Gen(0) | |
275 | ,fQABckgHisto1RecCuts(0) | |
276 | ,fQABckgHisto1Gen(0) | |
277 | ,fQABckgHisto2RecCuts(0) | |
742ee86c | 278 | ,fQABckgHisto2Gen(0) |
279 | ,fQABckgHisto3RecCuts(0) | |
280 | ,fQABckgHisto3Gen(0) | |
3170a3f8 | 281 | ,fQABckgHisto4RecCuts(0) |
282 | ,fQABckgHisto4Gen(0) | |
67e37e80 | 283 | ,fFFBckgHisto0RecCuts(0) |
284 | ,fFFBckgHisto0RecLeading(0) | |
285 | ,fFFBckgHisto0Gen(0) | |
286 | ,fFFBckgHisto0GenLeading(0) | |
287 | ,fFFBckgHisto1RecCuts(0) | |
288 | ,fFFBckgHisto1RecLeading(0) | |
289 | ,fFFBckgHisto1Gen(0) | |
290 | ,fFFBckgHisto1GenLeading(0) | |
291 | ,fFFBckgHisto2RecCuts(0) | |
292 | ,fFFBckgHisto2RecLeading(0) | |
293 | ,fFFBckgHisto2Gen(0) | |
294 | ,fFFBckgHisto2GenLeading(0) | |
742ee86c | 295 | ,fFFBckgHisto3RecCuts(0) |
296 | ,fFFBckgHisto3RecLeading(0) | |
297 | ,fFFBckgHisto3Gen(0) | |
298 | ,fFFBckgHisto3GenLeading(0) | |
3170a3f8 | 299 | ,fFFBckgHisto4RecCuts(0) |
300 | ,fFFBckgHisto4RecLeading(0) | |
301 | ,fFFBckgHisto4Gen(0) | |
302 | ,fFFBckgHisto4GenLeading(0) | |
67e37e80 | 303 | ,fIJBckgHisto0RecCuts(0) |
304 | ,fIJBckgHisto0RecLeading(0) | |
305 | ,fIJBckgHisto0Gen(0) | |
306 | ,fIJBckgHisto0GenLeading(0) | |
307 | ,fIJBckgHisto1RecCuts(0) | |
308 | ,fIJBckgHisto1RecLeading(0) | |
309 | ,fIJBckgHisto1Gen(0) | |
310 | ,fIJBckgHisto1GenLeading(0) | |
311 | ,fIJBckgHisto2RecCuts(0) | |
312 | ,fIJBckgHisto2RecLeading(0) | |
313 | ,fIJBckgHisto2Gen(0) | |
314 | ,fIJBckgHisto2GenLeading(0) | |
742ee86c | 315 | ,fIJBckgHisto3RecCuts(0) |
316 | ,fIJBckgHisto3RecLeading(0) | |
317 | ,fIJBckgHisto3Gen(0) | |
318 | ,fIJBckgHisto3GenLeading(0) | |
3170a3f8 | 319 | ,fIJBckgHisto4RecCuts(0) |
320 | ,fIJBckgHisto4RecLeading(0) | |
321 | ,fIJBckgHisto4Gen(0) | |
322 | ,fIJBckgHisto4GenLeading(0) | |
67e37e80 | 323 | ,fRandom(0) |
3af23c82 | 324 | ,fBckgSubMethod(0) |
656dc810 | 325 | { |
326 | // default constructor | |
67e37e80 | 327 | fBckgType[0] = 0; |
328 | fBckgType[1] = 0; | |
329 | fBckgType[2] = 0; | |
742ee86c | 330 | fBckgType[3] = 0; |
3170a3f8 | 331 | fBckgType[4] = 0; |
656dc810 | 332 | } |
333 | ||
334 | //__________________________________________________________________________________________ | |
335 | AliAnalysisTaskFragmentationFunction::AliAnalysisTaskFragmentationFunction(const char *name) | |
336 | : AliAnalysisTaskSE(name) | |
337 | ,fESD(0) | |
338 | ,fAOD(0) | |
40445651 | 339 | ,fAODExtension(0) |
340 | ,fNonStdFile("") | |
656dc810 | 341 | ,fBranchRecJets("jets") |
44b235ce | 342 | ,fBranchRecBackJets("") |
742ee86c | 343 | ,fBranchRecBckgClusters("") |
656dc810 | 344 | ,fBranchGenJets("") |
345 | ,fTrackTypeGen(0) | |
346 | ,fJetTypeGen(0) | |
fe343c6b | 347 | ,fJetTypeRecEff(0) |
656dc810 | 348 | ,fFilterMask(0) |
ac017ff3 | 349 | ,fUsePhysicsSelection(kTRUE) |
3af23c82 | 350 | ,fEventClass(0) |
351 | ,fMaxVertexZ(10) | |
656dc810 | 352 | ,fTrackPtCut(0) |
353 | ,fTrackEtaMin(0) | |
354 | ,fTrackEtaMax(0) | |
355 | ,fTrackPhiMin(0) | |
356 | ,fTrackPhiMax(0) | |
357 | ,fJetPtCut(0) | |
358 | ,fJetEtaMin(0) | |
359 | ,fJetEtaMax(0) | |
360 | ,fJetPhiMin(0) | |
361 | ,fJetPhiMax(0) | |
362 | ,fDiJetCut(0) | |
363 | ,fDiJetDeltaPhiCut(0) | |
364 | ,fDiJetPtFractionCut(0) | |
365 | ,fDiJetCDFCut(0) | |
366 | ,fDiJetKindBins(0) | |
367 | ,fFFRadius(0) | |
1da9498b | 368 | ,fFFBckgRadius(0) |
369 | ,fBckgMode(0) | |
67e37e80 | 370 | ,fIJMode(0) |
3af23c82 | 371 | ,fQAMode(0) |
372 | ,fFFMode(0) | |
373 | ,fDJMode(0) | |
374 | ,fEffMode(0) | |
375 | ,fPhiCorrMode(0) | |
742ee86c | 376 | ,fUseRecEffRecJetPtBins(0) |
377 | ,fUseResponseRecJetPtBins(1) | |
c2658535 | 378 | ,fAvgTrials(0) |
656dc810 | 379 | ,fTracksRec(0) |
380 | ,fTracksRecCuts(0) | |
381 | ,fTracksGen(0) | |
fe343c6b | 382 | ,fTracksAODMCCharged(0) |
383 | ,fTracksRecQualityCuts(0) | |
656dc810 | 384 | ,fJetsRec(0) |
385 | ,fJetsRecCuts(0) | |
386 | ,fJetsGen(0) | |
fe343c6b | 387 | ,fJetsRecEff(0) |
67e37e80 | 388 | ,fBckgJetsRec(0) |
389 | ,fBckgJetsRecCuts(0) | |
390 | ,fBckgJetsGen(0) | |
656dc810 | 391 | ,fQATrackHistosRec(0) |
392 | ,fQATrackHistosRecCuts(0) | |
393 | ,fQATrackHistosGen(0) | |
394 | ,fQAJetHistosRec(0) | |
395 | ,fQAJetHistosRecCuts(0) | |
396 | ,fQAJetHistosRecCutsLeading(0) | |
397 | ,fQAJetHistosGen(0) | |
398 | ,fQAJetHistosGenLeading(0) | |
fe343c6b | 399 | ,fQAJetHistosRecEffLeading(0) |
656dc810 | 400 | ,fFFHistosRecCuts(0) |
401 | ,fFFHistosRecLeading(0) | |
402 | ,fFFHistosRecLeadingTrack(0) | |
403 | ,fFFHistosGen(0) | |
404 | ,fFFHistosGenLeading(0) | |
405 | ,fFFHistosGenLeadingTrack(0) | |
406 | ,fIJHistosRecCuts(0) | |
407 | ,fIJHistosRecLeading(0) | |
408 | ,fIJHistosRecLeadingTrack(0) | |
409 | ,fIJHistosGen(0) | |
410 | ,fIJHistosGenLeading(0) | |
411 | ,fIJHistosGenLeadingTrack(0) | |
412 | ,fFFDiJetHistosRecCuts(0) | |
413 | ,fFFDiJetHistosRecLeading(0) | |
414 | ,fFFDiJetHistosRecLeadingTrack(0) | |
415 | ,fFFDiJetHistosGen(0) | |
416 | ,fFFDiJetHistosGenLeading(0) | |
417 | ,fFFDiJetHistosGenLeadingTrack(0) | |
418 | ,fQADiJetHistosRecCuts(0) | |
419 | ,fQADiJetHistosGen(0) | |
3af23c82 | 420 | ,fPhiCorrHistosJetArea(0) |
421 | ,fPhiCorrHistosTransverseArea(0) | |
422 | ,fPhiCorrHistosAwayArea(0) | |
656dc810 | 423 | ,fQATrackHighPtThreshold(0) |
424 | ,fFFNBinsJetPt(0) | |
425 | ,fFFJetPtMin(0) | |
426 | ,fFFJetPtMax(0) | |
427 | ,fFFNBinsPt(0) | |
428 | ,fFFPtMin(0) | |
429 | ,fFFPtMax(0) | |
430 | ,fFFNBinsXi(0) | |
431 | ,fFFXiMin(0) | |
432 | ,fFFXiMax(0) | |
433 | ,fFFNBinsZ(0) | |
434 | ,fFFZMin(0) | |
435 | ,fFFZMax(0) | |
436 | ,fQAJetNBinsPt(0) | |
437 | ,fQAJetPtMin(0) | |
438 | ,fQAJetPtMax(0) | |
439 | ,fQAJetNBinsEta(0) | |
440 | ,fQAJetEtaMin(0) | |
441 | ,fQAJetEtaMax(0) | |
442 | ,fQAJetNBinsPhi(0) | |
443 | ,fQAJetPhiMin(0) | |
444 | ,fQAJetPhiMax(0) | |
445 | ,fQATrackNBinsPt(0) | |
446 | ,fQATrackPtMin(0) | |
447 | ,fQATrackPtMax(0) | |
448 | ,fQATrackNBinsEta(0) | |
449 | ,fQATrackEtaMin(0) | |
450 | ,fQATrackEtaMax(0) | |
451 | ,fQATrackNBinsPhi(0) | |
452 | ,fQATrackPhiMin(0) | |
453 | ,fQATrackPhiMax(0) | |
454 | ,fIJNBinsJetPt(0) | |
455 | ,fIJJetPtMin(0) | |
456 | ,fIJJetPtMax(0) | |
457 | ,fIJNBinsPt(0) | |
458 | ,fIJPtMin(0) | |
459 | ,fIJPtMax(0) | |
460 | ,fIJNBinsZ(0) | |
461 | ,fIJZMin(0) | |
462 | ,fIJZMax(0) | |
463 | ,fIJNBinsCosTheta(0) | |
464 | ,fIJCosThetaMin(0) | |
465 | ,fIJCosThetaMax(0) | |
466 | ,fIJNBinsTheta(0) | |
467 | ,fIJThetaMin(0) | |
468 | ,fIJThetaMax(0) | |
469 | ,fIJNBinsJt(0) | |
470 | ,fIJJtMin(0) | |
471 | ,fIJJtMax(0) | |
472 | ,fDiJetNBinsJetInvMass(0) | |
473 | ,fDiJetJetInvMassMin(0) | |
474 | ,fDiJetJetInvMassMax(0) | |
475 | ,fDiJetNBinsJetPt(0) | |
476 | ,fDiJetJetPtMin(0) | |
477 | ,fDiJetJetPtMax(0) | |
478 | ,fDiJetNBinsPt(0) | |
479 | ,fDiJetPtMin(0) | |
480 | ,fDiJetPtMax(0) | |
481 | ,fDiJetNBinsXi(0) | |
482 | ,fDiJetXiMin(0) | |
483 | ,fDiJetXiMax(0) | |
484 | ,fDiJetNBinsZ(0) | |
485 | ,fDiJetZMin(0) | |
486 | ,fDiJetZMax(0) | |
487 | ,fQADiJetNBinsInvMass(0) | |
488 | ,fQADiJetInvMassMin(0) | |
489 | ,fQADiJetInvMassMax(0) | |
490 | ,fQADiJetNBinsJetPt(0) | |
491 | ,fQADiJetJetPtMin(0) | |
492 | ,fQADiJetJetPtMax(0) | |
493 | ,fQADiJetNBinsDeltaPhi(0) | |
494 | ,fQADiJetDeltaPhiMin(0) | |
495 | ,fQADiJetDeltaPhiMax(0) | |
496 | ,fQADiJetNBinsDeltaEta(0) | |
497 | ,fQADiJetDeltaEtaMin(0) | |
498 | ,fQADiJetDeltaEtaMax(0) | |
499 | ,fQADiJetNBinsDeltaPt(0) | |
500 | ,fQADiJetDeltaPtMin(0) | |
501 | ,fQADiJetDeltaPtMax(0) | |
3af23c82 | 502 | ,fQADiJetNBinsInBal(0) |
503 | ,fQADiJetInBalMin(0) | |
504 | ,fQADiJetInBalMax(0) | |
505 | ,fPhiCorrNBinsPt(0) | |
506 | ,fPhiCorrPtMin(0) | |
507 | ,fPhiCorrPtMax(0) | |
508 | ,fPhiCorrNBinsEta(0) | |
509 | ,fPhiCorrEtaMin(0) | |
510 | ,fPhiCorrEtaMax(0) | |
511 | ,fPhiCorrNBinsPhi(0) | |
512 | ,fPhiCorrPhiMin(0) | |
513 | ,fPhiCorrPhiMax(0) | |
656dc810 | 514 | ,fCommonHistList(0) |
515 | ,fh1EvtSelection(0) | |
516 | ,fh1VertexNContributors(0) | |
517 | ,fh1VertexZ(0) | |
518 | ,fh1EvtMult(0) | |
3af23c82 | 519 | ,fh1EvtCent(0) |
3170a3f8 | 520 | ,fh2TrackPtVsDCAXY(0) |
521 | ,fh2TrackPtVsDCAZ(0) | |
ac017ff3 | 522 | ,fh1Xsec(0) |
523 | ,fh1Trials(0) | |
524 | ,fh1PtHard(0) | |
525 | ,fh1PtHardTrials(0) | |
656dc810 | 526 | ,fh1nRecJetsCuts(0) |
527 | ,fh1nGenJets(0) | |
fe343c6b | 528 | ,fh1nRecEffJets(0) |
67e37e80 | 529 | ,fh1nRecBckgJetsCuts(0) |
530 | ,fh1nGenBckgJets(0) | |
cb76764e | 531 | ,fh2PtRecVsGenPrim(0) |
532 | ,fQATrackHistosRecEffGen(0) | |
533 | ,fQATrackHistosRecEffRec(0) | |
534 | ,fFFHistosRecEffGen(0) | |
3af23c82 | 535 | ,fFFHistosRecEffRec(0) |
536 | ,fhnResponseSinglePt(0) | |
537 | ,fhnResponseJetTrackPt(0) | |
538 | ,fhnResponseJetZ(0) | |
539 | ,fhnResponseJetXi(0) | |
67e37e80 | 540 | // Background |
541 | ,fh1OutLeadingMult(0) | |
742ee86c | 542 | ,fh1OutLeadingStatMult(0) |
67e37e80 | 543 | ,fh1PerpMult(0) |
3af23c82 | 544 | ,fh1ASideMult(0) |
545 | ,fh1ASideWindowMult(0) | |
546 | ,fh1PerpWindowMult(0) | |
67e37e80 | 547 | ,fh1Out2JetsMult(0) |
548 | ,fh1Out3JetsMult(0) | |
742ee86c | 549 | ,fh1MedianClustersMult(0) |
550 | ,fh1OutClustersMult(0) | |
67e37e80 | 551 | ,fQABckgHisto0RecCuts(0) |
552 | ,fQABckgHisto0Gen(0) | |
553 | ,fQABckgHisto1RecCuts(0) | |
554 | ,fQABckgHisto1Gen(0) | |
555 | ,fQABckgHisto2RecCuts(0) | |
742ee86c | 556 | ,fQABckgHisto2Gen(0) |
557 | ,fQABckgHisto3RecCuts(0) | |
558 | ,fQABckgHisto3Gen(0) | |
3170a3f8 | 559 | ,fQABckgHisto4RecCuts(0) |
560 | ,fQABckgHisto4Gen(0) | |
67e37e80 | 561 | ,fFFBckgHisto0RecCuts(0) |
562 | ,fFFBckgHisto0RecLeading(0) | |
563 | ,fFFBckgHisto0Gen(0) | |
564 | ,fFFBckgHisto0GenLeading(0) | |
565 | ,fFFBckgHisto1RecCuts(0) | |
566 | ,fFFBckgHisto1RecLeading(0) | |
567 | ,fFFBckgHisto1Gen(0) | |
568 | ,fFFBckgHisto1GenLeading(0) | |
569 | ,fFFBckgHisto2RecCuts(0) | |
570 | ,fFFBckgHisto2RecLeading(0) | |
571 | ,fFFBckgHisto2Gen(0) | |
572 | ,fFFBckgHisto2GenLeading(0) | |
742ee86c | 573 | ,fFFBckgHisto3RecCuts(0) |
574 | ,fFFBckgHisto3RecLeading(0) | |
575 | ,fFFBckgHisto3Gen(0) | |
576 | ,fFFBckgHisto3GenLeading(0) | |
3170a3f8 | 577 | ,fFFBckgHisto4RecCuts(0) |
578 | ,fFFBckgHisto4RecLeading(0) | |
579 | ,fFFBckgHisto4Gen(0) | |
580 | ,fFFBckgHisto4GenLeading(0) | |
67e37e80 | 581 | ,fIJBckgHisto0RecCuts(0) |
582 | ,fIJBckgHisto0RecLeading(0) | |
583 | ,fIJBckgHisto0Gen(0) | |
584 | ,fIJBckgHisto0GenLeading(0) | |
585 | ,fIJBckgHisto1RecCuts(0) | |
586 | ,fIJBckgHisto1RecLeading(0) | |
587 | ,fIJBckgHisto1Gen(0) | |
588 | ,fIJBckgHisto1GenLeading(0) | |
589 | ,fIJBckgHisto2RecCuts(0) | |
590 | ,fIJBckgHisto2RecLeading(0) | |
591 | ,fIJBckgHisto2Gen(0) | |
592 | ,fIJBckgHisto2GenLeading(0) | |
742ee86c | 593 | ,fIJBckgHisto3RecCuts(0) |
594 | ,fIJBckgHisto3RecLeading(0) | |
595 | ,fIJBckgHisto3Gen(0) | |
596 | ,fIJBckgHisto3GenLeading(0) | |
3170a3f8 | 597 | ,fIJBckgHisto4RecCuts(0) |
598 | ,fIJBckgHisto4RecLeading(0) | |
599 | ,fIJBckgHisto4Gen(0) | |
600 | ,fIJBckgHisto4GenLeading(0) | |
67e37e80 | 601 | ,fRandom(0) |
3af23c82 | 602 | ,fBckgSubMethod(0) |
656dc810 | 603 | { |
604 | // constructor | |
67e37e80 | 605 | fBckgType[0] = 0; |
606 | fBckgType[1] = 0; | |
607 | fBckgType[2] = 0; | |
742ee86c | 608 | fBckgType[3] = 0; |
3170a3f8 | 609 | fBckgType[4] = 0; |
67e37e80 | 610 | |
656dc810 | 611 | DefineOutput(1,TList::Class()); |
612 | ||
613 | ||
614 | } | |
615 | ||
616 | //__________________________________________________________________________________________________________________________ | |
617 | AliAnalysisTaskFragmentationFunction::AliAnalysisTaskFragmentationFunction(const AliAnalysisTaskFragmentationFunction ©) | |
618 | : AliAnalysisTaskSE() | |
619 | ,fESD(copy.fESD) | |
620 | ,fAOD(copy.fAOD) | |
40445651 | 621 | ,fAODExtension(copy.fAODExtension) |
622 | ,fNonStdFile(copy.fNonStdFile) | |
656dc810 | 623 | ,fBranchRecJets(copy.fBranchRecJets) |
3af23c82 | 624 | ,fBranchRecBackJets(copy.fBranchRecBackJets) |
742ee86c | 625 | ,fBranchRecBckgClusters(copy.fBranchRecBckgClusters) |
656dc810 | 626 | ,fBranchGenJets(copy.fBranchGenJets) |
627 | ,fTrackTypeGen(copy.fTrackTypeGen) | |
628 | ,fJetTypeGen(copy.fJetTypeGen) | |
fe343c6b | 629 | ,fJetTypeRecEff(copy.fJetTypeRecEff) |
656dc810 | 630 | ,fFilterMask(copy.fFilterMask) |
ac017ff3 | 631 | ,fUsePhysicsSelection(copy.fUsePhysicsSelection) |
3af23c82 | 632 | ,fEventClass(copy.fEventClass) |
633 | ,fMaxVertexZ(copy.fMaxVertexZ) | |
656dc810 | 634 | ,fTrackPtCut(copy.fTrackPtCut) |
635 | ,fTrackEtaMin(copy.fTrackEtaMin) | |
636 | ,fTrackEtaMax(copy.fTrackEtaMax) | |
637 | ,fTrackPhiMin(copy.fTrackPhiMin) | |
638 | ,fTrackPhiMax(copy.fTrackPhiMax) | |
639 | ,fJetPtCut(copy.fJetPtCut) | |
640 | ,fJetEtaMin(copy.fJetEtaMin) | |
641 | ,fJetEtaMax(copy.fJetEtaMax) | |
642 | ,fJetPhiMin(copy.fJetPhiMin) | |
fe343c6b | 643 | ,fJetPhiMax(copy.fJetPhiMax) |
656dc810 | 644 | ,fDiJetCut(copy.fDiJetCut) |
645 | ,fDiJetDeltaPhiCut(copy.fDiJetDeltaPhiCut) | |
646 | ,fDiJetPtFractionCut(copy.fDiJetPtFractionCut) | |
647 | ,fDiJetCDFCut(copy.fDiJetCDFCut) | |
648 | ,fDiJetKindBins(copy.fDiJetKindBins) | |
649 | ,fFFRadius(copy.fFFRadius) | |
1da9498b | 650 | ,fFFBckgRadius(copy.fFFBckgRadius) |
651 | ,fBckgMode(copy.fBckgMode) | |
67e37e80 | 652 | ,fIJMode(copy.fIJMode) |
3af23c82 | 653 | ,fQAMode(copy.fQAMode) |
654 | ,fFFMode(copy.fFFMode) | |
655 | ,fDJMode(copy.fDJMode) | |
656 | ,fEffMode(copy.fEffMode) | |
657 | ,fPhiCorrMode(copy.fPhiCorrMode) | |
cb76764e | 658 | ,fUseRecEffRecJetPtBins(copy.fUseRecEffRecJetPtBins) |
742ee86c | 659 | ,fUseResponseRecJetPtBins(copy.fUseResponseRecJetPtBins) |
c2658535 | 660 | ,fAvgTrials(copy.fAvgTrials) |
656dc810 | 661 | ,fTracksRec(copy.fTracksRec) |
662 | ,fTracksRecCuts(copy.fTracksRecCuts) | |
663 | ,fTracksGen(copy.fTracksGen) | |
fe343c6b | 664 | ,fTracksAODMCCharged(copy.fTracksAODMCCharged) |
665 | ,fTracksRecQualityCuts(copy.fTracksRecQualityCuts) | |
656dc810 | 666 | ,fJetsRec(copy.fJetsRec) |
667 | ,fJetsRecCuts(copy.fJetsRecCuts) | |
668 | ,fJetsGen(copy.fJetsGen) | |
fe343c6b | 669 | ,fJetsRecEff(copy.fJetsRecEff) |
67e37e80 | 670 | ,fBckgJetsRec(copy.fBckgJetsRec) |
671 | ,fBckgJetsRecCuts(copy.fBckgJetsRecCuts) | |
672 | ,fBckgJetsGen(copy.fBckgJetsGen) | |
656dc810 | 673 | ,fQATrackHistosRec(copy.fQATrackHistosRec) |
674 | ,fQATrackHistosRecCuts(copy.fQATrackHistosRecCuts) | |
675 | ,fQATrackHistosGen(copy.fQATrackHistosGen) | |
676 | ,fQAJetHistosRec(copy.fQAJetHistosRec) | |
677 | ,fQAJetHistosRecCuts(copy.fQAJetHistosRecCuts) | |
678 | ,fQAJetHistosRecCutsLeading(copy.fQAJetHistosRecCutsLeading) | |
679 | ,fQAJetHistosGen(copy.fQAJetHistosGen) | |
680 | ,fQAJetHistosGenLeading(copy.fQAJetHistosGenLeading) | |
fe343c6b | 681 | ,fQAJetHistosRecEffLeading(copy.fQAJetHistosRecEffLeading) |
656dc810 | 682 | ,fFFHistosRecCuts(copy.fFFHistosRecCuts) |
683 | ,fFFHistosRecLeading(copy.fFFHistosRecLeading) | |
684 | ,fFFHistosRecLeadingTrack(copy.fFFHistosRecLeadingTrack) | |
685 | ,fFFHistosGen(copy.fFFHistosGen) | |
686 | ,fFFHistosGenLeading(copy.fFFHistosGenLeading) | |
687 | ,fFFHistosGenLeadingTrack(copy.fFFHistosGenLeadingTrack) | |
688 | ,fIJHistosRecCuts(copy.fIJHistosRecCuts) | |
689 | ,fIJHistosRecLeading(copy.fIJHistosRecLeading) | |
690 | ,fIJHistosRecLeadingTrack(copy.fIJHistosRecLeadingTrack) | |
691 | ,fIJHistosGen(copy.fIJHistosGen) | |
692 | ,fIJHistosGenLeading(copy.fIJHistosGenLeading) | |
693 | ,fIJHistosGenLeadingTrack(copy.fIJHistosGenLeadingTrack) | |
694 | ,fFFDiJetHistosRecCuts(copy.fFFDiJetHistosRecCuts) | |
695 | ,fFFDiJetHistosRecLeading(copy.fFFDiJetHistosRecLeading) | |
696 | ,fFFDiJetHistosRecLeadingTrack(copy.fFFDiJetHistosRecLeadingTrack) | |
697 | ,fFFDiJetHistosGen(copy.fFFDiJetHistosGen) | |
698 | ,fFFDiJetHistosGenLeading(copy.fFFDiJetHistosGenLeading) | |
699 | ,fFFDiJetHistosGenLeadingTrack(copy.fFFDiJetHistosGenLeadingTrack) | |
700 | ,fQADiJetHistosRecCuts(copy.fQADiJetHistosRecCuts) | |
701 | ,fQADiJetHistosGen(copy.fQADiJetHistosGen) | |
3af23c82 | 702 | ,fPhiCorrHistosJetArea(copy.fPhiCorrHistosJetArea) |
703 | ,fPhiCorrHistosTransverseArea(copy.fPhiCorrHistosTransverseArea) | |
704 | ,fPhiCorrHistosAwayArea(copy.fPhiCorrHistosAwayArea) | |
656dc810 | 705 | ,fQATrackHighPtThreshold(copy.fQATrackHighPtThreshold) |
706 | ,fFFNBinsJetPt(copy.fFFNBinsJetPt) | |
707 | ,fFFJetPtMin(copy.fFFJetPtMin) | |
708 | ,fFFJetPtMax(copy.fFFJetPtMax) | |
709 | ,fFFNBinsPt(copy.fFFNBinsPt) | |
710 | ,fFFPtMin(copy.fFFPtMin) | |
711 | ,fFFPtMax(copy.fFFPtMax) | |
712 | ,fFFNBinsXi(copy.fFFNBinsXi) | |
713 | ,fFFXiMin(copy.fFFXiMin) | |
714 | ,fFFXiMax(copy.fFFXiMax) | |
715 | ,fFFNBinsZ(copy.fFFNBinsZ) | |
716 | ,fFFZMin(copy.fFFZMin) | |
717 | ,fFFZMax(copy.fFFZMax) | |
718 | ,fQAJetNBinsPt(copy.fQAJetNBinsPt) | |
719 | ,fQAJetPtMin(copy.fQAJetPtMin) | |
720 | ,fQAJetPtMax(copy.fQAJetPtMax) | |
721 | ,fQAJetNBinsEta(copy.fQAJetNBinsEta) | |
722 | ,fQAJetEtaMin(copy.fQAJetEtaMin) | |
723 | ,fQAJetEtaMax(copy.fQAJetEtaMax) | |
724 | ,fQAJetNBinsPhi(copy.fQAJetNBinsPhi) | |
725 | ,fQAJetPhiMin(copy.fQAJetPhiMin) | |
726 | ,fQAJetPhiMax(copy.fQAJetPhiMax) | |
727 | ,fQATrackNBinsPt(copy.fQATrackNBinsPt) | |
728 | ,fQATrackPtMin(copy.fQATrackPtMin) | |
729 | ,fQATrackPtMax(copy.fQATrackPtMax) | |
730 | ,fQATrackNBinsEta(copy.fQATrackNBinsEta) | |
731 | ,fQATrackEtaMin(copy.fQATrackEtaMin) | |
732 | ,fQATrackEtaMax(copy.fQATrackEtaMax) | |
733 | ,fQATrackNBinsPhi(copy.fQATrackNBinsPhi) | |
734 | ,fQATrackPhiMin(copy.fQATrackPhiMin) | |
735 | ,fQATrackPhiMax(copy.fQATrackPhiMax) | |
736 | ,fIJNBinsJetPt(copy.fIJNBinsJetPt) | |
737 | ,fIJJetPtMin(copy.fIJJetPtMin) | |
738 | ,fIJJetPtMax(copy.fIJJetPtMax) | |
739 | ,fIJNBinsPt(copy.fIJNBinsPt) | |
740 | ,fIJPtMin(copy.fIJPtMin) | |
741 | ,fIJPtMax(copy.fIJPtMax) | |
742 | ,fIJNBinsZ(copy.fIJNBinsZ) | |
743 | ,fIJZMin(copy.fIJZMin) | |
744 | ,fIJZMax(copy.fIJZMax) | |
745 | ,fIJNBinsCosTheta(copy.fIJNBinsCosTheta) | |
746 | ,fIJCosThetaMin(copy.fIJCosThetaMin) | |
747 | ,fIJCosThetaMax(copy.fIJCosThetaMax) | |
748 | ,fIJNBinsTheta(copy.fIJNBinsTheta) | |
749 | ,fIJThetaMin(copy.fIJThetaMin) | |
750 | ,fIJThetaMax(copy.fIJThetaMax) | |
751 | ,fIJNBinsJt(copy.fIJNBinsJt) | |
752 | ,fIJJtMin(copy.fIJJtMin) | |
753 | ,fIJJtMax(copy.fIJJtMax) | |
754 | ,fDiJetNBinsJetInvMass(copy.fDiJetNBinsJetInvMass) | |
755 | ,fDiJetJetInvMassMin(copy.fDiJetJetInvMassMin) | |
756 | ,fDiJetJetInvMassMax(copy.fDiJetJetInvMassMax) | |
757 | ,fDiJetNBinsJetPt(copy.fDiJetNBinsJetPt) | |
758 | ,fDiJetJetPtMin(copy.fDiJetJetPtMin) | |
759 | ,fDiJetJetPtMax(copy.fDiJetJetPtMax) | |
760 | ,fDiJetNBinsPt(copy.fDiJetNBinsPt) | |
761 | ,fDiJetPtMin(copy.fDiJetPtMin) | |
762 | ,fDiJetPtMax(copy.fDiJetPtMax) | |
763 | ,fDiJetNBinsXi(copy.fDiJetNBinsXi) | |
764 | ,fDiJetXiMin(copy.fDiJetXiMin) | |
765 | ,fDiJetXiMax(copy.fDiJetXiMax) | |
766 | ,fDiJetNBinsZ(copy.fDiJetNBinsZ) | |
767 | ,fDiJetZMin(copy.fDiJetZMin) | |
768 | ,fDiJetZMax(copy.fDiJetZMax) | |
769 | ,fQADiJetNBinsInvMass(copy.fQADiJetNBinsInvMass) | |
770 | ,fQADiJetInvMassMin(copy.fQADiJetInvMassMin) | |
771 | ,fQADiJetInvMassMax(copy.fQADiJetInvMassMax) | |
772 | ,fQADiJetNBinsJetPt(copy.fQADiJetNBinsJetPt) | |
773 | ,fQADiJetJetPtMin(copy.fQADiJetJetPtMin) | |
774 | ,fQADiJetJetPtMax(copy.fQADiJetJetPtMax) | |
775 | ,fQADiJetNBinsDeltaPhi(copy.fQADiJetNBinsDeltaPhi) | |
776 | ,fQADiJetDeltaPhiMin(copy.fQADiJetDeltaPhiMin) | |
777 | ,fQADiJetDeltaPhiMax(copy.fQADiJetDeltaPhiMax) | |
778 | ,fQADiJetNBinsDeltaEta(copy.fQADiJetNBinsDeltaEta) | |
779 | ,fQADiJetDeltaEtaMin(copy.fQADiJetDeltaEtaMin) | |
780 | ,fQADiJetDeltaEtaMax(copy.fQADiJetDeltaEtaMax) | |
781 | ,fQADiJetNBinsDeltaPt(copy.fQADiJetNBinsDeltaPt) | |
782 | ,fQADiJetDeltaPtMin(copy.fQADiJetDeltaPtMin) | |
783 | ,fQADiJetDeltaPtMax(copy.fQADiJetDeltaPtMax) | |
3af23c82 | 784 | ,fQADiJetNBinsInBal(copy.fQADiJetNBinsInBal) |
785 | ,fQADiJetInBalMin(copy.fQADiJetInBalMin) | |
786 | ,fQADiJetInBalMax(copy.fQADiJetInBalMax) | |
787 | ,fPhiCorrNBinsPt(copy.fPhiCorrNBinsPt) | |
788 | ,fPhiCorrPtMin(copy.fPhiCorrPtMin) | |
789 | ,fPhiCorrPtMax(copy.fPhiCorrPtMax) | |
790 | ,fPhiCorrNBinsEta(copy.fPhiCorrNBinsEta) | |
791 | ,fPhiCorrEtaMin(copy.fPhiCorrEtaMin) | |
792 | ,fPhiCorrEtaMax(copy.fPhiCorrEtaMax) | |
793 | ,fPhiCorrNBinsPhi(copy.fPhiCorrNBinsPhi) | |
794 | ,fPhiCorrPhiMin(copy.fPhiCorrPhiMin) | |
795 | ,fPhiCorrPhiMax(copy.fPhiCorrPhiMax) | |
656dc810 | 796 | ,fCommonHistList(copy.fCommonHistList) |
797 | ,fh1EvtSelection(copy.fh1EvtSelection) | |
798 | ,fh1VertexNContributors(copy.fh1VertexNContributors) | |
799 | ,fh1VertexZ(copy.fh1VertexZ) | |
800 | ,fh1EvtMult(copy.fh1EvtMult) | |
3af23c82 | 801 | ,fh1EvtCent(copy.fh1EvtCent) |
3170a3f8 | 802 | ,fh2TrackPtVsDCAXY(copy.fh2TrackPtVsDCAXY) |
803 | ,fh2TrackPtVsDCAZ(copy.fh2TrackPtVsDCAXY) | |
ac017ff3 | 804 | ,fh1Xsec(copy.fh1Xsec) |
805 | ,fh1Trials(copy.fh1Trials) | |
806 | ,fh1PtHard(copy.fh1PtHard) | |
807 | ,fh1PtHardTrials(copy.fh1PtHardTrials) | |
656dc810 | 808 | ,fh1nRecJetsCuts(copy.fh1nRecJetsCuts) |
809 | ,fh1nGenJets(copy.fh1nGenJets) | |
fe343c6b | 810 | ,fh1nRecEffJets(copy.fh1nRecEffJets) |
67e37e80 | 811 | ,fh1nRecBckgJetsCuts(copy.fh1nRecBckgJetsCuts) |
812 | ,fh1nGenBckgJets(copy.fh1nGenBckgJets) | |
cb76764e | 813 | ,fh2PtRecVsGenPrim(copy.fh2PtRecVsGenPrim) |
814 | ,fQATrackHistosRecEffGen(copy.fQATrackHistosRecEffGen) | |
815 | ,fQATrackHistosRecEffRec(copy.fQATrackHistosRecEffRec) | |
816 | ,fFFHistosRecEffGen(copy.fFFHistosRecEffGen) | |
817 | ,fFFHistosRecEffRec(copy.fFFHistosRecEffRec) | |
3af23c82 | 818 | ,fhnResponseSinglePt(copy.fhnResponseSinglePt) |
819 | ,fhnResponseJetTrackPt(copy.fhnResponseJetTrackPt) | |
820 | ,fhnResponseJetZ(copy.fhnResponseJetZ) | |
821 | ,fhnResponseJetXi(copy.fhnResponseJetXi) | |
1da9498b | 822 | // Background |
823 | ,fh1OutLeadingMult(copy.fh1OutLeadingMult) | |
742ee86c | 824 | ,fh1OutLeadingStatMult(copy.fh1OutLeadingStatMult) |
1da9498b | 825 | ,fh1PerpMult(copy.fh1PerpMult) |
3af23c82 | 826 | ,fh1ASideMult(copy.fh1ASideMult) |
827 | ,fh1ASideWindowMult(copy.fh1ASideWindowMult) | |
828 | ,fh1PerpWindowMult(copy.fh1PerpWindowMult) | |
1da9498b | 829 | ,fh1Out2JetsMult(copy.fh1Out2JetsMult) |
830 | ,fh1Out3JetsMult(copy.fh1Out3JetsMult) | |
742ee86c | 831 | ,fh1MedianClustersMult(copy.fh1MedianClustersMult) |
832 | ,fh1OutClustersMult(copy.fh1OutClustersMult) | |
67e37e80 | 833 | ,fQABckgHisto0RecCuts(copy.fQABckgHisto0RecCuts) |
834 | ,fQABckgHisto0Gen(copy.fQABckgHisto0Gen) | |
835 | ,fQABckgHisto1RecCuts(copy.fQABckgHisto1RecCuts) | |
836 | ,fQABckgHisto1Gen(copy.fQABckgHisto1Gen) | |
837 | ,fQABckgHisto2RecCuts(copy.fQABckgHisto2RecCuts) | |
742ee86c | 838 | ,fQABckgHisto2Gen(copy.fQABckgHisto2Gen) |
839 | ,fQABckgHisto3RecCuts(copy.fQABckgHisto3RecCuts) | |
840 | ,fQABckgHisto3Gen(copy.fQABckgHisto3Gen) | |
3170a3f8 | 841 | ,fQABckgHisto4RecCuts(copy.fQABckgHisto4RecCuts) |
842 | ,fQABckgHisto4Gen(copy.fQABckgHisto4Gen) | |
67e37e80 | 843 | ,fFFBckgHisto0RecCuts(copy.fFFBckgHisto0RecCuts) |
844 | ,fFFBckgHisto0RecLeading(copy.fFFBckgHisto0RecLeading) | |
845 | ,fFFBckgHisto0Gen(copy.fFFBckgHisto0Gen) | |
846 | ,fFFBckgHisto0GenLeading(copy.fFFBckgHisto0GenLeading) | |
847 | ,fFFBckgHisto1RecCuts(copy.fFFBckgHisto1RecCuts) | |
848 | ,fFFBckgHisto1RecLeading(copy.fFFBckgHisto1RecLeading) | |
849 | ,fFFBckgHisto1Gen(copy.fFFBckgHisto1Gen) | |
850 | ,fFFBckgHisto1GenLeading(copy.fFFBckgHisto1GenLeading) | |
851 | ,fFFBckgHisto2RecCuts(copy.fFFBckgHisto2RecCuts) | |
852 | ,fFFBckgHisto2RecLeading(copy.fFFBckgHisto2RecLeading) | |
853 | ,fFFBckgHisto2Gen(copy.fFFBckgHisto2Gen) | |
854 | ,fFFBckgHisto2GenLeading(copy.fFFBckgHisto2GenLeading) | |
742ee86c | 855 | ,fFFBckgHisto3RecCuts(copy.fFFBckgHisto3RecCuts) |
856 | ,fFFBckgHisto3RecLeading(copy.fFFBckgHisto3RecLeading) | |
857 | ,fFFBckgHisto3Gen(copy.fFFBckgHisto3Gen) | |
858 | ,fFFBckgHisto3GenLeading(copy.fFFBckgHisto3GenLeading) | |
3170a3f8 | 859 | ,fFFBckgHisto4RecCuts(copy.fFFBckgHisto4RecCuts) |
860 | ,fFFBckgHisto4RecLeading(copy.fFFBckgHisto4RecLeading) | |
861 | ,fFFBckgHisto4Gen(copy.fFFBckgHisto4Gen) | |
862 | ,fFFBckgHisto4GenLeading(copy.fFFBckgHisto4GenLeading) | |
67e37e80 | 863 | ,fIJBckgHisto0RecCuts(copy.fIJBckgHisto0RecCuts) |
864 | ,fIJBckgHisto0RecLeading(copy.fIJBckgHisto0RecLeading) | |
865 | ,fIJBckgHisto0Gen(copy.fIJBckgHisto0Gen) | |
866 | ,fIJBckgHisto0GenLeading(copy.fIJBckgHisto0GenLeading) | |
867 | ,fIJBckgHisto1RecCuts(copy.fIJBckgHisto1RecCuts) | |
868 | ,fIJBckgHisto1RecLeading(copy.fIJBckgHisto1RecLeading) | |
869 | ,fIJBckgHisto1Gen(copy.fIJBckgHisto1Gen) | |
870 | ,fIJBckgHisto1GenLeading(copy.fIJBckgHisto1GenLeading) | |
871 | ,fIJBckgHisto2RecCuts(copy.fIJBckgHisto2RecCuts) | |
872 | ,fIJBckgHisto2RecLeading(copy.fIJBckgHisto2RecLeading) | |
873 | ,fIJBckgHisto2Gen(copy.fIJBckgHisto2Gen) | |
874 | ,fIJBckgHisto2GenLeading(copy.fIJBckgHisto2GenLeading) | |
742ee86c | 875 | ,fIJBckgHisto3RecCuts(copy.fIJBckgHisto3RecCuts) |
876 | ,fIJBckgHisto3RecLeading(copy.fIJBckgHisto3RecLeading) | |
877 | ,fIJBckgHisto3Gen(copy.fIJBckgHisto3Gen) | |
878 | ,fIJBckgHisto3GenLeading(copy.fIJBckgHisto3GenLeading) | |
3170a3f8 | 879 | ,fIJBckgHisto4RecCuts(copy.fIJBckgHisto4RecCuts) |
880 | ,fIJBckgHisto4RecLeading(copy.fIJBckgHisto4RecLeading) | |
881 | ,fIJBckgHisto4Gen(copy.fIJBckgHisto4Gen) | |
882 | ,fIJBckgHisto4GenLeading(copy.fIJBckgHisto4GenLeading) | |
67e37e80 | 883 | ,fRandom(copy.fRandom) |
3af23c82 | 884 | ,fBckgSubMethod(copy.fBckgSubMethod) |
656dc810 | 885 | { |
886 | // copy constructor | |
67e37e80 | 887 | fBckgType[0] = copy.fBckgType[0]; |
888 | fBckgType[1] = copy.fBckgType[1]; | |
889 | fBckgType[2] = copy.fBckgType[2]; | |
742ee86c | 890 | fBckgType[3] = copy.fBckgType[3]; |
3170a3f8 | 891 | fBckgType[4] = copy.fBckgType[4]; |
656dc810 | 892 | } |
893 | ||
894 | // _________________________________________________________________________________________________________________________________ | |
895 | AliAnalysisTaskFragmentationFunction& AliAnalysisTaskFragmentationFunction::operator=(const AliAnalysisTaskFragmentationFunction& o) | |
896 | { | |
897 | // assignment | |
898 | ||
899 | if(this!=&o){ | |
900 | ||
901 | AliAnalysisTaskSE::operator=(o); | |
902 | fESD = o.fESD; | |
903 | fAOD = o.fAOD; | |
40445651 | 904 | fAODExtension = o.fAODExtension; |
905 | fNonStdFile = o.fNonStdFile; | |
656dc810 | 906 | fBranchRecJets = o.fBranchRecJets; |
3af23c82 | 907 | fBranchRecBackJets = o.fBranchRecBackJets; |
742ee86c | 908 | fBranchRecBckgClusters = o.fBranchRecBckgClusters; |
656dc810 | 909 | fBranchGenJets = o.fBranchGenJets; |
910 | fTrackTypeGen = o.fTrackTypeGen; | |
911 | fJetTypeGen = o.fJetTypeGen; | |
fe343c6b | 912 | fJetTypeRecEff = o.fJetTypeRecEff; |
656dc810 | 913 | fFilterMask = o.fFilterMask; |
ac017ff3 | 914 | fUsePhysicsSelection = o.fUsePhysicsSelection; |
3af23c82 | 915 | fEventClass = o.fEventClass; |
916 | fMaxVertexZ = o.fMaxVertexZ; | |
656dc810 | 917 | fTrackPtCut = o.fTrackPtCut; |
918 | fTrackEtaMin = o.fTrackEtaMin; | |
919 | fTrackEtaMax = o.fTrackEtaMax; | |
920 | fTrackPhiMin = o.fTrackPhiMin; | |
921 | fTrackPhiMax = o.fTrackPhiMax; | |
922 | fJetPtCut = o.fJetPtCut; | |
923 | fJetEtaMin = o.fJetEtaMin; | |
924 | fJetEtaMax = o.fJetEtaMax; | |
925 | fJetPhiMin = o.fJetPhiMin; | |
926 | fJetPhiMax = o.fJetPhiMin; | |
927 | fDiJetCut = o.fDiJetCut; | |
928 | fDiJetDeltaPhiCut = o.fDiJetDeltaPhiCut; | |
929 | fDiJetPtFractionCut = o.fDiJetPtFractionCut; | |
930 | fDiJetCDFCut = o.fDiJetCDFCut; | |
931 | fDiJetKindBins = o.fDiJetKindBins; | |
932 | fFFRadius = o.fFFRadius; | |
1da9498b | 933 | fFFBckgRadius = o.fFFBckgRadius; |
934 | fBckgMode = o.fBckgMode; | |
67e37e80 | 935 | fIJMode = o.fIJMode; |
3af23c82 | 936 | fQAMode = o.fQAMode; |
937 | fFFMode = o.fFFMode; | |
938 | fDJMode = o.fDJMode; | |
939 | fEffMode = o.fEffMode; | |
940 | fPhiCorrMode = o.fPhiCorrMode; | |
67e37e80 | 941 | fBckgType[0] = o.fBckgType[0]; |
942 | fBckgType[1] = o.fBckgType[1]; | |
943 | fBckgType[2] = o.fBckgType[2]; | |
742ee86c | 944 | fBckgType[3] = o.fBckgType[3]; |
3170a3f8 | 945 | fBckgType[4] = o.fBckgType[4]; |
cb76764e | 946 | fUseRecEffRecJetPtBins = o.fUseRecEffRecJetPtBins; |
742ee86c | 947 | fUseResponseRecJetPtBins = o.fUseResponseRecJetPtBins; |
c2658535 | 948 | fAvgTrials = o.fAvgTrials; |
656dc810 | 949 | fTracksRec = o.fTracksRec; |
950 | fTracksRecCuts = o.fTracksRecCuts; | |
951 | fTracksGen = o.fTracksGen; | |
fe343c6b | 952 | fTracksAODMCCharged = o.fTracksAODMCCharged; |
953 | fTracksRecQualityCuts = o.fTracksRecQualityCuts; | |
656dc810 | 954 | fJetsRec = o.fJetsRec; |
955 | fJetsRecCuts = o.fJetsRecCuts; | |
956 | fJetsGen = o.fJetsGen; | |
fe343c6b | 957 | fJetsRecEff = o.fJetsRecEff; |
67e37e80 | 958 | fBckgJetsRec = o.fBckgJetsRec; |
959 | fBckgJetsRecCuts = o.fBckgJetsRecCuts; | |
960 | fBckgJetsGen = o.fBckgJetsGen; | |
656dc810 | 961 | fQATrackHistosRec = o.fQATrackHistosRec; |
962 | fQATrackHistosRecCuts = o.fQATrackHistosRecCuts; | |
963 | fQATrackHistosGen = o.fQATrackHistosGen; | |
964 | fQAJetHistosRec = o.fQAJetHistosRec; | |
965 | fQAJetHistosRecCuts = o.fQAJetHistosRecCuts; | |
966 | fQAJetHistosRecCutsLeading = o.fQAJetHistosRecCutsLeading; | |
967 | fQAJetHistosGen = o.fQAJetHistosGen; | |
968 | fQAJetHistosGenLeading = o.fQAJetHistosGenLeading; | |
fe343c6b | 969 | fQAJetHistosRecEffLeading = o.fQAJetHistosRecEffLeading; |
656dc810 | 970 | fFFHistosRecCuts = o.fFFHistosRecCuts; |
971 | fFFHistosRecLeading = o.fFFHistosRecLeading; | |
972 | fFFHistosRecLeadingTrack = o.fFFHistosRecLeadingTrack; | |
973 | fFFHistosGen = o.fFFHistosGen; | |
974 | fFFHistosGenLeading = o.fFFHistosGenLeading; | |
975 | fFFHistosGenLeadingTrack = o.fFFHistosGenLeadingTrack; | |
976 | fIJHistosRecCuts = o.fIJHistosRecCuts; | |
977 | fIJHistosRecLeading = o.fIJHistosRecLeading; | |
978 | fIJHistosRecLeadingTrack = o.fIJHistosRecLeadingTrack; | |
979 | fIJHistosGen = o.fIJHistosGen; | |
980 | fIJHistosGenLeading = o.fIJHistosGenLeading; | |
981 | fIJHistosGenLeadingTrack = o.fIJHistosGenLeadingTrack; | |
982 | fFFDiJetHistosRecCuts = o.fFFDiJetHistosRecCuts; | |
983 | fFFDiJetHistosRecLeading = o.fFFDiJetHistosRecLeading; | |
984 | fFFDiJetHistosRecLeadingTrack = o.fFFDiJetHistosRecLeadingTrack; | |
985 | fFFDiJetHistosGen = o.fFFDiJetHistosGen; | |
986 | fFFDiJetHistosGenLeading = o.fFFDiJetHistosGenLeading; | |
987 | fFFDiJetHistosGenLeadingTrack = o.fFFDiJetHistosGenLeadingTrack; | |
988 | fQADiJetHistosRecCuts = o.fQADiJetHistosRecCuts; | |
989 | fQADiJetHistosGen = o.fQADiJetHistosGen; | |
3af23c82 | 990 | fPhiCorrHistosJetArea = o.fPhiCorrHistosJetArea; |
991 | fPhiCorrHistosTransverseArea = o.fPhiCorrHistosTransverseArea; | |
992 | fPhiCorrHistosAwayArea = o.fPhiCorrHistosAwayArea; | |
656dc810 | 993 | fQATrackHighPtThreshold = o.fQATrackHighPtThreshold; |
994 | fFFNBinsJetPt = o.fFFNBinsJetPt; | |
995 | fFFJetPtMin = o.fFFJetPtMin; | |
996 | fFFJetPtMax = o.fFFJetPtMax; | |
997 | fFFNBinsPt = o.fFFNBinsPt; | |
998 | fFFPtMin = o.fFFPtMin; | |
999 | fFFPtMax = o.fFFPtMax; | |
1000 | fFFNBinsXi = o.fFFNBinsXi; | |
1001 | fFFXiMin = o.fFFXiMin; | |
1002 | fFFXiMax = o.fFFXiMax; | |
1003 | fFFNBinsZ = o.fFFNBinsZ; | |
1004 | fFFZMin = o.fFFZMin; | |
1005 | fFFZMax = o.fFFZMax; | |
1006 | fQAJetNBinsPt = o.fQAJetNBinsPt; | |
1007 | fQAJetPtMin = o.fQAJetPtMin; | |
1008 | fQAJetPtMax = o.fQAJetPtMax; | |
1009 | fQAJetNBinsEta = o.fQAJetNBinsEta; | |
1010 | fQAJetEtaMin = o.fQAJetEtaMin; | |
1011 | fQAJetEtaMax = o.fQAJetEtaMax; | |
1012 | fQAJetNBinsPhi = o.fQAJetNBinsPhi; | |
1013 | fQAJetPhiMin = o.fQAJetPhiMin; | |
1014 | fQAJetPhiMax = o.fQAJetPhiMax; | |
1015 | fQATrackNBinsPt = o.fQATrackNBinsPt; | |
1016 | fQATrackPtMin = o.fQATrackPtMin; | |
1017 | fQATrackPtMax = o.fQATrackPtMax; | |
1018 | fQATrackNBinsEta = o.fQATrackNBinsEta; | |
1019 | fQATrackEtaMin = o.fQATrackEtaMin; | |
1020 | fQATrackEtaMax = o.fQATrackEtaMax; | |
1021 | fQATrackNBinsPhi = o.fQATrackNBinsPhi; | |
1022 | fQATrackPhiMin = o.fQATrackPhiMin; | |
1023 | fQATrackPhiMax = o.fQATrackPhiMax; | |
1024 | fIJNBinsJetPt = o.fIJNBinsJetPt; | |
1025 | fIJJetPtMin = o.fIJJetPtMin; | |
1026 | fIJJetPtMax = o.fIJJetPtMax; | |
1027 | fIJNBinsPt = o.fIJNBinsPt; | |
1028 | fIJPtMin = o.fIJPtMin; | |
1029 | fIJPtMax = o.fIJPtMax; | |
1030 | fIJNBinsZ = o.fIJNBinsZ; | |
1031 | fIJZMin = o.fIJZMin; | |
1032 | fIJZMax = o.fIJZMax; | |
1033 | fIJNBinsCosTheta = o.fIJNBinsCosTheta; | |
1034 | fIJCosThetaMin = o.fIJCosThetaMin; | |
1035 | fIJCosThetaMax = o.fIJCosThetaMax; | |
1036 | fIJNBinsTheta = o.fIJNBinsTheta; | |
1037 | fIJThetaMin = o.fIJThetaMin; | |
1038 | fIJThetaMax = o.fIJThetaMax; | |
1039 | fIJNBinsJt = o.fIJNBinsJt; | |
1040 | fIJJtMin = o.fIJJtMin; | |
1041 | fIJJtMax = o.fIJJtMax; | |
1042 | fDiJetNBinsJetInvMass = o.fDiJetNBinsJetInvMass; | |
1043 | fDiJetJetInvMassMin = o.fDiJetJetInvMassMin; | |
1044 | fDiJetJetInvMassMax = o.fDiJetJetInvMassMax; | |
1045 | fDiJetNBinsJetPt = o.fDiJetNBinsJetPt; | |
1046 | fDiJetJetPtMin = o.fDiJetJetPtMin; | |
1047 | fDiJetJetPtMax = o.fDiJetJetPtMax; | |
1048 | fDiJetNBinsPt = o.fDiJetNBinsPt; | |
1049 | fDiJetPtMin = o.fDiJetPtMin; | |
1050 | fDiJetPtMax = o.fDiJetPtMax; | |
1051 | fDiJetNBinsXi = o.fDiJetNBinsXi; | |
1052 | fDiJetXiMin = o.fDiJetXiMin; | |
1053 | fDiJetXiMax = o.fDiJetXiMax; | |
1054 | fDiJetNBinsZ = o.fDiJetNBinsZ; | |
1055 | fDiJetZMin = o.fDiJetZMin; | |
1056 | fDiJetZMax = o.fDiJetZMax; | |
1057 | fQADiJetNBinsInvMass = o.fQADiJetNBinsInvMass; | |
1058 | fQADiJetInvMassMin = o.fQADiJetInvMassMin; | |
1059 | fQADiJetInvMassMax = o.fQADiJetInvMassMax; | |
1060 | fQADiJetNBinsJetPt = o.fQADiJetNBinsJetPt; | |
1061 | fQADiJetJetPtMin = o.fQADiJetJetPtMin; | |
1062 | fQADiJetJetPtMax = o.fQADiJetJetPtMax; | |
1063 | fQADiJetNBinsDeltaPhi = o.fQADiJetNBinsDeltaPhi; | |
1064 | fQADiJetDeltaPhiMin = o.fQADiJetDeltaPhiMin; | |
1065 | fQADiJetDeltaPhiMax = o.fQADiJetDeltaPhiMax; | |
1066 | fQADiJetNBinsDeltaEta = o.fQADiJetNBinsDeltaEta; | |
1067 | fQADiJetDeltaEtaMin = o.fQADiJetDeltaEtaMin; | |
1068 | fQADiJetDeltaEtaMax = o.fQADiJetDeltaEtaMax; | |
1069 | fQADiJetNBinsDeltaPt = o.fQADiJetNBinsDeltaPt; | |
1070 | fQADiJetDeltaPtMin = o.fQADiJetDeltaPtMin; | |
1071 | fQADiJetDeltaPtMax = o.fQADiJetDeltaPtMax; | |
3af23c82 | 1072 | fQADiJetNBinsInBal = o.fQADiJetNBinsInBal; |
1073 | fQADiJetInBalMin = o.fQADiJetInBalMin; | |
1074 | fQADiJetInBalMax = o.fQADiJetInBalMax; | |
1075 | fPhiCorrNBinsPt = o.fPhiCorrNBinsPt; | |
1076 | fPhiCorrPtMin = o.fPhiCorrPtMin; | |
1077 | fPhiCorrPtMax = o.fPhiCorrPtMax; | |
1078 | fPhiCorrNBinsEta = o.fPhiCorrNBinsEta; | |
1079 | fPhiCorrEtaMin = o.fPhiCorrEtaMin; | |
1080 | fPhiCorrEtaMax = o.fPhiCorrEtaMax; | |
1081 | fPhiCorrNBinsPhi = o.fPhiCorrNBinsPhi; | |
1082 | fPhiCorrPhiMin = o.fPhiCorrPhiMin; | |
1083 | fPhiCorrPhiMax = o.fPhiCorrPhiMax; | |
656dc810 | 1084 | fCommonHistList = o.fCommonHistList; |
1085 | fh1EvtSelection = o.fh1EvtSelection; | |
1086 | fh1VertexNContributors = o.fh1VertexNContributors; | |
1087 | fh1VertexZ = o.fh1VertexZ; | |
1088 | fh1EvtMult = o.fh1EvtMult; | |
3af23c82 | 1089 | fh1EvtCent = o.fh1EvtCent; |
3170a3f8 | 1090 | fh2TrackPtVsDCAXY = o.fh2TrackPtVsDCAXY; |
1091 | fh2TrackPtVsDCAZ = o.fh2TrackPtVsDCAXY; | |
ac017ff3 | 1092 | fh1Xsec = o.fh1Xsec; |
1093 | fh1Trials = o.fh1Trials; | |
1094 | fh1PtHard = o.fh1PtHard; | |
1095 | fh1PtHardTrials = o.fh1PtHardTrials; | |
656dc810 | 1096 | fh1nRecJetsCuts = o.fh1nRecJetsCuts; |
1097 | fh1nGenJets = o.fh1nGenJets; | |
fe343c6b | 1098 | fh1nRecEffJets = o.fh1nRecEffJets; |
cb76764e | 1099 | fh2PtRecVsGenPrim = o.fh2PtRecVsGenPrim; |
1100 | fQATrackHistosRecEffGen = o.fQATrackHistosRecEffGen; | |
1101 | fQATrackHistosRecEffRec = o.fQATrackHistosRecEffRec; | |
1102 | fFFHistosRecEffGen = o.fFFHistosRecEffGen; | |
1103 | fFFHistosRecEffRec = o.fFFHistosRecEffRec; | |
3af23c82 | 1104 | fhnResponseSinglePt = o.fhnResponseSinglePt; |
1105 | fhnResponseJetTrackPt = o.fhnResponseJetTrackPt; | |
1106 | fhnResponseJetZ = o.fhnResponseJetZ; | |
1107 | fhnResponseJetXi = o.fhnResponseJetXi; | |
1da9498b | 1108 | // Background |
67e37e80 | 1109 | fh1OutLeadingMult = o.fh1OutLeadingMult; |
742ee86c | 1110 | fh1OutLeadingStatMult = o.fh1OutLeadingStatMult; |
67e37e80 | 1111 | fh1PerpMult = o.fh1PerpMult; |
3af23c82 | 1112 | fh1ASideMult = o.fh1ASideMult; |
1113 | fh1ASideWindowMult = o.fh1ASideWindowMult; | |
1114 | fh1PerpWindowMult = o.fh1PerpWindowMult; | |
67e37e80 | 1115 | fh1Out2JetsMult = o.fh1Out2JetsMult; |
1116 | fh1Out3JetsMult = o.fh1Out3JetsMult; | |
742ee86c | 1117 | fh1MedianClustersMult = o.fh1MedianClustersMult; |
1118 | fh1OutClustersMult = o.fh1OutClustersMult; | |
67e37e80 | 1119 | fQABckgHisto0RecCuts = o.fQABckgHisto0RecCuts; |
1120 | fQABckgHisto0Gen = o.fQABckgHisto0Gen; | |
1121 | fQABckgHisto1RecCuts = o.fQABckgHisto1RecCuts; | |
1122 | fQABckgHisto1Gen = o.fQABckgHisto1Gen; | |
1123 | fQABckgHisto2RecCuts = o.fQABckgHisto2RecCuts; | |
1124 | fQABckgHisto2Gen = o.fQABckgHisto2Gen; | |
742ee86c | 1125 | fQABckgHisto3RecCuts = o.fQABckgHisto3RecCuts; |
1126 | fQABckgHisto3Gen = o.fQABckgHisto3Gen; | |
3170a3f8 | 1127 | fQABckgHisto4RecCuts = o.fQABckgHisto4RecCuts; |
1128 | fQABckgHisto4Gen = o.fQABckgHisto4Gen; | |
67e37e80 | 1129 | fFFBckgHisto0RecCuts = o.fFFBckgHisto0RecCuts; |
1130 | fFFBckgHisto0RecLeading = o.fFFBckgHisto0RecLeading; | |
1131 | fFFBckgHisto0Gen = o.fFFBckgHisto0Gen; | |
1132 | fFFBckgHisto0GenLeading = o.fFFBckgHisto0GenLeading; | |
1133 | fFFBckgHisto1RecCuts = o.fFFBckgHisto1RecCuts; | |
1134 | fFFBckgHisto1RecLeading = o.fFFBckgHisto1RecLeading; | |
1135 | fFFBckgHisto1Gen = o.fFFBckgHisto1Gen; | |
1136 | fFFBckgHisto1GenLeading = o.fFFBckgHisto1GenLeading; | |
1137 | fFFBckgHisto2RecCuts = o.fFFBckgHisto2RecCuts; | |
1138 | fFFBckgHisto2RecLeading = o.fFFBckgHisto2RecLeading; | |
1139 | fFFBckgHisto2Gen = o.fFFBckgHisto2Gen; | |
1140 | fFFBckgHisto2GenLeading = o.fFFBckgHisto2GenLeading; | |
742ee86c | 1141 | fFFBckgHisto3RecCuts = o.fFFBckgHisto3RecCuts; |
1142 | fFFBckgHisto3RecLeading = o.fFFBckgHisto3RecLeading; | |
1143 | fFFBckgHisto3Gen = o.fFFBckgHisto3Gen; | |
1144 | fFFBckgHisto3GenLeading = o.fFFBckgHisto3GenLeading; | |
3170a3f8 | 1145 | fFFBckgHisto4RecCuts = o.fFFBckgHisto4RecCuts; |
1146 | fFFBckgHisto4RecLeading = o.fFFBckgHisto4RecLeading; | |
1147 | fFFBckgHisto4Gen = o.fFFBckgHisto4Gen; | |
1148 | fFFBckgHisto4GenLeading = o.fFFBckgHisto4GenLeading; | |
67e37e80 | 1149 | fIJBckgHisto0RecCuts = o.fIJBckgHisto0RecCuts; |
1150 | fIJBckgHisto0RecLeading = o.fIJBckgHisto0RecLeading; | |
1151 | fIJBckgHisto0Gen = o.fIJBckgHisto0Gen; | |
1152 | fIJBckgHisto0GenLeading = o.fIJBckgHisto0GenLeading; | |
1153 | fIJBckgHisto1RecCuts = o.fIJBckgHisto1RecCuts; | |
1154 | fIJBckgHisto1RecLeading = o.fIJBckgHisto1RecLeading; | |
1155 | fIJBckgHisto1Gen = o.fIJBckgHisto1Gen; | |
1156 | fIJBckgHisto1GenLeading = o.fIJBckgHisto1GenLeading; | |
1157 | fIJBckgHisto2RecCuts = o.fIJBckgHisto2RecCuts; | |
1158 | fIJBckgHisto2RecLeading = o.fIJBckgHisto2RecLeading; | |
1159 | fIJBckgHisto2Gen = o.fIJBckgHisto2Gen; | |
1160 | fIJBckgHisto2GenLeading = o.fIJBckgHisto2GenLeading; | |
742ee86c | 1161 | fIJBckgHisto3Gen = o.fIJBckgHisto3Gen; |
1162 | fIJBckgHisto3GenLeading = o.fIJBckgHisto3GenLeading; | |
3170a3f8 | 1163 | fIJBckgHisto4Gen = o.fIJBckgHisto4Gen; |
1164 | fIJBckgHisto4GenLeading = o.fIJBckgHisto4GenLeading; | |
67e37e80 | 1165 | fRandom = o.fRandom; |
3af23c82 | 1166 | fBckgSubMethod = o.fBckgSubMethod; |
656dc810 | 1167 | } |
1168 | ||
1169 | return *this; | |
1170 | } | |
1171 | ||
1172 | //___________________________________________________________________________ | |
1173 | AliAnalysisTaskFragmentationFunction::~AliAnalysisTaskFragmentationFunction() | |
1174 | { | |
1175 | // destructor | |
1176 | ||
fe343c6b | 1177 | if(fTracksRec) delete fTracksRec; |
1178 | if(fTracksRecCuts) delete fTracksRecCuts; | |
1179 | if(fTracksGen) delete fTracksGen; | |
1180 | if(fTracksAODMCCharged) delete fTracksAODMCCharged; | |
1181 | if(fTracksRecQualityCuts) delete fTracksRecQualityCuts; | |
1182 | if(fJetsRec) delete fJetsRec; | |
1183 | if(fJetsRecCuts) delete fJetsRecCuts; | |
1184 | if(fJetsGen) delete fJetsGen; | |
1185 | if(fJetsRecEff) delete fJetsRecEff; | |
742ee86c | 1186 | if(fBckgMode && |
3170a3f8 | 1187 | (fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters || |
1188 | fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || | |
1189 | fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading)){ | |
742ee86c | 1190 | |
67e37e80 | 1191 | if(fBckgJetsRec) delete fBckgJetsRec; |
1192 | if(fBckgJetsRecCuts) delete fBckgJetsRecCuts; | |
1193 | if(fBckgJetsGen) delete fBckgJetsGen; | |
1194 | } | |
1195 | if(fRandom) delete fRandom; | |
656dc810 | 1196 | } |
1197 | ||
1198 | //______________________________________________________________________________________________________ | |
1199 | AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::AliFragFuncHistos(const char* name, | |
1200 | Int_t nJetPt, Float_t jetPtMin, Float_t jetPtMax, | |
1201 | Int_t nPt, Float_t ptMin, Float_t ptMax, | |
1202 | Int_t nXi, Float_t xiMin, Float_t xiMax, | |
1203 | Int_t nZ , Float_t zMin , Float_t zMax ) | |
1204 | : TObject() | |
1205 | ,fNBinsJetPt(nJetPt) | |
1206 | ,fJetPtMin(jetPtMin) | |
1207 | ,fJetPtMax(jetPtMax) | |
1208 | ,fNBinsPt(nPt) | |
1209 | ,fPtMin(ptMin) | |
1210 | ,fPtMax(ptMax) | |
1211 | ,fNBinsXi(nXi) | |
1212 | ,fXiMin(xiMin) | |
1213 | ,fXiMax(xiMax) | |
1214 | ,fNBinsZ(nZ) | |
1215 | ,fZMin(zMin) | |
1216 | ,fZMax(zMax) | |
1217 | ,fh2TrackPt(0) | |
1218 | ,fh2Xi(0) | |
1219 | ,fh2Z(0) | |
1220 | ,fh1JetPt(0) | |
fceb275f | 1221 | ,fNameFF(name) |
656dc810 | 1222 | { |
1223 | // default constructor | |
1224 | ||
1225 | } | |
1226 | ||
1227 | //___________________________________________________________________________ | |
1228 | AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::AliFragFuncHistos(const AliFragFuncHistos& copy) | |
1229 | : TObject() | |
1230 | ,fNBinsJetPt(copy.fNBinsJetPt) | |
1231 | ,fJetPtMin(copy.fJetPtMin) | |
1232 | ,fJetPtMax(copy.fJetPtMax) | |
1233 | ,fNBinsPt(copy.fNBinsPt) | |
1234 | ,fPtMin(copy.fPtMin) | |
1235 | ,fPtMax(copy.fPtMax) | |
1236 | ,fNBinsXi(copy.fNBinsXi) | |
1237 | ,fXiMin(copy.fXiMin) | |
1238 | ,fXiMax(copy.fXiMax) | |
1239 | ,fNBinsZ(copy.fNBinsZ) | |
1240 | ,fZMin(copy.fZMin) | |
1241 | ,fZMax(copy.fZMax) | |
1242 | ,fh2TrackPt(copy.fh2TrackPt) | |
1243 | ,fh2Xi(copy.fh2Xi) | |
1244 | ,fh2Z(copy.fh2Z) | |
1245 | ,fh1JetPt(copy.fh1JetPt) | |
fceb275f | 1246 | ,fNameFF(copy.fNameFF) |
656dc810 | 1247 | { |
1248 | // copy constructor | |
1249 | } | |
1250 | ||
1251 | //_______________________________________________________________________________________________________________________________________________________________ | |
1252 | AliAnalysisTaskFragmentationFunction::AliFragFuncHistos& AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::operator=(const AliAnalysisTaskFragmentationFunction::AliFragFuncHistos& o) | |
1253 | { | |
1254 | // assignment | |
1255 | ||
1256 | if(this!=&o){ | |
1257 | TObject::operator=(o); | |
1258 | fNBinsJetPt = o.fNBinsJetPt; | |
1259 | fJetPtMin = o.fJetPtMin; | |
1260 | fJetPtMax = o.fJetPtMax; | |
1261 | fNBinsPt = o.fNBinsPt; | |
1262 | fPtMin = o.fPtMin; | |
1263 | fPtMax = o.fPtMax; | |
1264 | fNBinsXi = o.fNBinsXi; | |
1265 | fXiMin = o.fXiMin; | |
1266 | fXiMax = o.fXiMax; | |
1267 | fNBinsZ = o.fNBinsZ; | |
1268 | fZMin = o.fZMin; | |
1269 | fZMax = o.fZMax; | |
1270 | fh2TrackPt = o.fh2TrackPt; | |
1271 | fh2Xi = o.fh2Xi; | |
1272 | fh2Z = o.fh2Z; | |
1273 | fh1JetPt = o.fh1JetPt; | |
fceb275f | 1274 | fNameFF = o.fNameFF; |
656dc810 | 1275 | } |
1276 | ||
1277 | return *this; | |
1278 | } | |
1279 | ||
1280 | //_________________________________________________________ | |
1281 | AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::~AliFragFuncHistos() | |
1282 | { | |
1283 | // destructor | |
1284 | ||
1285 | if(fh1JetPt) delete fh1JetPt; | |
1286 | if(fh2TrackPt) delete fh2TrackPt; | |
1287 | if(fh2Xi) delete fh2Xi; | |
1288 | if(fh2Z) delete fh2Z; | |
1289 | } | |
1290 | ||
1291 | //_________________________________________________________________ | |
1292 | void AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::DefineHistos() | |
1293 | { | |
1294 | // book FF histos | |
1295 | ||
fceb275f | 1296 | fh1JetPt = new TH1F(Form("fh1FFJetPt%s", fNameFF.Data()),"",fNBinsJetPt,fJetPtMin,fJetPtMax); |
1297 | fh2TrackPt = new TH2F(Form("fh2FFTrackPt%s",fNameFF.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax,fNBinsPt, fPtMin, fPtMax); | |
1298 | fh2Xi = new TH2F(Form("fh2FFXi%s",fNameFF.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax, fNBinsXi, fXiMin, fXiMax); | |
1299 | fh2Z = new TH2F(Form("fh2FFZ%s",fNameFF.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax, fNBinsZ, fZMin, fZMax); | |
656dc810 | 1300 | |
1301 | AliAnalysisTaskFragmentationFunction::SetProperties(fh1JetPt, "p_{T} [GeV/c]", "entries"); | |
1302 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2TrackPt,"jet p_{T} [GeV/c]","p_{T} [GeV/c]","entries"); | |
1303 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Xi,"jet p_{T} [GeV/c]","#xi", "entries"); | |
1304 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Z,"jet p_{T} [GeV/c]","z","entries"); | |
1305 | } | |
1306 | ||
1307 | //_______________________________________________________________________________________________________________ | |
1da9498b | 1308 | void AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::FillFF(Float_t trackPt, Float_t jetPt, Bool_t incrementJetPt, Float_t norm) |
656dc810 | 1309 | { |
1310 | // fill FF | |
1311 | ||
1da9498b | 1312 | if(incrementJetPt && norm) fh1JetPt->Fill(jetPt,1/norm); |
942bf1b4 | 1313 | else if(incrementJetPt) fh1JetPt->Fill(jetPt); |
1314 | ||
1315 | // Added for proper normalization of FF background estimation | |
1316 | // when zero track are found in the background region | |
3170a3f8 | 1317 | if((int)trackPt==-1) return; |
942bf1b4 | 1318 | |
1da9498b | 1319 | if(norm)fh2TrackPt->Fill(jetPt,trackPt,1/norm); |
1320 | else fh2TrackPt->Fill(jetPt,trackPt); | |
656dc810 | 1321 | |
656dc810 | 1322 | Double_t z = 0.; |
1323 | if(jetPt>0) z = trackPt / jetPt; | |
1324 | Double_t xi = 0; | |
1325 | if(z>0) xi = TMath::Log(1/z); | |
1326 | ||
1da9498b | 1327 | if(norm){ |
1328 | fh2Xi->Fill(jetPt,xi,1/norm); | |
1329 | fh2Z->Fill(jetPt,z,1/norm); | |
1330 | } | |
1331 | else { | |
1332 | fh2Xi->Fill(jetPt,xi); | |
1333 | fh2Z->Fill(jetPt,z); | |
1334 | } | |
656dc810 | 1335 | } |
1336 | ||
1337 | //_________________________________________________________________________________ | |
1338 | void AliAnalysisTaskFragmentationFunction::AliFragFuncHistos::AddToOutput(TList* list) const | |
1339 | { | |
1340 | // add histos to list | |
1341 | ||
1342 | list->Add(fh1JetPt); | |
1343 | ||
1344 | list->Add(fh2TrackPt); | |
1345 | list->Add(fh2Xi); | |
1346 | list->Add(fh2Z); | |
1347 | } | |
1348 | ||
1349 | //_________________________________________________________________________________________________________ | |
1350 | AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::AliFragFuncQAJetHistos(const char* name, | |
1351 | Int_t nPt, Float_t ptMin, Float_t ptMax, | |
1352 | Int_t nEta, Float_t etaMin, Float_t etaMax, | |
1353 | Int_t nPhi, Float_t phiMin, Float_t phiMax) | |
1354 | : TObject() | |
1355 | ,fNBinsPt(nPt) | |
1356 | ,fPtMin(ptMin) | |
1357 | ,fPtMax(ptMax) | |
1358 | ,fNBinsEta(nEta) | |
1359 | ,fEtaMin(etaMin) | |
1360 | ,fEtaMax(etaMax) | |
1361 | ,fNBinsPhi(nPhi) | |
1362 | ,fPhiMin(phiMin) | |
1363 | ,fPhiMax(phiMax) | |
1364 | ,fh2EtaPhi(0) | |
1365 | ,fh1Pt(0) | |
fceb275f | 1366 | ,fNameQAJ(name) |
656dc810 | 1367 | { |
1368 | // default constructor | |
1369 | } | |
1370 | ||
1371 | //____________________________________________________________________________________ | |
1372 | AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::AliFragFuncQAJetHistos(const AliFragFuncQAJetHistos& copy) | |
1373 | : TObject() | |
1374 | ,fNBinsPt(copy.fNBinsPt) | |
1375 | ,fPtMin(copy.fPtMin) | |
1376 | ,fPtMax(copy.fPtMax) | |
1377 | ,fNBinsEta(copy.fNBinsEta) | |
1378 | ,fEtaMin(copy.fEtaMin) | |
1379 | ,fEtaMax(copy.fEtaMax) | |
1380 | ,fNBinsPhi(copy.fNBinsPhi) | |
1381 | ,fPhiMin(copy.fPhiMin) | |
1382 | ,fPhiMax(copy.fPhiMax) | |
1383 | ,fh2EtaPhi(copy.fh2EtaPhi) | |
1384 | ,fh1Pt(copy.fh1Pt) | |
fceb275f | 1385 | ,fNameQAJ(copy.fNameQAJ) |
656dc810 | 1386 | { |
1387 | // copy constructor | |
1388 | } | |
1389 | ||
1390 | //________________________________________________________________________________________________________________________________________________________________________ | |
1391 | AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos& AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::operator=(const AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos& o) | |
1392 | { | |
1393 | // assignment | |
1394 | ||
1395 | if(this!=&o){ | |
1396 | TObject::operator=(o); | |
1397 | fNBinsPt = o.fNBinsPt; | |
1398 | fPtMin = o.fPtMin; | |
1399 | fPtMax = o.fPtMax; | |
1400 | fNBinsEta = o.fNBinsEta; | |
1401 | fEtaMin = o.fEtaMin; | |
1402 | fEtaMax = o.fEtaMax; | |
1403 | fNBinsPhi = o.fNBinsPhi; | |
1404 | fPhiMin = o.fPhiMin; | |
1405 | fPhiMax = o.fPhiMax; | |
1406 | fh2EtaPhi = o.fh2EtaPhi; | |
1407 | fh1Pt = o.fh1Pt; | |
fceb275f | 1408 | fNameQAJ = o.fNameQAJ; |
656dc810 | 1409 | } |
1410 | ||
1411 | return *this; | |
1412 | } | |
1413 | ||
1414 | //______________________________________________________________ | |
1415 | AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::~AliFragFuncQAJetHistos() | |
1416 | { | |
1417 | // destructor | |
1418 | ||
1419 | if(fh2EtaPhi) delete fh2EtaPhi; | |
1420 | if(fh1Pt) delete fh1Pt; | |
1421 | } | |
1422 | ||
1423 | //____________________________________________________________________ | |
1424 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::DefineHistos() | |
1425 | { | |
1426 | // book jet QA histos | |
1427 | ||
fceb275f | 1428 | fh2EtaPhi = new TH2F(Form("fh2JetQAEtaPhi%s", fNameQAJ.Data()), Form("%s: #eta - #phi distribution", fNameQAJ.Data()), fNBinsEta, fEtaMin, fEtaMax, fNBinsPhi, fPhiMin, fPhiMax); |
1429 | fh1Pt = new TH1F(Form("fh1JetQAPt%s", fNameQAJ.Data()), Form("%s: p_{T} distribution", fNameQAJ.Data()), fNBinsPt, fPtMin, fPtMax); | |
656dc810 | 1430 | |
1431 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2EtaPhi, "#eta", "#phi"); | |
1432 | AliAnalysisTaskFragmentationFunction::SetProperties(fh1Pt, "p_{T} [GeV/c]", "entries"); | |
1433 | } | |
1434 | ||
1435 | //____________________________________________________________________________________________________ | |
1436 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::FillJetQA(Float_t eta, Float_t phi, Float_t pt) | |
1437 | { | |
1438 | // fill jet QA histos | |
1439 | ||
1440 | fh2EtaPhi->Fill( eta, phi); | |
1441 | fh1Pt->Fill( pt ); | |
1442 | } | |
1443 | ||
1444 | //____________________________________________________________________________________ | |
1445 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQAJetHistos::AddToOutput(TList* list) const | |
1446 | { | |
1447 | // add histos to list | |
1448 | ||
1449 | list->Add(fh2EtaPhi); | |
1450 | list->Add(fh1Pt); | |
1451 | } | |
1452 | ||
1453 | //___________________________________________________________________________________________________________ | |
1454 | AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::AliFragFuncQATrackHistos(const char* name, | |
1455 | Int_t nPt, Float_t ptMin, Float_t ptMax, | |
1456 | Int_t nEta, Float_t etaMin, Float_t etaMax, | |
1457 | Int_t nPhi, Float_t phiMin, Float_t phiMax, | |
1458 | Float_t ptThresh) | |
1459 | : TObject() | |
1460 | ,fNBinsPt(nPt) | |
1461 | ,fPtMin(ptMin) | |
1462 | ,fPtMax(ptMax) | |
1463 | ,fNBinsEta(nEta) | |
1464 | ,fEtaMin(etaMin) | |
1465 | ,fEtaMax(etaMax) | |
1466 | ,fNBinsPhi(nPhi) | |
1467 | ,fPhiMin(phiMin) | |
1468 | ,fPhiMax(phiMax) | |
1469 | ,fHighPtThreshold(ptThresh) | |
1470 | ,fh2EtaPhi(0) | |
1471 | ,fh1Pt(0) | |
1472 | ,fh2HighPtEtaPhi(0) | |
3af23c82 | 1473 | ,fh2PhiPt(0) |
fceb275f | 1474 | ,fNameQAT(name) |
656dc810 | 1475 | { |
1476 | // default constructor | |
1477 | } | |
1478 | ||
1479 | //__________________________________________________________________________________________ | |
1480 | AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::AliFragFuncQATrackHistos(const AliFragFuncQATrackHistos& copy) | |
1481 | : TObject() | |
1482 | ,fNBinsPt(copy.fNBinsPt) | |
1483 | ,fPtMin(copy.fPtMin) | |
1484 | ,fPtMax(copy.fPtMax) | |
1485 | ,fNBinsEta(copy.fNBinsEta) | |
1486 | ,fEtaMin(copy.fEtaMin) | |
1487 | ,fEtaMax(copy.fEtaMax) | |
1488 | ,fNBinsPhi(copy.fNBinsPhi) | |
1489 | ,fPhiMin(copy.fPhiMin) | |
1490 | ,fPhiMax(copy.fPhiMax) | |
1491 | ,fHighPtThreshold(copy.fHighPtThreshold) | |
1492 | ,fh2EtaPhi(copy.fh2EtaPhi) | |
1493 | ,fh1Pt(copy.fh1Pt) | |
1494 | ,fh2HighPtEtaPhi(copy.fh2HighPtEtaPhi) | |
3af23c82 | 1495 | ,fh2PhiPt(copy.fh2PhiPt) |
fceb275f | 1496 | ,fNameQAT(copy.fNameQAT) |
656dc810 | 1497 | { |
1498 | // copy constructor | |
1499 | } | |
1500 | ||
1501 | // _____________________________________________________________________________________________________________________________________________________________________________ | |
1502 | AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos& AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::operator=(const AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos& o) | |
1503 | { | |
1504 | // assignment | |
1505 | ||
1506 | if(this!=&o){ | |
1507 | TObject::operator=(o); | |
1508 | fNBinsPt = o.fNBinsPt; | |
1509 | fPtMin = o.fPtMin; | |
1510 | fPtMax = o.fPtMax; | |
1511 | fNBinsEta = o.fNBinsEta; | |
1512 | fEtaMin = o.fEtaMin; | |
1513 | fEtaMax = o.fEtaMax; | |
1514 | fNBinsPhi = o.fNBinsPhi; | |
1515 | fPhiMin = o.fPhiMin; | |
1516 | fPhiMax = o.fPhiMax; | |
1517 | fHighPtThreshold = o.fHighPtThreshold; | |
1518 | fh2EtaPhi = o.fh2EtaPhi; | |
1519 | fh1Pt = o.fh1Pt; | |
1520 | fh2HighPtEtaPhi = o.fh2HighPtEtaPhi; | |
3af23c82 | 1521 | fh2PhiPt = o.fh2PhiPt; |
fceb275f | 1522 | fNameQAT = o.fNameQAT; |
656dc810 | 1523 | } |
1524 | ||
1525 | return *this; | |
1526 | } | |
1527 | ||
1528 | //___________________________________________________________________ | |
1529 | AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::~AliFragFuncQATrackHistos() | |
1530 | { | |
1531 | // destructor | |
1532 | ||
1533 | if(fh2EtaPhi) delete fh2EtaPhi; | |
1534 | if(fh2HighPtEtaPhi) delete fh2HighPtEtaPhi; | |
1535 | if(fh1Pt) delete fh1Pt; | |
3af23c82 | 1536 | if(fh2PhiPt) delete fh2PhiPt; |
656dc810 | 1537 | } |
1538 | ||
1539 | //______________________________________________________________________ | |
1540 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::DefineHistos() | |
1541 | { | |
1542 | // book track QA histos | |
1543 | ||
fceb275f | 1544 | fh2EtaPhi = new TH2F(Form("fh2TrackQAEtaPhi%s", fNameQAT.Data()), Form("%s: #eta - #phi distribution", fNameQAT.Data()), fNBinsEta, fEtaMin, fEtaMax, fNBinsPhi, fPhiMin, fPhiMax); |
1545 | fh2HighPtEtaPhi = new TH2F(Form("fh2TrackQAHighPtEtaPhi%s", fNameQAT.Data()), Form("%s: #eta - #phi distribution for high-p_{T}", fNameQAT.Data()), fNBinsEta, fEtaMin, fEtaMax, fNBinsPhi, fPhiMin, fPhiMax); | |
1546 | fh1Pt = new TH1F(Form("fh1TrackQAPt%s", fNameQAT.Data()), Form("%s: p_{T} distribution", fNameQAT.Data()), fNBinsPt, fPtMin, fPtMax); | |
3170a3f8 | 1547 | fh2PhiPt = new TH2F(Form("fh2TrackQAPhiPt%s", fNameQAT.Data()), Form("%s: #phi - p_{T} distribution", fNameQAT.Data()), fNBinsPhi, fPhiMin, fPhiMax, fNBinsPt, fPtMin, fPtMax); |
3af23c82 | 1548 | |
656dc810 | 1549 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2EtaPhi, "#eta", "#phi"); |
1550 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2HighPtEtaPhi, "#eta", "#phi"); | |
1551 | AliAnalysisTaskFragmentationFunction::SetProperties(fh1Pt, "p_{T} [GeV/c]", "entries"); | |
3af23c82 | 1552 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2PhiPt, "#phi", "p_{T} [GeV/c]"); |
656dc810 | 1553 | } |
1554 | ||
1555 | //________________________________________________________________________________________________________ | |
3af23c82 | 1556 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::FillTrackQA(Float_t eta, Float_t phi, Float_t pt, Bool_t weightPt, Float_t norm) |
656dc810 | 1557 | { |
1558 | // fill track QA histos | |
3af23c82 | 1559 | Float_t weight = 1.; |
1560 | if(weightPt) weight = pt; | |
1561 | fh2EtaPhi->Fill( eta, phi, weight); | |
1562 | if(pt > fHighPtThreshold) fh2HighPtEtaPhi->Fill( eta, phi, weight); | |
1563 | if(norm) fh1Pt->Fill( pt, 1/norm ); | |
1564 | else fh1Pt->Fill( pt ); | |
1565 | fh2PhiPt->Fill(phi, pt); | |
656dc810 | 1566 | } |
1567 | ||
1568 | //______________________________________________________________________________________ | |
1569 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQATrackHistos::AddToOutput(TList* list) const | |
1570 | { | |
1571 | // add histos to list | |
1572 | ||
1573 | list->Add(fh2EtaPhi); | |
1574 | list->Add(fh2HighPtEtaPhi); | |
1575 | list->Add(fh1Pt); | |
3af23c82 | 1576 | list->Add(fh2PhiPt); |
656dc810 | 1577 | } |
1578 | ||
1579 | //______________________________________________________________________________________________________ | |
1580 | AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::AliFragFuncIntraJetHistos(const char* name, | |
1581 | Int_t nJetPt, Float_t jetPtMin, Float_t jetPtMax, | |
1582 | Int_t nPt, Float_t ptMin, Float_t ptMax, | |
1583 | Int_t nZ , Float_t zMin , Float_t zMax, | |
1584 | Int_t nCosTheta , Float_t costhetaMin , Float_t costhetaMax, | |
1585 | Int_t nTheta , Float_t thetaMin , Float_t thetaMax, | |
1586 | Int_t nJt , Float_t jtMin , Float_t jtMax) | |
1587 | : TObject() | |
1588 | ,fNBinsJetPt(nJetPt) | |
1589 | ,fJetPtMin(jetPtMin) | |
1590 | ,fJetPtMax(jetPtMax) | |
1591 | ,fNBinsPt(nPt) | |
1592 | ,fPtMin(ptMin) | |
1593 | ,fPtMax(ptMax) | |
1594 | ,fNBinsZ(nZ) | |
1595 | ,fZMin(zMin) | |
1596 | ,fZMax(zMax) | |
1597 | ,fNBinsJt(nJt) | |
1598 | ,fJtMin(jtMin) | |
1599 | ,fJtMax(jtMax) | |
1600 | ,fNBinsTheta(nTheta) | |
1601 | ,fThetaMin(thetaMin) | |
1602 | ,fThetaMax(thetaMax) | |
1603 | ,fNBinsCosTheta(nCosTheta) | |
1604 | ,fCosThetaMin(costhetaMin) | |
1605 | ,fCosThetaMax(costhetaMax) | |
656dc810 | 1606 | ,fh2CosTheta(0) |
67e37e80 | 1607 | ,fh2PtZ(0) |
1608 | ,fh3ThetaZ(0) | |
1609 | ,fh3JtTheta(0) | |
1610 | ,fh3JtZ(0) | |
fceb275f | 1611 | ,fNameIJ(name) |
656dc810 | 1612 | { |
1613 | // default constructor | |
1614 | ||
1615 | } | |
1616 | ||
1617 | //___________________________________________________________________________ | |
1618 | AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::AliFragFuncIntraJetHistos(const AliFragFuncIntraJetHistos& copy) | |
1619 | : TObject() | |
1620 | ,fNBinsJetPt(copy.fNBinsJetPt) | |
1621 | ,fJetPtMin(copy.fJetPtMin) | |
1622 | ,fJetPtMax(copy.fJetPtMax) | |
1623 | ,fNBinsPt(copy.fNBinsPt) | |
1624 | ,fPtMin(copy.fPtMin) | |
1625 | ,fPtMax(copy.fPtMax) | |
1626 | ,fNBinsZ(copy.fNBinsZ) | |
1627 | ,fZMin(copy.fZMin) | |
1628 | ,fZMax(copy.fZMax) | |
1629 | ,fNBinsJt(copy.fNBinsJt) | |
1630 | ,fJtMin(copy.fJtMin) | |
1631 | ,fJtMax(copy.fJtMax) | |
1632 | ,fNBinsTheta(copy.fNBinsTheta) | |
1633 | ,fThetaMin(copy.fThetaMin) | |
1634 | ,fThetaMax(copy.fThetaMax) | |
1635 | ,fNBinsCosTheta(copy.fNBinsCosTheta) | |
1636 | ,fCosThetaMin(copy.fCosThetaMin) | |
1637 | ,fCosThetaMax(copy.fCosThetaMax) | |
656dc810 | 1638 | ,fh2CosTheta(copy.fh2CosTheta) |
67e37e80 | 1639 | ,fh2PtZ(copy.fh2PtZ) |
1640 | ,fh3ThetaZ(copy.fh3ThetaZ) | |
1641 | ,fh3JtTheta(copy.fh3JtTheta) | |
1642 | ,fh3JtZ(copy.fh3JtZ) | |
fceb275f | 1643 | ,fNameIJ(copy.fNameIJ) |
656dc810 | 1644 | { |
1645 | // copy constructor | |
1646 | } | |
1647 | ||
1648 | //_______________________________________________________________________________________________________________________________________________________________ | |
1649 | AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos& AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::operator=(const AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos& o) | |
1650 | { | |
1651 | // assignment | |
1652 | ||
1653 | if(this!=&o){ | |
1654 | TObject::operator=(o); | |
1655 | fNBinsJetPt = o.fNBinsJetPt; | |
1656 | fJetPtMin = o.fJetPtMin; | |
1657 | fJetPtMax = o.fJetPtMax; | |
1658 | fNBinsPt = o.fNBinsPt; | |
1659 | fPtMin = o.fPtMin; | |
1660 | fPtMax = o.fPtMax; | |
1661 | fNBinsZ = o.fNBinsZ; | |
1662 | fZMin = o.fZMin; | |
1663 | fZMax = o.fZMax; | |
1664 | fNBinsJt = o.fNBinsJt; | |
1665 | fJtMin = o.fJtMin; | |
1666 | fJtMax = o.fJtMax; | |
1667 | fNBinsTheta = o.fNBinsTheta; | |
1668 | fThetaMin = o.fThetaMin; | |
1669 | fThetaMax = o.fThetaMax; | |
1670 | fNBinsCosTheta = o.fNBinsCosTheta; | |
1671 | fCosThetaMin = o.fCosThetaMin; | |
1672 | fCosThetaMax = o.fCosThetaMax; | |
656dc810 | 1673 | fh2CosTheta = o.fh2CosTheta; |
67e37e80 | 1674 | fh2PtZ = o.fh2PtZ; |
1675 | fh3ThetaZ = o.fh3ThetaZ; | |
1676 | fh3JtTheta = o.fh3JtTheta; | |
1677 | fh3JtZ = o.fh3JtZ; | |
fceb275f | 1678 | fNameIJ = o.fNameIJ; |
656dc810 | 1679 | } |
1680 | ||
1681 | return *this; | |
1682 | } | |
1683 | ||
1684 | //_________________________________________________________ | |
1685 | AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::~AliFragFuncIntraJetHistos() | |
1686 | { | |
1687 | // destructor | |
1688 | ||
1689 | ||
656dc810 | 1690 | if(fh2CosTheta) delete fh2CosTheta; |
67e37e80 | 1691 | if(fh2PtZ) delete fh2PtZ; |
1692 | if(fh3ThetaZ) delete fh3ThetaZ; | |
1693 | if(fh3JtTheta) delete fh3JtTheta; | |
1694 | if(fh3JtZ) delete fh3JtZ; | |
656dc810 | 1695 | |
1696 | } | |
1697 | ||
1698 | //_________________________________________________________________ | |
1699 | void AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::DefineHistos() | |
1700 | { | |
1701 | // book FF histos | |
1702 | ||
fceb275f | 1703 | fh2CosTheta = new TH2F(Form("fh2IJcosTheta%s",fNameIJ.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax,fNBinsCosTheta, fCosThetaMin, fCosThetaMax); |
67e37e80 | 1704 | fh2PtZ = new TH2F(Form("fh2IJPtZ%s",fNameIJ.Data()),"",fNBinsPt, fPtMin, fPtMax, fNBinsZ, fZMin, fZMax); |
1705 | fh3ThetaZ = new TH3F(Form("fh3IJThetaZ%s",fNameIJ.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax, fNBinsTheta, fThetaMin, fThetaMax, fNBinsZ, fZMin, fZMax); | |
1706 | fh3JtTheta = new TH3F(Form("fh3IJJtTheta%s",fNameIJ.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax, fNBinsJt, fJtMin, fJtMax, fNBinsTheta, fThetaMin, fThetaMax); | |
1707 | fh3JtZ = new TH3F(Form("fh3IJJtZ%s",fNameIJ.Data()),"",fNBinsJetPt, fJetPtMin, fJetPtMax, fNBinsJt, fJtMin, fJtMax, fNBinsZ, fZMin, fZMax); | |
656dc810 | 1708 | |
656dc810 | 1709 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2CosTheta,"jet p_{T} [GeV/c]","cos(#Theta)", "entries"); |
67e37e80 | 1710 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2PtZ,"had p_{T} [GeV/c]","z=p_{T}^{had}/p_{T}^{jet}","entries"); |
1711 | AliAnalysisTaskFragmentationFunction::SetProperties(fh3ThetaZ,"jet p_{T} [GeV/c]","#Theta [rad]","z=p_{T}^{had}/p_{T}^{jet}"); | |
1712 | AliAnalysisTaskFragmentationFunction::SetProperties(fh3JtTheta,"jet p_{T} [GeV/c]","j_{T} [GeV/c]","#Theta [rad]"); | |
1713 | AliAnalysisTaskFragmentationFunction::SetProperties(fh3JtZ,"jet p_{T} [GeV/c]","j_{T} [GeV/c]","z=p_{T}^{had}/p_{T}^{jet}"); | |
1714 | ||
656dc810 | 1715 | } |
1716 | ||
1717 | //_______________________________________________________________________________________________________________ | |
1da9498b | 1718 | void AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::FillIntraJet(const TLorentzVector* trackV, const TLorentzVector* jetV, Float_t norm) |
656dc810 | 1719 | { |
1720 | // fill IntraJet histos | |
1721 | ||
1722 | Float_t cosTheta = 0.; Float_t theta = 0.; | |
1723 | Float_t jt = 0.; Float_t z = 0.; | |
1724 | // For Theta distribution | |
1725 | Float_t pxT = trackV->Px(); | |
1726 | Float_t pyT = trackV->Py(); | |
1727 | Float_t pzT = trackV->Pz(); | |
1728 | Float_t ptT = trackV->Pt(); | |
1729 | Float_t pT = trackV->P(); | |
1730 | Float_t etaT = trackV->Eta(); | |
1731 | Float_t phiT = trackV->Phi(); // Check the value returned | |
1732 | Float_t pxJ = jetV->Px(); | |
1733 | Float_t pyJ = jetV->Py(); | |
1734 | Float_t pzJ = jetV->Pz(); | |
1735 | Float_t ptJ = jetV->Pt(); | |
1736 | Float_t pJ = jetV->P(); | |
1737 | ||
1738 | // Compute z | |
1da9498b | 1739 | if(ptJ>0) z = (Float_t)(ptT/ptJ); |
656dc810 | 1740 | |
1741 | // Compute theta | |
1742 | cosTheta = (pxT*pxJ+pyT*pyJ+pzT*pzJ)/(pT*pJ); | |
1743 | theta = TMath::ACos(cosTheta); | |
1744 | ||
1745 | // Compute jt | |
1746 | TVector3 trackP; TVector3 jetP; | |
1747 | jetP[0] = pxJ; | |
1748 | jetP[1] = pyJ; | |
1749 | jetP[2] = pzJ; | |
1750 | trackP.SetPtEtaPhi(ptT,etaT,phiT); | |
1751 | jt = TMath::Sin(trackP.Angle(jetP))*trackP.Mag(); | |
1752 | ||
67e37e80 | 1753 | // Fill histos |
1da9498b | 1754 | if(norm){ |
1755 | fh2CosTheta->Fill(ptJ,cosTheta,1/norm); | |
67e37e80 | 1756 | fh2PtZ->Fill(ptT,z,1/norm); |
1757 | fh3ThetaZ->Fill(ptJ,theta,z,1/norm); | |
1758 | fh3JtTheta->Fill(ptJ,jt,theta,1/norm); | |
1759 | fh3JtZ->Fill(ptJ,jt,z,1/norm); | |
1da9498b | 1760 | } |
1761 | else { | |
1762 | fh2CosTheta->Fill(ptJ,cosTheta); | |
67e37e80 | 1763 | fh2PtZ->Fill(ptT,z); |
1764 | fh3ThetaZ->Fill(ptJ,theta,z); | |
1765 | fh3JtTheta->Fill(ptJ,jt,theta); | |
1766 | fh3JtZ->Fill(ptJ,jt,z); | |
1da9498b | 1767 | } |
656dc810 | 1768 | |
656dc810 | 1769 | } |
1770 | ||
1771 | //______________________________________________________________________________________________________ | |
1772 | AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::AliFragFuncDiJetHistos(const char* name, Int_t kindSlices, | |
1773 | Int_t nJetInvMass, Float_t jetInvMassMin, Float_t jetInvMassMax, | |
1774 | Int_t nJetPt, Float_t jetPtMin, Float_t jetPtMax, | |
1775 | Int_t nPt, Float_t ptMin, Float_t ptMax, | |
1776 | Int_t nXi, Float_t xiMin, Float_t xiMax, | |
1777 | Int_t nZ , Float_t zMin , Float_t zMax) | |
1778 | : TObject() | |
1779 | ,fKindSlices(kindSlices) | |
1780 | ,fNBinsJetInvMass(nJetInvMass) | |
1781 | ,fJetInvMassMin(jetInvMassMin) | |
1782 | ,fJetInvMassMax(jetInvMassMax) | |
1783 | ,fNBinsJetPt(nJetPt) | |
1784 | ,fJetPtMin(jetPtMin) | |
1785 | ,fJetPtMax(jetPtMax) | |
1786 | ,fNBinsPt(nPt) | |
1787 | ,fPtMin(ptMin) | |
1788 | ,fPtMax(ptMax) | |
1789 | ,fNBinsXi(nXi) | |
1790 | ,fXiMin(xiMin) | |
1791 | ,fXiMax(xiMax) | |
1792 | ,fNBinsZ(nZ) | |
1793 | ,fZMin(zMin) | |
1794 | ,fZMax(zMax) | |
1795 | ,fh2TrackPtJet1(0) | |
1796 | ,fh2TrackPtJet2(0) | |
1797 | ,fh2TrackPtJet(0) | |
1798 | ,fh1Jet1Pt(0) | |
1799 | ,fh1Jet2Pt(0) | |
1800 | ,fh1JetPt(0) | |
1801 | ,fh2Xi1(0) | |
1802 | ,fh2Xi2(0) | |
1803 | ,fh2Xi(0) | |
1804 | ,fh2Z1(0) | |
1805 | ,fh2Z2(0) | |
1806 | ,fh2Z(0) | |
1807 | ,fh2Pt1(0) | |
1808 | ,fh2Pt2(0) | |
1809 | ,fh2Pt(0) | |
fceb275f | 1810 | ,fNameDJ(name) |
656dc810 | 1811 | { |
1812 | // default constructor | |
1813 | ||
1814 | } | |
1815 | ||
1816 | //______________________________________________________________________________________________________ | |
1817 | AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::AliFragFuncDiJetHistos(const AliFragFuncDiJetHistos& copy) | |
1818 | : TObject() | |
1819 | ,fKindSlices(copy.fKindSlices) | |
1820 | ,fNBinsJetInvMass(copy.fNBinsJetInvMass) | |
1821 | ,fJetInvMassMin(copy.fJetInvMassMin) | |
1822 | ,fJetInvMassMax(copy.fJetInvMassMax) | |
1823 | ,fNBinsJetPt(copy.fNBinsJetPt) | |
1824 | ,fJetPtMin(copy.fJetPtMin) | |
1825 | ,fJetPtMax(copy.fJetPtMax) | |
1826 | ,fNBinsPt(copy.fNBinsPt) | |
1827 | ,fPtMin(copy.fPtMin) | |
1828 | ,fPtMax(copy.fPtMax) | |
1829 | ,fNBinsXi(copy.fNBinsXi) | |
1830 | ,fXiMin(copy.fXiMin) | |
1831 | ,fXiMax(copy.fXiMax) | |
1832 | ,fNBinsZ(copy.fNBinsZ) | |
1833 | ,fZMin(copy.fZMin) | |
1834 | ,fZMax(copy.fZMax) | |
1835 | ,fh2TrackPtJet1(copy.fh2TrackPtJet1) | |
1836 | ,fh2TrackPtJet2(copy.fh2TrackPtJet2) | |
1837 | ,fh2TrackPtJet(copy.fh2TrackPtJet) | |
1838 | ,fh1Jet1Pt(copy.fh1Jet1Pt) | |
1839 | ,fh1Jet2Pt(copy.fh1Jet2Pt) | |
1840 | ,fh1JetPt(copy.fh1JetPt) | |
1841 | ,fh2Xi1(copy.fh2Xi1) | |
1842 | ,fh2Xi2(copy.fh2Xi2) | |
1843 | ,fh2Xi(copy.fh2Xi2) | |
1844 | ,fh2Z1(copy.fh2Z1) | |
1845 | ,fh2Z2(copy.fh2Z2) | |
1846 | ,fh2Z(copy.fh2Z) | |
1847 | ,fh2Pt1(copy.fh2Pt1) | |
1848 | ,fh2Pt2(copy.fh2Pt2) | |
1849 | ,fh2Pt(copy.fh2Pt) | |
fceb275f | 1850 | ,fNameDJ(copy.fNameDJ) |
656dc810 | 1851 | { |
1852 | // default constructor | |
1853 | ||
1854 | } | |
1855 | ||
1856 | //_______________________________________________________________________________________________________________________________________________________________ | |
1857 | AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos& AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::operator=(const AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos& o) | |
1858 | { | |
1859 | // assignment | |
1860 | ||
1861 | if(this!=&o){ | |
1862 | TObject::operator=(o); | |
1863 | fKindSlices = o.fKindSlices; | |
1864 | fNBinsJetInvMass = o.fNBinsJetInvMass; | |
1865 | fJetInvMassMin = o.fJetInvMassMin; | |
1866 | fJetInvMassMax = o.fJetInvMassMax; | |
1867 | fNBinsJetPt = o.fNBinsJetPt; | |
1868 | fJetPtMin = o.fJetPtMin; | |
1869 | fJetPtMax = o.fJetPtMax; | |
1870 | fNBinsPt = o.fNBinsPt; | |
1871 | fPtMin = o.fPtMin; | |
1872 | fPtMax = o.fPtMax; | |
1873 | fNBinsXi = o.fNBinsXi; | |
1874 | fXiMin = o.fXiMin; | |
1875 | fXiMax = o.fXiMax; | |
1876 | fNBinsZ = o.fNBinsZ; | |
1877 | fZMin = o.fZMin; | |
1878 | fZMax = o.fZMax; | |
1879 | fh2TrackPtJet1 = o.fh2TrackPtJet1; | |
1880 | fh2TrackPtJet2 = o.fh2TrackPtJet2; | |
1881 | fh2TrackPtJet = o.fh2TrackPtJet; | |
1882 | fh1Jet1Pt = o.fh1Jet1Pt; | |
1883 | fh1Jet2Pt = o.fh1Jet2Pt; | |
1884 | fh1JetPt = o.fh1JetPt; | |
1885 | fh2Xi1 = o.fh2Xi1; | |
1886 | fh2Xi2 = o.fh2Xi2; | |
1887 | fh2Xi = o.fh2Xi; | |
1888 | fh2Z1 = o.fh2Z1; | |
1889 | fh2Z2 = o.fh2Z2; | |
1890 | fh2Z = o.fh2Z; | |
1891 | fh2Pt1 = o.fh2Pt1; | |
1892 | fh2Pt2 = o.fh2Pt2; | |
1893 | fh2Pt = o.fh2Pt; | |
fceb275f | 1894 | fNameDJ = o.fNameDJ; |
656dc810 | 1895 | } |
1896 | ||
1897 | return *this; | |
1898 | } | |
1899 | ||
1900 | //_________________________________________________________ | |
1901 | AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::~AliFragFuncDiJetHistos() | |
1902 | { | |
1903 | // destructor | |
1904 | ||
1905 | if(fh2TrackPtJet1) delete fh2TrackPtJet1; | |
1906 | if(fh2TrackPtJet2) delete fh2TrackPtJet2; | |
1907 | if(fh2TrackPtJet ) delete fh2TrackPtJet; | |
1908 | if(fh1Jet1Pt) delete fh1Jet1Pt; | |
1909 | if(fh1Jet2Pt) delete fh1Jet2Pt; | |
1910 | if(fh1JetPt) delete fh1JetPt; | |
1911 | if(fh2Xi1) delete fh2Xi1; | |
1912 | if(fh2Xi2) delete fh2Xi2; | |
1913 | if(fh2Xi) delete fh2Xi; | |
1914 | if(fh2Z1) delete fh2Z1; | |
1915 | if(fh2Z2) delete fh2Z2; | |
1916 | if(fh2Z) delete fh2Z; | |
1917 | if(fh2Pt1) delete fh2Pt1; | |
1918 | if(fh2Pt2) delete fh2Pt2; | |
1919 | if(fh2Pt) delete fh2Pt; | |
1920 | } | |
1921 | ||
1922 | //________________________________________________________________________ | |
1923 | void AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::DefineDiJetHistos() | |
1924 | { | |
fceb275f | 1925 | // book DiJet histos |
1926 | ||
656dc810 | 1927 | Int_t nBins = 0; |
1928 | Double_t min = 0.; | |
1929 | Double_t max = 0.; | |
1930 | const char *xaxis = ""; | |
1931 | if(fKindSlices == 1) | |
1932 | { | |
1933 | nBins = fNBinsJetInvMass; | |
1934 | min = fJetInvMassMin; | |
1935 | max = fJetInvMassMax; | |
1936 | xaxis = "M_{JJ} [GeV]"; | |
1937 | } | |
1938 | if(fKindSlices == 2 || fKindSlices == 3) | |
1939 | { | |
1940 | nBins = fNBinsJetPt; | |
1941 | min = fJetPtMin; | |
1942 | max = fJetPtMax; | |
1943 | if(fKindSlices == 2) xaxis = "E_{Tmean} [GeV]"; | |
1944 | if(fKindSlices == 3) xaxis ="leading jet p_{T} [GeV/c]"; | |
1945 | } | |
1946 | ||
fceb275f | 1947 | fh1Jet1Pt = new TH1F(Form("fh1DJJet1Pt%s", fNameDJ.Data()), "", fNBinsJetPt, fJetPtMin, fJetPtMax); |
1948 | fh1Jet2Pt = new TH1F(Form("fh1DJJet2Pt%s", fNameDJ.Data()), "", fNBinsJetPt, fJetPtMin, fJetPtMax); | |
1949 | fh1JetPt = new TH1F(Form("fh1DJJetPt%s", fNameDJ.Data()), "", fNBinsJetPt, fJetPtMin, fJetPtMax); | |
656dc810 | 1950 | |
fceb275f | 1951 | fh2TrackPtJet1 = new TH2F(Form("fh2DJTrackPtJet1%s", fNameDJ.Data()), "",nBins, min, max, fNBinsPt, fPtMin, fPtMax); |
1952 | fh2TrackPtJet2 = new TH2F(Form("fh2DJTrackPtJet2%s", fNameDJ.Data()), "",nBins, min, max, fNBinsPt, fPtMin, fPtMax); | |
1953 | fh2TrackPtJet = new TH2F(Form("fh2DJTrackPtJet%s", fNameDJ.Data()), "",nBins, min, max, fNBinsPt, fPtMin, fPtMax); | |
656dc810 | 1954 | |
fceb275f | 1955 | fh2Xi1 = new TH2F(Form("fh2DJXi1%s", fNameDJ.Data()), "",nBins, min, max, fNBinsXi, fXiMin, fXiMax); |
1956 | fh2Xi2 = new TH2F(Form("fh2DJXi2%s", fNameDJ.Data()), "",nBins, min, max, fNBinsXi, fXiMin, fXiMax); | |
1957 | fh2Xi = new TH2F(Form("fh2DJXi%s", fNameDJ.Data()), "",nBins, min, max, fNBinsXi, fXiMin, fXiMax); | |
656dc810 | 1958 | |
fceb275f | 1959 | fh2Z1 = new TH2F(Form("fh2DJZ1%s", fNameDJ.Data()), "",nBins, min, max, fNBinsZ, fZMin, fZMax); |
1960 | fh2Z2 = new TH2F(Form("fh2DJZ2%s", fNameDJ.Data()), "",nBins, min, max, fNBinsZ, fZMin, fZMax); | |
1961 | fh2Z = new TH2F(Form("fh2DJZ%s", fNameDJ.Data()), "",nBins, min, max, fNBinsZ, fZMin, fZMax); | |
656dc810 | 1962 | |
fceb275f | 1963 | fh2Pt1 = new TH2F(Form("fh2DJPt1%s", fNameDJ.Data()), "",nBins, min, max, fNBinsPt, fPtMin, fPtMax); |
1964 | fh2Pt2 = new TH2F(Form("fh2DJPt2%s", fNameDJ.Data()), "",nBins, min, max, fNBinsPt, fPtMin, fPtMax); | |
1965 | fh2Pt = new TH2F(Form("fh2DJPtZ%s", fNameDJ.Data()), "",nBins, min, max, fNBinsPt, fPtMin, fPtMax); | |
656dc810 | 1966 | |
1967 | AliAnalysisTaskFragmentationFunction::SetProperties(fh1Jet1Pt, "p_{T} [GeV/c]", "entries"); | |
1968 | AliAnalysisTaskFragmentationFunction::SetProperties(fh1Jet2Pt, "p_{T} [GeV/c]", "entries"); | |
1969 | AliAnalysisTaskFragmentationFunction::SetProperties(fh1JetPt, "p_{T} [GeV/c]", "entries"); | |
1970 | ||
1971 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2TrackPtJet1, xaxis, "p_{T} [GeV/c]", "Entries"); | |
1972 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2TrackPtJet2, xaxis, "p_{T} [GeV/c]", "Entries"); | |
1973 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2TrackPtJet, xaxis, "p_{T} [GeV/c]", "Entries"); | |
1974 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Xi1, xaxis, "#xi", "Entries"); | |
1975 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Xi2, xaxis, "#xi", "Entries"); | |
1976 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Xi, xaxis, "#xi", "Entries"); | |
1977 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Z1, xaxis, "z", "Entries"); | |
1978 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Z2, xaxis, "z", "Entries"); | |
1979 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Z, xaxis, "z", "Entries"); | |
1980 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Pt1, xaxis, "p_{T} [GeV/c]", "Entries"); | |
1981 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Pt2, xaxis, "p_{T} [GeV/c]", "Entries"); | |
1982 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2Pt, xaxis, "p_{T} [GeV/c]", "Entries"); | |
656dc810 | 1983 | } |
1984 | ||
1985 | //________________________________________________________________________ | |
1986 | void AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::FillDiJetFF(Int_t jetType, Float_t trackPt, Float_t jetPt, Double_t jetBin, Bool_t incrementJetPt) | |
1987 | { | |
fceb275f | 1988 | // fill DiJet FF |
1989 | ||
656dc810 | 1990 | if(jetType == 0) |
1991 | { | |
1992 | if(incrementJetPt) fh1JetPt->Fill(jetPt); | |
1993 | ||
1994 | fh2TrackPtJet->Fill(jetBin, trackPt); | |
1995 | ||
1996 | Double_t z = trackPt / jetPt; | |
1997 | Double_t xi = 0; | |
3af23c82 | 1998 | if(z>0) xi = TMath::Log(1/z); |
656dc810 | 1999 | |
2000 | fh2Xi->Fill(jetBin, xi); | |
2001 | fh2Z->Fill(jetBin, z); | |
2002 | } | |
2003 | if(jetType == 1) | |
2004 | { | |
2005 | if(incrementJetPt) fh1Jet1Pt->Fill(jetPt); | |
2006 | ||
2007 | fh2TrackPtJet1->Fill(jetBin, trackPt); | |
2008 | ||
2009 | Double_t z = trackPt / jetPt; | |
2010 | Double_t xi = 0; | |
3af23c82 | 2011 | if(z>0) xi = TMath::Log(1/z); |
656dc810 | 2012 | |
2013 | fh2Xi1->Fill(jetBin, xi); | |
2014 | fh2Z1->Fill(jetBin, z); | |
2015 | } | |
2016 | if(jetType == 2) | |
2017 | { | |
2018 | if(incrementJetPt) fh1Jet2Pt->Fill(jetPt); | |
2019 | ||
2020 | fh2TrackPtJet2->Fill(jetBin, trackPt); | |
2021 | ||
2022 | Double_t z = trackPt / jetPt; | |
2023 | Double_t xi = 0; | |
3af23c82 | 2024 | if(z>0) xi = TMath::Log(1/z); |
656dc810 | 2025 | |
2026 | fh2Xi2->Fill(jetBin, xi); | |
2027 | fh2Z2->Fill(jetBin, z); | |
2028 | } | |
2029 | ||
2030 | ||
2031 | } | |
2032 | ||
2033 | //________________________________________________________________________ | |
2034 | void AliAnalysisTaskFragmentationFunction::AliFragFuncDiJetHistos::AddToOutput(TList* list)const | |
2035 | { | |
fceb275f | 2036 | // add histos to list |
2037 | ||
656dc810 | 2038 | list->Add(fh1Jet1Pt); |
2039 | list->Add(fh1Jet2Pt); | |
2040 | list->Add(fh1JetPt); | |
2041 | list->Add(fh2TrackPtJet1); | |
2042 | list->Add(fh2TrackPtJet2); | |
2043 | list->Add(fh2TrackPtJet); | |
2044 | list->Add(fh2Xi1); | |
2045 | list->Add(fh2Xi2); | |
2046 | list->Add(fh2Xi); | |
2047 | list->Add(fh2Z1); | |
2048 | list->Add(fh2Z2); | |
2049 | list->Add(fh2Z); | |
2050 | } | |
2051 | ||
2052 | //______________________________________________________________________________________________________ | |
2053 | AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::AliFragFuncQADiJetHistos(const char* name, Int_t kindSlices, | |
3af23c82 | 2054 | Int_t nInvMass, Float_t invMassMin, Float_t invMassMax, |
656dc810 | 2055 | Int_t nJetPt, Float_t jetPtMin, Float_t jetPtMax, |
3af23c82 | 2056 | Int_t nDeltaPhi, Float_t deltaPhiMin, Float_t deltaPhiMax, |
2057 | Int_t nDeltaEta, Float_t deltaEtaMin, Float_t deltaEtaMax, | |
2058 | Int_t nDeltaPt, Float_t deltaPtMin, Float_t deltaPtMax, | |
2059 | Int_t nInBal, Float_t inBalMin, Float_t inBalMax) | |
656dc810 | 2060 | : TObject() |
2061 | ,fKindSlices(kindSlices) | |
2062 | ,fNBinsJetInvMass(nInvMass) | |
2063 | ,fJetInvMassMin(invMassMin) | |
2064 | ,fJetInvMassMax(invMassMax) | |
2065 | ,fNBinsJetPt(nJetPt) | |
2066 | ,fJetPtMin(jetPtMin) | |
2067 | ,fJetPtMax(jetPtMax) | |
2068 | ,fNBinsDeltaPhi(nDeltaPhi) | |
2069 | ,fDeltaPhiMin(deltaPhiMin) | |
2070 | ,fDeltaPhiMax(deltaPhiMax) | |
2071 | ,fNBinsDeltaEta(nDeltaEta) | |
2072 | ,fDeltaEtaMin(deltaEtaMin) | |
2073 | ,fDeltaEtaMax(deltaEtaMax) | |
2074 | ,fNBinsDeltaPt(nDeltaPt) | |
2075 | ,fDeltaPtMin(deltaPtMin) | |
2076 | ,fDeltaPtMax(deltaPtMax) | |
3af23c82 | 2077 | ,fNBinsInBal(nInBal) |
2078 | ,fInBalMin(inBalMin) | |
2079 | ,fInBalMax(inBalMax) | |
656dc810 | 2080 | ,fh2InvMass(0) |
2081 | ,fh2DeltaPhi(0) | |
2082 | ,fh2DeltaEta(0) | |
2083 | ,fh2DeltaPt(0) | |
3af23c82 | 2084 | ,fh2InBal(0) |
fceb275f | 2085 | ,fNameQADJ(name) |
656dc810 | 2086 | { |
2087 | // default constructor | |
2088 | ||
2089 | } | |
2090 | ||
2091 | //______________________________________________________________________________________________________ | |
2092 | AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::AliFragFuncQADiJetHistos(const AliFragFuncQADiJetHistos& copy) | |
2093 | : TObject() | |
2094 | ,fKindSlices(copy.fKindSlices) | |
2095 | ,fNBinsJetInvMass(copy.fNBinsJetInvMass) | |
2096 | ,fJetInvMassMin(copy.fJetInvMassMin) | |
2097 | ,fJetInvMassMax(copy.fJetInvMassMax) | |
2098 | ,fNBinsJetPt(copy.fNBinsJetPt) | |
2099 | ,fJetPtMin(copy.fJetPtMin) | |
2100 | ,fJetPtMax(copy.fJetPtMax) | |
2101 | ,fNBinsDeltaPhi(copy.fNBinsDeltaPhi) | |
2102 | ,fDeltaPhiMin(copy.fDeltaPhiMin) | |
2103 | ,fDeltaPhiMax(copy.fDeltaPhiMax) | |
2104 | ,fNBinsDeltaEta(copy.fNBinsDeltaEta) | |
2105 | ,fDeltaEtaMin(copy.fDeltaEtaMin) | |
2106 | ,fDeltaEtaMax(copy.fDeltaEtaMax) | |
2107 | ,fNBinsDeltaPt(copy.fNBinsDeltaPt) | |
2108 | ,fDeltaPtMin(copy.fDeltaPtMin) | |
2109 | ,fDeltaPtMax(copy.fDeltaPtMax) | |
3af23c82 | 2110 | ,fNBinsInBal(copy.fNBinsInBal) |
2111 | ,fInBalMin(copy.fInBalMin) | |
2112 | ,fInBalMax(copy.fInBalMax) | |
656dc810 | 2113 | ,fh2InvMass(copy.fh2InvMass) |
2114 | ,fh2DeltaPhi(copy.fh2DeltaPhi) | |
2115 | ,fh2DeltaEta(copy.fh2DeltaEta) | |
2116 | ,fh2DeltaPt(copy.fh2DeltaPt) | |
3af23c82 | 2117 | ,fh2InBal(copy.fh2InBal) |
fceb275f | 2118 | ,fNameQADJ(copy.fNameQADJ) |
656dc810 | 2119 | { |
2120 | // default constructor | |
2121 | ||
2122 | } | |
2123 | ||
2124 | //_______________________________________________________________________________________________________________________________________________________________ | |
2125 | AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos& AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::operator=(const AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos& o) | |
2126 | { | |
2127 | // assignment | |
2128 | ||
2129 | if(this!=&o){ | |
2130 | TObject::operator=(o); | |
2131 | fKindSlices = o.fKindSlices; | |
2132 | fNBinsJetInvMass = o.fNBinsJetInvMass; | |
2133 | fJetInvMassMin = o.fJetInvMassMin; | |
2134 | fJetInvMassMax = o.fJetInvMassMax; | |
2135 | fNBinsJetPt = o.fNBinsJetPt; | |
2136 | fJetPtMin = o.fJetPtMin; | |
2137 | fJetPtMax = o.fJetPtMax; | |
2138 | fNBinsDeltaPhi = o.fNBinsDeltaPhi; | |
2139 | fDeltaPhiMin = o.fDeltaPhiMin; | |
2140 | fDeltaPhiMax = o.fDeltaPhiMax; | |
2141 | fNBinsDeltaEta = o.fNBinsDeltaEta; | |
2142 | fDeltaEtaMin = o.fDeltaEtaMin; | |
2143 | fDeltaEtaMax = o.fDeltaEtaMax; | |
2144 | fNBinsDeltaPt = o.fNBinsDeltaPt; | |
2145 | fDeltaPtMin = o.fDeltaPtMin; | |
2146 | fDeltaPtMax = o.fDeltaPtMax; | |
3af23c82 | 2147 | fNBinsInBal = o.fNBinsInBal; |
2148 | fInBalMin = o.fInBalMin; | |
2149 | fInBalMax = o.fInBalMax; | |
656dc810 | 2150 | fh2InvMass = o.fh2InvMass; |
2151 | fh2DeltaPhi = o.fh2DeltaPhi; | |
2152 | fh2DeltaEta = o.fh2DeltaEta; | |
2153 | fh2DeltaPt = o.fh2DeltaPt; | |
3af23c82 | 2154 | fh2InBal = o.fh2InBal; |
fceb275f | 2155 | fNameQADJ = o.fNameQADJ; |
656dc810 | 2156 | } |
2157 | ||
2158 | return *this; | |
2159 | } | |
2160 | ||
2161 | //_________________________________________________________ | |
2162 | AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::~AliFragFuncQADiJetHistos() | |
2163 | { | |
2164 | // destructor | |
2165 | ||
2166 | if(fh2InvMass) delete fh2InvMass; | |
2167 | if(fh2DeltaPhi) delete fh2DeltaPhi; | |
2168 | if(fh2DeltaEta) delete fh2DeltaEta; | |
2169 | if(fh2DeltaPt) delete fh2DeltaPt; | |
3af23c82 | 2170 | if(fh2InBal) delete fh2InBal; |
656dc810 | 2171 | } |
2172 | ||
2173 | //________________________________________________________________________ | |
2174 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::DefineQADiJetHistos() | |
2175 | { | |
fceb275f | 2176 | // define histos |
2177 | ||
656dc810 | 2178 | Int_t nBins = 0; |
2179 | Double_t min = 0.; | |
2180 | Double_t max = 0.; | |
2181 | const char *xaxis = ""; | |
2182 | if(fKindSlices == 1) | |
2183 | { | |
2184 | nBins = fNBinsJetInvMass; | |
2185 | min = fJetInvMassMin; | |
2186 | max = fJetInvMassMax; | |
2187 | xaxis = "M_{JJ} [GeV]"; | |
2188 | } | |
2189 | if(fKindSlices == 2 || fKindSlices == 3) | |
2190 | { | |
2191 | nBins = fNBinsJetPt; | |
2192 | min = fJetPtMin; | |
2193 | max = fJetPtMax; | |
2194 | if(fKindSlices == 2) xaxis = "E_{Tmean} [GeV]"; | |
2195 | if(fKindSlices == 3) xaxis ="leading jet p_{T} [GeV/c]"; | |
2196 | } | |
2197 | ||
2198 | ||
fceb275f | 2199 | fh2InvMass = new TH2F(Form("fh2DJInvMassPositionCut%s", fNameQADJ.Data()), "",nBins, min, max, fNBinsJetInvMass, fJetInvMassMin, fJetInvMassMax); |
2200 | fh2DeltaPhi = new TH2F(Form("fh2DJDeltaPhiPositionCut%s", fNameQADJ.Data()), "",nBins, min, max, fNBinsDeltaPhi, fDeltaPhiMin, fDeltaPhiMax); | |
2201 | fh2DeltaEta = new TH2F(Form("fh2DJDeltaEtaPositionCut%s", fNameQADJ.Data()), "",nBins, min, max, fNBinsDeltaEta, fDeltaEtaMin, fDeltaEtaMax); | |
2202 | fh2DeltaPt = new TH2F(Form("fh2DJDeltaPtPositionCut%s", fNameQADJ.Data()), "",nBins, min, max, fNBinsDeltaPt, fDeltaPtMin, fDeltaPtMax); | |
3af23c82 | 2203 | fh2InBal = new TH2F(Form("fh2DJInBalPositionCut%s", fNameQADJ.Data()), "",nBins, min, max, fNBinsInBal, fInBalMin, fInBalMax); |
2204 | ||
656dc810 | 2205 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2InvMass, xaxis, "Invariant Mass", "Entries"); |
2206 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2DeltaPhi, xaxis, "#Delta #phi", "Entries"); | |
2207 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2DeltaEta, xaxis, "#Delta #eta", "Entries"); | |
2208 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2DeltaPt, xaxis, "#Delta p_{T}", "Entries"); | |
3af23c82 | 2209 | AliAnalysisTaskFragmentationFunction::SetProperties(fh2InBal, xaxis, "(p_{T}^{1}-p_{T}^{2})/(p_{T}^{1}+p_{T}^{2})", "Entries"); |
656dc810 | 2210 | |
2211 | } | |
2212 | ||
2213 | //________________________________________________________________________ | |
3af23c82 | 2214 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::FillDiJetQA(Double_t invMass, Double_t deltaPhi, Double_t deltaEta,Double_t deltaPt, Double_t inbal, Double_t jetBin) |
656dc810 | 2215 | { |
fceb275f | 2216 | // fill dijet QA |
2217 | ||
656dc810 | 2218 | fh2InvMass->Fill(jetBin, invMass); |
2219 | fh2DeltaPhi->Fill(jetBin, deltaPhi); | |
2220 | fh2DeltaEta->Fill(jetBin, deltaEta); | |
2221 | fh2DeltaPt->Fill(jetBin, deltaPt); | |
3af23c82 | 2222 | fh2InBal->Fill(jetBin, inbal); |
656dc810 | 2223 | } |
2224 | ||
2225 | //________________________________________________________________________ | |
2226 | void AliAnalysisTaskFragmentationFunction::AliFragFuncQADiJetHistos::AddToOutput(TList* list)const | |
2227 | { | |
fceb275f | 2228 | // add histos to list |
2229 | ||
656dc810 | 2230 | list->Add(fh2InvMass); |
2231 | list->Add(fh2DeltaPhi); | |
2232 | list->Add(fh2DeltaEta); | |
2233 | list->Add(fh2DeltaPt); | |
3af23c82 | 2234 | list->Add(fh2InBal); |
656dc810 | 2235 | } |
2236 | ||
2237 | //_________________________________________________________________________________ | |
2238 | void AliAnalysisTaskFragmentationFunction::AliFragFuncIntraJetHistos::AddToOutput(TList* list) const | |
2239 | { | |
2240 | // add histos to list | |
2241 | ||
2242 | list->Add(fh2CosTheta); | |
67e37e80 | 2243 | list->Add(fh2PtZ); |
2244 | list->Add(fh3ThetaZ); | |
2245 | list->Add(fh3JtTheta); | |
2246 | list->Add(fh3JtZ); | |
656dc810 | 2247 | |
2248 | } | |
2249 | ||
1da9498b | 2250 | //_________________________________________________________________________________ |
ac017ff3 | 2251 | Bool_t AliAnalysisTaskFragmentationFunction::Notify() |
2252 | { | |
2253 | // | |
2254 | // Implemented Notify() to read the cross sections | |
2255 | // and number of trials from pyxsec.root | |
c2658535 | 2256 | // (taken from AliAnalysisTaskJetSpectrum2) |
ac017ff3 | 2257 | // |
2258 | TTree *tree = AliAnalysisManager::GetAnalysisManager()->GetTree(); | |
c2658535 | 2259 | Float_t xsection = 0; |
2260 | Float_t ftrials = 1; | |
2261 | ||
2262 | fAvgTrials = 1; | |
ac017ff3 | 2263 | if(tree){ |
2264 | TFile *curfile = tree->GetCurrentFile(); | |
2265 | if (!curfile) { | |
2266 | Error("Notify","No current file"); | |
2267 | return kFALSE; | |
2268 | } | |
2269 | if(!fh1Xsec||!fh1Trials){ | |
2270 | Printf("%s%d No Histogram fh1Xsec",(char*)__FILE__,__LINE__); | |
2271 | return kFALSE; | |
2272 | } | |
c2658535 | 2273 | AliAnalysisHelperJetTasks::PythiaInfoFromFile(curfile->GetName(),xsection,ftrials); |
ac017ff3 | 2274 | fh1Xsec->Fill("<#sigma>",xsection); |
c2658535 | 2275 | // construct a poor man average trials |
2276 | Float_t nEntries = (Float_t)tree->GetTree()->GetEntries(); | |
2277 | if(ftrials>=nEntries && nEntries>0.)fAvgTrials = ftrials/nEntries; | |
ac017ff3 | 2278 | } |
67e37e80 | 2279 | |
2280 | // Set seed for backg study | |
2281 | fRandom = new TRandom3(); | |
2282 | fRandom->SetSeed(0); | |
2283 | ||
ac017ff3 | 2284 | return kTRUE; |
2285 | } | |
2286 | ||
2287 | ||
2288 | ||
656dc810 | 2289 | //__________________________________________________________________ |
2290 | void AliAnalysisTaskFragmentationFunction::UserCreateOutputObjects() | |
2291 | { | |
2292 | // create output objects | |
2293 | ||
2294 | if(fDebug > 1) Printf("AliAnalysisTaskFragmentationFunction::UserCreateOutputObjects()"); | |
2295 | ||
2296 | // create list of tracks and jets | |
2297 | ||
2298 | fTracksRec = new TList(); | |
2299 | fTracksRec->SetOwner(kFALSE); | |
2300 | ||
2301 | fTracksRecCuts = new TList(); | |
2302 | fTracksRecCuts->SetOwner(kFALSE); | |
2303 | ||
2304 | fTracksGen = new TList(); | |
2305 | fTracksGen->SetOwner(kFALSE); | |
2306 | ||
fe343c6b | 2307 | fTracksAODMCCharged = new TList(); |
2308 | fTracksAODMCCharged->SetOwner(kFALSE); | |
2309 | ||
2310 | fTracksRecQualityCuts = new TList(); | |
2311 | fTracksRecQualityCuts->SetOwner(kFALSE); | |
2312 | ||
656dc810 | 2313 | fJetsRec = new TList(); |
2314 | fJetsRec->SetOwner(kFALSE); | |
44b235ce | 2315 | if(fBranchRecJets.Contains("KT") && fBckgSubMethod) fJetsRec->SetOwner(kTRUE); |
656dc810 | 2316 | |
2317 | fJetsRecCuts = new TList(); | |
2318 | fJetsRecCuts->SetOwner(kFALSE); | |
44b235ce | 2319 | if(fBranchRecJets.Contains("KT") && fBckgSubMethod) fJetsRecCuts->SetOwner(kTRUE); |
656dc810 | 2320 | |
2321 | fJetsGen = new TList(); | |
2322 | fJetsGen->SetOwner(kFALSE); | |
2323 | ||
fe343c6b | 2324 | fJetsRecEff = new TList(); |
2325 | fJetsRecEff->SetOwner(kFALSE); | |
2326 | ||
656dc810 | 2327 | // fJetsKine = new TList(); |
2328 | // fJetsKine->SetOwner(kTRUE); // delete AOD jets using mom from Kine Tree via TList::Clear() | |
2329 | ||
742ee86c | 2330 | if(fBckgMode && |
3170a3f8 | 2331 | (fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters || |
2332 | fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || | |
2333 | fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading)){ | |
742ee86c | 2334 | |
67e37e80 | 2335 | fBckgJetsRec = new TList(); |
2336 | fBckgJetsRec->SetOwner(kFALSE); | |
2337 | ||
2338 | fBckgJetsRecCuts = new TList(); | |
2339 | fBckgJetsRecCuts->SetOwner(kFALSE); | |
2340 | ||
2341 | fBckgJetsGen = new TList(); | |
2342 | fBckgJetsGen->SetOwner(kFALSE); | |
2343 | } | |
656dc810 | 2344 | |
2345 | // | |
2346 | // Create histograms / output container | |
2347 | // | |
2348 | ||
2349 | OpenFile(1); | |
2350 | fCommonHistList = new TList(); | |
2351 | ||
2352 | Bool_t oldStatus = TH1::AddDirectoryStatus(); | |
2353 | TH1::AddDirectory(kFALSE); | |
2354 | ||
2355 | ||
2356 | // Histograms | |
2357 | fh1EvtSelection = new TH1F("fh1EvtSelection", "Event Selection", 6, -0.5, 5.5); | |
3af23c82 | 2358 | fh1EvtSelection->GetXaxis()->SetBinLabel(1,"ACCEPTED"); |
2359 | fh1EvtSelection->GetXaxis()->SetBinLabel(2,"event selection: rejected"); | |
2360 | fh1EvtSelection->GetXaxis()->SetBinLabel(3,"event class: rejected"); | |
2361 | fh1EvtSelection->GetXaxis()->SetBinLabel(4,"vertex Ncontr: rejected"); | |
2362 | fh1EvtSelection->GetXaxis()->SetBinLabel(5,"vertex z: rejected"); | |
2363 | fh1EvtSelection->GetXaxis()->SetBinLabel(6,"vertex type: rejected"); | |
2364 | ||
742ee86c | 2365 | fh1VertexNContributors = new TH1F("fh1VertexNContributors", "Vertex N contributors", 2500,-.5, 2499.5); |
656dc810 | 2366 | fh1VertexZ = new TH1F("fh1VertexZ", "Vertex z distribution", 30, -15., 15.); |
3af23c82 | 2367 | fh1EvtMult = new TH1F("fh1EvtMult","Event multiplicity, track pT cut > 150 MeV/c, |#eta| < 0.9",120,0.,12000.); |
2368 | fh1EvtCent = new TH1F("fh1EvtCent","centrality",100,0.,100.); | |
3170a3f8 | 2369 | fh2TrackPtVsDCAXY = new TH2F("fh2TrackPtVsDCAXY","",400,-0.02,0.02,100,0.,10.); |
2370 | fh2TrackPtVsDCAZ = new TH2F("fh2TrackPtVsDCAZ","",100,-0.050,0.050,100,0.,10.); | |
2371 | ||
ac017ff3 | 2372 | fh1Xsec = new TProfile("fh1Xsec","xsec from pyxsec.root",1,0,1); |
2373 | fh1Xsec->GetXaxis()->SetBinLabel(1,"<#sigma>"); | |
2374 | fh1Trials = new TH1F("fh1Trials","trials from pyxsec.root",1,0,1); | |
2375 | fh1Trials->GetXaxis()->SetBinLabel(1,"#sum{ntrials}"); | |
2376 | fh1PtHard = new TH1F("fh1PtHard","PYTHIA Pt hard;p_{T,hard}",350,-.5,349.5); | |
2377 | fh1PtHardTrials = new TH1F("fh1PtHardTrials","PYTHIA Pt hard weight with trials;p_{T,hard}",350,-.5,349.5); | |
2378 | ||
656dc810 | 2379 | fh1nRecJetsCuts = new TH1F("fh1nRecJetsCuts","reconstructed jets per event",10,-0.5,9.5); |
2380 | fh1nGenJets = new TH1F("fh1nGenJets","generated jets per event",10,-0.5,9.5); | |
fe343c6b | 2381 | fh1nRecEffJets = new TH1F("fh1nRecEffJets","reconstruction effiency: jets per event",10,-0.5,9.5); |
cb76764e | 2382 | fh2PtRecVsGenPrim = new TH2F("fh2PtRecVsGenPrim","rec vs gen pt",fQATrackNBinsPt,fQATrackPtMin,fQATrackPtMax,fQATrackNBinsPt,fQATrackPtMin,fQATrackPtMax); |
fe343c6b | 2383 | |
67e37e80 | 2384 | // Background |
2385 | if(fBckgMode) { | |
3170a3f8 | 2386 | if(fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters || |
2387 | fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || | |
2388 | fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading){ | |
742ee86c | 2389 | |
67e37e80 | 2390 | fh1nRecBckgJetsCuts = new TH1F("fh1nRecBckgJetsCuts","reconstructed background jets per event",10,-0.5,9.5); |
2391 | fh1nGenBckgJets = new TH1F("fh1nGenBckgJets","generated background jets per event",10,-0.5,9.5); | |
2392 | } | |
1da9498b | 2393 | |
3170a3f8 | 2394 | if(fBckgType[0]==kBckgPerp || fBckgType[1]==kBckgPerp || fBckgType[2]==kBckgPerp || fBckgType[3]==kBckgPerp || fBckgType[4]==kBckgPerp ) |
742ee86c | 2395 | fh1PerpMult = new TH1F("fh1PerpMult","Background multiplicity - Cone perpendicular to leading jet axis",500,0.,500.); |
3170a3f8 | 2396 | if(fBckgType[0]==kBckgASide || fBckgType[1]==kBckgASide || fBckgType[2]==kBckgASide || fBckgType[3]==kBckgASide || fBckgType[4]==kBckgASide) |
742ee86c | 2397 | fh1ASideMult = new TH1F("fh1ASideMult","Background multiplicity - Cone in the away side of leading jet axis",500,0.,500.); |
3170a3f8 | 2398 | if(fBckgType[0]==kBckgASideWindow || fBckgType[1]==kBckgASideWindow || fBckgType[2]==kBckgASideWindow || fBckgType[3]==kBckgASideWindow || fBckgType[4]==kBckgASideWindow) |
742ee86c | 2399 | fh1ASideWindowMult = new TH1F("fh1ASideWindowMult","Background multiplicity - Cone in the away side of leading jet axis",500,0.,500.); |
3170a3f8 | 2400 | if(fBckgType[0]==kBckgPerpWindow || fBckgType[1]==kBckgPerpWindow || fBckgType[2]==kBckgPerpWindow || fBckgType[3]==kBckgPerpWindow || fBckgType[4]==kBckgPerpWindow) |
742ee86c | 2401 | fh1PerpWindowMult = new TH1F("fh1PerpWindowMult","Background multiplicity - Cone in the perp direction of leading jet axis",500,0.,500.); |
3170a3f8 | 2402 | if(fBckgType[0]==kBckgOutLJ || fBckgType[1]==kBckgOutLJ || fBckgType[2]==kBckgOutLJ || fBckgType[3]==kBckgOutLJ || fBckgType[4]==kBckgOutLJ) |
742ee86c | 2403 | fh1OutLeadingMult = new TH1F("fh1OutLeadingMult","Background multiplicity - Cone outside leading jet",500,0,500.); |
3170a3f8 | 2404 | if(fBckgType[0]==kBckgOutLJStat || fBckgType[1]==kBckgOutLJStat || fBckgType[2]==kBckgOutLJStat || fBckgType[3]==kBckgOutLJStat || fBckgType[4]==kBckgOutLJStat) |
742ee86c | 2405 | fh1OutLeadingStatMult = new TH1F("fh1OutLeadingStatMult","Background multiplicity - Cone outside leading jet",3000,0,3000.); |
3170a3f8 | 2406 | if(fBckgType[0]==kBckgOut2J || fBckgType[1]==kBckgOut2J || fBckgType[2]==kBckgOut2J || fBckgType[3]==kBckgOut2J || fBckgType[4]==kBckgOut2J) |
742ee86c | 2407 | fh1Out2JetsMult = new TH1F("fh1Out2JetsMult","Background multiplicity - Cone outside 2 jets",500,0.,500.); |
3170a3f8 | 2408 | if(fBckgType[0]==kBckgOut3J || fBckgType[1]==kBckgOut3J || fBckgType[2]==kBckgOut3J || fBckgType[3]==kBckgOut3J || fBckgType[4]==kBckgOut3J) |
742ee86c | 2409 | fh1Out3JetsMult = new TH1F("fh1Out3JetsMult","Background multiplicity - Cone outside 3 jets",500,0.,500.); |
3170a3f8 | 2410 | if(fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters) |
742ee86c | 2411 | fh1MedianClustersMult = new TH1F("fh1MedianClustersMult","Background multiplicity - median cluster",500,0.,500.); |
3170a3f8 | 2412 | if(fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || fBckgType[3]==kBckgClustersOutLeading |
2413 | || fBckgType[4]==kBckgClustersOutLeading) | |
742ee86c | 2414 | fh1OutClustersMult = new TH1F("fh1OutClustersMult","Background multiplicity - clusters outside leading jet",3000,0.,3000.); |
2415 | } | |
2416 | ||
3af23c82 | 2417 | if(fQAMode){ |
2418 | if(fQAMode&1){ // track QA | |
2419 | fQATrackHistosRec = new AliFragFuncQATrackHistos("Rec", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2420 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2421 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2422 | fQATrackHighPtThreshold); | |
2423 | fQATrackHistosRecCuts = new AliFragFuncQATrackHistos("RecCuts", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2424 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2425 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2426 | fQATrackHighPtThreshold); | |
2427 | fQATrackHistosGen = new AliFragFuncQATrackHistos("Gen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2428 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2429 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2430 | fQATrackHighPtThreshold); | |
2431 | } | |
656dc810 | 2432 | |
3af23c82 | 2433 | if(fQAMode&2){ // jet QA |
2434 | fQAJetHistosRec = new AliFragFuncQAJetHistos("Rec", fQAJetNBinsPt, fQAJetPtMin, fQAJetPtMax, | |
2435 | fQAJetNBinsEta, fQAJetEtaMin, fQAJetEtaMax, | |
2436 | fQAJetNBinsPhi, fQAJetPhiMin, fQAJetPhiMax); | |
2437 | fQAJetHistosRecCuts = new AliFragFuncQAJetHistos("RecCuts", fQAJetNBinsPt, fQAJetPtMin, fQAJetPtMax, | |
2438 | fQAJetNBinsEta, fQAJetEtaMin, fQAJetEtaMax, | |
2439 | fQAJetNBinsPhi, fQAJetPhiMin, fQAJetPhiMax); | |
2440 | fQAJetHistosRecCutsLeading = new AliFragFuncQAJetHistos("RecCutsLeading", fQAJetNBinsPt, fQAJetPtMin, fQAJetPtMax, | |
2441 | fQAJetNBinsEta, fQAJetEtaMin, fQAJetEtaMax, | |
2442 | fQAJetNBinsPhi, fQAJetPhiMin, fQAJetPhiMax); | |
2443 | fQAJetHistosGen = new AliFragFuncQAJetHistos("Gen", fQAJetNBinsPt, fQAJetPtMin, fQAJetPtMax, | |
2444 | fQAJetNBinsEta, fQAJetEtaMin, fQAJetEtaMax, | |
2445 | fQAJetNBinsPhi, fQAJetPhiMin, fQAJetPhiMax); | |
2446 | fQAJetHistosGenLeading = new AliFragFuncQAJetHistos("GenLeading", fQAJetNBinsPt, fQAJetPtMin, fQAJetPtMax, | |
2447 | fQAJetNBinsEta, fQAJetEtaMin, fQAJetEtaMax, | |
2448 | fQAJetNBinsPhi, fQAJetPhiMin, fQAJetPhiMax); | |
2449 | if(fEffMode) fQAJetHistosRecEffLeading = new AliFragFuncQAJetHistos("RecEffLeading", fQAJetNBinsPt, fQAJetPtMin, fQAJetPtMax, | |
2450 | fQAJetNBinsEta, fQAJetEtaMin, fQAJetEtaMax,fQAJetNBinsPhi, fQAJetPhiMin, fQAJetPhiMax); | |
2451 | } | |
2452 | } // end: QA | |
656dc810 | 2453 | |
3af23c82 | 2454 | if(fFFMode){ |
2455 | fFFHistosRecCuts = new AliFragFuncHistos("RecCuts", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
656dc810 | 2456 | fFFNBinsPt, fFFPtMin, fFFPtMax, |
2457 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2458 | fFFNBinsZ , fFFZMin , fFFZMax); | |
3af23c82 | 2459 | fFFHistosRecLeading = new AliFragFuncHistos("RecLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, |
2460 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2461 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2462 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2463 | fFFHistosRecLeadingTrack = new AliFragFuncHistos("RecLeadingTrack", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2464 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2465 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2466 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2467 | fFFHistosGen = new AliFragFuncHistos("Gen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
656dc810 | 2468 | fFFNBinsPt, fFFPtMin, fFFPtMax, |
2469 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2470 | fFFNBinsZ , fFFZMin , fFFZMax); | |
3af23c82 | 2471 | fFFHistosGenLeading = new AliFragFuncHistos("GenLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, |
2472 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2473 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2474 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2475 | fFFHistosGenLeadingTrack = new AliFragFuncHistos("GenLeadingTrack", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2476 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2477 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2478 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2479 | } // end: FF | |
656dc810 | 2480 | |
67e37e80 | 2481 | if(fIJMode) |
2482 | { | |
2483 | fIJHistosRecCuts = new AliFragFuncIntraJetHistos("RecCuts", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
2484 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2485 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2486 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2487 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2488 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2489 | fIJHistosRecLeading = new AliFragFuncIntraJetHistos("RecLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
2490 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2491 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2492 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2493 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2494 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2495 | fIJHistosRecLeadingTrack = new AliFragFuncIntraJetHistos("RecLeadingTrack", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
2496 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2497 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2498 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2499 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2500 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2501 | fIJHistosGen = new AliFragFuncIntraJetHistos("Gen", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
656dc810 | 2502 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2503 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2504 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2505 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2506 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2507 | fIJHistosGenLeading = new AliFragFuncIntraJetHistos("GenLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
2508 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2509 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2510 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2511 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2512 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2513 | fIJHistosGenLeadingTrack = new AliFragFuncIntraJetHistos("GenLeadingTrack", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
2514 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2515 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2516 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2517 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2518 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
3af23c82 | 2519 | } // end: intra-jet |
67e37e80 | 2520 | |
3af23c82 | 2521 | if(fDJMode){ |
2522 | if(fDJMode&1){ | |
2523 | fFFDiJetHistosRecCuts = new AliFragFuncDiJetHistos("RecCuts", fDiJetKindBins, | |
2524 | fDiJetNBinsJetInvMass, fDiJetJetInvMassMin, fDiJetJetInvMassMax, | |
2525 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2526 | fDiJetNBinsPt, fDiJetPtMin, fDiJetPtMax, | |
2527 | fDiJetNBinsXi, fDiJetXiMin, fDiJetXiMax, | |
2528 | fDiJetNBinsZ, fDiJetZMin, fDiJetZMax); | |
2529 | fFFDiJetHistosRecLeading = new AliFragFuncDiJetHistos("RecLeading", fDiJetKindBins, | |
2530 | fDiJetNBinsJetInvMass, fDiJetJetInvMassMin, fDiJetJetInvMassMax, | |
2531 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2532 | fDiJetNBinsPt, fDiJetPtMin, fDiJetPtMax, | |
2533 | fDiJetNBinsXi, fDiJetXiMin, fDiJetXiMax, | |
2534 | fDiJetNBinsZ, fDiJetZMin, fDiJetZMax); | |
2535 | fFFDiJetHistosRecLeadingTrack = new AliFragFuncDiJetHistos("RecLeadingTrack", fDiJetKindBins, | |
2536 | fDiJetNBinsJetInvMass, fDiJetJetInvMassMin, fDiJetJetInvMassMax, | |
2537 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2538 | fDiJetNBinsPt, fDiJetPtMin, fDiJetPtMax, | |
2539 | fDiJetNBinsXi, fDiJetXiMin, fDiJetXiMax, | |
2540 | fDiJetNBinsZ, fDiJetZMin, fDiJetZMax); | |
2541 | ||
2542 | fFFDiJetHistosGen = new AliFragFuncDiJetHistos("Gen", fDiJetKindBins, | |
2543 | fDiJetNBinsJetInvMass, fDiJetJetInvMassMin, fDiJetJetInvMassMax, | |
2544 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2545 | fDiJetNBinsPt, fDiJetPtMin, fDiJetPtMax, | |
2546 | fDiJetNBinsXi, fDiJetXiMin, fDiJetXiMax, | |
2547 | fDiJetNBinsZ, fDiJetZMin, fDiJetZMax); | |
2548 | fFFDiJetHistosGenLeading = new AliFragFuncDiJetHistos("GenLeading", fDiJetKindBins, | |
2549 | fDiJetNBinsJetInvMass, fDiJetJetInvMassMin, fDiJetJetInvMassMax, | |
2550 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2551 | fDiJetNBinsPt, fDiJetPtMin, fDiJetPtMax, | |
2552 | fDiJetNBinsXi, fDiJetXiMin, fDiJetXiMax, | |
2553 | fDiJetNBinsZ, fDiJetZMin, fDiJetZMax); | |
2554 | fFFDiJetHistosGenLeadingTrack = new AliFragFuncDiJetHistos("GenLeadingTrack", fDiJetKindBins, | |
2555 | fDiJetNBinsJetInvMass, fDiJetJetInvMassMin, fDiJetJetInvMassMax, | |
2556 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2557 | fDiJetNBinsPt, fDiJetPtMin, fDiJetPtMax, | |
2558 | fDiJetNBinsXi, fDiJetXiMin, fDiJetXiMax, | |
2559 | fDiJetNBinsZ, fDiJetZMin, fDiJetZMax); | |
2560 | } | |
2561 | ||
2562 | if(fDJMode&2){ | |
2563 | fQADiJetHistosRecCuts = new AliFragFuncQADiJetHistos("RecCuts", fDiJetKindBins, | |
2564 | fQADiJetNBinsInvMass, fQADiJetInvMassMin, fQADiJetInvMassMax, | |
2565 | fQADiJetNBinsJetPt, fQADiJetJetPtMin, fQADiJetJetPtMax, | |
2566 | fQADiJetNBinsDeltaPhi, fQADiJetDeltaPhiMin, fQADiJetDeltaPhiMax , | |
2567 | fQADiJetNBinsDeltaEta, fQADiJetDeltaEtaMin, fQADiJetDeltaEtaMax , | |
2568 | fQADiJetNBinsDeltaPt, fQADiJetDeltaPtMin, fQADiJetDeltaPtMax, | |
2569 | fQADiJetNBinsInBal, fQADiJetInBalMin, fQADiJetInBalMax); | |
2570 | fQADiJetHistosGen = new AliFragFuncQADiJetHistos("Gen", fDiJetKindBins, | |
2571 | fQADiJetNBinsInvMass, fQADiJetInvMassMin, fQADiJetInvMassMax, | |
2572 | fDiJetNBinsJetPt, fDiJetJetPtMin, fDiJetJetPtMax, | |
2573 | fQADiJetNBinsDeltaPhi, fQADiJetDeltaPhiMin, fQADiJetDeltaPhiMax, | |
2574 | fQADiJetNBinsDeltaEta, fQADiJetDeltaEtaMin, fQADiJetDeltaEtaMax, | |
2575 | fQADiJetNBinsDeltaPt, fQADiJetDeltaPtMin, fQADiJetDeltaPtMax, | |
2576 | fQADiJetNBinsInBal, fQADiJetInBalMin, fQADiJetInBalMax); | |
2577 | } | |
2578 | } // end: di-jet | |
656dc810 | 2579 | |
cb76764e | 2580 | // efficiency |
2581 | ||
3af23c82 | 2582 | if(fEffMode){ |
2583 | if(fQAMode&1){ | |
2584 | fQATrackHistosRecEffGen = new AliFragFuncQATrackHistos("RecEffGen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2585 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2586 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2587 | fQATrackHighPtThreshold); | |
2588 | ||
2589 | fQATrackHistosRecEffRec = new AliFragFuncQATrackHistos("RecEffRec", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2590 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2591 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2592 | fQATrackHighPtThreshold); | |
cb76764e | 2593 | |
cb76764e | 2594 | |
3af23c82 | 2595 | Int_t nBinsResponseSinglePt[2] = {fFFNBinsPt, fFFNBinsPt}; |
2596 | Double_t binMinResponseSinglePt[2] = {fFFPtMin, fFFPtMin}; | |
2597 | Double_t binMaxResponseSinglePt[2] = {fFFPtMax, fFFPtMax}; | |
2598 | const char* labelsResponseSinglePt[2] = {"rec p_{T} [GeV/c]", "gen p_{T} [GeV/c]"}; | |
2599 | ||
2600 | fhnResponseSinglePt = new THnSparseF("fhnResponseSinglePt","track pt gen : track pt rec",2, | |
2601 | nBinsResponseSinglePt,binMinResponseSinglePt,binMaxResponseSinglePt); | |
2602 | ||
2603 | AliAnalysisTaskFragmentationFunction::SetProperties(fhnResponseSinglePt,2,labelsResponseSinglePt); | |
2604 | } | |
2605 | if(fFFMode){ | |
2606 | fFFHistosRecEffGen = new AliFragFuncHistos("RecEffGen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2607 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2608 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2609 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2610 | ||
2611 | fFFHistosRecEffRec = new AliFragFuncHistos("RecEffRec", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2612 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2613 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2614 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2615 | ||
2616 | ||
2617 | Int_t nBinsResponseJetTrackPt[3] = {fFFNBinsJetPt,fFFNBinsPt,fFFNBinsPt}; | |
2618 | Double_t binMinResponseJetTrackPt[3] = {fFFJetPtMin,fFFPtMin, fFFPtMin}; | |
2619 | Double_t binMaxResponseJetTrackPt[3] = {fFFJetPtMax,fFFPtMax,fFFPtMax}; | |
2620 | const char* labelsResponseJetTrackPt[3] = { "jet p_{T} [GeV/c]","rec p_{T} [GeV/c]", "gen p_{T} [GeV/c]"}; | |
2621 | ||
2622 | fhnResponseJetTrackPt = new THnSparseF("fhnResponseJetTrackPt","jet pt:track pt rec:track pt gen",3, | |
2623 | nBinsResponseJetTrackPt,binMinResponseJetTrackPt,binMaxResponseJetTrackPt); | |
2624 | ||
2625 | AliAnalysisTaskFragmentationFunction::SetProperties(fhnResponseJetTrackPt,3,labelsResponseJetTrackPt); | |
2626 | ||
2627 | Int_t nBinsResponseJetZ[3] = {fFFNBinsJetPt, fFFNBinsZ,fFFNBinsZ}; | |
2628 | Double_t binMinResponseJetZ[3] = {fFFJetPtMin, fFFZMin, fFFZMin}; | |
2629 | Double_t binMaxResponseJetZ[3] = {fFFJetPtMax, fFFZMax, fFFZMax}; | |
2630 | const char* labelsResponseJetZ[3] = { "jet p_{T} [GeV/c]","rec z","gen z"}; | |
2631 | ||
2632 | fhnResponseJetZ = new THnSparseF("fhnResponseJetZ","jet pt:track pt rec:track pt gen",3, | |
2633 | nBinsResponseJetZ,binMinResponseJetZ,binMaxResponseJetZ); | |
2634 | ||
2635 | AliAnalysisTaskFragmentationFunction::SetProperties(fhnResponseJetZ,3,labelsResponseJetZ); | |
2636 | ||
2637 | Int_t nBinsResponseJetXi[3] = {fFFNBinsJetPt, fFFNBinsXi,fFFNBinsXi}; | |
2638 | Double_t binMinResponseJetXi[3] = {fFFJetPtMin, fFFXiMin, fFFXiMin}; | |
2639 | Double_t binMaxResponseJetXi[3] = {fFFJetPtMax, fFFXiMax, fFFXiMax}; | |
2640 | const char* labelsResponseJetXi[3] = { "jet p_{T} [GeV/c]","rec xi","gen xi"}; | |
2641 | ||
2642 | fhnResponseJetXi = new THnSparseF("fhnResponseJetXi","jet pt:track xi rec:track xi gen",3, | |
2643 | nBinsResponseJetXi,binMinResponseJetXi,binMaxResponseJetXi); | |
2644 | ||
2645 | AliAnalysisTaskFragmentationFunction::SetProperties(fhnResponseJetXi,3,labelsResponseJetXi); | |
2646 | ||
2647 | } | |
2648 | } // end: efficiency | |
67e37e80 | 2649 | |
1da9498b | 2650 | // Background |
2651 | if(fBckgMode){ | |
67e37e80 | 2652 | // Track QA |
3170a3f8 | 2653 | TString title[5]; |
2654 | for(Int_t i=0; i<5; i++){ | |
67e37e80 | 2655 | if(fBckgType[i]==kBckgPerp) title[i]="Perp"; |
3af23c82 | 2656 | else if(fBckgType[i]==kBckgPerpWindow) title[i]="PerpW"; |
2657 | else if(fBckgType[i]==kBckgASide) title[i]="ASide"; | |
2658 | else if(fBckgType[i]==kBckgASideWindow) title[i]="ASideW"; | |
67e37e80 | 2659 | else if(fBckgType[i]==kBckgOutLJ) title[i]="OutLeadingJet"; |
2660 | else if(fBckgType[i]==kBckgOut2J) title[i]="Out2Jets"; | |
2661 | else if(fBckgType[i]==kBckgOut3J) title[i]="Out3Jets"; | |
2662 | else if(fBckgType[i]==kBckgOutAJ) title[i]="AllJets"; | |
2663 | else if(fBckgType[i]==kBckgOutLJStat) title[i]="OutLeadingJetStat"; | |
2664 | else if(fBckgType[i]==kBckgOut2JStat) title[i]="Out2JetsStat"; | |
2665 | else if(fBckgType[i]==kBckgOut3JStat) title[i]="Out3JetsStat"; | |
2666 | else if(fBckgType[i]==kBckgOutAJStat) title[i]="AllJetsStat"; | |
742ee86c | 2667 | else if(fBckgType[i]==kBckgClustersOutLeading) title[i]="OutClusters"; |
2668 | else if(fBckgType[i]==kBckgClusters) title[i]="MedianClusters"; | |
67e37e80 | 2669 | else printf("Please chose background method number %d!",i); |
2670 | } | |
2671 | ||
3af23c82 | 2672 | if(fQAMode&1){ |
2673 | fQABckgHisto0RecCuts = new AliFragFuncQATrackHistos("Bckg"+title[0]+"RecCuts", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2674 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2675 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2676 | fQATrackHighPtThreshold); | |
2677 | fQABckgHisto0Gen = new AliFragFuncQATrackHistos("Bckg"+title[0]+"Gen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2678 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2679 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2680 | fQATrackHighPtThreshold); | |
2681 | fQABckgHisto1RecCuts = new AliFragFuncQATrackHistos("Bckg"+title[1]+"RecCuts", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2682 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2683 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2684 | fQATrackHighPtThreshold); | |
2685 | fQABckgHisto1Gen = new AliFragFuncQATrackHistos("Bckg"+title[1]+"Gen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2686 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2687 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2688 | fQATrackHighPtThreshold); | |
2689 | fQABckgHisto2RecCuts = new AliFragFuncQATrackHistos("Bckg"+title[2]+"RecCuts", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2690 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2691 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2692 | fQATrackHighPtThreshold); | |
2693 | fQABckgHisto2Gen = new AliFragFuncQATrackHistos("Bckg"+title[2]+"Gen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2694 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2695 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2696 | fQATrackHighPtThreshold); | |
742ee86c | 2697 | fQABckgHisto3RecCuts = new AliFragFuncQATrackHistos("Bckg"+title[3]+"RecCuts", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, |
2698 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2699 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2700 | fQATrackHighPtThreshold); | |
2701 | fQABckgHisto3Gen = new AliFragFuncQATrackHistos("Bckg"+title[3]+"Gen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2702 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2703 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2704 | fQATrackHighPtThreshold); | |
3170a3f8 | 2705 | fQABckgHisto4RecCuts = new AliFragFuncQATrackHistos("Bckg"+title[4]+"RecCuts", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, |
2706 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2707 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2708 | fQATrackHighPtThreshold); | |
2709 | fQABckgHisto4Gen = new AliFragFuncQATrackHistos("Bckg"+title[4]+"Gen", fQATrackNBinsPt, fQATrackPtMin, fQATrackPtMax, | |
2710 | fQATrackNBinsEta, fQATrackEtaMin, fQATrackEtaMax, | |
2711 | fQATrackNBinsPhi, fQATrackPhiMin, fQATrackPhiMax, | |
2712 | fQATrackHighPtThreshold); | |
2713 | ||
2714 | ||
3af23c82 | 2715 | } // end: background QA |
2716 | ||
2717 | if(fFFMode){ | |
2718 | // outside leading jet or 2 jets or more | |
2719 | fFFBckgHisto0RecCuts = new AliFragFuncHistos("Bckg"+title[0]+"RecCuts", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2720 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2721 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2722 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2723 | fFFBckgHisto0RecLeading = new AliFragFuncHistos("Bckg"+title[0]+"RecLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2724 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2725 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2726 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2727 | fFFBckgHisto0Gen = new AliFragFuncHistos("Bckg"+title[0]+"Gen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2728 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2729 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2730 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2731 | fFFBckgHisto0GenLeading = new AliFragFuncHistos("Bckg"+title[0]+"GenLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2732 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2733 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2734 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2735 | ||
2736 | fFFBckgHisto1RecCuts = new AliFragFuncHistos("Bckg"+title[1]+"RecCuts", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2737 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2738 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2739 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2740 | fFFBckgHisto1RecLeading = new AliFragFuncHistos("Bckg"+title[1]+"RecLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2741 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2742 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2743 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2744 | fFFBckgHisto1Gen = new AliFragFuncHistos("Bckg"+title[1]+"Gen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2745 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2746 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2747 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2748 | fFFBckgHisto1GenLeading = new AliFragFuncHistos("Bckg"+title[1]+"GenLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2749 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2750 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2751 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2752 | ||
2753 | fFFBckgHisto2RecCuts = new AliFragFuncHistos("Bckg"+title[2]+"RecCuts", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2754 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2755 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2756 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2757 | fFFBckgHisto2RecLeading = new AliFragFuncHistos("Bckg"+title[2]+"RecLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2758 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2759 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2760 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2761 | fFFBckgHisto2Gen = new AliFragFuncHistos("Bckg"+title[2]+"Gen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2762 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2763 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2764 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2765 | fFFBckgHisto2GenLeading = new AliFragFuncHistos("Bckg"+title[2]+"GenLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2766 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2767 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2768 | fFFNBinsZ , fFFZMin , fFFZMax); | |
742ee86c | 2769 | fFFBckgHisto3RecCuts = new AliFragFuncHistos("Bckg"+title[3]+"RecCuts", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, |
2770 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2771 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2772 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2773 | fFFBckgHisto3RecLeading = new AliFragFuncHistos("Bckg"+title[3]+"RecLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2774 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2775 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2776 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2777 | fFFBckgHisto3Gen = new AliFragFuncHistos("Bckg"+title[3]+"Gen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2778 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2779 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2780 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2781 | fFFBckgHisto3GenLeading = new AliFragFuncHistos("Bckg"+title[3]+"GenLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2782 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2783 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2784 | fFFNBinsZ , fFFZMin , fFFZMax); | |
3170a3f8 | 2785 | fFFBckgHisto4RecCuts = new AliFragFuncHistos("Bckg"+title[4]+"RecCuts", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, |
2786 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2787 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2788 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2789 | fFFBckgHisto4RecLeading = new AliFragFuncHistos("Bckg"+title[4]+"RecLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2790 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2791 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2792 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2793 | fFFBckgHisto4Gen = new AliFragFuncHistos("Bckg"+title[4]+"Gen", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2794 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2795 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2796 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2797 | fFFBckgHisto4GenLeading = new AliFragFuncHistos("Bckg"+title[4]+"GenLeading", fFFNBinsJetPt, fFFJetPtMin, fFFJetPtMax, | |
2798 | fFFNBinsPt, fFFPtMin, fFFPtMax, | |
2799 | fFFNBinsXi, fFFXiMin, fFFXiMax, | |
2800 | fFFNBinsZ , fFFZMin , fFFZMax); | |
2801 | ||
3af23c82 | 2802 | } // end: background FF |
67e37e80 | 2803 | |
2804 | if(fIJMode){ | |
2805 | fIJBckgHisto0RecCuts = new AliFragFuncIntraJetHistos("Bckg"+title[0]+"RecCuts", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
1da9498b | 2806 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2807 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2808 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2809 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2810 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2811 | fIJBckgHisto0RecLeading = new AliFragFuncIntraJetHistos("Bckg"+title[0]+"RecLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
1da9498b | 2812 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2813 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2814 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2815 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2816 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2817 | fIJBckgHisto0Gen = new AliFragFuncIntraJetHistos("Bckg"+title[0]+"Gen", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
1da9498b | 2818 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2819 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2820 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2821 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2822 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2823 | fIJBckgHisto0GenLeading = new AliFragFuncIntraJetHistos("Bckg"+title[0]+"GenLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
2824 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
1da9498b | 2825 | fIJNBinsZ, fIJZMin, fIJZMax, |
2826 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2827 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2828 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2829 | |
2830 | ||
2831 | fIJBckgHisto1RecCuts = new AliFragFuncIntraJetHistos("Bckg"+title[1]+"RecCuts", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
1da9498b | 2832 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2833 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2834 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2835 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2836 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2837 | fIJBckgHisto1RecLeading = new AliFragFuncIntraJetHistos("Bckg"+title[1]+"RecLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
1da9498b | 2838 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
67e37e80 | 2839 | fIJNBinsZ, fIJZMin, fIJZMax, |
2840 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2841 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2842 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2843 | fIJBckgHisto1Gen = new AliFragFuncIntraJetHistos("Bckg"+title[1]+"Gen", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
1da9498b | 2844 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2845 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2846 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2847 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2848 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2849 | fIJBckgHisto1GenLeading = new AliFragFuncIntraJetHistos("Bckg"+title[1]+"GenLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
2850 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2851 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2852 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2853 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2854 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2855 | ||
2856 | fIJBckgHisto2RecCuts = new AliFragFuncIntraJetHistos("Bckg"+title[2]+"RecCuts", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
1da9498b | 2857 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2858 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2859 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2860 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2861 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2862 | fIJBckgHisto2RecLeading = new AliFragFuncIntraJetHistos("Bckg"+title[2]+"RecLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
1da9498b | 2863 | fIJNBinsPt, fIJPtMin, fIJPtMax, |
2864 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2865 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2866 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2867 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
67e37e80 | 2868 | fIJBckgHisto2Gen = new AliFragFuncIntraJetHistos("Bckg"+title[2]+"Gen", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, |
2869 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2870 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2871 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2872 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2873 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
2874 | fIJBckgHisto2GenLeading = new AliFragFuncIntraJetHistos("Bckg"+title[2]+"GenLeading", fIJNBinsJetPt, fIJJetPtMin, fIJJetPtMax, | |
2875 | fIJNBinsPt, fIJPtMin, fIJPtMax, | |
2876 | fIJNBinsZ, fIJZMin, fIJZMax, | |
2877 | fIJNBinsCosTheta , fIJCosThetaMin , fIJCosThetaMax, | |
2878 | fIJNBinsTheta , fIJThetaMin , fIJThetaMax, | |
2879 | fIJNBinsJt , fIJJtMin , fIJJtMax); | |
3af23c82 | 2880 | } // end: background intra-jet |
2881 | } // end: background | |
2882 | ||
2883 | if(fPhiCorrMode){ | |
2884 | fPhiCorrHistosJetArea = new AliFragFuncQATrackHistos("JetArea", fPhiCorrNBinsPt, fPhiCorrPtMin, fPhiCorrPtMax, | |
2885 | fPhiCorrNBinsEta, fPhiCorrEtaMin, fPhiCorrEtaMax, | |
2886 | fPhiCorrNBinsPhi, fPhiCorrPhiMin, fPhiCorrPhiMax, | |
2887 | fQATrackHighPtThreshold); | |
2888 | ||
2889 | fPhiCorrHistosTransverseArea = new AliFragFuncQATrackHistos("TransverseArea", fPhiCorrNBinsPt, fPhiCorrPtMin, fPhiCorrPtMax, | |
2890 | fPhiCorrNBinsEta, fPhiCorrEtaMin, fPhiCorrEtaMax, | |
2891 | fPhiCorrNBinsPhi, fPhiCorrPhiMin, fPhiCorrPhiMax, | |
2892 | fQATrackHighPtThreshold); | |
2893 | ||
2894 | fPhiCorrHistosAwayArea = new AliFragFuncQATrackHistos("AwayArea", fPhiCorrNBinsPt, fPhiCorrPtMin, fPhiCorrPtMax, | |
2895 | fPhiCorrNBinsEta, fPhiCorrEtaMin, fPhiCorrEtaMax, | |
2896 | fPhiCorrNBinsPhi, fPhiCorrPhiMin, fPhiCorrPhiMax, | |
2897 | fQATrackHighPtThreshold); | |
2898 | } // end: phi correlation | |
656dc810 | 2899 | |
3af23c82 | 2900 | |
2901 | // ____________ define histograms ____________________ | |
2902 | ||
2903 | if(fQAMode){ | |
2904 | if(fQAMode&1){ // track QA | |
2905 | fQATrackHistosRec->DefineHistos(); | |
2906 | fQATrackHistosRecCuts->DefineHistos(); | |
2907 | fQATrackHistosGen->DefineHistos(); | |
2908 | } | |
656dc810 | 2909 | |
3af23c82 | 2910 | if(fQAMode&2){ // jet QA |
2911 | fQAJetHistosRec->DefineHistos(); | |
2912 | fQAJetHistosRecCuts->DefineHistos(); | |
2913 | fQAJetHistosRecCutsLeading->DefineHistos(); | |
2914 | fQAJetHistosGen->DefineHistos(); | |
2915 | fQAJetHistosGenLeading->DefineHistos(); | |
2916 | if(fEffMode) fQAJetHistosRecEffLeading->DefineHistos(); | |
2917 | } | |
2918 | } | |
656dc810 | 2919 | |
3af23c82 | 2920 | if(fFFMode){ |
2921 | fFFHistosRecCuts->DefineHistos(); | |
2922 | fFFHistosRecLeading->DefineHistos(); | |
2923 | fFFHistosRecLeadingTrack->DefineHistos(); | |
2924 | fFFHistosGen->DefineHistos(); | |
2925 | fFFHistosGenLeading->DefineHistos(); | |
2926 | fFFHistosGenLeadingTrack->DefineHistos(); | |
2927 | } | |
656dc810 | 2928 | |
67e37e80 | 2929 | if(fIJMode){ |
2930 | fIJHistosRecCuts->DefineHistos(); | |
2931 | fIJHistosRecLeading->DefineHistos(); | |
2932 | fIJHistosRecLeadingTrack->DefineHistos(); | |
2933 | fIJHistosGen->DefineHistos(); | |
2934 | fIJHistosGenLeading->DefineHistos(); | |
2935 | fIJHistosGenLeadingTrack->DefineHistos(); | |
2936 | } | |
2937 | ||
3af23c82 | 2938 | if(fDJMode){ |
2939 | if(fDJMode&1){ | |
2940 | fFFDiJetHistosRecCuts->DefineDiJetHistos(); | |
2941 | fFFDiJetHistosRecLeading->DefineDiJetHistos(); | |
2942 | fFFDiJetHistosRecLeadingTrack->DefineDiJetHistos(); | |
2943 | fFFDiJetHistosGen->DefineDiJetHistos(); | |
2944 | fFFDiJetHistosGenLeading->DefineDiJetHistos(); | |
2945 | fFFDiJetHistosGenLeadingTrack->DefineDiJetHistos(); | |
2946 | } | |
2947 | ||
2948 | if(fDJMode&2){ | |
2949 | fQADiJetHistosRecCuts->DefineQADiJetHistos(); | |
2950 | fQADiJetHistosGen->DefineQADiJetHistos(); | |
2951 | } | |
2952 | } // end: di-jet | |
656dc810 | 2953 | |
3af23c82 | 2954 | if(fEffMode){ |
2955 | if(fQAMode&1){ | |
2956 | fQATrackHistosRecEffGen->DefineHistos(); | |
2957 | fQATrackHistosRecEffRec->DefineHistos(); | |
2958 | } | |
2959 | if(fFFMode){ | |
2960 | fFFHistosRecEffGen->DefineHistos(); | |
2961 | fFFHistosRecEffRec->DefineHistos(); | |
2962 | } | |
2963 | } // end: efficiency | |
cb76764e | 2964 | |
1da9498b | 2965 | // Background |
2966 | if(fBckgMode){ | |
3af23c82 | 2967 | if(fFFMode){ |
2968 | fFFBckgHisto0RecCuts->DefineHistos(); | |
2969 | fFFBckgHisto0RecLeading->DefineHistos(); | |
2970 | fFFBckgHisto0Gen->DefineHistos(); | |
2971 | fFFBckgHisto0GenLeading->DefineHistos(); | |
2972 | fFFBckgHisto1RecCuts->DefineHistos(); | |
2973 | fFFBckgHisto1RecLeading->DefineHistos(); | |
2974 | fFFBckgHisto1Gen->DefineHistos(); | |
2975 | fFFBckgHisto1GenLeading->DefineHistos(); | |
2976 | fFFBckgHisto2RecCuts->DefineHistos(); | |
2977 | fFFBckgHisto2RecLeading->DefineHistos(); | |
2978 | fFFBckgHisto2Gen->DefineHistos(); | |
2979 | fFFBckgHisto2GenLeading->DefineHistos(); | |
742ee86c | 2980 | fFFBckgHisto3RecCuts->DefineHistos(); |
2981 | fFFBckgHisto3RecLeading->DefineHistos(); | |
2982 | fFFBckgHisto3Gen->DefineHistos(); | |
2983 | fFFBckgHisto3GenLeading->DefineHistos(); | |
3170a3f8 | 2984 | fFFBckgHisto4RecCuts->DefineHistos(); |
2985 | fFFBckgHisto4RecLeading->DefineHistos(); | |
2986 | fFFBckgHisto4Gen->DefineHistos(); | |
2987 | fFFBckgHisto4GenLeading->DefineHistos(); | |
3af23c82 | 2988 | } |
2989 | ||
67e37e80 | 2990 | if(fIJMode){ |
2991 | fIJBckgHisto0RecCuts->DefineHistos(); | |
2992 | fIJBckgHisto0RecLeading->DefineHistos(); | |
2993 | fIJBckgHisto0Gen->DefineHistos(); | |
2994 | fIJBckgHisto0GenLeading->DefineHistos(); | |
2995 | fIJBckgHisto1RecCuts->DefineHistos(); | |
2996 | fIJBckgHisto1RecLeading->DefineHistos(); | |
2997 | fIJBckgHisto1Gen->DefineHistos(); | |
2998 | fIJBckgHisto1GenLeading->DefineHistos(); | |
2999 | fIJBckgHisto2RecCuts->DefineHistos(); | |
3000 | fIJBckgHisto2RecLeading->DefineHistos(); | |
3001 | fIJBckgHisto2Gen->DefineHistos(); | |
3002 | fIJBckgHisto2GenLeading->DefineHistos(); | |
3003 | } | |
3004 | ||
3af23c82 | 3005 | if(fQAMode&1){ |
3006 | fQABckgHisto0RecCuts->DefineHistos(); | |
3007 | fQABckgHisto0Gen->DefineHistos(); | |
3008 | fQABckgHisto1RecCuts->DefineHistos(); | |
3009 | fQABckgHisto1Gen->DefineHistos(); | |
3010 | fQABckgHisto2RecCuts->DefineHistos(); | |
3011 | fQABckgHisto2Gen->DefineHistos(); | |
742ee86c | 3012 | fQABckgHisto3RecCuts->DefineHistos(); |
3013 | fQABckgHisto3Gen->DefineHistos(); | |
3170a3f8 | 3014 | fQABckgHisto4RecCuts->DefineHistos(); |
3015 | fQABckgHisto4Gen->DefineHistos(); | |
3af23c82 | 3016 | } |
3017 | } // end: background | |
1da9498b | 3018 | |
3af23c82 | 3019 | if(fPhiCorrMode){ |
3020 | fPhiCorrHistosJetArea->DefineHistos(); | |
3021 | fPhiCorrHistosTransverseArea->DefineHistos(); | |
3022 | fPhiCorrHistosAwayArea->DefineHistos(); | |
3023 | } | |
3024 | ||
fb03edbe | 3025 | Bool_t genJets = (fJetTypeGen != kJetsUndef) ? kTRUE : kFALSE; |
3026 | Bool_t genTracks = (fTrackTypeGen != kTrackUndef) ? kTRUE : kFALSE; | |
3027 | Bool_t recJetsEff = (fJetTypeRecEff != kJetsUndef) ? kTRUE : kFALSE; | |
3028 | ||
3af23c82 | 3029 | fCommonHistList->Add(fh1EvtSelection); |
3030 | fCommonHistList->Add(fh1EvtMult); | |
3031 | fCommonHistList->Add(fh1EvtCent); | |
3170a3f8 | 3032 | fCommonHistList->Add(fh2TrackPtVsDCAXY); |
3033 | fCommonHistList->Add(fh2TrackPtVsDCAZ); | |
3af23c82 | 3034 | fCommonHistList->Add(fh1VertexNContributors); |
3035 | fCommonHistList->Add(fh1VertexZ); | |
3036 | fCommonHistList->Add(fh1nRecJetsCuts); | |
3037 | if(genJets && genTracks){ | |
3038 | fCommonHistList->Add(fh1Xsec); | |
3039 | fCommonHistList->Add(fh1Trials); | |
3040 | fCommonHistList->Add(fh1PtHard); | |
3041 | fCommonHistList->Add(fh1PtHardTrials); | |
3042 | if(genJets) fCommonHistList->Add(fh1nGenJets); | |
3043 | } | |
fb03edbe | 3044 | |
3af23c82 | 3045 | // FF histograms |
3046 | if(fFFMode){ | |
656dc810 | 3047 | fFFHistosRecCuts->AddToOutput(fCommonHistList); |
3048 | fFFHistosRecLeading->AddToOutput(fCommonHistList); | |
3049 | fFFHistosRecLeadingTrack->AddToOutput(fCommonHistList); | |
3af23c82 | 3050 | if(genJets && genTracks){ |
3051 | fCommonHistList->Add(fh1Xsec); | |
3052 | fCommonHistList->Add(fh1Trials); | |
3053 | fCommonHistList->Add(fh1PtHard); | |
3054 | fCommonHistList->Add(fh1PtHardTrials); | |
3055 | if(genJets) fCommonHistList->Add(fh1nGenJets); | |
3056 | ||
3057 | fFFHistosGen->AddToOutput(fCommonHistList); | |
3058 | fFFHistosGenLeading->AddToOutput(fCommonHistList); | |
3059 | fFFHistosGenLeadingTrack->AddToOutput(fCommonHistList); | |
3060 | } | |
3061 | } | |
fb03edbe | 3062 | |
3af23c82 | 3063 | // Background |
3064 | if(fBckgMode){ | |
3065 | if(fFFMode){ | |
67e37e80 | 3066 | fFFBckgHisto0RecCuts->AddToOutput(fCommonHistList); |
3067 | fFFBckgHisto0RecLeading->AddToOutput(fCommonHistList); | |
3068 | fFFBckgHisto1RecCuts->AddToOutput(fCommonHistList); | |
3069 | fFFBckgHisto1RecLeading->AddToOutput(fCommonHistList); | |
3070 | fFFBckgHisto2RecCuts->AddToOutput(fCommonHistList); | |
3071 | fFFBckgHisto2RecLeading->AddToOutput(fCommonHistList); | |
742ee86c | 3072 | fFFBckgHisto3RecCuts->AddToOutput(fCommonHistList); |
3073 | fFFBckgHisto3RecLeading->AddToOutput(fCommonHistList); | |
3170a3f8 | 3074 | fFFBckgHisto4RecCuts->AddToOutput(fCommonHistList); |
3075 | fFFBckgHisto4RecLeading->AddToOutput(fCommonHistList); | |
3076 | ||
3af23c82 | 3077 | if(genJets && genTracks){ |
3078 | fFFBckgHisto0Gen->AddToOutput(fCommonHistList); | |
3079 | fFFBckgHisto0GenLeading->AddToOutput(fCommonHistList); | |
3080 | fFFBckgHisto1Gen->AddToOutput(fCommonHistList); | |
3081 | fFFBckgHisto1GenLeading->AddToOutput(fCommonHistList); | |
3082 | fFFBckgHisto2Gen->AddToOutput(fCommonHistList); | |
3083 | fFFBckgHisto2GenLeading->AddToOutput(fCommonHistList); | |
742ee86c | 3084 | fFFBckgHisto3Gen->AddToOutput(fCommonHistList); |
3085 | fFFBckgHisto3GenLeading->AddToOutput(fCommonHistList); | |
3170a3f8 | 3086 | fFFBckgHisto4Gen->AddToOutput(fCommonHistList); |
3087 | fFFBckgHisto4GenLeading->AddToOutput(fCommonHistList); | |
3af23c82 | 3088 | } |
3089 | } | |
3090 | ||
3091 | if(fQAMode&1){ | |
67e37e80 | 3092 | fQABckgHisto0RecCuts->AddToOutput(fCommonHistList); |
3093 | fQABckgHisto1RecCuts->AddToOutput(fCommonHistList); | |
3094 | fQABckgHisto2RecCuts->AddToOutput(fCommonHistList); | |
742ee86c | 3095 | fQABckgHisto3RecCuts->AddToOutput(fCommonHistList); |
3170a3f8 | 3096 | fQABckgHisto4RecCuts->AddToOutput(fCommonHistList); |
3af23c82 | 3097 | if(genJets && genTracks){ |
3098 | fQABckgHisto0Gen->AddToOutput(fCommonHistList); | |
3099 | fQABckgHisto1Gen->AddToOutput(fCommonHistList); | |
3100 | fQABckgHisto2Gen->AddToOutput(fCommonHistList); | |
742ee86c | 3101 | fQABckgHisto3Gen->AddToOutput(fCommonHistList); |
3170a3f8 | 3102 | fQABckgHisto4Gen->AddToOutput(fCommonHistList); |
3af23c82 | 3103 | } |
1da9498b | 3104 | } |
3105 | ||
3170a3f8 | 3106 | if(fBckgType[0]==kBckgOutLJ || fBckgType[1]==kBckgOutLJ || fBckgType[2]==kBckgOutLJ || fBckgType[3]==kBckgOutLJ || fBckgType[4]==kBckgOutLJ) |
3af23c82 | 3107 | fCommonHistList->Add(fh1OutLeadingMult); |
3170a3f8 | 3108 | if(fBckgType[0]==kBckgOutLJStat || fBckgType[1]==kBckgOutLJStat || fBckgType[2]==kBckgOutLJStat || fBckgType[3]==kBckgOutLJStat || fBckgType[4]==kBckgOutLJStat) |
742ee86c | 3109 | fCommonHistList->Add(fh1OutLeadingStatMult); |
3170a3f8 | 3110 | if(fBckgType[0]==kBckgPerp || fBckgType[1]==kBckgPerp || fBckgType[2]==kBckgPerp || fBckgType[3]==kBckgPerp || fBckgType[4]==kBckgPerp) |
3af23c82 | 3111 | fCommonHistList->Add(fh1PerpMult); |
3170a3f8 | 3112 | if(fBckgType[0]==kBckgASide || fBckgType[1]==kBckgASide || fBckgType[2]==kBckgASide || fBckgType[3]==kBckgASide || fBckgType[4]==kBckgASide) |
3af23c82 | 3113 | fCommonHistList->Add(fh1ASideMult); |
3170a3f8 | 3114 | if(fBckgType[0]==kBckgASideWindow || fBckgType[1]==kBckgASideWindow || fBckgType[2]==kBckgASideWindow || fBckgType[3]==kBckgASideWindow || fBckgType[4]==kBckgASideWindow) |
3af23c82 | 3115 | fCommonHistList->Add(fh1ASideWindowMult); |
3170a3f8 | 3116 | if(fBckgType[0]==kBckgPerpWindow || fBckgType[1]==kBckgPerpWindow || fBckgType[2]==kBckgPerpWindow || fBckgType[3]==kBckgPerpWindow || fBckgType[4]==kBckgPerpWindow) |
3af23c82 | 3117 | fCommonHistList->Add(fh1PerpWindowMult); |
3170a3f8 | 3118 | if(fBckgType[0]==kBckgOut2J || fBckgType[1]==kBckgOut2J || fBckgType[2]==kBckgOut2J || fBckgType[3]==kBckgOut2J || fBckgType[4]==kBckgOut2J) |
3af23c82 | 3119 | fCommonHistList->Add(fh1Out2JetsMult); |
3170a3f8 | 3120 | if(fBckgType[0]==kBckgOut3J || fBckgType[1]==kBckgOut3J || fBckgType[2]==kBckgOut3J || fBckgType[3]==kBckgOut3J || fBckgType[4]==kBckgOut3J) |
3af23c82 | 3121 | fCommonHistList->Add(fh1Out3JetsMult); |
3170a3f8 | 3122 | if(fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters) |
742ee86c | 3123 | fCommonHistList->Add(fh1MedianClustersMult); |
3170a3f8 | 3124 | if(fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading |
3125 | || fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading) | |
742ee86c | 3126 | fCommonHistList->Add(fh1OutClustersMult); |
656dc810 | 3127 | } |
3af23c82 | 3128 | |
3129 | // QA | |
3130 | if(fQAMode){ | |
3131 | if(fQAMode&1){ // track QA | |
3132 | fQATrackHistosRec->AddToOutput(fCommonHistList); | |
3133 | fQATrackHistosRecCuts->AddToOutput(fCommonHistList); | |
3134 | if(genTracks) fQATrackHistosGen->AddToOutput(fCommonHistList); | |
fb03edbe | 3135 | } |
fe343c6b | 3136 | |
3af23c82 | 3137 | if(fQAMode&2){ // jet QA |
3138 | fQAJetHistosRec->AddToOutput(fCommonHistList); | |
3139 | fQAJetHistosRecCuts->AddToOutput(fCommonHistList); | |
3140 | fQAJetHistosRecCutsLeading->AddToOutput(fCommonHistList); | |
3141 | if(recJetsEff && fEffMode) fQAJetHistosRecEffLeading->AddToOutput(fCommonHistList); | |
3142 | if(genJets){ | |
3143 | fQAJetHistosGen->AddToOutput(fCommonHistList); | |
3144 | fQAJetHistosGenLeading->AddToOutput(fCommonHistList); | |
3145 | } | |
67e37e80 | 3146 | } |
656dc810 | 3147 | } |
3af23c82 | 3148 | |
742ee86c | 3149 | if(fBckgMode && |
3170a3f8 | 3150 | (fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters || |
3151 | fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || | |
3152 | fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading)) { | |
3af23c82 | 3153 | fCommonHistList->Add(fh1nRecBckgJetsCuts); |
3154 | if(genJets) fCommonHistList->Add(fh1nGenBckgJets); | |
656dc810 | 3155 | } |
3af23c82 | 3156 | |
3157 | // phi correlation | |
3158 | if(fPhiCorrMode){ | |
742ee86c | 3159 | fPhiCorrHistosJetArea->AddToOutput(fCommonHistList); |
3160 | fPhiCorrHistosTransverseArea->AddToOutput(fCommonHistList); | |
3161 | fPhiCorrHistosAwayArea->AddToOutput(fCommonHistList); | |
3af23c82 | 3162 | } |
3163 | ||
3164 | // intra-jet | |
3165 | if(fIJMode){ | |
3166 | fIJHistosRecCuts->AddToOutput(fCommonHistList); | |
3167 | fIJHistosRecLeading->AddToOutput(fCommonHistList); | |
3168 | fIJHistosRecLeadingTrack->AddToOutput(fCommonHistList); | |
3169 | ||
3170 | // Background | |
3171 | if(fBckgMode){ | |
3172 | fIJBckgHisto0RecCuts->AddToOutput(fCommonHistList); | |
3173 | fIJBckgHisto0RecLeading->AddToOutput(fCommonHistList); | |
3174 | fIJBckgHisto1RecCuts->AddToOutput(fCommonHistList); | |
3175 | fIJBckgHisto1RecLeading->AddToOutput(fCommonHistList); | |
3176 | fIJBckgHisto2RecCuts->AddToOutput(fCommonHistList); | |
3177 | fIJBckgHisto2RecLeading->AddToOutput(fCommonHistList); | |
3178 | } | |
3179 | ||
3180 | if(genJets && genTracks){ | |
3181 | fIJHistosGen->AddToOutput(fCommonHistList); | |
3182 | fIJHistosGenLeading->AddToOutput(fCommonHistList); | |
3183 | fIJHistosGenLeadingTrack->AddToOutput(fCommonHistList); | |
1da9498b | 3184 | |
67e37e80 | 3185 | // Background |
3186 | if(fBckgMode){ | |
3af23c82 | 3187 | fIJBckgHisto0Gen->AddToOutput(fCommonHistList); |
3188 | fIJBckgHisto0GenLeading->AddToOutput(fCommonHistList); | |
3189 | fIJBckgHisto1Gen->AddToOutput(fCommonHistList); | |
3190 | fIJBckgHisto1GenLeading->AddToOutput(fCommonHistList); | |
3191 | fIJBckgHisto2Gen->AddToOutput(fCommonHistList); | |
3192 | fIJBckgHisto2GenLeading->AddToOutput(fCommonHistList); | |
67e37e80 | 3193 | } |
3af23c82 | 3194 | } // end: gen |
3195 | } // end: intra-jet | |
3196 | ||
3197 | if(fDJMode){ | |
3198 | if(fDJMode&1){ | |
3199 | fFFDiJetHistosRecCuts->AddToOutput(fCommonHistList); | |
3200 | fFFDiJetHistosRecLeading->AddToOutput(fCommonHistList); | |
3201 | fFFDiJetHistosRecLeadingTrack->AddToOutput(fCommonHistList); | |
67e37e80 | 3202 | if(genJets && genTracks){ |
3af23c82 | 3203 | fFFDiJetHistosGen->AddToOutput(fCommonHistList); |
fb03edbe | 3204 | fFFDiJetHistosGenLeading->AddToOutput(fCommonHistList); |
3205 | fFFDiJetHistosGenLeadingTrack->AddToOutput(fCommonHistList); | |
3af23c82 | 3206 | } |
3207 | } // end: di-jet | |
3208 | if(fDJMode&2){ | |
3209 | fQADiJetHistosRecCuts->AddToOutput(fCommonHistList); | |
3210 | if(genJets && genTracks){ | |
3211 | fQADiJetHistosGen->AddToOutput(fCommonHistList); | |
3212 | } | |
3213 | } // end: di-jet QA | |
3214 | } // end: di-jet | |
3215 | ||
3216 | if(fEffMode && recJetsEff && genTracks){ | |
3217 | if(fQAMode&1){ | |
cb76764e | 3218 | fQATrackHistosRecEffGen->AddToOutput(fCommonHistList); |
3219 | fQATrackHistosRecEffRec->AddToOutput(fCommonHistList); | |
3af23c82 | 3220 | fCommonHistList->Add(fhnResponseSinglePt); |
3221 | } | |
3222 | if(fFFMode){ | |
cb76764e | 3223 | fFFHistosRecEffGen->AddToOutput(fCommonHistList); |
3224 | fFFHistosRecEffRec->AddToOutput(fCommonHistList); | |
3af23c82 | 3225 | fCommonHistList->Add(fhnResponseJetTrackPt); |
3226 | fCommonHistList->Add(fhnResponseJetZ); | |
3227 | fCommonHistList->Add(fhnResponseJetXi); | |
fb03edbe | 3228 | } |
3af23c82 | 3229 | fCommonHistList->Add(fh1nRecEffJets); |
3230 | fCommonHistList->Add(fh2PtRecVsGenPrim); | |
656dc810 | 3231 | } |
3af23c82 | 3232 | |
656dc810 | 3233 | |
3234 | // =========== Switch on Sumw2 for all histos =========== | |
3235 | for (Int_t i=0; i<fCommonHistList->GetEntries(); ++i){ | |
3236 | TH1 *h1 = dynamic_cast<TH1*>(fCommonHistList->At(i)); | |
3237 | if (h1) h1->Sumw2(); | |
3af23c82 | 3238 | else{ |
3239 | THnSparse *hnSparse = dynamic_cast<THnSparse*>(fCommonHistList->At(i)); | |
3240 | if(hnSparse) hnSparse->Sumw2(); | |
3241 | } | |
656dc810 | 3242 | } |
3243 | ||
3244 | TH1::AddDirectory(oldStatus); | |
3245 | } | |
3246 | ||
3247 | //_______________________________________________ | |
3248 | void AliAnalysisTaskFragmentationFunction::Init() | |
3249 | { | |
3250 | // Initialization | |
3251 | if(fDebug > 1) Printf("AliAnalysisTaskFragmentationFunction::Init()"); | |
3252 | ||
3253 | } | |
3254 | ||
3255 | //_____________________________________________________________ | |
3256 | void AliAnalysisTaskFragmentationFunction::UserExec(Option_t *) | |
3257 | { | |
3258 | // Main loop | |
3259 | // Called for each event | |
3260 | if(fDebug > 1) Printf("AliAnalysisTaskFragmentationFunction::UserExec()"); | |
3261 | ||
3262 | ||
3263 | if(fDebug > 1) Printf("Analysis event #%5d", (Int_t) fEntry); | |
3264 | // Trigger selection | |
67e37e80 | 3265 | |
656dc810 | 3266 | AliInputEventHandler* inputHandler = (AliInputEventHandler*) |
3267 | ((AliAnalysisManager::GetAnalysisManager())->GetInputEventHandler()); | |
3af23c82 | 3268 | if(!(inputHandler->IsEventSelected() & AliVEvent::kMB)){ |
ac017ff3 | 3269 | if(inputHandler->InheritsFrom("AliESDInputHandler") && fUsePhysicsSelection){ // PhysicsSelection only with ESD input |
3af23c82 | 3270 | fh1EvtSelection->Fill(1.); |
656dc810 | 3271 | if (fDebug > 1 ) Printf(" Trigger Selection: event REJECTED ... "); |
3272 | PostData(1, fCommonHistList); | |
3273 | return; | |
3274 | } | |
3275 | } | |
1da9498b | 3276 | |
656dc810 | 3277 | fESD = dynamic_cast<AliESDEvent*>(InputEvent()); |
3278 | if(!fESD){ | |
3279 | if(fDebug>3) Printf("%s:%d ESDEvent not found in the input", (char*)__FILE__,__LINE__); | |
3280 | } | |
3281 | ||
3282 | fMCEvent = MCEvent(); | |
3283 | if(!fMCEvent){ | |
3284 | if(fDebug>3) Printf("%s:%d MCEvent not found in the input", (char*)__FILE__,__LINE__); | |
3285 | } | |
3286 | ||
3287 | // get AOD event from input/ouput | |
3288 | TObject* handler = AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler(); | |
3289 | if( handler && handler->InheritsFrom("AliAODInputHandler") ) { | |
3290 | fAOD = ((AliAODInputHandler*)handler)->GetEvent(); | |
3291 | if (fDebug > 1) Printf("%s:%d AOD event from input", (char*)__FILE__,__LINE__); | |
3292 | } | |
3293 | else { | |
3294 | handler = AliAnalysisManager::GetAnalysisManager()->GetOutputEventHandler(); | |
3295 | if( handler && handler->InheritsFrom("AliAODHandler") ) { | |
3296 | fAOD = ((AliAODHandler*)handler)->GetAOD(); | |
3297 | if (fDebug > 1) Printf("%s:%d AOD event from output", (char*)__FILE__,__LINE__); | |
3298 | } | |
3299 | } | |
3300 | ||
40445651 | 3301 | if(fNonStdFile.Length()!=0){ |
3302 | // case we have an AOD extension - fetch the jets from the extended output | |
3303 | ||
3304 | AliAODHandler *aodH = dynamic_cast<AliAODHandler*>(AliAnalysisManager::GetAnalysisManager()->GetOutputEventHandler()); | |
3305 | fAODExtension = (aodH?aodH->GetExtension(fNonStdFile.Data()):0); | |
3306 | if(!fAODExtension){ | |
3307 | if(fDebug>1)Printf("AODExtension not found for %s",fNonStdFile.Data()); | |
3308 | } | |
3309 | } | |
3310 | ||
656dc810 | 3311 | if(!fAOD){ |
3312 | Printf("%s:%d AODEvent not found", (char*)__FILE__,__LINE__); | |
3313 | return; | |
3314 | } | |
3315 | ||
3af23c82 | 3316 | // event selection ************************************************** |
3317 | // *** event class *** | |
3318 | Double_t centPercent = -1; | |
3319 | if(fEventClass>0){ | |
3320 | Int_t cl = 0; | |
3321 | if(handler->InheritsFrom("AliAODInputHandler")){ | |
3322 | // since it is not supported by the helper task define own classes | |
3323 | centPercent = fAOD->GetHeader()->GetCentrality(); | |
3324 | cl = 1; | |
3325 | if(centPercent>10) cl = 2; | |
3326 | if(centPercent>30) cl = 3; | |
3327 | if(centPercent>50) cl = 4; | |
3328 | } | |
3329 | else { | |
3330 | cl = AliAnalysisHelperJetTasks::EventClass(); | |
3331 | } | |
3332 | ||
3333 | if(cl!=fEventClass){ | |
3334 | // event not in selected event class, reject event | |
3335 | if (fDebug > 1) Printf("%s:%d event not in selected event class: event REJECTED ...",(char*)__FILE__,__LINE__); | |
3336 | fh1EvtSelection->Fill(2.); | |
3337 | PostData(1, fCommonHistList); | |
3338 | return; | |
3339 | } | |
3340 | } | |
44b235ce | 3341 | |
3af23c82 | 3342 | // *** vertex cut *** |
656dc810 | 3343 | AliAODVertex* primVtx = fAOD->GetPrimaryVertex(); |
3344 | Int_t nTracksPrim = primVtx->GetNContributors(); | |
3345 | fh1VertexNContributors->Fill(nTracksPrim); | |
3346 | ||
3347 | if (fDebug > 1) Printf("%s:%d primary vertex selection: %d", (char*)__FILE__,__LINE__,nTracksPrim); | |
3348 | if(!nTracksPrim){ | |
3349 | if (fDebug > 1) Printf("%s:%d primary vertex selection: event REJECTED...",(char*)__FILE__,__LINE__); | |
3af23c82 | 3350 | fh1EvtSelection->Fill(3.); |
656dc810 | 3351 | PostData(1, fCommonHistList); |
3352 | return; | |
3353 | } | |
3af23c82 | 3354 | |
656dc810 | 3355 | fh1VertexZ->Fill(primVtx->GetZ()); |
3356 | ||
3af23c82 | 3357 | if(TMath::Abs(primVtx->GetZ())>fMaxVertexZ){ |
656dc810 | 3358 | if (fDebug > 1) Printf("%s:%d primary vertex z = %f: event REJECTED...",(char*)__FILE__,__LINE__,primVtx->GetZ()); |
3af23c82 | 3359 | fh1EvtSelection->Fill(4.); |
656dc810 | 3360 | PostData(1, fCommonHistList); |
3361 | return; | |
3362 | } | |
3af23c82 | 3363 | |
656dc810 | 3364 | TString primVtxName(primVtx->GetName()); |
3365 | ||
3366 | if(primVtxName.CompareTo("TPCVertex",TString::kIgnoreCase) == 1){ | |
3367 | if (fDebug > 1) Printf("%s:%d primary vertex selection: TPC vertex, event REJECTED...",(char*)__FILE__,__LINE__); | |
3af23c82 | 3368 | fh1EvtSelection->Fill(5.); |
656dc810 | 3369 | PostData(1, fCommonHistList); |
3370 | return; | |
3371 | } | |
3af23c82 | 3372 | |
3373 | if (fDebug > 1) Printf("%s:%d event ACCEPTED ...",(char*)__FILE__,__LINE__); | |
3374 | fh1EvtSelection->Fill(0.); | |
3375 | fh1EvtCent->Fill(centPercent); | |
ac017ff3 | 3376 | |
3377 | ||
3378 | //___ get MC information __________________________________________________________________ | |
3379 | ||
3380 | Double_t ptHard = 0.; | |
3381 | Double_t nTrials = 1; // trials for MC trigger weight for real data | |
3e1c1eee | 3382 | |
3383 | if(fMCEvent){ | |
5fde4a38 | 3384 | AliGenEventHeader* genHeader = fMCEvent->GenEventHeader(); |
cb883243 | 3385 | if(genHeader){ |
5fde4a38 | 3386 | AliGenPythiaEventHeader* pythiaGenHeader = dynamic_cast<AliGenPythiaEventHeader*>(genHeader); |
3387 | AliGenHijingEventHeader* hijingGenHeader = 0x0; | |
3388 | ||
3389 | if(pythiaGenHeader){ | |
3390 | if(fDebug>3) Printf("%s:%d pythiaGenHeader found", (char*)__FILE__,__LINE__); | |
3391 | nTrials = pythiaGenHeader->Trials(); | |
3392 | ptHard = pythiaGenHeader->GetPtHard(); | |
3393 | ||
3394 | fh1PtHard->Fill(ptHard); | |
3395 | fh1PtHardTrials->Fill(ptHard,nTrials); | |
3396 | ||
ac017ff3 | 3397 | |
5fde4a38 | 3398 | } else { // no pythia, hijing? |
c2658535 | 3399 | |
5fde4a38 | 3400 | if(fDebug>3) Printf("%s:%d no pythiaGenHeader found", (char*)__FILE__,__LINE__); |
3401 | ||
3402 | hijingGenHeader = dynamic_cast<AliGenHijingEventHeader*>(genHeader); | |
3403 | if(!hijingGenHeader){ | |
3404 | Printf("%s:%d no pythiaGenHeader or hjingGenHeader found", (char*)__FILE__,__LINE__); | |
3405 | } else { | |
3406 | if(fDebug>3) Printf("%s:%d hijingGenHeader found", (char*)__FILE__,__LINE__); | |
3407 | } | |
3e1c1eee | 3408 | } |
5fde4a38 | 3409 | |
3410 | fh1Trials->Fill("#sum{ntrials}",fAvgTrials); | |
cb883243 | 3411 | } |
5fde4a38 | 3412 | } |
656dc810 | 3413 | |
656dc810 | 3414 | //___ fetch jets __________________________________________________________________________ |
44b235ce | 3415 | |
656dc810 | 3416 | Int_t nJ = GetListOfJets(fJetsRec, kJetsRec); |
3417 | Int_t nRecJets = 0; | |
3418 | if(nJ>=0) nRecJets = fJetsRec->GetEntries(); | |
3419 | if(fDebug>2)Printf("%s:%d Selected Rec jets: %d %d",(char*)__FILE__,__LINE__,nJ,nRecJets); | |
3420 | if(nJ != nRecJets) Printf("%s:%d Mismatch Selected Rec Jets: %d %d",(char*)__FILE__,__LINE__,nJ,nRecJets); | |
3421 | ||
3422 | Int_t nJCuts = GetListOfJets(fJetsRecCuts, kJetsRecAcceptance); | |
3423 | Int_t nRecJetsCuts = 0; | |
3424 | if(nJCuts>=0) nRecJetsCuts = fJetsRecCuts->GetEntries(); | |
3425 | if(fDebug>2)Printf("%s:%d Selected Rec jets after cuts: %d %d",(char*)__FILE__,__LINE__,nJCuts,nRecJetsCuts); | |
3426 | if(nRecJetsCuts != nJCuts) Printf("%s:%d Mismatch selected Rec jets after cuts: %d %d",(char*)__FILE__,__LINE__,nJCuts,nRecJetsCuts); | |
3427 | fh1nRecJetsCuts->Fill(nRecJetsCuts); | |
3428 | ||
656dc810 | 3429 | if(fJetTypeGen==kJetsKine || fJetTypeGen == kJetsKineAcceptance) fJetsGen->SetOwner(kTRUE); // kine aod jets allocated on heap, delete them with TList::Clear() |
3430 | Int_t nJGen = GetListOfJets(fJetsGen, fJetTypeGen); | |
3431 | Int_t nGenJets = 0; | |
3432 | if(nJGen>=0) nGenJets = fJetsGen->GetEntries(); | |
3433 | if(fDebug>2)Printf("%s:%d Selected Gen jets: %d %d",(char*)__FILE__,__LINE__,nJGen,nGenJets); | |
3434 | if(nJGen != nGenJets) Printf("%s:%d Mismatch selected Gen jets: %d %d",(char*)__FILE__,__LINE__,nJGen,nGenJets); | |
3435 | fh1nGenJets->Fill(nGenJets); | |
3436 | ||
3437 | ||
fe343c6b | 3438 | if(fJetTypeRecEff==kJetsKine || fJetTypeRecEff == kJetsKineAcceptance) fJetsRecEff->SetOwner(kTRUE); // kine aod jets allocated on heap, delete them with TList::Clear() |
3439 | Int_t nJRecEff = GetListOfJets(fJetsRecEff, fJetTypeRecEff); | |
3440 | Int_t nRecEffJets = 0; | |
3441 | if(nJRecEff>=0) nRecEffJets = fJetsRecEff->GetEntries(); | |
3442 | if(fDebug>2)Printf("%s:%d Selected RecEff jets: %d %d",(char*)__FILE__,__LINE__,nJRecEff,nRecEffJets); | |
3443 | if(nJRecEff != nRecEffJets) Printf("%s:%d Mismatch selected RecEff jets: %d %d",(char*)__FILE__,__LINE__,nJRecEff,nRecEffJets); | |
3444 | fh1nRecEffJets->Fill(nRecEffJets); | |
3445 | ||
67e37e80 | 3446 | //____ fetch background jets ___________________________________________________ |
742ee86c | 3447 | if(fBckgMode && |
3170a3f8 | 3448 | (fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters || |
3449 | fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || | |
3450 | fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading)){ | |
742ee86c | 3451 | |
3452 | Int_t nBJ = GetListOfBckgJets(fBckgJetsRec, kJetsRec); | |
67e37e80 | 3453 | Int_t nRecBckgJets = 0; |
3454 | if(nBJ>=0) nRecBckgJets = fBckgJetsRec->GetEntries(); | |
3455 | if(fDebug>2)Printf("%s:%d Selected Rec background jets: %d %d",(char*)__FILE__,__LINE__,nBJ,nRecBckgJets); | |
3456 | if(nBJ != nRecBckgJets) Printf("%s:%d Mismatch Selected Rec background jets: %d %d",(char*)__FILE__,__LINE__,nBJ,nRecBckgJets); | |
3457 | ||
742ee86c | 3458 | Int_t nBJCuts = GetListOfBckgJets(fBckgJetsRecCuts, kJetsRecAcceptance); |
67e37e80 | 3459 | Int_t nRecBckgJetsCuts = 0; |
3460 | if(nBJCuts>=0) nRecBckgJetsCuts = fBckgJetsRecCuts->GetEntries(); | |
3461 | if(fDebug>2)Printf("%s:%d Selected Rec background jets after cuts: %d %d",(char*)__FILE__,__LINE__,nJCuts,nRecJetsCuts); | |
3462 | if(nRecBckgJetsCuts != nBJCuts) Printf("%s:%d Mismatch selected Rec background jets after cuts: %d %d",(char*)__FILE__,__LINE__,nBJCuts,nRecBckgJetsCuts); | |
3463 | fh1nRecBckgJetsCuts->Fill(nRecBckgJetsCuts); | |
3464 | ||
742ee86c | 3465 | if(0){ // protection OB - not yet implemented |
3466 | if(fJetTypeGen==kJetsKine || fJetTypeGen == kJetsKineAcceptance) fBckgJetsGen->SetOwner(kTRUE); // kine aod jets allocated on heap, delete them with TList::Clear() | |
3467 | Int_t nBJGen = GetListOfBckgJets(fBckgJetsGen, fJetTypeGen); | |
3468 | Int_t nGenBckgJets = 0; | |
3469 | if(nBJGen>=0) nGenBckgJets = fBckgJetsGen->GetEntries(); | |
3470 | if(fDebug>2)Printf("%s:%d Selected Gen background jets: %d %d",(char*)__FILE__,__LINE__,nBJGen,nGenBckgJets); | |
3471 | if(nBJGen != nGenBckgJets) Printf("%s:%d Mismatch selected Gen background jets: %d %d",(char*)__FILE__,__LINE__,nBJGen,nGenBckgJets); | |
3472 | fh1nGenBckgJets->Fill(nGenBckgJets); | |
3473 | } | |
67e37e80 | 3474 | } |
fe343c6b | 3475 | |
44b235ce | 3476 | |
656dc810 | 3477 | //____ fetch particles __________________________________________________________ |
3478 | ||
3479 | Int_t nT = GetListOfTracks(fTracksRec, kTrackAOD); | |
3480 | Int_t nRecPart = 0; | |
3481 | if(nT>=0) nRecPart = fTracksRec->GetEntries(); | |
3482 | if(fDebug>2)Printf("%s:%d Selected Rec tracks: %d %d",(char*)__FILE__,__LINE__,nT,nRecPart); | |
3483 | if(nRecPart != nT) Printf("%s:%d Mismatch selected Rec tracks: %d %d",(char*)__FILE__,__LINE__,nT,nRecPart); | |
3484 | ||
3485 | ||
3486 | Int_t nTCuts = GetListOfTracks(fTracksRecCuts, kTrackAODCuts); | |
3487 | Int_t nRecPartCuts = 0; | |
3488 | if(nTCuts>=0) nRecPartCuts = fTracksRecCuts->GetEntries(); | |
3489 | if(fDebug>2)Printf("%s:%d Selected Rec tracks after cuts: %d %d",(char*)__FILE__,__LINE__,nTCuts,nRecPartCuts); | |
3490 | if(nRecPartCuts != nTCuts) Printf("%s:%d Mismatch selected Rec tracks after cuts: %d %d",(char*)__FILE__,__LINE__,nTCuts,nRecPartCuts); | |
3491 | fh1EvtMult->Fill(nRecPartCuts); | |
3492 | ||
3493 | ||
3af23c82 | 3494 | |
656dc810 | 3495 | Int_t nTGen = GetListOfTracks(fTracksGen,fTrackTypeGen); |
3496 | Int_t nGenPart = 0; | |
3497 | if(nTGen>=0) nGenPart = fTracksGen->GetEntries(); | |
3498 | if(fDebug>2)Printf("%s:%d Selected Gen tracks: %d %d",(char*)__FILE__,__LINE__,nTGen,nGenPart); | |
3499 | if(nGenPart != nTGen) Printf("%s:%d Mismatch selected Gen tracks: %d %d",(char*)__FILE__,__LINE__,nTGen,nGenPart); | |
3500 | ||
3501 | ||
3502 | //____ analysis, fill histos ___________________________________________________ | |
3503 | ||
3af23c82 | 3504 | if(fQAMode){ |
3505 | // loop over tracks | |
3506 | if(fQAMode&1){ | |
3507 | for(Int_t it=0; it<nRecPart; ++it){ | |
3508 | AliVParticle *part = dynamic_cast<AliVParticle*>(fTracksRec->At(it)); | |
b85b355c | 3509 | if(part)fQATrackHistosRec->FillTrackQA( part->Eta(), TVector2::Phi_0_2pi(part->Phi()), part->Pt()); |
3af23c82 | 3510 | } |
3511 | for(Int_t it=0; it<nRecPartCuts; ++it){ | |
3512 | AliVParticle *part = dynamic_cast<AliVParticle*>(fTracksRecCuts->At(it)); | |
b85b355c | 3513 | if(part)fQATrackHistosRecCuts->FillTrackQA( part->Eta(), TVector2::Phi_0_2pi(part->Phi()), part->Pt()); |
3af23c82 | 3514 | } |
3515 | for(Int_t it=0; it<nGenPart; ++it){ | |
3516 | AliVParticle *part = dynamic_cast<AliVParticle*>(fTracksGen->At(it)); | |
b85b355c | 3517 | if(part)fQATrackHistosGen->FillTrackQA( part->Eta(), TVector2::Phi_0_2pi(part->Phi()), part->Pt()); |
3af23c82 | 3518 | } |
3170a3f8 | 3519 | |
3520 | // fill DCA to prim vertex | |
3521 | for(Int_t it=0; it<nRecPartCuts; ++it){ | |
3522 | AliAODTrack *aodtr = dynamic_cast<AliAODTrack*>(fTracksRecCuts->At(it)); | |
3523 | ||
3524 | if(!aodtr) continue; | |
3525 | if(!primVtx) continue; | |
3526 | ||
3527 | Double_t Bfield = fAOD->GetMagneticField(); | |
3528 | Double_t dz[2]; | |
3529 | Double_t cov[3]; | |
3530 | ||
3531 | AliAODTrack tmp(*aodtr); | |
3532 | tmp.PropagateToDCA(primVtx, Bfield, 5., dz, cov); | |
3533 | ||
3534 | Double_t dcaXY = dz[0]; | |
3535 | Double_t dcaZ = dz[1]; | |
3536 | ||
3537 | fh2TrackPtVsDCAXY->Fill(dcaXY,tmp.Pt()); | |
3538 | fh2TrackPtVsDCAZ->Fill(dcaZ,tmp.Pt()); | |
3539 | } | |
3af23c82 | 3540 | } |
656dc810 | 3541 | |
3170a3f8 | 3542 | |
3543 | ||
3544 | ||
3af23c82 | 3545 | // loop over jets |
3546 | ||
3547 | if(fQAMode&2){ | |
3548 | for(Int_t ij=0; ij<nRecJets; ++ij){ | |
3549 | AliAODJet* jet = dynamic_cast<AliAODJet*>(fJetsRec->At(ij)); | |
b85b355c | 3550 | if(jet)fQAJetHistosRec->FillJetQA( jet->Eta(), TVector2::Phi_0_2pi(jet->Phi()), jet->Pt()); |
3af23c82 | 3551 | } |
3552 | } | |
656dc810 | 3553 | } |
656dc810 | 3554 | |
3af23c82 | 3555 | if(fQAMode || fFFMode || fIJMode || fPhiCorrMode){ |
3556 | for(Int_t ij=0; ij<nRecJetsCuts; ++ij){ | |
656dc810 | 3557 | |
1ea145ef | 3558 | AliAODJet* jet = (AliAODJet*)(fJetsRecCuts->At(ij)); |
3af23c82 | 3559 | if(fQAMode&2) fQAJetHistosRecCuts->FillJetQA( jet->Eta(), TVector2::Phi_0_2pi(jet->Phi()), jet->Pt()); |
656dc810 | 3560 | |
3af23c82 | 3561 | if(ij==0){ // leading jet |
656dc810 | 3562 | |
3af23c82 | 3563 | if(fQAMode&2) fQAJetHistosRecCutsLeading->FillJetQA( jet->Eta(), TVector2::Phi_0_2pi(jet->Phi()), jet->Pt() ); |
656dc810 | 3564 | |
3af23c82 | 3565 | TList* jettracklist = new TList(); |
3566 | Double_t sumPt = 0.; | |
3567 | Float_t leadTrackPt = 0.; | |
3568 | TLorentzVector* leadTrackV = new TLorentzVector(); | |
3569 | ||
3570 | if(GetFFRadius()<=0){ | |
3571 | GetJetTracksTrackrefs(jettracklist, jet); | |
3572 | } else { | |
3573 | GetJetTracksPointing(fTracksRecCuts, jettracklist, jet, GetFFRadius(), sumPt); | |
656dc810 | 3574 | } |
3af23c82 | 3575 | |
3576 | for(Int_t it=0; it<jettracklist->GetSize(); ++it){ | |
3577 | ||
3578 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(jettracklist->At(it)); | |
ab851c96 | 3579 | if(!trackVP)continue; |
3af23c82 | 3580 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
3581 | ||
3582 | Float_t jetPt = jet->Pt(); | |
3583 | Float_t trackPt = trackV->Pt(); | |
3584 | ||
3585 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
3586 | ||
3587 | if(fFFMode) fFFHistosRecCuts->FillFF( trackPt, jetPt, incrementJetPt); | |
3588 | if(fIJMode) fIJHistosRecCuts->FillIntraJet( trackV, jet->MomentumVector() ); | |
3589 | ||
3590 | if(it==0){ // leading track | |
3591 | leadTrackPt = trackPt; | |
3592 | leadTrackV->SetPxPyPzE(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); | |
3593 | ||
3594 | if(fFFMode) fFFHistosRecLeadingTrack->FillFF( leadTrackPt, jetPt, kTRUE); | |
3595 | if(fIJMode) fIJHistosRecLeadingTrack->FillIntraJet( leadTrackV, jet->MomentumVector() ); | |
3596 | } | |
3597 | if(fFFMode) fFFHistosRecLeading->FillFF( trackPt, leadTrackPt , incrementJetPt); | |
3598 | if(fIJMode) fIJHistosRecLeading->FillIntraJet( trackV, leadTrackV ); | |
3599 | ||
3600 | delete trackV; | |
3601 | } | |
3602 | ||
742ee86c | 3603 | // ff and ij for background study |
3af23c82 | 3604 | if(fBckgMode){ |
3605 | if(fBckgType[0]!=-1) | |
3606 | FillBckgHistos(fBckgType[0], fTracksRecCuts, fJetsRecCuts, jet, leadTrackPt, leadTrackV, | |
3607 | fFFBckgHisto0RecCuts, fFFBckgHisto0RecLeading, | |
3608 | fIJBckgHisto0RecCuts, fIJBckgHisto0RecLeading, | |
3609 | fQABckgHisto0RecCuts); | |
3610 | if(fBckgType[1]!=-1) | |
3611 | FillBckgHistos(fBckgType[1], fTracksRecCuts, fJetsRecCuts, jet, leadTrackPt, leadTrackV, | |
3612 | fFFBckgHisto1RecCuts, fFFBckgHisto1RecLeading, | |
3613 | fIJBckgHisto1RecCuts, fIJBckgHisto1RecLeading, | |
3614 | fQABckgHisto1RecCuts); | |
3615 | if(fBckgType[2]!=-1) | |
3616 | FillBckgHistos(fBckgType[2], fTracksRecCuts, fJetsRecCuts, jet, leadTrackPt, leadTrackV, | |
3617 | fFFBckgHisto2RecCuts, fFFBckgHisto2RecLeading, | |
3618 | fIJBckgHisto2RecCuts, fIJBckgHisto2RecLeading, | |
3619 | fQABckgHisto2RecCuts); | |
742ee86c | 3620 | if(fBckgType[3]!=-1) |
3621 | FillBckgHistos(fBckgType[3], fTracksRecCuts, fJetsRecCuts, jet, leadTrackPt, leadTrackV, | |
3622 | fFFBckgHisto3RecCuts, fFFBckgHisto3RecLeading, | |
3623 | fIJBckgHisto3RecCuts, fIJBckgHisto3RecLeading, | |
3624 | fQABckgHisto3RecCuts); | |
3170a3f8 | 3625 | if(fBckgType[4]!=-1) |
3626 | FillBckgHistos(fBckgType[4], fTracksRecCuts, fJetsRecCuts, jet, leadTrackPt, leadTrackV, | |
3627 | fFFBckgHisto4RecCuts, fFFBckgHisto4RecLeading, | |
3628 | fIJBckgHisto4RecCuts, fIJBckgHisto4RecLeading, | |
3629 | fQABckgHisto4RecCuts); | |
3af23c82 | 3630 | } // end if(fBckgMode) |
3631 | ||
3632 | delete leadTrackV; | |
3633 | delete jettracklist; | |
656dc810 | 3634 | |
3af23c82 | 3635 | // phi correlation |
3636 | if(fPhiCorrMode){ | |
3637 | for(Int_t it=0; it<nRecPartCuts; ++it){ | |
1ea145ef | 3638 | AliVParticle *part = (AliVParticle*)(fTracksRecCuts->At(it)); |
3af23c82 | 3639 | |
3640 | Float_t partEta = part->Eta(); | |
3641 | Float_t partPhi = part->Phi(); | |
3642 | Float_t partPt = part->Pt(); | |
3643 | ||
3644 | fPhiCorrHistosJetArea->FillTrackQA( partEta, | |
3645 | TVector2::Phi_mpi_pi( jet->Phi() - partPhi ), | |
3646 | partPt, | |
3647 | kTRUE); | |
3648 | ||
3649 | fPhiCorrHistosTransverseArea->FillTrackQA( partEta, | |
3650 | TVector2::Phi_mpi_pi( jet->Phi() - partPhi + TMath::Pi()/2), | |
3651 | partPt, | |
3652 | kTRUE); | |
3653 | ||
3654 | fPhiCorrHistosAwayArea->FillTrackQA( partEta, | |
3655 | TVector2::Phi_mpi_pi( jet->Phi() - partPhi + TMath::Pi()), | |
3656 | partPt, | |
3657 | kTRUE); | |
3658 | } | |
3659 | } // end: phi-correlation | |
3660 | ||
3661 | } // end: leading jet | |
3662 | } // end: rec. jets after cuts | |
656dc810 | 3663 | |
3af23c82 | 3664 | // generated jets |
3665 | for(Int_t ij=0; ij<nGenJets; ++ij){ | |
656dc810 | 3666 | |
3af23c82 | 3667 | AliAODJet* jet = dynamic_cast<AliAODJet*>(fJetsGen->At(ij)); |
ab851c96 | 3668 | if(!jet)continue; |
3af23c82 | 3669 | if(fQAMode&2) fQAJetHistosGen->FillJetQA( jet->Eta(), TVector2::Phi_0_2pi(jet->Phi()), jet->Pt()); |
656dc810 | 3670 | |
3af23c82 | 3671 | if(ij==0){ // leading jet |
cb76764e | 3672 | |
3af23c82 | 3673 | if(fQAMode&2) fQAJetHistosGenLeading->FillJetQA( jet->Eta(), TVector2::Phi_0_2pi(jet->Phi()), jet->Pt()); |
cb76764e | 3674 | |
3af23c82 | 3675 | TList* jettracklist = new TList(); |
3676 | Double_t sumPt = 0.; | |
3677 | Float_t leadTrackPt = 0.; | |
3678 | TLorentzVector* leadTrackV = new TLorentzVector(); | |
656dc810 | 3679 | |
3af23c82 | 3680 | if(GetFFRadius()<=0){ |
3681 | GetJetTracksTrackrefs(jettracklist, jet); | |
3682 | } else { | |
3683 | GetJetTracksPointing(fTracksGen, jettracklist, jet, GetFFRadius(), sumPt); | |
656dc810 | 3684 | } |
3af23c82 | 3685 | |
3686 | for(Int_t it=0; it<jettracklist->GetSize(); ++it){ | |
3687 | ||
3688 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(jettracklist->At(it)); | |
3689 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); | |
3690 | ||
3691 | Float_t jetPt = jet->Pt(); | |
3692 | Float_t trackPt = trackV->Pt(); | |
3693 | ||
3694 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
3695 | ||
3696 | if(fFFMode) fFFHistosGen->FillFF( trackPt, jetPt, incrementJetPt ); | |
3697 | if(fIJMode) fIJHistosGen->FillIntraJet( trackV, jet->MomentumVector() ); | |
3698 | ||
3699 | if(it==0){ // leading track | |
3700 | leadTrackPt = trackPt; | |
3701 | leadTrackV->SetPxPyPzE(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); | |
3702 | ||
3703 | if(fFFMode) fFFHistosGenLeadingTrack->FillFF( leadTrackPt, jetPt, kTRUE ); | |
3704 | if(fIJMode) fIJHistosGenLeadingTrack->FillIntraJet( leadTrackV, jet->MomentumVector() ); | |
3705 | } | |
3706 | if(fFFMode) fFFHistosGenLeading->FillFF( trackPt, leadTrackPt, incrementJetPt ); | |
3707 | if(fIJMode) fIJHistosGenLeading->FillIntraJet( trackV, leadTrackV ); | |
3708 | ||
3709 | delete trackV; | |
3710 | } | |
3711 | ||
3712 | delete leadTrackV; | |
3713 | delete jettracklist; | |
656dc810 | 3714 | } |
656dc810 | 3715 | } |
3af23c82 | 3716 | } // end: QA, FF and intra-jet |
656dc810 | 3717 | |
3718 | //_______ DiJet part _____________________________________________________ | |
3af23c82 | 3719 | if(fDJMode){ |
3720 | if (nRecJetsCuts > 1) | |
656dc810 | 3721 | { |
1ea145ef | 3722 | AliAODJet* jet1 = (AliAODJet*)(fJetsRecCuts->At(0)); |
3723 | AliAODJet* jet2 = (AliAODJet*)(fJetsRecCuts->At(1)); | |
656dc810 | 3724 | |
3af23c82 | 3725 | // DiJet deltaphi calculation |
3726 | Double_t phi1 = TVector2::Phi_0_2pi(jet1->Phi()); | |
3727 | Double_t phi2 = TVector2::Phi_0_2pi(jet2->Phi()); | |
3728 | Double_t deltaPhi = TMath::Abs(phi1-phi2); | |
3729 | if (deltaPhi > TMath::Pi() && deltaPhi < 2*TMath::Pi()) deltaPhi = 2*TMath::Pi() - deltaPhi; | |
3730 | ||
3731 | // DiJet CDF cut calculation | |
3732 | Double_t et1 = TMath::Abs(jet1->E()*TMath::Sin(jet1->Theta())); | |
3733 | Double_t et2 = TMath::Abs(jet2->E()*TMath::Sin(jet2->Theta())); | |
3734 | Double_t sumEt = et1 + et2; | |
3735 | Double_t normEt1PlusEt2 = TMath::Sqrt(et1*et1+et2*et2+2*et1*et2*TMath::Cos(deltaPhi)); | |
3736 | Double_t ratio = (Double_t)(normEt1PlusEt2/sumEt); | |
3737 | ||
3738 | // DiJet events selection | |
3739 | Bool_t positionCut = 0; | |
3740 | Bool_t positionEnergyCut = 0; | |
3741 | Bool_t cdfCut = 0; | |
3742 | ||
3743 | // Position cut : | |
3744 | if (deltaPhi > fDiJetDeltaPhiCut) positionCut = 1; | |
3745 | // Position-Energy cut : | |
3746 | if ((deltaPhi > fDiJetDeltaPhiCut) && ((jet2->Pt()) >= fDiJetPtFractionCut*(jet1->Pt()))) positionEnergyCut = 1; | |
3747 | // CDF cut : | |
3748 | if (ratio < fDiJetCDFCut) cdfCut = 1; | |
3749 | ||
3750 | Int_t go = 0; | |
3751 | ||
3752 | if (fDiJetCut == 1 && positionCut == 1) go = 1; | |
3753 | if (fDiJetCut == 2 && positionEnergyCut == 1) go = 1; | |
3754 | if (fDiJetCut == 3 && cdfCut == 1) go = 1; | |
3755 | ||
3756 | if (go) | |
656dc810 | 3757 | { |
3af23c82 | 3758 | Double_t deltaEta = TMath::Abs(jet1->Eta()-jet2->Eta()); |
3759 | Double_t deltaPt = TMath::Abs(jet1->Pt()-jet2->Pt()); | |
3760 | Double_t inbal = (jet1->Pt()-jet2->Pt())/(jet1->Pt()+jet2->Pt()); | |
3761 | Double_t meanEt = (Double_t)((et1+et2)/2.); | |
3762 | Double_t invariantMass = (Double_t)InvMass(jet1,jet2); | |
656dc810 | 3763 | |
3af23c82 | 3764 | Double_t jetBin = GetDiJetBin(invariantMass, jet1->Pt(), meanEt, fDiJetKindBins); |
656dc810 | 3765 | |
3af23c82 | 3766 | if (jetBin > 0) |
656dc810 | 3767 | { |
3af23c82 | 3768 | if(fDJMode&2) fQADiJetHistosRecCuts->FillDiJetQA(invariantMass, deltaPhi, deltaEta, deltaPt, inbal, jetBin); |
3769 | ||
3770 | if(fDJMode&1){ | |
3771 | TList* jettracklist1 = new TList(); | |
3772 | Double_t sumPt1 = 0.; | |
3773 | Float_t leadTrackPt1 = 0; | |
3774 | ||
3775 | TList* jettracklist2 = new TList(); | |
3776 | Double_t sumPt2 = 0.; | |
3777 | Float_t leadTrackPt2 = 0; | |
3778 | ||
3779 | if(GetFFRadius()<=0) | |
3780 | { | |
3781 | GetJetTracksTrackrefs(jettracklist1, jet1); | |
3782 | GetJetTracksTrackrefs(jettracklist2, jet2); | |
3783 | } | |
3784 | else | |
3785 | { | |
3786 | GetJetTracksPointing(fTracksRecCuts, jettracklist1, jet1, GetFFRadius(), sumPt1); | |
3787 | GetJetTracksPointing(fTracksRecCuts, jettracklist2, jet2, GetFFRadius(), sumPt2); | |
3788 | } | |
3789 | ||
3790 | Int_t nTracks = jettracklist1->GetSize(); | |
3791 | if (jettracklist1->GetSize() < jettracklist2->GetSize()) nTracks = jettracklist2->GetSize(); | |
3792 | ||
3793 | for(Int_t it=0; it<nTracks; ++it) | |
3794 | { | |
3795 | if (it < jettracklist1->GetSize()) | |
3796 | { | |
ab851c96 | 3797 | AliVParticle *vp = (dynamic_cast<AliVParticle*> (jettracklist1->At(it))); |
3798 | Float_t trackPt1 = (vp?vp->Pt():0); | |
3af23c82 | 3799 | Float_t jetPt1 = jet1->Pt(); |
3800 | ||
3801 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
3802 | ||
3803 | fFFDiJetHistosRecCuts->FillDiJetFF(1, trackPt1, jetPt1, jetBin, incrementJetPt); | |
3804 | fFFDiJetHistosRecCuts->FillDiJetFF(0, trackPt1, jetPt1, jetBin, incrementJetPt); | |
3805 | ||
3806 | if (it == 0) | |
3807 | { | |
3808 | leadTrackPt1 = trackPt1; | |
3809 | ||
3810 | fFFDiJetHistosRecLeadingTrack->FillDiJetFF(1, leadTrackPt1, jetPt1, jetBin, kTRUE); | |
3811 | fFFDiJetHistosRecLeadingTrack->FillDiJetFF(0, leadTrackPt1, jetPt1, jetBin, kTRUE); | |
3812 | } | |
3813 | ||
3814 | fFFDiJetHistosRecLeading->FillDiJetFF(1, trackPt1, leadTrackPt1, jetBin, incrementJetPt); | |
3815 | fFFDiJetHistosRecLeading->FillDiJetFF(0, trackPt1, leadTrackPt1, jetBin, incrementJetPt); | |
3816 | } | |
3817 | ||
3818 | if (it < jettracklist2->GetSize()) | |
3819 | { | |
9939142f | 3820 | Float_t trackPt2 = ((AliVParticle*)(jettracklist2->At(it)))->Pt(); |
3af23c82 | 3821 | Float_t jetPt2 = jet2->Pt(); |
3822 | ||
3823 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
3824 | ||
3825 | fFFDiJetHistosRecCuts->FillDiJetFF(2, trackPt2, jetPt2, jetBin, incrementJetPt); | |
3826 | fFFDiJetHistosRecCuts->FillDiJetFF(0, trackPt2, jetPt2, jetBin, incrementJetPt); | |
3827 | ||
3828 | if (it == 0) | |
3829 | { | |
3830 | leadTrackPt2 = trackPt2; | |
3831 | ||
3832 | fFFDiJetHistosRecLeadingTrack->FillDiJetFF(2, leadTrackPt2, jetPt2, jetBin, kTRUE); | |
3833 | fFFDiJetHistosRecLeadingTrack->FillDiJetFF(0, leadTrackPt2, jetPt2, jetBin, kTRUE); | |
3834 | } | |
3835 | ||
3836 | fFFDiJetHistosRecLeading->FillDiJetFF(2, trackPt2, leadTrackPt2, jetBin, incrementJetPt); | |
3837 | fFFDiJetHistosRecLeading->FillDiJetFF(0, trackPt2, leadTrackPt2, jetBin, incrementJetPt); | |
3838 | } | |
3839 | } // End loop on tracks | |
3840 | ||
3841 | delete jettracklist1; | |
3842 | delete jettracklist2; | |
3843 | } | |
3844 | } // End if(jetBin > 0) | |
3845 | else { Printf("Jet bins for di-jet studies not set !");} | |
3846 | } // End if(go) | |
3847 | } // End if(nRecJets > 1) | |
3848 | ||
3849 | if (nGenJets > 1) | |
3850 | { | |
3851 | AliAODJet* jet1 = dynamic_cast<AliAODJet*>(fJetsGen->At(0)); | |
3852 | AliAODJet* jet2 = dynamic_cast<AliAODJet*>(fJetsGen->At(1)); | |
ab851c96 | 3853 | if(jet1&&jet2){ |
3af23c82 | 3854 | |
3855 | Double_t deltaPhi = 0; | |
3856 | Double_t phi1 = TVector2::Phi_0_2pi(jet1->Phi()); | |
3857 | Double_t phi2 = TVector2::Phi_0_2pi(jet2->Phi()); | |
3858 | deltaPhi = TMath::Abs(phi1-phi2); | |
3859 | if (deltaPhi > TMath::Pi() && deltaPhi < 2*TMath::Pi()) deltaPhi = 2*TMath::Pi() - deltaPhi; | |
3860 | ||
3861 | Double_t et1 = TMath::Abs(jet1->E()*TMath::Sin(jet1->Theta())); | |
3862 | Double_t et2 = TMath::Abs(jet2->E()*TMath::Sin(jet2->Theta())); | |
3863 | Double_t sumEt = et1 + et2; | |
3864 | Double_t normEt1PlusEt2 = TMath::Sqrt(et1*et1+et2*et2+2*et1*et2*TMath::Cos(deltaPhi)); | |
3865 | Double_t ratio = (Double_t)(normEt1PlusEt2/sumEt); | |
3866 | ||
3867 | // DiJet events selection | |
3868 | Bool_t positionCut = 0; | |
3869 | Bool_t positionEnergyCut = 0; | |
3870 | Bool_t cdfCut = 0; | |
3871 | ||
3872 | // Position cut : | |
3873 | if (deltaPhi > fDiJetDeltaPhiCut) positionCut = 1; | |
3874 | // Position-Energy cut : | |
3875 | if ((deltaPhi > fDiJetDeltaPhiCut) && ((jet2->Pt()) >= fDiJetPtFractionCut*(jet1->Pt()))) positionEnergyCut = 1; | |
3876 | // CDF cut : | |
3877 | if (ratio < fDiJetCDFCut) cdfCut = 1; | |
3878 | ||
3879 | Int_t go = 0; | |
3880 | ||
3881 | if (fDiJetCut == 1 && positionCut == 1) go = 1; | |
3882 | if (fDiJetCut == 2 && positionEnergyCut == 1) go = 1; | |
3883 | if (fDiJetCut == 3 && cdfCut == 1) go = 1; | |
3884 | ||
3885 | if (go) | |
3886 | { | |
3887 | Double_t deltaEta = TMath::Abs(jet1->Eta()-jet2->Eta()); | |
3888 | Double_t deltaPt = TMath::Abs(jet1->Pt()-jet2->Pt()); | |
3889 | Double_t inbal = (jet1->Pt()-jet2->Pt())/(jet1->Pt()+jet2->Pt()); | |
3890 | Double_t meanEt = (Double_t)((et1+et2)/2.); | |
3891 | Double_t invariantMass = (Double_t)InvMass(jet1,jet2); | |
656dc810 | 3892 | |
3af23c82 | 3893 | Double_t jetBin = GetDiJetBin(invariantMass, jet1->Pt(), meanEt, fDiJetKindBins); |
656dc810 | 3894 | |
3af23c82 | 3895 | if(jetBin > 0) |
656dc810 | 3896 | { |
3af23c82 | 3897 | if(fDJMode&2) fQADiJetHistosGen->FillDiJetQA(invariantMass, deltaPhi, deltaEta, deltaPt, inbal, jetBin); |
656dc810 | 3898 | |
3af23c82 | 3899 | if(fDJMode&1){ |
3900 | TList* jettracklist1 = new TList(); | |
3901 | Double_t sumPt1 = 0.; | |
3902 | Float_t leadTrackPt1 = 0.; | |
3903 | ||
3904 | TList* jettracklist2 = new TList(); | |
3905 | Double_t sumPt2 = 0.; | |
3906 | Float_t leadTrackPt2 = 0.; | |
3907 | ||
3908 | if(GetFFRadius()<=0) | |
3909 | { | |
3910 | GetJetTracksTrackrefs(jettracklist1, jet1); | |
3911 | GetJetTracksTrackrefs(jettracklist2, jet2); | |
3912 | } | |
3913 | else | |
3914 | { | |
3915 | GetJetTracksPointing(fTracksGen, jettracklist1, jet1, GetFFRadius(), sumPt1); | |
3916 | GetJetTracksPointing(fTracksGen, jettracklist2, jet2, GetFFRadius(), sumPt2); | |
3917 | } | |
3918 | ||
3919 | Int_t nTracks = jettracklist1->GetSize(); | |
3920 | if (jettracklist1->GetSize() < jettracklist2->GetSize()) nTracks = jettracklist2->GetSize(); | |
3921 | ||
3922 | for(Int_t it=0; it<nTracks; ++it) | |
3923 | { | |
3924 | if (it < jettracklist1->GetSize()) | |
3925 | { | |
1ea145ef | 3926 | Float_t trackPt1 = ((AliVParticle*)jettracklist1->At(it))->Pt(); |
3af23c82 | 3927 | Float_t jetPt1 = jet1->Pt(); |
3928 | ||
3929 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
3930 | ||
3931 | fFFDiJetHistosGen->FillDiJetFF( 1, trackPt1, jetPt1, jetBin, incrementJetPt); | |
3932 | fFFDiJetHistosGen->FillDiJetFF( 0, trackPt1, jetPt1, jetBin, incrementJetPt); | |
3933 | ||
3934 | if(it==0) | |
3935 | { | |
3936 | leadTrackPt1 = trackPt1; | |
3937 | ||
3938 | fFFDiJetHistosGenLeadingTrack->FillDiJetFF( 1, leadTrackPt1, jetPt1, jetBin, kTRUE); | |
3939 | fFFDiJetHistosGenLeadingTrack->FillDiJetFF( 0, leadTrackPt1, jetPt1, jetBin, kTRUE); | |
3940 | } | |
3941 | ||
3942 | fFFDiJetHistosGenLeading->FillDiJetFF( 1, trackPt1, leadTrackPt1, jetBin, incrementJetPt); | |
3943 | fFFDiJetHistosGenLeading->FillDiJetFF( 0, trackPt1, leadTrackPt1, jetBin, incrementJetPt); | |
3944 | } | |
3945 | ||
3946 | if (it < jettracklist2->GetSize()) | |
3947 | { | |
3170a3f8 | 3948 | Float_t trackPt2 = ((AliVParticle*)jettracklist2->At(it))->Pt(); |
3af23c82 | 3949 | Float_t jetPt2 = jet2->Pt(); |
3950 | ||
3951 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
3952 | ||
3953 | fFFDiJetHistosGen->FillDiJetFF( 2, trackPt2, jetPt2, jetBin, incrementJetPt); | |
3954 | fFFDiJetHistosGen->FillDiJetFF( 0, trackPt2, jetPt2, jetBin, incrementJetPt); | |
3955 | ||
3956 | if (it==0) | |
3957 | { | |
3958 | leadTrackPt2 = trackPt2; | |
3959 | ||
3960 | fFFDiJetHistosGenLeadingTrack->FillDiJetFF( 2, leadTrackPt2, jetPt2, jetBin, kTRUE); | |
3961 | fFFDiJetHistosGenLeadingTrack->FillDiJetFF( 0, leadTrackPt2, jetPt2, jetBin, kTRUE); | |
3962 | } | |
3963 | ||
3964 | fFFDiJetHistosGenLeading->FillDiJetFF( 2, trackPt2, leadTrackPt2, jetBin, incrementJetPt); | |
3965 | fFFDiJetHistosGenLeading->FillDiJetFF( 0, trackPt2, leadTrackPt2, jetBin, incrementJetPt); | |
3966 | } | |
3967 | } // End loop on tracks | |
3968 | ||
3969 | delete jettracklist1; | |
3970 | delete jettracklist2; | |
3971 | } | |
3972 | } // End if(jetBin > 0) | |
3973 | else { Printf("Jet bins for di-jet studies not set !");} | |
3974 | } // End if (go) | |
ab851c96 | 3975 | }// end if jet1 and jet2 |
3af23c82 | 3976 | } // End if(nGenJets > 1) |
3977 | } // end: di-jet | |
656dc810 | 3978 | |
fe343c6b | 3979 | // ____ efficiency _______________________________ |
3980 | ||
3af23c82 | 3981 | if(fEffMode && (fJetTypeRecEff != kJetsUndef)){ |
cb76764e | 3982 | |
3983 | // arrays for generated particles: reconstructed AOD track index, isPrimary flag, are initialized in AssociateGenRec(...) function | |
3984 | TArrayI indexAODTr; | |
3985 | TArrayS isGenPrim; | |
fe343c6b | 3986 | |
cb76764e | 3987 | // array for reconcstructed AOD tracks: generated particle index, initialized in AssociateGenRec(...) function |
3988 | TArrayI indexMCTr; | |
fe343c6b | 3989 | |
cb76764e | 3990 | Int_t nTracksAODMCCharged = GetListOfTracks(fTracksAODMCCharged, kTrackAODMCCharged); |
3991 | if(fDebug>2)Printf("%s:%d selected AODMC tracks: %d ",(char*)__FILE__,__LINE__,nTracksAODMCCharged); | |
fe343c6b | 3992 | |
cb76764e | 3993 | Int_t nTracksRecQualityCuts = GetListOfTracks(fTracksRecQualityCuts, kTrackAODQualityCuts); |
3994 | if(fDebug>2)Printf("%s:%d selected rec tracks quality after cuts, full acceptance/pt : %d ",(char*)__FILE__,__LINE__,nTracksRecQualityCuts); | |
fe343c6b | 3995 | |
cb76764e | 3996 | // associate gen and rec tracks, store indices in TArrays |
3997 | AssociateGenRec(fTracksAODMCCharged,fTracksRecQualityCuts,indexAODTr,indexMCTr,isGenPrim); | |
fe343c6b | 3998 | |
cb76764e | 3999 | // single track eff |
3af23c82 | 4000 | if(fQAMode&1) FillSingleTrackRecEffHisto(fQATrackHistosRecEffGen,fQATrackHistosRecEffRec,fTracksAODMCCharged,indexAODTr,isGenPrim); |
4001 | if(fQAMode&1) FillSingleTrackResponse(fhnResponseSinglePt,fTracksAODMCCharged,fTracksRecQualityCuts,indexAODTr,isGenPrim); | |
4002 | ||
fe343c6b | 4003 | |
cb76764e | 4004 | // jet track eff |
fe343c6b | 4005 | |
cb76764e | 4006 | Double_t sumPtGenLeadingJetRecEff = 0; |
4007 | Double_t sumPtRecLeadingJetRecEff = 0; | |
fe343c6b | 4008 | |
cb76764e | 4009 | for(Int_t ij=0; ij<nRecEffJets; ++ij){ |
4010 | ||
9939142f | 4011 | AliAODJet* jet = (AliAODJet*)(fJetsRecEff->At(ij)); |
4012 | ||
cb76764e | 4013 | if(ij==0){ // leading jet |
4014 | ||
4015 | TList* jettracklistGen = new TList(); | |
4016 | GetJetTracksPointing(fTracksGen, jettracklistGen, jet, GetFFRadius(), sumPtGenLeadingJetRecEff); // for efficiency: gen tracks from pointing with gen/rec jet | |
4017 | ||
4018 | TList* jettracklistRec = new TList(); | |
4019 | GetJetTracksPointing(fTracksRecCuts,jettracklistRec, jet, GetFFRadius(), sumPtRecLeadingJetRecEff); // bin efficiency in jet pt bins using rec tracks | |
4020 | ||
4021 | Double_t jetEta = jet->Eta(); | |
4022 | Double_t jetPhi = TVector2::Phi_0_2pi(jet->Phi()); | |
4023 | ||
3af23c82 | 4024 | if(fQAMode&2) fQAJetHistosRecEffLeading->FillJetQA( jetEta, jetPhi, sumPtGenLeadingJetRecEff ); |
4025 | ||
4026 | if(fFFMode) FillJetTrackRecEffHisto(fFFHistosRecEffGen,fFFHistosRecEffRec,sumPtGenLeadingJetRecEff,sumPtRecLeadingJetRecEff, | |
4027 | jettracklistGen,fTracksAODMCCharged,indexAODTr,isGenPrim,fUseRecEffRecJetPtBins); | |
4028 | ||
4029 | if(fFFMode) FillJetTrackResponse(fhnResponseJetTrackPt,fhnResponseJetZ,fhnResponseJetXi,sumPtGenLeadingJetRecEff,sumPtRecLeadingJetRecEff, | |
742ee86c | 4030 | jettracklistGen,fTracksAODMCCharged,fTracksRecQualityCuts,indexAODTr,isGenPrim,fUseResponseRecJetPtBins); |
4031 | ||
cb76764e | 4032 | delete jettracklistGen; |
4033 | delete jettracklistRec; | |
4034 | } | |
4035 | } | |
4036 | ||
2d1d1b60 | 4037 | |
cb76764e | 4038 | // bckgr eff: complementary cones |
2d1d1b60 | 4039 | |
cb76764e | 4040 | if(0){ |
4041 | ||
4042 | for(Int_t ij=0; ij<nRecEffJets; ++ij){ | |
4043 | ||
4044 | AliAODJet* jet = dynamic_cast<AliAODJet*>(fJetsRecEff->At(ij)); | |
4045 | ||
4046 | if(ij==0){ // leading jet | |
4047 | ||
4048 | TList* perpjettracklistGen = new TList(); | |
4049 | Double_t sumPtGen = 0.; | |
4050 | ||
742ee86c | 4051 | GetTracksTiltedwrpJetAxis(TMath::Pi()/2.,fTracksGen, perpjettracklistGen, jet, GetFFRadius() , sumPtGen); // for efficiency: gen tracks perp to gen/rec jet |
cb76764e | 4052 | |
4053 | // here could be your histos !!! | |
4054 | // FillJetTrackRecEffHisto(fFFBckgrPerpHistosRecEffGen,fFFBckgrPerpHistosRecEffRec,sumPtGenLeadingJetRecEff,sumPtRecLeadingJetRecEff,perpjettracklistGen, | |
4055 | // fTracksAODMCCharged,indexAODTr,isGenPrim,fUseRecEffRecJetPtBins); | |
4056 | ||
4057 | delete perpjettracklistGen; | |
4058 | } | |
4059 | } | |
4060 | } | |
2d1d1b60 | 4061 | |
cb76764e | 4062 | // bgr eff: outside N leading jets |
2d1d1b60 | 4063 | |
cb76764e | 4064 | if(0){ |
fe343c6b | 4065 | |
cb76764e | 4066 | Int_t nCases = 1; |
fe343c6b | 4067 | |
cb76764e | 4068 | TList* outjettracklistGen = new TList(); |
4069 | Double_t sumPtGen = 0.; | |
4070 | ||
3af23c82 | 4071 | GetTracksOutOfNJets(nCases, fTracksGen, outjettracklistGen, fJetsRecEff, sumPtGen); // for efficiency: gen tracks outide n gen/rec jets |
cb76764e | 4072 | |
4073 | // here could be your histos !!! | |
4074 | // FillJetTrackRecEffHisto(fFFBckgrOutHistosRecEffGen,fFFBckgrOutHistosRecEffRec,sumPtGenLeadingJetRecEff,sumPtRecLeadingJetRecEff, | |
4075 | // outjettracklistGen,fTracksAODMCCharged,indexAODTr,isGenPrim,fUseRecEffRecJetPtBins); | |
fe343c6b | 4076 | |
cb76764e | 4077 | delete outjettracklistGen; |
fe343c6b | 4078 | } |
cb76764e | 4079 | } |
4080 | ||
fe343c6b | 4081 | //___________________ |
4082 | ||
656dc810 | 4083 | fTracksRec->Clear(); |
4084 | fTracksRecCuts->Clear(); | |
4085 | fTracksGen->Clear(); | |
fe343c6b | 4086 | fTracksAODMCCharged->Clear(); |
4087 | fTracksRecQualityCuts->Clear(); | |
4088 | ||
656dc810 | 4089 | fJetsRec->Clear(); |
4090 | fJetsRecCuts->Clear(); | |
4091 | fJetsGen->Clear(); | |
fe343c6b | 4092 | fJetsRecEff->Clear(); |
656dc810 | 4093 | |
742ee86c | 4094 | if(fBckgMode && |
3170a3f8 | 4095 | (fBckgType[0]==kBckgClusters || fBckgType[1]==kBckgClusters || fBckgType[2]==kBckgClusters || fBckgType[3]==kBckgClusters || fBckgType[4]==kBckgClusters || |
4096 | fBckgType[0]==kBckgClustersOutLeading || fBckgType[1]==kBckgClustersOutLeading || fBckgType[2]==kBckgClustersOutLeading || | |
4097 | fBckgType[3]==kBckgClustersOutLeading || fBckgType[4]==kBckgClustersOutLeading)){ | |
742ee86c | 4098 | |
67e37e80 | 4099 | fBckgJetsRec->Clear(); |
4100 | fBckgJetsRecCuts->Clear(); | |
4101 | fBckgJetsGen->Clear(); | |
4102 | } | |
4103 | ||
656dc810 | 4104 | //Post output data. |
4105 | PostData(1, fCommonHistList); | |
656dc810 | 4106 | } |
4107 | ||
4108 | //________________________________________________________________________________________ | |
fceb275f | 4109 | Double_t AliAnalysisTaskFragmentationFunction::InvMass(const AliAODJet* jet1, const AliAODJet* jet2) |
656dc810 | 4110 | { |
fceb275f | 4111 | // cald DiJet inv mass |
656dc810 | 4112 | |
4113 | Double_t invMass = 0.; | |
4114 | invMass = TMath::Sqrt(pow(jet1->E()+jet2->E(),2) - pow(jet1->Px()+jet2->Px(),2) - | |
4115 | pow(jet1->Py()+jet2->Py(),2) - pow(jet1->Pz()+jet2->Pz(),2)); | |
4116 | ||
4117 | return invMass; | |
4118 | ||
4119 | } | |
4120 | ||
4121 | //________________________________________________________________________________________ | |
4122 | Double_t AliAnalysisTaskFragmentationFunction::GetDiJetBin(Double_t invMass, Double_t leadingJetPt, Double_t EtMean, Int_t kindBins) | |
4123 | { | |
fceb275f | 4124 | // calc DiJet bin according to kindBins parameter |
4125 | ||
656dc810 | 4126 | Double_t jetBinOk = 0.; |
4127 | Double_t jetBin = 0.; | |
4128 | ||
4129 | Float_t stepInvMass = (fDiJetJetInvMassMax - fDiJetJetInvMassMin)/fDiJetNBinsJetInvMass; | |
4130 | Float_t stepPt = (fDiJetJetPtMax - fDiJetJetPtMin)/fDiJetNBinsJetPt; | |
4131 | ||
4132 | if (kindBins == 1) | |
4133 | { | |
4134 | for(Int_t i=0; i<fDiJetNBinsJetInvMass; ++i) | |
4135 | { | |
656457c9 | 4136 | jetBin = fDiJetJetInvMassMin + i*stepInvMass + stepInvMass/2.; |
656dc810 | 4137 | if(((fDiJetJetInvMassMin+i*stepInvMass) <= invMass) && |
190d081e | 4138 | (fDiJetJetInvMassMin + (i+1)*stepInvMass) > invMass) {jetBinOk = jetBin; break;} |
4139 | else jetBinOk = -1.; | |
656dc810 | 4140 | } |
656dc810 | 4141 | } |
4142 | else if (kindBins == 3) | |
4143 | { | |
4144 | for(Int_t i=0; i<fDiJetNBinsJetPt; ++i) | |
4145 | { | |
656457c9 | 4146 | jetBin = fDiJetJetPtMin + i*stepPt + stepPt/2.; |
656dc810 | 4147 | if(((fDiJetJetPtMin+i*stepPt) <= EtMean) && |
190d081e | 4148 | (fDiJetJetPtMin + (i+1)*stepPt) > EtMean) {jetBinOk = jetBin; break;} |
4149 | else jetBinOk = -1.; | |
656dc810 | 4150 | } |
656dc810 | 4151 | } |
4152 | else if (kindBins == 2) | |
4153 | { | |
4154 | for(Int_t i=0; i<fDiJetNBinsJetPt; ++i) | |
4155 | { | |
656457c9 | 4156 | jetBin = fDiJetJetPtMin + i*stepPt + stepPt/2.; |
656dc810 | 4157 | if(((fDiJetJetPtMin+i*stepPt) <= leadingJetPt) && |
190d081e | 4158 | (fDiJetJetPtMin + (i+1)*stepPt) > leadingJetPt) {jetBinOk = jetBin; break;} |
4159 | else jetBinOk = -1.; | |
656dc810 | 4160 | } |
656dc810 | 4161 | } |
4162 | else {Printf("WARNING: kindBins wrongly set ! Please make sure to call SetKindSlices() and set the kind parameter to 1, 2 or 3.\n");} | |
4163 | ||
4164 | return jetBinOk; | |
4165 | ||
4166 | } | |
4167 | ||
4168 | ||
4169 | //______________________________________________________________ | |
4170 | void AliAnalysisTaskFragmentationFunction::Terminate(Option_t *) | |
4171 | { | |
4172 | // terminated | |
4173 | ||
4174 | if(fDebug > 1) printf("AliAnalysisTaskFragmentationFunction::Terminate() \n"); | |
4175 | } | |
4176 | ||
4177 | //_________________________________________________________________________________ | |
4178 | Int_t AliAnalysisTaskFragmentationFunction::GetListOfTracks(TList *list, Int_t type) | |
4179 | { | |
4180 | // fill list of tracks selected according to type | |
4181 | ||
4182 | if(fDebug > 2) Printf("%s:%d Selecting tracks with %d", (char*)__FILE__,__LINE__,type); | |
4183 | ||
4184 | if(!list){ | |
4185 | if(fDebug>1) Printf("%s:%d no input list", (char*)__FILE__,__LINE__); | |
4186 | return -1; | |
4187 | } | |
4188 | ||
ab851c96 | 4189 | if(!fAOD) return -1; |
4190 | ||
3af23c82 | 4191 | if(!fAOD->GetTracks()) return 0; |
4192 | ||
656dc810 | 4193 | if(type==kTrackUndef) return 0; |
4194 | ||
4195 | Int_t iCount = 0; | |
190d081e | 4196 | if(type==kTrackAODCuts || type==kTrackAODQualityCuts || type==kTrackAOD){ |
656dc810 | 4197 | |
4198 | // all rec. tracks, esd filter mask, eta range | |
ab851c96 | 4199 | |
656dc810 | 4200 | |
4201 | for(Int_t it=0; it<fAOD->GetNumberOfTracks(); ++it){ | |
4202 | AliAODTrack *tr = fAOD->GetTrack(it); | |
4203 | ||
190d081e | 4204 | if(type == kTrackAODCuts || type==kTrackAODQualityCuts ){ |
656dc810 | 4205 | if((fFilterMask>0)&&!(tr->TestFilterBit(fFilterMask))) continue; |
190d081e | 4206 | if(type == kTrackAODCuts){ |
4207 | if(tr->Eta() < fTrackEtaMin || tr->Eta() > fTrackEtaMax) continue; | |
4208 | if(tr->Phi() < fTrackPhiMin || tr->Phi() > fTrackPhiMax) continue; | |
4209 | if(tr->Pt() < fTrackPtCut) continue; | |
4210 | } | |
656dc810 | 4211 | } |
4212 | list->Add(tr); | |
4213 | iCount++; | |
4214 | } | |
4215 | } | |
4216 | else if (type==kTrackKineAll || type==kTrackKineCharged || type==kTrackKineChargedAcceptance){ | |
4217 | // kine particles, all or rather charged | |
4218 | if(!fMCEvent) return iCount; | |
4219 | ||
4220 | for(Int_t it=0; it<fMCEvent->GetNumberOfTracks(); ++it){ | |
4221 | AliMCParticle* part = (AliMCParticle*) fMCEvent->GetTrack(it); | |
4222 | ||
4223 | if(type == kTrackKineCharged || type == kTrackKineChargedAcceptance){ | |
4224 | if(part->Charge()==0) continue; | |
4225 | ||
4226 | if(type == kTrackKineChargedAcceptance && | |
4227 | ( part->Eta() < fTrackEtaMin | |
4228 | || part->Eta() > fTrackEtaMax | |
4229 | || part->Phi() < fTrackPhiMin | |
4230 | || part->Phi() > fTrackPhiMax | |
4231 | || part->Pt() < fTrackPtCut)) continue; | |
4232 | } | |
4233 | ||
4234 | list->Add(part); | |
4235 | iCount++; | |
4236 | } | |
4237 | } | |
4238 | else if (type==kTrackAODMCCharged || type==kTrackAODMCAll || type==kTrackAODMCChargedAcceptance) { | |
4239 | // MC particles (from AOD), physical primaries, all or rather charged or rather charged within acceptance | |
4240 | if(!fAOD) return -1; | |
4241 | ||
4242 | TClonesArray *tca = dynamic_cast<TClonesArray*>(fAOD->FindListObject(AliAODMCParticle::StdBranchName())); | |
4243 | if(!tca)return iCount; | |
4244 | ||
4245 | for(int it=0; it<tca->GetEntriesFast(); ++it){ | |
4246 | AliAODMCParticle *part = dynamic_cast<AliAODMCParticle*>(tca->At(it)); | |
ab851c96 | 4247 | if(!part)continue; |
656dc810 | 4248 | if(!part->IsPhysicalPrimary())continue; |
4249 | ||
4250 | if (type==kTrackAODMCCharged || type==kTrackAODMCChargedAcceptance){ | |
4251 | if(part->Charge()==0) continue; | |
4252 | if(type==kTrackAODMCChargedAcceptance && | |
4253 | ( part->Eta() > fTrackEtaMax | |
4254 | || part->Eta() < fTrackEtaMin | |
4255 | || part->Phi() > fTrackPhiMax | |
4256 | || part->Phi() < fTrackPhiMin | |
4257 | || part->Pt() < fTrackPtCut)) continue; | |
4258 | } | |
4259 | ||
4260 | list->Add(part); | |
4261 | iCount++; | |
4262 | } | |
4263 | } | |
4264 | ||
4265 | list->Sort(); | |
4266 | return iCount; | |
4267 | ||
4268 | } | |
4269 | // _______________________________________________________________________________ | |
4270 | Int_t AliAnalysisTaskFragmentationFunction::GetListOfJets(TList *list, Int_t type) | |
4271 | { | |
4272 | // fill list of jets selected according to type | |
3af23c82 | 4273 | |
656dc810 | 4274 | if(!list){ |
4275 | if(fDebug>1) Printf("%s:%d no input list", (char*)__FILE__,__LINE__); | |
4276 | return -1; | |
4277 | } | |
4278 | ||
4279 | if(type == kJetsRec || type == kJetsRecAcceptance){ // reconstructed jets | |
4280 | ||
4281 | if(fBranchRecJets.Length()==0){ | |
4282 | Printf("%s:%d no rec jet branch specified", (char*)__FILE__,__LINE__); | |
4283 | if(fDebug>1)fAOD->Print(); | |
4284 | return 0; | |
4285 | } | |
4286 | ||
cb76764e | 4287 | TClonesArray *aodRecJets = 0; |
40445651 | 4288 | if(fBranchRecJets.Length()) aodRecJets = dynamic_cast<TClonesArray*>(fAOD->FindListObject(fBranchRecJets.Data())); |
4289 | if(fAODExtension&&!aodRecJets) aodRecJets = dynamic_cast<TClonesArray*>(fAODExtension->GetAOD()->FindListObject(fBranchRecJets.Data())); | |
4290 | if(!aodRecJets) aodRecJets = dynamic_cast<TClonesArray*>(fAOD->GetList()->FindObject(fBranchRecJets.Data())); | |
656dc810 | 4291 | |
4292 | if(!aodRecJets){ | |
4293 | if(fBranchRecJets.Length()) Printf("%s:%d no reconstructed jet array with name %s in AOD", (char*)__FILE__,__LINE__,fBranchRecJets.Data()); | |
656dc810 | 4294 | if(fDebug>1)fAOD->Print(); |
4295 | return 0; | |
4296 | } | |
4297 | ||
3af23c82 | 4298 | // Reorder jet pt and fill new temporary AliAODJet objects |
656dc810 | 4299 | Int_t nRecJets = 0; |
4300 | ||
4301 | for(Int_t ij=0; ij<aodRecJets->GetEntries(); ++ij){ | |
4302 | ||
4303 | AliAODJet *tmp = dynamic_cast<AliAODJet*>(aodRecJets->At(ij)); | |
4304 | if(!tmp) continue; | |
3af23c82 | 4305 | |
656dc810 | 4306 | if( tmp->Pt() < fJetPtCut ) continue; |
4307 | if( type == kJetsRecAcceptance && | |
4308 | ( tmp->Eta() < fJetEtaMin | |
4309 | || tmp->Eta() > fJetEtaMax | |
4310 | || tmp->Phi() < fJetPhiMin | |
4311 | || tmp->Phi() > fJetPhiMax )) continue; | |
656dc810 | 4312 | |
44b235ce | 4313 | if(fBckgSubMethod && fBranchRecJets.Contains("B0") && |
3af23c82 | 4314 | fBranchRecJets.Contains("KT")) { |
44b235ce | 4315 | |
3af23c82 | 4316 | AliAODJet *tmpJet = GetAODBckgSubJet(tmp, fBckgSubMethod); |
4317 | ||
4318 | if(!tmpJet) continue; | |
cb76764e | 4319 | |
3af23c82 | 4320 | list->Add(tmpJet); |
44b235ce | 4321 | |
3af23c82 | 4322 | nRecJets++; |
4323 | } | |
4324 | else { | |
4325 | list->Add(tmp); | |
4326 | ||
4327 | nRecJets++; | |
4328 | } | |
4329 | } | |
4330 | ||
4331 | list->Sort(); | |
4332 | ||
656dc810 | 4333 | return nRecJets; |
656dc810 | 4334 | } |
4335 | else if(type == kJetsKine || type == kJetsKineAcceptance){ | |
4336 | ||
4337 | // generated jets | |
4338 | Int_t nGenJets = 0; | |
4339 | ||
4340 | if(!fMCEvent){ | |
4341 | if(fDebug>1) Printf("%s:%d no mcEvent",(char*)__FILE__,__LINE__); | |
4342 | return 0; | |
4343 | } | |
5fde4a38 | 4344 | |
4345 | AliGenEventHeader* genHeader = fMCEvent->GenEventHeader(); | |
4346 | AliGenPythiaEventHeader* pythiaGenHeader = dynamic_cast<AliGenPythiaEventHeader*>(genHeader); | |
4347 | AliGenHijingEventHeader* hijingGenHeader = 0x0; | |
4348 | ||
656dc810 | 4349 | if(!pythiaGenHeader){ |
5fde4a38 | 4350 | hijingGenHeader = dynamic_cast<AliGenHijingEventHeader*>(genHeader); |
4351 | ||
4352 | if(!hijingGenHeader){ | |
4353 | Printf("%s:%d no pythiaGenHeader or hijingGenHeader found", (char*)__FILE__,__LINE__); | |
4354 | return 0; | |
4355 | }else{ | |
4356 | TLorentzVector mom[4]; | |
4357 | AliAODJet* jet[4]; | |
4358 | hijingGenHeader->GetJets(mom[0], mom[1], mom[2], mom[3]); | |
4359 | ||
4360 | for(Int_t i=0; i<2; ++i){ | |
4361 | if(!mom[i].Pt()) continue; | |
4362 | jet[i] = new AliAODJet(mom[i]); | |
4363 | ||
4364 | if( type == kJetsKineAcceptance && | |
4365 | ( jet[i]->Eta() < fJetEtaMin | |
4366 | || jet[i]->Eta() > fJetEtaMax | |
4367 | || jet[i]->Phi() < fJetPhiMin | |
4368 | || jet[i]->Phi() > fJetPhiMax )) continue; | |
4369 | ||
4370 | list->Add(jet[i]); | |
4371 | nGenJets++; | |
4372 | } | |
4373 | list->Sort(); | |
4374 | return nGenJets; | |
4375 | } | |
656dc810 | 4376 | } |
4377 | ||
4378 | // fetch the pythia generated jets | |
4379 | for(int ip=0; ip<pythiaGenHeader->NTriggerJets(); ++ip){ | |
4380 | ||
4381 | Float_t p[4]; | |
4382 | AliAODJet *jet = new AliAODJet(); | |
4383 | pythiaGenHeader->TriggerJet(ip, p); | |
4384 | jet->SetPxPyPzE(p[0], p[1], p[2], p[3]); | |
4385 | ||
4386 | if( type == kJetsKineAcceptance && | |
4387 | ( jet->Eta() < fJetEtaMin | |
4388 | || jet->Eta() > fJetEtaMax | |
4389 | || jet->Phi() < fJetPhiMin | |
4390 | || jet->Phi() > fJetPhiMax )) continue; | |
4391 | ||
3af23c82 | 4392 | list->Add(jet); |
4393 | nGenJets++; | |
656dc810 | 4394 | } |
4395 | list->Sort(); | |
4396 | return nGenJets; | |
4397 | } | |
4398 | else if(type == kJetsGen || type == kJetsGenAcceptance ){ | |
4399 | ||
4400 | if(fBranchGenJets.Length()==0){ | |
4401 | if(fDebug>1) Printf("%s:%d no gen jet branch specified", (char*)__FILE__,__LINE__); | |
4402 | return 0; | |
4403 | } | |
4404 | ||
cb76764e | 4405 | TClonesArray *aodGenJets = 0; |
3af23c82 | 4406 | if(fBranchGenJets.Length()) aodGenJets = dynamic_cast<TClonesArray*>(fAOD->FindListObject(fBranchGenJets.Data())); |
4407 | if(!aodGenJets) aodGenJets = dynamic_cast<TClonesArray*>(fAOD->GetList()->FindObject(fBranchGenJets.Data())); | |
40445651 | 4408 | if(fAODExtension&&!aodGenJets) aodGenJets = dynamic_cast<TClonesArray*>(fAODExtension->GetAOD()->FindListObject(fBranchGenJets.Data())); |
656dc810 | 4409 | |
4410 | if(!aodGenJets){ | |
4411 | if(fDebug>0){ | |
4412 | if(fBranchGenJets.Length()) Printf("%s:%d Generated jet branch %s not found",(char*)__FILE__,__LINE__,fBranchGenJets.Data()); | |
4413 | } | |
4414 | if(fDebug>1)fAOD->Print(); | |
4415 | return 0; | |
4416 | } | |
4417 | ||
4418 | Int_t nGenJets = 0; | |
4419 | ||
4420 | for(Int_t ig=0; ig<aodGenJets->GetEntries(); ++ig){ | |
4421 | ||
4422 | AliAODJet *tmp = dynamic_cast<AliAODJet*>(aodGenJets->At(ig)); | |
4423 | if(!tmp) continue; | |
4424 | ||
4425 | if( tmp->Pt() < fJetPtCut ) continue; | |
4426 | if( type == kJetsGenAcceptance && | |
4427 | ( tmp->Eta() < fJetEtaMin | |
4428 | || tmp->Eta() > fJetEtaMax | |
4429 | || tmp->Phi() < fJetPhiMin | |
4430 | || tmp->Phi() > fJetPhiMax )) continue; | |
4431 | ||
3af23c82 | 4432 | list->Add(tmp); |
4433 | nGenJets++; | |
656dc810 | 4434 | } |
4435 | list->Sort(); | |
4436 | return nGenJets; | |
656dc810 | 4437 | } |
4438 | else{ | |
4439 | if(fDebug>0)Printf("%s:%d no such type %d",(char*)__FILE__,__LINE__,type); | |
4440 | return 0; | |
4441 | } | |
4442 | } | |
4443 | ||
742ee86c | 4444 | // ___________________________________________________________________________________ |
4445 | Int_t AliAnalysisTaskFragmentationFunction::GetListOfBckgJets(TList *list, Int_t type) | |
656dc810 | 4446 | { |
742ee86c | 4447 | // fill list of bgr clusters selected according to type |
656dc810 | 4448 | |
742ee86c | 4449 | if(type == kJetsRec || type == kJetsRecAcceptance){ // reconstructed jets |
67e37e80 | 4450 | |
742ee86c | 4451 | if(fBranchRecBckgClusters.Length()==0){ |
4452 | Printf("%s:%d no rec jet branch specified", (char*)__FILE__,__LINE__); | |
4453 | if(fDebug>1)fAOD->Print(); | |
4454 | return 0; | |
4455 | } | |
4456 | ||
4457 | TClonesArray *aodRecJets = 0; | |
4458 | if(fBranchRecBckgClusters.Length()) aodRecJets = dynamic_cast<TClonesArray*>(fAOD->FindListObject(fBranchRecBckgClusters.Data())); | |
4459 | if(!aodRecJets) aodRecJets = dynamic_cast<TClonesArray*>(fAOD->GetList()->FindObject(fBranchRecBckgClusters.Data())); | |
40445651 | 4460 | if(fAODExtension&&!aodRecJets) aodRecJets = dynamic_cast<TClonesArray*>(fAODExtension->GetAOD()->FindListObject(fBranchRecBckgClusters.Data())); |
4461 | ||
742ee86c | 4462 | if(!aodRecJets){ |
4463 | if(fBranchRecBckgClusters.Length()) Printf("%s:%d no reconstructed jet array with name %s in AOD", (char*)__FILE__,__LINE__,fBranchRecBckgClusters.Data()); | |
4464 | if(fDebug>1)fAOD->Print(); | |
4465 | return 0; | |
4466 | } | |
4467 | ||
4468 | // Reorder jet pt and fill new temporary AliAODJet objects | |
4469 | Int_t nRecJets = 0; | |
4470 | ||
4471 | for(Int_t ij=0; ij<aodRecJets->GetEntries(); ++ij){ | |
4472 | ||
4473 | AliAODJet *tmp = dynamic_cast<AliAODJet*>(aodRecJets->At(ij)); | |
4474 | if(!tmp) continue; | |
4475 | ||
4476 | // if( tmp->Pt() < fJetPtCut ) continue; // no pt cut on bckg clusters ! | |
4477 | if( type == kJetsRecAcceptance && | |
4478 | ( tmp->Eta() < fJetEtaMin | |
4479 | || tmp->Eta() > fJetEtaMax | |
4480 | || tmp->Phi() < fJetPhiMin | |
4481 | || tmp->Phi() > fJetPhiMax )) continue; | |
4482 | ||
4483 | list->Add(tmp); | |
4484 | ||
4485 | nRecJets++; | |
4486 | ||
4487 | } | |
4488 | ||
4489 | list->Sort(); | |
4490 | ||
4491 | return nRecJets; | |
4492 | } | |
656dc810 | 4493 | |
742ee86c | 4494 | // /* |
4495 | // MC clusters still Under construction | |
4496 | // */ | |
4497 | ||
4498 | return 0; | |
3af23c82 | 4499 | } |
67e37e80 | 4500 | |
3af23c82 | 4501 | // _________________________________________________________________________________________________________ |
4502 | void AliAnalysisTaskFragmentationFunction::SetProperties(THnSparse* h,const Int_t dim, const char** labels) | |
4503 | { | |
4504 | // Set properties of THnSparse | |
67e37e80 | 4505 | |
3af23c82 | 4506 | for(Int_t i=0; i<dim; i++){ |
4507 | h->GetAxis(i)->SetTitle(labels[i]); | |
4508 | h->GetAxis(i)->SetTitleColor(1); | |
4509 | } | |
4510 | } | |
67e37e80 | 4511 | |
656dc810 | 4512 | // __________________________________________________________________________________________ |
4513 | void AliAnalysisTaskFragmentationFunction::SetProperties(TH1* h,const char* x, const char* y) | |
4514 | { | |
4515 | //Set properties of histos (x and y title) | |
4516 | ||
4517 | h->SetXTitle(x); | |
4518 | h->SetYTitle(y); | |
4519 | h->GetXaxis()->SetTitleColor(1); | |
4520 | h->GetYaxis()->SetTitleColor(1); | |
4521 | } | |
4522 | ||
4523 | // _________________________________________________________________________________________________________ | |
67e37e80 | 4524 | void AliAnalysisTaskFragmentationFunction::SetProperties(TH1* h,const char* x, const char* y, const char* z) |
656dc810 | 4525 | { |
4526 | //Set properties of histos (x,y and z title) | |
4527 | ||
4528 | h->SetXTitle(x); | |
4529 | h->SetYTitle(y); | |
4530 | h->SetZTitle(z); | |
4531 | h->GetXaxis()->SetTitleColor(1); | |
4532 | h->GetYaxis()->SetTitleColor(1); | |
4533 | h->GetZaxis()->SetTitleColor(1); | |
4534 | } | |
4535 | ||
4536 | // ________________________________________________________________________________________________________________________________________________________ | |
fceb275f | 4537 | void AliAnalysisTaskFragmentationFunction::GetJetTracksPointing(TList* inputlist, TList* outputlist, const AliAODJet* jet, const Double_t radius,Double_t& sumPt) |
656dc810 | 4538 | { |
4539 | // fill list of tracks in cone around jet axis | |
4540 | ||
4541 | sumPt = 0; | |
4542 | ||
4543 | Double_t jetMom[3]; | |
4544 | jet->PxPyPz(jetMom); | |
4545 | TVector3 jet3mom(jetMom); | |
4546 | ||
4547 | for (Int_t itrack=0; itrack<inputlist->GetSize(); itrack++){ | |
4548 | ||
4549 | AliVParticle* track = dynamic_cast<AliVParticle*>(inputlist->At(itrack)); | |
ab851c96 | 4550 | if(!track)continue; |
656dc810 | 4551 | Double_t trackMom[3]; |
4552 | track->PxPyPz(trackMom); | |
4553 | TVector3 track3mom(trackMom); | |
4554 | ||
4555 | Double_t dR = jet3mom.DeltaR(track3mom); | |
4556 | ||
4557 | if(dR<radius){ | |
4558 | ||
4559 | outputlist->Add(track); | |
4560 | ||
4561 | sumPt += track->Pt(); | |
4562 | } | |
4563 | } | |
4564 | ||
4565 | outputlist->Sort(); | |
4566 | } | |
4567 | ||
4568 | // ___________________________________________________________________________________________ | |
fceb275f | 4569 | void AliAnalysisTaskFragmentationFunction::GetJetTracksTrackrefs(TList* list, const AliAODJet* jet) |
656dc810 | 4570 | { |
4571 | // list of jet tracks from trackrefs | |
4572 | ||
4573 | Int_t nTracks = jet->GetRefTracks()->GetEntriesFast(); | |
4574 | ||
4575 | for (Int_t itrack=0; itrack<nTracks; itrack++) { | |
4576 | ||
4577 | AliVParticle* track = dynamic_cast<AliVParticle*>(jet->GetRefTracks()->At(itrack)); | |
4578 | if(!track){ | |
4579 | AliError("expected ref track not found "); | |
4580 | continue; | |
4581 | } | |
4582 | ||
4583 | list->Add(track); | |
4584 | } | |
4585 | ||
4586 | list->Sort(); | |
4587 | } | |
fe343c6b | 4588 | |
4589 | // _ ________________________________________________________________________________________________________________________________ | |
4590 | void AliAnalysisTaskFragmentationFunction::AssociateGenRec(TList* tracksAODMCCharged,TList* tracksRec, TArrayI& indexAODTr,TArrayI& indexMCTr,TArrayS& isGenPrim) | |
4591 | { | |
4592 | // associate generated and reconstructed tracks, fill TArrays of list indices | |
4593 | ||
4594 | ||
4595 | Int_t nTracksRec = tracksRec->GetSize(); | |
4596 | Int_t nTracksGen = tracksAODMCCharged->GetSize(); | |
4597 | TClonesArray *tca = dynamic_cast<TClonesArray*>(fAOD->FindListObject(AliAODMCParticle::StdBranchName())); | |
4598 | ||
4599 | if(!nTracksGen) return; | |
4600 | if(!tca) return; | |
4601 | ||
4602 | // set size | |
4603 | indexAODTr.Set(nTracksGen); | |
4604 | indexMCTr.Set(nTracksRec); | |
4605 | isGenPrim.Set(nTracksGen); | |
4606 | ||
4607 | indexAODTr.Reset(-1); | |
4608 | indexMCTr.Reset(-1); | |
4609 | isGenPrim.Reset(0); | |
4610 | ||
4611 | // loop over reconstructed tracks, get generated track | |
4612 | ||
4613 | for(Int_t iRec=0; iRec<nTracksRec; iRec++){ | |
4614 | ||
4615 | AliAODTrack* rectrack = dynamic_cast<AliAODTrack*>(tracksRec->At(iRec)); | |
ab851c96 | 4616 | if(!rectrack)continue; |
289a2293 | 4617 | Int_t label = TMath::Abs(rectrack->GetLabel()); |
fe343c6b | 4618 | |
4619 | // find MC track in our list | |
cb76764e | 4620 | AliAODMCParticle* gentrack = dynamic_cast<AliAODMCParticle*> (tca->At(label)); |
ab851c96 | 4621 | |
fe343c6b | 4622 | Int_t listIndex = -1; |
4623 | if(gentrack) listIndex = tracksAODMCCharged->IndexOf(gentrack); | |
4624 | ||
4625 | if(listIndex>=0){ | |
4626 | ||
4627 | indexAODTr[listIndex] = iRec; | |
4628 | indexMCTr[iRec] = listIndex; | |
4629 | } | |
4630 | } | |
4631 | ||
4632 | ||
4633 | // define primary sample for reconstruction efficiency | |
4634 | ||
4635 | for(Int_t iGen=0; iGen<nTracksGen; iGen++){ | |
4636 | ||
4637 | AliAODMCParticle* gentrack = dynamic_cast<AliAODMCParticle*> (tracksAODMCCharged->At(iGen)); | |
ab851c96 | 4638 | if(!gentrack)continue; |
fe343c6b | 4639 | Int_t pdg = gentrack->GetPdgCode(); |
4640 | ||
4641 | // 211 - pi, 2212 - proton, 321 - Kaon, 11 - electron, 13 - muon | |
4642 | if(TMath::Abs(pdg) == 211 || TMath::Abs(pdg) == 2212 || TMath::Abs(pdg) == 321 || | |
4643 | TMath::Abs(pdg) == 11 || TMath::Abs(pdg) == 13){ | |
4644 | ||
4645 | isGenPrim[iGen] = kTRUE; | |
cb76764e | 4646 | |
4647 | Int_t iRec = indexAODTr[iGen]; // can be -1 if no good reconstructed track | |
4648 | ||
4649 | if(iRec>=0){ | |
4650 | Float_t genPt = gentrack->Pt(); | |
ab851c96 | 4651 | AliAODTrack* vt = dynamic_cast<AliAODTrack*>(tracksRec->At(iRec)); |
4652 | if(vt){ | |
4653 | Float_t recPt = vt->Pt(); | |
4654 | fh2PtRecVsGenPrim->Fill(genPt,recPt); | |
4655 | } | |
cb76764e | 4656 | } |
fe343c6b | 4657 | } |
4658 | } | |
4659 | } | |
4660 | ||
4661 | // _____________________________________________________________________________________________________________________________________________ | |
cb76764e | 4662 | void AliAnalysisTaskFragmentationFunction::FillSingleTrackRecEffHisto(AliFragFuncQATrackHistos* trackQAGen, AliFragFuncQATrackHistos* trackQARec, TList* tracksGen, |
fceb275f | 4663 | const TArrayI& indexAODTr, const TArrayS& isGenPrim){ |
fe343c6b | 4664 | |
cb76764e | 4665 | // fill QA for single track reconstruction efficiency |
fceb275f | 4666 | |
fe343c6b | 4667 | Int_t nTracksGen = tracksGen->GetSize(); |
4668 | ||
4669 | if(!nTracksGen) return; | |
4670 | ||
4671 | for(Int_t iGen=0; iGen<nTracksGen; iGen++){ | |
4672 | ||
4673 | if(isGenPrim[iGen] != 1) continue; // select primaries | |
4674 | ||
4675 | AliAODMCParticle* gentrack = dynamic_cast<AliAODMCParticle*> (tracksGen->At(iGen)); | |
1ea145ef | 4676 | if(!gentrack)continue; |
fe343c6b | 4677 | Double_t ptGen = gentrack->Pt(); |
4678 | Double_t etaGen = gentrack->Eta(); | |
4679 | Double_t phiGen = TVector2::Phi_0_2pi(gentrack->Phi()); | |
4680 | ||
4681 | // apply same acc & pt cuts as for FF | |
fe343c6b | 4682 | |
4683 | if(etaGen < fTrackEtaMin || etaGen > fTrackEtaMax) continue; | |
4684 | if(phiGen < fTrackPhiMin || phiGen > fTrackPhiMax) continue; | |
4685 | if(ptGen < fTrackPtCut) continue; | |
4686 | ||
cb76764e | 4687 | trackQAGen->FillTrackQA(etaGen, phiGen, ptGen); |
fe343c6b | 4688 | |
cb76764e | 4689 | Int_t iRec = indexAODTr[iGen]; // can be -1 if no good reconstructed track |
4690 | if(iRec>=0) trackQARec->FillTrackQA(etaGen, phiGen, ptGen); | |
fe343c6b | 4691 | } |
4692 | } | |
4693 | ||
4694 | // ______________________________________________________________________________________________________________________________________________________ | |
cb76764e | 4695 | void AliAnalysisTaskFragmentationFunction::FillJetTrackRecEffHisto(TObject* histGen, TObject* histRec, Double_t jetPtGen, Double_t jetPtRec, TList* jetTrackList, |
3af23c82 | 4696 | const TList* tracksGen, const TArrayI& indexAODTr, const TArrayS& isGenPrim, const Bool_t useRecJetPt) |
fe343c6b | 4697 | { |
cb76764e | 4698 | |
4699 | // fill objects for jet track reconstruction efficiency | |
3af23c82 | 4700 | // arguments histGen/histRec can be of different type: AliFragFuncHistos*, AliFragFuncIntraJetHistos*, ... |
fe343c6b | 4701 | |
4702 | Int_t nTracksJet = jetTrackList->GetSize(); // list with AODMC tracks | |
4703 | ||
4704 | if(!nTracksJet) return; | |
4705 | ||
cb76764e | 4706 | Bool_t incrementJetPtGenFF = kTRUE; // needed in case we fill FFHistos |
4707 | Bool_t incrementJetPtRecFF = kTRUE; // needed in case we fill FFHistos | |
4708 | ||
fe343c6b | 4709 | for(Int_t iTr=0; iTr<nTracksJet; iTr++){ |
4710 | ||
4711 | AliAODMCParticle* gentrack = dynamic_cast<AliAODMCParticle*> (jetTrackList->At(iTr)); | |
ab851c96 | 4712 | if(!gentrack)continue; |
fe343c6b | 4713 | // find jet track in gen tracks list |
4714 | Int_t iGen = tracksGen->IndexOf(gentrack); | |
4715 | ||
4716 | if(iGen<0){ | |
4717 | if(fDebug>0) Printf("%s:%d gen jet track not found ",(char*)__FILE__,__LINE__); | |
4718 | continue; | |
4719 | } | |
4720 | ||
4721 | if(isGenPrim[iGen] != 1) continue; // select primaries | |
4722 | ||
4723 | Double_t ptGen = gentrack->Pt(); | |
4724 | Double_t etaGen = gentrack->Eta(); | |
4725 | Double_t phiGen = TVector2::Phi_0_2pi(gentrack->Phi()); | |
4726 | ||
4727 | // apply same acc & pt cuts as for FF | |
fe343c6b | 4728 | |
4729 | if(etaGen < fTrackEtaMin || etaGen > fTrackEtaMax) continue; | |
4730 | if(phiGen < fTrackPhiMin || phiGen > fTrackPhiMax) continue; | |
4731 | if(ptGen < fTrackPtCut) continue; | |
4732 | ||
2d1d1b60 | 4733 | Double_t z = ptGen / jetPtGen; |
fe343c6b | 4734 | Double_t xi = 0; |
4735 | if(z>0) xi = TMath::Log(1/z); | |
4736 | ||
cb76764e | 4737 | Int_t iRec = indexAODTr[iGen]; // can be -1 if no good reconstructed track |
4738 | Bool_t isRec = (iRec>=0) ? kTRUE : kFALSE; | |
4739 | ||
4740 | if(dynamic_cast<AliFragFuncHistos*>(histGen) && dynamic_cast<AliFragFuncHistos*>(histRec)){ | |
4741 | ||
ab851c96 | 4742 | // after checking can afford normal cast |
4743 | AliFragFuncHistos* effFFhistGen = (AliFragFuncHistos*)(histGen); | |
4744 | AliFragFuncHistos* effFFhistRec = (AliFragFuncHistos*)(histRec); | |
cb76764e | 4745 | |
4746 | if(useRecJetPt) effFFhistGen->FillFF( ptGen, jetPtRec, incrementJetPtGenFF ); | |
4747 | else effFFhistGen->FillFF( ptGen, jetPtGen, incrementJetPtGenFF ); | |
4748 | ||
4749 | incrementJetPtGenFF = kFALSE; | |
fe343c6b | 4750 | |
cb76764e | 4751 | if(isRec){ |
4752 | if(useRecJetPt) effFFhistRec->FillFF( ptGen, jetPtRec, incrementJetPtRecFF ); | |
4753 | else effFFhistRec->FillFF( ptGen, jetPtGen, incrementJetPtRecFF ); | |
4754 | ||
4755 | incrementJetPtRecFF = kFALSE; | |
4756 | } | |
4757 | } | |
4758 | else if(dynamic_cast<AliFragFuncIntraJetHistos*>(histGen) && dynamic_cast<AliFragFuncIntraJetHistos*>(histRec)){ | |
4759 | ||
4760 | // eff for IJ histos ... | |
4761 | ||
4762 | } | |
fe343c6b | 4763 | } |
4764 | } | |
1da9498b | 4765 | |
3af23c82 | 4766 | |
4767 | // _____________________________________________________________________________________________________________________________________________ | |
4768 | void AliAnalysisTaskFragmentationFunction::FillSingleTrackResponse(THnSparse* hnResponse, TList* tracksGen, TList* tracksRec, | |
4769 | const TArrayI& indexAODTr, const TArrayS& isGenPrim) | |
4770 | { | |
4771 | // fill response matrix for single tracks | |
4772 | ||
4773 | ||
4774 | Int_t nTracksGen = tracksGen->GetSize(); | |
4775 | ||
4776 | if(!nTracksGen) return; | |
4777 | ||
4778 | for(Int_t iGen=0; iGen<nTracksGen; iGen++){ | |
4779 | ||
4780 | if(isGenPrim[iGen] != 1) continue; // select primaries | |
4781 | ||
4782 | AliAODMCParticle* gentrack = dynamic_cast<AliAODMCParticle*> (tracksGen->At(iGen)); | |
ab851c96 | 4783 | if(!gentrack)continue; |
3af23c82 | 4784 | Double_t ptGen = gentrack->Pt(); |
4785 | Double_t etaGen = gentrack->Eta(); | |
4786 | Double_t phiGen = TVector2::Phi_0_2pi(gentrack->Phi()); | |
4787 | ||
4788 | // apply same acc & pt cuts as for FF | |
4789 | if(etaGen < fTrackEtaMin || etaGen > fTrackEtaMax) continue; | |
4790 | if(phiGen < fTrackPhiMin || phiGen > fTrackPhiMax) continue; | |
4791 | if(ptGen < fTrackPtCut) continue; | |
4792 | ||
4793 | Int_t iRec = indexAODTr[iGen]; // can be -1 if no good reconstructed track | |
4794 | if(iRec>=0){ | |
4795 | AliAODTrack* rectrack = dynamic_cast<AliAODTrack*>(tracksRec->At(iRec)); | |
ab851c96 | 4796 | if(!rectrack)continue; |
3af23c82 | 4797 | Double_t ptRec = rectrack->Pt(); |
4798 | ||
4799 | Double_t entries[2] = {ptRec,ptGen}; // AliCorrFW convention: gen vs rec | |
4800 | hnResponse->Fill(entries); | |
4801 | } | |
4802 | } | |
4803 | } | |
4804 | ||
4805 | ||
4806 | // ______________________________________________________________________________________________________________________________________________________ | |
4807 | void AliAnalysisTaskFragmentationFunction::FillJetTrackResponse(THnSparse* hnResponsePt, THnSparse* hnResponseZ, THnSparse* hnResponseXi, | |
4808 | Double_t jetPtGen, Double_t jetPtRec, TList* jetTrackList, | |
4809 | const TList* tracksGen, TList* tracksRec, const TArrayI& indexAODTr, const TArrayS& isGenPrim,const Bool_t useRecJetPt) | |
4810 | { | |
4811 | // fill response matrix for tracks in jets | |
4812 | ||
4813 | Int_t nTracksJet = jetTrackList->GetSize(); // list with AODMC tracks | |
4814 | ||
4815 | if(!nTracksJet) return; | |
4816 | ||
4817 | for(Int_t iTr=0; iTr<nTracksJet; iTr++){ | |
4818 | ||
4819 | AliAODMCParticle* gentrack = dynamic_cast<AliAODMCParticle*> (jetTrackList->At(iTr)); | |
ab851c96 | 4820 | if(!gentrack)continue; |
3af23c82 | 4821 | // find jet track in gen tracks list |
4822 | Int_t iGen = tracksGen->IndexOf(gentrack); | |
4823 | ||
4824 | if(iGen<0){ | |
4825 | if(fDebug>0) Printf("%s:%d gen jet track not found ",(char*)__FILE__,__LINE__); | |
4826 | continue; | |
4827 | } | |
4828 | ||
4829 | if(isGenPrim[iGen] != 1) continue; // select primaries | |
4830 | ||
4831 | Double_t ptGen = gentrack->Pt(); | |
4832 | Double_t etaGen = gentrack->Eta(); | |
4833 | Double_t phiGen = TVector2::Phi_0_2pi(gentrack->Phi()); | |
4834 | ||
4835 | // apply same acc & pt cuts as for FF | |
4836 | ||
4837 | if(etaGen < fTrackEtaMin || etaGen > fTrackEtaMax) continue; | |
4838 | if(phiGen < fTrackPhiMin || phiGen > fTrackPhiMax) continue; | |
4839 | if(ptGen < fTrackPtCut) continue; | |
4840 | ||
742ee86c | 4841 | Double_t zGen = ptGen / jetPtRec; |
3af23c82 | 4842 | Double_t xiGen = 0; |
4843 | if(zGen>0) xiGen = TMath::Log(1/zGen); | |
4844 | ||
4845 | Int_t iRec = indexAODTr[iGen]; // can be -1 if no good reconstructed track | |
4846 | ||
4847 | if(iRec>=0){ | |
4848 | ||
4849 | AliAODTrack* rectrack = dynamic_cast<AliAODTrack*>(tracksRec->At(iRec)); | |
ab851c96 | 4850 | if(rectrack){ |
4851 | Double_t ptRec = rectrack->Pt(); | |
4852 | ||
742ee86c | 4853 | Double_t zRec = ptRec / jetPtRec; |
ab851c96 | 4854 | Double_t xiRec = 0; |
4855 | if(zRec>0) xiRec = TMath::Log(1/zRec); | |
3af23c82 | 4856 | |
ab851c96 | 4857 | Double_t jetPt = useRecJetPt ? jetPtRec : jetPtGen; |
4858 | ||
4859 | Double_t entriesPt[3] = {jetPt,ptRec,ptGen}; // AliCorrFW convention: gen vs rec | |
4860 | Double_t entriesZ[3] = {jetPt,zRec,zGen}; | |
4861 | Double_t entriesXi[3] = {jetPt,xiRec,xiGen}; | |
4862 | ||
4863 | hnResponsePt->Fill(entriesPt); | |
4864 | hnResponseZ->Fill(entriesZ); | |
4865 | hnResponseXi->Fill(entriesXi); | |
4866 | } | |
3af23c82 | 4867 | } |
4868 | } | |
4869 | } | |
4870 | ||
4871 | // _____________________________________________________________________________________________________________________________________________________________________ | |
4872 | void AliAnalysisTaskFragmentationFunction::GetTracksTiltedwrpJetAxis(Float_t alpha, TList* inputlist, TList* outputlist, AliAODJet* jet, Double_t radius,Double_t& sumPt) | |
1da9498b | 4873 | { |
4874 | // List of tracks in cone perpendicular to the jet azimuthal direction | |
4875 | ||
4876 | Double_t jetMom[3]; | |
4877 | jet->PxPyPz(jetMom); | |
67e37e80 | 4878 | |
1da9498b | 4879 | TVector3 jet3mom(jetMom); |
4880 | // Rotate phi and keep eta unchanged | |
3af23c82 | 4881 | Double_t etaTilted = jet3mom.Eta(); |
4882 | Double_t phiTilted = TVector2::Phi_0_2pi(jet3mom.Phi()) + alpha; | |
4883 | if(phiTilted > 2*TMath::Pi()) phiTilted = phiTilted - 2*TMath::Pi(); | |
1da9498b | 4884 | |
4885 | for (Int_t itrack=0; itrack<inputlist->GetSize(); itrack++){ | |
4886 | ||
4887 | AliVParticle* track = dynamic_cast<AliVParticle*>(inputlist->At(itrack)); | |
ab851c96 | 4888 | if(!track)continue; |
1da9498b | 4889 | Double_t trackMom[3]; |
4890 | track->PxPyPz(trackMom); | |
4891 | TVector3 track3mom(trackMom); | |
4892 | ||
3af23c82 | 4893 | Double_t deta = track3mom.Eta() - etaTilted; |
4894 | Double_t dphi = TMath::Abs(track3mom.Phi() - phiTilted); | |
4895 | if (dphi > TMath::Pi()) dphi = 2. * TMath::Pi() - dphi; | |
4896 | Double_t dR = TMath::Sqrt(deta * deta + dphi * dphi); | |
4897 | ||
1da9498b | 4898 | if(dR<=radius){ |
4899 | outputlist->Add(track); | |
4900 | sumPt += track->Pt(); | |
4901 | } | |
4902 | } | |
4903 | ||
4904 | } | |
4905 | ||
4906 | // ________________________________________________________________________________________________________________________________________________________ | |
3af23c82 | 4907 | void AliAnalysisTaskFragmentationFunction::GetTracksTiltedwrpJetAxisWindow(Float_t alpha, TList* inputlist, TList* outputlist, AliAODJet* jet, Double_t radius,Double_t& sumPt,Double_t &normFactor) |
4908 | { | |
4909 | // List of tracks in cone perpendicular to the jet azimuthal direction | |
4910 | ||
4911 | Double_t jetMom[3]; | |
4912 | jet->PxPyPz(jetMom); | |
4913 | ||
4914 | TVector3 jet3mom(jetMom); | |
4915 | // Rotate phi and keep eta unchanged | |
4916 | Double_t etaTilted = jet3mom.Eta(); | |
4917 | Double_t phiTilted = TVector2::Phi_0_2pi(jet3mom.Phi()) + alpha; | |
4918 | if(phiTilted > 2*TMath::Pi()) phiTilted = phiTilted - 2*TMath::Pi(); | |
4919 | ||
4920 | for (Int_t itrack=0; itrack<inputlist->GetSize(); itrack++) | |
4921 | { | |
ab851c96 | 4922 | |
3af23c82 | 4923 | AliVParticle* track = dynamic_cast<AliVParticle*>(inputlist->At(itrack)); |
ab851c96 | 4924 | if(!track)continue; |
3af23c82 | 4925 | Float_t trackEta = track->Eta(); |
4926 | Float_t trackPhi = track->Phi(); | |
4927 | ||
942bf1b4 | 4928 | if( ( phiTilted-radius >= 0 ) && ( phiTilted+radius <= 2*TMath::Pi())) |
3af23c82 | 4929 | { |
4930 | if((trackPhi<=phiTilted+radius) && | |
4931 | (trackPhi>=phiTilted-radius) && | |
942bf1b4 | 4932 | (trackEta<=fTrackEtaMax)&&(trackEta>=fTrackEtaMin)) // 0.9 and - 0.9 |
3af23c82 | 4933 | { |
4934 | outputlist->Add(track); | |
4935 | sumPt += track->Pt(); | |
4936 | } | |
4937 | } | |
4938 | else if( phiTilted-radius < 0 ) | |
4939 | { | |
4940 | if((( trackPhi < phiTilted+radius ) || | |
4941 | ( trackPhi > 2*TMath::Pi()-(radius-phiTilted) )) && | |
4942 | (( trackEta <= fTrackEtaMax ) && ( trackEta >= fTrackEtaMin ))) | |
4943 | { | |
4944 | outputlist->Add(track); | |
4945 | sumPt += track->Pt(); | |
4946 | } | |
4947 | } | |
4948 | else if( phiTilted+radius > 2*TMath::Pi() ) | |
4949 | { | |
4950 | if((( trackPhi > phiTilted-radius ) || | |
942bf1b4 | 4951 | ( trackPhi < phiTilted+radius-2*TMath::Pi() )) && |
3af23c82 | 4952 | (( trackEta <= fTrackEtaMax ) && ( trackEta >= fTrackEtaMin ))) |
4953 | { | |
4954 | outputlist->Add(track); | |
4955 | sumPt += track->Pt(); | |
4956 | } | |
4957 | } | |
4958 | } | |
4959 | ||
4960 | // Jet area - Temporarily added should be modified with the proper jet area value | |
4961 | Float_t areaJet = CalcJetArea(etaTilted,radius); | |
4962 | Float_t areaTilted = 2*radius*(fTrackEtaMax-fTrackEtaMin); | |
4963 | ||
4964 | normFactor = (Float_t) 1. / (areaJet / areaTilted); | |
4965 | ||
4966 | } | |
4967 | ||
4968 | ||
4969 | // ________________________________________________________________________________________________________________________________________________________ | |
4970 | void AliAnalysisTaskFragmentationFunction::GetTracksOutOfNJets(Int_t nCases, TList* inputlist, TList* outputlist, TList* jetlist, Double_t& sumPt) | |
1da9498b | 4971 | { |
4972 | // List of tracks outside cone around N jet axis | |
4973 | // Particles taken randomly | |
4974 | ||
4975 | sumPt = 0; | |
4976 | // Int_t nj = jetlist->GetSize(); | |
4977 | Float_t rc = GetFFRadius(); | |
4978 | Float_t rcl = GetFFBckgRadius(); | |
4979 | ||
4980 | // Estimate jet and background areas | |
4981 | Float_t* areaJet = new Float_t[nCases]; | |
ab851c96 | 4982 | memset(areaJet, 0, sizeof(Float_t) * nCases); |
1da9498b | 4983 | Float_t* areaJetLarge = new Float_t[nCases]; |
ab851c96 | 4984 | memset(areaJetLarge, 0, sizeof(Float_t) * nCases); |
1da9498b | 4985 | Float_t areaFull = (fTrackEtaMax-fTrackEtaMin)*(fTrackPhiMax-fTrackPhiMin); |
4986 | Float_t areaOut = areaFull; | |
4987 | ||
4988 | //estimate jets and background areas | |
4989 | Int_t nOut = 0; | |
4990 | Int_t ijet = 0; | |
4991 | TList* templist = new TList(); | |
4992 | TClonesArray *vect3Jet = new TClonesArray("TVector3",nCases); | |
4993 | ||
4994 | for(Int_t ij=0; ij<nCases; ++ij) | |
4995 | { | |
4996 | // Get jet information | |
4997 | AliAODJet* jet = dynamic_cast<AliAODJet*>(jetlist->At(ij)); | |
ab851c96 | 4998 | if(!jet)continue; |
1da9498b | 4999 | TVector3 jet3mom; |
5000 | jet3mom.SetPtEtaPhi(jet->Pt(),jet->Eta(),jet->Phi()); | |
5001 | new((*vect3Jet)[ijet]) TVector3((TVector3)jet3mom); | |
5002 | Float_t etaJet = (Float_t)((TVector3*) vect3Jet->At(ij))->Eta(); | |
5003 | ||
5004 | // Jet area | |
5005 | areaJet[ij] = CalcJetArea(etaJet,rc); | |
5006 | ||
5007 | // Area jet larger angle | |
5008 | areaJetLarge[ij] = CalcJetArea(etaJet,rcl); | |
5009 | ||
5010 | // Outside jet area | |
5011 | areaOut = areaOut - areaJetLarge[ij]; | |
5012 | ijet++; | |
5013 | } | |
5014 | ||
5015 | // List of all tracks outside jet areas | |
5016 | for (Int_t itrack=0; itrack<inputlist->GetSize(); itrack++){ | |
5017 | ||
5018 | AliVParticle* track = dynamic_cast<AliVParticle*>(inputlist->At(itrack)); | |
ab851c96 | 5019 | if(!track)continue; |
1da9498b | 5020 | Double_t trackMom[3]; |
5021 | track->PxPyPz(trackMom); | |
5022 | TVector3 track3mom(trackMom); | |
5023 | ||
5024 | Double_t *dR = new Double_t[nCases]; | |
5025 | for(Int_t ij=0; ij<nCases; ij++) | |
5026 | dR[ij] = (Double_t)((TVector3*) vect3Jet->At(ij))->DeltaR(track3mom); | |
5027 | ||
5028 | if((nCases==1 && (dR[0]>rcl)) || | |
5029 | (nCases==2 && (dR[0]>rcl && dR[1]>rcl)) || | |
5030 | (nCases==3 && (dR[0]>rcl && dR[1]>rcl && dR[2]>rcl))) | |
5031 | { | |
5032 | templist->Add(track); | |
5033 | nOut++; | |
5034 | } | |
5035 | delete [] dR; | |
5036 | } | |
5037 | ||
67e37e80 | 5038 | // Take tracks randomly |
5039 | Int_t nScaled = (Int_t) (nOut * areaJet[0] / areaOut + 0.5); | |
5040 | TArrayI* ar = new TArrayI(nOut); | |
1da9498b | 5041 | |
67e37e80 | 5042 | for(Int_t init=0; init<nOut; init++) |
5043 | (*ar)[init] = init; | |
1da9498b | 5044 | |
67e37e80 | 5045 | Int_t *randIndex = new Int_t[nScaled]; |
5046 | for(Int_t init2=0; init2<nScaled; init2++) | |
5047 | randIndex[init2] = -1; | |
1da9498b | 5048 | |
67e37e80 | 5049 | // Select nScaled different random numbers in nOut |
5050 | for(Int_t i=0; i<nScaled; i++) | |
1da9498b | 5051 | { |
67e37e80 | 5052 | Int_t* tmpArr = new Int_t[nOut-i]; |
5053 | Int_t temp = fRandom->Integer(nOut-i); | |
5054 | for(Int_t ind = 0; ind< ar->GetSize()-1; ind++) | |
1da9498b | 5055 | { |
67e37e80 | 5056 | if(ind<temp) tmpArr[ind] = (*ar)[ind]; |
5057 | else tmpArr[ind] = (*ar)[ind+1]; | |
1da9498b | 5058 | } |
67e37e80 | 5059 | randIndex[i] = (*ar)[temp]; |
1da9498b | 5060 | |
67e37e80 | 5061 | ar->Set(nOut-i-1,tmpArr); |
5062 | ||
5063 | delete [] tmpArr; | |
5064 | ||
5065 | } | |
5066 | ||
5067 | for(Int_t ipart=0; ipart<nScaled; ipart++) | |
5068 | { | |
1ea145ef | 5069 | AliVParticle* track = (AliVParticle*)(templist->At(randIndex[ipart])); |
67e37e80 | 5070 | outputlist->Add(track); |
5071 | sumPt += track->Pt(); | |
5072 | } | |
1da9498b | 5073 | |
5074 | outputlist->Sort(); | |
5075 | ||
1da9498b | 5076 | delete vect3Jet; |
5077 | delete templist; | |
5078 | delete [] areaJetLarge; | |
5079 | delete [] areaJet; | |
67e37e80 | 5080 | delete ar; |
5081 | delete [] randIndex; | |
1da9498b | 5082 | |
5083 | } | |
5084 | ||
5085 | // ________________________________________________________________________________________________________________________________________________________ | |
3af23c82 | 5086 | void AliAnalysisTaskFragmentationFunction::GetTracksOutOfNJetsStat(Int_t nCases, TList* inputlist, TList* outputlist, TList* jetlist, Double_t& sumPt, Double_t &normFactor) |
1da9498b | 5087 | { |
5088 | // List of tracks outside cone around N jet axis | |
5089 | // All particles taken + final scaling factor | |
5090 | ||
5091 | sumPt = 0; | |
5092 | Float_t rc = GetFFRadius(); | |
5093 | Float_t rcl = GetFFBckgRadius(); | |
5094 | ||
5095 | // Estimate jet and background areas | |
5096 | Float_t* areaJet = new Float_t[nCases]; | |
9939142f | 5097 | memset(areaJet, 0, sizeof(Float_t) * nCases); |
1da9498b | 5098 | Float_t* areaJetLarge = new Float_t[nCases]; |
9939142f | 5099 | memset(areaJetLarge, 0, sizeof(Float_t) * nCases); |
1da9498b | 5100 | Float_t areaFull = (fTrackEtaMax-fTrackEtaMin)*(fTrackPhiMax-fTrackPhiMin); |
5101 | Float_t areaOut = areaFull; | |
5102 | ||
5103 | //estimate jets and background areas | |
5104 | Int_t nOut = 0; | |
5105 | Int_t ijet = 0; | |
5106 | TClonesArray *vect3Jet = new TClonesArray("TVector3",nCases); | |
5107 | ||
5108 | for(Int_t ij=0; ij<nCases; ++ij) | |
5109 | { | |
5110 | // Get jet information | |
5111 | AliAODJet* jet = dynamic_cast<AliAODJet*>(jetlist->At(ij)); | |
ab851c96 | 5112 | if(!jet)continue; |
1da9498b | 5113 | TVector3 jet3mom; |
5114 | jet3mom.SetPtEtaPhi(jet->Pt(),jet->Eta(),jet->Phi()); | |
5115 | new((*vect3Jet)[ijet]) TVector3((TVector3)jet3mom); | |
5116 | Float_t etaJet = (Float_t)((TVector3*) vect3Jet->At(ij))->Eta(); | |
5117 | ||
5118 | // Jet area | |
5119 | areaJet[ij] = CalcJetArea(etaJet,rc); | |
5120 | ||
5121 | // Area jet larger angle | |
5122 | areaJetLarge[ij] = CalcJetArea(etaJet,rcl); | |
5123 | ||
5124 | // Outside jets area | |
5125 | areaOut = areaOut - areaJetLarge[ij]; | |
5126 | ijet++; | |
5127 | } | |
5128 | ||
5129 | for (Int_t itrack=0; itrack<inputlist->GetSize(); itrack++){ | |
5130 | ||
5131 | AliVParticle* track = dynamic_cast<AliVParticle*>(inputlist->At(itrack)); | |
ab851c96 | 5132 | if(!track)continue; |
1da9498b | 5133 | Double_t trackMom[3]; |
5134 | track->PxPyPz(trackMom); | |
5135 | TVector3 track3mom(trackMom); | |
5136 | ||
5137 | Double_t *dR = new Double_t[nCases]; | |
5138 | for(Int_t ij=0; ij<nCases; ij++) | |
5139 | dR[ij] = (Double_t)((TVector3*) vect3Jet->At(ij))->DeltaR(track3mom); | |
5140 | ||
5141 | if((nCases==0) || | |
5142 | (nCases==1 && (dR[0]>rcl)) || | |
5143 | (nCases==2 && (dR[0]>rcl && dR[1]>rcl)) || | |
5144 | (nCases==3 && (dR[0]>rcl && dR[1]>rcl && dR[2]>rcl))) | |
5145 | { | |
5146 | outputlist->Add(track); | |
5147 | sumPt += track->Pt(); | |
5148 | nOut++; | |
5149 | } | |
5150 | delete [] dR; | |
5151 | } | |
5152 | ||
5153 | if(nCases==0) areaJet[0] = TMath::Pi()*rc*rc; | |
5154 | normFactor = (Float_t) 1./(areaJet[0] / areaOut); | |
5155 | ||
5156 | outputlist->Sort(); | |
5157 | ||
5158 | delete vect3Jet; | |
5159 | delete [] areaJetLarge; | |
5160 | delete [] areaJet; | |
5161 | ||
5162 | } | |
5163 | ||
5164 | // ______________________________________________________________________________________________________________________________________________________ | |
3af23c82 | 5165 | Float_t AliAnalysisTaskFragmentationFunction::CalcJetArea(const Float_t etaJet, const Float_t rc) const |
1da9498b | 5166 | { |
3af23c82 | 5167 | // calculate area of jet with eta etaJet and radius rc |
1da9498b | 5168 | |
5169 | Float_t detamax = etaJet + rc; | |
5170 | Float_t detamin = etaJet - rc; | |
5171 | Float_t accmax = 0.0; Float_t accmin = 0.0; | |
5172 | if(detamax > fTrackEtaMax){ // sector outside etamax | |
5173 | Float_t h = fTrackEtaMax - etaJet; | |
5174 | accmax = rc*rc*TMath::ACos(h/rc) - h*TMath::Sqrt(rc*rc - h*h); | |
5175 | } | |
5176 | if(detamin < fTrackEtaMin){ // sector outside etamin | |
5177 | Float_t h = fTrackEtaMax + etaJet; | |
5178 | accmin = rc*rc*TMath::ACos(h/rc) - h*TMath::Sqrt(rc*rc - h*h); | |
5179 | } | |
5180 | Float_t areaJet = rc*rc*TMath::Pi() - accmax - accmin; | |
5181 | ||
5182 | return areaJet; | |
5183 | ||
5184 | } | |
67e37e80 | 5185 | |
742ee86c | 5186 | // ___________________________________________________________________________________________________________________________ |
5187 | void AliAnalysisTaskFragmentationFunction::GetClusterTracksOutOf1Jet(AliAODJet* jet, TList* outputlist, Double_t &normFactor) | |
5188 | { | |
5189 | // fill tracks from bckgCluster branch in list, | |
5190 | // for all clusters outside jet cone | |
5191 | // sum up total area of clusters | |
5192 | ||
5193 | Double_t rc = GetFFRadius(); | |
5194 | Double_t rcl = GetFFBckgRadius(); | |
5195 | ||
5196 | Double_t areaTotal = 0; | |
5197 | Double_t sumPtTotal = 0; | |
5198 | ||
5199 | for(Int_t ij=0; ij<fBckgJetsRec->GetEntries(); ++ij){ | |
5200 | ||
5201 | AliAODJet* bgrCluster = (AliAODJet*)(fBckgJetsRec->At(ij)); // not 'recCuts': use all clusters in full eta range | |
5202 | ||
5203 | Double_t dR = jet->DeltaR(bgrCluster); | |
5204 | ||
5205 | if(dR<rcl) continue; | |
5206 | ||
5207 | Double_t clusterPt = bgrCluster->Pt(); | |
5208 | Double_t area = bgrCluster->EffectiveAreaCharged(); | |
5209 | areaTotal += area; | |
5210 | sumPtTotal += clusterPt; | |
5211 | ||
5212 | Int_t nTracksJet = bgrCluster->GetRefTracks()->GetEntries(); | |
5213 | ||
5214 | for(Int_t it = 0; it<nTracksJet; it++){ | |
5215 | ||
5216 | AliVParticle* track = dynamic_cast<AliVParticle*>(bgrCluster->GetTrack(it)); | |
3170a3f8 | 5217 | if(!track) continue; |
742ee86c | 5218 | |
5219 | Float_t trackPt = track->Pt(); | |
5220 | Float_t trackEta = track->Eta(); | |
5221 | Float_t trackPhi = TVector2::Phi_0_2pi(track->Phi()); | |
5222 | ||
5223 | if(trackEta < fTrackEtaMin || trackEta > fTrackEtaMax) continue; | |
5224 | if(trackPhi < fTrackPhiMin || trackPhi > fTrackPhiMax) continue; | |
5225 | if(trackPt < fTrackPtCut) continue; | |
5226 | ||
5227 | outputlist->Add(track); | |
5228 | } | |
5229 | } | |
5230 | ||
5231 | Double_t areaJet = TMath::Pi()*rc*rc; | |
5232 | if(areaTotal) normFactor = (Float_t) 1./(areaJet / areaTotal); | |
5233 | ||
5234 | outputlist->Sort(); | |
5235 | } | |
5236 | ||
5237 | // _______________________________________________________________________________________________________________________ | |
5238 | void AliAnalysisTaskFragmentationFunction::GetClusterTracksMedian(TList* outputlist, Double_t &normFactor) | |
5239 | { | |
5240 | // fill tracks from bckgCluster branch, | |
5241 | // using cluster with median density (odd number of clusters) | |
5242 | // or picking randomly one of the two closest to median (even number) | |
5243 | ||
3170a3f8 | 5244 | normFactor = 0; |
5245 | ||
742ee86c | 5246 | Int_t nBckgClusters = fBckgJetsRec->GetEntries(); // not 'recCuts': use all clusters in full eta range |
5247 | ||
3170a3f8 | 5248 | if(!nBckgClusters) return; |
5249 | ||
742ee86c | 5250 | Double_t* bgrDensity = new Double_t[nBckgClusters]; |
5251 | Int_t* indices = new Int_t[nBckgClusters]; | |
5252 | ||
5253 | for(Int_t ij=0; ij<nBckgClusters; ++ij){ | |
5254 | ||
5255 | AliAODJet* bgrCluster = (AliAODJet*)(fBckgJetsRec->At(ij)); | |
5256 | Double_t clusterPt = bgrCluster->Pt(); | |
5257 | Double_t area = bgrCluster->EffectiveAreaCharged(); | |
5258 | ||
5259 | Double_t density = 0; | |
5260 | if(area>0) density = clusterPt/area; | |
5261 | ||
5262 | bgrDensity[ij] = density; | |
5263 | indices[ij] = ij; | |
5264 | } | |
5265 | ||
5266 | TMath::Sort(nBckgClusters, bgrDensity, indices); | |
5267 | ||
5268 | // get median cluster | |
5269 | ||
5270 | AliAODJet* medianCluster = 0; | |
5271 | Double_t medianDensity = 0; | |
5272 | ||
5273 | if(TMath::Odd(nBckgClusters)){ | |
5274 | ||
5275 | Int_t medianIndex = indices[(Int_t) (0.5*(nBckgClusters-1))]; | |
5276 | medianCluster = (AliAODJet*)(fBckgJetsRec->At(medianIndex)); | |
5277 | ||
5278 | Double_t clusterPt = medianCluster->Pt(); | |
5279 | Double_t area = medianCluster->EffectiveAreaCharged(); | |
5280 | ||
5281 | if(area>0) medianDensity = clusterPt/area; | |
5282 | } | |
5283 | else{ | |
5284 | ||
5285 | Int_t medianIndex1 = indices[(Int_t) (0.5*nBckgClusters-1)]; | |
5286 | Int_t medianIndex2 = indices[(Int_t) (0.5*nBckgClusters)]; | |
5287 | ||
5288 | AliAODJet* medianCluster1 = (AliAODJet*)(fBckgJetsRec->At(medianIndex1)); | |
5289 | AliAODJet* medianCluster2 = (AliAODJet*)(fBckgJetsRec->At(medianIndex2)); | |
5290 | ||
5291 | Double_t density1 = 0; | |
5292 | Double_t clusterPt1 = medianCluster1->Pt(); | |
5293 | Double_t area1 = medianCluster1->EffectiveAreaCharged(); | |
5294 | if(area1>0) density1 = clusterPt1/area1; | |
5295 | ||
5296 | Double_t density2 = 0; | |
5297 | Double_t clusterPt2 = medianCluster2->Pt(); | |
5298 | Double_t area2 = medianCluster2->EffectiveAreaCharged(); | |
5299 | if(area2>0) density2 = clusterPt2/area2; | |
5300 | ||
5301 | medianDensity = 0.5*(density1+density2); | |
5302 | ||
5303 | medianCluster = ( (fRandom->Rndm()>0.5) ? medianCluster1 : medianCluster2 ); // select one randomly to avoid adding areas | |
5304 | } | |
5305 | ||
5306 | Int_t nTracksJet = medianCluster->GetRefTracks()->GetEntries(); | |
5307 | ||
5308 | for(Int_t it = 0; it<nTracksJet; it++){ | |
5309 | ||
5310 | AliVParticle* track = dynamic_cast<AliVParticle*>(medianCluster->GetTrack(it)); | |
3170a3f8 | 5311 | if(!track) continue; |
742ee86c | 5312 | |
5313 | Float_t trackPt = track->Pt(); | |
5314 | Float_t trackEta = track->Eta(); | |
5315 | Float_t trackPhi = TVector2::Phi_0_2pi(track->Phi()); | |
5316 | ||
5317 | if(trackEta < fTrackEtaMin || trackEta > fTrackEtaMax) continue; | |
5318 | if(trackPhi < fTrackPhiMin || trackPhi > fTrackPhiMax) continue; | |
5319 | if(trackPt < fTrackPtCut) continue; | |
5320 | ||
5321 | outputlist->Add(track); | |
5322 | } | |
5323 | ||
5324 | Double_t areaMedian = medianCluster->EffectiveAreaCharged(); | |
5325 | Double_t areaJet = TMath::Pi()*GetFFRadius()*GetFFRadius(); | |
5326 | ||
5327 | if(areaMedian) normFactor = (Float_t) 1./(areaJet / areaMedian); | |
5328 | ||
5329 | outputlist->Sort(); | |
5330 | ||
5331 | delete[] bgrDensity; | |
5332 | delete[] indices; | |
5333 | } | |
5334 | ||
67e37e80 | 5335 | // ______________________________________________________________________________________________________________________________________________________ |
5336 | void AliAnalysisTaskFragmentationFunction::FillBckgHistos(Int_t type, TList* inputtracklist, TList* inputjetlist, AliAODJet* jet, Float_t leadTrackPt, TLorentzVector* leadTrackV, | |
5337 | AliFragFuncHistos* ffbckghistocuts, AliFragFuncHistos* ffbckghistoleading, | |
5338 | AliFragFuncIntraJetHistos* ijbckghistocuts, AliFragFuncIntraJetHistos* ijbckghistoleading, | |
5339 | AliFragFuncQATrackHistos* qabckghistocuts){ | |
5340 | ||
5341 | // List of tracks outside jets for background study | |
5342 | TList* tracklistout2jets = new TList(); | |
5343 | TList* tracklistout3jets = new TList(); | |
5344 | TList* tracklistout2jetsStat = new TList(); | |
5345 | TList* tracklistout3jetsStat = new TList(); | |
5346 | Double_t sumPtOut2Jets = 0.; | |
5347 | Double_t sumPtOut3Jets = 0.; | |
5348 | Double_t sumPtOut2JetsStat = 0.; | |
5349 | Double_t sumPtOut3JetsStat = 0.; | |
5350 | Double_t normFactor2Jets = 0.; | |
5351 | Double_t normFactor3Jets = 0.; | |
5352 | ||
5353 | Int_t nRecJetsCuts = fJetsRecCuts->GetEntries(); | |
5354 | ||
5355 | if(nRecJetsCuts>1) { | |
3af23c82 | 5356 | GetTracksOutOfNJets(2,inputtracklist, tracklistout2jets, inputjetlist, sumPtOut2Jets); |
5357 | GetTracksOutOfNJetsStat(2,inputtracklist, tracklistout2jetsStat, inputjetlist,sumPtOut2JetsStat, normFactor2Jets); | |
5358 | ||
67e37e80 | 5359 | } |
5360 | if(nRecJetsCuts>2) { | |
3af23c82 | 5361 | GetTracksOutOfNJets(3,inputtracklist, tracklistout3jets, inputjetlist, sumPtOut3Jets); |
5362 | GetTracksOutOfNJetsStat(3,inputtracklist, tracklistout3jetsStat, inputjetlist, sumPtOut3JetsStat, normFactor3Jets); | |
67e37e80 | 5363 | } |
5364 | ||
5365 | if(type==kBckgOutLJ || type==kBckgOutAJ) | |
5366 | { | |
5367 | TList* tracklistoutleading = new TList(); | |
5368 | Double_t sumPtOutLeading = 0.; | |
3af23c82 | 5369 | GetTracksOutOfNJets(1,inputtracklist, tracklistoutleading, inputjetlist, sumPtOutLeading); |
67e37e80 | 5370 | if(type==kBckgOutLJ) fh1OutLeadingMult->Fill(tracklistoutleading->GetSize()); |
5371 | ||
5372 | for(Int_t it=0; it<tracklistoutleading->GetSize(); ++it){ | |
5373 | ||
9939142f | 5374 | AliVParticle* trackVP = (AliVParticle*)(tracklistoutleading->At(it)); |
3170a3f8 | 5375 | if(!trackVP) continue; |
67e37e80 | 5376 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5377 | ||
5378 | Float_t jetPt = jet->Pt(); | |
5379 | Float_t trackPt = trackV->Pt(); | |
5380 | ||
5381 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5382 | ||
5383 | if(type==kBckgOutLJ) | |
5384 | { | |
3af23c82 | 5385 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt); |
67e37e80 | 5386 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5387 | ||
3af23c82 | 5388 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt); |
67e37e80 | 5389 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5390 | ||
5391 | // Fill track QA for background | |
3af23c82 | 5392 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt); |
67e37e80 | 5393 | } |
5394 | ||
5395 | // All cases included | |
5396 | if(nRecJetsCuts==1 && type==kBckgOutAJ) | |
5397 | { | |
3af23c82 | 5398 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); |
67e37e80 | 5399 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5400 | ||
3af23c82 | 5401 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); |
67e37e80 | 5402 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5403 | } | |
5404 | delete trackV; | |
5405 | } | |
942bf1b4 | 5406 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5407 | if(tracklistoutleading->GetSize()==0) { | |
5408 | Float_t jetPt = jet->Pt(); | |
5409 | Bool_t incrementJetPt = kTRUE; | |
5410 | if(type==kBckgOutLJ) | |
5411 | { | |
5412 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5413 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5414 | } | |
5415 | // All cases included | |
5416 | if(nRecJetsCuts==1 && type==kBckgOutAJ) | |
5417 | { | |
5418 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5419 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5420 | } | |
5421 | } | |
67e37e80 | 5422 | delete tracklistoutleading; |
5423 | } | |
5424 | if(type==kBckgOutLJStat || type==kBckgOutAJStat) | |
5425 | { | |
5426 | TList* tracklistoutleadingStat = new TList(); | |
5427 | Double_t sumPtOutLeadingStat = 0.; | |
5428 | Double_t normFactorLeading = 0.; | |
5429 | ||
3af23c82 | 5430 | GetTracksOutOfNJetsStat(1,inputtracklist, tracklistoutleadingStat, inputjetlist, sumPtOutLeadingStat, normFactorLeading); |
742ee86c | 5431 | if(type==kBckgOutLJStat) fh1OutLeadingStatMult->Fill(tracklistoutleadingStat->GetSize()); |
67e37e80 | 5432 | |
5433 | for(Int_t it=0; it<tracklistoutleadingStat->GetSize(); ++it){ | |
5434 | ||
5435 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistoutleadingStat->At(it)); | |
3170a3f8 | 5436 | if(!trackVP) continue; |
67e37e80 | 5437 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5438 | ||
5439 | Float_t jetPt = jet->Pt(); | |
5440 | Float_t trackPt = trackV->Pt(); | |
67e37e80 | 5441 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; |
5442 | ||
5443 | // Stat plots | |
5444 | if(type==kBckgOutLJStat) | |
5445 | { | |
3af23c82 | 5446 | if(fFFMode)ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactorLeading); |
67e37e80 | 5447 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactorLeading); |
5448 | ||
3af23c82 | 5449 | if(fFFMode)ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactorLeading); |
67e37e80 | 5450 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactorLeading); |
5451 | ||
5452 | // Fill track QA for background | |
742ee86c | 5453 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt); // OB added bgr QA |
67e37e80 | 5454 | } |
5455 | ||
5456 | // All cases included | |
5457 | if(nRecJetsCuts==1 && type==kBckgOutAJStat) | |
5458 | { | |
3af23c82 | 5459 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactorLeading); |
67e37e80 | 5460 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactorLeading ); |
5461 | ||
3af23c82 | 5462 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactorLeading); |
67e37e80 | 5463 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactorLeading ); |
742ee86c | 5464 | |
5465 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt ); // OB added bgr QA | |
5466 | ||
67e37e80 | 5467 | } |
5468 | delete trackV; | |
5469 | } | |
942bf1b4 | 5470 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5471 | if(tracklistoutleadingStat->GetSize()==0) { | |
5472 | Float_t jetPt = jet->Pt(); | |
5473 | Bool_t incrementJetPt = kTRUE; | |
5474 | if(type==kBckgOutLJStat) | |
5475 | { | |
5476 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactorLeading); | |
5477 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactorLeading); | |
5478 | } | |
5479 | // All cases included | |
5480 | if(nRecJetsCuts==1 && type==kBckgOutLJStat) | |
5481 | { | |
5482 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactorLeading); | |
5483 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactorLeading ); | |
5484 | } | |
5485 | } | |
5486 | ||
67e37e80 | 5487 | delete tracklistoutleadingStat; |
5488 | } | |
5489 | ||
5490 | if(type==kBckgPerp) | |
5491 | { | |
5492 | Double_t sumPtPerp = 0.; | |
5493 | TList* tracklistperp = new TList(); | |
3af23c82 | 5494 | GetTracksTiltedwrpJetAxis(TMath::Pi()/2., inputtracklist,tracklistperp,jet,GetFFRadius(),sumPtPerp); |
67e37e80 | 5495 | fh1PerpMult->Fill(tracklistperp->GetSize()); |
5496 | ||
5497 | for(Int_t it=0; it<tracklistperp->GetSize(); ++it){ | |
5498 | ||
5499 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistperp->At(it)); | |
ab851c96 | 5500 | if(!trackVP)continue; |
67e37e80 | 5501 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5502 | ||
5503 | Float_t jetPt = jet->Pt(); | |
5504 | Float_t trackPt = trackV->Pt(); | |
5505 | ||
5506 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5507 | ||
3af23c82 | 5508 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); |
67e37e80 | 5509 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5510 | ||
3af23c82 | 5511 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); |
67e37e80 | 5512 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5513 | ||
5514 | // Fill track QA for background | |
3af23c82 | 5515 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt); |
67e37e80 | 5516 | |
5517 | delete trackV; | |
5518 | } | |
942bf1b4 | 5519 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5520 | if(tracklistperp->GetSize()==0) { | |
5521 | Float_t jetPt = jet->Pt(); | |
5522 | Bool_t incrementJetPt = kTRUE; | |
5523 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5524 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5525 | } | |
5526 | ||
67e37e80 | 5527 | delete tracklistperp; |
5528 | } | |
5529 | ||
3af23c82 | 5530 | if(type==kBckgASide) |
5531 | { | |
5532 | Double_t sumPtASide = 0.; | |
5533 | TList* tracklistaside = new TList(); | |
5534 | GetTracksTiltedwrpJetAxis(TMath::Pi(),inputtracklist,tracklistaside,jet,GetFFRadius(),sumPtASide); | |
5535 | fh1ASideMult->Fill(tracklistaside->GetSize()); | |
5536 | ||
5537 | for(Int_t it=0; it<tracklistaside->GetSize(); ++it){ | |
5538 | ||
1ea145ef | 5539 | AliVParticle* trackVP = (AliVParticle*)(tracklistaside->At(it)); |
3170a3f8 | 5540 | if(!trackVP) continue; |
3af23c82 | 5541 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5542 | ||
5543 | Float_t jetPt = jet->Pt(); | |
5544 | Float_t trackPt = trackV->Pt(); | |
5545 | ||
5546 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5547 | ||
5548 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); | |
5549 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); | |
5550 | ||
5551 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); | |
5552 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); | |
5553 | ||
5554 | // Fill track QA for background | |
5555 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt); | |
5556 | ||
5557 | delete trackV; | |
5558 | } | |
942bf1b4 | 5559 | if(tracklistaside->GetSize()==0) { |
5560 | Float_t jetPt = jet->Pt(); | |
5561 | Bool_t incrementJetPt = kTRUE; | |
5562 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5563 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5564 | } | |
5565 | ||
3af23c82 | 5566 | delete tracklistaside; |
5567 | } | |
5568 | ||
5569 | if(type==kBckgASideWindow) | |
5570 | { | |
5571 | Double_t normFactorASide = 0.; | |
5572 | Double_t sumPtASideW = 0.; | |
5573 | TList* tracklistasidew = new TList(); | |
5574 | GetTracksTiltedwrpJetAxisWindow(TMath::Pi(),inputtracklist,tracklistasidew,jet,GetFFRadius(),sumPtASideW,normFactorASide); | |
5575 | fh1ASideWindowMult->Fill(tracklistasidew->GetSize()); | |
5576 | ||
5577 | for(Int_t it=0; it<tracklistasidew->GetSize(); ++it){ | |
5578 | ||
5579 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistasidew->At(it)); | |
3170a3f8 | 5580 | if(!trackVP) continue; |
3af23c82 | 5581 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5582 | ||
5583 | Float_t jetPt = jet->Pt(); | |
5584 | Float_t trackPt = trackV->Pt(); | |
3af23c82 | 5585 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; |
5586 | ||
5587 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactorASide); | |
5588 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactorASide); | |
5589 | ||
5590 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactorASide ); | |
5591 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactorASide ); | |
5592 | ||
5593 | // Fill track QA for background | |
5594 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt, kFALSE, normFactorASide); | |
5595 | ||
5596 | delete trackV; | |
5597 | } | |
942bf1b4 | 5598 | if(tracklistasidew->GetSize()==0) { |
5599 | Float_t jetPt = jet->Pt(); | |
5600 | Bool_t incrementJetPt = kTRUE; | |
5601 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactorASide); | |
5602 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactorASide); | |
5603 | } | |
5604 | ||
3af23c82 | 5605 | delete tracklistasidew; |
5606 | } | |
5607 | ||
5608 | if(type==kBckgPerpWindow) | |
5609 | { | |
5610 | Double_t normFactorPerp = 0.; | |
5611 | Double_t sumPtPerpW = 0.; | |
5612 | TList* tracklistperpw = new TList(); | |
5613 | GetTracksTiltedwrpJetAxisWindow(TMath::Pi()/2.,inputtracklist,tracklistperpw,jet,GetFFRadius(),sumPtPerpW,normFactorPerp); | |
5614 | fh1PerpWindowMult->Fill(tracklistperpw->GetSize()); | |
5615 | ||
5616 | for(Int_t it=0; it<tracklistperpw->GetSize(); ++it){ | |
5617 | ||
5618 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistperpw->At(it)); | |
3170a3f8 | 5619 | if(!trackVP) continue; |
3af23c82 | 5620 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5621 | ||
5622 | Float_t jetPt = jet->Pt(); | |
5623 | Float_t trackPt = trackV->Pt(); | |
3af23c82 | 5624 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; |
5625 | ||
5626 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactorPerp); | |
5627 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactorPerp); | |
5628 | ||
5629 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactorPerp ); | |
5630 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactorPerp ); | |
5631 | ||
5632 | // Fill track QA for background | |
5633 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt, kFALSE, normFactorPerp); | |
5634 | ||
5635 | delete trackV; | |
5636 | } | |
942bf1b4 | 5637 | if(tracklistperpw->GetSize()==0) { |
5638 | Float_t jetPt = jet->Pt(); | |
5639 | Bool_t incrementJetPt = kTRUE; | |
5640 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactorPerp); | |
5641 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactorPerp); | |
5642 | } | |
5643 | ||
3af23c82 | 5644 | delete tracklistperpw; |
5645 | } | |
5646 | ||
5647 | ||
67e37e80 | 5648 | if(type==kBckgOut2J || type==kBckgOutAJ) |
5649 | { | |
5650 | if(type==kBckgOut2J) fh1Out2JetsMult->Fill(tracklistout2jets->GetSize()); | |
5651 | for(Int_t it=0; it<tracklistout2jets->GetSize(); ++it){ | |
5652 | ||
5653 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistout2jets->At(it)); | |
3170a3f8 | 5654 | if(!trackVP) continue; |
67e37e80 | 5655 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5656 | ||
5657 | Float_t jetPt = jet->Pt(); | |
5658 | Float_t trackPt = trackV->Pt(); | |
5659 | ||
5660 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5661 | ||
5662 | if(type==kBckgOut2J) | |
5663 | { | |
3af23c82 | 5664 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); |
67e37e80 | 5665 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5666 | ||
3af23c82 | 5667 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); |
67e37e80 | 5668 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5669 | ||
3af23c82 | 5670 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt); |
67e37e80 | 5671 | } |
5672 | ||
5673 | // All cases included | |
5674 | if(nRecJetsCuts==2 && type==kBckgOutAJ) | |
5675 | { | |
3af23c82 | 5676 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); |
67e37e80 | 5677 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5678 | ||
3af23c82 | 5679 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); |
67e37e80 | 5680 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5681 | } | |
5682 | delete trackV; | |
5683 | } | |
942bf1b4 | 5684 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5685 | if(tracklistout2jets->GetSize()==0) { | |
5686 | Float_t jetPt = jet->Pt(); | |
5687 | Bool_t incrementJetPt = kTRUE; | |
5688 | if(type==kBckgOut2J) | |
5689 | { | |
5690 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5691 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5692 | } | |
5693 | // All cases included | |
5694 | if(nRecJetsCuts==2 && type==kBckgOutAJ) | |
5695 | { | |
5696 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5697 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5698 | } | |
5699 | } | |
5700 | ||
67e37e80 | 5701 | } |
5702 | ||
5703 | if(type==kBckgOut2JStat || type==kBckgOutAJStat) | |
5704 | { | |
5705 | for(Int_t it=0; it<tracklistout2jetsStat->GetSize(); ++it){ | |
5706 | ||
5707 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistout2jetsStat->At(it)); | |
3170a3f8 | 5708 | if(!trackVP) continue; |
67e37e80 | 5709 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5710 | ||
5711 | Float_t jetPt = jet->Pt(); | |
5712 | Float_t trackPt = trackV->Pt(); | |
67e37e80 | 5713 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; |
5714 | ||
5715 | if(type==kBckgOut2JStat) | |
5716 | { | |
3af23c82 | 5717 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactor2Jets); |
67e37e80 | 5718 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactor2Jets ); |
5719 | ||
3af23c82 | 5720 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactor2Jets); |
67e37e80 | 5721 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactor2Jets ); |
5722 | ||
3170a3f8 | 5723 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt ); // OB added bgr QA |
67e37e80 | 5724 | } |
5725 | ||
5726 | // All cases included | |
5727 | if(nRecJetsCuts==2 && type==kBckgOutAJStat) | |
5728 | { | |
3af23c82 | 5729 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactor2Jets); |
67e37e80 | 5730 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactor2Jets ); |
5731 | ||
3af23c82 | 5732 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactor2Jets); |
67e37e80 | 5733 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactor2Jets ); |
742ee86c | 5734 | |
5735 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt ); // OB added bgr QA | |
67e37e80 | 5736 | } |
5737 | delete trackV; | |
5738 | } | |
942bf1b4 | 5739 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5740 | if(tracklistout2jetsStat->GetSize()==0) { | |
5741 | Float_t jetPt = jet->Pt(); | |
5742 | Bool_t incrementJetPt = kTRUE; | |
5743 | if(type==kBckgOut2JStat) | |
5744 | { | |
5745 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactor2Jets); | |
5746 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactor2Jets); | |
5747 | } | |
5748 | // All cases included | |
5749 | if(nRecJetsCuts==2 && type==kBckgOutAJStat) | |
5750 | { | |
5751 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactor2Jets); | |
5752 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactor2Jets ); | |
5753 | } | |
5754 | } | |
5755 | ||
67e37e80 | 5756 | } |
5757 | ||
5758 | if(type==kBckgOut3J || type==kBckgOutAJ) | |
5759 | { | |
5760 | if(type==kBckgOut3J) fh1Out3JetsMult->Fill(tracklistout3jets->GetSize()); | |
5761 | ||
5762 | for(Int_t it=0; it<tracklistout3jets->GetSize(); ++it){ | |
5763 | ||
5764 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistout3jets->At(it)); | |
3170a3f8 | 5765 | if(!trackVP) continue; |
67e37e80 | 5766 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5767 | ||
5768 | Float_t jetPt = jet->Pt(); | |
5769 | Float_t trackPt = trackV->Pt(); | |
5770 | ||
5771 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5772 | ||
5773 | if(type==kBckgOut3J) | |
5774 | { | |
942bf1b4 | 5775 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); |
67e37e80 | 5776 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5777 | ||
942bf1b4 | 5778 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); |
67e37e80 | 5779 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5780 | ||
5781 | qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt); | |
5782 | } | |
5783 | ||
5784 | // All cases included | |
5785 | if(nRecJetsCuts==3 && type==kBckgOutAJ) | |
5786 | { | |
942bf1b4 | 5787 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt ); |
67e37e80 | 5788 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector() ); |
5789 | ||
942bf1b4 | 5790 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt ); |
67e37e80 | 5791 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV ); |
5792 | } | |
5793 | delete trackV; | |
5794 | } | |
942bf1b4 | 5795 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5796 | if(tracklistout3jets->GetSize()==0) { | |
5797 | Float_t jetPt = jet->Pt(); | |
5798 | Bool_t incrementJetPt = kTRUE; | |
5799 | if(type==kBckgOut3J) | |
5800 | { | |
5801 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5802 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5803 | } | |
5804 | // All cases included | |
5805 | if(nRecJetsCuts==3 && type==kBckgOutAJ) | |
5806 | { | |
5807 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt ); | |
5808 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt ); | |
5809 | } | |
5810 | } | |
5811 | ||
5812 | ||
67e37e80 | 5813 | } |
5814 | ||
5815 | if(type==kBckgOut3JStat || type==kBckgOutAJStat) | |
5816 | { | |
5817 | for(Int_t it=0; it<tracklistout3jetsStat->GetSize(); ++it){ | |
5818 | ||
5819 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistout3jetsStat->At(it)); | |
3170a3f8 | 5820 | if(!trackVP) continue; |
67e37e80 | 5821 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5822 | ||
5823 | Float_t jetPt = jet->Pt(); | |
5824 | Float_t trackPt = trackV->Pt(); | |
67e37e80 | 5825 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; |
5826 | ||
5827 | if(type==kBckgOut3JStat) | |
5828 | { | |
942bf1b4 | 5829 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactor3Jets); |
67e37e80 | 5830 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactor3Jets); |
5831 | ||
942bf1b4 | 5832 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactor3Jets); |
67e37e80 | 5833 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactor3Jets); |
5834 | ||
3af23c82 | 5835 | //if(fQAMode&1) qabckghistocuts->FillTrackQA( trackEta, TVector2::Phi_0_2pi(trackPhi), trackPt); |
67e37e80 | 5836 | } |
5837 | ||
5838 | // All cases included | |
5839 | if(nRecJetsCuts==3 && type==kBckgOutAJStat) | |
5840 | { | |
3af23c82 | 5841 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactor3Jets ); |
67e37e80 | 5842 | if(fIJMode) ijbckghistocuts->FillIntraJet( trackV, jet->MomentumVector(), normFactor3Jets); |
5843 | ||
3af23c82 | 5844 | if(fFFMode) ffbckghistoleading->FillFF( trackPt, leadTrackPt , incrementJetPt, normFactor3Jets ); |
742ee86c | 5845 | if(fIJMode) ijbckghistoleading->FillIntraJet( trackV, leadTrackV, normFactor3Jets ); |
5846 | ||
5847 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt ); // OB added bgr QA | |
5848 | ||
67e37e80 | 5849 | } |
5850 | delete trackV; | |
5851 | } | |
942bf1b4 | 5852 | // Increment jet pt with one entry in case #tracks outside jets = 0 |
5853 | if(tracklistout3jetsStat->GetSize()==0) { | |
5854 | Float_t jetPt = jet->Pt(); | |
5855 | Bool_t incrementJetPt = kTRUE; | |
5856 | if(type==kBckgOut3JStat) | |
5857 | { | |
5858 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactor3Jets); | |
5859 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactor3Jets); | |
5860 | } | |
5861 | // All cases included | |
5862 | if(nRecJetsCuts==3 && type==kBckgOutAJStat) | |
5863 | { | |
5864 | if(fFFMode) ffbckghistocuts->FillFF( -1., jetPt, incrementJetPt, normFactor3Jets); | |
5865 | if(fFFMode) ffbckghistoleading->FillFF( -1., leadTrackPt , incrementJetPt, normFactor3Jets ); | |
5866 | } | |
5867 | } | |
5868 | ||
67e37e80 | 5869 | } |
5870 | ||
742ee86c | 5871 | if(type==kBckgClustersOutLeading){ // clusters bgr: all tracks in clusters out of leading jet |
5872 | ||
5873 | TList* tracklistClustersOutLeading = new TList(); | |
5874 | Double_t normFactorClusters = 0; | |
5875 | Float_t jetPt = jet->Pt(); | |
5876 | ||
5877 | GetClusterTracksOutOf1Jet(jet, tracklistClustersOutLeading, normFactorClusters); | |
5878 | fh1OutClustersMult->Fill(tracklistClustersOutLeading->GetSize()); | |
5879 | ||
5880 | for(Int_t it=0; it<tracklistClustersOutLeading->GetSize(); ++it){ | |
5881 | ||
5882 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistClustersOutLeading->At(it)); | |
3170a3f8 | 5883 | if(!trackVP) continue; |
742ee86c | 5884 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5885 | ||
5886 | Float_t trackPt = trackVP->Pt(); | |
5887 | ||
5888 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5889 | ||
5890 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactorClusters ); | |
5891 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt ); | |
67e37e80 | 5892 | |
742ee86c | 5893 | delete trackV; |
5894 | } | |
5895 | ||
5896 | delete tracklistClustersOutLeading; | |
5897 | ||
5898 | } | |
5899 | ||
5900 | if(type == kBckgClusters){ // clusters bgr: all tracks in 'median cluster' | |
5901 | ||
5902 | TList* tracklistClustersMedian = new TList(); | |
5903 | Double_t normFactorClusters = 0; | |
5904 | Float_t jetPt = jet->Pt(); | |
5905 | ||
5906 | GetClusterTracksMedian(tracklistClustersMedian, normFactorClusters); | |
5907 | fh1MedianClustersMult->Fill(tracklistClustersMedian->GetSize()); | |
3170a3f8 | 5908 | |
742ee86c | 5909 | for(Int_t it=0; it<tracklistClustersMedian->GetSize(); ++it){ |
5910 | ||
5911 | AliVParticle* trackVP = dynamic_cast<AliVParticle*>(tracklistClustersMedian->At(it)); | |
3170a3f8 | 5912 | if(!trackVP) continue; |
742ee86c | 5913 | TLorentzVector* trackV = new TLorentzVector(trackVP->Px(),trackVP->Py(),trackVP->Pz(),trackVP->P()); |
5914 | ||
5915 | Float_t trackPt = trackVP->Pt(); | |
5916 | ||
5917 | Bool_t incrementJetPt = (it==0) ? kTRUE : kFALSE; | |
5918 | ||
5919 | if(fFFMode) ffbckghistocuts->FillFF( trackPt, jetPt, incrementJetPt, normFactorClusters ); | |
5920 | if(fQAMode&1) qabckghistocuts->FillTrackQA( trackV->Eta(), TVector2::Phi_0_2pi(trackV->Phi()), trackPt ); | |
5921 | ||
5922 | delete trackV; | |
5923 | } | |
5924 | ||
5925 | delete tracklistClustersMedian; | |
5926 | } | |
5927 | ||
67e37e80 | 5928 | delete tracklistout2jets; |
5929 | delete tracklistout3jets; | |
5930 | delete tracklistout2jetsStat; | |
5931 | delete tracklistout3jetsStat; | |
742ee86c | 5932 | |
67e37e80 | 5933 | } |
3af23c82 | 5934 | |
5935 | // ______________________________________________________________________________________________________________________________________________________ | |
5936 | AliAODJet* AliAnalysisTaskFragmentationFunction::GetAODBckgSubJet(AliAODJet* jet, Int_t method) | |
5937 | { | |
5938 | // correct jet pt for (mean bgr energy density) x (jet area) | |
5939 | ||
44b235ce | 5940 | if(!fBranchRecBackJets.Length()){ |
5941 | if(fDebug>0)Printf("%s:%d background branch name not set",(char*)__FILE__,__LINE__); | |
5942 | return 0; | |
5943 | } | |
5944 | ||
3af23c82 | 5945 | static AliAODJetEventBackground* externalBackground = (AliAODJetEventBackground*)(fAOD->FindListObject(fBranchRecBackJets.Data())); |
5946 | ||
5947 | if(!externalBackground){ | |
44b235ce | 5948 | if(fDebug>0)Printf("%s:%d no external background object found in %s",(char*)__FILE__,__LINE__,fBranchRecBackJets.Data()); |
3af23c82 | 5949 | return 0; |
5950 | } | |
5951 | ||
5952 | Float_t rho = externalBackground->GetBackground(method); | |
5953 | ||
5954 | // Calculate background and subtract it from jet pt | |
5955 | Float_t ptBack = rho*jet->EffectiveAreaCharged(); | |
5956 | Float_t ptSub = jet->Pt()-ptBack; | |
5957 | ||
5958 | // Get px, py, pz from eta, phi, pt | |
5959 | TLorentzVector vecSub; | |
5960 | AliAODJet *tmpJet = 0; | |
5961 | if(ptSub>=0){ | |
5962 | vecSub.SetPtEtaPhiM(ptSub,jet->Eta(),jet->Phi(),0.); | |
5963 | tmpJet = new AliAODJet(vecSub.Px(),vecSub.Py(),vecSub.Pz(),vecSub.P()); | |
5964 | } | |
5965 | ||
5966 | return tmpJet; | |
5967 | ||
5968 | } | |
5969 | ||
5970 |