]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWGHF/hfe/AliAnalysisTaskElecHadronCorrel.cxx
updated
[u/mrichter/AliRoot.git] / PWGHF / hfe / AliAnalysisTaskElecHadronCorrel.cxx
CommitLineData
57189f04 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16
17////////////////////////////////////////////////////////////////////////
18// //
19// Task for Heavy Flavour Electron-Hadron DeltaPhi Correlation //
20// Non-Photonic Electron identified with Invariant mass //
21// analysis methos in function SelectPhotonicElectron //
22// DeltaPhi calculated in function ElectronHadCorrel //
23// //
24// Author: Deepa Thomas (Utrecht University) //
25// //
26////////////////////////////////////////////////////////////////////////
27
28#include "TChain.h"
29#include "TTree.h"
30#include "TH2F.h"
31#include "TMath.h"
32#include "TCanvas.h"
33#include "THnSparse.h"
34#include "TLorentzVector.h"
35#include "TString.h"
36#include "TFile.h"
37
38#include "AliAnalysisTask.h"
39#include "AliAnalysisManager.h"
40
41#include "AliESDEvent.h"
42#include "AliESDHandler.h"
43#include "AliAODEvent.h"
44#include "AliAODHandler.h"
45
46#include "AliAnalysisTaskElecHadronCorrel.h"
47#include "TGeoGlobalMagField.h"
48#include "AliLog.h"
49#include "AliAnalysisTaskSE.h"
50#include "TRefArray.h"
51#include "TVector.h"
987053ce 52
57189f04 53#include "AliESDInputHandler.h"
987053ce 54#include "AliAODInputHandler.h"
57189f04 55#include "AliESDpid.h"
987053ce 56#include "AliAODPid.h"
57189f04 57#include "AliESDtrackCuts.h"
58#include "AliPhysicsSelection.h"
987053ce 59#include "AliCentralitySelectionTask.h"
57189f04 60#include "AliESDCaloCluster.h"
61#include "AliAODCaloCluster.h"
520a29a8 62#include "AliESDCaloTrigger.h"
57189f04 63#include "AliEMCALRecoUtils.h"
64#include "AliEMCALGeometry.h"
65#include "AliGeomManager.h"
66#include "stdio.h"
67#include "TGeoManager.h"
68#include "iostream"
69#include "fstream"
3c56855b 70
9866fa7b 71//#include "AliEventPoolManager.h"
3c56855b 72
520a29a8 73#include "AliCentrality.h"
57189f04 74#include "AliMagF.h"
75
76#include "AliKFParticle.h"
77#include "AliKFVertex.h"
78
79#include "AliPID.h"
80#include "AliPIDResponse.h"
81#include "AliHFEcontainer.h"
82#include "AliHFEcuts.h"
83#include "AliHFEpid.h"
84#include "AliHFEpidBase.h"
85#include "AliHFEpidQAmanager.h"
86#include "AliHFEtools.h"
87#include "AliCFContainer.h"
88#include "AliCFManager.h"
987053ce 89#include "AliVEvent.h"
90#include "AliStack.h"
91#include "AliMCEvent.h"
92#include "TProfile.h"
93#include "AliESDVZERO.h"
94#include "AliAODVZERO.h"
95#include "TVector3.h"
96#include "TRandom2.h"
57189f04 97
a9123929 98 ClassImp(AliAnalysisTaskElecHadronCorrel)
9866fa7b 99//ClassImp(AliehDPhiBasicParticle)
a9123929 100 //________________________________________________________________________
520a29a8 101 AliAnalysisTaskElecHadronCorrel::AliAnalysisTaskElecHadronCorrel(const char *name)
57189f04 102 : AliAnalysisTaskSE(name)
987053ce 103 ,fVevent(0)
57189f04 104 ,fESD(0)
987053ce 105 ,fAOD(0)
57189f04 106 ,fGeom(0)
107 ,fOutputList(0)
520a29a8 108 ,fTrackCuts1(new AliESDtrackCuts)
109 ,fTrackCuts2(new AliESDtrackCuts)
57189f04 110 ,fCuts(0)
111 ,fIdentifiedAsOutInz(kFALSE)
112 ,fPassTheEventCut(kFALSE)
113 ,fRejectKinkMother(kFALSE)
114 ,fVz(0.0)
115 ,fCFM(0)
116 ,fPID(0)
117 ,fPIDqa(0)
57189f04 118 ,fInvmassCut(0.01)
3c56855b 119 ,fCentrality(0)
120 ,fCentralityMin(0)
121 ,fCentralityMax(0)
122 ,fkCentralityMethod(0)
a9123929 123 ,fTPCnsigEleMin(-2)
124 ,fTPCnsigEleMax(2)
125 ,fTPCnsigHadMin(-10)
126 ,fTPCnsigHadMax(-3.5)
127 ,fM02CutMin(0.03)
128 ,fM02CutMax(0.5)
129 ,fM20CutMin(0.03)
130 ,fM20CutMax(0.3)
131 ,fDispCutMin(0)
132 ,fDispCutMax(1)
133 ,fEovPMin(0.8)
134 ,fEovPMax(1.2)
135 ,fTriggerCentral(kTRUE)
9866fa7b 136// ,fPoolMgr(0x0)
a9123929 137 ,fNoEvents(0)
138 // ,fTrkpt(0)
139 ,fTrkEovPAft(0)
140 // ,fTrkEovPBefHad(0)
141 // ,fdEdxBef(0)
987053ce 142 ,fSemiIncElecDphi(0)
487ae960 143 ,fSemiIncElecDphi1(0)
144 ,fSemiIncElecDphi2(0)
145 ,fSemiIncElecDphi3(0)
146 ,fSemiIncElecDphi4(0)
57189f04 147 ,fPhotElecDphi(0)
487ae960 148 ,fPhotElecDphi1(0)
149 ,fPhotElecDphi2(0)
150 ,fPhotElecDphi3(0)
151 ,fPhotElecDphi4(0)
57189f04 152 ,fInclusiveElecDphi(0)
487ae960 153 ,fInclusiveElecDphi1(0)
154 ,fInclusiveElecDphi2(0)
155 ,fInclusiveElecDphi3(0)
156 ,fInclusiveElecDphi4(0)
33369c14 157 ,fInclusiveElecDphiEtaFS(0)
158 ,fInclusiveElecDphiEtaFS1(0)
159 ,fInclusiveElecDphiEtaFS2(0)
160 ,fInclusiveElecDphiEtaFS3(0)
161 ,fInclusiveElecDphiEtaFS4(0)
57189f04 162 ,fDphiULSMassLow(0)
487ae960 163 ,fDphiULSMassLow1(0)
164 ,fDphiULSMassLow2(0)
165 ,fDphiULSMassLow3(0)
166 ,fDphiULSMassLow4(0)
57189f04 167 ,fDphiLSMassLow(0)
487ae960 168 ,fDphiLSMassLow1(0)
169 ,fDphiLSMassLow2(0)
170 ,fDphiLSMassLow3(0)
171 ,fDphiLSMassLow4(0)
520a29a8 172 ,fDphiULSMassLowNoPartner(0)
487ae960 173 ,fDphiULSMassLowNoPartner1(0)
174 ,fDphiULSMassLowNoPartner2(0)
175 ,fDphiULSMassLowNoPartner3(0)
176 ,fDphiULSMassLowNoPartner4(0)
520a29a8 177 ,fDphiLSMassLowNoPartner(0)
487ae960 178 ,fDphiLSMassLowNoPartner1(0)
179 ,fDphiLSMassLowNoPartner2(0)
180 ,fDphiLSMassLowNoPartner3(0)
181 ,fDphiLSMassLowNoPartner4(0)
57189f04 182 ,fPhotoElecPt(0)
183 ,fSemiInclElecPt(0)
520a29a8 184 ,fInclusiveElecPt(0)
185 ,fULSElecPt(0)
186 ,fLSElecPt(0)
bf697dda 187 ,fSemiIncElecDphiEta1(0)
188 ,fSemiIncElecDphiEta11(0)
189 ,fSemiIncElecDphiEta12(0)
190 ,fSemiIncElecDphiEta13(0)
191 ,fSemiIncElecDphiEta14(0)
192 ,fPhotElecDphiEta1(0)
193 ,fPhotElecDphiEta11(0)
194 ,fPhotElecDphiEta12(0)
195 ,fPhotElecDphiEta13(0)
196 ,fPhotElecDphiEta14(0)
197 ,fInclusiveElecDphiEta1(0)
198 ,fInclusiveElecDphiEta11(0)
199 ,fInclusiveElecDphiEta12(0)
200 ,fInclusiveElecDphiEta13(0)
201 ,fInclusiveElecDphiEta14(0)
202 ,fDphiULSMassLowEta1(0)
203 ,fDphiULSMassLowEta11(0)
204 ,fDphiULSMassLowEta12(0)
205 ,fDphiULSMassLowEta13(0)
206 ,fDphiULSMassLowEta14(0)
207 ,fDphiLSMassLowEta1(0)
208 ,fDphiLSMassLowEta11(0)
209 ,fDphiLSMassLowEta12(0)
210 ,fDphiLSMassLowEta13(0)
211 ,fDphiLSMassLowEta14(0)
212 ,fDphiULSMassLowNoPartnerEta1(0)
213 ,fDphiULSMassLowNoPartnerEta11(0)
214 ,fDphiULSMassLowNoPartnerEta12(0)
215 ,fDphiULSMassLowNoPartnerEta13(0)
216 ,fDphiULSMassLowNoPartnerEta14(0)
217 ,fDphiLSMassLowNoPartnerEta1(0)
218 ,fDphiLSMassLowNoPartnerEta11(0)
219 ,fDphiLSMassLowNoPartnerEta12(0)
220 ,fDphiLSMassLowNoPartnerEta13(0)
221 ,fDphiLSMassLowNoPartnerEta14(0)
222 ,fSemiIncElecDphiEta2(0)
223 ,fSemiIncElecDphiEta21(0)
224 ,fSemiIncElecDphiEta22(0)
225 ,fSemiIncElecDphiEta23(0)
226 ,fSemiIncElecDphiEta24(0)
227 ,fPhotElecDphiEta2(0)
228 ,fPhotElecDphiEta21(0)
229 ,fPhotElecDphiEta22(0)
230 ,fPhotElecDphiEta23(0)
231 ,fPhotElecDphiEta24(0)
232 ,fInclusiveElecDphiEta2(0)
233 ,fInclusiveElecDphiEta21(0)
234 ,fInclusiveElecDphiEta22(0)
235 ,fInclusiveElecDphiEta23(0)
236 ,fInclusiveElecDphiEta24(0)
237 ,fDphiULSMassLowEta2(0)
238 ,fDphiULSMassLowEta21(0)
239 ,fDphiULSMassLowEta22(0)
240 ,fDphiULSMassLowEta23(0)
241 ,fDphiULSMassLowEta24(0)
242 ,fDphiLSMassLowEta2(0)
243 ,fDphiLSMassLowEta21(0)
244 ,fDphiLSMassLowEta22(0)
245 ,fDphiLSMassLowEta23(0)
246 ,fDphiLSMassLowEta24(0)
247 ,fDphiULSMassLowNoPartnerEta2(0)
248 ,fDphiULSMassLowNoPartnerEta21(0)
249 ,fDphiULSMassLowNoPartnerEta22(0)
250 ,fDphiULSMassLowNoPartnerEta23(0)
251 ,fDphiULSMassLowNoPartnerEta24(0)
252 ,fDphiLSMassLowNoPartnerEta2(0)
253 ,fDphiLSMassLowNoPartnerEta21(0)
254 ,fDphiLSMassLowNoPartnerEta22(0)
255 ,fDphiLSMassLowNoPartnerEta23(0)
256 ,fDphiLSMassLowNoPartnerEta24(0)
257 // ,fTrackPtBefTrkCuts(0)
258 // ,fTrackPtAftTrkCuts(0)
259 // ,fTPCnsigma(0)
260 // ,fNCellv1(0)
261 // ,fClsEv1(0)
262 // ,fNClusv1(0)
263 ,fInvmassLS1(0)
264 // ,fInvmassLS2(0)
265 // ,fInvmassLS3(0)
266 // ,fInvmassLS4(0)
267 // ,fInvmassLS5(0)
268 ,fInvmassULS1(0)
269 // ,fInvmassULS2(0)
270 // ,fInvmassULS3(0)
271 // ,fInvmassULS4(0)
272 // ,fInvmassULS5(0)
520a29a8 273 ,fcentrality(0)
274 ,fElecPhi(0)
3c56855b 275 ,fElecPhiTPChalf(0)
bf697dda 276 ,fElecPhiPt(0)
277 // ,fElecPhiTPC(0)
278 // ,fElecPhiTPCEovP(0)
520a29a8 279 ,fHadronPhi(0)
3c56855b 280 ,fHadronPhiTPChalf(0)
bf697dda 281 ,fHadronPhiPt(0)
282 /* ,fTrackHFEcuts(0)
283 ,fTrakPhiSPD1(0)
284 ,fTrakPhiSPD2(0)
285 ,fTrakPhiSPDOr(0)
286 ,fTrakPhiSPDAnd(0)
287 ,fTrackHFEcutsITS(0)
288 */
9866fa7b 289/* ,fNoMixedEvents(0)
a9123929 290 ,fMixStat(0)
291 ,fMixStat1(0)
292 ,fMixedIncElecDphi(0)
293 ,fMixedIncElecDphi1(0)
294 ,fMixedIncElecDphi2(0)
295 ,fMixedIncElecDphi3(0)
296 ,fMixedIncElecDphi4(0)
297 ,fMixedPhotElecDphi(0)
298 ,fMixedPhotElecDphi1(0)
299 ,fMixedPhotElecDphi2(0)
300 ,fMixedPhotElecDphi3(0)
301 ,fMixedPhotElecDphi4(0)
302 ,fMixedSemiIncElecDphi(0)
303 ,fMixedSemiIncElecDphi1(0)
304 ,fMixedSemiIncElecDphi2(0)
305 ,fMixedSemiIncElecDphi3(0)
306 ,fMixedSemiIncElecDphi4(0)
307 ,fMixedDphiULSMassLow(0)
308 ,fMixedDphiULSMassLow1(0)
309 ,fMixedDphiULSMassLow2(0)
310 ,fMixedDphiULSMassLow3(0)
311 ,fMixedDphiULSMassLow4(0)
312 ,fMixedDphiLSMassLow(0)
313 ,fMixedDphiLSMassLow1(0)
314 ,fMixedDphiLSMassLow2(0)
315 ,fMixedDphiLSMassLow3(0)
316 ,fMixedDphiLSMassLow4(0)
9866fa7b 317*/
3c56855b 318 ,fHadronPt(0)
319 ,fCentralityPass(0)
320 ,fCentralityNoPass(0)
0841d73f 321 ,fHadronDphi(0)
322 ,fHadronDphi1(0)
323 ,fHadronDphi2(0)
324 ,fHadronDphi3(0)
325 ,fHadronDphi4(0)
326 ,fPiPt(0)
33369c14 327 ,fHadronDphiNoSS(0)
328 ,fHadronDphiNoSS1(0)
329 ,fHadronDphiNoSS2(0)
330 ,fHadronDphiNoSS3(0)
331 ,fHadronDphiNoSS4(0)
332 ,fPiPtNoSS(0)
bf697dda 333 ,fEovPWoSS(0)
334 ,fEovPWSS(0)
335 ,fEovPHadWoSS(0)
336 ,fEovPHadWSS(0)
0c884279 337 ,fHadronDphiEta1(0)
338 ,fHadronDphiEta11(0)
339 ,fHadronDphiEta12(0)
340 ,fHadronDphiEta13(0)
341 ,fHadronDphiEta14(0)
342 ,fHadronDphiNoSSEta1(0)
343 ,fHadronDphiNoSSEta11(0)
344 ,fHadronDphiNoSSEta12(0)
345 ,fHadronDphiNoSSEta13(0)
346 ,fHadronDphiNoSSEta14(0)
347 ,fHadronDphiEta2(0)
348 ,fHadronDphiEta21(0)
349 ,fHadronDphiEta22(0)
350 ,fHadronDphiEta23(0)
351 ,fHadronDphiEta24(0)
352 ,fHadronDphiNoSSEta2(0)
353 ,fHadronDphiNoSSEta21(0)
354 ,fHadronDphiNoSSEta22(0)
355 ,fHadronDphiNoSSEta23(0)
a9123929 356,fHadronDphiNoSSEta24(0)
357 //,fSparseElectron(0)
358 // ,fvalueElectron(0)
57189f04 359{
360 //Named constructor
520a29a8 361
57189f04 362 fPID = new AliHFEpid("hfePid");
bf697dda 363 //fvalueElectron = new Double_t[6];
57189f04 364
365 // Define input and output slots here
366 // Input slot #0 works with a TChain
367 DefineInput(0, TChain::Class());
368 // Output slot #0 id reserved by the base class for AOD
369 // Output slot #1 writes into a TH1 container
370 // DefineOutput(1, TH1I::Class());
371 DefineOutput(1, TList::Class());
372 // DefineOutput(3, TTree::Class());
373}
374
375//________________________________________________________________________
376AliAnalysisTaskElecHadronCorrel::AliAnalysisTaskElecHadronCorrel()
377 : AliAnalysisTaskSE("DefaultAnalysis_AliAnalysisElecHadCorrel")
987053ce 378 ,fVevent(0)
57189f04 379 ,fESD(0)
987053ce 380 ,fAOD(0)
57189f04 381 ,fGeom(0)
382 ,fOutputList(0)
520a29a8 383 ,fTrackCuts1(new AliESDtrackCuts)
384 ,fTrackCuts2(new AliESDtrackCuts)
57189f04 385 ,fCuts(0)
386 ,fIdentifiedAsOutInz(kFALSE)
387 ,fPassTheEventCut(kFALSE)
388 ,fRejectKinkMother(kFALSE)
4e01b68c 389 ,fVz(0.0)
390 ,fCFM(0)
391 ,fPID(0)
392 ,fPIDqa(0)
57189f04 393 ,fInvmassCut(0.01)
3c56855b 394 ,fCentrality(0)
395 ,fCentralityMin(0)
396 ,fCentralityMax(0)
a9123929 397 ,fkCentralityMethod(0)
398 ,fTPCnsigEleMin(-2)
399 ,fTPCnsigEleMax(2)
400 ,fTPCnsigHadMin(-10)
401 ,fTPCnsigHadMax(-3.5)
402 ,fM02CutMin(0.03)
403 ,fM02CutMax(0.5)
404 ,fM20CutMin(0.03)
405 ,fM20CutMax(0.3)
406 ,fDispCutMin(0)
407 ,fDispCutMax(1)
408 ,fEovPMin(0.8)
409 ,fEovPMax(1.2)
410 ,fTriggerCentral(kTRUE)
9866fa7b 411// ,fPoolMgr(0x0)
bf697dda 412 ,fNoEvents(0)
413 // ,fTrkpt(0)
414 ,fTrkEovPAft(0)
415 // ,fTrkEovPBefHad(0)
416 // ,fdEdxBef(0)
987053ce 417 ,fSemiIncElecDphi(0)
487ae960 418 ,fSemiIncElecDphi1(0)
419 ,fSemiIncElecDphi2(0)
420 ,fSemiIncElecDphi3(0)
421 ,fSemiIncElecDphi4(0)
57189f04 422 ,fPhotElecDphi(0)
487ae960 423 ,fPhotElecDphi1(0)
424 ,fPhotElecDphi2(0)
425 ,fPhotElecDphi3(0)
426 ,fPhotElecDphi4(0)
57189f04 427 ,fInclusiveElecDphi(0)
487ae960 428 ,fInclusiveElecDphi1(0)
429 ,fInclusiveElecDphi2(0)
430 ,fInclusiveElecDphi3(0)
431 ,fInclusiveElecDphi4(0)
33369c14 432 ,fInclusiveElecDphiEtaFS(0)
433 ,fInclusiveElecDphiEtaFS1(0)
434 ,fInclusiveElecDphiEtaFS2(0)
435 ,fInclusiveElecDphiEtaFS3(0)
436 ,fInclusiveElecDphiEtaFS4(0)
57189f04 437 ,fDphiULSMassLow(0)
487ae960 438 ,fDphiULSMassLow1(0)
439 ,fDphiULSMassLow2(0)
440 ,fDphiULSMassLow3(0)
441 ,fDphiULSMassLow4(0)
57189f04 442 ,fDphiLSMassLow(0)
487ae960 443 ,fDphiLSMassLow1(0)
444 ,fDphiLSMassLow2(0)
445 ,fDphiLSMassLow3(0)
446 ,fDphiLSMassLow4(0)
520a29a8 447 ,fDphiULSMassLowNoPartner(0)
487ae960 448 ,fDphiULSMassLowNoPartner1(0)
449 ,fDphiULSMassLowNoPartner2(0)
450 ,fDphiULSMassLowNoPartner3(0)
451 ,fDphiULSMassLowNoPartner4(0)
520a29a8 452 ,fDphiLSMassLowNoPartner(0)
487ae960 453 ,fDphiLSMassLowNoPartner1(0)
454 ,fDphiLSMassLowNoPartner2(0)
455 ,fDphiLSMassLowNoPartner3(0)
456 ,fDphiLSMassLowNoPartner4(0)
57189f04 457 ,fPhotoElecPt(0)
458 ,fSemiInclElecPt(0)
520a29a8 459 ,fInclusiveElecPt(0)
460 ,fULSElecPt(0)
461 ,fLSElecPt(0)
bf697dda 462 ,fSemiIncElecDphiEta1(0)
463 ,fSemiIncElecDphiEta11(0)
464 ,fSemiIncElecDphiEta12(0)
465 ,fSemiIncElecDphiEta13(0)
466 ,fSemiIncElecDphiEta14(0)
467 ,fPhotElecDphiEta1(0)
468 ,fPhotElecDphiEta11(0)
469 ,fPhotElecDphiEta12(0)
470 ,fPhotElecDphiEta13(0)
471 ,fPhotElecDphiEta14(0)
472 ,fInclusiveElecDphiEta1(0)
473 ,fInclusiveElecDphiEta11(0)
474 ,fInclusiveElecDphiEta12(0)
475 ,fInclusiveElecDphiEta13(0)
476 ,fInclusiveElecDphiEta14(0)
477 ,fDphiULSMassLowEta1(0)
478 ,fDphiULSMassLowEta11(0)
479 ,fDphiULSMassLowEta12(0)
480 ,fDphiULSMassLowEta13(0)
481 ,fDphiULSMassLowEta14(0)
482 ,fDphiLSMassLowEta1(0)
483 ,fDphiLSMassLowEta11(0)
484 ,fDphiLSMassLowEta12(0)
485 ,fDphiLSMassLowEta13(0)
486 ,fDphiLSMassLowEta14(0)
487 ,fDphiULSMassLowNoPartnerEta1(0)
488 ,fDphiULSMassLowNoPartnerEta11(0)
489 ,fDphiULSMassLowNoPartnerEta12(0)
490 ,fDphiULSMassLowNoPartnerEta13(0)
491 ,fDphiULSMassLowNoPartnerEta14(0)
492 ,fDphiLSMassLowNoPartnerEta1(0)
493 ,fDphiLSMassLowNoPartnerEta11(0)
494 ,fDphiLSMassLowNoPartnerEta12(0)
495 ,fDphiLSMassLowNoPartnerEta13(0)
496 ,fDphiLSMassLowNoPartnerEta14(0)
497 ,fSemiIncElecDphiEta2(0)
498 ,fSemiIncElecDphiEta21(0)
499 ,fSemiIncElecDphiEta22(0)
500 ,fSemiIncElecDphiEta23(0)
501 ,fSemiIncElecDphiEta24(0)
502 ,fPhotElecDphiEta2(0)
503 ,fPhotElecDphiEta21(0)
504 ,fPhotElecDphiEta22(0)
505 ,fPhotElecDphiEta23(0)
506 ,fPhotElecDphiEta24(0)
507 ,fInclusiveElecDphiEta2(0)
508 ,fInclusiveElecDphiEta21(0)
509 ,fInclusiveElecDphiEta22(0)
510 ,fInclusiveElecDphiEta23(0)
511 ,fInclusiveElecDphiEta24(0)
512 ,fDphiULSMassLowEta2(0)
513 ,fDphiULSMassLowEta21(0)
514 ,fDphiULSMassLowEta22(0)
515 ,fDphiULSMassLowEta23(0)
516 ,fDphiULSMassLowEta24(0)
517 ,fDphiLSMassLowEta2(0)
518 ,fDphiLSMassLowEta21(0)
519 ,fDphiLSMassLowEta22(0)
520 ,fDphiLSMassLowEta23(0)
521 ,fDphiLSMassLowEta24(0)
522 ,fDphiULSMassLowNoPartnerEta2(0)
523 ,fDphiULSMassLowNoPartnerEta21(0)
524 ,fDphiULSMassLowNoPartnerEta22(0)
525 ,fDphiULSMassLowNoPartnerEta23(0)
526 ,fDphiULSMassLowNoPartnerEta24(0)
527 ,fDphiLSMassLowNoPartnerEta2(0)
528 ,fDphiLSMassLowNoPartnerEta21(0)
529 ,fDphiLSMassLowNoPartnerEta22(0)
530 ,fDphiLSMassLowNoPartnerEta23(0)
531 ,fDphiLSMassLowNoPartnerEta24(0)
532 // ,fTrackPtBefTrkCuts(0)
533 // ,fTrackPtAftTrkCuts(0)
534 // ,fTPCnsigma(0)
535 // ,fNCellv1(0)
536 // ,fClsEv1(0)
537 // ,fNClusv1(0)
538 ,fInvmassLS1(0)
539 // ,fInvmassLS2(0)
540 // ,fInvmassLS3(0)
541 // ,fInvmassLS4(0)
542 // ,fInvmassLS5(0)
543 ,fInvmassULS1(0)
544 // ,fInvmassULS2(0)
545 // ,fInvmassULS3(0)
546 // ,fInvmassULS4(0)
547 // ,fInvmassULS5(0)
520a29a8 548 ,fcentrality(0)
549 ,fElecPhi(0)
3c56855b 550 ,fElecPhiTPChalf(0)
bf697dda 551 ,fElecPhiPt(0)
552 // ,fElecPhiTPC(0)
553 // ,fElecPhiTPCEovP(0)
520a29a8 554 ,fHadronPhi(0)
3c56855b 555 ,fHadronPhiTPChalf(0)
bf697dda 556 ,fHadronPhiPt(0)
557 /* ,fTrackHFEcuts(0)
558 ,fTrakPhiSPD1(0)
559 ,fTrakPhiSPD2(0)
560 ,fTrakPhiSPDOr(0)
561 ,fTrakPhiSPDAnd(0)
562 ,fTrackHFEcutsITS(0)
563 */
9866fa7b 564/* ,fNoMixedEvents(0)
a9123929 565 ,fMixStat(0)
566 ,fMixStat1(0)
567 ,fMixedIncElecDphi(0)
568 ,fMixedIncElecDphi1(0)
569 ,fMixedIncElecDphi2(0)
570 ,fMixedIncElecDphi3(0)
571 ,fMixedIncElecDphi4(0)
572 ,fMixedPhotElecDphi(0)
573 ,fMixedPhotElecDphi1(0)
574 ,fMixedPhotElecDphi2(0)
575 ,fMixedPhotElecDphi3(0)
576 ,fMixedPhotElecDphi4(0)
577 ,fMixedSemiIncElecDphi(0)
578 ,fMixedSemiIncElecDphi1(0)
579 ,fMixedSemiIncElecDphi2(0)
580 ,fMixedSemiIncElecDphi3(0)
581 ,fMixedSemiIncElecDphi4(0)
582 ,fMixedDphiULSMassLow(0)
583 ,fMixedDphiULSMassLow1(0)
584 ,fMixedDphiULSMassLow2(0)
585 ,fMixedDphiULSMassLow3(0)
586 ,fMixedDphiULSMassLow4(0)
587 ,fMixedDphiLSMassLow(0)
588 ,fMixedDphiLSMassLow1(0)
589 ,fMixedDphiLSMassLow2(0)
590 ,fMixedDphiLSMassLow3(0)
591 ,fMixedDphiLSMassLow4(0)
9866fa7b 592*/
3c56855b 593 ,fHadronPt(0)
594 ,fCentralityPass(0)
595 ,fCentralityNoPass(0)
0841d73f 596 ,fHadronDphi(0)
597 ,fHadronDphi1(0)
598 ,fHadronDphi2(0)
599 ,fHadronDphi3(0)
600 ,fHadronDphi4(0)
33369c14 601 ,fPiPt(0)
602 ,fHadronDphiNoSS(0)
603 ,fHadronDphiNoSS1(0)
604 ,fHadronDphiNoSS2(0)
605 ,fHadronDphiNoSS3(0)
606 ,fHadronDphiNoSS4(0)
607 ,fPiPtNoSS(0)
bf697dda 608 ,fEovPWoSS(0)
609 ,fEovPWSS(0)
610 ,fEovPHadWoSS(0)
0c884279 611 ,fEovPHadWSS(0)
612 ,fHadronDphiEta1(0)
613 ,fHadronDphiEta11(0)
614 ,fHadronDphiEta12(0)
615 ,fHadronDphiEta13(0)
616 ,fHadronDphiEta14(0)
617 ,fHadronDphiNoSSEta1(0)
618 ,fHadronDphiNoSSEta11(0)
619 ,fHadronDphiNoSSEta12(0)
620 ,fHadronDphiNoSSEta13(0)
621 ,fHadronDphiNoSSEta14(0)
622 ,fHadronDphiEta2(0)
623 ,fHadronDphiEta21(0)
624 ,fHadronDphiEta22(0)
625 ,fHadronDphiEta23(0)
626 ,fHadronDphiEta24(0)
627 ,fHadronDphiNoSSEta2(0)
628 ,fHadronDphiNoSSEta21(0)
629 ,fHadronDphiNoSSEta22(0)
630 ,fHadronDphiNoSSEta23(0)
a9123929 631,fHadronDphiNoSSEta24(0)
632 //,fSparseElectron(0)
633 // ,fvalueElectron(0)
57189f04 634{
520a29a8 635 //Default constructor
636 fPID = new AliHFEpid("hfePid");
bf697dda 637 //fvalueElectron = new Double_t[6];
57189f04 638
520a29a8 639 // Constructor
4e01b68c 640 // Define input and output slots here
641 // Input slot #0 works with a TChain
642 DefineInput(0, TChain::Class());
643 // Output slot #0 id reserved by the base class for AOD
644 // Output slot #1 writes into a TH1 container
645 // DefineOutput(1, TH1I::Class());
646 DefineOutput(1, TList::Class());
647 //DefineOutput(3, TTree::Class());
57189f04 648}
649//_________________________________________
650
651AliAnalysisTaskElecHadronCorrel::~AliAnalysisTaskElecHadronCorrel()
652{
4e01b68c 653 //Destructor
654
655 delete fOutputList;
656 delete fGeom;
657 delete fPID;
658 delete fCFM;
659 delete fPIDqa;
660 delete fTrackCuts1;
661 delete fTrackCuts2;
bf697dda 662 // delete fSparseElectron;
663 // delete []fvalueElectron;
57189f04 664}
665//_________________________________________
666
667void AliAnalysisTaskElecHadronCorrel::UserExec(Option_t*)
668{
4e01b68c 669 //Main loop
670 //Called for each event
671
672 // create pointer to event
987053ce 673 fAOD = dynamic_cast<AliAODEvent*>(InputEvent());
4e01b68c 674 fESD = dynamic_cast<AliESDEvent*>(InputEvent());
bf697dda 675
987053ce 676 if(!(fESD || fAOD)){
677 printf("ERROR: fESD & fAOD not available\n");
678 return;
679 }
680 fVevent = dynamic_cast<AliVEvent*>(InputEvent());
681 if (!fVevent) {
682 printf("ERROR: fVEvent not available\n");
4e01b68c 683 return;
684 }
520a29a8 685
4e01b68c 686 if(!fCuts){
687 AliError("HFE cuts not available");
688 return;
689 }
690
691 if(!fPID->IsInitialized()){
692 // Initialize PID with the given run number
693 AliWarning("PID not initialised, get from Run no");
a9123929 694
987053ce 695 if(IsAODanalysis())fPID->InitializePID(fAOD->GetRunNumber());
696 else fPID->InitializePID(fESD->GetRunNumber());
4e01b68c 697 }
698
520a29a8 699
a9123929 700 if(fTriggerCentral){
701 // trigger selection
702 if(!(((AliInputEventHandler*)(AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler()))->IsEventSelected() & (AliVEvent::kCentral))) return;
703 }
704
705 if(!fTriggerCentral){
706 // trigger selection
707 if(!(((AliInputEventHandler*)(AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler()))->IsEventSelected() & (AliVEvent::kSemiCentral))) return;
708 }
987053ce 709 // centrality selection
a9123929 710 // SetCentralityParameters(0., 7., "V0M");
987053ce 711 Bool_t pass = kFALSE;
712 CheckCentrality(fVevent,pass);
e4b0faf2 713 if(!pass)return;
714
987053ce 715 Int_t fNOtrks = fVevent->GetNumberOfTracks();
716 const AliVVertex *pVtx = fVevent->GetPrimaryVertex();
520a29a8 717
4e01b68c 718 Double_t pVtxZ = -999;
719 pVtxZ = pVtx->GetZ();
520a29a8 720
4e01b68c 721 if(TMath::Abs(pVtxZ)>10) return;
722 fNoEvents->Fill(0);
723
724 if(fNOtrks<2) return;
725
726 AliPIDResponse *pidResponse = fInputHandler->GetPIDResponse();
727 if(!pidResponse){
728 AliDebug(1, "Using default PID Response");
a9123929 729 pidResponse = AliHFEtools::GetDefaultPID(kFALSE, fInputEvent->IsA() == AliAODEvent::Class());
730 }
731
732 fPID->SetPIDResponse(pidResponse);
733
734 fCFM->SetRecEventInfo(fVevent);
735
736 AliCentrality *fCentrality2 = (AliCentrality*)fAOD->GetCentrality();
737 Double_t centvalue1 = fCentrality2->GetCentralityPercentile("V0M");
9866fa7b 738/*
a9123929 739 //Event mixing
740 AliEventPool* pool = fPoolMgr->GetEventPool(centvalue1, pVtxZ); // Get the buffer associated with the current centrality and z-vtx
741 if (!pool)
742 AliFatal(Form("No pool found for centrality = %f, zVtx = %f", centvalue1, pVtxZ));
9866fa7b 743*/
a9123929 744 // Look for kink mother for AOD
745 Double_t *listofmotherkink =0;
746 Int_t numberofvertices = 0, numberofmotherkink = 0;
747 if(IsAODanalysis()){
748 numberofvertices = fAOD->GetNumberOfVertices();
749 listofmotherkink = new Double_t[numberofvertices];
750 for(Int_t ivertex=0; ivertex < numberofvertices; ivertex++) {
751 AliAODVertex *aodvertex = fAOD->GetVertex(ivertex);
752 if(!aodvertex) continue;
753 if(aodvertex->GetType()==AliAODVertex::kKink) {
754 AliAODTrack *mother = (AliAODTrack *) aodvertex->GetParent();
755 if(!mother) continue;
756 Int_t idmother = mother->GetID();
757 listofmotherkink[numberofmotherkink] = idmother;
758 numberofmotherkink++;
759 }
760 }
761 }
762
763 // Track loop
764 for (Int_t iTracks = 0; iTracks < fVevent->GetNumberOfTracks(); iTracks++) {
765 AliVParticle* Vtrack = fVevent->GetTrack(iTracks);
766 if (!Vtrack) {
767 printf("ERROR: Could not receive track %d\n", iTracks);
768 continue;
769 }
770 AliVTrack *track = dynamic_cast<AliVTrack*>(Vtrack);
771 AliESDtrack *etrack = dynamic_cast<AliESDtrack*>(Vtrack);
772 AliAODTrack *atrack = dynamic_cast<AliAODTrack*>(Vtrack);
773
774 if(IsAODanalysis())
775 if(!atrack->TestFilterMask(AliAODTrack::kTrkGlobalNoDCA)) continue;
776
777 if(track->Pt()<1) continue;
778
779 // fTrackPtBefTrkCuts->Fill(track->Pt());
780
781 // RecKine: ITSTPC cuts
782 if(!ProcessCutStep(AliHFEcuts::kStepRecKineITSTPC, track)) continue;
783
784 // Reject kink mother
785 if(fRejectKinkMother) { // Quick and dirty fix to reject both kink mothers and daughters
786 if(IsAODanalysis()){
787 Bool_t kinkmotherpass = kTRUE;
788 for(Int_t kinkmother = 0; kinkmother < numberofmotherkink; kinkmother++) {
789 if(track->GetID() == listofmotherkink[kinkmother]) {
790 kinkmotherpass = kFALSE;
791 continue;
792 }
bf697dda 793 }
a9123929 794 if(!kinkmotherpass) continue;
795 }
796 else{
797 if(etrack->GetKinkIndex(0) != 0) continue;
798 }
799 }
800 // RecPrim
801 // if(!ProcessCutStep(AliHFEcuts::kStepRecPrim, track)) continue; //gives warning for AOD, so not using
802
803 // HFE cuts: TPC PID cleanup
804 if(!ProcessCutStep(AliHFEcuts::kStepHFEcutsTPC, track)) continue;
805
806 // fTrackHFEcuts->Fill(track->Phi());
807
808 // HFEcuts: ITS layers cuts
809 if(!ProcessCutStep(AliHFEcuts::kStepHFEcutsITS, track)) continue;
810
811 // fTrackHFEcutsITS->Fill(track->Phi());
812 //fTrackPtAftTrkCuts->Fill(track->Pt());
813
814 Double_t fClsE = -999, p = -999, fEovP=-999, pt = -999, dEdx=-999, fTPCnSigma=0;
815 pt = track->Pt();
816 p = track->P();
817 dEdx = track->GetTPCsignal();
818 fTPCnSigma = fPID->GetPIDResponse() ? fPID->GetPIDResponse()->NumberOfSigmasTPC(track, AliPID::kElectron) : 1000;
819
820 //TPC electron phi
821 // if(fTPCnSigma >= -2 && fTPCnSigma <= 2){
822 // fElecPhiTPC->Fill(track->Phi());
823 // }
824
825 //eta cut (-0.7,0.7)
826 if(track->Eta() < -0.7 || track->Eta() > 0.7) continue;
827
828 // Track extrapolation to EMCAL
829 Int_t fClsId = track->GetEMCALcluster();
830 if(fClsId <0) continue;
831 AliVCluster *cluster = fVevent->GetCaloCluster(fClsId);
832 if(!cluster->IsEMCAL()) continue;
833 if(TMath::Abs(cluster->GetTrackDx())>0.05 || TMath::Abs(cluster->GetTrackDz())>0.05) continue;
834 // fdEdxBef->Fill(p,dEdx);
835 //fTPCnsigma->Fill(p,fTPCnSigma);
836
837 // fTrkpt->Fill(pt);
838 fClsE = cluster->E();
839 fEovP = fClsE/p;
840
841 //--------THnsparse---------
842 //fvalueElectron[0] = pt;
843 //fvalueElectron[1] = fTPCnSigma;
844 //fvalueElectron[2] = fEovP;
845 //fvalueElectron[3] = cluster->GetM20();
846 //fvalueElectron[4] = cluster->GetM02();
847 //fvalueElectron[5] = cluster->GetDispersion();
848
849 //fSparseElectron->Fill(fvalueElectron);
850
851 //----------------
852 //EovP distribution for Had
853 if((fTPCnSigma > fTPCnsigHadMin) && (fTPCnSigma < fTPCnsigHadMax)) fEovPHadWoSS->Fill(pt,fEovP);
854 if(((fTPCnSigma > fTPCnsigHadMin) && (fTPCnSigma < fTPCnsigHadMax)) && ((cluster->GetM20()> fM20CutMin) && (cluster->GetM20()< fM20CutMax)) && ((cluster->GetM02()> fM02CutMin) && (cluster->GetM02()< fM02CutMax)) && ((cluster->GetDispersion()< fDispCutMax))) fEovPHadWSS->Fill(pt,fEovP);
855
856 //Dphi distribution hadrons with shower shape cuts
857 if(((fTPCnSigma > fTPCnsigHadMin) && (fTPCnSigma < fTPCnsigHadMax)) && ((cluster->GetM20()> fM20CutMin) && (cluster->GetM20()< fM20CutMax)) && ((cluster->GetM02()> fM02CutMin) && (cluster->GetM02()< fM02CutMax)) && ((cluster->GetDispersion()< fDispCutMax))&&(fEovP >= fEovPMin && fEovP <= fEovPMax)){
858 ElectronHadCorrel(iTracks, track, fHadronDphi, fHadronDphi1,fHadronDphi2,fHadronDphi3,fHadronDphi4);
859 ElectronHadCorrelEtaBins(iTracks, track, fHadronDphiEta1, fHadronDphiEta11,fHadronDphiEta12,fHadronDphiEta13,fHadronDphiEta14,fHadronDphiEta2, fHadronDphiEta21,fHadronDphiEta22,fHadronDphiEta23,fHadronDphiEta24);
860 fPiPt->Fill(pt);
861 }
862
863 //Dphi distribution hadrons without shower shape cuts
864 if((fTPCnSigma > fTPCnsigHadMin) && (fTPCnSigma < fTPCnsigHadMax)&&(fEovP >= fEovPMin && fEovP <= fEovPMax)){
865 ElectronHadCorrel(iTracks, track, fHadronDphiNoSS, fHadronDphiNoSS1,fHadronDphiNoSS2,fHadronDphiNoSS3,fHadronDphiNoSS4);
866 ElectronHadCorrelEtaBins(iTracks, track, fHadronDphiNoSSEta1, fHadronDphiNoSSEta11,fHadronDphiNoSSEta12,fHadronDphiNoSSEta13,fHadronDphiNoSSEta14,fHadronDphiNoSSEta2, fHadronDphiNoSSEta21,fHadronDphiNoSSEta22,fHadronDphiNoSSEta23,fHadronDphiNoSSEta24);
867 fPiPtNoSS->Fill(pt);
868 }
869
870 //Electron id with TPC
871 if(fTPCnSigma < fTPCnsigEleMin || fTPCnSigma > fTPCnsigEleMax) continue;
872 fEovPWoSS->Fill(pt,fEovP);
873 // fElecPhiTPCEovP->Fill(track->Phi());
874
875 //Electron id with shower shape
876 if(cluster->GetM20()< fM20CutMin || cluster->GetM20()> fM20CutMax || cluster->GetM02()< fM02CutMin || cluster->GetM02()> fM02CutMax || cluster->GetDispersion()> fDispCutMax) continue;
877 fEovPWSS->Fill(pt,fEovP);
878
879 //Electron id with E/p
880 if(fEovP < fEovPMin || fEovP > fEovPMax) continue;
881
882 fTrkEovPAft->Fill(pt,fEovP);
883 fElecPhi->Fill(track->Phi());
884 fElecPhiPt->Fill(track->Phi(),track->Pt());
885 if (track->Eta() >0 && track->Eta() <0.7) fElecPhiTPChalf->Fill(track->Phi());
886
887 HadronInfo(iTracks);
888
889 Bool_t fFlagPhotonicElec = kFALSE;
890 // select photonic electron
891 SelectPhotonicElectron(iTracks,track,fFlagPhotonicElec);
892
893 //Inclusive electron-hadron correlation
894 ElectronHadCorrel(iTracks, track, fInclusiveElecDphi, fInclusiveElecDphi1,fInclusiveElecDphi2,fInclusiveElecDphi3,fInclusiveElecDphi4);
895 fInclusiveElecPt->Fill(pt);
9866fa7b 896 //MixedEvent(track,fMixedIncElecDphi, fMixedIncElecDphi1,fMixedIncElecDphi2, fMixedIncElecDphi3, fMixedIncElecDphi4);
a9123929 897
898 //Dphi in Eta bins
899 ElectronHadCorrelEtaBins(iTracks, track, fInclusiveElecDphiEta1, fInclusiveElecDphiEta11,fInclusiveElecDphiEta12,fInclusiveElecDphiEta13,fInclusiveElecDphiEta14,fInclusiveElecDphiEta2, fInclusiveElecDphiEta21,fInclusiveElecDphiEta22,fInclusiveElecDphiEta23,fInclusiveElecDphiEta24);
900
901 //Inclusive electron-hadron correlation far eta side
902 ElectronHadCorrelEtaFarSide(iTracks, track, fInclusiveElecDphiEtaFS, fInclusiveElecDphiEtaFS1,fInclusiveElecDphiEtaFS2,fInclusiveElecDphiEtaFS3,fInclusiveElecDphiEtaFS4);
9866fa7b 903 // MixedEvent(track,fMixedIncElecDphi, fMixedIncElecDphi1,fMixedIncElecDphi2, fMixedIncElecDphi3, fMixedIncElecDphi4);
a9123929 904
905 // photonic electron
906 if(fFlagPhotonicElec){
907 //Electron hadron correlation
908 ElectronHadCorrel(iTracks, track, fPhotElecDphi,fPhotElecDphi1,fPhotElecDphi2,fPhotElecDphi3,fPhotElecDphi4);
909 fPhotoElecPt->Fill(pt);
9866fa7b 910// MixedEvent(track,fMixedPhotElecDphi, fMixedPhotElecDphi1,fMixedPhotElecDphi2, fMixedPhotElecDphi3, fMixedPhotElecDphi4);
a9123929 911
912 //Dphi in Eta bins
913 ElectronHadCorrelEtaBins(iTracks, track, fPhotElecDphiEta1,fPhotElecDphiEta11,fPhotElecDphiEta12,fPhotElecDphiEta13,fPhotElecDphiEta14,fPhotElecDphiEta2,fPhotElecDphiEta21,fPhotElecDphiEta22,fPhotElecDphiEta23,fPhotElecDphiEta24);
914 }
915
916 // Semi inclusive electron
917 if(!fFlagPhotonicElec){
918 //Electron hadron correlation
919 ElectronHadCorrel(iTracks, track, fSemiIncElecDphi, fSemiIncElecDphi1,fSemiIncElecDphi2,fSemiIncElecDphi3,fSemiIncElecDphi4);
920 fSemiInclElecPt->Fill(pt);
9866fa7b 921// MixedEvent(track,fMixedSemiIncElecDphi,fMixedSemiIncElecDphi1,fMixedSemiIncElecDphi2, fMixedSemiIncElecDphi3, fMixedSemiIncElecDphi4);
a9123929 922
923 //Dphi in Eta bins
924 ElectronHadCorrelEtaBins(iTracks, track, fSemiIncElecDphiEta1, fSemiIncElecDphiEta11,fSemiIncElecDphiEta12,fSemiIncElecDphiEta13,fSemiIncElecDphiEta14,fSemiIncElecDphiEta2, fSemiIncElecDphiEta21,fSemiIncElecDphiEta22,fSemiIncElecDphiEta23,fSemiIncElecDphiEta24);
925 }
926 }
927 /* //EMC clusters
928 Int_t clsNo = fVevent->GetNumberOfCaloClusters();
929 fNClusv1->Fill(clsNo);
930 for(Int_t iclus=0; iclus<clsNo ; iclus++){
931 AliVCluster* clus = fVevent->GetCaloCluster(iclus);
932 if(!clus->IsEMCAL()) continue;
933 fNCellv1->Fill(clus->GetNCells());
934 fClsEv1->Fill(clus->E());
935 }
936 */
9866fa7b 937/*
a9123929 938 TObjArray* tracksClone = CloneAndReduceTrackList();
939 tracksClone->SetOwner();
940 pool->UpdatePool(tracksClone);
9866fa7b 941*/
a9123929 942 delete listofmotherkink;
943 PostData(1, fOutputList);
57189f04 944}
945//_________________________________________
946void AliAnalysisTaskElecHadronCorrel::UserCreateOutputObjects()
947{
948 //Create histograms
987053ce 949
950 AliDebug(3, "Creating Output Objects");
951 // Automatic determination of the analysis mode
952 AliVEventHandler *inputHandler = dynamic_cast<AliVEventHandler *>(AliAnalysisManager::GetAnalysisManager()->GetInputEventHandler());
953 if(!TString(inputHandler->IsA()->GetName()).CompareTo("AliAODInputHandler")){
954 SetAODAnalysis();
955 } else {
956 SetESDAnalysis();
957 }
958 printf("Analysis Mode: %s Analysis\n", IsAODanalysis() ? "AOD" : "ESD");
520a29a8 959
57189f04 960 //--------Initialize PID
961 fPID->SetHasMCData(kFALSE);
962 if(!fPID->GetNumberOfPIDdetectors())
520a29a8 963 {
964 fPID->AddDetector("TPC", 0);
965 fPID->AddDetector("EMCAL", 1);
966 }
967
57189f04 968 fPID->SortDetectors();
969 fPIDqa = new AliHFEpidQAmanager();
970 fPIDqa->Initialize(fPID);
520a29a8 971
57189f04 972 //--------Initialize correction Framework and Cuts
973 fCFM = new AliCFManager;
974 const Int_t kNcutSteps = AliHFEcuts::kNcutStepsMCTrack + AliHFEcuts::kNcutStepsRecTrack + AliHFEcuts::kNcutStepsDETrack;
975 fCFM->SetNStepParticle(kNcutSteps);
976 for(Int_t istep = 0; istep < kNcutSteps; istep++)
977 fCFM->SetParticleCutsList(istep, NULL);
520a29a8 978
57189f04 979 if(!fCuts){
980 AliWarning("Cuts not available. Default cuts will be used");
981 fCuts = new AliHFEcuts;
982 fCuts->CreateStandardCuts();
983 }
987053ce 984
985 if(IsAODanalysis()) fCuts->SetAOD();
57189f04 986 fCuts->Initialize(fCFM);
9866fa7b 987/*
4e01b68c 988 //Mixed event initialising
989 Int_t trackDepth = 2000;
990 Int_t poolsize = 1000;
991
992 Int_t nCentralityBins = 5;
487ae960 993 Int_t nZvtxBins = 4;
a9123929 994 Double_t CentralityBins[6];
995 Double_t CentralityBinsSC[7];
996 Double_t vertexBins[5];
997 if(fTriggerCentral)
998 {
999 CentralityBins[0] = 0;
1000 CentralityBins[1] = 2;
1001 CentralityBins[2] = 4;
1002 CentralityBins[3] = 6;
1003 CentralityBins[4] = 8;
1004 CentralityBins[5] = 10;
1005
1006 vertexBins[0] = -10;
1007 vertexBins[1] = -5;
1008 vertexBins[2] = 0;
1009 vertexBins[3] = 5;
1010 vertexBins[4] = 10;
1011 fPoolMgr = new AliEventPoolManager(poolsize, trackDepth, nCentralityBins, (Double_t*) CentralityBins, nZvtxBins, (Double_t*) vertexBins);
1012 }
1013
1014
1015 if(!fTriggerCentral)
1016 {
1017 CentralityBinsSC[0] = 20;
1018 CentralityBinsSC[1] = 25;
1019 CentralityBinsSC[2] = 30;
1020 CentralityBinsSC[3] = 35;
1021 CentralityBinsSC[4] = 40;
1022 CentralityBinsSC[5] = 45;
1023 CentralityBinsSC[6] = 50;
1024
1025 vertexBins[0] = -10;
1026 vertexBins[1] = -5;
1027 vertexBins[2] = 0;
1028 vertexBins[3] = 5;
1029 vertexBins[4] = 10;
1030 fPoolMgr = new AliEventPoolManager(poolsize, trackDepth, nCentralityBins, (Double_t*) CentralityBinsSC, nZvtxBins, (Double_t*) vertexBins);
1031 }
9866fa7b 1032*/
4e01b68c 1033
57189f04 1034 //---------Output Tlist
1035 fOutputList = new TList();
1036 fOutputList->SetOwner();
1037 fOutputList->Add(fPIDqa->MakeList("PIDQA"));
520a29a8 1038
57189f04 1039 fNoEvents = new TH1F("fNoEvents","",1,0,1) ;
1040 fOutputList->Add(fNoEvents);
520a29a8 1041
1042 fcentrality = new TH1F("fcentrality","centrality", 100,0,100);
1043 fOutputList->Add(fcentrality);
987053ce 1044
bf697dda 1045 // fTrkpt = new TH1F("fTrkpt","track pt",1000,0,50);
1046 // fOutputList->Add(fTrkpt);
1047
1048 // fTrackPtBefTrkCuts = new TH1F("fTrackPtBefTrkCuts","track pt before track cuts",1000,0,50);
1049 // fOutputList->Add(fTrackPtBefTrkCuts);
520a29a8 1050
bf697dda 1051 // fTrackPtAftTrkCuts = new TH1F("fTrackPtAftTrkCuts","track pt after track cuts",1000,0,50);
1052 // fOutputList->Add(fTrackPtAftTrkCuts);
520a29a8 1053
bf697dda 1054 // fTPCnsigma = new TH2F("fTPCnsigma", "TPC - n sigma",1000,0,50,200,-10,10);
1055 // fOutputList->Add(fTPCnsigma);
987053ce 1056
94b12681 1057 fTrkEovPAft = new TH2F("fTrkEovPAft","track E/p after HFE pid",1000,0,50,100,0,2);
1058 fOutputList->Add(fTrkEovPAft);
520a29a8 1059
bf697dda 1060 // fTrkEovPBefHad = new TH2F("fTrkEovPBefHad","track E/p for TPCnsig < 3.5",1000,0,50,100,0,2);
1061 // fOutputList->Add(fTrkEovPBefHad);
520a29a8 1062
bf697dda 1063 // fdEdxBef = new TH2F("fdEdxBef","track dEdx vs p before HFE pid",1000,0,50,150,0,150);
1064 // fOutputList->Add(fdEdxBef);
520a29a8 1065
520a29a8 1066 fElecPhi = new TH1F("fElecPhi", "Electron phi",1000,0,6.28);
1067 fOutputList->Add(fElecPhi);
1068
3c56855b 1069 fElecPhiPt = new TH2F("fElecPhiPt", "Electron phi vs pt; Electron phi; pt (GeV/c)",1000,0,6.28,1000,0,100);
1070 fOutputList->Add(fElecPhiPt);
1071
1072 fElecPhiTPChalf = new TH1F("fElecPhiTPChalf", "Electron phi for 0<eta<0.7",1000,0,6.28);
1073 fOutputList->Add(fElecPhiTPChalf);
1074
bf697dda 1075 /* fElecPhiTPC = new TH1F("fElecPhiTPC", "Electron phi after TPC cut",1000,0,6.28);
1076 fOutputList->Add(fElecPhiTPC);
4e01b68c 1077
bf697dda 1078 fElecPhiTPCEovP = new TH1F("fElecPhiTPCEovP", "Electron phi after TPC and E/p cut",1000,0,6.28);
1079 fOutputList->Add(fElecPhiTPCEovP);
1080 */
520a29a8 1081 fHadronPhi = new TH1F("fHadronPhi", "Hadron phi",1000,0,6.28);
1082 fOutputList->Add(fHadronPhi);
1083
3c56855b 1084 fHadronPhiTPChalf = new TH1F("fHadronPhiTPChalf", "Hadron phi for 0<eta<0.9",1000,0,6.28);
1085 fOutputList->Add(fHadronPhiTPChalf);
1086
1087 fHadronPhiPt = new TH2F("fHadronPhiPt", "Hadron phi vs pt; hadron phi; pt (GeV/c)",1000,0,6.28,1000,0,100);
1088 fOutputList->Add(fHadronPhiPt);
1089
bf697dda 1090 /*
1091 fTrackHFEcuts = new TH1F("fTrackHFEcuts","Track phi for HFE cuts",1000,0,6.28);
1092 fOutputList->Add(fTrackHFEcuts);
4e01b68c 1093
bf697dda 1094 fTrakPhiSPD1 = new TH1F("fTrakPhiSPD1","Track phi for hit in SPD layer 1",1000,0,6.28);
1095 fOutputList->Add(fTrakPhiSPD1);
4e01b68c 1096
bf697dda 1097 fTrakPhiSPD2 = new TH1F("fTrakPhiSPD2","Track phi for hit in SPD layer 2",1000,0,6.28);
1098 fOutputList->Add(fTrakPhiSPD2);
4e01b68c 1099
bf697dda 1100 fTrakPhiSPDOr = new TH1F("fTrakPhiSPDOr","Track phi for hit in any SPD layer",1000,0,6.28);
1101 fOutputList->Add(fTrakPhiSPDOr);
4e01b68c 1102
bf697dda 1103 fTrakPhiSPDAnd = new TH1F("fTrakPhiSPDAnd","Track phi for hit in both SPD layer",1000,0,6.28);
1104 fOutputList->Add(fTrakPhiSPDAnd);
4e01b68c 1105
bf697dda 1106 fTrackHFEcutsITS = new TH1F("fTrackHFEcutsITS","Track phi for HFE cuts + ITS HFE cuts",1000,0,6.28);
1107 fOutputList->Add(fTrackHFEcutsITS);
1108 */
0523ddd5 1109 fSemiIncElecDphi = new TH2F("fSemiIncElecDphi", "Semi Inclusive elec-had Dphi correlation",200,0,20,64,-1.57,4.71);
57189f04 1110 fOutputList->Add(fSemiIncElecDphi);
520a29a8 1111
a9123929 1112 fSemiIncElecDphi1 = new TH2F("fSemiIncElecDphi1", "Semi Inclusive elec-had Dphi correlation for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
487ae960 1113 fOutputList->Add(fSemiIncElecDphi1);
1114
a9123929 1115 fSemiIncElecDphi2 = new TH2F("fSemiIncElecDphi2", "Semi Inclusive elec-had Dphi correlation for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
487ae960 1116 fOutputList->Add(fSemiIncElecDphi2);
1117
a9123929 1118 fSemiIncElecDphi3 = new TH2F("fSemiIncElecDphi3", "Semi Inclusive elec-had Dphi correlation for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
487ae960 1119 fOutputList->Add(fSemiIncElecDphi3);
1120
a9123929 1121 fSemiIncElecDphi4 = new TH2F("fSemiIncElecDphi4", "Semi Inclusive elec-had Dphi correlation for 4<pt^{asso}<10",200,0,20,64,-1.57,4.71);
487ae960 1122 fOutputList->Add(fSemiIncElecDphi4);
1123
0523ddd5 1124 fPhotElecDphi = new TH2F("fPhotElecDphi", "Photon elec-had Dphi correlation",200,0,20,64,-1.57,4.71);
57189f04 1125 fOutputList->Add(fPhotElecDphi);
520a29a8 1126
a9123929 1127 fPhotElecDphi1 = new TH2F("fPhotElecDphi1", "Photon elec-had Dphi correlation for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
487ae960 1128 fOutputList->Add(fPhotElecDphi1);
1129
a9123929 1130 fPhotElecDphi2 = new TH2F("fPhotElecDphi2", "Photon elec-had Dphi correlation for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
487ae960 1131 fOutputList->Add(fPhotElecDphi2);
1132
a9123929 1133 fPhotElecDphi3 = new TH2F("fPhotElecDphi3", "Photon elec-had Dphi correlation for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
487ae960 1134 fOutputList->Add(fPhotElecDphi3);
1135
a9123929 1136 fPhotElecDphi4 = new TH2F("fPhotElecDphi4", "Photon elec-had Dphi correlation for 4<pt^{asso}<10",200,0,20,64,-1.57,4.71);
487ae960 1137 fOutputList->Add(fPhotElecDphi4);
1138
0523ddd5 1139 fInclusiveElecDphi = new TH2F("fInclusiveElecDphi", "Inclusive elec-had Dphi correlation",200,0,20,64,-1.57,4.71);
57189f04 1140 fOutputList->Add(fInclusiveElecDphi);
520a29a8 1141
a9123929 1142 fInclusiveElecDphi1 = new TH2F("fInclusiveElecDphi1", "Inclusive elec-had Dphi correlation for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
487ae960 1143 fOutputList->Add(fInclusiveElecDphi1);
1144
a9123929 1145 fInclusiveElecDphi2 = new TH2F("fInclusiveElecDphi2", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
487ae960 1146 fOutputList->Add(fInclusiveElecDphi2);
1147
a9123929 1148 fInclusiveElecDphi3 = new TH2F("fInclusiveElecDphi3", "Inclusive elec-had Dphi correlation for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
487ae960 1149 fOutputList->Add(fInclusiveElecDphi3);
1150
a9123929 1151 fInclusiveElecDphi4 = new TH2F("fInclusiveElecDphi4", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<10",200,0,20,64,-1.57,4.71);
487ae960 1152 fOutputList->Add(fInclusiveElecDphi4);
1153
33369c14 1154 fInclusiveElecDphiEtaFS = new TH2F("fInclusiveElecDphiEtaFS", "Inclusive elec-had Dphi correlation (hadron 1<eta<1.6)",200,0,20,64,-1.57,4.71);
1155 fOutputList->Add(fInclusiveElecDphiEtaFS);
1156
a9123929 1157 fInclusiveElecDphiEtaFS1 = new TH2F("fInclusiveElecDphiEtaFS1", "Inclusive elec-had Dphi correlation for 2<pt^{asso}<4 (hadron 1<eta<1.6)",200,0,20,64,-1.57,4.71);
33369c14 1158 fOutputList->Add(fInclusiveElecDphiEtaFS1);
1159
a9123929 1160 fInclusiveElecDphiEtaFS2 = new TH2F("fInclusiveElecDphiEtaFS2", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<6 (hadron 1<eta<1.6)",200,0,20,64,-1.57,4.71);
33369c14 1161 fOutputList->Add(fInclusiveElecDphiEtaFS2);
1162
a9123929 1163 fInclusiveElecDphiEtaFS3 = new TH2F("fInclusiveElecDphiEtaFS3", "Inclusive elec-had Dphi correlation for 6<pt^{asso}<8 (hadron 1<eta<1.6)",200,0,20,64,-1.57,4.71);
33369c14 1164 fOutputList->Add(fInclusiveElecDphiEtaFS3);
1165
a9123929 1166 fInclusiveElecDphiEtaFS4 = new TH2F("fInclusiveElecDphiEtaFS4", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<10 (hadron 1<eta<1.6)",200,0,20,64,-1.57,4.71);
33369c14 1167 fOutputList->Add(fInclusiveElecDphiEtaFS4);
1168
0523ddd5 1169 fDphiULSMassLow = new TH2F("fDphiULSMassLow", "e-h Dphi ULS, mass<cut",200,0,20,64,-1.57,4.71);
57189f04 1170 fOutputList->Add(fDphiULSMassLow);
520a29a8 1171
a9123929 1172 fDphiULSMassLow1 = new TH2F("fDphiULSMassLow1", "e-h Dphi ULS, mass<cut for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
487ae960 1173 fOutputList->Add(fDphiULSMassLow1);
1174
a9123929 1175 fDphiULSMassLow2 = new TH2F("fDphiULSMassLow2", "e-h Dphi ULS, mass<cut for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
487ae960 1176 fOutputList->Add(fDphiULSMassLow2);
1177
a9123929 1178 fDphiULSMassLow3 = new TH2F("fDphiULSMassLow3", "e-h Dphi ULS, mass<cut for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
487ae960 1179 fOutputList->Add(fDphiULSMassLow3);
1180
a9123929 1181 fDphiULSMassLow4 = new TH2F("fDphiULSMassLow4", "e-h Dphi ULS, mass<cut for 4<pt^{asso}<10",200,0,20,64,-1.57,4.71);
487ae960 1182 fOutputList->Add(fDphiULSMassLow4);
1183
0523ddd5 1184 fDphiLSMassLow = new TH2F("fDphiLSMassLow", "e-h Dphi LS, mass<cut",200,0,20,64,-1.57,4.71);
57189f04 1185 fOutputList->Add(fDphiLSMassLow);
520a29a8 1186
a9123929 1187 fDphiLSMassLow1 = new TH2F("fDphiLSMassLow1", "e-h Dphi LS, mass<cut for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
487ae960 1188 fOutputList->Add(fDphiLSMassLow1);
1189
a9123929 1190 fDphiLSMassLow2 = new TH2F("fDphiLSMassLow2", "e-h Dphi LS, mass<cut for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
487ae960 1191 fOutputList->Add(fDphiLSMassLow2);
1192
a9123929 1193 fDphiLSMassLow3 = new TH2F("fDphiLSMassLow3", "e-h Dphi LS, mass<cut for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
487ae960 1194 fOutputList->Add(fDphiLSMassLow3);
1195
a9123929 1196 fDphiLSMassLow4 = new TH2F("fDphiLSMassLow4", "e-h Dphi LS, mass<cut for 8<pt^{asso}<10",200,0,20,64,-1.57,4.71);
487ae960 1197 fOutputList->Add(fDphiLSMassLow4);
1198
0523ddd5 1199 fDphiULSMassLowNoPartner = new TH2F("fDphiULSMassLowNoPartner", "e-h Dphi ULS with no partner, mass<mass cut,",200,0,20,64,-1.57,4.71);
520a29a8 1200 fOutputList->Add(fDphiULSMassLowNoPartner);
1201
a9123929 1202 fDphiULSMassLowNoPartner1 = new TH2F("fDphiULSMassLowNoPartner1", "e-h Dphi ULS with no partner, mass<mass cut for 2<pt^{asso}<4,",200,0,20,64,-1.57,4.71);
487ae960 1203 fOutputList->Add(fDphiULSMassLowNoPartner1);
1204
a9123929 1205 fDphiULSMassLowNoPartner2 = new TH2F("fDphiULSMassLowNoPartner2", "e-h Dphi ULS with no partner, mass<mass cut for 4<pt^{asso}<6,",200,0,20,64,-1.57,4.71);
487ae960 1206 fOutputList->Add(fDphiULSMassLowNoPartner2);
1207
a9123929 1208 fDphiULSMassLowNoPartner3 = new TH2F("fDphiULSMassLowNoPartner3", "e-h Dphi ULS with no partner, mass<mass cut for 6<pt^{asso}<8,",200,0,20,64,-1.57,4.71);
487ae960 1209 fOutputList->Add(fDphiULSMassLowNoPartner3);
1210
a9123929 1211 fDphiULSMassLowNoPartner4 = new TH2F("fDphiULSMassLowNoPartner4", "e-h Dphi ULS with no partner, mass<mass cut for 4<pt^{asso}<10,",200,0,20,64,-1.57,4.71);
487ae960 1212 fOutputList->Add(fDphiULSMassLowNoPartner4);
1213
0523ddd5 1214 fDphiLSMassLowNoPartner = new TH2F("fDphiLSMassLowNoPartner", "e-h Dphi LS with no partner, mass<mass cut",200,0,20,64,-1.57,4.71);
520a29a8 1215 fOutputList->Add(fDphiLSMassLowNoPartner);
1216
a9123929 1217 fDphiLSMassLowNoPartner1 = new TH2F("fDphiLSMassLowNoPartner1", "e-h Dphi LS with no partner, mass<mass cut for 2<pt^{asso}<4,",200,0,20,64,-1.57,4.71);
487ae960 1218 fOutputList->Add(fDphiLSMassLowNoPartner1);
1219
a9123929 1220 fDphiLSMassLowNoPartner2 = new TH2F("fDphiLSMassLowNoPartner2", "e-h Dphi LS with no partner, mass<mass cut for 4<pt^{asso}<6,",200,0,20,64,-1.57,4.71);
487ae960 1221 fOutputList->Add(fDphiLSMassLowNoPartner2);
1222
a9123929 1223 fDphiLSMassLowNoPartner3 = new TH2F("fDphiLSMassLowNoPartner3", "e-h Dphi LS with no partner, mass<mass cut for 6<pt^{asso}<8,",200,0,20,64,-1.57,4.71);
487ae960 1224 fOutputList->Add(fDphiLSMassLowNoPartner3);
1225
a9123929 1226 fDphiLSMassLowNoPartner4 = new TH2F("fDphiLSMassLowNoPartner4", "e-h Dphi LS with no partner, mass<mass cut for 4<pt^{asso}<10,",200,0,20,64,-1.57,4.71);
487ae960 1227 fOutputList->Add(fDphiLSMassLowNoPartner4);
1228
57189f04 1229 fPhotoElecPt = new TH1F("fPhotoElecPt", "photonic electron pt",1000,0,100);
1230 fOutputList->Add(fPhotoElecPt);
520a29a8 1231
57189f04 1232 fSemiInclElecPt = new TH1F("fSemiInclElecPt", "Semi-inclusive electron pt",1000,0,100);
1233 fOutputList->Add(fSemiInclElecPt);
520a29a8 1234
1235 fInclusiveElecPt = new TH1F("fInclElecPt", "Inclusive electron pt",1000,0,100);
1236 fOutputList->Add(fInclusiveElecPt);
1237
1238 fULSElecPt = new TH1F("fULSElecPt", "ULS electron pt",1000,0,100);
1239 fOutputList->Add(fULSElecPt);
1240
1241 fLSElecPt = new TH1F("fLSElecPt", "LS electron pt",1000,0,100);
1242 fOutputList->Add(fLSElecPt);
987053ce 1243
a9123929 1244 fSemiIncElecDphiEta1 = new TH2F("fSemiIncElecDphiEta1", "Semi Inclusive elec-had Dphi correlation for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1245 fOutputList->Add(fSemiIncElecDphiEta1);
a9123929 1246 fSemiIncElecDphiEta11 = new TH2F("fSemiIncElecDphiEta11", "Semi Inclusive elec-had Dphi correlation for 2<pt^{asso}<4 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1247 fOutputList->Add(fSemiIncElecDphiEta11);
a9123929 1248 fSemiIncElecDphiEta12 = new TH2F("fSemiIncElecDphiEta12", "Semi Inclusive elec-had Dphi correlation for 4<pt^{asso}<6 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1249 fOutputList->Add(fSemiIncElecDphiEta12);
a9123929 1250 fSemiIncElecDphiEta13 = new TH2F("fSemiIncElecDphiEta13", "Semi Inclusive elec-had Dphi correlation for 6<pt^{asso}<8 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1251 fOutputList->Add(fSemiIncElecDphiEta13);
a9123929 1252 fSemiIncElecDphiEta14 = new TH2F("fSemiIncElecDphiEta14", "Semi Inclusive elec-had Dphi correlation for 4<pt^{asso}<10 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1253 fOutputList->Add(fSemiIncElecDphiEta14);
a9123929 1254 fPhotElecDphiEta1 = new TH2F("fPhotElecDphiEta1", "Photon elec-had Dphi correlation for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1255 fOutputList->Add(fPhotElecDphiEta1);
a9123929 1256 fPhotElecDphiEta11 = new TH2F("fPhotElecDphiEta11", "Photon elec-had Dphi correlation for 2<pt^{asso}<4 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1257 fOutputList->Add(fPhotElecDphiEta11);
a9123929 1258 fPhotElecDphiEta12 = new TH2F("fPhotElecDphiEta12", "Photon elec-had Dphi correlation for 4<pt^{asso}<6 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1259 fOutputList->Add(fPhotElecDphiEta12);
a9123929 1260 fPhotElecDphiEta13 = new TH2F("fPhotElecDphiEta13", "Photon elec-had Dphi correlation for 6<pt^{asso}<8 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1261 fOutputList->Add(fPhotElecDphiEta13);
a9123929 1262 fPhotElecDphiEta14 = new TH2F("fPhotElecDphiEta14", "Photon elec-had Dphi correlation for 4<pt^{asso}<10 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1263 fOutputList->Add(fPhotElecDphiEta14);
a9123929 1264 fInclusiveElecDphiEta1 = new TH2F("fInclusiveElecDphiEta1", "Inclusive elec-had Dphi correlation for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1265 fOutputList->Add(fInclusiveElecDphiEta1);
a9123929 1266 fInclusiveElecDphiEta11 = new TH2F("fInclusiveElecDphiEta11", "Inclusive elec-had Dphi correlation for 2<pt^{asso}<4 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1267 fOutputList->Add(fInclusiveElecDphiEta11);
a9123929 1268 fInclusiveElecDphiEta12 = new TH2F("fInclusiveElecDphiEta12", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<6 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1269 fOutputList->Add(fInclusiveElecDphiEta12);
a9123929 1270 fInclusiveElecDphiEta13 = new TH2F("fInclusiveElecDphiEta13", "Inclusive elec-had Dphi correlation for 6<pt^{asso}<8 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1271 fOutputList->Add(fInclusiveElecDphiEta13);
a9123929 1272 fInclusiveElecDphiEta14 = new TH2F("fInclusiveElecDphiEta14", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<10 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1273 fOutputList->Add(fInclusiveElecDphiEta14);
a9123929 1274 fDphiULSMassLowEta1 = new TH2F("fDphiULSMassLowEta1", "e-h Dphi ULS, mass<cut for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1275 fOutputList->Add(fDphiULSMassLowEta1);
a9123929 1276 fDphiULSMassLowEta11 = new TH2F("fDphiULSMassLowEta11", "e-h Dphi ULS, mass<cut for 2<pt^{asso}<4 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1277 fOutputList->Add(fDphiULSMassLowEta11);
a9123929 1278 fDphiULSMassLowEta12 = new TH2F("fDphiULSMassLowEta12", "e-h Dphi ULS, mass<cut for 4<pt^{asso}<6 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1279 fOutputList->Add(fDphiULSMassLowEta12);
a9123929 1280 fDphiULSMassLowEta13 = new TH2F("fDphiULSMassLowEta13", "e-h Dphi ULS, mass<cut for 6<pt^{asso}<8 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1281 fOutputList->Add(fDphiULSMassLowEta13);
a9123929 1282 fDphiULSMassLowEta14 = new TH2F("fDphiULSMassLowEta14", "e-h Dphi ULS, mass<cut for 4<pt^{asso}<10 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1283 fOutputList->Add(fDphiULSMassLowEta14);
a9123929 1284 fDphiLSMassLowEta1 = new TH2F("fDphiLSMassLowEta1", "e-h Dphi LS, mass<cut for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1285 fOutputList->Add(fDphiLSMassLowEta1);
a9123929 1286 fDphiLSMassLowEta11 = new TH2F("fDphiLSMassLowEta11", "e-h Dphi LS, mass<cut for 2<pt^{asso}<4 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1287 fOutputList->Add(fDphiLSMassLowEta11);
a9123929 1288 fDphiLSMassLowEta12 = new TH2F("fDphiLSMassLowEta12", "e-h Dphi LS, mass<cut for 4<pt^{asso}<6 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1289 fOutputList->Add(fDphiLSMassLowEta12);
a9123929 1290 fDphiLSMassLowEta13 = new TH2F("fDphiLSMassLowEta13", "e-h Dphi LS, mass<cut for 6<pt^{asso}<8 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1291 fOutputList->Add(fDphiLSMassLowEta13);
a9123929 1292 fDphiLSMassLowEta14 = new TH2F("fDphiLSMassLowEta14", "e-h Dphi LS, mass<cut for 8<pt^{asso}<10 for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1293 fOutputList->Add(fDphiLSMassLowEta14);
a9123929 1294 fDphiULSMassLowNoPartnerEta1 = new TH2F("fDphiULSMassLowNoPartnerEta1", "e-h Dphi ULS with no partner, mass<mass cut, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1295 fOutputList->Add(fDphiULSMassLowNoPartnerEta1);
a9123929 1296 fDphiULSMassLowNoPartnerEta11 = new TH2F("fDphiULSMassLowNoPartnerEta11", "e-h Dphi ULS with no partner, mass<mass cut for 2<pt^{asso}<4, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1297 fOutputList->Add(fDphiULSMassLowNoPartnerEta11);
a9123929 1298 fDphiULSMassLowNoPartnerEta12 = new TH2F("fDphiULSMassLowNoPartnerEta12", "e-h Dphi ULS with no partner, mass<mass cut for 4<pt^{asso}<6, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1299 fOutputList->Add(fDphiULSMassLowNoPartnerEta12);
a9123929 1300 fDphiULSMassLowNoPartnerEta13 = new TH2F("fDphiULSMassLowNoPartnerEta13", "e-h Dphi ULS with no partner, mass<mass cut for 6<pt^{asso}<8, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1301 fOutputList->Add(fDphiULSMassLowNoPartnerEta13);
a9123929 1302 fDphiULSMassLowNoPartnerEta14 = new TH2F("fDphiULSMassLowNoPartnerEta14", "e-h Dphi ULS with no partner, mass<mass cut for 4<pt^{asso}<10, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1303 fOutputList->Add(fDphiULSMassLowNoPartnerEta14);
a9123929 1304 fDphiLSMassLowNoPartnerEta1 = new TH2F("fDphiLSMassLowNoPartnerEta1", "e-h Dphi LS with no partner, mass<mass cut, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1305 fOutputList->Add(fDphiLSMassLowNoPartnerEta1);
a9123929 1306 fDphiLSMassLowNoPartnerEta11 = new TH2F("fDphiLSMassLowNoPartnerEta11", "e-h Dphi LS with no partner, mass<mass cut for 2<pt^{asso}<4, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1307 fOutputList->Add(fDphiLSMassLowNoPartnerEta11);
a9123929 1308 fDphiLSMassLowNoPartnerEta12 = new TH2F("fDphiLSMassLowNoPartnerEta12", "e-h Dphi LS with no partner, mass<mass cut for 4<pt^{asso}<6, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1309 fOutputList->Add(fDphiLSMassLowNoPartnerEta12);
a9123929 1310 fDphiLSMassLowNoPartnerEta13 = new TH2F("fDphiLSMassLowNoPartnerEta13", "e-h Dphi LS with no partner, mass<mass cut for 6<pt^{asso}<8, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1311 fOutputList->Add(fDphiLSMassLowNoPartnerEta13);
a9123929 1312 fDphiLSMassLowNoPartnerEta14 = new TH2F("fDphiLSMassLowNoPartnerEta14", "e-h Dphi LS with no partner, mass<mass cut for 4<pt^{asso}<10, for |Eta < 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1313 fOutputList->Add(fDphiLSMassLowNoPartnerEta14);
1314
a9123929 1315 fSemiIncElecDphiEta2 = new TH2F("fSemiIncElecDphiEta2", "Semi Inclusive elec-had Dphi correlation for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1316 fOutputList->Add(fSemiIncElecDphiEta2);
a9123929 1317 fSemiIncElecDphiEta21 = new TH2F("fSemiIncElecDphiEta21", "Semi Inclusive elec-had Dphi correlation for 2<pt^{asso}<4 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1318 fOutputList->Add(fSemiIncElecDphiEta21);
a9123929 1319 fSemiIncElecDphiEta22 = new TH2F("fSemiIncElecDphiEta22", "Semi Inclusive elec-had Dphi correlation for 4<pt^{asso}<6 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1320 fOutputList->Add(fSemiIncElecDphiEta22);
a9123929 1321 fSemiIncElecDphiEta23 = new TH2F("fSemiIncElecDphiEta23", "Semi Inclusive elec-had Dphi correlation for 6<pt^{asso}<8 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1322 fOutputList->Add(fSemiIncElecDphiEta23);
a9123929 1323 fSemiIncElecDphiEta24 = new TH2F("fSemiIncElecDphiEta24", "Semi Inclusive elec-had Dphi correlation for 4<pt^{asso}<10 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1324 fOutputList->Add(fSemiIncElecDphiEta24);
a9123929 1325 fPhotElecDphiEta2 = new TH2F("fPhotElecDphiEta2", "Photon elec-had Dphi correlation for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1326 fOutputList->Add(fPhotElecDphiEta2);
a9123929 1327 fPhotElecDphiEta21 = new TH2F("fPhotElecDphiEta21", "Photon elec-had Dphi correlation for 2<pt^{asso}<4 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1328 fOutputList->Add(fPhotElecDphiEta21);
a9123929 1329 fPhotElecDphiEta22 = new TH2F("fPhotElecDphiEta22", "Photon elec-had Dphi correlation for 4<pt^{asso}<6 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1330 fOutputList->Add(fPhotElecDphiEta22);
a9123929 1331 fPhotElecDphiEta23 = new TH2F("fPhotElecDphiEta23", "Photon elec-had Dphi correlation for 6<pt^{asso}<8 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1332 fOutputList->Add(fPhotElecDphiEta23);
a9123929 1333 fPhotElecDphiEta24 = new TH2F("fPhotElecDphiEta24", "Photon elec-had Dphi correlation for 4<pt^{asso}<10 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1334 fOutputList->Add(fPhotElecDphiEta24);
a9123929 1335 fInclusiveElecDphiEta2 = new TH2F("fInclusiveElecDphiEta2", "Inclusive elec-had Dphi correlation for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1336 fOutputList->Add(fInclusiveElecDphiEta2);
a9123929 1337 fInclusiveElecDphiEta21 = new TH2F("fInclusiveElecDphiEta21", "Inclusive elec-had Dphi correlation for 2<pt^{asso}<4 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1338 fOutputList->Add(fInclusiveElecDphiEta21);
a9123929 1339 fInclusiveElecDphiEta22 = new TH2F("fInclusiveElecDphiEta22", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<6 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1340 fOutputList->Add(fInclusiveElecDphiEta22);
a9123929 1341 fInclusiveElecDphiEta23 = new TH2F("fInclusiveElecDphiEta23", "Inclusive elec-had Dphi correlation for 6<pt^{asso}<8 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1342 fOutputList->Add(fInclusiveElecDphiEta23);
a9123929 1343 fInclusiveElecDphiEta24 = new TH2F("fInclusiveElecDphiEta24", "Inclusive elec-had Dphi correlation for 4<pt^{asso}<10 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1344 fOutputList->Add(fInclusiveElecDphiEta24);
a9123929 1345 fDphiULSMassLowEta2 = new TH2F("fDphiULSMassLowEta2", "e-h Dphi ULS, mass<cut for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1346 fOutputList->Add(fDphiULSMassLowEta2);
a9123929 1347 fDphiULSMassLowEta21 = new TH2F("fDphiULSMassLowEta21", "e-h Dphi ULS, mass<cut for 2<pt^{asso}<4 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1348 fOutputList->Add(fDphiULSMassLowEta21);
a9123929 1349 fDphiULSMassLowEta22 = new TH2F("fDphiULSMassLowEta22", "e-h Dphi ULS, mass<cut for 4<pt^{asso}<6 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1350 fOutputList->Add(fDphiULSMassLowEta22);
a9123929 1351 fDphiULSMassLowEta23 = new TH2F("fDphiULSMassLowEta23", "e-h Dphi ULS, mass<cut for 6<pt^{asso}<8 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1352 fOutputList->Add(fDphiULSMassLowEta23);
a9123929 1353 fDphiULSMassLowEta24 = new TH2F("fDphiULSMassLowEta24", "e-h Dphi ULS, mass<cut for 4<pt^{asso}<10 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1354 fOutputList->Add(fDphiULSMassLowEta24);
a9123929 1355 fDphiLSMassLowEta2 = new TH2F("fDphiLSMassLowEta2", "e-h Dphi LS, mass<cut for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1356 fOutputList->Add(fDphiLSMassLowEta2);
a9123929 1357 fDphiLSMassLowEta21 = new TH2F("fDphiLSMassLowEta21", "e-h Dphi LS, mass<cut for 2<pt^{asso}<4 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1358 fOutputList->Add(fDphiLSMassLowEta21);
a9123929 1359 fDphiLSMassLowEta22 = new TH2F("fDphiLSMassLowEta22", "e-h Dphi LS, mass<cut for 4<pt^{asso}<6 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1360 fOutputList->Add(fDphiLSMassLowEta22);
a9123929 1361 fDphiLSMassLowEta23 = new TH2F("fDphiLSMassLowEta23", "e-h Dphi LS, mass<cut for 6<pt^{asso}<8 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1362 fOutputList->Add(fDphiLSMassLowEta23);
a9123929 1363 fDphiLSMassLowEta24 = new TH2F("fDphiLSMassLowEta24", "e-h Dphi LS, mass<cut for 4<pt^{asso}<10 for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1364 fOutputList->Add(fDphiLSMassLowEta24);
a9123929 1365 fDphiULSMassLowNoPartnerEta2 = new TH2F("fDphiULSMassLowNoPartnerEta2", "e-h Dphi ULS with no partner, mass<mass cut, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1366 fOutputList->Add(fDphiULSMassLowNoPartnerEta2);
a9123929 1367 fDphiULSMassLowNoPartnerEta21 = new TH2F("fDphiULSMassLowNoPartnerEta21", "e-h Dphi ULS with no partner, mass<mass cut for 2<pt^{asso}<4, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1368 fOutputList->Add(fDphiULSMassLowNoPartnerEta21);
a9123929 1369 fDphiULSMassLowNoPartnerEta22 = new TH2F("fDphiULSMassLowNoPartnerEta22", "e-h Dphi ULS with no partner, mass<mass cut for 4<pt^{asso}<6, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1370 fOutputList->Add(fDphiULSMassLowNoPartnerEta22);
a9123929 1371 fDphiULSMassLowNoPartnerEta23 = new TH2F("fDphiULSMassLowNoPartnerEta23", "e-h Dphi ULS with no partner, mass<mass cut for 6<pt^{asso}<8, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1372 fOutputList->Add(fDphiULSMassLowNoPartnerEta23);
a9123929 1373 fDphiULSMassLowNoPartnerEta24 = new TH2F("fDphiULSMassLowNoPartnerEta24", "e-h Dphi ULS with no partner, mass<mass cut for 4<pt^{asso}<10, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1374 fOutputList->Add(fDphiULSMassLowNoPartnerEta24);
a9123929 1375 fDphiLSMassLowNoPartnerEta2 = new TH2F("fDphiLSMassLowNoPartnerEta2", "e-h Dphi LS with no partner, mass<mass cut, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1376 fOutputList->Add(fDphiLSMassLowNoPartnerEta2);
a9123929 1377 fDphiLSMassLowNoPartnerEta21 = new TH2F("fDphiLSMassLowNoPartnerEta21", "e-h Dphi LS with no partner, mass<mass cut for 2<pt^{asso}<4, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1378 fOutputList->Add(fDphiLSMassLowNoPartnerEta21);
a9123929 1379 fDphiLSMassLowNoPartnerEta22 = new TH2F("fDphiLSMassLowNoPartnerEta22", "e-h Dphi LS with no partner, mass<mass cut for 4<pt^{asso}<6, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1380 fOutputList->Add(fDphiLSMassLowNoPartnerEta22);
a9123929 1381 fDphiLSMassLowNoPartnerEta23 = new TH2F("fDphiLSMassLowNoPartnerEta23", "e-h Dphi LS with no partner, mass<mass cut for 6<pt^{asso}<8, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1382 fOutputList->Add(fDphiLSMassLowNoPartnerEta23);
a9123929 1383 fDphiLSMassLowNoPartnerEta24 = new TH2F("fDphiLSMassLowNoPartnerEta24", "e-h Dphi LS with no partner, mass<mass cut for 4<pt^{asso}<10, for |Eta > 0.8|",200,0,20,64,-1.57,4.71);
bf697dda 1384 fOutputList->Add(fDphiLSMassLowNoPartnerEta24);
1385
1386 /* fNCellv1 = new TH1F("fNCellv1","Ncell in clus (v1); NCell; count",100,0,100) ;
1387 fOutputList->Add(fNCellv1);
1388
1389 fClsEv1 = new TH1F("fClsEv1", "Clus E(v1); Cls E; count",1000,0,100);
1390 fOutputList->Add(fClsEv1);
1391
1392 fNClusv1 = new TH1F("fNClusv1","Nclus in event (v1); NClus; count",500,0,500) ;
1393 fOutputList->Add(fNClusv1);
1394 */
33369c14 1395 fInvmassLS1 = new TH1F("fInvmassLS1", "Inv mass of LS (e,e) for pt^{e}>2; mass(GeV/c^2); counts;", 1000,0,1.0);
520a29a8 1396 fOutputList->Add(fInvmassLS1);
1397
33369c14 1398 fInvmassULS1 = new TH1F("fInvmassULS1", "Inv mass of ULS (e,e) for pt^{e}>2; mass(GeV/c^2); counts;", 1000,0,1.0);
520a29a8 1399 fOutputList->Add(fInvmassULS1);
bf697dda 1400 /*
1401 fInvmassLS2 = new TH1F("fInvmassLS2", "Inv mass of LS (e,e) for pt^{e}>1; mass(GeV/c^2); counts;", 1000,0,1.0);
1402 fOutputList->Add(fInvmassLS2);
487ae960 1403
bf697dda 1404 fInvmassULS2 = new TH1F("fInvmassULS2", "Inv mass of ULS (e,e) for pt^{e}>1; mass(GeV/c^2); counts;", 1000,0,1.0);
1405 fOutputList->Add(fInvmassULS2);
487ae960 1406
bf697dda 1407 fInvmassLS3 = new TH1F("fInvmassLS3", "Inv mass of LS (e,e) for pt^{e}>2; mass(GeV/c^2); counts;", 1000,0,1.0);
1408 fOutputList->Add(fInvmassLS3);
487ae960 1409
bf697dda 1410 fInvmassULS3 = new TH1F("fInvmassULS3", "Inv mass of ULS (e,e) for pt^{e}>2; mass(GeV/c^2); counts;", 1000,0,1.0);
1411 fOutputList->Add(fInvmassULS3);
487ae960 1412
bf697dda 1413 fInvmassLS4 = new TH1F("fInvmassLS4", "Inv mass of LS (e,e) for pt^{e}>3; mass(GeV/c^2); counts;", 1000,0,1.0);
1414 fOutputList->Add(fInvmassLS4);
487ae960 1415
bf697dda 1416 fInvmassULS4 = new TH1F("fInvmassULS4", "Inv mass of ULS (e,e) for pt^{e}>3; mass(GeV/c^2); counts;", 1000,0,1.0);
1417 fOutputList->Add(fInvmassULS4);
487ae960 1418
bf697dda 1419 fInvmassLS5 = new TH1F("fInvmassLS5", "Inv mass of LS (e,e) for pt^{e}>4; mass(GeV/c^2); counts;", 1000,0,1.0);
1420 fOutputList->Add(fInvmassLS5);
487ae960 1421
bf697dda 1422 fInvmassULS5 = new TH1F("fInvmassULS5", "Inv mass of ULS (e,e) for pt^{e}>4; mass(GeV/c^2); counts;", 1000,0,1.0);
1423 fOutputList->Add(fInvmassULS5);
1424 */
9866fa7b 1425/* fNoMixedEvents = new TH1F("fNoMixedEvents","",1,0,1) ;
a9123929 1426 fOutputList->Add(fNoMixedEvents);
4e01b68c 1427
a9123929 1428 fMixStat = new TH2F("fMixStat","no of events in pool vs Centrality;Nevent in pool;Centrality",200,0,200,5,0,10);
1429 fOutputList->Add(fMixStat);
4e01b68c 1430
a9123929 1431 fMixStat1 = new TH2F("fMixStat1","no of events in pool vs zvtx;Nevents in pool;zvtx",200,0,200,4,-10,10);
1432 fOutputList->Add(fMixStat1);
4e01b68c 1433
a9123929 1434 fMixedIncElecDphi = new TH2F("fMixedIncElecDphi", "Mixed event - Inclusive elec-had Dphi correlation",200,0,20,100,-1.57,4.71);
1435 fOutputList->Add(fMixedIncElecDphi);
4e01b68c 1436
a9123929 1437 fMixedIncElecDphi1 = new TH2F("fMixedIncElecDphi1", "Mixed event - Inclusive elec-had Dphi correlation 2<pt<4",200,0,20,100,-1.57,4.71);
1438 fOutputList->Add(fMixedIncElecDphi1);
3c56855b 1439
a9123929 1440 fMixedIncElecDphi2 = new TH2F("fMixedIncElecDphi2", "Mixed event - Inclusive elec-had Dphi correlation 4<pt<6",200,0,20,100,-1.57,4.71);
1441 fOutputList->Add(fMixedIncElecDphi2);
3c56855b 1442
a9123929 1443 fMixedIncElecDphi3 = new TH2F("fMixedIncElecDphi3", "Mixed event - Inclusive elec-had Dphi correlation 6<pt<8",200,0,20,100,-1.57,4.71);
1444 fOutputList->Add(fMixedIncElecDphi3);
4e01b68c 1445
a9123929 1446 fMixedIncElecDphi4 = new TH2F("fMixedIncElecDphi4", "Mixed event - Inclusive elec-had Dphi correlation 4<pt<10",200,0,20,100,-1.57,4.71);
1447 fOutputList->Add(fMixedIncElecDphi4);
3c56855b 1448
a9123929 1449 fMixedSemiIncElecDphi = new TH2F("fMixedSemiIncElecDphi", "Mixed event - Semi Inclusive elec-had Dphi correlation",200,0,20,100,-1.57,4.71);
1450 fOutputList->Add(fMixedSemiIncElecDphi);
3c56855b 1451
a9123929 1452 fMixedSemiIncElecDphi1 = new TH2F("fMixedSemiIncElecDphi1", "Mixed event - Semi Inclusive elec-had Dphi correlation 2<pt<4",200,0,20,100,-1.57,4.71);
1453 fOutputList->Add(fMixedSemiIncElecDphi1);
4e01b68c 1454
a9123929 1455 fMixedSemiIncElecDphi2 = new TH2F("fMixedSemiIncElecDphi2", "Mixed event - Semi Inclusive elec-had Dphi correlation 4<pt<6",200,0,20,100,-1.57,4.71);
1456 fOutputList->Add(fMixedSemiIncElecDphi2);
3c56855b 1457
a9123929 1458 fMixedSemiIncElecDphi3 = new TH2F("fMixedSemiIncElecDphi3", "Mixed event - Semi Inclusive elec-had Dphi correlation 6<pt<8",200,0,20,100,-1.57,4.71);
1459 fOutputList->Add(fMixedSemiIncElecDphi3);
3c56855b 1460
a9123929 1461 fMixedSemiIncElecDphi4 = new TH2F("fMixedSemiIncElecDphi4", "Mixed event - Semi Inclusive elec-had Dphi correlation 4<pt<10",200,0,20,100,-1.57,4.71);
1462 fOutputList->Add(fMixedSemiIncElecDphi4);
4e01b68c 1463
a9123929 1464 fMixedPhotElecDphi = new TH2F("fMixedPhotElecDphi", "Mixed event - Photo elec-had Dphi correlation",200,0,20,100,-1.57,4.71);
1465 fOutputList->Add(fMixedPhotElecDphi);
3c56855b 1466
a9123929 1467 fMixedPhotElecDphi1 = new TH2F("fMixedPhotElecDphi1", "Mixed event - Photo elec-had Dphi correlation 2<pt<4",200,0,20,100,-1.57,4.71);
1468 fOutputList->Add(fMixedPhotElecDphi1);
3c56855b 1469
a9123929 1470 fMixedPhotElecDphi2 = new TH2F("fMixedPhotElecDphi2", "Mixed event - Photo elec-had Dphi correlation 4<pt<6",200,0,20,100,-1.57,4.71);
1471 fOutputList->Add(fMixedPhotElecDphi2);
3c56855b 1472
a9123929 1473 fMixedPhotElecDphi3 = new TH2F("fMixedPhotElecDphi3", "Mixed event - Photo elec-had Dphi correlation 6<pt<8",200,0,20,100,-1.57,4.71);
1474 fOutputList->Add(fMixedPhotElecDphi3);
1475
1476 fMixedPhotElecDphi4 = new TH2F("fMixedPhotElecDphi4", "Mixed event - Photo elec-had Dphi correlation 4<pt<10",200,0,20,100,-1.57,4.71);
1477 fOutputList->Add(fMixedPhotElecDphi4);
1478
1479 fMixedDphiULSMassLow = new TH2F("fMixedDphiULSMassLow", "Mixed event - ULS mass < cut elec-had Dphi correlation",200,0,20,100,-1.57,4.71);
1480 fOutputList->Add(fMixedDphiULSMassLow);
1481
1482 fMixedDphiULSMassLow1 = new TH2F("fMixedDphiULSMassLow1", "Mixed event - ULS mass < cut elec-had Dphi correlation 2<pt<4",200,0,20,100,-1.57,4.71);
1483 fOutputList->Add(fMixedDphiULSMassLow1);
1484
1485 fMixedDphiULSMassLow2 = new TH2F("fMixedDphiULSMassLow2", "Mixed event - ULS mass < cut elec-had Dphi correlation 4<pt<6",200,0,20,100,-1.57,4.71);
1486 fOutputList->Add(fMixedDphiULSMassLow2);
1487
1488 fMixedDphiULSMassLow3 = new TH2F("fMixedDphiULSMassLow3", "Mixed event - ULS mass < cut elec-had Dphi correlation 6<pt<8",200,0,20,100,-1.57,4.71);
1489 fOutputList->Add(fMixedDphiULSMassLow3);
1490
1491 fMixedDphiULSMassLow4 = new TH2F("fMixedDphiULSMassLow4", "Mixed event - ULS mass < cut elec-had Dphi correlation 4<pt<10",200,0,20,100,-1.57,4.71);
1492 fOutputList->Add(fMixedDphiULSMassLow4);
1493
1494 fMixedDphiLSMassLow = new TH2F("fMixedDphiLSMassLow", "Mixed event - LS mass < cut elec-had Dphi correlation",200,0,20,100,-1.57,4.71);
1495 fOutputList->Add(fMixedDphiLSMassLow);
1496
1497 fMixedDphiLSMassLow1 = new TH2F("fMixedDphiLSMassLow1", "Mixed event - LS mass < cut elec-had Dphi correlation 2<pt<4",200,0,20,100,-1.57,4.71);
1498 fOutputList->Add(fMixedDphiLSMassLow1);
1499
1500 fMixedDphiLSMassLow2 = new TH2F("fMixedDphiLSMassLow2", "Mixed event - LS mass < cut elec-had Dphi correlation 4<pt<6",200,0,20,100,-1.57,4.71);
1501 fOutputList->Add(fMixedDphiLSMassLow2);
1502
1503 fMixedDphiLSMassLow3 = new TH2F("fMixedDphiLSMassLow3", "Mixed event - LS mass < cut elec-had Dphi correlation 6<pt<8",200,0,20,100,-1.57,4.71);
1504 fOutputList->Add(fMixedDphiLSMassLow3);
1505
1506 fMixedDphiLSMassLow4 = new TH2F("fMixedDphiLSMassLow4", "Mixed event - LS mass < cut elec-had Dphi correlation 4<pt<10",200,0,20,100,-1.57,4.71);
1507 fOutputList->Add(fMixedDphiLSMassLow4);
9866fa7b 1508*/
3c56855b 1509 fHadronPt = new TH1F("fHadronPt","hadron pt distribution",1000,0,100);
1510 fOutputList->Add(fHadronPt);
1511
1512 fCentralityPass = new TH1F("fCentralityPass", "Centrality Pass", 101, -1, 100);
1513 fOutputList->Add(fCentralityPass);
1514
1515 fCentralityNoPass = new TH1F("fCentralityNoPass", "Centrality No Pass", 101, -1, 100);
1516 fOutputList->Add(fCentralityNoPass);
1517
0841d73f 1518 fHadronDphi = new TH2F("fHadronDphi", "Hadron-had Dphi correlation",200,0,20,64,-1.57,4.71);
1519 fOutputList->Add(fHadronDphi);
1520
a9123929 1521 fHadronDphi1 = new TH2F("fHadronDphi1", "Hadron-had Dphi correlation for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
0841d73f 1522 fOutputList->Add(fHadronDphi1);
1523
a9123929 1524 fHadronDphi2 = new TH2F("fHadronDphi2", "Hadron-had Dphi correlation for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
0841d73f 1525 fOutputList->Add(fHadronDphi2);
1526
a9123929 1527 fHadronDphi3 = new TH2F("fHadronDphi3", "Hadron-had Dphi correlation for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
0841d73f 1528 fOutputList->Add(fHadronDphi3);
1529
a9123929 1530 fHadronDphi4 = new TH2F("fHadronDphi4", "Hadron-had Dphi correlation for 4<pt^{asso}<10",200,0,20,64,-1.57,4.71);
0841d73f 1531 fOutputList->Add(fHadronDphi4);
1532
33369c14 1533 fPiPt = new TH1F("fPiPt","Pi (-10 <TPC nsig < -3.5) pt distribution",1000,0,100);
0841d73f 1534 fOutputList->Add(fPiPt);
1535
33369c14 1536 fHadronDphiNoSS = new TH2F("fHadronDphiNoSS", "Hadron-had Dphi correlation (NoSS cuts)",200,0,20,64,-1.57,4.71);
1537 fOutputList->Add(fHadronDphiNoSS);
1538
a9123929 1539 fHadronDphiNoSS1 = new TH2F("fHadronDphiNoSS1", "Hadron-had Dphi correlation (NoSS cuts) for 2<pt^{asso}<4",200,0,20,64,-1.57,4.71);
33369c14 1540 fOutputList->Add(fHadronDphiNoSS1);
1541
a9123929 1542 fHadronDphiNoSS2 = new TH2F("fHadronDphiNoSS2", "Hadron-had Dphi correlation (NoSS cuts) for 4<pt^{asso}<6",200,0,20,64,-1.57,4.71);
33369c14 1543 fOutputList->Add(fHadronDphiNoSS2);
1544
a9123929 1545 fHadronDphiNoSS3 = new TH2F("fHadronDphiNoSS3", "Hadron-had Dphi correlation (NoSS cuts) for 6<pt^{asso}<8",200,0,20,64,-1.57,4.71);
33369c14 1546 fOutputList->Add(fHadronDphiNoSS3);
1547
a9123929 1548 fHadronDphiNoSS4 = new TH2F("fHadronDphiNoSS4", "Hadron-had Dphi correlation (NoSS cuts) for 4<pt^{asso}<10",200,0,20,64,-1.57,4.71);
33369c14 1549 fOutputList->Add(fHadronDphiNoSS4);
1550
1551 fPiPtNoSS = new TH1F("fPiPtNoSS","Pi (-10 <TPC nsig < -3.5) (NoSS cuts) pt distribution",1000,0,100);
1552 fOutputList->Add(fPiPtNoSS);
1553
bf697dda 1554 fEovPWoSS = new TH2F("fEovPWoSS","E/p distribution without SS cuts",1000,0,50,100,0,2);
1555 fOutputList->Add(fEovPWoSS);
1556
1557 fEovPWSS = new TH2F("fEovPWSS","E/p distribution with SS cuts",1000,0,50,100,0,2);
1558 fOutputList->Add(fEovPWSS);
1559
1560 fEovPHadWoSS = new TH2F("fEovPHadWoSS","E/p distribution for hadrons without SS cuts",1000,0,50,100,0,2);
1561 fOutputList->Add(fEovPHadWoSS);
1562
1563 fEovPHadWSS = new TH2F("fEovPHadWSS","E/p distribution for hadrons with SS cuts",1000,0,50,100,0,2);
1564 fOutputList->Add(fEovPHadWSS);
1565
0c884279 1566 fHadronDphiEta1 = new TH2F("fHadronDphiEta1", "Hadron-had Dphi correlation for |Eta <1|",200,0,20,64,-1.57,4.71);
1567 fOutputList->Add(fHadronDphiEta1);
a9123929 1568 fHadronDphiEta11 = new TH2F("fHadronDphiEta11", "Hadron-had Dphi correlation for 2<pt^{asso}<4 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1569 fOutputList->Add(fHadronDphiEta11);
a9123929 1570 fHadronDphiEta12 = new TH2F("fHadronDphiEta12", "Hadron-had Dphi correlation for 4<pt^{asso}<6 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1571 fOutputList->Add(fHadronDphiEta12);
a9123929 1572 fHadronDphiEta13 = new TH2F("fHadronDphiEta13", "Hadron-had Dphi correlation for 6<pt^{asso}<8 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1573 fOutputList->Add(fHadronDphiEta13);
a9123929 1574 fHadronDphiEta14 = new TH2F("fHadronDphiEta14", "Hadron-had Dphi correlation for 8<pt^{asso}<10 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1575 fOutputList->Add(fHadronDphiEta14);
1576
1577 fHadronDphiNoSSEta1 = new TH2F("fHadronDphiNoSSEta1", "Hadron-had DphiNoSS correlation for |Eta <1|",200,0,20,64,-1.57,4.71);
1578 fOutputList->Add(fHadronDphiNoSSEta1);
a9123929 1579 fHadronDphiNoSSEta11 = new TH2F("fHadronDphiNoSSEta11", "Hadron-had DphiNoSS correlation for 2<pt^{asso}<4 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1580 fOutputList->Add(fHadronDphiNoSSEta11);
a9123929 1581 fHadronDphiNoSSEta12 = new TH2F("fHadronDphiNoSSEta12", "Hadron-had DphiNoSS correlation for 4<pt^{asso}<6 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1582 fOutputList->Add(fHadronDphiNoSSEta12);
a9123929 1583 fHadronDphiNoSSEta13 = new TH2F("fHadronDphiNoSSEta13", "Hadron-had DphiNoSS correlation for 6<pt^{asso}<8 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1584 fOutputList->Add(fHadronDphiNoSSEta13);
a9123929 1585 fHadronDphiNoSSEta14 = new TH2F("fHadronDphiNoSSEta14", "Hadron-had DphiNoSS correlation for 4<pt^{asso}<10 for |Eta <1|",200,0,20,64,-1.57,4.71);
0c884279 1586 fOutputList->Add(fHadronDphiNoSSEta14);
1587
1588 fHadronDphiEta2 = new TH2F("fHadronDphiEta2", "Hadron-had Dphi correlation for |Eta >1|",200,0,20,64,-1.57,4.71);
1589 fOutputList->Add(fHadronDphiEta2);
a9123929 1590 fHadronDphiEta21 = new TH2F("fHadronDphiEta21", "Hadron-had Dphi correlation for 2<pt^{asso}<4 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1591 fOutputList->Add(fHadronDphiEta21);
a9123929 1592 fHadronDphiEta22 = new TH2F("fHadronDphiEta22", "Hadron-had Dphi correlation for 4<pt^{asso}<6 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1593 fOutputList->Add(fHadronDphiEta22);
a9123929 1594 fHadronDphiEta23 = new TH2F("fHadronDphiEta23", "Hadron-had Dphi correlation for 6<pt^{asso}<8 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1595 fOutputList->Add(fHadronDphiEta23);
a9123929 1596 fHadronDphiEta24 = new TH2F("fHadronDphiEta24", "Hadron-had Dphi correlation for 4<pt^{asso}<10 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1597 fOutputList->Add(fHadronDphiEta24);
1598
1599 fHadronDphiNoSSEta2 = new TH2F("fHadronDphiNoSSEta2", "Hadron-had DphiNoSS correlation for |Eta >1|",200,0,20,64,-1.57,4.71);
1600 fOutputList->Add(fHadronDphiNoSSEta2);
a9123929 1601 fHadronDphiNoSSEta21 = new TH2F("fHadronDphiNoSSEta21", "Hadron-had DphiNoSS correlation for 2<pt^{asso}<4 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1602 fOutputList->Add(fHadronDphiNoSSEta21);
a9123929 1603 fHadronDphiNoSSEta22 = new TH2F("fHadronDphiNoSSEta22", "Hadron-had DphiNoSS correlation for 4<pt^{asso}<6 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1604 fOutputList->Add(fHadronDphiNoSSEta22);
a9123929 1605 fHadronDphiNoSSEta23 = new TH2F("fHadronDphiNoSSEta23", "Hadron-had DphiNoSS correlation for 6<pt^{asso}<8 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1606 fOutputList->Add(fHadronDphiNoSSEta23);
a9123929 1607 fHadronDphiNoSSEta24 = new TH2F("fHadronDphiNoSSEta24", "Hadron-had DphiNoSS correlation for 4<pt^{asso}<10 for |Eta >1|",200,0,20,64,-1.57,4.71);
0c884279 1608 fOutputList->Add(fHadronDphiNoSSEta24);
1609
1610
bf697dda 1611 // Int_t binsv1[6]={500,200,50,50,50,50}; //pt, TPCnsig, E/p, M20, M02, dispersion
1612 // Double_t xminv1[6]={0,-10,0,0,0,0};
1613 // Double_t xmaxv1[6]={25,10,2,2,2,2};
1614 // fSparseElectron = new THnSparseD ("Electron","Electron",6,binsv1,xminv1,xmaxv1);
1615 // fOutputList->Add(fSparseElectron);
33369c14 1616
57189f04 1617 PostData(1,fOutputList);
1618}
1619
1620//________________________________________________________________________
1621void AliAnalysisTaskElecHadronCorrel::Terminate(Option_t *)
1622{
1623 // Info("Terminate");
520a29a8 1624 AliAnalysisTaskSE::Terminate();
57189f04 1625}
1626
1627//________________________________________________________________________
1628Bool_t AliAnalysisTaskElecHadronCorrel::ProcessCutStep(Int_t cutStep, AliVParticle *track)
1629{
1630 // Check single track cuts for a given cut step
1631 const Int_t kMCOffset = AliHFEcuts::kNcutStepsMCTrack;
1632 if(!fCFM->CheckParticleCuts(cutStep + kMCOffset, track)) return kFALSE;
1633 return kTRUE;
1634}
987053ce 1635
57189f04 1636//_________________________________________
987053ce 1637void AliAnalysisTaskElecHadronCorrel::SelectPhotonicElectron(Int_t itrack, AliVTrack *track, Bool_t &fFlagPhotonicElec)
57189f04 1638{
1639 //Identify non-heavy flavour electrons using Invariant mass method
520a29a8 1640
57189f04 1641 fTrackCuts1->SetAcceptKinkDaughters(kFALSE);
1642 fTrackCuts1->SetRequireTPCRefit(kTRUE);
e4b0faf2 1643 fTrackCuts1->SetRequireITSRefit(kTRUE);
57189f04 1644 fTrackCuts1->SetEtaRange(-0.9,0.9);
1645 fTrackCuts1->SetRequireSigmaToVertex(kTRUE);
e4b0faf2 1646 fTrackCuts1->SetMaxChi2PerClusterTPC(4);
57189f04 1647 fTrackCuts1->SetMinNClustersTPC(80);
987053ce 1648 fTrackCuts1->SetMaxDCAToVertexZ(3.2);
1649 fTrackCuts1->SetMaxDCAToVertexXY(2.4);
1650 fTrackCuts1->SetDCAToVertex2D(kTRUE);
520a29a8 1651
57189f04 1652 Bool_t flagPhotonicElec = kFALSE;
520a29a8 1653
987053ce 1654 for(Int_t jTracks = 0; jTracks<fVevent->GetNumberOfTracks(); jTracks++){
1655 AliVParticle* VtrackAsso = fVevent->GetTrack(jTracks);
1656 if (!VtrackAsso) {
57189f04 1657 printf("ERROR: Could not receive track %d\n", jTracks);
1658 continue;
1659 }
987053ce 1660
1661 AliVTrack *trackAsso = dynamic_cast<AliVTrack*>(VtrackAsso);
1662
1663 //track cuts applied
1664 if(IsAODanalysis()) {
1665 AliAODTrack *atrackAsso = dynamic_cast<AliAODTrack*>(VtrackAsso);
1666 if(!atrackAsso->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
1667 if(atrackAsso->GetTPCNcls() < 80) continue;
1668 if((!(atrackAsso->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackAsso->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
1669 }
1670 else{
1671 AliESDtrack *etrackAsso = dynamic_cast<AliESDtrack*>(VtrackAsso);
1672 if(!fTrackCuts1->AcceptTrack(etrackAsso)) continue;
1673 }
1674
e4b0faf2 1675 if(jTracks==itrack) continue;
520a29a8 1676
987053ce 1677 Double_t dEdxAsso = -999., ptAsso=-999., nsigma=-999.0;
520a29a8 1678 Double_t mass=-999., width = -999;
57189f04 1679 Bool_t fFlagLS=kFALSE, fFlagULS=kFALSE;
520a29a8 1680
57189f04 1681 dEdxAsso = trackAsso->GetTPCsignal();
487ae960 1682 nsigma = fPID->GetPIDResponse() ? fPID->GetPIDResponse()->NumberOfSigmasTPC(trackAsso, AliPID::kElectron) : 1000;
57189f04 1683 ptAsso = trackAsso->Pt();
1684 Int_t chargeAsso = trackAsso->Charge();
1685 Int_t charge = track->Charge();
520a29a8 1686
57189f04 1687 if(ptAsso <0.3) continue;
3c56855b 1688 if(trackAsso->Eta()<-0.9 || trackAsso->Eta()>0.9) continue;
487ae960 1689 if(nsigma < -3 || nsigma > 3) continue;
520a29a8 1690
57189f04 1691 Int_t fPDGe1 = 11; Int_t fPDGe2 = 11;
1692 if(charge>0) fPDGe1 = -11;
1693 if(chargeAsso>0) fPDGe2 = -11;
520a29a8 1694
57189f04 1695 if(charge == chargeAsso) fFlagLS = kTRUE;
1696 if(charge != chargeAsso) fFlagULS = kTRUE;
520a29a8 1697
1698 AliKFParticle ge1 = AliKFParticle(*track, fPDGe1);
1699 AliKFParticle ge2 = AliKFParticle(*trackAsso, fPDGe2);
57189f04 1700 AliKFParticle recg(ge1, ge2);
3c56855b 1701
57189f04 1702 if(recg.GetNDF()<1) continue;
1703 Double_t chi2recg = recg.GetChi2()/recg.GetNDF();
1704 if(TMath::Sqrt(TMath::Abs(chi2recg))>3.) continue;
520a29a8 1705
3c56855b 1706 Int_t MassCorrect;
1707 MassCorrect = recg.GetMass(mass,width);
520a29a8 1708
487ae960 1709 if(fFlagLS) {
33369c14 1710 if(track->Pt()>2)fInvmassLS1->Fill(mass);
a9123929 1711 // if(track->Pt()> 1) fInvmassLS2->Fill(mass);
1712 // if(track->Pt()>2) fInvmassLS3->Fill(mass);
1713 // if(track->Pt()>3) fInvmassLS4->Fill(mass);
1714 // if(track->Pt()>4) fInvmassLS5->Fill(mass);
487ae960 1715 }
1716 if(fFlagULS) {
33369c14 1717 if(track->Pt()>2)fInvmassULS1->Fill(mass);
1718 //if(track->Pt() >1) fInvmassULS2->Fill(mass);
1719 //if(track->Pt() >2) fInvmassULS3->Fill(mass);
1720 //if(track->Pt() >3) fInvmassULS4->Fill(mass);
1721 //if(track->Pt() >4) fInvmassULS5->Fill(mass);
487ae960 1722 }
520a29a8 1723
520a29a8 1724 if(mass<fInvmassCut){
1725 if(fFlagULS)
1726 {
487ae960 1727 ElectronHadCorrel(itrack,track,fDphiULSMassLow, fDphiULSMassLow1,fDphiULSMassLow2,fDphiULSMassLow3,fDphiULSMassLow4);
bf697dda 1728 ElectronHadCorrelEtaBins(itrack,track,fDphiULSMassLowEta1, fDphiULSMassLowEta11,fDphiULSMassLowEta12,fDphiULSMassLowEta13,fDphiULSMassLowEta14,fDphiULSMassLowEta2, fDphiULSMassLowEta21,fDphiULSMassLowEta22,fDphiULSMassLowEta23,fDphiULSMassLowEta24);
520a29a8 1729 fULSElecPt->Fill(track->Pt());
9866fa7b 1730 //MixedEvent(track,fMixedDphiULSMassLow,fMixedDphiULSMassLow1,fMixedDphiULSMassLow2, fMixedDphiULSMassLow3, fMixedDphiULSMassLow4);
520a29a8 1731 }
1732 if(fFlagLS)
1733 {
487ae960 1734 ElectronHadCorrel(itrack,track,fDphiLSMassLow,fDphiLSMassLow1,fDphiLSMassLow2,fDphiLSMassLow3,fDphiLSMassLow4);
bf697dda 1735 ElectronHadCorrelEtaBins(itrack,track,fDphiLSMassLowEta1, fDphiLSMassLowEta11,fDphiLSMassLowEta12,fDphiLSMassLowEta13,fDphiLSMassLowEta14,fDphiLSMassLowEta2, fDphiLSMassLowEta21,fDphiLSMassLowEta22,fDphiLSMassLowEta23,fDphiLSMassLowEta24);
520a29a8 1736 fLSElecPt->Fill(track->Pt());
9866fa7b 1737// MixedEvent(track,fMixedDphiLSMassLow,fMixedDphiLSMassLow1,fMixedDphiLSMassLow2, fMixedDphiLSMassLow3, fMixedDphiLSMassLow4);
520a29a8 1738 }
bf697dda 1739 if(fFlagLS){
1740 ElectronHadCorrelNoPartner(itrack,jTracks,track,fDphiLSMassLowNoPartner, fDphiLSMassLowNoPartner1,fDphiLSMassLowNoPartner2,fDphiLSMassLowNoPartner3,fDphiLSMassLowNoPartner4);
1741 ElectronHadCorrelEtaBinsNoPartner(itrack,jTracks,track,fDphiLSMassLowNoPartnerEta1, fDphiLSMassLowNoPartnerEta11,fDphiLSMassLowNoPartnerEta12,fDphiLSMassLowNoPartnerEta13,fDphiLSMassLowNoPartnerEta14,fDphiLSMassLowNoPartnerEta2, fDphiLSMassLowNoPartnerEta21,fDphiLSMassLowNoPartnerEta22,fDphiLSMassLowNoPartnerEta23,fDphiLSMassLowNoPartnerEta24);
1742 }
1743 if(fFlagULS) {
1744 ElectronHadCorrelNoPartner(itrack,jTracks,track,fDphiULSMassLowNoPartner, fDphiULSMassLowNoPartner1,fDphiULSMassLowNoPartner2,fDphiULSMassLowNoPartner3,fDphiULSMassLowNoPartner4);
1745 ElectronHadCorrelEtaBinsNoPartner(itrack,jTracks,track,fDphiULSMassLowNoPartnerEta1, fDphiULSMassLowNoPartnerEta11,fDphiULSMassLowNoPartnerEta12,fDphiULSMassLowNoPartnerEta13,fDphiULSMassLowNoPartnerEta14,fDphiULSMassLowNoPartnerEta2, fDphiULSMassLowNoPartnerEta21,fDphiULSMassLowNoPartnerEta22,fDphiULSMassLowNoPartnerEta23,fDphiULSMassLowNoPartnerEta24);
1746 }
57189f04 1747 }
520a29a8 1748
57189f04 1749 if(mass<fInvmassCut && fFlagULS && !flagPhotonicElec){
1750 flagPhotonicElec = kTRUE;
1751 }
520a29a8 1752 // }
1753
987053ce 1754}
1755fFlagPhotonicElec = flagPhotonicElec;
57189f04 1756}
1757//_________________________________________
987053ce 1758void AliAnalysisTaskElecHadronCorrel::ElectronHadCorrel(Int_t itrack, AliVTrack *track, TH2F *DphiPt, TH2F *DphiPt1,TH2F *DphiPt2,TH2F *DphiPt3,TH2F *DphiPt4)
57189f04 1759{
1760 //Construct Delta Phi between electrons and hadrons
520a29a8 1761
57189f04 1762 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
1763 fTrackCuts2->SetRequireTPCRefit(kTRUE);
1764 fTrackCuts2->SetRequireITSRefit(kTRUE);
1765 fTrackCuts2->SetEtaRange(-0.9,0.9);
1766 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
e4b0faf2 1767 fTrackCuts2->SetMaxChi2PerClusterTPC(4);
57189f04 1768 fTrackCuts2->SetMinNClustersTPC(80);
987053ce 1769 fTrackCuts2->SetMaxDCAToVertexZ(3.2);
1770 fTrackCuts2->SetMaxDCAToVertexXY(2.4);
1771 fTrackCuts2->SetDCAToVertex2D(kTRUE);
520a29a8 1772
987053ce 1773 for(Int_t ktracks = 0; ktracks<fVevent->GetNumberOfTracks(); ktracks++){
1774 AliVParticle* VtrackHad = fVevent->GetTrack(ktracks);
1775 if (!VtrackHad) {
57189f04 1776 printf("ERROR: Could not receive track %d\n", ktracks);
1777 continue;
1778 }
987053ce 1779
1780 AliVTrack *trackHad = dynamic_cast<AliVTrack*>(VtrackHad);
1781
1782 if(IsAODanalysis()) {
1783 AliAODTrack *atrackHad = dynamic_cast<AliAODTrack*>(VtrackHad);
1784 if(!atrackHad->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
1785 if((!(atrackHad->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackHad->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
1786 if(atrackHad->GetTPCNcls() < 80) continue;
1787 }
1788 else{
1789 AliESDtrack *etrackHad = dynamic_cast<AliESDtrack*>(VtrackHad);
1790 if(!fTrackCuts2->AcceptTrack(etrackHad)) continue;
1791 }
a9123929 1792
57189f04 1793 if(ktracks == itrack) continue; //do not select the same electron
520a29a8 1794
57189f04 1795 Double_t ptHad= -999, pHad=-999., dEdxHad = -999;
1796 Double_t ptEle = -999;
1797 Double_t phiEle = -999, phiHad = -999, Dphi = -999;
1798 Double_t pi = 3.14;
520a29a8 1799
57189f04 1800 dEdxHad = trackHad->GetTPCsignal();
1801 ptHad = trackHad->Pt();
1802 pHad = trackHad->P();
4e01b68c 1803 ptEle = track->Pt();
520a29a8 1804
987053ce 1805 // if(ptHad <2) continue;
4e01b68c 1806 if(ptHad > ptEle) continue;
3c56855b 1807 if(trackHad->Eta()<-0.9 || trackHad->Eta()>0.9) continue;
3c56855b 1808
57189f04 1809 phiEle = track->Phi();
1810 phiHad = trackHad->Phi();
1811 Dphi = phiEle - phiHad;
520a29a8 1812 if (Dphi > 3*pi/2)
57189f04 1813 Dphi = Dphi - 2*pi;
520a29a8 1814 if (Dphi < -pi/2)
57189f04 1815 Dphi = Dphi + 2*pi;
520a29a8 1816
487ae960 1817 if(ptHad>2) DphiPt->Fill(ptEle,Dphi);
1818 if(ptHad>2 && ptHad<4) DphiPt1->Fill(ptEle,Dphi);
1819 if(ptHad>4 && ptHad<6) DphiPt2->Fill(ptEle,Dphi);
1820 if(ptHad>6 && ptHad<8) DphiPt3->Fill(ptEle,Dphi);
a9123929 1821 if(ptHad>4 && ptHad<10) DphiPt4->Fill(ptEle,Dphi);
4e01b68c 1822
57189f04 1823 }
1824}
1825//_________________________________________
987053ce 1826void AliAnalysisTaskElecHadronCorrel::ElectronHadCorrelNoPartner(Int_t itrack,Int_t jtrack, AliVTrack *track, TH2F *DphiPtNew, TH2F *DphiPtNew1,TH2F *DphiPtNew2,TH2F *DphiPtNew3,TH2F *DphiPtNew4)
57189f04 1827{
520a29a8 1828 //Construct Delta Phi between electrons and hadrons for electrons from invariant mass calculation excluding associated track
57189f04 1829
520a29a8 1830 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
1831 fTrackCuts2->SetRequireTPCRefit(kTRUE);
1832 fTrackCuts2->SetRequireITSRefit(kTRUE);
1833 fTrackCuts2->SetEtaRange(-0.9,0.9);
1834 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
e4b0faf2 1835 fTrackCuts2->SetMaxChi2PerClusterTPC(4);
520a29a8 1836 fTrackCuts2->SetMinNClustersTPC(80);
987053ce 1837 fTrackCuts2->SetMaxDCAToVertexZ(3.2);
1838 fTrackCuts2->SetMaxDCAToVertexXY(2.4);
1839 fTrackCuts2->SetDCAToVertex2D(kTRUE);
520a29a8 1840
987053ce 1841 for(Int_t ktracks = 0; ktracks<fVevent->GetNumberOfTracks(); ktracks++){
1842 AliVParticle* VtrackHad = fVevent->GetTrack(ktracks);
1843 if (!VtrackHad) {
520a29a8 1844 printf("ERROR: Could not receive track %d\n", ktracks);
1845 continue;
1846 }
a9123929 1847
987053ce 1848 AliVTrack *trackHad = dynamic_cast<AliVTrack*>(VtrackHad);
520a29a8 1849
987053ce 1850 if(IsAODanalysis()) {
1851 AliAODTrack *atrackHad = dynamic_cast<AliAODTrack*>(VtrackHad);
1852 if(!atrackHad->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
1853 if((!(atrackHad->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackHad->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
1854 if(atrackHad->GetTPCNcls() < 80) continue;
1855 }
1856 else{
1857 AliESDtrack *etrackHad = dynamic_cast<AliESDtrack*>(VtrackHad);
1858 if(!fTrackCuts2->AcceptTrack(etrackHad)) continue;
1859 }
1860
1861 if(ktracks == itrack || ktracks == jtrack) continue; //do not select the same electron and associated track from inv mass cal
520a29a8 1862
1863 Double_t ptHad= -999, pHad=-999., dEdxHad = -999;
1864 Double_t ptEle = -999;
1865 Double_t phiEle = -999, phiHad = -999, Dphi = -999;
1866 Double_t pi = 3.14;
1867
1868 dEdxHad = trackHad->GetTPCsignal();
1869 ptHad = trackHad->Pt();
1870 pHad = trackHad->P();
4e01b68c 1871 ptEle = track->Pt();
520a29a8 1872
a9123929 1873 // if(ptHad <2) continue;
4e01b68c 1874 if(ptHad > ptEle) continue;
3c56855b 1875 if(trackHad->Eta()<-0.9 || trackHad->Eta()>0.9) continue;
520a29a8 1876
1877 phiEle = track->Phi();
1878 phiHad = trackHad->Phi();
1879 Dphi = phiEle - phiHad;
1880 if (Dphi > 3*pi/2)
1881 Dphi = Dphi - 2*pi;
1882 if (Dphi < -pi/2)
1883 Dphi = Dphi + 2*pi;
57189f04 1884
487ae960 1885 if(ptHad>2) DphiPtNew->Fill(ptEle,Dphi);
1886 if(ptHad>2 && ptHad<4) DphiPtNew1->Fill(ptEle,Dphi);
1887 if(ptHad>4 && ptHad<6) DphiPtNew2->Fill(ptEle,Dphi);
1888 if(ptHad>6 && ptHad<8) DphiPtNew3->Fill(ptEle,Dphi);
a9123929 1889 if(ptHad>4 && ptHad<10) DphiPtNew4->Fill(ptEle,Dphi);
520a29a8 1890 }
1891}
4e01b68c 1892//_________________________________________
33369c14 1893void AliAnalysisTaskElecHadronCorrel::ElectronHadCorrelEtaFarSide(Int_t itrack, AliVTrack *track, TH2F *DphiPt, TH2F *DphiPt1,TH2F *DphiPt2,TH2F *DphiPt3,TH2F *DphiPt4)
4e01b68c 1894{
33369c14 1895 //Construct Delta Phi between electrons and hadrons for 1<eta(had)<1.6
4e01b68c 1896
33369c14 1897 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
1898 fTrackCuts2->SetRequireTPCRefit(kTRUE);
1899 fTrackCuts2->SetRequireITSRefit(kTRUE);
1900 fTrackCuts2->SetEtaRange(-0.9,0.9);
1901 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
1902 fTrackCuts2->SetMaxChi2PerClusterTPC(4);
1903 fTrackCuts2->SetMinNClustersTPC(80);
1904 fTrackCuts2->SetMaxDCAToVertexZ(3.2);
1905 fTrackCuts2->SetMaxDCAToVertexXY(2.4);
1906 fTrackCuts2->SetDCAToVertex2D(kTRUE);
4e01b68c 1907
33369c14 1908 for(Int_t ktracks = 0; ktracks<fVevent->GetNumberOfTracks(); ktracks++){
1909 AliVParticle* VtrackHad = fVevent->GetTrack(ktracks);
1910 if (!VtrackHad) {
1911 printf("ERROR: Could not receive track %d\n", ktracks);
1912 continue;
1913 }
1914 AliVTrack *trackHad = dynamic_cast<AliVTrack*>(VtrackHad);
4e01b68c 1915
33369c14 1916 if(IsAODanalysis()) {
1917 AliAODTrack *atrackHad = dynamic_cast<AliAODTrack*>(VtrackHad);
1918 if(!atrackHad->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
1919 if((!(atrackHad->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackHad->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
1920 if(atrackHad->GetTPCNcls() < 80) continue;
1921 }
1922 else{
1923 AliESDtrack *etrackHad = dynamic_cast<AliESDtrack*>(VtrackHad);
1924 if(!fTrackCuts2->AcceptTrack(etrackHad)) continue;
1925 }
4e01b68c 1926
33369c14 1927 if(ktracks == itrack) continue; //do not select the same electron
4e01b68c 1928
33369c14 1929 Double_t ptHad= -999, pHad=-999., dEdxHad = -999;
1930 Double_t ptEle = -999;
1931 Double_t phiEle = -999, phiHad = -999, Dphi = -999;
1932 Double_t pi = 3.14;
4e01b68c 1933
33369c14 1934 dEdxHad = trackHad->GetTPCsignal();
1935 ptHad = trackHad->Pt();
1936 pHad = trackHad->P();
1937 ptEle = track->Pt();
4e01b68c 1938
33369c14 1939 // if(ptHad <2) continue;
1940 if(ptHad > ptEle) continue;
1941 if(trackHad->Eta()<1 || trackHad->Eta()>1.6) continue;
1942
1943 phiEle = track->Phi();
1944 phiHad = trackHad->Phi();
1945 Dphi = phiEle - phiHad;
1946 if (Dphi > 3*pi/2)
1947 Dphi = Dphi - 2*pi;
1948 if (Dphi < -pi/2)
1949 Dphi = Dphi + 2*pi;
1950
1951 if(ptHad>2) DphiPt->Fill(ptEle,Dphi);
1952 if(ptHad>2 && ptHad<4) DphiPt1->Fill(ptEle,Dphi);
1953 if(ptHad>4 && ptHad<6) DphiPt2->Fill(ptEle,Dphi);
1954 if(ptHad>6 && ptHad<8) DphiPt3->Fill(ptEle,Dphi);
a9123929 1955 if(ptHad>4 && ptHad<10) DphiPt4->Fill(ptEle,Dphi);
33369c14 1956
1957 }
4e01b68c 1958}
bf697dda 1959//_________________________________________
1960void AliAnalysisTaskElecHadronCorrel::ElectronHadCorrelEtaBins(Int_t itrack, AliVTrack *track, TH2F *DphiPtEta1, TH2F *DphiPtEta11,TH2F *DphiPtEta12,TH2F *DphiPtEta13,TH2F *DphiPtEta14,TH2F *DphiPtEta2, TH2F *DphiPtEta21,TH2F *DphiPtEta22,TH2F *DphiPtEta23,TH2F *DphiPtEta24)
1961{
1962 //Construct Delta Phi between electrons and hadrons in different Eta bins
1963
1964 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
1965 fTrackCuts2->SetRequireTPCRefit(kTRUE);
1966 fTrackCuts2->SetRequireITSRefit(kTRUE);
1967 fTrackCuts2->SetEtaRange(-0.9,0.9);
1968 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
1969 fTrackCuts2->SetMaxChi2PerClusterTPC(4);
1970 fTrackCuts2->SetMinNClustersTPC(80);
1971 fTrackCuts2->SetMaxDCAToVertexZ(3.2);
1972 fTrackCuts2->SetMaxDCAToVertexXY(2.4);
1973 fTrackCuts2->SetDCAToVertex2D(kTRUE);
1974
1975 for(Int_t ktracks = 0; ktracks<fVevent->GetNumberOfTracks(); ktracks++){
1976 AliVParticle* VtrackHad = fVevent->GetTrack(ktracks);
1977 if (!VtrackHad) {
1978 printf("ERROR: Could not receive track %d\n", ktracks);
1979 continue;
1980 }
1981
1982 AliVTrack *trackHad = dynamic_cast<AliVTrack*>(VtrackHad);
1983
1984 if(IsAODanalysis()) {
1985 AliAODTrack *atrackHad = dynamic_cast<AliAODTrack*>(VtrackHad);
1986 if(!atrackHad->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
1987 if((!(atrackHad->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackHad->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
1988 if(atrackHad->GetTPCNcls() < 80) continue;
1989 }
1990 else{
1991 AliESDtrack *etrackHad = dynamic_cast<AliESDtrack*>(VtrackHad);
1992 if(!fTrackCuts2->AcceptTrack(etrackHad)) continue;
1993 }
1994
1995 if(ktracks == itrack) continue; //do not select the same electron
1996
1997 Double_t ptHad= -999, pHad=-999., dEdxHad = -999;
1998 Double_t ptEle = -999;
1999 Double_t phiEle = -999, phiHad = -999, Dphi = -999;
2000 Double_t etaEle = -999, etaHad=-999, DEta=-999;
2001 Double_t pi = 3.14;
2002
2003 dEdxHad = trackHad->GetTPCsignal();
2004 ptHad = trackHad->Pt();
2005 pHad = trackHad->P();
2006 ptEle = track->Pt();
2007
2008 // if(ptHad <2) continue;
2009 if(ptHad > ptEle) continue;
2010 if(trackHad->Eta()<-0.9 || trackHad->Eta()>0.9) continue;
2011
2012 phiEle = track->Phi();
2013 phiHad = trackHad->Phi();
2014 Dphi = phiEle - phiHad;
2015
2016 if (Dphi > 3*pi/2)
2017 Dphi = Dphi - 2*pi;
2018 if (Dphi < -pi/2)
2019 Dphi = Dphi + 2*pi;
2020
2021 etaEle = track->Eta();
2022 etaHad = trackHad->Eta();
2023 DEta = etaEle - etaHad;
2024
2025 if(TMath::Abs(DEta)<0.8){
a9123929 2026 if(ptHad>2) DphiPtEta1->Fill(ptEle,Dphi);
2027 if(ptHad>2 && ptHad<4) DphiPtEta11->Fill(ptEle,Dphi);
2028 if(ptHad>4 && ptHad<6) DphiPtEta12->Fill(ptEle,Dphi);
2029 if(ptHad>6 && ptHad<8) DphiPtEta13->Fill(ptEle,Dphi);
2030 if(ptHad>4 && ptHad<10) DphiPtEta14->Fill(ptEle,Dphi);
bf697dda 2031 }
2032
2033 if(TMath::Abs(DEta)>0.8){
2034 if(ptHad>2) DphiPtEta2->Fill(ptEle,Dphi);
2035 if(ptHad>2 && ptHad<4) DphiPtEta21->Fill(ptEle,Dphi);
2036 if(ptHad>4 && ptHad<6) DphiPtEta22->Fill(ptEle,Dphi);
2037 if(ptHad>6 && ptHad<8) DphiPtEta23->Fill(ptEle,Dphi);
a9123929 2038 if(ptHad>4 && ptHad<10) DphiPtEta24->Fill(ptEle,Dphi);
bf697dda 2039 }
2040 }
2041}
2042//_________________________________________
2043void AliAnalysisTaskElecHadronCorrel::ElectronHadCorrelEtaBinsNoPartner(Int_t itrack,Int_t jtrack, AliVTrack *track, TH2F *DphiPtEta1, TH2F *DphiPtEta11,TH2F *DphiPtEta12,TH2F *DphiPtEta13,TH2F *DphiPtEta14,TH2F *DphiPtEta2, TH2F *DphiPtEta21,TH2F *DphiPtEta22,TH2F *DphiPtEta23,TH2F *DphiPtEta24)
2044{
2045 //Construct Delta Phi between electrons and hadrons in different Eta bins (exclude associated track)
2046
2047 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
2048 fTrackCuts2->SetRequireTPCRefit(kTRUE);
2049 fTrackCuts2->SetRequireITSRefit(kTRUE);
2050 fTrackCuts2->SetEtaRange(-0.9,0.9);
2051 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
2052 fTrackCuts2->SetMaxChi2PerClusterTPC(4);
2053 fTrackCuts2->SetMinNClustersTPC(80);
2054 fTrackCuts2->SetMaxDCAToVertexZ(3.2);
2055 fTrackCuts2->SetMaxDCAToVertexXY(2.4);
2056 fTrackCuts2->SetDCAToVertex2D(kTRUE);
2057
2058 for(Int_t ktracks = 0; ktracks<fVevent->GetNumberOfTracks(); ktracks++){
2059 AliVParticle* VtrackHad = fVevent->GetTrack(ktracks);
2060 if (!VtrackHad) {
2061 printf("ERROR: Could not receive track %d\n", ktracks);
2062 continue;
2063 }
2064
2065 AliVTrack *trackHad = dynamic_cast<AliVTrack*>(VtrackHad);
2066
2067 if(IsAODanalysis()) {
2068 AliAODTrack *atrackHad = dynamic_cast<AliAODTrack*>(VtrackHad);
2069 if(!atrackHad->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
2070 if((!(atrackHad->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackHad->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
2071 if(atrackHad->GetTPCNcls() < 80) continue;
2072 }
2073 else{
2074 AliESDtrack *etrackHad = dynamic_cast<AliESDtrack*>(VtrackHad);
2075 if(!fTrackCuts2->AcceptTrack(etrackHad)) continue;
2076 }
2077
2078 if(ktracks == itrack || ktracks == jtrack) continue; //do not select the same electron and associated track from inv mass cal
2079
2080 Double_t ptHad= -999, pHad=-999., dEdxHad = -999;
2081 Double_t ptEle = -999;
2082 Double_t phiEle = -999, phiHad = -999, Dphi = -999;
2083 Double_t etaEle = -999, etaHad=-999, DEta=-999;
2084 Double_t pi = 3.14;
2085
2086 dEdxHad = trackHad->GetTPCsignal();
2087 ptHad = trackHad->Pt();
2088 pHad = trackHad->P();
2089 ptEle = track->Pt();
2090
2091 // if(ptHad <2) continue;
2092 if(ptHad > ptEle) continue;
2093 if(trackHad->Eta()<-0.9 || trackHad->Eta()>0.9) continue;
2094
2095 phiEle = track->Phi();
2096 phiHad = trackHad->Phi();
2097 Dphi = phiEle - phiHad;
2098
2099 if (Dphi > 3*pi/2)
2100 Dphi = Dphi - 2*pi;
2101 if (Dphi < -pi/2)
2102 Dphi = Dphi + 2*pi;
2103
2104 etaEle = track->Eta();
2105 etaHad = trackHad->Eta();
2106 DEta = etaEle - etaHad;
2107
2108 if(TMath::Abs(DEta)<0.8){
2109 if(ptHad>2) DphiPtEta1->Fill(ptEle,Dphi);
2110 if(ptHad>2 && ptHad<4) DphiPtEta11->Fill(ptEle,Dphi);
2111 if(ptHad>4 && ptHad<6) DphiPtEta12->Fill(ptEle,Dphi);
2112 if(ptHad>6 && ptHad<8) DphiPtEta13->Fill(ptEle,Dphi);
a9123929 2113 if(ptHad>4 && ptHad<10) DphiPtEta14->Fill(ptEle,Dphi);
bf697dda 2114 }
2115
2116 if(TMath::Abs(DEta)>0.8){
2117 if(ptHad>2) DphiPtEta2->Fill(ptEle,Dphi);
2118 if(ptHad>2 && ptHad<4) DphiPtEta21->Fill(ptEle,Dphi);
2119 if(ptHad>4 && ptHad<6) DphiPtEta22->Fill(ptEle,Dphi);
2120 if(ptHad>6 && ptHad<8) DphiPtEta23->Fill(ptEle,Dphi);
a9123929 2121 if(ptHad>4 && ptHad<10) DphiPtEta24->Fill(ptEle,Dphi);
bf697dda 2122 }
2123 }
2124}
9866fa7b 2125/*
33369c14 2126//_________________________________________
a9123929 2127void AliAnalysisTaskElecHadronCorrel::MixedEvent(AliVTrack *track, TH2F *DphiPt, TH2F *DphiPt1,TH2F *DphiPt2, TH2F *DphiPt3, TH2F *DphiPt4)
4e01b68c 2128{
4e01b68c 2129
a9123929 2130 const AliAODVertex *pVtx = fAOD->GetPrimaryVertex();
2131 Double_t zVtx;
2132 zVtx = pVtx->GetZ();
4e01b68c 2133
a9123929 2134 AliCentrality *fCentrality1 = (AliCentrality*)fAOD->GetCentrality();
2135 Double_t centvalue = fCentrality1->GetCentralityPercentile("V0M");
3c56855b 2136
a9123929 2137 AliEventPool* pool = fPoolMgr->GetEventPool(centvalue, zVtx); // Get the buffer associated with the current centrality and z-vtx
2138 if (!pool)
2139 AliFatal(Form("No pool found for centrality = %f, zVtx = %f", centvalue, zVtx));
33369c14 2140
a9123929 2141 // pool->PrintInfo();
2142 if (pool->GetCurrentNEvents() >= 5) // start mixing when 5 events are in the buffer
2143 {
2144 Int_t nMix = pool->GetCurrentNEvents();
2145 fNoMixedEvents->Fill(0);
2146 fMixStat->Fill(pool->GetCurrentNEvents(),centvalue);
2147 fMixStat1->Fill(pool->GetCurrentNEvents(),zVtx);
2148
2149 // cout << "nMix = " << nMix << " tracks in pool = " << pool->NTracksInPool() << endl;
2150 for (Int_t jMix=0; jMix<nMix; jMix++) // mix with each event in the buffer
2151 {
2152 TObjArray* bgTracks = pool->GetEvent(jMix);
2153 for (Int_t i=0;i<bgTracks->GetEntriesFast(); i++)
2154 {
2155 AliVParticle* mixtrk = (AliVParticle*) bgTracks->At(i);
2156
2157 Double_t mixtrkPhi = -999;
2158 Double_t ptEle = -999;
2159 Double_t phiEle = -999, Dphi = -999;
2160 Double_t pi = 3.14;
2161 Double_t ptmixtrk = -999;
2162
2163 ptEle = track->Pt();
2164 ptmixtrk = mixtrk->Pt();
2165 if(ptmixtrk > ptEle) continue;
2166
2167 mixtrkPhi = mixtrk->Phi();
2168 phiEle = track->Phi();
2169 Dphi = phiEle - mixtrkPhi;
2170
2171 if (Dphi > 3*pi/2)
2172 Dphi = Dphi - 2*pi;
2173 if (Dphi < -pi/2)
2174 Dphi = Dphi + 2*pi;
2175 if(ptmixtrk>2) DphiPt->Fill(ptEle,Dphi);
2176 if(ptmixtrk>2 && ptmixtrk<4) DphiPt1->Fill(ptEle,Dphi);
2177 if(ptmixtrk>4 && ptmixtrk<6) DphiPt2->Fill(ptEle,Dphi);
2178 if(ptmixtrk>6 && ptmixtrk<8) DphiPt3->Fill(ptEle,Dphi);
2179 if(ptmixtrk>4 && ptmixtrk<10) DphiPt4->Fill(ptEle,Dphi);
2180 }
2181 }
2182 }
33369c14 2183}
2184//___________________________________________
2185TObjArray* AliAnalysisTaskElecHadronCorrel::CloneAndReduceTrackList()
2186{
a9123929 2187 // clones a track list by using AliehDPhiBasicParticle which uses much less memory (used for event mixing)
2188
2189 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
2190 fTrackCuts2->SetRequireTPCRefit(kTRUE);
2191 fTrackCuts2->SetRequireITSRefit(kTRUE);
2192 fTrackCuts2->SetEtaRange(-0.9,0.9);
2193 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
2194 fTrackCuts2->SetMaxChi2PerClusterTPC(3.5);
2195 fTrackCuts2->SetMinNClustersTPC(80);
2196
2197 TObjArray* tracksClone = new TObjArray;
2198 tracksClone->SetOwner(kTRUE);
2199
2200 for(Int_t ktracks = 0; ktracks<fAOD->GetNumberOfTracks(); ktracks++){
2201 AliAODTrack* track = fAOD->GetTrack(ktracks);
2202 if (!track) {
2203 printf("ERROR: Could not receive track %d\n", ktracks);
2204 continue;
2205 }
2206 if(!track->TestFilterMask(AliAODTrack::kTrkGlobalNoDCA)) continue;
2207
2208 // if(ktracks == iTrack) continue;
2209 Double_t eta=-999,ptHad= -999, pHad=-999., phi=-999.0;
2210 Int_t label=-9999, id=-999;
2211 eta = track->Eta();
2212 ptHad = track->Pt();
2213 pHad = track->P();
2214 phi= track->Phi();
2215 label= track->GetLabel();
2216 id=track->GetID();
2217
2218 if(track->Eta()<-0.9 || track->Eta()>0.9) continue;
2219 if(!ProcessCutStep(AliHFEcuts::kStepRecKineITSTPC, track)) continue;
2220 if(!ProcessCutStep(AliHFEcuts::kStepHFEcutsTPC, track)) continue;
2221 if(ptHad <2) continue;
2222 // if(!fTrackCuts2->AcceptTrack(track)) continue;
2223
2224 AliVParticle* particle = (AliVParticle*) fAOD->GetTrack(ktracks);
2225 tracksClone->Add(new AliehDPhiBasicParticle(particle->Eta(), particle->Phi(), particle->Pt(), particle->Charge()));
2226
4e01b68c 2227 }
33369c14 2228
a9123929 2229 return tracksClone;
33369c14 2230}
9866fa7b 2231*/
3c56855b 2232//___________________________________________
2233void AliAnalysisTaskElecHadronCorrel::HadronInfo(Int_t itrack)
2234{
2235 //Hadron information
987053ce 2236
3c56855b 2237 fTrackCuts2->SetAcceptKinkDaughters(kFALSE);
2238 fTrackCuts2->SetRequireTPCRefit(kTRUE);
2239 fTrackCuts2->SetRequireITSRefit(kTRUE);
2240 fTrackCuts2->SetEtaRange(-0.9,0.9);
2241 fTrackCuts2->SetRequireSigmaToVertex(kTRUE);
e4b0faf2 2242 fTrackCuts2->SetMaxChi2PerClusterTPC(4);
3c56855b 2243 fTrackCuts2->SetMinNClustersTPC(80);
987053ce 2244 fTrackCuts2->SetMaxDCAToVertexZ(3.2);
2245 fTrackCuts2->SetMaxDCAToVertexXY(2.4);
2246 fTrackCuts2->SetDCAToVertex2D(kTRUE);
3c56855b 2247
987053ce 2248 for(Int_t ktracks = 0; ktracks<fVevent->GetNumberOfTracks(); ktracks++){
2249 AliVParticle* VtrackHad = fVevent->GetTrack(ktracks);
2250 if (!VtrackHad) {
3c56855b 2251 printf("ERROR: Could not receive track %d\n", ktracks);
2252 continue;
2253 }
987053ce 2254
2255 AliVTrack *trackHad = dynamic_cast<AliVTrack*>(VtrackHad);
2256
2257 if(IsAODanalysis()) {
2258 AliAODTrack *atrackHad = dynamic_cast<AliAODTrack*>(VtrackHad);
2259 if(!atrackHad->TestFilterMask(AliAODTrack::kTrkTPCOnly)) continue;
2260 if((!(atrackHad->GetStatus()&AliESDtrack::kITSrefit)|| (!(atrackHad->GetStatus()&AliESDtrack::kTPCrefit)))) continue;
2261 if(atrackHad->GetTPCNcls() < 80) continue;
2262 }
2263 else{
2264 AliESDtrack *etrackHad = dynamic_cast<AliESDtrack*>(VtrackHad);
2265 if(!fTrackCuts2->AcceptTrack(etrackHad)) continue;
2266 }
2267
3c56855b 2268 if(ktracks == itrack) continue; //do not select the same electron
a9123929 2269
3c56855b 2270 Double_t ptHad= -999;
3c56855b 2271 ptHad = trackHad->Pt();
a9123929 2272
3c56855b 2273 if(trackHad->Eta()<-0.9 || trackHad->Eta()>0.9) continue;
a9123929 2274 // cout << "pt had = " << ptHad <<endl;
3c56855b 2275
3c56855b 2276 if(ptHad<2) continue;
2277
2278 fHadronPhi->Fill(trackHad->Phi());
2279 fHadronPhiPt->Fill(trackHad->Phi(),ptHad);
2280 if (trackHad->Eta() >0 && trackHad->Eta() <0.9) fHadronPhiTPChalf->Fill(trackHad->Phi());
2281
3c56855b 2282 fHadronPt->Fill(ptHad);
2283 }
2284}
2285//_________________________________________
987053ce 2286void AliAnalysisTaskElecHadronCorrel::CheckCentrality(AliVEvent* event, Bool_t &centralitypass)
3c56855b 2287{
2288 // Check if event is within the set centrality range. Falls back to V0 centrality determination if no method is set
2289 if (!fkCentralityMethod) AliFatal("No centrality method set! FATAL ERROR!");
2290 fCentrality = event->GetCentrality()->GetCentralityPercentile(fkCentralityMethod);
a9123929 2291 // cout << "Centrality evaluated-------------------------: " << fCentrality <<endl;
3c56855b 2292
2293 if ((fCentrality <= fCentralityMin) || (fCentrality > fCentralityMax))
2294 {
2295 fCentralityNoPass->Fill(fCentrality);
a9123929 2296 // cout << "--------------Fill no pass-------------------------"<<endl;
3c56855b 2297 centralitypass = kFALSE;
2298 }else
2299 {
2300 fCentralityPass->Fill(fCentrality);
a9123929 2301 // cout << "--------------Fill pass-------------------------"<<endl;
3c56855b 2302 centralitypass = kTRUE;
2303 }
2304
2305}
2306//_____________________________________________________________________________
2307void AliAnalysisTaskElecHadronCorrel::SetCentralityParameters(Double_t CentralityMin, Double_t CentralityMax, const char* CentralityMethod)
2308{
2309 // Set a centrality range ]min, max] and define the method to use for centrality selection
2310 fCentralityMin = CentralityMin;
2311 fCentralityMax = CentralityMax;
2312 fkCentralityMethod = CentralityMethod;
2313}