AliPhysics  ff1d528 (ff1d528)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliAnaParticleIsolation.cxx
Go to the documentation of this file.
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 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 // --- ROOT system ---
17 #include <TClonesArray.h>
18 #include <TList.h>
19 #include <TObjString.h>
20 #include <TH2F.h>
21 //#include <TH3F.h>
22 #include <TClass.h>
23 #include <TH2F.h>
24 #include "TDatabasePDG.h"
25 
26 // --- Analysis system ---
28 #include "AliCaloTrackReader.h"
29 #include "AliMCEvent.h"
30 #include "AliIsolationCut.h"
31 #include "AliFiducialCut.h"
32 #include "AliMCAnalysisUtils.h"
34 #include "AliVParticle.h"
35 #include "AliAODPWG4ParticleCorrelation.h"
36 #include "AliMCAnalysisUtils.h"
37 #include "AliVTrack.h"
38 #include "AliVCluster.h"
39 #include "AliESDEvent.h"
40 #include "AliAODEvent.h"
41 
42 // --- Detectors ---
43 #include "AliEMCALGeometry.h"
44 #include "AliPHOSGeoUtils.h"
45 
49 
50 //__________________________________________________
52 //__________________________________________________
55 fIsoDetector(-1), fIsoDetectorString(""),
56 fReMakeIC(0), fMakeSeveralIC(0),
57 fFillTMHisto(0), fFillSSHisto(1),
58 fFillEMCALRegionHistograms(0), fFillUEBandSubtractHistograms(1),
59 fFillCellHistograms(0),
60 fFillOverlapHistograms(0),
61 fStudyTracksInCone(0), fStudyMCConversionRadius(0),
62 fStudyExoticTrigger(0),
63 fFillTaggedDecayHistograms(0), fNDecayBits(0),
64 fDecayBits(), fDecayTagsM02Cut(0),
65 fFillNLMHistograms(0),
66 fLeadingOnly(0), fCheckLeadingWithNeutralClusters(0),
67 fSelectPrimariesInCone(0), fMakePrimaryPi0DecayStudy(0),
68 fFillBackgroundBinHistograms(0), fNBkgBin(0),
69 fFillPtTrigBinHistograms(0), fNPtTrigBin(0),
70 fMinCellsAngleOverlap(0),
71 // Several IC
72 fNCones(0), fNPtThresFrac(0),
73 fConeSizes(), fPtThresholds(),
74 fPtFractions(), fSumPtThresholds(),
75 fStudyPtCutInCone(0), fNPtCutsInCone(0),
76 fMinPtCutInCone(), fMaxPtCutInCone(),
77 fStudyEtaCutInCone(0), fNEtaCutsInCone(0), fEtaCutInCone(),
78 fStudyRCutInCone(0), fNRCutsInCone(0), fRCutInCone(),
79 fNNCellsInCandidate(0), fNCellsInCandidate(),
80 fNExoCutInCandidate(0), fExoCutInCandidate(),
81 fMomentum(), fMomIso(),
82 fMomDaugh1(), fMomDaugh2(),
83 fTrackVector(), fProdVertex(),
84 fCluster(0), fClustersArr(0),
85 fIsExoticTrigger(0), fClusterExoticity(1),
86 // Histograms
87 fhEIso(0), fhPtIso(0),
88 fhPtCentralityIso(0), fhPtEventPlaneIso(0),
89 fhPtNLocMaxIso(0),
90 fhPhiIso(0), fhEtaIso(0), fhEtaPhiIso(0),
91 fhEtaPhiNoIso(0),
92 fhENoIso(0), fhPtNoIso(0), fhPtNLocMaxNoIso(0),
93 fhEIsoExoTrigger(0), fhENoIsoExoTrigger(0),
94 fhPtIsoExoTrigger(0), fhPtNoIsoExoTrigger(0),
95 
96 fhPtInCone(0),
97 fhPtClusterInCone(0), fhPtCellInCone(0), fhPtTrackInCone(0),
98 fhPtInConeExoTrigger(0), fhPtClusterInConeExoTrigger(0), fhPtTrackInConeExoTrigger(0),
99 fhPtTrackInConeOtherBCPileUpSPD(0), fhPtTrackInConeVtxBC0(0),
100 fhPtTrackInConeBC0PileUpSPD(0),
101 fhPtInConePileUp(), fhPtInConeCent(0),
102 
103 fhPerpConeSumPt(0), fhPerpConeSumPtTOFBC0(0),
104 fhPtInPerpCone(0), fhPtInPerpConeTOFBC0(0),
105 fhEtaPhiInConeCluster(0), fhEtaPhiCluster(0),
106 fhEtaPhiInConeTrack(0), fhEtaPhiTrack(0),
107 fhEtaPhiInPerpCone(0), fhEtaPhiInPerpConeTOFBC0(0),
108 fhEtaBandClusterEtaPhi(0), fhPhiBandClusterEtaPhi(0),
109 fhEtaBandTrackEtaPhi(0), fhPhiBandTrackEtaPhi(0),
110 fhEtaBandClusterPt(0), fhPhiBandClusterPt(0),
111 fhEtaBandTrackPt(0), fhPhiBandTrackPt(0),
112 fhEtaBandCell(0), fhPhiBandCell(0),
113 fhConePtLead(0), fhConePtLeadCluster(0), fhConePtLeadTrack(0),
114 fhConePtLeadClustervsTrack(0), fhConePtLeadClusterTrackFrac(0),
115 fhConeSumPt(0), //fhPtLambda0Eiso(0),
116 fhConeSumPtCellTrack(0),
117 fhConeSumPtCell(0), fhConeSumPtCluster(0), fhConeSumPtTrack(0),
118 fhConeSumPtExoTrigger(0), fhConeSumPtClusterExoTrigger(0), fhConeSumPtTrackExoTrigger(0),
119 
120 fhConeSumPtEtaBandUECluster(0), fhConeSumPtPhiBandUECluster(0),
121 fhConeSumPtEtaBandUETrack(0), fhConeSumPtPhiBandUETrack(0),
122 fhConeSumPtEtaBandUECell(0), fhConeSumPtPhiBandUECell(0),
123 fhConeSumPtTrigEtaPhi(0),
124 fhConeSumPtCellTrackTrigEtaPhi(0),
125 fhConeSumPtEtaBandUEClusterTrigEtaPhi(0), fhConeSumPtPhiBandUEClusterTrigEtaPhi(0),
126 fhConeSumPtEtaBandUETrackTrigEtaPhi(0), fhConeSumPtPhiBandUETrackTrigEtaPhi(0),
127 fhConeSumPtEtaBandUECellTrigEtaPhi(0), fhConeSumPtPhiBandUECellTrigEtaPhi(0),
128 fhConeSumPtEtaUESub(0), fhConeSumPtPhiUESub(0),
129 fhConeSumPtEtaUESubTrigEtaPhi(0), fhConeSumPtPhiUESubTrigEtaPhi(0),
130 fhConeSumPtEtaUESubTrackCell(0), fhConeSumPtPhiUESubTrackCell(0),
131 fhConeSumPtEtaUESubTrackCellTrigEtaPhi(0), fhConeSumPtPhiUESubTrackCellTrigEtaPhi(0),
132 fhConeSumPtEtaUENormCluster(0), fhConeSumPtPhiUENormCluster(0),
133 fhConeSumPtEtaUESubCluster(0), fhConeSumPtPhiUESubCluster(0),
134 fhConeSumPtEtaUESubClusterTrigEtaPhi(0), fhConeSumPtPhiUESubClusterTrigEtaPhi(0),
135 fhConeSumPtEtaUESubCell(0), fhConeSumPtPhiUESubCell(0),
136 fhConeSumPtEtaUESubCellTrigEtaPhi(0), fhConeSumPtPhiUESubCellTrigEtaPhi(0),
137 fhConeSumPtEtaUENormTrack(0), fhConeSumPtPhiUENormTrack(0),
138 fhConeSumPtEtaUESubTrack(0), fhConeSumPtPhiUESubTrack(0),
139 fhConeSumPtEtaUESubTrackTrigEtaPhi(0), fhConeSumPtPhiUESubTrackTrigEtaPhi(0),
140 fhFractionTrackOutConeEta(0), fhFractionTrackOutConeEtaTrigEtaPhi(0),
141 fhFractionClusterOutConeEta(0), fhFractionClusterOutConeEtaTrigEtaPhi(0),
142 fhFractionClusterOutConePhi(0), fhFractionClusterOutConePhiTrigEtaPhi(0),
143 fhFractionCellOutConeEta(0), fhFractionCellOutConeEtaTrigEtaPhi(0),
144 fhFractionCellOutConePhi(0), fhFractionCellOutConePhiTrigEtaPhi(0),
145 fhConeSumPtClustervsTrack(0), fhConeSumPtClusterTrackFrac(0),
146 fhConeSumPtEtaUESubClustervsTrack(0), fhConeSumPtPhiUESubClustervsTrack(0),
147 fhConeSumPtCellvsTrack(0),
148 fhConeSumPtEtaUESubCellvsTrack(0), fhConeSumPtPhiUESubCellvsTrack(0),
149 fhEtaBandClustervsTrack(0), fhPhiBandClustervsTrack(0),
150 fhEtaBandNormClustervsTrack(0), fhPhiBandNormClustervsTrack(0),
151 fhEtaBandCellvsTrack(0), fhPhiBandCellvsTrack(0),
152 fhEtaBandNormCellvsTrack(0), fhPhiBandNormCellvsTrack(0),
153 fhConeSumPtSubvsConeSumPtTotPhiTrack(0), fhConeSumPtSubNormvsConeSumPtTotPhiTrack(0),
154 fhConeSumPtSubvsConeSumPtTotEtaTrack(0), fhConeSumPtSubNormvsConeSumPtTotEtaTrack(0),
155 fhConeSumPtSubvsConeSumPtTotPhiCluster(0), fhConeSumPtSubNormvsConeSumPtTotPhiCluster(0),
156 fhConeSumPtSubvsConeSumPtTotEtaCluster(0), fhConeSumPtSubNormvsConeSumPtTotEtaCluster(0),
157 fhConeSumPtSubvsConeSumPtTotPhiCell(0), fhConeSumPtSubNormvsConeSumPtTotPhiCell(0),
158 fhConeSumPtSubvsConeSumPtTotEtaCell(0), fhConeSumPtSubNormvsConeSumPtTotEtaCell(0),
159 fhConeSumPtVSUETracksEtaBand(0), fhConeSumPtVSUETracksPhiBand(0),
160 fhConeSumPtVSUEClusterEtaBand(0), fhConeSumPtVSUEClusterPhiBand(0),
161 fhPtPrimMCPi0DecayPairOutOfCone(0),
162 fhPtPrimMCPi0DecayPairOutOfAcceptance(0),
163 fhPtPrimMCPi0DecayPairOutOfAcceptanceNoOverlap(0),
164 fhPtPrimMCPi0DecayPairAcceptInConeLowPt(0),
165 fhPtPrimMCPi0DecayPairAcceptInConeLowPtNoOverlap(0),
166 fhPtPrimMCPi0DecayPairAcceptInConeLowPtNoOverlapCaloE(0),
167 fhPtPrimMCPi0DecayPairNoOverlap(0),
168 fhPtPrimMCPi0DecayIsoPairOutOfCone(0),
169 fhPtPrimMCPi0DecayIsoPairOutOfAcceptance(0),
170 fhPtPrimMCPi0DecayIsoPairOutOfAcceptanceNoOverlap(0),
171 fhPtPrimMCPi0DecayIsoPairAcceptInConeLowPt(0),
172 fhPtPrimMCPi0DecayIsoPairAcceptInConeLowPtNoOverlap(0),
173 fhPtPrimMCPi0DecayIsoPairAcceptInConeLowPtNoOverlapCaloE(0),
174 fhPtPrimMCPi0DecayIsoPairNoOverlap(0),
175 fhPtPrimMCPi0Overlap(0), fhPtPrimMCPi0IsoOverlap(0),
176 fhPtPrimMCEtaDecayPairOutOfCone(0),
177 fhPtPrimMCEtaDecayPairOutOfAcceptance(0),
178 fhPtPrimMCEtaDecayPairOutOfAcceptanceNoOverlap(0),
179 fhPtPrimMCEtaDecayPairAcceptInConeLowPt(0),
180 fhPtPrimMCEtaDecayPairAcceptInConeLowPtNoOverlap(0),
181 fhPtPrimMCEtaDecayPairAcceptInConeLowPtNoOverlapCaloE(0),
182 fhPtPrimMCEtaDecayPairNoOverlap(0),
183 fhPtPrimMCEtaDecayIsoPairOutOfCone(0),
184 fhPtPrimMCEtaDecayIsoPairOutOfAcceptance(0),
185 fhPtPrimMCEtaDecayIsoPairOutOfAcceptanceNoOverlap(0),
186 fhPtPrimMCEtaDecayIsoPairAcceptInConeLowPt(0),
187 fhPtPrimMCEtaDecayIsoPairAcceptInConeLowPtNoOverlap(0),
188 fhPtPrimMCEtaDecayIsoPairAcceptInConeLowPtNoOverlapCaloE(0),
189 fhPtPrimMCEtaDecayIsoPairNoOverlap(0),
190 fhPtPrimMCEtaOverlap(0), fhPtPrimMCEtaIsoOverlap(0),
191 fhPtLeadConeBin(0), fhSumPtConeBin(0),
192 fhPtLeadConeBinMC(0), fhSumPtConeBinMC(0),
193 fhPtLeadConeBinDecay(0), fhSumPtConeBinDecay(0),
194 fhPtLeadConeBinLambda0(0), fhSumPtConeBinLambda0(0),
195 fhPtLeadConeBinLambda0MC(0), fhSumPtConeBinLambda0MC(0),
196 fhPtTrigBinPtLeadCone(0), fhPtTrigBinSumPtCone(0),
197 fhPtTrigBinSumPtTrackCone(0), fhPtTrigBinSumPtClusterCone(0),
198 fhPtTrigBinPtLeadConeMC(0), fhPtTrigBinSumPtConeMC(0),
199 fhPtTrigBinSumPtTrackConeMC(0), fhPtTrigBinSumPtClusterConeMC(0),
200 fhPtTrigBinPtLeadConeDecay(0), fhPtTrigBinSumPtConeDecay(0),
201 fhPtTrigBinSumPtTrackConeDecay(0), fhPtTrigBinSumPtClusterConeDecay(0),
202 fhPtTrigBinLambda0vsPtLeadCone(0), fhPtTrigBinLambda0vsSumPtCone(0),
203 fhPtTrigBinLambda0vsSumPtTrackCone(0), fhPtTrigBinLambda0vsSumPtClusterCone(0),
204 fhPtTrigBinLambda0vsPtLeadConeMC(0), fhPtTrigBinLambda0vsSumPtConeMC(0),
205 fhPtTrigBinLambda0vsSumPtTrackConeMC(0), fhPtTrigBinLambda0vsSumPtClusterConeMC(0),
206 fhPtTrigBinLambda0vsSumPtConeMCNoOverlap(0),fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap(0),
207 fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap(0), fhPtTrigBinLambda0vsSumPtConeMC1Overlap(0),
208 fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap(0),fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap(0),
209 // Number of local maxima in cluster
210 fhNLocMax(),
211 fhELambda0LocMax1(), fhELambda1LocMax1(),
212 fhELambda0LocMax2(), fhELambda1LocMax2(),
213 fhELambda0LocMaxN(), fhELambda1LocMaxN(),
214 // PileUp
215 fhEIsoPileUp(), fhPtIsoPileUp(),
216 fhENoIsoPileUp(), fhPtNoIsoPileUp(),
217 fhTimeENoCut(0), fhTimeESPD(0), fhTimeESPDMulti(0),
218 fhTimeNPileUpVertSPD(0), fhTimeNPileUpVertTrack(0),
219 fhTimeNPileUpVertContributors(0),
220 fhTimePileUpMainVertexZDistance(0), fhTimePileUpMainVertexZDiamond(0),
221 
222 fhPtClusterInConePerRCut(0), fhPtClusterInConePerRCutLargePtTrig(0),
223 fhPtTrackInConePerRCut(0), fhPtTrackInConePerRCutLargePtTrig(0),
224 fhConeSumPtClusterPerRCut(0), fhConeSumPtClusterPerRCutLargePtTrig(0),
225 fhConeSumPtTrackPerRCut(0), fhConeSumPtTrackPerRCutLargePtTrig(0),
226 fhConeNClusterPerMinPtCut(0), fhConeNClusterPerMinPtCutLargePtTrig(0),
227 fhConeNTrackPerMinPtCut(0), fhConeNTrackPerMinPtCutLargePtTrig(0),
228 fhPerpConeNTrackPerMinPtCut(0), fhPerpConeNTrackPerMinPtCutLargePtTrig(0),
229 fhConeSumPtClusterPerMinPtCut(0), fhConeSumPtClusterPerMinPtCutLargePtTrig(0),
230 fhConeSumPtTrackPerMinPtCut(0), fhConeSumPtTrackPerMinPtCutLargePtTrig(0),
231 fhPerpConeSumPtTrackPerMinPtCut(0), fhPerpConeSumPtTrackPerMinPtCutLargePtTrig(0),
232 fhConeSumPtClusterPerMaxPtCut(0), fhConeSumPtClusterPerMaxPtCutLargePtTrig(0),
233 fhConeSumPtTrackPerMaxPtCut(0), fhConeSumPtTrackPerMaxPtCutLargePtTrig(0),
234 fhConeSumPtTrackPerEtaCut(0), fhConeSumPtTrackPerEtaCutLargePtTrig(0),
235 
236 fhPtClusterInConePerNCellCut(0), fhPtClusterInConePerNCellCutLargePtTrig(0),
237 fhPtTrackInConePerNCellCut(0), fhPtTrackInConePerNCellCutLargePtTrig(0),
238 fhConeSumPtClusterPerNCellCut(0), fhConeSumPtClusterPerNCellCutLargePtTrig(0),
239 fhConeSumPtTrackPerNCellCut(0), fhConeSumPtTrackPerNCellCutLargePtTrig(0),
240 fhPtClusterInConePerExoCut(0), fhPtClusterInConePerExoCutLargePtTrig(0),
241 fhPtTrackInConePerExoCut(0), fhPtTrackInConePerExoCutLargePtTrig(0),
242 fhConeSumPtClusterPerExoCut(0), fhConeSumPtClusterPerExoCutLargePtTrig(0),
243 fhConeSumPtTrackPerExoCut(0), fhConeSumPtTrackPerExoCutLargePtTrig(0),
244 
245 fhConeSumPtTrackTOFBC0(0), fhConeSumPtTrackTOFBCN(0), fhConeSumPtTrackTOFNo(0),
246 fhPtTrackInConeTOFBC0 (0), fhPtTrackInConeTOFBCN (0), fhPtTrackInConeTOFNo (0),
247 fhPhiTrackInCone(0), fhEtaTrackInCone(0), fhEtaPhiTrackInCone(0),
248 fhPhiTrackInConeTOFBC0(0), fhPhiTrackInConeTOFBCN(0), fhPhiTrackInConeTOFNo(0),
249 fhEtaTrackInConeTOFBC0(0), fhEtaTrackInConeTOFBCN(0), fhEtaTrackInConeTOFNo(0),
250 fhEtaPhiTrackInConeTOFBC0(0), fhEtaPhiTrackInConeTOFBCN(0), fhEtaPhiTrackInConeTOFNo(0),
251 fhTrackTOFInCone(0), fhTrackTOFInConeBC0(0), fhTrackTOFInConeExoTrigger(0),
252 
253 fhConeSumPtTrackITSRefitOnSPDOn(0), fhConeSumPtTrackITSRefitOnSPDOff(0), fhConeSumPtTrackITSRefitOffSPDOff(0),
254 fhPtTrackInConeITSRefitOnSPDOn(0), fhPtTrackInConeITSRefitOnSPDOff(0) , fhPtTrackInConeITSRefitOffSPDOff(0),
255 fhPhiTrackInConeITSRefitOnSPDOn(0), fhPhiTrackInConeITSRefitOnSPDOff(0), fhPhiTrackInConeITSRefitOffSPDOff(0),
256 fhEtaTrackInConeITSRefitOnSPDOn(0), fhEtaTrackInConeITSRefitOnSPDOff(0), fhEtaTrackInConeITSRefitOffSPDOff(0),
257 fhEtaPhiTrackInConeITSRefitOnSPDOn(0),fhEtaPhiTrackInConeITSRefitOnSPDOff(0), fhEtaPhiTrackInConeITSRefitOffSPDOff(0),
258 fhConeSumPtTrackTOFBC0ITSRefitOnSPDOn(0), fhPtTrackInConeTOFBC0ITSRefitOnSPDOn(0),
259 fhPhiTrackInConeTOFBC0ITSRefitOnSPDOn(0), fhEtaTrackInConeTOFBC0ITSRefitOnSPDOn(0),fhEtaPhiTrackInConeTOFBC0ITSRefitOnSPDOn(0),
260 fhPerpConeSumPtITSRefitOnSPDOn (0), fhPtInPerpConeITSRefitOnSPDOn(0), fhEtaPhiInPerpConeITSRefitOnSPDOn(0),
261 fhPerpConeSumPtTOFBC0ITSRefitOnSPDOn (0), fhPtInPerpConeTOFBC0ITSRefitOnSPDOn (0), fhEtaPhiInPerpConeTOFBC0ITSRefitOnSPDOn(0)
262 {
263  InitParameters();
264 
265  for(Int_t i = 0; i < 5 ; i++)
266  {
267  fConeSizes[i] = 0 ;
268 
269  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
270  fhSumPtLeadingPtMC[imc][i] = 0 ;
271 
272  for(Int_t j = 0; j < 5 ; j++)
273  {
274  fhPtThresIsolated [i][j] = 0 ;
275  fhPtFracIsolated [i][j] = 0 ;
276  fhSumPtIsolated [i][j] = 0 ;
277 
278  fhEtaPhiPtThresIso [i][j] = 0 ;
279  fhEtaPhiPtThresDecayIso [i][j] = 0 ;
280  fhPtPtThresDecayIso [i][j] = 0 ;
281 
282  fhEtaPhiPtFracIso [i][j] = 0 ;
283  fhEtaPhiPtFracDecayIso [i][j] = 0 ;
284  fhPtPtFracDecayIso [i][j] = 0 ;
285  fhPtPtSumDecayIso [i][j] = 0 ;
286  fhPtSumDensityIso [i][j] = 0 ;
287  fhPtSumDensityDecayIso [i][j] = 0 ;
288  fhEtaPhiSumDensityIso [i][j] = 0 ;
289  fhEtaPhiSumDensityDecayIso [i][j] = 0 ;
290  fhPtFracPtSumIso [i][j] = 0 ;
291  fhPtFracPtSumDecayIso [i][j] = 0 ;
292  fhEtaPhiFracPtSumIso [i][j] = 0 ;
293  fhEtaPhiFracPtSumDecayIso [i][j] = 0 ;
294 
295  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
296  {
297  fhPtThresIsolatedMC[imc][i][j] = 0 ;
298  fhPtFracIsolatedMC [imc][i][j] = 0 ;
299  fhSumPtIsolatedMC [imc][i][j] = 0 ;
300 
301  }
302  }
303  }
304 
305  for(Int_t ibit =0; ibit < AliNeutralMesonSelection::fgkMaxNDecayBits; ibit++)
306  {
307  for(Int_t iso =0; iso < 2; iso++)
308  {
309  fhPtDecay [iso][ibit] = 0;
310  fhEtaPhiDecay [iso][ibit] = 0;
311  fhPtLambda0Decay[iso][ibit] = 0;
312  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
313  fhPtDecayMC[iso][ibit][imc] = 0;
314  }
315  }
316 
317  for(Int_t i = 0; i < 5 ; i++)
318  {
319  fPtFractions [i] = 0 ;
320  fPtThresholds [i] = 0 ;
321  fSumPtThresholds[i] = 0 ;
322 
323  fhSumPtLeadingPt [i] = 0 ;
324  fhPtLeadingPt [i] = 0 ;
325  fhPerpSumPtLeadingPt[i] = 0 ;
326  fhPerpPtLeadingPt [i] = 0 ;
327  }
328 
329  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
330  {
331  fhPtNoIsoMC [imc] = 0;
332  fhPtIsoMC [imc] = 0;
333  fhPhiIsoMC [imc] = 0;
334  fhEtaIsoMC [imc] = 0;
335 
336  for(Int_t i = 0; i < 2 ; i++)
337  {
338  fhPtLambda0MC [imc][i] = 0;
339  fhPtLambda0MCConv [imc][i] = 0;
340  fhPtLambda0MCWith1Overlap [imc][i] = 0;
341  fhPtLambda0MCConvWith1Overlap[imc][i] = 0;
342  fhPtLambda0MCWithNoOverlap [imc][i] = 0;
343  fhPtLambda0MCConvWithNoOverlap[imc][i] = 0;
344  fhPtNOverlap [imc][i] = 0;
345  fhPtNOverlapConv [imc][i] = 0;
346  fhTrackMatchedDEtaMC [imc][i] = 0 ;
347  fhTrackMatchedDPhiMC [imc][i] = 0 ;
348  fhTrackMatchedDEtaDPhiMC [imc][i] = 0 ;
349  }
350  }
351 
352  for(Int_t imc = 0; imc < 4; imc++)
353  {
354  fhPtTrackInConeMCPrimary [imc] = 0;
355  fhPtTrackInConeMCSecondary [imc] = 0;
358  }
359 
360  for(Int_t i = 0; i < 2 ; i++)
361  {
363  fhdEdx [i] = 0 ; fhEOverP [i] = 0 ; fhTrackMatchedMCParticle[i] = 0 ;
364  fhELambda0 [i] = 0 ; fhPtLambda0 [i] = 0 ; //fhELambda1 [i] = 0 ;
365  fhELambda0TRD [i] = 0 ; fhPtLambda0TRD [i] = 0 ; //fhELambda1TRD [i] = 0 ;
366 
367  // Number of local maxima in cluster
368  fhNLocMax [i] = 0 ;
369  fhELambda0LocMax1[i] = 0 ; fhELambda1LocMax1[i] = 0 ;
370  fhELambda0LocMax2[i] = 0 ; fhELambda1LocMax2[i] = 0 ;
371  fhELambda0LocMaxN[i] = 0 ; fhELambda1LocMaxN[i] = 0 ;
372 
374  for(Int_t iR = 0; iR < 6; iR++) fhMCConversionLambda0RcutTRD[iR][i] = 0;
375 
376  for(Int_t ieta = 0; ieta < 4; ieta++)
377  {
378  for(Int_t iphi = 0; iphi < 3; iphi++)
379  {
380 // fhLam0EMCALRegion [i][ieta][iphi] = 0;
381 // fhLam0EMCALRegionTRD[i][ieta][iphi] = 0;
382 //
383 // for(Int_t ireg = 0; ireg < 6; ireg++)
384 // {
385 // fhLam0EMCALRegionMCConvRcut [i][ieta][iphi][ireg] = 0;
386 // fhLam0EMCALRegionTRDMCConvRcut[i][ieta][iphi][ireg] = 0;
387 // }
388 
389  for(Int_t ism =0; ism < 20; ism++)
390  {
391  fhLam0EMCALRegionPerSM [i][ieta][iphi][ism] = 0;
392  fhConeSumPtTrackEMCALRegionPerSM [ieta][iphi][ism] = 0;
393  fhConeSumPtClusterEMCALRegionPerSM [ieta][iphi][ism] = 0;
394  }
395  }
396  }
397  for(Int_t j = 0; j < 7; j++) fhEtaPhiLam0BinPtBin[i][j] = 0 ;
398  }
399 
400  // Acceptance
401  for(Int_t i = 0; i < fgkNmcPrimTypes; i++)
402  {
403  fhPtPrimMCiso[i] = 0;
404  fhEPrimMC [i] = 0;
405  fhPtPrimMC [i] = 0;
406  fhEtaPrimMC [i] = 0;
407  fhPhiPrimMC [i] = 0;
408  }
409 
410  // Pile-Up
411 
412  for(Int_t i = 0 ; i < 7 ; i++)
413  {
414  fhPtInConePileUp[i] = 0 ;
415  fhEIsoPileUp [i] = 0 ;
416  fhPtIsoPileUp [i] = 0 ;
417  fhENoIsoPileUp [i] = 0 ;
418  fhPtNoIsoPileUp [i] = 0 ;
419  }
420 
421  for(Int_t i = 0 ; i < 3 ; i++)
422  {
423  fhPtTrackInConeDCA [i] = 0 ;
424  fhPtTrackInPerpConeDCA[i] = 0 ;
425  }
426 }
427 
428 //_______________________________________________________________________________________________
430 //_______________________________________________________________________________________________
431 void AliAnaParticleIsolation::CalculateCaloUEBand(AliAODPWG4ParticleCorrelation * pCandidate,
432  Float_t & etaBandPtSum, Float_t & phiBandPtSum)
433 {
434  if( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kOnlyCharged ) return ;
435 
436  Float_t conesize = GetIsolationCut()->GetConeSize();
437 
438  // Select the Calorimeter
439  TObjArray * pl = 0x0;
440  if (GetCalorimeter() == kPHOS )
441  pl = GetPHOSClusters();
442  else if (GetCalorimeter() == kEMCAL)
443  pl = GetEMCALClusters();
444 
445  if(!pl) return ;
446 
447  // Get vertex for cluster momentum calculation
448  Double_t vertex[] = {0,0,0} ; //vertex ;
449  if(GetReader()->GetDataType() != AliCaloTrackReader::kMC)
450  GetReader()->GetVertex(vertex);
451 
452  Float_t ptTrig = pCandidate->Pt() ;
453  Float_t phiTrig = pCandidate->Phi();
454  Float_t etaTrig = pCandidate->Eta();
455 
456  for(Int_t icluster=0; icluster < pl->GetEntriesFast(); icluster++)
457  {
458  AliVCluster* cluster = (AliVCluster *) pl->At(icluster);
459 
460  if ( !cluster )
461  {
462  AliWarning("Cluster not available?");
463  continue;
464  }
465 
466  // Do not count the candidate (photon or pi0) or the daughters of the candidate
467  if(cluster->GetID() == pCandidate->GetCaloLabel(0) ||
468  cluster->GetID() == pCandidate->GetCaloLabel(1) ) continue ;
469 
470  // Remove matched clusters to tracks if Neutral and Track info is used
472  IsTrackMatched(cluster,GetReader()->GetInputEvent())) continue ;
473 
474  cluster->GetMomentum(fMomentum,vertex) ;//Assume that come from vertex in straight line
475 
476  // Exclude particles in cone
477  Float_t rad = GetIsolationCut()->Radius(etaTrig, phiTrig, fMomentum.Eta(), fMomentum.Phi());
478 
479  // Histograms of eta and phi for all clusters
481  fhEtaPhiCluster->Fill(fMomentum.Eta(), fMomentum.Phi(), GetEventWeight());
482 
483  if(rad < conesize)
484  {
485  // Histograms for all clusters in cone
488 
489  continue ;
490  }
491 
492  // Fill histogram for UE in phi band in EMCal acceptance
493  if(fMomentum.Eta() > (etaTrig-conesize) && fMomentum.Eta() < (etaTrig+conesize))
494  {
495  phiBandPtSum+=fMomentum.Pt();
498  fhPhiBandClusterPt ->Fill(ptTrig, fMomentum.Pt (), GetEventWeight());
499  }
500 
501  // Fill histogram for UE in eta band in EMCal acceptance
502  if(fMomentum.Phi() > (phiTrig-conesize) && fMomentum.Phi() < (phiTrig+conesize))
503  {
504  etaBandPtSum+=fMomentum.Pt();
507  fhEtaBandClusterPt ->Fill(ptTrig, fMomentum.Pt(), GetEventWeight());
508  }
509  }
510 
511  fhConeSumPtEtaBandUECluster->Fill(ptTrig, etaBandPtSum, GetEventWeight());
512  fhConeSumPtPhiBandUECluster->Fill(ptTrig, phiBandPtSum, GetEventWeight());
513 
515  {
516  fhConeSumPtEtaBandUEClusterTrigEtaPhi->Fill(etaTrig, phiTrig, etaBandPtSum *GetEventWeight()); // Check
517  fhConeSumPtPhiBandUEClusterTrigEtaPhi->Fill(etaTrig, phiTrig, phiBandPtSum *GetEventWeight()); // Check
518  }
519 }
520 
521 //________________________________________________________________________________________________
523 //________________________________________________________________________________________________
524 void AliAnaParticleIsolation::CalculateCaloCellUEBand(AliAODPWG4ParticleCorrelation * pCandidate,
525  Float_t & etaBandPtSumCells, Float_t & phiBandPtSumCells)
526 {
527  if( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kOnlyCharged ) return ;
528 
529  Float_t conesize = GetIsolationCut()->GetConeSize();
530 
531  Float_t phiTrig = pCandidate->Phi();
532  if(phiTrig<0) phiTrig += TMath::TwoPi();
533 
534  Float_t etaTrig = pCandidate->Eta();
535 
536  if(pCandidate->GetDetectorTag()==kEMCAL)
537  {
538  AliEMCALGeometry* eGeom = AliEMCALGeometry::GetInstance();
539  Int_t absId = -999;
540 
541  if (eGeom->GetAbsCellIdFromEtaPhi(etaTrig,phiTrig,absId))
542  {
543  if(!eGeom->CheckAbsCellId(absId)) return ;
544 
545  // Get absolute (col,row) of trigger particle
546  Int_t nSupMod = eGeom->GetSuperModuleNumber(absId);
547  Int_t nModule = -1;
548  Int_t imEta=-1, imPhi=-1;
549  Int_t ieta =-1, iphi =-1;
550 
551  if (eGeom->GetCellIndex(absId,nSupMod,nModule,imPhi,imEta))
552  {
553  eGeom->GetCellPhiEtaIndexInSModule(nSupMod,nModule,imPhi,imEta,iphi,ieta);
554 
555  Int_t colTrig = ieta;
556  if (nSupMod % 2) colTrig = AliEMCALGeoParams::fgkEMCALCols + ieta ;
557 
558  Int_t rowTrig = iphi + AliEMCALGeoParams::fgkEMCALRows*int(nSupMod/2);
559 
560  Int_t sqrSize = int(conesize/0.0143);
561 
562  AliVCaloCells * cells = GetEMCALCells();
563 
564  Int_t nTotalRows = AliEMCALGeoParams::fgkEMCALRows*16/3 ; // 24*(16/3) 5 full-size Sectors (2 SM) + 1 one-third Sector (2 SM)
565  Int_t nTotalCols = 2*AliEMCALGeoParams::fgkEMCALCols;
566  // printf("nTotalRows %i, nTotalCols %i\n",nTotalRows,nTotalCols);
567  // Loop on cells in eta band
568 
569  Int_t irowmin = rowTrig-sqrSize;
570  if ( irowmin < 0 ) irowmin = 0 ;
571 
572  Int_t irowmax = rowTrig+sqrSize;
573  if ( irowmax > AliEMCALGeoParams::fgkEMCALRows ) irowmax = AliEMCALGeoParams::fgkEMCALRows;
574 
575  for(Int_t irow = irowmin; irow <irowmax; irow++)
576  {
577  for(Int_t icol = 0; icol < nTotalCols; icol++)
578  {
579  Int_t inSector = int(irow/AliEMCALGeoParams::fgkEMCALRows);
580  if(inSector==5) continue;
581  Int_t inSupMod = -1;
582  Int_t icolLoc = -1;
583  if(icol < AliEMCALGeoParams::fgkEMCALCols)
584  {
585  inSupMod = 2*inSector + 1;
586  icolLoc = icol;
587  }
588  else if(icol > AliEMCALGeoParams::fgkEMCALCols - 1)
589  {
590  inSupMod = 2*inSector;
591  icolLoc = icol-AliEMCALGeoParams::fgkEMCALCols;
592  }
593 
594  Int_t irowLoc = irow - AliEMCALGeoParams::fgkEMCALRows*inSector ;
595 
596  // Exclude cells in cone
597  if(TMath::Abs(icol-colTrig) < sqrSize || TMath::Abs(irow-rowTrig) < sqrSize){
598  continue ;
599  }
600 
601  Int_t iabsId = eGeom->GetAbsCellIdFromCellIndexes(inSupMod,irowLoc,icolLoc);
602  if(!eGeom->CheckAbsCellId(iabsId)) continue;
603 
604  etaBandPtSumCells += cells->GetCellAmplitude(iabsId);
605 
606  fhEtaBandCell->Fill(colTrig, rowTrig, GetEventWeight());
607 
608  // printf("ETA inSupMod %i,irowLoc %i,icolLoc %i, iabsId %i, etaBandPtSumCells %f\n",nSupMod,irowLoc,icolLoc,iabsId,etaBandPtSumCells);
609  }
610  }
611 
612  Int_t icolmin = colTrig-sqrSize;
613  if ( icolmin < 0 ) icolmin = 0;
614 
615  Int_t icolmax = colTrig+sqrSize;
616  if ( icolmax > AliEMCALGeoParams::fgkEMCALCols ) icolmax = AliEMCALGeoParams::fgkEMCALCols;
617 
618  // Loop on cells in phi band
619  for(Int_t icol = icolmin; icol < icolmax; icol++)
620  {
621  for(Int_t irow = 0; irow < nTotalRows; irow++)
622  {
623  Int_t inSector = int(irow/AliEMCALGeoParams::fgkEMCALRows);
624  if ( inSector == 5 ) continue ;
625 
626  Int_t inSupMod = -1;
627  Int_t icolLoc = -1;
628  // printf("icol %i, irow %i, inSector %i\n",icol,irow ,inSector);
629 
630  if(icol < AliEMCALGeoParams::fgkEMCALCols)
631  {
632  // printf("icol < AliEMCALGeoParams::fgkEMCALCols %i\n",AliEMCALGeoParams::fgkEMCALCols );
633  inSupMod = 2*inSector + 1;
634  icolLoc = icol;
635  }
636  else if(icol > AliEMCALGeoParams::fgkEMCALCols - 1)
637  {
638  // printf("icol > AliEMCALGeoParams::fgkEMCALCols -1 %i\n",AliEMCALGeoParams::fgkEMCALCols -1 );
639  inSupMod = 2*inSector;
640  icolLoc = icol-AliEMCALGeoParams::fgkEMCALCols;
641  }
642 
643  Int_t irowLoc = irow - AliEMCALGeoParams::fgkEMCALRows*inSector ; // Stesso problema di sopra //
644 
645  // Exclude cells in cone
646  if(TMath::Abs(icol-colTrig) < sqrSize) {
647  //printf("TMath::Abs(icol-colTrig) %i < sqrSize %i\n",TMath::Abs(icol-colTrig) ,sqrSize);continue ;
648  }
649  if(TMath::Abs(irow-rowTrig) < sqrSize) {
650  //printf("TMath::Abs(irow-rowTrig) %i < sqrSize %i\n",TMath::Abs(irow-rowTrig) ,sqrSize);continue ;
651  }
652 
653  Int_t iabsId = eGeom->GetAbsCellIdFromCellIndexes(inSupMod,irowLoc,icolLoc);
654  if(!eGeom->CheckAbsCellId(iabsId))
655  {
656  AliWarning(Form("!eGeom->CheckAbsCellId(iabsId=%i) inSupMod %i irowLoc %i icolLoc %i",iabsId,inSupMod, irowLoc, icolLoc));
657  continue;
658  }
659 
660  phiBandPtSumCells += cells->GetCellAmplitude(iabsId);
661 
662  fhPhiBandCell->Fill(colTrig, rowTrig, GetEventWeight());
663  //printf("inSupMod %i,irowLoc %i,icolLoc %i, iabsId %i, phiBandPtSumCells %f\n",nSupMod,irowLoc,icolLoc,iabsId,phiBandPtSumCells);
664  }
665  }
666  }
667  }
668  }
669 
670  Float_t ptTrig = pCandidate->Pt();
671 
672  fhConeSumPtEtaBandUECell ->Fill(ptTrig , etaBandPtSumCells, GetEventWeight());
673  fhConeSumPtPhiBandUECell ->Fill(ptTrig , phiBandPtSumCells, GetEventWeight());
674  fhConeSumPtEtaBandUECellTrigEtaPhi->Fill(etaTrig, phiTrig, etaBandPtSumCells *GetEventWeight()); // Check
675  fhConeSumPtPhiBandUECellTrigEtaPhi->Fill(etaTrig, phiTrig, phiBandPtSumCells *GetEventWeight()); // Check
676 }
677 
678 //________________________________________________________________________________________________
680 //________________________________________________________________________________________________
681 void AliAnaParticleIsolation::CalculateTrackUEBand(AliAODPWG4ParticleCorrelation * pCandidate,
682  Float_t & etaBandPtSum, Float_t & phiBandPtSum)
683 {
684  if( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kOnlyNeutral ) return ;
685 
686  Float_t conesize = GetIsolationCut()->GetConeSize();
687 
688  Double_t sumptPerp = 0. ;
689  Double_t sumptPerpBC0 = 0. ;
690  Double_t sumptPerpITSSPD = 0. ;
691  Double_t sumptPerpBC0ITSSPD = 0.;
692 
693  Float_t coneptsumPerpTrackPerMinCut[20];
694  Float_t coneNPerpTrackPerMinCut [20];
695 
697  {
698  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
699  {
700  coneptsumPerpTrackPerMinCut[icut] = 0;
701  coneNPerpTrackPerMinCut [icut] = 0;
702  }
703  }
704 
705  Float_t ptTrig = pCandidate->Pt() ;
706  Float_t phiTrig = pCandidate->Phi();
707  Float_t etaTrig = pCandidate->Eta();
708 
709  Double_t bz = GetReader()->GetInputEvent()->GetMagneticField();
710 
711  TObjArray * trackList = GetCTSTracks() ;
712  for(Int_t itrack=0; itrack < trackList->GetEntriesFast(); itrack++)
713  {
714  AliVTrack* track = (AliVTrack *) trackList->At(itrack);
715 
716  if(!track)
717  {
718  AliWarning("Track not available?");
719  continue;
720  }
721 
722  // In case of isolation of single tracks or conversion photon (2 tracks) or pi0 (4 tracks),
723  // do not count the candidate or the daughters of the candidate
724  // in the isolation conte
725  if ( pCandidate->GetDetectorTag() == kCTS ) // make sure conversions are tagged as kCTS!!!
726  {
727  Int_t trackID = GetReader()->GetTrackID(track) ; // needed instead of track->GetID() since AOD needs some manipulations
728  Bool_t contained = kFALSE;
729 
730  for(Int_t i = 0; i < 4; i++)
731  {
732  if( trackID == pCandidate->GetTrackLabel(i) ) contained = kTRUE;
733  }
734 
735  if ( contained ) continue ;
736  }
737 
738  // Histogram of eta:phi for all tracks
740  fhEtaPhiTrack->Fill(track->Eta(), track->Phi(), GetEventWeight());
741 
742  //exclude particles in cone
743  Float_t rad = GetIsolationCut()->Radius(etaTrig, phiTrig, track->Eta(), track->Phi());
744  if(rad < conesize)
745  {
746  // Histogram of eta:phi for all tracks in cone
748  fhEtaPhiInConeTrack->Fill(track->Eta(), track->Phi(), GetEventWeight());
749  continue ;
750  }
751 
752  // Fill histogram for UE in phi band
753  if(track->Eta() > (etaTrig-conesize) && track->Eta() < (etaTrig+conesize))
754  {
755  phiBandPtSum+=track->Pt();
757  fhPhiBandTrackEtaPhi->Fill(track->Eta(), track->Phi(), GetEventWeight());
758  fhPhiBandTrackPt->Fill(ptTrig , track->Pt (), GetEventWeight());
759  }
760 
761  // Fill histogram for UE in eta band in EMCal acceptance
762  if(track->Phi() > (phiTrig-conesize) && track->Phi() < (phiTrig+conesize))
763  {
764  etaBandPtSum+=track->Pt();
766  fhEtaBandTrackEtaPhi->Fill(track->Eta(), track->Phi(), GetEventWeight());
767  fhEtaBandTrackPt ->Fill(ptTrig , track->Pt (), GetEventWeight());
768  }
769 
770  // Fill the histograms at +-45 degrees in phi from trigger particle, perpedicular to trigger axis in phi
771  //++++++++
772  Double_t dPhi = phiTrig - track->Phi() + TMath::PiOver2();
773  Double_t dEta = etaTrig - track->Eta();
774  Double_t arg = dPhi*dPhi + dEta*dEta;
775 
776  if(TMath::Sqrt(arg) < conesize)
777  {
778  sumptPerp+=track->Pt();
779 
780  fhPtInPerpCone->Fill(ptTrig, track->Pt(), GetEventWeight());
781 
783  {
784  fhEtaPhiInPerpCone->Fill(track->Eta(),track->Phi(), GetEventWeight());
785 
786  ULong_t status = track->GetStatus();
787  Bool_t okTOF = (status & AliVTrack::kTOFout) == AliVTrack::kTOFout ;
788  Int_t trackBC = track->GetTOFBunchCrossing(bz);
789  //Double32_t tof = track->GetTOFsignal()*1e-3;
790 
791  if(okTOF && trackBC == 0)
792  {
793  fhPtInPerpConeTOFBC0->Fill(ptTrig, track->Pt(), GetEventWeight());
794  fhEtaPhiInPerpConeTOFBC0->Fill(track->Eta(),track->Phi(), GetEventWeight());
795 
796  sumptPerpBC0+=track->Pt();
797  }
798 
799  Bool_t bConstrained = (!track->HasPointOnITSLayer(0) && !track->HasPointOnITSLayer(1));
800  //Bool_t bITSRefit = (status & AliVTrack::kITSrefit) == AliVTrack::kITSrefit;
801  if(!bConstrained)
802  {
803  fhPtInPerpConeITSRefitOnSPDOn->Fill(ptTrig, track->Pt(), GetEventWeight());
804  fhEtaPhiInPerpConeITSRefitOnSPDOn->Fill(track->Eta(),track->Phi(), GetEventWeight());
805 
806  sumptPerpITSSPD+=track->Pt();
807  }
808 
809  if(okTOF && trackBC == 0 && !bConstrained)
810  {
811  fhPtInPerpConeTOFBC0ITSRefitOnSPDOn->Fill(ptTrig, track->Pt(), GetEventWeight());
812  fhEtaPhiInPerpConeTOFBC0ITSRefitOnSPDOn->Fill(track->Eta(),track->Phi(), GetEventWeight());
813 
814  sumptPerpBC0ITSSPD+=track->Pt();
815  }
816  }
817  }
818 
819  //----------
820  dPhi = phiTrig - track->Phi() - TMath::PiOver2();
821  arg = dPhi*dPhi + dEta*dEta;
822 
823  if(TMath::Sqrt(arg) < conesize)
824  {
825  sumptPerp+=track->Pt();
826 
828  {
829  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
830  {
831  if ( track->Pt() > fMinPtCutInCone[icut] )
832  {
833  coneptsumPerpTrackPerMinCut[icut]+=track->Pt();
834  coneNPerpTrackPerMinCut [icut]++;
835  }
836  }
837  }
838 
839  fhPtInPerpCone->Fill(ptTrig, track->Pt(), GetEventWeight());
840 
842  {
843  fhEtaPhiInPerpCone->Fill(track->Eta(),track->Phi(), GetEventWeight());
844 
845  ULong_t status = track->GetStatus();
846  Bool_t okTOF = (status & AliVTrack::kTOFout) == AliVTrack::kTOFout ;
847  Int_t trackBC = track->GetTOFBunchCrossing(bz);
848  //Double32_t tof = track->GetTOFsignal()*1e-3;
849 
850  if(okTOF && trackBC == 0)
851  {
852  fhPtInPerpConeTOFBC0->Fill(ptTrig, track->Pt(), GetEventWeight());
853  fhEtaPhiInPerpConeTOFBC0->Fill(track->Eta(),track->Phi(), GetEventWeight());
854 
855  sumptPerpBC0+=track->Pt();
856  }
857 
858  Bool_t bConstrained = (!track->HasPointOnITSLayer(0) && !track->HasPointOnITSLayer(1));
859  //Bool_t bITSRefit = (status & AliVTrack::kITSrefit) == AliVTrack::kITSrefit;
860  if(!bConstrained)
861  {
862  fhPtInPerpConeITSRefitOnSPDOn->Fill(ptTrig, track->Pt(), GetEventWeight());
863  fhEtaPhiInPerpConeITSRefitOnSPDOn->Fill(track->Eta(),track->Phi(), GetEventWeight());
864 
865  sumptPerpITSSPD+=track->Pt();
866  }
867 
868  if(okTOF && trackBC == 0 && !bConstrained)
869  {
870  fhPtInPerpConeTOFBC0ITSRefitOnSPDOn->Fill(ptTrig, track->Pt(), GetEventWeight());
871  fhEtaPhiInPerpConeTOFBC0ITSRefitOnSPDOn->Fill(track->Eta(),track->Phi(), GetEventWeight());
872 
873  sumptPerpBC0ITSSPD+=track->Pt();
874  }
875 
876  if(ptTrig > 10)
877  {
878  Double_t dca[2] = {1e6,1e6};
879  Double_t covar[3] = {1e6,1e6,1e6};
880 
881  Double_t dcaCons = -999;
882  if ( GetReader()->GetDataType() == AliCaloTrackReader::kAOD )
883  {
884  AliAODTrack * aodTrack = dynamic_cast<AliAODTrack*>(track);
885  dcaCons = aodTrack->DCA();
886  }
887 
888  track->PropagateToDCA(GetReader()->GetInputEvent()->GetPrimaryVertex(),bz,100.,dca,covar);
889 
890  if(dcaCons == -999)
891  {
892  fhPtTrackInPerpConeDCA[0]->Fill(track->Pt(), dca[0], GetEventWeight());
893  fhPtTrackInPerpConeDCA[1]->Fill(track->Pt(), dca[1], GetEventWeight());
894  }
895  else
896  {
897  fhPtTrackInPerpConeDCA[2]->Fill(track->Pt(), dcaCons, GetEventWeight());
898  }
899  } // trigger pt cut for DCA
900 
901  } // study tracks in cone
902  } // r in cone
903  } // track loop
904 
905  fhPerpConeSumPt ->Fill(ptTrig, sumptPerp , GetEventWeight());
906  fhConeSumPtEtaBandUETrack ->Fill(ptTrig, etaBandPtSum, GetEventWeight());
907  fhConeSumPtPhiBandUETrack ->Fill(ptTrig, phiBandPtSum, GetEventWeight());
908 
910  {
911  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
912  {
913  fhPerpConeSumPtTrackPerMinPtCut->Fill(icut+1, coneptsumPerpTrackPerMinCut[icut], GetEventWeight());
914  fhPerpConeNTrackPerMinPtCut ->Fill(icut+1, coneNPerpTrackPerMinCut [icut], GetEventWeight());
915 
916  if ( ptTrig > 10 )
917  {
918  fhPerpConeSumPtTrackPerMinPtCutLargePtTrig->Fill(icut+1, coneptsumPerpTrackPerMinCut[icut], GetEventWeight());
919  fhPerpConeNTrackPerMinPtCutLargePtTrig ->Fill(icut+1, coneNPerpTrackPerMinCut [icut], GetEventWeight());
920  }
921  }
922  }
923 
924 
926  {
927  fhConeSumPtEtaBandUETrackTrigEtaPhi->Fill(etaTrig, phiTrig, etaBandPtSum *GetEventWeight()); // check
928  fhConeSumPtPhiBandUETrackTrigEtaPhi->Fill(etaTrig, phiTrig, phiBandPtSum *GetEventWeight()); // check
929  }
930 
931  if(fStudyTracksInCone)
932  {
933  fhPerpConeSumPtTOFBC0 ->Fill(ptTrig, sumptPerpBC0 , GetEventWeight());
934  fhPerpConeSumPtITSRefitOnSPDOn->Fill(ptTrig, sumptPerpITSSPD, GetEventWeight());
935  fhPerpConeSumPtTOFBC0ITSRefitOnSPDOn->Fill(ptTrig, sumptPerpBC0ITSSPD, GetEventWeight());
936  }
937 
938 }
939 
940 //_____________________________________________________________________________________________________________________________________
942 //_____________________________________________________________________________________________________________________________________
943 void AliAnaParticleIsolation::CalculateNormalizeUEBandPerUnitArea(AliAODPWG4ParticleCorrelation * pCandidate, Float_t coneptsumCluster,
944  Float_t coneptsumCell, Float_t coneptsumTrack,
945  Float_t &sumEtaUESub , Float_t &sumPhiUESub)
946 {
947  Float_t etaUEptsumTrack = 0 ;
948  Float_t phiUEptsumTrack = 0 ;
949  Float_t etaUEptsumCluster = 0 ;
950  Float_t phiUEptsumCluster = 0 ;
951  Float_t etaUEptsumCell = 0 ;
952  Float_t phiUEptsumCell = 0 ;
953 
954  Int_t partTypeInCone = GetIsolationCut()->GetParticleTypeInCone();
955 
956  // Do the normalization
957 
958  Float_t conesize = GetIsolationCut()->GetConeSize();
959  Float_t coneA = conesize*conesize*TMath::Pi(); // A = pi R^2, isolation cone area
960  Float_t ptTrig = pCandidate->Pt() ;
961  Float_t phiTrig = pCandidate->Phi();
962  Float_t etaTrig = pCandidate->Eta();
963 
964 
965  // ------ //
966  // Tracks //
967  // ------ //
968  Float_t phiUEptsumTrackNorm = 0 ;
969  Float_t etaUEptsumTrackNorm = 0 ;
970  Float_t coneptsumTrackSubPhi = 0 ;
971  Float_t coneptsumTrackSubEta = 0 ;
972  Float_t coneptsumTrackSubPhiNorm = 0 ;
973  Float_t coneptsumTrackSubEtaNorm = 0 ;
974 
975  if ( partTypeInCone != AliIsolationCut::kOnlyNeutral )
976  {
977  // Sum the pT in the phi or eta band for clusters or tracks
978  CalculateTrackUEBand (pCandidate,etaUEptsumTrack ,phiUEptsumTrack );// rajouter ici l'histo eta phi
979 
980  // Fill histograms
982  {
983  fhConeSumPtVSUETracksEtaBand->Fill(coneptsumTrack, etaUEptsumTrack, GetEventWeight());
984  fhConeSumPtVSUETracksPhiBand->Fill(coneptsumTrack, phiUEptsumTrack, GetEventWeight());
985  }
986 
987  Float_t correctConeSumTrack = 1;
988  Float_t correctConeSumTrackPhi = 1;
989 
991  phiUEptsumTrack,etaUEptsumTrack,
992  phiUEptsumTrackNorm,etaUEptsumTrackNorm,
993  correctConeSumTrack,correctConeSumTrackPhi);
994 
995  coneptsumTrackSubPhi = coneptsumTrack - phiUEptsumTrackNorm;
996  coneptsumTrackSubEta = coneptsumTrack - etaUEptsumTrackNorm;
997 
998  fhConeSumPtPhiUESubTrack ->Fill(ptTrig, coneptsumTrackSubPhi, GetEventWeight());
999  fhConeSumPtEtaUESubTrack ->Fill(ptTrig, coneptsumTrackSubEta, GetEventWeight());
1000 
1001  fhConeSumPtPhiUENormTrack ->Fill(ptTrig, phiUEptsumTrackNorm , GetEventWeight());
1002  fhConeSumPtEtaUENormTrack ->Fill(ptTrig, etaUEptsumTrackNorm , GetEventWeight());
1003 
1004  if(coneptsumTrack > 0)
1005  {
1006  coneptsumTrackSubPhiNorm = coneptsumTrackSubPhi/coneptsumTrack;
1007  coneptsumTrackSubEtaNorm = coneptsumTrackSubEta/coneptsumTrack;
1008  }
1009 
1011  {
1012  fhConeSumPtPhiUESubTrackTrigEtaPhi ->Fill(etaTrig, phiTrig, coneptsumTrackSubPhi *GetEventWeight()); // check
1013  fhConeSumPtEtaUESubTrackTrigEtaPhi ->Fill(etaTrig, phiTrig, coneptsumTrackSubEta *GetEventWeight()); // check
1014 
1015  fhFractionTrackOutConeEta ->Fill(ptTrig , correctConeSumTrack-1, GetEventWeight());
1016  fhFractionTrackOutConeEtaTrigEtaPhi->Fill(etaTrig, phiTrig,correctConeSumTrack-1 *GetEventWeight()); // check
1017 
1018  fhConeSumPtSubvsConeSumPtTotPhiTrack ->Fill(coneptsumTrack, coneptsumTrackSubPhi , GetEventWeight());
1019  fhConeSumPtSubNormvsConeSumPtTotPhiTrack->Fill(coneptsumTrack, coneptsumTrackSubPhiNorm, GetEventWeight());
1020  fhConeSumPtSubvsConeSumPtTotEtaTrack ->Fill(coneptsumTrack, coneptsumTrackSubEta , GetEventWeight());
1021  fhConeSumPtSubNormvsConeSumPtTotEtaTrack->Fill(coneptsumTrack, coneptsumTrackSubEtaNorm, GetEventWeight());
1022  }
1023  }
1024 
1025  // ------------------------ //
1026  // EMCal Clusters and cells //
1027  // ------------------------ //
1028  Float_t phiUEptsumClusterNorm = 0 ;
1029  Float_t etaUEptsumClusterNorm = 0 ;
1030  Float_t coneptsumClusterSubPhi = 0 ;
1031  Float_t coneptsumClusterSubEta = 0 ;
1032  Float_t coneptsumClusterSubPhiNorm = 0 ;
1033  Float_t coneptsumClusterSubEtaNorm = 0 ;
1034  Float_t phiUEptsumCellNorm = 0 ;
1035  Float_t etaUEptsumCellNorm = 0 ;
1036  Float_t coneptsumCellSubPhi = 0 ;
1037  Float_t coneptsumCellSubEta = 0 ;
1038  Float_t coneptsumCellSubPhiNorm = 0 ;
1039  Float_t coneptsumCellSubEtaNorm = 0 ;
1040 
1041  if ( partTypeInCone != AliIsolationCut::kOnlyCharged )
1042  {
1043  // -------------- //
1044  // EMCal clusters //
1045  // -------------- //
1046 
1047  // Sum the pT in the phi or eta band for clusters or tracks
1048  CalculateCaloUEBand (pCandidate,etaUEptsumCluster,phiUEptsumCluster);// rajouter ici l'histo eta phi
1049 
1050  // Fill histograms
1052  {
1053  fhConeSumPtVSUEClusterEtaBand->Fill(coneptsumCluster, etaUEptsumCluster, GetEventWeight());
1054  fhConeSumPtVSUEClusterPhiBand->Fill(coneptsumCluster, phiUEptsumCluster, GetEventWeight());
1055  }
1056 
1057  Float_t correctConeSumClusterEta = 1;
1058  Float_t correctConeSumClusterPhi = 1;
1059 
1061  phiUEptsumCluster,etaUEptsumCluster,
1062  phiUEptsumClusterNorm,etaUEptsumClusterNorm,
1063  correctConeSumClusterEta,correctConeSumClusterPhi);
1064 
1065  // In case that cone is out of eta and phi side, we are over correcting, not too often with the current cuts ...
1066  // Comment if not used
1067  // Float_t coneBadCellsCoeff =1;
1068  // Float_t etaBandBadCellsCoeff=1;
1069  // Float_t phiBandBadCellsCoeff=1;
1070  // GetIsolationCut()->GetCoeffNormBadCell(pCandidate, GetReader(),coneBadCellsCoeff,etaBandBadCellsCoeff,phiBandBadCellsCoeff) ;
1071 
1072  //coneptsumCluster=coneptsumCluster*coneBadCellsCoeff*correctConeSumClusterEta*correctConeSumClusterPhi;
1073 
1074  coneptsumClusterSubPhi = coneptsumCluster - phiUEptsumClusterNorm;
1075  coneptsumClusterSubEta = coneptsumCluster - etaUEptsumClusterNorm;
1076 
1077  fhConeSumPtPhiUENormCluster ->Fill(ptTrig , phiUEptsumClusterNorm , GetEventWeight());
1078  fhConeSumPtPhiUESubCluster ->Fill(ptTrig , coneptsumClusterSubPhi, GetEventWeight());
1079  fhConeSumPtEtaUENormCluster ->Fill(ptTrig , etaUEptsumClusterNorm , GetEventWeight());
1080  fhConeSumPtEtaUESubCluster ->Fill(ptTrig , coneptsumClusterSubEta, GetEventWeight());
1081 
1082  if(coneptsumCluster!=0)
1083  {
1084  coneptsumClusterSubPhiNorm = coneptsumClusterSubPhi/coneptsumCluster;
1085  coneptsumClusterSubEtaNorm = coneptsumClusterSubEta/coneptsumCluster;
1086  }
1087 
1089  {
1090  fhConeSumPtPhiUESubClusterTrigEtaPhi ->Fill(etaTrig, phiTrig, coneptsumClusterSubPhi *GetEventWeight()); // check
1091  fhConeSumPtEtaUESubClusterTrigEtaPhi ->Fill(etaTrig, phiTrig, coneptsumClusterSubEta *GetEventWeight()); // check
1092 
1093  fhFractionClusterOutConeEta ->Fill(ptTrig , correctConeSumClusterEta-1, GetEventWeight());
1094  fhFractionClusterOutConeEtaTrigEtaPhi->Fill(etaTrig, phiTrig, correctConeSumClusterEta-1 *GetEventWeight()); // check
1095  fhFractionClusterOutConePhi ->Fill(ptTrig , correctConeSumClusterPhi-1, GetEventWeight());
1096  fhFractionClusterOutConePhiTrigEtaPhi->Fill(etaTrig, phiTrig, correctConeSumClusterPhi-1 *GetEventWeight()); // check
1097 
1098  fhConeSumPtSubvsConeSumPtTotPhiCluster ->Fill(coneptsumCluster,coneptsumClusterSubPhi , GetEventWeight());
1099  fhConeSumPtSubNormvsConeSumPtTotPhiCluster->Fill(coneptsumCluster,coneptsumClusterSubPhiNorm, GetEventWeight());
1100  fhConeSumPtSubvsConeSumPtTotEtaCluster ->Fill(coneptsumCluster,coneptsumClusterSubEta , GetEventWeight());
1101  fhConeSumPtSubNormvsConeSumPtTotEtaCluster->Fill(coneptsumCluster,coneptsumClusterSubEtaNorm, GetEventWeight());
1102  }
1103 
1104  // ----------- //
1105  // EMCal Cells //
1106  // ----------- //
1107 
1108  if ( fFillCellHistograms )
1109  {
1110  // Sum the pT in the phi or eta band for clusters or tracks
1111  CalculateCaloCellUEBand(pCandidate,etaUEptsumCell ,phiUEptsumCell );
1112 
1113  // Move to AliIsolationCut the calculation not the histograms??
1114 
1115  //Careful here if EMCal limits changed .. 2010 (4 SM) to 2011-12 (10 SM), for the moment consider 100 deg in phi
1116  Float_t emcEtaSize = 0.7*2; // TO FIX
1117  Float_t emcPhiSize = TMath::DegToRad()*100.; // TO FIX
1118 
1119  if(((2*conesize*emcPhiSize)-coneA)!=0)phiUEptsumCellNorm = phiUEptsumCell*(coneA / ((2*conesize*emcPhiSize)-coneA));
1120  if(((2*conesize*emcEtaSize)-coneA)!=0)etaUEptsumCellNorm = etaUEptsumCell*(coneA / ((2*conesize*emcEtaSize)-coneA));
1121 
1122  // Need to correct coneptsumCluster by the fraction of the cone out of the calorimeter cut acceptance!
1123 
1124  Float_t correctConeSumCellEta = 1;
1125  if(TMath::Abs(etaTrig)+conesize > emcEtaSize/2.)
1126  {
1127  Float_t excess = TMath::Abs(etaTrig) + conesize - emcEtaSize/2.;
1128  correctConeSumCellEta = GetIsolationCut()->CalculateExcessAreaFraction(excess);
1129  //printf("Excess EMC-Eta %2.3f, coneA %2.2f, excessA %2.2f, angle %2.2f,factor %2.2f\n",excess,coneA, excessA, angle*TMath::RadToDeg(), correctConeSumClusterEta);
1130  // Need to correct phi band surface if part of the cone falls out of track cut acceptance!
1131  if(((2*(conesize-excess)*emcPhiSize)-(coneA-correctConeSumCellEta))!=0)phiUEptsumCellNorm = phiUEptsumCell*(coneA / ((2*(conesize-excess)*emcPhiSize)-(coneA-correctConeSumCellEta)));
1132  }
1133 
1134  Float_t correctConeSumCellPhi = 1;
1135  //printf("EMCPhiTrig %2.2f, conesize %2.2f, sum %2.2f, rest %2.2f \n",phiTrig*TMath::RadToDeg(),conesize*TMath::RadToDeg(),(phiTrig+conesize)*TMath::RadToDeg(),(phiTrig-conesize)*TMath::RadToDeg() );
1136  if((phiTrig+conesize > 180*TMath::DegToRad()) ||
1137  (phiTrig-conesize < 80*TMath::DegToRad()))
1138  {
1139  Float_t excess = 0;
1140  if( phiTrig+conesize > 180*TMath::DegToRad() ) excess = conesize + phiTrig - 180*TMath::DegToRad() ;
1141  else excess = conesize - phiTrig + 80*TMath::DegToRad() ;
1142 
1143  correctConeSumCellPhi = GetIsolationCut()->CalculateExcessAreaFraction(excess);
1144  //printf("Excess EMC-Phi %2.3f, coneA %2.2f, excessA %2.2f, angle %2.2f,factor %2.2f\n",excess,coneA, excessA, angle*TMath::RadToDeg(), correctConeSumClusterPhi);
1145 
1146  // Need to correct eta band surface if part of the cone falls out of track cut acceptance!
1147  if(((2*(conesize-excess)*emcEtaSize)-(coneA-correctConeSumCellPhi))!=0)etaUEptsumCellNorm = etaUEptsumCell*(coneA / ((2*(conesize-excess)*emcEtaSize)-(coneA-correctConeSumCellPhi)));
1148  }
1149 
1150  // In case that cone is out of eta and phi side, we are over correcting, not too often with the current cuts ...
1151  coneptsumCellSubPhi = coneptsumCell*correctConeSumCellEta*correctConeSumCellPhi - phiUEptsumCellNorm;
1152  coneptsumCellSubEta = coneptsumCell*correctConeSumCellEta*correctConeSumCellPhi - etaUEptsumCellNorm;
1153 
1154  fhConeSumPtPhiUESubCell ->Fill(ptTrig , coneptsumCellSubPhi, GetEventWeight());
1155  fhConeSumPtPhiUESubCellTrigEtaPhi ->Fill(etaTrig, phiTrig, coneptsumCellSubPhi *GetEventWeight()); // check
1156  fhConeSumPtEtaUESubCell ->Fill(ptTrig , coneptsumCellSubEta, GetEventWeight());
1157  fhConeSumPtEtaUESubCellTrigEtaPhi ->Fill(etaTrig, phiTrig, coneptsumCellSubEta *GetEventWeight()); // check
1158 
1159  fhFractionCellOutConeEta ->Fill(ptTrig , correctConeSumCellEta-1, GetEventWeight());
1160  fhFractionCellOutConeEtaTrigEtaPhi->Fill(etaTrig, phiTrig, correctConeSumCellEta-1 *GetEventWeight()); // check
1161  fhFractionCellOutConePhi ->Fill(ptTrig , correctConeSumCellPhi-1, GetEventWeight());
1162  fhFractionCellOutConePhiTrigEtaPhi->Fill(etaTrig, phiTrig, correctConeSumCellPhi-1 *GetEventWeight()); // check
1163  if ( coneptsumCell > 0.01 )
1164  {
1165  coneptsumCellSubPhiNorm = coneptsumCellSubPhi/coneptsumCell;
1166  coneptsumCellSubEtaNorm = coneptsumCellSubEta/coneptsumCell;
1167  }
1168 
1169  fhConeSumPtSubvsConeSumPtTotPhiCell ->Fill(coneptsumCell,coneptsumCellSubPhi , GetEventWeight());
1170  fhConeSumPtSubNormvsConeSumPtTotPhiCell->Fill(coneptsumCell,coneptsumCellSubPhiNorm, GetEventWeight());
1171  fhConeSumPtSubvsConeSumPtTotEtaCell ->Fill(coneptsumCell,coneptsumCellSubEta , GetEventWeight());
1172  fhConeSumPtSubNormvsConeSumPtTotEtaCell->Fill(coneptsumCell,coneptsumCellSubEtaNorm, GetEventWeight());
1173  }
1174  }
1175 
1176  sumPhiUESub = coneptsumClusterSubPhi + coneptsumTrackSubPhi;
1177  sumEtaUESub = coneptsumClusterSubEta + coneptsumTrackSubEta;
1178 
1179  if ( partTypeInCone == AliIsolationCut::kNeutralAndCharged )
1180  {
1181  // --------------------------- //
1182  // Tracks and clusters in cone //
1183  // --------------------------- //
1184  fhConeSumPtPhiUESub ->Fill(ptTrig, sumPhiUESub, GetEventWeight());
1185  fhConeSumPtEtaUESub ->Fill(ptTrig, sumEtaUESub, GetEventWeight());
1186 
1188  {
1189  fhConeSumPtPhiUESubTrigEtaPhi->Fill(etaTrig, phiTrig, sumPhiUESub *GetEventWeight()); // check
1190  fhConeSumPtEtaUESubTrigEtaPhi->Fill(etaTrig, phiTrig, sumEtaUESub *GetEventWeight()); // check
1191 
1192  fhEtaBandClustervsTrack ->Fill(etaUEptsumCluster ,etaUEptsumTrack , GetEventWeight());
1193  fhPhiBandClustervsTrack ->Fill(phiUEptsumCluster ,phiUEptsumTrack , GetEventWeight());
1194  fhEtaBandNormClustervsTrack->Fill(etaUEptsumClusterNorm,etaUEptsumTrackNorm, GetEventWeight());
1195  fhPhiBandNormClustervsTrack->Fill(phiUEptsumClusterNorm,phiUEptsumTrackNorm, GetEventWeight());
1196 
1197  fhConeSumPtEtaUESubClustervsTrack->Fill(coneptsumClusterSubEta, coneptsumTrackSubEta, GetEventWeight());
1198  fhConeSumPtPhiUESubClustervsTrack->Fill(coneptsumClusterSubPhi, coneptsumTrackSubPhi, GetEventWeight());
1199  }
1200 
1201  // ------------------------ //
1202  // Tracks and cells in cone //
1203  // ------------------------ //
1204 
1206  {
1207  Double_t sumPhiUESubTrackCell = coneptsumCellSubPhi + coneptsumTrackSubPhi;
1208  Double_t sumEtaUESubTrackCell = coneptsumCellSubEta + coneptsumTrackSubEta;
1209 
1210  fhConeSumPtPhiUESubTrackCell ->Fill(ptTrig , sumPhiUESubTrackCell, GetEventWeight());
1211  fhConeSumPtPhiUESubTrackCellTrigEtaPhi->Fill(etaTrig, phiTrig, sumPhiUESubTrackCell *GetEventWeight()); // check
1212  fhConeSumPtEtaUESubTrackCell ->Fill(ptTrig , sumEtaUESubTrackCell, GetEventWeight());
1213  fhConeSumPtEtaUESubTrackCellTrigEtaPhi->Fill(etaTrig, phiTrig, sumEtaUESubTrackCell *GetEventWeight()); // check
1214 
1215  fhEtaBandCellvsTrack ->Fill(etaUEptsumCell , etaUEptsumTrack , GetEventWeight());
1216  fhPhiBandCellvsTrack ->Fill(phiUEptsumCell , phiUEptsumTrack , GetEventWeight());
1217  fhEtaBandNormCellvsTrack->Fill(etaUEptsumCellNorm, etaUEptsumTrackNorm, GetEventWeight());
1218  fhPhiBandNormCellvsTrack->Fill(phiUEptsumCellNorm, phiUEptsumTrackNorm, GetEventWeight());
1219 
1220  fhConeSumPtEtaUESubCellvsTrack->Fill(coneptsumCellSubEta, coneptsumTrackSubEta, GetEventWeight());
1221  fhConeSumPtPhiUESubCellvsTrack->Fill(coneptsumCellSubPhi, coneptsumTrackSubPhi, GetEventWeight());
1222  }
1223  }
1224 }
1225 
1226 //______________________________________________________________________________________________________________
1228 //______________________________________________________________________________________________________________
1229 void AliAnaParticleIsolation::CalculateCaloSignalInCone(AliAODPWG4ParticleCorrelation * aodParticle,
1230  Float_t & coneptsumCluster, Float_t & coneptLeadCluster)
1231 {
1232  coneptLeadCluster = 0;
1233  coneptsumCluster = 0;
1234 
1235  if( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kOnlyCharged ) return ;
1236 
1237  Float_t ptTrig = aodParticle->Pt();
1238 
1239  // Recover reference arrays with clusters and tracks
1240  TObjArray * refclusters = aodParticle->GetObjArray(GetAODObjArrayName()+"Clusters");
1241  if(!refclusters)
1242  {
1243  fhConeSumPtCluster ->Fill(ptTrig, 0., GetEventWeight());
1244  fhConePtLeadCluster->Fill(ptTrig, 0., GetEventWeight());
1246  fhConeSumPtClusterExoTrigger->Fill(ptTrig, 0., GetEventWeight());
1247 
1248  if(coneptLeadCluster > 0 || coneptsumCluster > 0)
1249  AliError(Form("No ref tracks!!! sum %f, lead %f",coneptsumCluster,coneptLeadCluster));
1250 
1251  return ;
1252  }
1253 
1254  // Get vertex for cluster momentum calculation
1255  Double_t vertex[] = {0,0,0} ; //vertex ;
1256  if(GetReader()->GetDataType() != AliCaloTrackReader::kMC)
1257  GetReader()->GetVertex(vertex);
1258 
1259  Float_t ptcone = 0;
1260  Float_t coneNClusterPerMinCut [20];
1261  Float_t coneptsumClusterPerMinCut[20];
1262  Float_t coneptsumClusterPerMaxCut[20];
1263  Float_t coneptsumClusterPerRCut [10];
1264 
1265  Float_t coneptsumClusterPerNCellCut[20];
1266  Float_t coneptsumClusterPerExoCut [20];
1267 
1268  if(fStudyPtCutInCone)
1269  {
1270  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
1271  {
1272  coneNClusterPerMinCut [icut] = 0;
1273  coneptsumClusterPerMinCut[icut] = 0;
1274  coneptsumClusterPerMaxCut[icut] = 0;
1275  }
1276  }
1277 
1278  if(fStudyRCutInCone)
1279  {
1280  for(Int_t icut = 0; icut < fNRCutsInCone; icut++)
1281  {
1282  coneptsumClusterPerRCut[icut] = 0;
1283  }
1284  }
1285 
1287  {
1288  for(Int_t icut = 0; icut < fNNCellsInCandidate; icut++)
1289  {
1290  coneptsumClusterPerNCellCut[icut] = 0;
1291  }
1292 
1293  for(Int_t icut = 0; icut < fNExoCutInCandidate; icut++)
1294  {
1295  coneptsumClusterPerExoCut[icut] = 0;
1296  }
1297  }
1298 
1299 
1300  for(Int_t icalo=0; icalo < refclusters->GetEntriesFast(); icalo++)
1301  {
1302  AliVCluster* calo = (AliVCluster *) refclusters->At(icalo);
1303  calo->GetMomentum(fMomentum,vertex) ;//Assume that come from vertex in straight line
1304 
1305  ptcone = fMomentum.Pt();
1306 
1307  fhPtInCone ->Fill(ptTrig, ptcone, GetEventWeight());
1308  fhPtClusterInCone->Fill(ptTrig, ptcone, GetEventWeight());
1309 
1311  {
1312  fhPtInConeExoTrigger ->Fill(ptTrig , ptcone, GetEventWeight());
1313  fhPtClusterInConeExoTrigger ->Fill(ptTrig , ptcone, GetEventWeight());
1314  }
1315 
1316  if(IsPileUpAnalysisOn())
1317  {
1318  if(GetReader()->IsPileUpFromSPD()) fhPtInConePileUp[0]->Fill(ptTrig, ptcone, GetEventWeight());
1319  if(GetReader()->IsPileUpFromEMCal()) fhPtInConePileUp[1]->Fill(ptTrig, ptcone, GetEventWeight());
1320  if(GetReader()->IsPileUpFromSPDOrEMCal()) fhPtInConePileUp[2]->Fill(ptTrig, ptcone, GetEventWeight());
1321  if(GetReader()->IsPileUpFromSPDAndEMCal()) fhPtInConePileUp[3]->Fill(ptTrig, ptcone, GetEventWeight());
1322  if(GetReader()->IsPileUpFromSPDAndNotEMCal()) fhPtInConePileUp[4]->Fill(ptTrig, ptcone, GetEventWeight());
1323  if(GetReader()->IsPileUpFromEMCalAndNotSPD()) fhPtInConePileUp[5]->Fill(ptTrig, ptcone, GetEventWeight());
1324  if(GetReader()->IsPileUpFromNotSPDAndNotEMCal()) fhPtInConePileUp[6]->Fill(ptTrig, ptcone, GetEventWeight());
1325  }
1326 
1328 
1329  coneptsumCluster+=ptcone;
1330  if(ptcone > coneptLeadCluster) coneptLeadCluster = ptcone;
1331 
1332  if(fStudyPtCutInCone)
1333  {
1334  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
1335  {
1336  if ( ptcone > fMinPtCutInCone[icut] )
1337  {
1338  coneptsumClusterPerMinCut[icut]+=ptcone;
1339  coneNClusterPerMinCut [icut]++;
1340  }
1341 
1342  if ( ptcone < fMaxPtCutInCone[icut] ) coneptsumClusterPerMaxCut[icut]+=ptcone;
1343  }
1344  }
1345 
1346  if(fStudyRCutInCone)
1347  {
1348  Float_t distance = GetIsolationCut()->Radius(aodParticle->Eta(), aodParticle->Phi(), fMomentum.Eta(), GetPhi(fMomentum.Phi()));
1349  for(Int_t icut = 0; icut < fNRCutsInCone; icut++)
1350  {
1351  if ( distance < fRCutInCone[icut] )
1352  {
1353  coneptsumClusterPerRCut[icut]+=ptcone;
1354  fhPtClusterInConePerRCut->Fill(icut+1, ptcone, GetEventWeight());
1355  if(ptTrig > 10) fhPtClusterInConePerRCutLargePtTrig->Fill(icut+1, ptcone, GetEventWeight());
1356  }
1357  }
1358  }
1359 
1361  {
1362  for(Int_t icut = 0; icut < fNNCellsInCandidate; icut++)
1363  {
1364  if ( fCluster->GetNCells() >= fNCellsInCandidate[icut] )
1365  {
1366  coneptsumClusterPerNCellCut[icut]+=ptcone;
1367  fhPtClusterInConePerNCellCut->Fill(icut+1, ptcone, GetEventWeight());
1368  if(ptTrig > 10) fhPtClusterInConePerNCellCutLargePtTrig->Fill(icut+1, ptcone, GetEventWeight());
1369  }
1370  }
1371 
1372  for(Int_t icut = 0; icut < fNExoCutInCandidate; icut++)
1373  {
1374  if ( fClusterExoticity < fExoCutInCandidate[icut] )
1375  {
1376  coneptsumClusterPerExoCut[icut]+=ptcone;
1377  fhPtClusterInConePerExoCut->Fill(icut+1, ptcone, GetEventWeight());
1378  if(ptTrig > 10) fhPtClusterInConePerExoCutLargePtTrig->Fill(icut+1, ptcone, GetEventWeight());
1379  }
1380  }
1381  }
1382  }
1383 
1384  fhConeSumPtCluster ->Fill(ptTrig, coneptsumCluster , GetEventWeight());
1385  fhConePtLeadCluster->Fill(ptTrig, coneptLeadCluster, GetEventWeight());
1387  fhConeSumPtClusterExoTrigger ->Fill(ptTrig, coneptsumCluster , GetEventWeight());
1388 
1389  aodParticle->SetNeutralLeadPtInCone(coneptLeadCluster);
1390  aodParticle->SetNeutralPtSumInCone(coneptsumCluster);
1391 
1392  if(fStudyPtCutInCone)
1393  {
1394  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
1395  {
1396  fhConeNClusterPerMinPtCut ->Fill(icut, coneNClusterPerMinCut [icut], GetEventWeight());
1397  fhConeSumPtClusterPerMinPtCut->Fill(icut, coneptsumClusterPerMinCut[icut], GetEventWeight());
1398  fhConeSumPtClusterPerMaxPtCut->Fill(icut, coneptsumClusterPerMaxCut[icut], GetEventWeight());
1399 
1400  if ( ptTrig > 10 )
1401  {
1402  fhConeNClusterPerMinPtCutLargePtTrig ->Fill(icut, coneNClusterPerMinCut [icut], GetEventWeight());
1403  fhConeSumPtClusterPerMinPtCutLargePtTrig->Fill(icut, coneptsumClusterPerMinCut[icut], GetEventWeight());
1404  fhConeSumPtClusterPerMaxPtCutLargePtTrig->Fill(icut, coneptsumClusterPerMaxCut[icut], GetEventWeight());
1405  }
1406  }
1407  }
1408 
1409  if(fStudyRCutInCone)
1410  {
1411  for(Int_t icut = 0; icut < fNRCutsInCone; icut++)
1412  {
1413  fhConeSumPtClusterPerRCut->Fill(icut, coneptsumClusterPerRCut[icut], GetEventWeight());
1414  if ( ptTrig > 10 ) fhConeSumPtClusterPerRCutLargePtTrig->Fill(icut, coneptsumClusterPerRCut[icut], GetEventWeight());
1415  }
1416  }
1417 
1419  {
1420  for(Int_t icut = 0; icut < fNNCellsInCandidate; icut++)
1421  {
1422  fhConeSumPtClusterPerNCellCut->Fill(icut, coneptsumClusterPerNCellCut[icut], GetEventWeight());
1423  if ( ptTrig > 10 ) fhConeSumPtClusterPerNCellCutLargePtTrig->Fill(icut, coneptsumClusterPerNCellCut[icut], GetEventWeight());
1424  }
1425 
1426  for(Int_t icut = 0; icut < fNExoCutInCandidate; icut++)
1427  {
1428  fhConeSumPtClusterPerExoCut->Fill(icut, coneptsumClusterPerExoCut[icut], GetEventWeight());
1429  if ( ptTrig > 10 ) fhConeSumPtClusterPerExoCutLargePtTrig->Fill(icut, coneptsumClusterPerExoCut[icut], GetEventWeight());
1430  }
1431  }
1432 }
1433 
1434 //______________________________________________________________________________________________________
1437 //______________________________________________________________________________________________________
1438 void AliAnaParticleIsolation::CalculateCaloCellSignalInCone(AliAODPWG4ParticleCorrelation * aodParticle,
1439  Float_t & coneptsumCell)
1440 {
1441  if( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kOnlyCharged ) return ;
1442 
1443  if( !fFillCellHistograms ) return ;
1444 
1445  Float_t conesize = GetIsolationCut()->GetConeSize();
1446 
1447  Float_t ptTrig = aodParticle->Pt();
1448  Float_t phiTrig = aodParticle->Phi();
1449  if(phiTrig<0) phiTrig += TMath::TwoPi();
1450  Float_t etaTrig = aodParticle->Eta();
1451 
1452  if(aodParticle->GetDetectorTag()==kEMCAL)
1453  {
1454  AliEMCALGeometry* eGeom = AliEMCALGeometry::GetInstance();
1455  Int_t absId = -999;
1456 
1457  if (eGeom->GetAbsCellIdFromEtaPhi(etaTrig,phiTrig,absId))
1458  {
1459  if(!eGeom->CheckAbsCellId(absId)) return ;
1460 
1461  // Get absolute (col,row) of trigger particle
1462  Int_t nSupMod = eGeom->GetSuperModuleNumber(absId);
1463  Int_t nModule = -1;
1464  Int_t imEta=-1, imPhi=-1;
1465  Int_t ieta =-1, iphi =-1;
1466 
1467  if (eGeom->GetCellIndex(absId,nSupMod,nModule,imPhi,imEta))
1468  {
1469  Int_t iEta=-1, iPhi=-1;
1470  eGeom->GetCellPhiEtaIndexInSModule(nSupMod,nModule,imPhi,imEta,iphi,ieta);
1471 
1472  Int_t colTrig = iEta;
1473  if (nSupMod % 2) colTrig = AliEMCALGeoParams::fgkEMCALCols + iEta ;
1474  Int_t rowTrig = iPhi + AliEMCALGeoParams::fgkEMCALRows*int(nSupMod/2);
1475 
1476  Int_t sqrSize = int(conesize/0.0143);
1477 
1478  AliVCaloCells * cells = GetEMCALCells();
1479 
1480  // Loop on cells in cone
1481  for(Int_t irow = rowTrig-sqrSize; irow < rowTrig+sqrSize; irow++)
1482  {
1483  for(Int_t icol = colTrig-sqrSize; icol < colTrig+sqrSize; icol++)
1484  {
1485  Int_t inSector = int(irow/AliEMCALGeoParams::fgkEMCALRows);
1486  if(inSector==5) continue;
1487 
1488  Int_t inSupMod = -1;
1489  Int_t icolLoc = -1;
1490  if(icol < AliEMCALGeoParams::fgkEMCALCols)
1491  {
1492  inSupMod = 2*inSector + 1;
1493  icolLoc = icol;
1494  }
1495  else if(icol > AliEMCALGeoParams::fgkEMCALCols - 1)
1496  {
1497  inSupMod = 2*inSector;
1498  icolLoc = icol-AliEMCALGeoParams::fgkEMCALCols;
1499  }
1500 
1501  Int_t irowLoc = irow - AliEMCALGeoParams::fgkEMCALRows*inSector ;
1502 
1503  Int_t iabsId = eGeom->GetAbsCellIdFromCellIndexes(inSupMod,irowLoc,icolLoc);
1504  if(!eGeom->CheckAbsCellId(iabsId)) continue;
1505 
1506  fhPtCellInCone->Fill(ptTrig, cells->GetCellAmplitude(iabsId), GetEventWeight());
1507  coneptsumCell += cells->GetCellAmplitude(iabsId);
1508  }
1509  }
1510  }
1511  }
1512  }
1513 
1514  fhConeSumPtCell->Fill(ptTrig, coneptsumCell, GetEventWeight());
1515 }
1516 
1517 //___________________________________________________________________________________________________________
1519 //___________________________________________________________________________________________________________
1520 void AliAnaParticleIsolation::CalculateTrackSignalInCone(AliAODPWG4ParticleCorrelation * aodParticle,
1521  Float_t & coneptsumTrack, Float_t & coneptLeadTrack)
1522 {
1523  coneptLeadTrack = 0;
1524  coneptsumTrack = 0;
1525  if( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kOnlyNeutral ) return ;
1526 
1527  Float_t ptTrig = aodParticle->Pt();
1528  // Recover reference arrays with clusters and tracks
1529  TObjArray * reftracks = aodParticle->GetObjArray(GetAODObjArrayName()+"Tracks");
1530  if(!reftracks)
1531  {
1532  fhConeSumPtTrack ->Fill(ptTrig, 0., GetEventWeight());
1534  fhConeSumPtTrackExoTrigger->Fill(ptTrig, 0., GetEventWeight());
1535 
1536  if(fStudyTracksInCone)
1537  {
1538  fhConeSumPtTrackTOFNo ->Fill(ptTrig, 0., GetEventWeight());
1539  fhConeSumPtTrackTOFBC0->Fill(ptTrig, 0., GetEventWeight());
1540  fhConeSumPtTrackTOFBCN->Fill(ptTrig, 0., GetEventWeight());
1541  fhConeSumPtTrackITSRefitOnSPDOn ->Fill(ptTrig, 0., GetEventWeight());
1543  fhConeSumPtTrackITSRefitOnSPDOff ->Fill(ptTrig, 0., GetEventWeight());
1545  }
1546 
1547  fhConePtLeadTrack ->Fill(ptTrig, 0., GetEventWeight());
1548 
1549  if(coneptLeadTrack > 0 || coneptsumTrack > 0)
1550  AliError(Form("No ref tracks!!! sum %f, lead %f",coneptsumTrack,coneptLeadTrack));
1551  return ;
1552  }
1553 
1554  Double_t bz = GetReader()->GetInputEvent()->GetMagneticField();
1555 
1556  Float_t pTtrack = 0;
1557  Float_t phitrack = 0;
1558  Float_t etatrack = 0;
1559  Float_t coneNTrackPerMinCut [20];
1560  Float_t coneptsumTrackPerMinCut[20];
1561  Float_t coneptsumTrackPerMaxCut[20];
1562  Float_t coneptsumTrackPerEtaCut[10];
1563  Float_t coneptsumTrackPerNCellCut[20];
1564  Float_t coneptsumTrackPerExoCut[20];
1565  Float_t coneptsumTrackPerRCut [10];
1566  Float_t coneptsumTrackTOFBC0 = 0;
1567  Float_t coneptsumTrackTOFBCN = 0;
1568  Float_t coneptsumTrackTOFNo = 0;
1569  Float_t coneptsumTrackITSRefitOnSPDOn = 0;
1570  Float_t coneptsumTrackITSRefitOnSPDOff = 0;
1571  Float_t coneptsumTrackITSRefitOffSPDOff = 0;
1572  Float_t coneptsumTrackTOFBC0ITSRefitOnSPDOn = 0;
1573 
1574  if(fStudyPtCutInCone)
1575  {
1576  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
1577  {
1578  coneptsumTrackPerMinCut[icut] = 0;
1579  coneptsumTrackPerMaxCut[icut] = 0;
1580  coneNTrackPerMinCut [icut] = 0;
1581  }
1582  }
1583 
1584  if(fStudyEtaCutInCone)
1585  {
1586  for(Int_t icut = 0; icut < fNEtaCutsInCone; icut++)
1587  {
1588  coneptsumTrackPerEtaCut[icut] = 0;
1589  }
1590  }
1591 
1592  if(fStudyRCutInCone)
1593  {
1594  for(Int_t icut = 0; icut < fNRCutsInCone; icut++)
1595  {
1596  coneptsumTrackPerRCut[icut] = 0;
1597  }
1598  }
1599 
1601  {
1602  for(Int_t icut = 0; icut < fNNCellsInCandidate; icut++)
1603  {
1604  coneptsumTrackPerNCellCut[icut] = 0;
1605  }
1606 
1607  for(Int_t icut = 0; icut < fNExoCutInCandidate; icut++)
1608  {
1609  coneptsumTrackPerExoCut[icut] = 0;
1610  }
1611  }
1612 
1613  for(Int_t itrack=0; itrack < reftracks->GetEntriesFast(); itrack++)
1614  {
1615  AliVTrack* track = (AliVTrack *) reftracks->At(itrack);
1616 
1617  pTtrack = track->Pt();
1618 
1619  fhPtInCone ->Fill(ptTrig , pTtrack, GetEventWeight());
1620  fhPtTrackInCone ->Fill(ptTrig , pTtrack, GetEventWeight());
1621 
1622  if( IsDataMC() && GetMC() )
1623  {
1624  Int_t trackLabel = TMath::Abs(track->GetLabel());
1625 
1626  AliVParticle * mcpart = GetMC()->GetTrack(trackLabel);
1627  if( !mcpart ) continue;
1628 
1629  Int_t partInConeCharge = TMath::Abs(mcpart->Charge());
1630  Int_t partInConePDG = mcpart->PdgCode();
1631  Bool_t physPrimary = mcpart->IsPhysicalPrimary();
1632 
1633  if ( partInConeCharge > 0 && TMath::Abs(partInConePDG) != 11 ) // exclude electrons and neutrals
1634  {
1635  Int_t mcChTag = 3;
1636  if ( TMath::Abs(partInConePDG) == 211 ) mcChTag = 0;
1637  else if ( TMath::Abs(partInConePDG) == 321 ) mcChTag = 1;
1638  else if ( TMath::Abs(partInConePDG) == 2212 ) mcChTag = 2;
1639  if(physPrimary)
1640  fhPtTrackInConeMCPrimary [mcChTag]->Fill(ptTrig , pTtrack, GetEventWeight());
1641  else
1642  fhPtTrackInConeMCSecondary[mcChTag]->Fill(ptTrig , pTtrack, GetEventWeight());
1643  }
1644  }
1645 
1647  {
1648  fhPtInConeExoTrigger ->Fill(ptTrig , pTtrack, GetEventWeight());
1649  fhPtTrackInConeExoTrigger ->Fill(ptTrig , pTtrack, GetEventWeight());
1650  }
1651 
1653 
1654  coneptsumTrack+=pTtrack;
1655  if(pTtrack > coneptLeadTrack) coneptLeadTrack = pTtrack;
1656 
1657  if(fStudyPtCutInCone)
1658  {
1659  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
1660  {
1661  if ( pTtrack > fMinPtCutInCone[icut] )
1662  {
1663  coneptsumTrackPerMinCut[icut]+=pTtrack;
1664  coneNTrackPerMinCut [icut]++;
1665  }
1666 
1667  if ( pTtrack < fMaxPtCutInCone[icut] ) coneptsumTrackPerMaxCut[icut]+=pTtrack;
1668  }
1669  }
1670 
1671  if(fStudyEtaCutInCone)
1672  {
1673  for(Int_t icut = 0; icut < fNEtaCutsInCone; icut++)
1674  {
1675  if ( TMath::Abs(track->Eta()) < fEtaCutInCone[icut] ) coneptsumTrackPerEtaCut[icut]+=pTtrack;
1676  }
1677  }
1678 
1679  if(fStudyRCutInCone)
1680  {
1681  Float_t distance = GetIsolationCut()->Radius(aodParticle->Eta(), aodParticle->Phi(), track->Eta(), track->Phi());
1682  for(Int_t icut = 0; icut < fNRCutsInCone; icut++)
1683  {
1684  if ( distance < fRCutInCone[icut] )
1685  {
1686  coneptsumTrackPerRCut[icut]+=pTtrack;
1687  fhPtTrackInConePerRCut->Fill(icut+1, pTtrack, GetEventWeight());
1688  if(ptTrig > 10) fhPtTrackInConePerRCutLargePtTrig->Fill(icut+1, pTtrack, GetEventWeight());
1689  }
1690  }
1691  }
1692 
1694  {
1695  for(Int_t icut = 0; icut < fNNCellsInCandidate; icut++)
1696  {
1697  if ( fCluster->GetNCells() >= fNCellsInCandidate[icut] )
1698  {
1699  coneptsumTrackPerNCellCut[icut]+=pTtrack;
1700  fhPtTrackInConePerNCellCut->Fill(icut+1, pTtrack, GetEventWeight());
1701  if(ptTrig > 10) fhPtTrackInConePerNCellCutLargePtTrig->Fill(icut+1, pTtrack, GetEventWeight());
1702  }
1703  }
1704 
1705  for(Int_t icut = 0; icut < fNExoCutInCandidate; icut++)
1706  {
1707  if ( fClusterExoticity < fExoCutInCandidate[icut] )
1708  {
1709  coneptsumTrackPerExoCut[icut]+=pTtrack;
1710  fhPtTrackInConePerExoCut->Fill(icut+1, pTtrack, GetEventWeight());
1711  if(ptTrig > 10) fhPtTrackInConePerExoCutLargePtTrig->Fill(icut+1, pTtrack, GetEventWeight());
1712  }
1713  }
1714  }
1715 
1716  Bool_t okTOF = kFALSE ;
1717  Int_t trackBC = 0;
1718  if(fStudyTracksInCone)
1719  {
1720  phitrack = track->Phi();
1721  etatrack = track->Eta();
1722 
1723  fhPhiTrackInCone->Fill(pTtrack, phitrack, GetEventWeight());
1724  fhEtaTrackInCone->Fill(pTtrack, etatrack, GetEventWeight());
1725  fhEtaPhiTrackInCone->Fill(etatrack, phitrack, GetEventWeight());
1726 
1727  // TOF
1728  ULong_t status = track->GetStatus();
1729  okTOF = (status & AliVTrack::kTOFout) == AliVTrack::kTOFout ;
1730  trackBC = track->GetTOFBunchCrossing(bz);
1731  Double32_t tof = track->GetTOFsignal()*1e-3;
1732 
1733  Int_t vtxBC = GetReader()->GetVertexBC();
1734  if(vtxBC == 0 || vtxBC==AliVTrack::kTOFBCNA) fhPtTrackInConeVtxBC0->Fill(ptTrig, pTtrack, GetEventWeight());
1735 
1736  if(okTOF)
1737  {
1738  fhTrackTOFInCone->Fill(pTtrack,tof,GetEventWeight());
1739 
1741  fhTrackTOFInConeExoTrigger->Fill(pTtrack,tof,GetEventWeight());
1742 
1743  if(trackBC == 0)
1744  {
1745  fhPtTrackInConeTOFBC0 ->Fill(ptTrig , pTtrack , GetEventWeight());
1746  fhPhiTrackInConeTOFBC0->Fill(pTtrack, phitrack, GetEventWeight());
1747  fhEtaTrackInConeTOFBC0->Fill(pTtrack, etatrack, GetEventWeight());
1748  fhEtaPhiTrackInConeTOFBC0->Fill(etatrack, phitrack, GetEventWeight());
1749  fhTrackTOFInConeBC0 ->Fill(pTtrack, tof , GetEventWeight());
1750  coneptsumTrackTOFBC0 += pTtrack;
1751  }
1752  else
1753  {
1754  fhPtTrackInConeTOFBCN ->Fill(ptTrig , pTtrack , GetEventWeight());
1755  fhPhiTrackInConeTOFBCN->Fill(pTtrack, phitrack, GetEventWeight());
1756  fhEtaTrackInConeTOFBCN->Fill(pTtrack, etatrack, GetEventWeight());
1757  fhEtaPhiTrackInConeTOFBCN->Fill(etatrack, phitrack, GetEventWeight());
1758  coneptsumTrackTOFBCN += pTtrack;
1759  }
1760  }
1761  else
1762  {
1763  fhPtTrackInConeTOFNo ->Fill(ptTrig, pTtrack , GetEventWeight());
1764  fhPhiTrackInConeTOFNo->Fill(ptTrig, phitrack, GetEventWeight());
1765  fhEtaTrackInConeTOFNo->Fill(ptTrig, etatrack, GetEventWeight());
1766  fhEtaPhiTrackInConeTOFNo->Fill(etatrack, phitrack, GetEventWeight());
1767  coneptsumTrackTOFNo += pTtrack;
1768  }
1769 
1770 
1771  Bool_t bITSRefit = (status & AliVTrack::kITSrefit) == AliVTrack::kITSrefit;
1772  Bool_t bConstrained = (!track->HasPointOnITSLayer(0) && !track->HasPointOnITSLayer(1));
1773  //printf("Track %d, pt %2.2f, eta %2.2f, phi %2.2f, SPDRefit %d, refit %d\n",
1774  // itrack, pTtrack, etatrack, phitrack, bConstrained, bITSRefit);
1775 
1776  if(bConstrained)
1777  {
1778  if(bITSRefit)
1779  {
1780  coneptsumTrackITSRefitOnSPDOff += pTtrack;
1781  fhPtTrackInConeITSRefitOnSPDOff ->Fill(ptTrig, pTtrack , GetEventWeight());
1782  fhPhiTrackInConeITSRefitOnSPDOff->Fill(ptTrig, phitrack, GetEventWeight());
1783  fhEtaTrackInConeITSRefitOnSPDOff->Fill(ptTrig, etatrack, GetEventWeight());
1784  fhEtaPhiTrackInConeITSRefitOnSPDOff->Fill(etatrack, phitrack, GetEventWeight());
1785  }
1786  else
1787  {
1788  coneptsumTrackITSRefitOffSPDOff += pTtrack;
1789  fhPtTrackInConeITSRefitOffSPDOff ->Fill(ptTrig, pTtrack , GetEventWeight());
1790  fhPhiTrackInConeITSRefitOffSPDOff->Fill(ptTrig, phitrack, GetEventWeight());
1791  fhEtaTrackInConeITSRefitOffSPDOff->Fill(ptTrig, etatrack, GetEventWeight());
1792  fhEtaPhiTrackInConeITSRefitOffSPDOff->Fill(etatrack, phitrack, GetEventWeight());
1793  }
1794  }
1795  else
1796  {
1797  coneptsumTrackITSRefitOnSPDOn += pTtrack;
1798  fhPtTrackInConeITSRefitOnSPDOn ->Fill(ptTrig, pTtrack , GetEventWeight());
1799  fhPhiTrackInConeITSRefitOnSPDOn->Fill(ptTrig, phitrack, GetEventWeight());
1800  fhEtaTrackInConeITSRefitOnSPDOn->Fill(ptTrig, etatrack, GetEventWeight());
1801  fhEtaPhiTrackInConeITSRefitOnSPDOn->Fill(etatrack, phitrack, GetEventWeight());
1802  }
1803 
1804  if(okTOF && trackBC == 0 && !bConstrained)
1805  {
1806  fhPtTrackInConeTOFBC0ITSRefitOnSPDOn ->Fill(ptTrig , pTtrack , GetEventWeight());
1807  fhPhiTrackInConeTOFBC0ITSRefitOnSPDOn->Fill(pTtrack, phitrack, GetEventWeight());
1808  fhEtaTrackInConeTOFBC0ITSRefitOnSPDOn->Fill(pTtrack, etatrack, GetEventWeight());
1809  fhEtaPhiTrackInConeTOFBC0ITSRefitOnSPDOn->Fill(etatrack, phitrack, GetEventWeight());
1810  coneptsumTrackTOFBC0ITSRefitOnSPDOn += pTtrack;
1811  }
1812 
1813  // DCA
1814  //
1815  if(ptTrig > 10)
1816  {
1817  Double_t dca[2] = {1e6,1e6};
1818  Double_t covar[3] = {1e6,1e6,1e6};
1819 
1820  Double_t dcaCons = -999;
1821  if ( GetReader()->GetDataType() == AliCaloTrackReader::kAOD )
1822  {
1823  AliAODTrack * aodTrack = dynamic_cast<AliAODTrack*>(track);
1824  dcaCons = aodTrack->DCA();
1825  }
1826 
1827  track->PropagateToDCA(GetReader()->GetInputEvent()->GetPrimaryVertex(),bz,100.,dca,covar);
1828 
1829  if(dcaCons == -999)
1830  {
1831  fhPtTrackInConeDCA[0]->Fill(pTtrack, dca[0], GetEventWeight());
1832  fhPtTrackInConeDCA[1]->Fill(pTtrack, dca[1], GetEventWeight());
1833  }
1834  else
1835  {
1836  fhPtTrackInConeDCA[2]->Fill(pTtrack, dcaCons, GetEventWeight());
1837  }
1838  } // trigger pt cut
1839  }
1840 
1841  if(IsPileUpAnalysisOn())
1842  {
1843  if(GetReader()->IsPileUpFromSPD())
1844  {
1845  fhPtInConePileUp[0] ->Fill(ptTrig, pTtrack, GetEventWeight());
1846  if(fStudyTracksInCone)
1847  {
1848  if(okTOF && trackBC!=0 ) fhPtTrackInConeOtherBCPileUpSPD->Fill(ptTrig, pTtrack, GetEventWeight());
1849  if(okTOF && trackBC==0 ) fhPtTrackInConeBC0PileUpSPD ->Fill(ptTrig, pTtrack, GetEventWeight());
1850  }
1851  }
1852  if(GetReader()->IsPileUpFromEMCal()) fhPtInConePileUp[1]->Fill(ptTrig, pTtrack, GetEventWeight());
1853  if(GetReader()->IsPileUpFromSPDOrEMCal()) fhPtInConePileUp[2]->Fill(ptTrig, pTtrack, GetEventWeight());
1854  if(GetReader()->IsPileUpFromSPDAndEMCal()) fhPtInConePileUp[3]->Fill(ptTrig, pTtrack, GetEventWeight());
1855  if(GetReader()->IsPileUpFromSPDAndNotEMCal()) fhPtInConePileUp[4]->Fill(ptTrig, pTtrack, GetEventWeight());
1856  if(GetReader()->IsPileUpFromEMCalAndNotSPD()) fhPtInConePileUp[5]->Fill(ptTrig, pTtrack, GetEventWeight());
1857  if(GetReader()->IsPileUpFromNotSPDAndNotEMCal()) fhPtInConePileUp[6]->Fill(ptTrig, pTtrack, GetEventWeight());
1858  }
1859  }
1860 
1861  fhConeSumPtTrack ->Fill(ptTrig, coneptsumTrack , GetEventWeight());
1862  fhConePtLeadTrack->Fill(ptTrig, coneptLeadTrack, GetEventWeight());
1864  fhConeSumPtTrackExoTrigger ->Fill(ptTrig, coneptsumTrack , GetEventWeight());
1865 
1866  if(fStudyTracksInCone)
1867  {
1868  fhConeSumPtTrackTOFBC0->Fill(ptTrig, coneptsumTrackTOFBC0, GetEventWeight());
1869  fhConeSumPtTrackTOFBCN->Fill(ptTrig, coneptsumTrackTOFBCN, GetEventWeight());
1870  fhConeSumPtTrackTOFNo ->Fill(ptTrig, coneptsumTrackTOFNo , GetEventWeight());
1871 
1872  fhConeSumPtTrackITSRefitOnSPDOn ->Fill(ptTrig, coneptsumTrackITSRefitOnSPDOn , GetEventWeight());
1873  fhConeSumPtTrackITSRefitOffSPDOff->Fill(ptTrig, coneptsumTrackITSRefitOffSPDOff, GetEventWeight());
1874  fhConeSumPtTrackITSRefitOnSPDOff ->Fill(ptTrig, coneptsumTrackITSRefitOnSPDOff , GetEventWeight());
1875 
1876  fhConeSumPtTrackTOFBC0ITSRefitOnSPDOn->Fill(ptTrig, coneptsumTrackTOFBC0ITSRefitOnSPDOn, GetEventWeight());
1877  }
1878 
1879  aodParticle->SetChargedLeadPtInCone(coneptLeadTrack);
1880  aodParticle->SetChargedPtSumInCone(coneptsumTrack);
1881 
1882  if(fStudyPtCutInCone)
1883  {
1884  for(Int_t icut = 0; icut < fNPtCutsInCone; icut++)
1885  {
1886  fhConeSumPtTrackPerMinPtCut->Fill(icut+1, coneptsumTrackPerMinCut[icut], GetEventWeight());
1887  fhConeSumPtTrackPerMaxPtCut->Fill(icut+1, coneptsumTrackPerMaxCut[icut], GetEventWeight());
1888  fhConeNTrackPerMinPtCut ->Fill(icut+1, coneNTrackPerMinCut [icut], GetEventWeight());
1889 
1890  if ( ptTrig > 10 )
1891  {
1892  fhConeSumPtTrackPerMinPtCutLargePtTrig->Fill(icut+1, coneptsumTrackPerMinCut[icut], GetEventWeight());
1893  fhConeSumPtTrackPerMaxPtCutLargePtTrig->Fill(icut+1, coneptsumTrackPerMaxCut[icut], GetEventWeight());
1894  fhConeNTrackPerMinPtCutLargePtTrig ->Fill(icut+1, coneNTrackPerMinCut [icut], GetEventWeight());
1895  }
1896  }
1897  }
1898 
1899  if(fStudyEtaCutInCone)
1900  {
1901  for(Int_t icut = 0; icut < fNEtaCutsInCone; icut++)
1902  {
1903  fhConeSumPtTrackPerEtaCut ->Fill(icut+1, coneptsumTrackPerEtaCut[icut], GetEventWeight());
1904  if ( ptTrig > 10 ) fhConeSumPtTrackPerEtaCutLargePtTrig->Fill(icut+1, coneptsumTrackPerEtaCut[icut], GetEventWeight());
1905  }
1906  }
1907 
1908  if(fStudyRCutInCone)
1909  {
1910  for(Int_t icut = 0; icut < fNRCutsInCone; icut++)
1911  {
1912  fhConeSumPtTrackPerRCut ->Fill(icut+1, coneptsumTrackPerRCut[icut], GetEventWeight());
1913  if ( ptTrig > 10 ) fhConeSumPtTrackPerRCutLargePtTrig->Fill(icut+1, coneptsumTrackPerRCut[icut], GetEventWeight());
1914  }
1915  }
1916 
1918  {
1919  for(Int_t icut = 0; icut < fNNCellsInCandidate; icut++)
1920  {
1921  fhConeSumPtTrackPerNCellCut->Fill(icut, coneptsumTrackPerNCellCut[icut], GetEventWeight());
1922  if ( ptTrig > 10 ) fhConeSumPtTrackPerNCellCutLargePtTrig->Fill(icut, coneptsumTrackPerNCellCut[icut], GetEventWeight());
1923  }
1924 
1925  for(Int_t icut = 0; icut < fNExoCutInCandidate; icut++)
1926  {
1927  fhConeSumPtTrackPerExoCut->Fill(icut, coneptsumTrackPerExoCut[icut], GetEventWeight());
1928  if ( ptTrig > 10 ) fhConeSumPtTrackPerExoCutLargePtTrig->Fill(icut, coneptsumTrackPerExoCut[icut], GetEventWeight());
1929  }
1930  }
1931 }
1932 
1933 //_____________________________________________________________________________
1935 //_____________________________________________________________________________
1937 {
1938  AliVEvent * event = GetReader()->GetInputEvent();
1939 
1940  fhTimeENoCut->Fill(energy, time, GetEventWeight());
1941  if(GetReader()->IsPileUpFromSPD()) fhTimeESPD ->Fill(energy, time, GetEventWeight());
1942  if(event->IsPileupFromSPDInMultBins()) fhTimeESPDMulti->Fill(energy, time, GetEventWeight());
1943 
1944  if(energy < 8) return; // Fill time figures for high energy clusters not too close to trigger threshold
1945 
1946  AliESDEvent* esdEv = dynamic_cast<AliESDEvent*> (event);
1947  AliAODEvent* aodEv = dynamic_cast<AliAODEvent*> (event);
1948 
1949  // N pile up vertices
1950  Int_t nVerticesSPD = -1;
1951  Int_t nVerticesTracks = -1;
1952 
1953  if (esdEv)
1954  {
1955  nVerticesSPD = esdEv->GetNumberOfPileupVerticesSPD();
1956  nVerticesTracks = esdEv->GetNumberOfPileupVerticesTracks();
1957 
1958  }//ESD
1959  else if (aodEv)
1960  {
1961  nVerticesSPD = aodEv->GetNumberOfPileupVerticesSPD();
1962  nVerticesTracks = aodEv->GetNumberOfPileupVerticesTracks();
1963  }//AOD
1964 
1965  fhTimeNPileUpVertSPD ->Fill(time, nVerticesSPD , GetEventWeight());
1966  fhTimeNPileUpVertTrack->Fill(time, nVerticesTracks, GetEventWeight());
1967 
1968  //printf("Is SPD %d, Is SPD Multi %d, n spd %d, n track %d\n",
1969  // GetReader()->IsPileUpFromSPD(),event->IsPileupFromSPDInMultBins(),nVerticesSPD,nVerticesTracks);
1970 
1971  Int_t ncont = -1;
1972  Float_t z1 = -1, z2 = -1;
1973  Float_t diamZ = -1;
1974  for(Int_t iVert=0; iVert<nVerticesSPD;iVert++)
1975  {
1976  if (esdEv)
1977  {
1978  const AliESDVertex* pv=esdEv->GetPileupVertexSPD(iVert);
1979  ncont=pv->GetNContributors();
1980  z1 = esdEv->GetPrimaryVertexSPD()->GetZ();
1981  z2 = pv->GetZ();
1982  diamZ = esdEv->GetDiamondZ();
1983  }//ESD
1984  else if (aodEv)
1985  {
1986  AliAODVertex *pv=aodEv->GetVertex(iVert);
1987  if(pv->GetType()!=AliAODVertex::kPileupSPD) continue;
1988  ncont=pv->GetNContributors();
1989  z1=aodEv->GetPrimaryVertexSPD()->GetZ();
1990  z2=pv->GetZ();
1991  diamZ = aodEv->GetDiamondZ();
1992  }// AOD
1993 
1994  Double_t distZ = TMath::Abs(z2-z1);
1995  diamZ = TMath::Abs(z2-diamZ);
1996 
1997  fhTimeNPileUpVertContributors ->Fill(time, ncont, GetEventWeight());
1998  fhTimePileUpMainVertexZDistance->Fill(time, distZ, GetEventWeight());
1999  fhTimePileUpMainVertexZDiamond ->Fill(time, diamZ, GetEventWeight());
2000 
2001  }// loop
2002 }
2003 
2004 //_____________________________________________________________________________________________________________________
2006 //_____________________________________________________________________________________________________________________
2008 (AliAODPWG4ParticleCorrelation *pCandidate,
2009  Float_t coneptsum, Float_t coneptsumTrack, Float_t coneptsumClust,
2010  Float_t coneleadpt, Int_t mcIndex)
2011 {
2012  if(!fFillTMHisto && !fFillSSHisto && !fFillBackgroundBinHistograms && !fFillTaggedDecayHistograms) return;
2013 
2014  Int_t nMaxima = pCandidate->GetNLM();
2015  Int_t mcTag = pCandidate->GetTag() ;
2016  Bool_t isolated = pCandidate->IsIsolated();
2017 
2018  Float_t m02 = pCandidate->GetM02() ;
2019  Float_t energy = pCandidate->E();
2020  Float_t pt = pCandidate->Pt();
2021  Float_t eta = pCandidate->Eta();
2022  Float_t phi = pCandidate->Phi();
2023  if(phi<0) phi+= TMath::TwoPi();
2024 
2025  // Candidates tagged as decay in another analysis (AliAnaPi0EbE)
2026  //
2027  if(fFillTaggedDecayHistograms)
2028  {
2029  Int_t decayTag = pCandidate->DecayTag();
2030  if(decayTag < 0) decayTag = 0;
2031 
2032  for(Int_t ibit = 0; ibit < fNDecayBits; ibit++)
2033  {
2034  if(!GetNeutralMesonSelection()->CheckDecayBit(decayTag,fDecayBits[ibit])) continue;
2035 
2036  if(fFillSSHisto) fhPtLambda0Decay[isolated][ibit]->Fill(pt, m02, GetEventWeight());
2037 
2038  // In case it was not done on the trigger selection task
2039  // apply here a shower shape cut to select photons
2040  if( m02 > fDecayTagsM02Cut ) continue;
2041 
2042  fhPtDecay [isolated][ibit]->Fill(pt, GetEventWeight());
2043  fhEtaPhiDecay[isolated][ibit]->Fill(eta, phi, GetEventWeight());
2044 
2045  if(IsDataMC())
2046  {
2047  fhPtDecayMC[isolated][ibit][mcIndex]->Fill(pt, GetEventWeight());
2048 
2049  if(GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton))
2050  fhPtDecayMC[isolated][ibit][kmcPhoton]->Fill(pt, GetEventWeight());
2051 
2052  if(GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2053  {
2054  if ( mcIndex == kmcPi0Decay ) fhPtDecayMC[isolated][ibit][kmcPi0DecayLostPair]->Fill(pt, GetEventWeight());
2055  else if( mcIndex == kmcEtaDecay ) fhPtDecayMC[isolated][ibit][kmcEtaDecayLostPair]->Fill(pt, GetEventWeight());
2056  }
2057  }
2058  } // bit loop
2059  } // decay histograms
2060 
2061  // Get the max pt leading in cone or the sum of pt in cone
2062  // assign a bin to the candidate, depending on both quantities
2063  // see the shower shape in those bins.
2064  if(fFillBackgroundBinHistograms)
2065  {
2066  // Get the background bin for this cone and trigger
2067  Int_t ptsumBin = -1;
2068  Int_t leadptBin = -1;
2069 
2070  AliDebug(1,Form("pT cand: %2.2f, In cone pT: Sum %2.2f, Lead %2.2f, n bins %d",pt,coneptsum,coneleadpt,fNBkgBin));
2071 
2072  for(Int_t ibin = 0; ibin < fNBkgBin; ibin++)
2073  {
2074  if( coneptsum >= fBkgBinLimit[ibin] && coneptsum < fBkgBinLimit[ibin+1]) ptsumBin = ibin;
2075  if( coneleadpt >= fBkgBinLimit[ibin] && coneleadpt < fBkgBinLimit[ibin+1]) leadptBin = ibin;
2076  }
2077 
2078  // Fill the histograms per bin of pt lead or pt sum
2079 
2080  if ( leadptBin >= 0 )
2081  {
2082  AliDebug(1,Form("\t Lead bin %d [%2.2f,%2.2f]", leadptBin,fBkgBinLimit[leadptBin],fBkgBinLimit[leadptBin+1]));
2083 
2084  fhPtLeadConeBin[leadptBin]->Fill(pt, GetEventWeight());
2085 
2086  if(fFillSSHisto)
2087  fhPtLeadConeBinLambda0[leadptBin]->Fill(pt, m02, GetEventWeight());
2088 
2089  if ( leadptBin == 0 )
2090  AliDebug(1,Form("No track/clusters in isolation cone: cand pt %2.2f GeV/c, track multiplicity %d, N clusters %d",
2091  pt, GetTrackMultiplicity(),GetEMCALClusters()->GetEntriesFast()));
2092  }
2093 
2094  if ( ptsumBin >= 0 )
2095  {
2096  AliDebug(1,Form("\t Sum bin %d [%2.2f,%2.2f]" , ptsumBin ,fBkgBinLimit[ptsumBin] ,fBkgBinLimit[ptsumBin +1]));
2097 
2098  fhSumPtConeBin[ptsumBin]->Fill(pt, GetEventWeight());
2099 
2100  if(fFillSSHisto) fhSumPtConeBinLambda0[ptsumBin]->Fill(pt, m02, GetEventWeight());
2101  }
2102 
2103  // Check if it was a decay
2104  if( fFillTaggedDecayHistograms && m02 < fDecayTagsM02Cut )
2105  {
2106  Int_t decayTag = pCandidate->DecayTag();
2107  if(decayTag < 0) decayTag = 0;
2108 
2109  for(Int_t ibit = 0; ibit < fNDecayBits; ibit++)
2110  {
2111  if(GetNeutralMesonSelection()->CheckDecayBit(decayTag,fDecayBits[ibit]))
2112  {
2113  Int_t leadptBinDecay = leadptBin+ibit*fNBkgBin;
2114  Int_t ptsumBinDecay = ptsumBin+ibit*fNBkgBin;
2115  if( leadptBin >=0 ) fhPtLeadConeBinDecay[leadptBinDecay]->Fill(pt, GetEventWeight());
2116  if( ptsumBin >=0 ) fhSumPtConeBinDecay [ ptsumBinDecay]->Fill(pt, GetEventWeight());
2117  }
2118  }
2119  }
2120 
2121  if(IsDataMC())
2122  {
2123  Int_t leadptBinMC = leadptBin+mcIndex*fNBkgBin;
2124  Int_t ptsumBinMC = ptsumBin+mcIndex*fNBkgBin;
2125 
2126  if( leadptBin >=0 )
2127  {
2128  fhPtLeadConeBinMC[leadptBinMC]->Fill(pt, GetEventWeight());
2129  if(fFillSSHisto) fhPtLeadConeBinLambda0MC[leadptBinMC]->Fill(pt, m02, GetEventWeight());
2130  }
2131 
2132  if( ptsumBin >=0 )
2133  {
2134  fhSumPtConeBinMC [ ptsumBinMC]->Fill(pt, GetEventWeight());
2135  if(fFillSSHisto) fhSumPtConeBinLambda0MC [ ptsumBinMC]->Fill(pt, m02, GetEventWeight());
2136  }
2137 
2138  if(GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton))
2139  {
2140  leadptBinMC = leadptBin+kmcPhoton*fNBkgBin;
2141  ptsumBinMC = ptsumBin+kmcPhoton*fNBkgBin;
2142  if( leadptBin >=0 )
2143  {
2144  fhPtLeadConeBinMC[leadptBinMC]->Fill(pt, GetEventWeight());
2145  if(fFillSSHisto) fhPtLeadConeBinLambda0MC[leadptBinMC]->Fill(pt, m02, GetEventWeight());
2146  }
2147 
2148  if( ptsumBin >=0 )
2149  {
2150  fhSumPtConeBinMC [ ptsumBinMC]->Fill(pt, GetEventWeight());
2151  if(fFillSSHisto) fhSumPtConeBinLambda0MC [ ptsumBinMC]->Fill(pt, m02, GetEventWeight());
2152  }
2153  }
2154 
2155  // Check if decay and if pair is lost
2156  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2157  {
2158  if ( mcIndex == kmcPi0Decay )
2159  {
2160  leadptBinMC = leadptBin+kmcPi0DecayLostPair*fNBkgBin;
2161  ptsumBinMC = ptsumBin+kmcPi0DecayLostPair*fNBkgBin;
2162  }
2163  else if(mcIndex == kmcEtaDecay)
2164  {
2165  leadptBinMC = leadptBin+kmcEtaDecayLostPair*fNBkgBin;
2166  ptsumBinMC = ptsumBin+kmcEtaDecayLostPair*fNBkgBin;
2167  }
2168  else
2169  AliFatal(Form("Lost decay Bit assigned to bad case, mcIndex %d",mcIndex));
2170 
2171  if( leadptBin >=0 )
2172  {
2173  fhPtLeadConeBinMC[leadptBinMC]->Fill(pt, GetEventWeight());
2174  if(fFillSSHisto) fhPtLeadConeBinLambda0MC[leadptBinMC]->Fill(pt, m02, GetEventWeight());
2175  }
2176 
2177  if( ptsumBin >=0 )
2178  {
2179  fhSumPtConeBinMC [ ptsumBinMC]->Fill(pt);
2180  if(fFillSSHisto) fhSumPtConeBinLambda0MC [ ptsumBinMC]->Fill(pt, m02, GetEventWeight());
2181  }
2182 
2183  } // check decays with lost pairs
2184 
2185  } // MC data
2186  } // background dependent bins
2187 
2188  // Fill histograms on selected pt bins of the trigger particle
2189  Int_t ptTrigBin = -1;
2190  if(fFillPtTrigBinHistograms)
2191  {
2192  for(Int_t ibin = 0; ibin < fNPtTrigBin; ibin++)
2193  {
2194  if( pt >= fPtTrigBinLimit[ibin] && pt < fPtTrigBinLimit[ibin+1]) ptTrigBin = ibin;
2195  }
2196 
2197  // Fill the histograms if the bin is found.
2198  if ( ptTrigBin >= 0 )
2199  {
2200  AliDebug(1,Form("Trigger pT %f, bin %d [%2.2f,%2.2f]",pt,ptTrigBin,fPtTrigBinLimit[ptTrigBin],fPtTrigBinLimit[ptTrigBin+1]));
2201 
2202  fhPtTrigBinPtLeadCone[ptTrigBin]->Fill(coneleadpt, GetEventWeight());
2203  fhPtTrigBinSumPtCone [ptTrigBin]->Fill(coneptsum , GetEventWeight());
2204 
2205  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2206  {
2207  fhPtTrigBinSumPtTrackCone [ptTrigBin]->Fill(coneptsumTrack, GetEventWeight());
2208  fhPtTrigBinSumPtClusterCone[ptTrigBin]->Fill(coneptsumClust, GetEventWeight());
2209  }
2210 
2211  if(fFillSSHisto)
2212  {
2213  fhPtTrigBinLambda0vsPtLeadCone[ptTrigBin]->Fill(coneleadpt, m02, GetEventWeight());
2214  fhPtTrigBinLambda0vsSumPtCone [ptTrigBin]->Fill(coneptsum , m02, GetEventWeight());
2215 
2216  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2217  {
2218  fhPtTrigBinLambda0vsSumPtTrackCone [ptTrigBin]->Fill(coneptsumTrack, m02, GetEventWeight());
2219  fhPtTrigBinLambda0vsSumPtClusterCone[ptTrigBin]->Fill(coneptsumClust, m02, GetEventWeight());
2220  }
2221  }
2222 
2223  // Check if it was a decay
2224  if( fFillTaggedDecayHistograms && m02 < fDecayTagsM02Cut )
2225  {
2226  Int_t decayTag = pCandidate->DecayTag();
2227  if(decayTag < 0) decayTag = 0;
2228 
2229  for(Int_t ibit = 0; ibit < fNDecayBits; ibit++)
2230  {
2231  if(GetNeutralMesonSelection()->CheckDecayBit(decayTag,fDecayBits[ibit]))
2232  {
2233  Int_t binDecay = ptTrigBin+ibit*fNPtTrigBin;
2234  if( binDecay > 0 )
2235  {
2236  fhPtTrigBinPtLeadConeDecay[binDecay]->Fill(coneleadpt, GetEventWeight());
2237  fhPtTrigBinSumPtConeDecay [binDecay]->Fill(coneptsum , GetEventWeight());
2238 
2239  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2240  {
2241  fhPtTrigBinSumPtTrackConeDecay [binDecay]->Fill(coneptsumTrack, GetEventWeight());
2242  fhPtTrigBinSumPtClusterConeDecay[binDecay]->Fill(coneptsumClust, GetEventWeight());
2243  }
2244  }
2245  }
2246  }
2247  } // decay
2248 
2249  if( IsDataMC() )
2250  {
2251  Int_t ptTrigBinMC = ptTrigBin+mcIndex*fNPtTrigBin;
2252 
2253  fhPtTrigBinPtLeadConeMC[ptTrigBinMC]->Fill(coneleadpt , GetEventWeight());
2254  fhPtTrigBinSumPtConeMC [ptTrigBinMC]->Fill(coneptsum , GetEventWeight());
2255 
2256  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2257  {
2258  fhPtTrigBinSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, GetEventWeight());
2259  fhPtTrigBinSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, GetEventWeight());
2260  }
2261 
2262  if(fFillSSHisto)
2263  {
2264  fhPtTrigBinLambda0vsPtLeadConeMC[ptTrigBinMC]->Fill(coneleadpt , m02, GetEventWeight());
2265  fhPtTrigBinLambda0vsSumPtConeMC [ptTrigBinMC]->Fill(coneptsum , m02, GetEventWeight());
2266 
2267  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2268  {
2269  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, m02, GetEventWeight());
2270  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, m02, GetEventWeight());
2271  }
2272  }
2273 
2274  if(GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton))
2275  {
2276  ptTrigBinMC = ptTrigBin+kmcPhoton*fNPtTrigBin;
2277 
2278  fhPtTrigBinPtLeadConeMC[ptTrigBinMC]->Fill(coneleadpt, GetEventWeight());
2279  fhPtTrigBinSumPtConeMC [ptTrigBinMC]->Fill(coneptsum , GetEventWeight());
2280 
2281  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2282  {
2283  fhPtTrigBinSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, GetEventWeight());
2284  fhPtTrigBinSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, GetEventWeight());
2285  }
2286 
2287  if(fFillSSHisto)
2288  {
2289  fhPtTrigBinLambda0vsPtLeadConeMC[ptTrigBinMC]->Fill(coneleadpt, m02, GetEventWeight());
2290  fhPtTrigBinLambda0vsSumPtConeMC [ptTrigBinMC]->Fill(coneptsum , m02, GetEventWeight());
2291 
2292  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2293  {
2294  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, m02, GetEventWeight());
2295  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, m02, GetEventWeight());
2296  }
2297  }
2298  } // photon MC
2299 
2300  // decays with lost pair
2301  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2302  {
2303  if ( mcIndex == kmcPi0Decay ) ptTrigBinMC = ptTrigBin+kmcPi0DecayLostPair*fNPtTrigBin;
2304  else if( mcIndex == kmcEtaDecay ) ptTrigBinMC = ptTrigBin+kmcEtaDecayLostPair*fNPtTrigBin;
2305 
2306  fhPtTrigBinPtLeadConeMC[ptTrigBinMC]->Fill(coneleadpt , GetEventWeight());
2307  fhPtTrigBinSumPtConeMC [ptTrigBinMC]->Fill(coneptsum , GetEventWeight());
2308 
2309  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2310  {
2311  fhPtTrigBinSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, GetEventWeight());
2312  fhPtTrigBinSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, GetEventWeight());
2313  }
2314 
2315  if(fFillSSHisto)
2316  {
2317  fhPtTrigBinLambda0vsPtLeadConeMC[ptTrigBinMC]->Fill(coneleadpt , m02, GetEventWeight());
2318  fhPtTrigBinLambda0vsSumPtConeMC [ptTrigBinMC]->Fill(coneptsum , m02, GetEventWeight());
2319 
2320  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2321  {
2322  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, m02, GetEventWeight());
2323  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, m02, GetEventWeight());
2324  }
2325  }
2326  } // lost decays MC
2327 
2328  } // MC
2329 
2330  } // proper pT bin found
2331  } // pT trigger bins
2332 
2333  //
2334  // Shower shape dependent histograms
2335  //
2336  if(fFillSSHisto)
2337  {
2338  //fhPtLambda0Eiso->Fill(pt, m02, coneptsum);
2339 
2340  fhELambda0 [isolated]->Fill(energy, m02, GetEventWeight());
2341  fhPtLambda0[isolated]->Fill(pt, m02, GetEventWeight());
2342  //fhELambda1 [isolated]->Fill(energy, m20);
2343 
2344  //
2345  // MC
2346  //
2347  if(IsDataMC())
2348  {
2349  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2350  fhPtLambda0MC[kmcPhoton][isolated]->Fill(pt, m02, GetEventWeight());
2351 
2352  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2353  {
2354  if ( mcIndex == kmcPi0Decay ) fhPtLambda0MC[kmcPi0DecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2355  else if( mcIndex == kmcEtaDecay ) fhPtLambda0MC[kmcEtaDecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2356  }
2357 
2358  fhPtLambda0MC[mcIndex][isolated]->Fill(pt, m02, GetEventWeight());
2359 
2360  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCConversion) )
2361  {
2362  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2363  fhPtLambda0MCConv[kmcPhoton][isolated]->Fill(pt, m02, GetEventWeight());
2364 
2365  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2366  {
2367  if ( mcIndex == kmcPi0Decay ) fhPtLambda0MCConv[kmcPi0DecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2368  else if( mcIndex == kmcEtaDecay ) fhPtLambda0MCConv[kmcEtaDecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2369  }
2370 
2371  fhPtLambda0MCConv[mcIndex][isolated]->Fill(pt, m02, GetEventWeight());
2372  } // Conversion
2373 
2374  //
2375  // Check overlaps
2376  //
2377  Int_t noverlaps = 0;
2378  if ( fFillOverlapHistograms && fCluster )
2379  {
2380  const UInt_t nlabels = fCluster->GetNLabels();
2381  Int_t overpdg[nlabels];
2382  Int_t overlab[nlabels];
2383  noverlaps = GetMCAnalysisUtils()->GetNOverlaps(fCluster->GetLabels(), nlabels, mcTag, -1,
2384  GetMC(), overpdg, overlab);
2385 
2386  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2387  fhPtNOverlap[kmcPhoton][isolated]->Fill(pt, noverlaps, GetEventWeight());
2388 
2389  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2390  {
2391  if ( mcIndex == kmcPi0Decay ) fhPtNOverlap[kmcPi0DecayLostPair][isolated]->Fill(pt, noverlaps, GetEventWeight());
2392  else if( mcIndex == kmcEtaDecay ) fhPtNOverlap[kmcEtaDecayLostPair][isolated]->Fill(pt, noverlaps, GetEventWeight());
2393  }
2394 
2395  fhPtNOverlap[mcIndex][isolated]->Fill(pt, noverlaps, GetEventWeight());
2396 
2397  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCConversion) )
2398  {
2399  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2400  fhPtNOverlapConv[kmcPhoton][isolated]->Fill(pt, noverlaps, GetEventWeight());
2401 
2402  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2403  {
2404  if ( mcIndex == kmcPi0Decay ) fhPtNOverlapConv[kmcPi0DecayLostPair][isolated]->Fill(pt, noverlaps, GetEventWeight());
2405  else if( mcIndex == kmcEtaDecay ) fhPtNOverlapConv[kmcEtaDecayLostPair][isolated]->Fill(pt, noverlaps, GetEventWeight());
2406  }
2407 
2408  fhPtNOverlapConv[mcIndex][isolated]->Fill(pt, noverlaps, GetEventWeight());
2409  } // Conversion
2410 
2411 
2412  if ( noverlaps == 1 )
2413  {
2414  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2415  fhPtLambda0MCWith1Overlap[kmcPhoton][isolated]->Fill(pt, m02, GetEventWeight());
2416 
2417  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2418  {
2419  if ( mcIndex == kmcPi0Decay ) fhPtLambda0MCWith1Overlap[kmcPi0DecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2420  else if( mcIndex == kmcEtaDecay ) fhPtLambda0MCWith1Overlap[kmcEtaDecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2421  }
2422 
2423  fhPtLambda0MCWith1Overlap[mcIndex][isolated]->Fill(pt, m02, GetEventWeight());
2424 
2425  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCConversion) )
2426  {
2427  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2428  fhPtLambda0MCConvWith1Overlap[kmcPhoton][isolated]->Fill(pt, m02, GetEventWeight());
2429 
2430  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2431  {
2432  if ( mcIndex == kmcPi0Decay ) fhPtLambda0MCConvWith1Overlap[kmcPi0DecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2433  else if( mcIndex == kmcEtaDecay ) fhPtLambda0MCConvWith1Overlap[kmcEtaDecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2434  }
2435 
2436  fhPtLambda0MCConvWith1Overlap[mcIndex][isolated]->Fill(pt, m02, GetEventWeight());
2437  } // Conversion
2438  } // At least 1 overlap
2439  else if (noverlaps == 0 ) // No overlap
2440  {
2441  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2442  fhPtLambda0MCWithNoOverlap[kmcPhoton][isolated]->Fill(pt, m02, GetEventWeight());
2443 
2444  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2445  {
2446  if ( mcIndex == kmcPi0Decay ) fhPtLambda0MCWithNoOverlap[kmcPi0DecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2447  else if( mcIndex == kmcEtaDecay ) fhPtLambda0MCWithNoOverlap[kmcEtaDecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2448  }
2449 
2450  fhPtLambda0MCWithNoOverlap[mcIndex][isolated]->Fill(pt, m02, GetEventWeight());
2451 
2452  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCConversion) )
2453  {
2454  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2455  fhPtLambda0MCConvWithNoOverlap[kmcPhoton][isolated]->Fill(pt, m02, GetEventWeight());
2456 
2457  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCDecayPairLost) )
2458  {
2459  if ( mcIndex == kmcPi0Decay ) fhPtLambda0MCConvWithNoOverlap[kmcPi0DecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2460  else if( mcIndex == kmcEtaDecay ) fhPtLambda0MCConvWithNoOverlap[kmcEtaDecayLostPair][isolated]->Fill(pt, m02, GetEventWeight());
2461  }
2462 
2463  fhPtLambda0MCConvWithNoOverlap[mcIndex][isolated]->Fill(pt, m02, GetEventWeight());
2464  } // Conversion
2465  } // more than 1 overlap
2466  }
2467 
2468  //
2469  // Sum in cone and shower shape in different pT bins of candidate and overlap condition
2470  //
2471  if(fFillPtTrigBinHistograms && fFillSSHisto)
2472  {
2473  Int_t ptTrigBinMC = ptTrigBin+mcIndex *fNPtTrigBin;
2474  Int_t ptTrigBinMCPhoton = ptTrigBin+kmcPhoton*fNPtTrigBin;
2475  Int_t ptTrigBinMCPi0Lost = ptTrigBin+kmcPi0DecayLostPair*fNPtTrigBin;
2476  Int_t ptTrigBinMCEtaLost = ptTrigBin+kmcEtaDecayLostPair*fNPtTrigBin;
2477 
2478  if ( ptTrigBin >= 0 )
2479  {
2480  fhPtTrigBinLambda0vsSumPtConeMC[ptTrigBinMC]->Fill(coneptsum, m02, GetEventWeight());
2481 
2482  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2483  {
2484  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMC]->Fill(coneptsumTrack, m02, GetEventWeight());
2485  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMC]->Fill(coneptsumClust, m02, GetEventWeight());
2486  }
2487 
2488  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2489  {
2490  fhPtTrigBinLambda0vsSumPtConeMC[ptTrigBinMCPhoton]->Fill(coneptsum, m02, GetEventWeight());
2491 
2492  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2493  {
2494  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMCPhoton]->Fill(coneptsumTrack, m02, GetEventWeight());
2495  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMCPhoton]->Fill(coneptsumClust, m02, GetEventWeight());
2496  }
2497  }
2498 
2499  if( mcIndex == kmcPi0Decay )
2500  {
2501  fhPtTrigBinLambda0vsSumPtConeMC[ptTrigBinMCPi0Lost]->Fill(coneptsum, m02, GetEventWeight());
2502 
2503  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2504  {
2505  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMCPi0Lost]->Fill(coneptsumTrack, m02, GetEventWeight());
2506  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMCPi0Lost]->Fill(coneptsumClust, m02, GetEventWeight());
2507  }
2508  }
2509 
2510  if( mcIndex == kmcEtaDecay )
2511  {
2512  fhPtTrigBinLambda0vsSumPtConeMC[ptTrigBinMCEtaLost]->Fill(coneptsum, m02, GetEventWeight());
2513 
2514  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2515  {
2516  fhPtTrigBinLambda0vsSumPtTrackConeMC [ptTrigBinMCEtaLost]->Fill(coneptsumTrack, m02, GetEventWeight());
2517  fhPtTrigBinLambda0vsSumPtClusterConeMC[ptTrigBinMCEtaLost]->Fill(coneptsumClust, m02, GetEventWeight());
2518  }
2519  }
2520 
2521  if(fFillOverlapHistograms)
2522  {
2523  if ( noverlaps == 0 )
2524  {
2525  fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[ptTrigBinMC]->Fill(coneptsum, m02, GetEventWeight());
2526 
2527  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2528  {
2529  fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap [ptTrigBinMC]->Fill(coneptsumTrack, m02, GetEventWeight());
2530  fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[ptTrigBinMC]->Fill(coneptsumClust, m02, GetEventWeight());
2531  }
2532 
2533  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2534  {
2535  fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[ptTrigBinMCPhoton]->Fill(coneptsum, m02, GetEventWeight());
2536 
2537  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2538  {
2539  fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap [ptTrigBinMCPhoton]->Fill(coneptsumTrack, m02, GetEventWeight());
2540  fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[ptTrigBinMCPhoton]->Fill(coneptsumClust, m02, GetEventWeight());
2541  }
2542  }
2543 
2544  if( mcIndex == kmcPi0Decay )
2545  {
2546  fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[ptTrigBinMCPi0Lost]->Fill(coneptsum, m02, GetEventWeight());
2547 
2548  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2549  {
2550  fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap [ptTrigBinMCPi0Lost]->Fill(coneptsumTrack, m02, GetEventWeight());
2551  fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[ptTrigBinMCPi0Lost]->Fill(coneptsumClust, m02, GetEventWeight());
2552  }
2553  }
2554 
2555  if( mcIndex == kmcEtaDecay )
2556  {
2557  fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[ptTrigBinMCEtaLost]->Fill(coneptsum, m02, GetEventWeight());
2558 
2559  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2560  {
2561  fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap [ptTrigBinMCEtaLost]->Fill(coneptsumTrack, m02, GetEventWeight());
2562  fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[ptTrigBinMCEtaLost]->Fill(coneptsumClust, m02, GetEventWeight());
2563  }
2564  }
2565 
2566 
2567  } // nover = 0
2568  else if ( noverlaps == 1 )
2569  {
2570  fhPtTrigBinLambda0vsSumPtConeMC1Overlap[ptTrigBinMC]->Fill(coneptsum, m02, GetEventWeight());
2571  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2572  {
2573  fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap [ptTrigBinMC]->Fill(coneptsumTrack, m02, GetEventWeight());
2574  fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[ptTrigBinMC]->Fill(coneptsumClust, m02, GetEventWeight());
2575  }
2576 
2577  if( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) )
2578  {
2579  fhPtTrigBinLambda0vsSumPtConeMC1Overlap[ptTrigBinMCPhoton]->Fill(coneptsum, m02, GetEventWeight());
2580 
2581  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2582  {
2583  fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap [ptTrigBinMCPhoton]->Fill(coneptsumTrack, m02, GetEventWeight());
2584  fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[ptTrigBinMCPhoton]->Fill(coneptsumClust, m02, GetEventWeight());
2585  }
2586 
2587  if( mcIndex == kmcPi0Decay )
2588  {
2589  fhPtTrigBinLambda0vsSumPtConeMC1Overlap[ptTrigBinMCPi0Lost]->Fill(coneptsum, m02, GetEventWeight());
2590 
2591  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2592  {
2593  fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap [ptTrigBinMCPi0Lost]->Fill(coneptsumTrack, m02, GetEventWeight());
2594  fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[ptTrigBinMCPi0Lost]->Fill(coneptsumClust, m02, GetEventWeight());
2595  }
2596  }
2597 
2598  if( mcIndex == kmcEtaDecay )
2599  {
2600  fhPtTrigBinLambda0vsSumPtConeMC1Overlap[ptTrigBinMCEtaLost]->Fill(coneptsum, m02, GetEventWeight());
2601 
2602  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
2603  {
2604  fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap [ptTrigBinMCEtaLost]->Fill(coneptsumTrack, m02, GetEventWeight());
2605  fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[ptTrigBinMCEtaLost]->Fill(coneptsumClust, m02, GetEventWeight());
2606  }
2607  }
2608  }
2609  } // nover = 1
2610  } // fill overlaps
2611 
2612  } // pt bin exists
2613  } // fFillPtTrigBinHistograms && fFillSSHisto
2614 
2615  } // MC
2616 
2617  if(GetCalorimeter() == kEMCAL && GetFirstSMCoveredByTRD() >= 0 &&
2618  GetModuleNumber(pCandidate) >= GetFirstSMCoveredByTRD() )
2619  {
2620  fhELambda0TRD [isolated]->Fill(energy, m02, GetEventWeight());
2621  fhPtLambda0TRD[isolated]->Fill(pt , m02, GetEventWeight());
2622  //fhELambda1TRD [isolated]->Fill(energy, m20 );
2623  }
2624 
2625  if(fFillNLMHistograms)
2626  {
2627  fhNLocMax[isolated]->Fill(energy, nMaxima, GetEventWeight());
2628  if (nMaxima==1)
2629  {
2630  fhELambda0LocMax1[isolated]->Fill(energy, m02, GetEventWeight());
2631  fhELambda1LocMax1[isolated]->Fill(energy, m02, GetEventWeight());
2632  }
2633  else if(nMaxima==2)
2634  {
2635  fhELambda0LocMax2[isolated]->Fill(energy, m02, GetEventWeight());
2636  fhELambda1LocMax2[isolated]->Fill(energy, m02, GetEventWeight());
2637  }
2638  else
2639  {
2640  fhELambda0LocMaxN[isolated]->Fill(energy, m02, GetEventWeight());
2641  fhELambda1LocMaxN[isolated]->Fill(energy, m02, GetEventWeight());
2642  }
2643  }
2644  } // SS histo fill
2645 
2646  // Track matching dependent histograms
2647  if ( fFillTMHisto && fCluster )
2648  {
2649  Float_t dZ = fCluster->GetTrackDz();
2650  Float_t dR = fCluster->GetTrackDx();
2651 
2652 // if(fCluster->IsEMCAL() && GetCaloUtils()->IsRecalculationOfClusterTrackMatchingOn())
2653 // {
2654 // dR = 2000., dZ = 2000.;
2655 // GetCaloUtils()->GetEMCALRecoUtils()->GetMatchedResiduals(fCluster->GetID(),dZ,dR);
2656 // }
2657 
2658  //printf("ParticleIsolation: dPhi %f, dEta %f\n",dR,dZ);
2659  if(fhTrackMatchedDEta[isolated] && TMath::Abs(dR) < 999)
2660  {
2661  fhTrackMatchedDEta[isolated]->Fill(energy, dZ, GetEventWeight());
2662  fhTrackMatchedDPhi[isolated]->Fill(energy, dR, GetEventWeight());
2663  if(energy > 0.5) fhTrackMatchedDEtaDPhi[isolated]->Fill(dZ, dR, GetEventWeight());
2664  if(IsDataMC())
2665  {
2666  fhTrackMatchedDEtaMC[mcIndex][isolated]->Fill(energy, dZ, GetEventWeight());
2667  fhTrackMatchedDPhiMC[mcIndex][isolated]->Fill(energy, dR, GetEventWeight());
2668  if(energy > 0.5) fhTrackMatchedDEtaDPhiMC[mcIndex][isolated]->Fill(dZ, dR, GetEventWeight());
2669  }
2670  }
2671 
2672  // Check dEdx and E/p of matched clusters
2673 
2674  if(TMath::Abs(dZ) < 0.05 && TMath::Abs(dR) < 0.05)
2675  {
2676  AliVTrack *track = GetCaloUtils()->GetMatchedTrack(fCluster, GetReader()->GetInputEvent());
2677 
2678  if(track)
2679  {
2680  Float_t dEdx = track->GetTPCsignal();
2681  fhdEdx[isolated]->Fill(fCluster->E(), dEdx, GetEventWeight());
2682 
2683  Float_t eOverp = fCluster->E()/track->P();
2684  fhEOverP[isolated]->Fill(fCluster->E(), eOverp, GetEventWeight());
2685  }
2686  //else
2687  // printf("AliAnaParticleIsolation::FillTrackMatchingShowerShapeHistograms() - Residual OK but (dR, dZ)= (%2.4f,%2.4f) no track associated WHAT? \n", dR,dZ);
2688 
2689 
2690  if(IsDataMC())
2691  {
2692  if ( !GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCConversion) )
2693  {
2694  if ( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPi0) ||
2695  GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCEta) ) fhTrackMatchedMCParticle[isolated]->Fill(energy, 2.5, GetEventWeight());
2696  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) ) fhTrackMatchedMCParticle[isolated]->Fill(energy, 0.5, GetEventWeight());
2697  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCElectron) ) fhTrackMatchedMCParticle[isolated]->Fill(energy, 1.5, GetEventWeight());
2698  else fhTrackMatchedMCParticle[isolated]->Fill(energy, 3.5, GetEventWeight());
2699 
2700  }
2701  else
2702  {
2703  if ( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPi0) ||
2704  GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCEta) ) fhTrackMatchedMCParticle[isolated]->Fill(energy, 6.5, GetEventWeight());
2705  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCPhoton) ) fhTrackMatchedMCParticle[isolated]->Fill(energy, 4.5, GetEventWeight());
2706  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag,AliMCAnalysisUtils::kMCElectron) ) fhTrackMatchedMCParticle[isolated]->Fill(energy, 5.5, GetEventWeight());
2707  else fhTrackMatchedMCParticle[isolated]->Fill(energy, 7.5, GetEventWeight());
2708  }
2709  } // MC
2710  } // match window
2711  }// TM histos fill
2712 }
2713 
2714 //______________________________________________________
2716 //______________________________________________________
2718 {
2719  TString parList ; //this will be list of parameters used for this analysis.
2720  const Int_t buffersize = 255;
2721  char onePar[buffersize] ;
2722 
2723  snprintf(onePar, buffersize,"--- AliAnaParticleIsolation ---:") ;
2724  parList+=onePar ;
2725  snprintf(onePar, buffersize,"Calorimeter: %s;",GetCalorimeterString().Data()) ;
2726  parList+=onePar ;
2727  snprintf(onePar, buffersize,"Isolation Cand. Detector: %s;",fIsoDetectorString.Data()) ;
2728  parList+=onePar ;
2729  snprintf(onePar, buffersize,"Fill histo UE %d",fFillUEBandSubtractHistograms) ;
2730  parList+=onePar ;
2731  snprintf(onePar, buffersize,"fReMakeIC =%d (Flag for reisolation during histogram filling);",fReMakeIC) ;
2732  parList+=onePar ;
2733  snprintf(onePar, buffersize,"fMakeSeveralIC=%d (Flag for isolation with several cuts at the same time );",fMakeSeveralIC) ;
2734  parList+=onePar ;
2735  snprintf(onePar, buffersize,"fFillTMHisto=%d (Flag for track matching histograms);",fFillTMHisto) ;
2736  parList+=onePar ;
2737  snprintf(onePar, buffersize,"fFillSSHisto=%d (Flag for shower shape histograms);",fFillSSHisto) ;
2738  parList+=onePar ;
2739 
2740  if(fMakeSeveralIC)
2741  {
2742  snprintf(onePar, buffersize,"fNCones =%d (Number of cone sizes);",fNCones) ;
2743  parList+=onePar ;
2744  snprintf(onePar, buffersize,"fNPtThresFrac=%d (Flag for isolation with several cuts at the same time);",fNPtThresFrac) ;
2745  parList+=onePar ;
2746 
2747  for(Int_t icone = 0; icone < fNCones ; icone++)
2748  {
2749  snprintf(onePar, buffersize,"fConeSizes[%d]=%1.2f (isolation cone size);",icone, fConeSizes[icone]) ;
2750  parList+=onePar ;
2751  }
2752  for(Int_t ipt = 0; ipt < fNPtThresFrac ; ipt++)
2753  {
2754  snprintf(onePar, buffersize,"fPtThresholds[%d]=%1.2f (isolation pt threshold);",ipt, fPtThresholds[ipt]) ;
2755  parList+=onePar ;
2756  }
2757  for(Int_t ipt = 0; ipt < fNPtThresFrac ; ipt++)
2758  {
2759  snprintf(onePar, buffersize,"fPtFractions[%d]=%1.2f (isolation pt fraction threshold);",ipt, fPtFractions[ipt]) ;
2760  parList+=onePar ;
2761  }
2762  for(Int_t ipt = 0; ipt < fNPtThresFrac ; ipt++)
2763  {
2764  snprintf(onePar, buffersize,"fSumPtThresholds[%d]=%1.2f (isolation sum pt threshold);",ipt, fSumPtThresholds[ipt]) ;
2765  parList+=onePar ;
2766  }
2767  }
2768 
2769  //Get parameters set in base class.
2770  parList += GetBaseParametersList() ;
2771 
2772  //Get parameters set in IC class.
2773  if(!fMakeSeveralIC)parList += GetIsolationCut()->GetICParametersList() ;
2774 
2775  return new TObjString(parList) ;
2776 }
2777 
2778 //________________________________________________________
2781 //________________________________________________________
2783 {
2784  TList * outputContainer = new TList() ;
2785  outputContainer->SetName("IsolatedParticleHistos") ;
2786 
2788  Int_t nphibins = GetHistogramRanges()->GetHistoPhiBins();
2789  Int_t netabins = GetHistogramRanges()->GetHistoEtaBins();
2799  Int_t ntimebins= GetHistogramRanges()->GetHistoTimeBins();
2802 
2809 
2810  Int_t ndedxbins = GetHistogramRanges()->GetHistodEdxBins();
2813  Int_t nPoverEbins = GetHistogramRanges()->GetHistoPOverEBins();
2814  Float_t pOverEmax = GetHistogramRanges()->GetHistoPOverEMax();
2815  Float_t pOverEmin = GetHistogramRanges()->GetHistoPOverEMin();
2816 
2817  Int_t nptsumbins = GetHistogramRanges()->GetHistoNPtSumBins();
2820  Int_t nptinconebins = GetHistogramRanges()->GetHistoNPtInConeBins();
2821  Float_t ptinconemax = GetHistogramRanges()->GetHistoPtInConeMax();
2822  Float_t ptinconemin = GetHistogramRanges()->GetHistoPtInConeMin();
2823 
2827 
2828  // Init the number of modules, set in the class AliCalorimeterUtils
2829  //
2830  InitCaloParameters(); // See AliCaloTrackCorrBaseClass
2831 
2832  //Float_t ptthre = GetIsolationCut()->GetPtThreshold();
2833  //Float_t ptsumthre = GetIsolationCut()->GetSumPtThreshold();
2834  //Float_t ptfrac = GetIsolationCut()->GetPtFraction();
2837  Int_t particle = GetIsolationCut()->GetParticleTypeInCone() ;
2838 
2839  TString sThreshold = "";
2840  if ( method == AliIsolationCut::kSumPtIC )
2841  {
2842  sThreshold = Form(", %2.2f < #Sigma #it{p}_{T}^{in cone} < %2.2f GeV/#it{c}",
2843  GetIsolationCut()->GetSumPtThreshold(), GetIsolationCut()->GetSumPtThresholdMax());
2844  if(GetIsolationCut()->GetSumPtThresholdMax() > 200)
2845  sThreshold = Form(", #Sigma #it{p}_{T}^{in cone} = %2.2f GeV/#it{c}",
2846  GetIsolationCut()->GetSumPtThreshold());
2847  }
2848  else if ( method == AliIsolationCut::kPtThresIC)
2849  {
2850  sThreshold = Form(", %2.2f < #it{p}_{T}^{th} < %2.2f GeV/#it{c}",
2851  GetIsolationCut()->GetPtThreshold(),GetIsolationCut()->GetPtThresholdMax());
2852  if(GetIsolationCut()->GetSumPtThreshold() > 200)
2853  sThreshold = Form(", #it{p}_{T}^{th} = %2.2f GeV/#it{c}",
2854  GetIsolationCut()->GetPtThreshold());
2855  }
2856  else if ( method == AliIsolationCut::kPtFracIC)
2857  sThreshold = Form(", #Sigma #it{p}_{T}^{in cone}/#it{p}_{T}^{trig} = %2.2f" ,
2858  GetIsolationCut()->GetPtFraction());
2859 
2860  TString sParticle = ", x^{0,#pm}";
2861  if ( particle == AliIsolationCut::kOnlyNeutral ) sParticle = ", x^{0}";
2862  else if ( particle == AliIsolationCut::kOnlyCharged ) sParticle = ", x^{#pm}";
2863 
2864  TString parTitle = Form("#it{R} = %2.2f%s%s" ,GetIsolationCut()->GetConeSize(),sThreshold.Data(),sParticle.Data());
2865  TString parTitleR = Form("#it{R} = %2.2f%s" ,GetIsolationCut()->GetConeSize(),sParticle.Data());
2866  TString parTitleRCh = Form("#it{R} = %2.2f, x^{#pm}",GetIsolationCut()->GetConeSize());
2867  TString parTitleRNe = Form("#it{R} = %2.2f, x^{0}" ,GetIsolationCut()->GetConeSize());
2868 
2869  TString pileUpName[] = {"SPD","EMCAL","SPDOrEMCAL","SPDAndEMCAL","SPDAndNotEMCAL","EMCALAndNotSPD","NotSPDAndNotEMCAL"} ;
2870 
2871  // MC histograms title and name
2872  TString mcPartType[] = { "#gamma" , "#gamma_{prompt}" , "#gamma_{fragmentation}",
2873  "#pi^{0} (merged #gamma)", "#gamma_{#pi decay}" , "#gamma_{#pi decay} lost companion",
2874  "#eta (merged #gamma)" , "#gamma_{#eta decay}", "#gamma_{#eta decay} lost companion",
2875  "#gamma_{other decay}" , "e^{#pm}" , "hadrons?"} ;
2876 
2877  TString mcPartName[] = { "Photon","PhotonPrompt","PhotonFrag",
2878  "Pi0" ,"Pi0Decay" ,"Pi0DecayLostPair",
2879  "Eta" ,"EtaDecay" ,"EtaDecayLostPair",
2880  "OtherDecay","Electron","Hadron"} ;
2881 
2882  // Primary MC histograms title and name
2883  TString pptype[] = { "#gamma" , "#gamma_{#pi decay}" , "#gamma_{#eta decay}", "#gamma_{other decay}",
2884  "#gamma_{prompt}", "#gamma_{fragmentation}", "#gamma_{ISR}" ,
2885  "#pi^{0}" , "#eta"} ;
2886 
2887  TString ppname[] = { "Photon" , "PhotonPi0Decay","PhotonEtaDecay", "PhotonOtherDecay",
2888  "PhotonPrompt", "PhotonFrag" , "PhotonISR" ,
2889  "Pi0" , "Eta"} ;
2890 
2891  // Not Isolated histograms, reference histograms
2892 
2893  fhENoIso = new TH1F("hENoIso",
2894  Form("Number of not isolated leading particles vs #it{p}_{T}, %s",parTitle.Data()),
2895  nptbins,ptmin,ptmax);
2896  fhENoIso->SetYTitle("#it{counts}");
2897  fhENoIso->SetXTitle("E (GeV/#it{c})");
2898  outputContainer->Add(fhENoIso) ;
2899 
2900  fhPtNoIso = new TH1F("hPtNoIso",
2901  Form("Number of not isolated leading particles vs #it{p}_{T}, %s",parTitle.Data()),
2902  nptbins,ptmin,ptmax);
2903  fhPtNoIso->SetYTitle("#it{counts}");
2904  fhPtNoIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
2905  outputContainer->Add(fhPtNoIso) ;
2906 
2908  {
2909  fhENoIsoExoTrigger = new TH1F
2910  ("hENoIsoExoTrigger",
2911  Form("Number of not isolated particles vs E, %s, exot>0.97",parTitle.Data()),
2912  nptbins,ptmin,ptmax);
2913  fhENoIsoExoTrigger->SetYTitle("d#it{N} / d#it{E}");
2914  fhENoIsoExoTrigger->SetXTitle("#it{E} (GeV/#it{c})");
2915  outputContainer->Add(fhENoIsoExoTrigger) ;
2916 
2917  fhPtNoIsoExoTrigger = new TH1F
2918  ("hPtNoIsoExoTrigger",
2919  Form("Number of not isolated particles vs #it{p}_{T}, %s, exot>0.97",parTitle.Data()),
2920  nptbins,ptmin,ptmax);
2921  fhPtNoIsoExoTrigger->SetYTitle("d#it{N} / #it{p}_{T}");
2922  fhPtNoIsoExoTrigger->SetXTitle("#it{p}_{T} (GeV/#it{c})");
2923  outputContainer->Add(fhPtNoIsoExoTrigger) ;
2924  }
2925 
2926  fhEtaPhiNoIso = new TH2F("hEtaPhiNoIso",
2927  Form("Number of not isolated leading particles #eta vs #varphi, %s",parTitle.Data()),
2928  netabins,etamin,etamax,nphibins,phimin,phimax);
2929  fhEtaPhiNoIso->SetXTitle("#eta");
2930  fhEtaPhiNoIso->SetYTitle("#varphi (rad)");
2931  outputContainer->Add(fhEtaPhiNoIso) ;
2932 
2933  if(IsDataMC())
2934  {
2935  // For histograms in arrays, index in the array, corresponding to any particle origin
2936 
2937  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
2938  {
2939  fhPtNoIsoMC[imc] = new TH1F(Form("hPtNoIsoMC%s",mcPartName[imc].Data()),
2940  Form("#it{p}_{T} of NOT isolated %s, %s",mcPartType[imc].Data(),parTitle.Data()),
2941  nptbins,ptmin,ptmax);
2942  fhPtNoIsoMC[imc]->SetYTitle("#it{counts}");
2943  fhPtNoIsoMC[imc]->SetXTitle("#it{p}_{T}(GeV/#it{c})");
2944  outputContainer->Add(fhPtNoIsoMC[imc]) ;
2945 
2946  fhPtIsoMC[imc] = new TH1F(Form("hPtMC%s",mcPartName[imc].Data()),
2947  Form("#it{p}_{T} of isolated %s, %s",mcPartType[imc].Data(),parTitle.Data()),
2948  nptbins,ptmin,ptmax);
2949  fhPtIsoMC[imc]->SetYTitle("#it{counts}");
2950  fhPtIsoMC[imc]->SetXTitle("#it{p}_{T}(GeV/#it{c})");
2951  outputContainer->Add(fhPtIsoMC[imc]) ;
2952 
2953  fhPhiIsoMC[imc] = new TH2F(Form("hPhiMC%s",mcPartName[imc].Data()),
2954  Form("#varphi vs #it{p}_{T} of isolated %s, %s",mcPartType[imc].Data(),parTitle.Data()),
2955  nptbins,ptmin,ptmax,nphibins,phimin,phimax);
2956  fhPhiIsoMC[imc]->SetYTitle("#varphi (rad)");
2957  fhPhiIsoMC[imc]->SetXTitle("#it{p}_{T}(GeV/#it{c})");
2958  outputContainer->Add(fhPhiIsoMC[imc]) ;
2959 
2960  fhEtaIsoMC[imc] = new TH2F(Form("hEtaMC%s",mcPartName[imc].Data()),
2961  Form("#eta vs #it{p}_{T} of isolated %s, %s",mcPartType[imc].Data(),parTitle.Data()),
2962  nptbins,ptmin,ptmax,netabins,etamin,etamax);
2963  fhEtaIsoMC[imc]->SetYTitle("#eta");
2964  fhEtaIsoMC[imc]->SetXTitle("#it{p}_{T}(GeV/#it{c})");
2965  outputContainer->Add(fhEtaIsoMC[imc]) ;
2966  }
2967  }
2968 
2969  // Histograms for tagged candidates as decay
2971  {
2972  TString isoName [] = {"NoIso","Iso"};
2973  TString isoTitle[] = {"Not isolated" ,"isolated"};
2974 
2975  for(Int_t ibit = 0; ibit < fNDecayBits; ibit++)
2976  {
2977  for(Int_t iso = 0; iso < 2; iso++)
2978  {
2979  if(fMakeSeveralIC && iso) continue;
2980  fhPtDecay[iso][ibit] =
2981  new TH1F(Form("hPtDecay%s_bit%d",isoName[iso].Data(),fDecayBits[ibit]),
2982  Form("Number of %s leading pi0 decay particles vs #it{p}_{T}, bit %d, %s",isoTitle[iso].Data(),fDecayBits[ibit],parTitle.Data()),
2983  nptbins,ptmin,ptmax);
2984  fhPtDecay[iso][ibit]->SetYTitle("#it{counts}");
2985  fhPtDecay[iso][ibit]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
2986  outputContainer->Add(fhPtDecay[iso][ibit]) ;
2987 
2988  fhEtaPhiDecay[iso][ibit] =
2989  new TH2F(Form("hEtaPhiDecay%s_bit%d",isoName[iso].Data(),fDecayBits[ibit]),
2990  Form("Number of %s leading Pi0 decay particles #eta vs #varphi, bit %d, %s",isoTitle[iso].Data(),fDecayBits[ibit],parTitle.Data()),
2991  netabins,etamin,etamax,nphibins,phimin,phimax);
2992  fhEtaPhiDecay[iso][ibit]->SetXTitle("#eta");
2993  fhEtaPhiDecay[iso][ibit]->SetYTitle("#varphi (rad)");
2994  outputContainer->Add(fhEtaPhiDecay[iso][ibit]) ;
2995 
2996  if(fFillSSHisto)
2997  {
2998  fhPtLambda0Decay[iso][ibit] = new TH2F
2999  (Form("hPtLambda0Decay%s_bit%d",isoName[iso].Data(),fDecayBits[ibit]),
3000  Form("%s cluster : #it{p}_{T} vs #lambda_{0}, decay bit %d, %s",isoTitle[iso].Data(), fDecayBits[ibit], parTitle.Data()),
3001  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3002  fhPtLambda0Decay[iso][ibit]->SetYTitle("#lambda_{0}^{2}");
3003  fhPtLambda0Decay[iso][ibit]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3004  outputContainer->Add(fhPtLambda0Decay[iso][ibit]) ;
3005  }
3006 
3007  if(IsDataMC())
3008  {
3009  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
3010  {
3011  fhPtDecayMC[iso][ibit][imc] =
3012  new TH1F(Form("hPtDecay%s_bit%d_MC%s",isoName[iso].Data(),fDecayBits[ibit],mcPartName[imc].Data()),
3013  Form("#it{p}_{T} of %s, decay bit %d, %s, %s",isoTitle[iso].Data(),fDecayBits[ibit],mcPartType[imc].Data(),parTitle.Data()),
3014  nptbins,ptmin,ptmax);
3015  fhPtDecayMC[iso][ibit][imc]->SetYTitle("#it{counts}");
3016  fhPtDecayMC[iso][ibit][imc]->SetXTitle("#it{p}_{T}(GeV/#it{c})");
3017  outputContainer->Add(fhPtDecayMC[iso][ibit][imc]) ;
3018  }// MC particle loop
3019  }// MC
3020  } // bit loop
3021  } //iso loop
3022  }// decay
3023 
3024  if(!fMakeSeveralIC)
3025  {
3026  TString isoName [] = {"NoIso","Iso"};
3027  TString isoTitle[] = {"Not isolated" ,"isolated"};
3028 
3029  fhEIso = new TH1F("hE",
3030  Form("Number of isolated particles vs E, %s",parTitle.Data()),
3031  nptbins,ptmin,ptmax);
3032  fhEIso->SetYTitle("d#it{N} / d#it{E}");
3033  fhEIso->SetXTitle("#it{E} (GeV/#it{c})");
3034  outputContainer->Add(fhEIso) ;
3035 
3036  fhPtIso = new TH1F("hPt",
3037  Form("Number of isolated particles vs #it{p}_{T}, %s",parTitle.Data()),
3038  nptbins,ptmin,ptmax);
3039  fhPtIso->SetYTitle("d#it{N} / #it{p}_{T}");
3040  fhPtIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3041  outputContainer->Add(fhPtIso) ;
3042 
3044  {
3045  fhEIsoExoTrigger = new TH1F
3046  ("hEIsoExoTrigger",
3047  Form("Number of isolated particles vs E, %s, exot>0.97",parTitle.Data()),
3048  nptbins,ptmin,ptmax);
3049  fhEIsoExoTrigger->SetYTitle("d#it{N} / d#it{E}");
3050  fhEIsoExoTrigger->SetXTitle("#it{E} (GeV/#it{c})");
3051  outputContainer->Add(fhEIsoExoTrigger) ;
3052 
3053  fhPtIsoExoTrigger = new TH1F
3054  ("hPtIsoExoTrigger",
3055  Form("Number of isolated particles vs #it{p}_{T}, %s, exot>0.97",parTitle.Data()),
3056  nptbins,ptmin,ptmax);
3057  fhPtIsoExoTrigger->SetYTitle("d#it{N} / #it{p}_{T}");
3058  fhPtIsoExoTrigger->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3059  outputContainer->Add(fhPtIsoExoTrigger) ;
3060  }
3061 
3062  fhPhiIso = new TH2F("hPhi",
3063  Form("Number of isolated particles vs #varphi, %s",parTitle.Data()),
3064  nptbins,ptmin,ptmax,nphibins,phimin,phimax);
3065  fhPhiIso->SetYTitle("#varphi (rad)");
3066  fhPhiIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3067  outputContainer->Add(fhPhiIso) ;
3068 
3069  fhEtaIso = new TH2F("hEta",
3070  Form("Number of isolated particles vs #eta, %s",parTitle.Data()),
3071  nptbins,ptmin,ptmax,netabins,etamin,etamax);
3072  fhEtaIso->SetYTitle("#eta");
3073  fhEtaIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3074  outputContainer->Add(fhEtaIso) ;
3075 
3076  fhEtaPhiIso = new TH2F("hEtaPhiIso",
3077  Form("Number of isolated particles #eta vs #varphi, %s",parTitle.Data()),
3078  netabins,etamin,etamax,nphibins,phimin,phimax);
3079  fhEtaPhiIso->SetXTitle("#eta");
3080  fhEtaPhiIso->SetYTitle("#varphi (rad)");
3081  outputContainer->Add(fhEtaPhiIso) ;
3082 
3084  {
3085  fhPtCentralityIso = new TH2F("hPtCentrality",
3086  Form("centrality vs #it{p}_{T} for isolated particles, %s",parTitle.Data()),
3087  nptbins,ptmin,ptmax, 100,0,100);
3088  fhPtCentralityIso->SetYTitle("centrality");
3089  fhPtCentralityIso->SetXTitle("#it{p}_{T}(GeV/#it{c})");
3090  outputContainer->Add(fhPtCentralityIso) ;
3091 
3092  fhPtEventPlaneIso = new TH2F("hPtEventPlane",
3093  Form("event plane angle vs #it{p}_{T} for isolated particles, %s",parTitle.Data()),
3094  nptbins,ptmin,ptmax, 100,0,TMath::Pi());
3095  fhPtEventPlaneIso->SetYTitle("Event plane angle (rad)");
3096  fhPtEventPlaneIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3097  outputContainer->Add(fhPtEventPlaneIso) ;
3098  }
3099 
3100  if(fFillNLMHistograms)
3101  {
3102  fhPtNLocMaxIso = new TH2F("hPtNLocMax",
3103  Form("Number of isolated particles vs #it{p}_{T}, %s",parTitle.Data()),
3104  nptbins,ptmin,ptmax,10,0,10);
3105  fhPtNLocMaxIso->SetYTitle("#it{NLM}");
3106  fhPtNLocMaxIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3107 
3108  fhPtNLocMaxNoIso = new TH2F("hPtNLocMaxNoIso",
3109  Form("Number of not isolated particles vs #it{p}_{T}, %s",parTitle.Data()),
3110  nptbins,ptmin,ptmax,10,0,10);
3111  fhPtNLocMaxNoIso->SetYTitle("#it{NLM}");
3112  fhPtNLocMaxNoIso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3113  outputContainer->Add(fhPtNLocMaxNoIso) ;
3114  }
3115 
3116  fhConePtLead = new TH2F("hConePtLead",
3117  Form("Track or Cluster leading #it{p}_{T} in isolation cone for #it{R} = %2.2f",r),
3118  nptbins,ptmin,ptmax,nptbins,ptmin,ptmax);
3119  fhConePtLead->SetYTitle("#it{p}_{T, leading} (GeV/#it{c})");
3120  fhConePtLead->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3121  outputContainer->Add(fhConePtLead) ;
3122 
3123  fhConeSumPt = new TH2F
3124  ("hConePtSum",
3125  Form("Track and Cluster #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f",r),
3126  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3127  fhConeSumPt->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3128  fhConeSumPt->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3129  outputContainer->Add(fhConeSumPt) ;
3130 
3132  {
3134  ("hConePtSumExoTrigger",
3135  Form("#Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, exo trigger",r),
3136  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3137  fhConeSumPtExoTrigger->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3138  fhConeSumPtExoTrigger->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3139  outputContainer->Add(fhConeSumPtExoTrigger) ;
3140  }
3141 
3142 // fhPtLambda0Eiso = new TH3F
3143 // (Form("hPtLambda0Eiso"),
3144 // Form("ABCD 3D Matrix: #it{p}_{T} vs #lambda_{0}^{2} vs E_{T}^{iso}, %s",parTitle.Data()),70,0.,70.,200,0.,2.,110,-10.,100.);
3145 // fhPtLambda0Eiso->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3146 // fhPtLambda0Eiso->SetYTitle("#lambda_{0}^{2}");
3147 // fhPtLambda0Eiso->SetZTitle("E_{T}^{iso} (GeV/#it{c})");
3148 // outputContainer->Add(fhPtLambda0Eiso) ;
3149 
3150  fhConeSumPtTrigEtaPhi = new TH2F("hConePtSumTrigEtaPhi",
3151  Form("Trigger #eta vs #varphi, #Sigma #it{p}_{T} in isolation cone for %s",parTitleR.Data()),
3152  netabins,etamin,etamax,nphibins,phimin,phimax);
3153  fhConeSumPtTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3154  fhConeSumPtTrigEtaPhi->SetXTitle("#eta_{trigger}");
3155  fhConeSumPtTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
3156  outputContainer->Add(fhConeSumPtTrigEtaPhi) ;
3157 
3158  fhPtInCone = new TH2F("hPtInCone",
3159  Form("#it{p}_{T} of clusters and tracks in isolation cone for %s",parTitleR.Data()),
3160  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
3161  fhPtInCone->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
3162  fhPtInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3163  outputContainer->Add(fhPtInCone) ;
3164 
3166  {
3167  fhPtInConeExoTrigger = new TH2F("hPtInConeExoTrigger",
3168  Form("#it{p}_{T} in isolation cone for %s, exotic trigger",parTitleR.Data()),
3169  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
3170  fhPtInConeExoTrigger->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
3171  fhPtInConeExoTrigger->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3172  outputContainer->Add(fhPtInConeExoTrigger) ;
3173  }
3174 
3176  {
3177  fhPtLeadConeBin = new TH1F*[fNBkgBin];
3178  fhSumPtConeBin = new TH1F*[fNBkgBin];
3179  if(fFillSSHisto)
3180  {
3183  }
3184 
3186  {
3189  }
3190 
3191  if(IsDataMC())
3192  {
3193  fhPtLeadConeBinMC = new TH1F*[fNBkgBin*fgkNmcTypes];
3194  fhSumPtConeBinMC = new TH1F*[fNBkgBin*fgkNmcTypes];
3195 
3196  if(fFillSSHisto)
3197  {
3200  }
3201  }
3202 
3203  for(Int_t ibin = 0; ibin < fNBkgBin; ibin++)
3204  {
3205  fhPtLeadConeBin[ibin] = new TH1F
3206  (Form("hPtLeadCone_Bin%d",ibin),
3207  Form("cone %2.2f<#it{p}_{T}^{leading}<%2.2f GeV/#it{c}, %s",
3208  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax);
3209  fhPtLeadConeBin[ibin]->SetYTitle("d #it{N} / d #it{p}_{T}");
3210  fhPtLeadConeBin[ibin]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3211  outputContainer->Add(fhPtLeadConeBin[ibin]) ;
3212 
3213  fhSumPtConeBin[ibin] = new TH1F
3214  (Form("hSumPtCone_Bin%d",ibin),
3215  Form("in cone %2.2f <#Sigma #it{p}_{T}< %2.2f GeV/#it{c}, %s",
3216  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax);
3217  fhSumPtConeBin[ibin]->SetYTitle("d #it{N} / d #it{p}_{T}");
3218  fhSumPtConeBin[ibin]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3219  outputContainer->Add(fhSumPtConeBin[ibin]) ;
3220 
3222  {
3223  for(Int_t idecay = 0; idecay < fNDecayBits; idecay++)
3224  {
3225  Int_t bindecay = ibin+idecay*fNBkgBin;
3226 
3227  fhPtLeadConeBinDecay[bindecay] = new TH1F
3228  (Form("hPtLeadCone_Bin%d_DecayBit%d",ibin,fDecayBits[idecay]),
3229  Form("Decay bit %d, cone %2.2f<#it{p}_{T}^{leading}<%2.2f GeV/#it{c}, %s",
3230  fDecayBits[idecay],fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax);
3231  fhPtLeadConeBinDecay[bindecay]->SetYTitle("d #it{N} / d #it{p}_{T}");
3232  fhPtLeadConeBinDecay[bindecay]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3233  outputContainer->Add(fhPtLeadConeBinDecay[bindecay]) ;
3234 
3235  fhSumPtConeBinDecay[bindecay] = new TH1F
3236  (Form("hSumPtCone_Bin%d_DecayBit%d",ibin,fDecayBits[idecay]),
3237  Form("Decay bit %d, in cone %2.2f <#Sigma #it{p}_{T}< %2.2f GeV/#it{c}, %s",
3238  fDecayBits[idecay],fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax);
3239  fhSumPtConeBinDecay[bindecay]->SetYTitle("d #it{N} / d #it{p}_{T}");
3240  fhSumPtConeBinDecay[bindecay]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3241  outputContainer->Add(fhSumPtConeBinDecay[bindecay]) ;
3242  }
3243  }
3244 
3245  if(IsDataMC())
3246  {
3247  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
3248  {
3249  Int_t binmc = ibin+imc*fNBkgBin;
3250  fhPtLeadConeBinMC[binmc] = new TH1F
3251  (Form("hPtLeadCone_Bin%d_MC%s",ibin, mcPartName[imc].Data()),
3252  Form("in cone %2.2f<#it{p}_{T}^{leading}<%2.2f GeV/#it{c}, MC %s, %s",
3253  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),nptbins,ptmin,ptmax);
3254  fhPtLeadConeBinMC[binmc]->SetYTitle("d #it{N} / d #it{p}_{T}");
3255  fhPtLeadConeBinMC[binmc]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3256  outputContainer->Add(fhPtLeadConeBinMC[binmc]) ;
3257 
3258  fhSumPtConeBinMC[binmc] = new TH1F
3259  (Form("hSumPtCone_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3260  Form("in cone %2.2f <#Sigma #it{p}_{T}< %2.2f GeV/#it{c}, MC %s, %s",
3261  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),nptbins,ptmin,ptmax);
3262  fhSumPtConeBinMC[binmc]->SetYTitle("d #it{N} / d #it{p}_{T}");
3263  fhSumPtConeBinMC[binmc]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3264  outputContainer->Add(fhSumPtConeBinMC[binmc]) ;
3265  } // MC particle loop
3266  }
3267 
3268  if(fFillSSHisto)
3269  {
3270  fhPtLeadConeBinLambda0[ibin] = new TH2F
3271  (Form("hPtLeadConeLambda0_Bin%d",ibin),
3272  Form("#lambda_{0}, in cone %2.2f<#it{p}_{T}^{leading}<%2.2f GeV/#it{c}, %s",
3273  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3274  fhPtLeadConeBinLambda0[ibin]->SetYTitle("#lambda_{0}^{2}");
3275  fhPtLeadConeBinLambda0[ibin]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3276  outputContainer->Add(fhPtLeadConeBinLambda0[ibin]) ;
3277 
3278  fhSumPtConeBinLambda0[ibin] = new TH2F
3279  (Form("hSumPtConeLambda0_Bin%d",ibin),
3280  Form("#lambda_{0}, in cone %2.2f <#Sigma #it{p}_{T}< %2.2f GeV/#it{c}, %s",
3281  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3282  fhSumPtConeBinLambda0[ibin]->SetYTitle("#lambda_{0}^{2}");
3283  fhSumPtConeBinLambda0[ibin]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3284  outputContainer->Add(fhSumPtConeBinLambda0[ibin]) ;
3285 
3286  if(IsDataMC())
3287  {
3288  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
3289  {
3290  Int_t binmc = ibin+imc*fNBkgBin;
3291  fhPtLeadConeBinLambda0MC[binmc] = new TH2F
3292  (Form("hPtLeadConeLambda0_Bin%d_MC%s",ibin, mcPartName[imc].Data()),
3293  Form("#lambda_{0}, in cone %2.2f<#it{p}_{T}^{leading}<%2.2f GeV/#it{c}, MC %s, %s",
3294  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3295  fhPtLeadConeBinLambda0MC[binmc]->SetYTitle("#lambda_{0}^{2}");
3296  fhPtLeadConeBinLambda0MC[binmc]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3297  outputContainer->Add(fhPtLeadConeBinLambda0MC[binmc]) ;
3298 
3299  fhSumPtConeBinLambda0MC[binmc] = new TH2F
3300  (Form("hSumPtConeLambda0_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3301  Form("#lambda_{0}, in cone %2.2f <#Sigma #it{p}_{T}< %2.2f GeV/#it{c}, MC %s, %s",
3302  fBkgBinLimit[ibin],fBkgBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3303  fhSumPtConeBinLambda0MC[binmc]->SetYTitle("#lambda_{0}^{2}");
3304  fhSumPtConeBinLambda0MC[binmc]->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3305  outputContainer->Add(fhSumPtConeBinLambda0MC[binmc]) ;
3306  } // MC particle loop
3307  }
3308  } // shower shape on
3309  } // pt in cone bin loop
3310  } // bkg cone pt bin histograms
3311 
3313  {
3314  fhPtTrigBinPtLeadCone = new TH1F*[fNPtTrigBin];
3315  fhPtTrigBinSumPtCone = new TH1F*[fNPtTrigBin];
3316 
3319 
3320  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3321  {
3324 
3327  }
3328 
3329  if(IsDataMC())
3330  {
3333  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3334  {
3337  }
3338  }
3339 
3340  if(fFillSSHisto)
3341  {
3344  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3345  {
3348  }
3349 
3350  if(IsDataMC())
3351  {
3354  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3355  {
3358  }
3359 
3361  {
3364  if ( GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3365  {
3370  }
3371  }
3372  }
3373  }
3374 
3375  for(Int_t ibin = 0; ibin < fNPtTrigBin; ibin++)
3376  {
3377  fhPtTrigBinPtLeadCone[ibin] = new TH1F
3378  (Form("hPtTrigBin_PtLeadCone_Bin%d",ibin),
3379  Form("#it{p}_{T}^{lead. in cone}, %2.2f<#it{p}_{T}^{cand}<%2.2f GeV/#it{c}, %s",
3380  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax);
3381  fhPtTrigBinPtLeadCone[ibin]->SetYTitle("d #it{N} / d #it{p}_{T}");
3382  fhPtTrigBinPtLeadCone[ibin]->SetXTitle("#it{p}_{T}^{in cone} (GeV/#it{c})");
3383  outputContainer->Add(fhPtTrigBinPtLeadCone[ibin]) ;
3384 
3385  fhPtTrigBinSumPtCone[ibin] = new TH1F
3386  (Form("hPtTrigBin_SumPtCone_Bin%d",ibin),
3387  Form("#Sigma #it{p}_{T}^{in cone} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3388  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleR.Data()),nptsumbins,ptsummin,ptsummax);
3389  fhPtTrigBinSumPtCone[ibin]->SetYTitle("d #it{N} / d #it{p}_{T}");
3390  fhPtTrigBinSumPtCone[ibin]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3391  outputContainer->Add(fhPtTrigBinSumPtCone[ibin]) ;
3392 
3393  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3394  {
3395  fhPtTrigBinSumPtTrackCone[ibin] = new TH1F
3396  (Form("hPtTrigBin_SumPtTrackCone_Bin%d",ibin),
3397  Form("#Sigma #it{p}_{T}^{in cone}_{track} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3398  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleRCh.Data()),nptsumbins,ptsummin,ptsummax);
3399  fhPtTrigBinSumPtTrackCone[ibin]->SetYTitle("d #it{N} / d #it{p}_{T}");
3400  fhPtTrigBinSumPtTrackCone[ibin]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3401  outputContainer->Add(fhPtTrigBinSumPtTrackCone[ibin]) ;
3402 
3403  fhPtTrigBinSumPtClusterCone[ibin] = new TH1F
3404  (Form("hPtTrigBin_SumPtClusterCone_Bin%d",ibin),
3405  Form("#Sigma #it{p}_{T}^{in cone}_{cluster} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3406  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleRNe.Data()),nptsumbins,ptsummin,ptsummax);
3407  fhPtTrigBinSumPtClusterCone[ibin]->SetYTitle("d #it{N} / d #it{p}_{T}");
3408  fhPtTrigBinSumPtClusterCone[ibin]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{cluster} (GeV/#it{c})");
3409  outputContainer->Add(fhPtTrigBinSumPtClusterCone[ibin]) ;
3410  }
3411 
3413  {
3414  for(Int_t idecay = 0; idecay < fNDecayBits; idecay++)
3415  {
3416  Int_t binDecay = ibin+idecay*fNPtTrigBin;
3417 
3418  fhPtTrigBinPtLeadConeDecay[binDecay] = new TH1F
3419  (Form("hPtTrigBin_PtLeadCone_Bin%d_DecayBit%d",ibin,fDecayBits[idecay]),
3420  Form("Decay bit %d, #it{p}_{T}^{lead. in cone}, %2.2f<#it{p}_{T}^{cand}<%2.2f GeV/#it{c}, %s",
3421  fDecayBits[idecay],fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax);
3422  fhPtTrigBinPtLeadConeDecay[binDecay]->SetYTitle("d #it{N} / d #it{p}_{T}");
3423  fhPtTrigBinPtLeadConeDecay[binDecay]->SetXTitle("#it{p}_{T}^{lead in cone} (GeV/#it{c})");
3424  outputContainer->Add(fhPtTrigBinPtLeadConeDecay[binDecay]) ;
3425 
3426  fhPtTrigBinSumPtConeDecay[binDecay] = new TH1F
3427  (Form("hPtTrigBin_SumPtCone_Bin%d_DecayBit%d",ibin,fDecayBits[idecay]),
3428  Form("Decay bit %d, #Sigma #it{p}_{T}^{in cone} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3429  fDecayBits[idecay],fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleR.Data()),nptsumbins,ptsummin,ptsummax);
3430  fhPtTrigBinSumPtConeDecay[binDecay]->SetYTitle("d #it{N} / d #it{p}_{T}");
3431  fhPtTrigBinSumPtConeDecay[binDecay]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3432  outputContainer->Add(fhPtTrigBinSumPtConeDecay[binDecay]) ;
3433 
3434  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3435  {
3436  fhPtTrigBinSumPtTrackConeDecay[binDecay] = new TH1F
3437  (Form("hPtTrigBin_SumPtTrackCone_Bin%d_DecayBit%d",ibin,fDecayBits[idecay]),
3438  Form("Decay bit %d, #Sigma #it{p}_{T}^{in cone}_{track} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3439  fDecayBits[idecay],fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleRCh.Data()),nptsumbins,ptsummin,ptsummax);
3440  fhPtTrigBinSumPtTrackConeDecay[binDecay]->SetYTitle("d #it{N} / d #it{p}_{T}");
3441  fhPtTrigBinSumPtTrackConeDecay[binDecay]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3442  outputContainer->Add(fhPtTrigBinSumPtTrackConeDecay[binDecay]) ;
3443 
3444  fhPtTrigBinSumPtClusterConeDecay[binDecay] = new TH1F
3445  (Form("hPtTrigBin_SumPtClusterCone_Bin%d_DecayBit%d",ibin,fDecayBits[idecay]),
3446  Form("Decay bit %d, #Sigma #it{p}_{T}^{in cone}_{cluster} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3447  fDecayBits[idecay],fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleRNe.Data()),nptsumbins,ptsummin,ptsummax);
3448  fhPtTrigBinSumPtClusterConeDecay[binDecay]->SetYTitle("d #it{N} / d #it{p}_{T}");
3449  fhPtTrigBinSumPtClusterConeDecay[binDecay]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{cluster} (GeV/#it{c})");
3450  outputContainer->Add(fhPtTrigBinSumPtClusterConeDecay[binDecay]) ;
3451  }
3452  }
3453  }
3454 
3455  if(IsDataMC())
3456  {
3457  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
3458  {
3459  Int_t binmc = ibin+imc*fNPtTrigBin;
3460  fhPtTrigBinPtLeadConeMC[binmc] = new TH1F
3461  (Form("hPtTrigBin_PtLeadCone_Bin%d_MC%s",ibin, mcPartName[imc].Data()),
3462  Form("#it{p}_{T}^{lead. in cone}, %2.2f<#it{p}_{T}^{cand}<%2.2f GeV/#it{c}, MC %s, %s",
3463  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),nptbins,ptmin,ptmax);
3464  fhPtTrigBinPtLeadConeMC[binmc]->SetYTitle("d #it{N} / d #it{p}_{T}");
3465  fhPtTrigBinPtLeadConeMC[binmc]->SetXTitle("#it{p}_{T}^{lead in cone} (GeV/#it{c})");
3466  outputContainer->Add(fhPtTrigBinPtLeadConeMC[binmc]) ;
3467 
3468  fhPtTrigBinSumPtConeMC[binmc] = new TH1F
3469  (Form("hPtTrigBin_SumPtCone_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3470  Form("#Sigma #it{p}_{T}^{in cone}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC %s, %s",
3471  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),nptsumbins,ptsummin,ptsummax);
3472  fhPtTrigBinSumPtConeMC[binmc]->SetYTitle("d #it{N} / d #it{p}_{T}");
3473  fhPtTrigBinSumPtConeMC[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3474  outputContainer->Add(fhPtTrigBinSumPtConeMC[binmc]) ;
3475 
3476  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3477  {
3478  fhPtTrigBinSumPtTrackConeMC[binmc] = new TH1F
3479  (Form("hPtTrigBin_SumPtTrackCone_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3480  Form("#Sigma #it{p}_{T}^{in cone}_{track}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC %s, %s",
3481  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRCh.Data()),nptsumbins,ptsummin,ptsummax);
3482  fhPtTrigBinSumPtTrackConeMC[binmc]->SetYTitle("d #it{N} / d #it{p}_{T}");
3483  fhPtTrigBinSumPtTrackConeMC[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3484  outputContainer->Add(fhPtTrigBinSumPtTrackConeMC[binmc]) ;
3485 
3486  fhPtTrigBinSumPtClusterConeMC[binmc] = new TH1F
3487  (Form("hPtTrigBin_SumPtClusterCone_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3488  Form("#Sigma #it{p}_{T}^{in cone}_{cluster}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC %s, %s",
3489  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRNe.Data()),nptsumbins,ptsummin,ptsummax);
3490  fhPtTrigBinSumPtClusterConeMC[binmc]->SetYTitle("d #it{N} / d #it{p}_{T}");
3491  fhPtTrigBinSumPtClusterConeMC[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3492  outputContainer->Add(fhPtTrigBinSumPtClusterConeMC[binmc]) ;
3493  }
3494  } // MC particle loop
3495  } // MC
3496 
3497  if(fFillSSHisto)
3498  {
3500  (Form("hPtTrigBin_PtLeadConeVSLambda0_Bin%d",ibin),
3501  Form("#lambda_{0} vs #it{p}_{T}^{lead. in cone}, %2.2f<#it{p}_{T}^{cand}<%2.2f GeV/#it{c}, %s",
3502  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleR.Data()),nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3503  fhPtTrigBinLambda0vsPtLeadCone[ibin]->SetYTitle("#lambda_{0}^{2}");
3504  fhPtTrigBinLambda0vsPtLeadCone[ibin]->SetXTitle("#it{p}_{T}^{lead in cone} (GeV/#it{c})");
3505  outputContainer->Add(fhPtTrigBinLambda0vsPtLeadCone[ibin]) ;
3506 
3508  (Form("hPtTrigBin_SumPtConeVSLambda0_Bin%d",ibin),
3509  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3510  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleR.Data()),nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3511  fhPtTrigBinLambda0vsSumPtCone[ibin]->SetYTitle("#lambda_{0}^{2}");
3512  fhPtTrigBinLambda0vsSumPtCone[ibin]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3513  outputContainer->Add(fhPtTrigBinLambda0vsSumPtCone[ibin]) ;
3514 
3515  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3516  {
3518  (Form("hPtTrigBin_SumPtTrackConeVSLambda0_Bin%d",ibin),
3519  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{track} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3520  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleRCh.Data()),nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3521  fhPtTrigBinLambda0vsSumPtTrackCone[ibin]->SetYTitle("#lambda_{0}^{2}");
3522  fhPtTrigBinLambda0vsSumPtTrackCone[ibin]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3523  outputContainer->Add(fhPtTrigBinLambda0vsSumPtTrackCone[ibin]) ;
3524 
3526  (Form("hPtTrigBin_SumPtClusterConeVSLambda0_Bin%d",ibin),
3527  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{cluster} %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, %s",
3528  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], parTitleRNe.Data()),nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3529  fhPtTrigBinLambda0vsSumPtClusterCone[ibin]->SetYTitle("#lambda_{0}^{2}");
3530  fhPtTrigBinLambda0vsSumPtClusterCone[ibin]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{cluster} (GeV/#it{c})");
3531  outputContainer->Add(fhPtTrigBinLambda0vsSumPtClusterCone[ibin]) ;
3532  }
3533 
3534  if(IsDataMC())
3535  {
3536  for(Int_t imc = 0; imc < fgkNmcTypes; imc++)
3537  {
3538  Int_t binmc = ibin+imc*fNPtTrigBin;
3540  (Form("hPtTrigBin_PtLeadConeVSLambda0_Bin%d_MC%s",ibin, mcPartName[imc].Data()),
3541  Form("#lambda_{0} vs #it{p}_{T}^{lead. in cone}, %2.2f<#it{p}_{T}^{cand}<%2.2f GeV/#it{c}, MC %s, %s",
3542  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),
3543  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3544  fhPtTrigBinLambda0vsPtLeadConeMC[binmc]->SetYTitle("#lambda_{0}^{2}");
3545  fhPtTrigBinLambda0vsPtLeadConeMC[binmc]->SetXTitle("#it{p}_{T}^{lead in cone} (GeV/#it{c})");
3546  outputContainer->Add(fhPtTrigBinLambda0vsPtLeadConeMC[binmc]) ;
3547 
3549  (Form("hPtTrigBin_SumPtConeVSLambda0_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3550  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC %s, %s",
3551  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),
3552  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3553  fhPtTrigBinLambda0vsSumPtConeMC[binmc]->SetYTitle("#lambda_{0}^{2}");
3554  fhPtTrigBinLambda0vsSumPtConeMC[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3555  outputContainer->Add(fhPtTrigBinLambda0vsSumPtConeMC[binmc]) ;
3556 
3557  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3558  {
3560  (Form("hPtTrigBin_SumPtTrackConeVSLambda0_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3561  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{track}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC %s, %s",
3562  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRCh.Data()),
3563  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3564  fhPtTrigBinLambda0vsSumPtTrackConeMC[binmc]->SetYTitle("#lambda_{0}^{2}");
3565  fhPtTrigBinLambda0vsSumPtTrackConeMC[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3566  outputContainer->Add(fhPtTrigBinLambda0vsSumPtTrackConeMC[binmc]) ;
3567 
3569  (Form("hPtTrigBin_SumPtClusterConeVSLambda0_Bin%d_MC%s",ibin,mcPartName[imc].Data()),
3570  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{cluster}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC %s, %s",
3571  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRNe.Data()),
3572  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3573  fhPtTrigBinLambda0vsSumPtClusterConeMC[binmc]->SetYTitle("#lambda_{0}^{2}");
3574  fhPtTrigBinLambda0vsSumPtClusterConeMC[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{cluster} (GeV/#it{c})");
3575  outputContainer->Add(fhPtTrigBinLambda0vsSumPtClusterConeMC[binmc]) ;
3576  }
3577 
3579  {
3581  (Form("hPtTrigBin_SumPtConeVSLambda0_Bin%d_MC_NoOverlap%s",ibin,mcPartName[imc].Data()),
3582  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC, No Overlaps %s, %s",
3583  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),
3584  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3585  fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[binmc]->SetYTitle("#lambda_{0}^{2}");
3586  fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3587  outputContainer->Add(fhPtTrigBinLambda0vsSumPtConeMCNoOverlap[binmc]) ;
3588 
3590  (Form("hPtTrigBin_SumPtConeVSLambda0_Bin%d_MC_1Overlap%s",ibin,mcPartName[imc].Data()),
3591  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC, 1 Overlap %s, %s",
3592  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleR.Data()),
3593  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3594  fhPtTrigBinLambda0vsSumPtConeMC1Overlap[binmc]->SetYTitle("#lambda_{0}^{2}");
3595  fhPtTrigBinLambda0vsSumPtConeMC1Overlap[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone} (GeV/#it{c})");
3596  outputContainer->Add(fhPtTrigBinLambda0vsSumPtConeMC1Overlap[binmc]) ;
3597 
3598  if(GetIsolationCut()->GetParticleTypeInCone()==AliIsolationCut::kNeutralAndCharged )
3599  {
3601  (Form("hPtTrigBin_SumPtTrackConeVSLambda0_Bin%d_MC_NoOverlap%s",ibin,mcPartName[imc].Data()),
3602  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{track}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC, No Overlaps %s, %s",
3603  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRCh.Data()),
3604  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3605  fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap[binmc]->SetYTitle("#lambda_{0}^{2}");
3606  fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3607  outputContainer->Add(fhPtTrigBinLambda0vsSumPtTrackConeMCNoOverlap[binmc]) ;
3608 
3610  (Form("hPtTrigBin_SumPtClusterConeVSLambda0_Bin%d_MC_NoOverlap%s",ibin,mcPartName[imc].Data()),
3611  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{cluster}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC, No Overlaps %s, %s",
3612  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRNe.Data()),
3613  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3614  fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[binmc]->SetYTitle("#lambda_{0}^{2}");
3615  fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{cluster} (GeV/#it{c})");
3616  outputContainer->Add(fhPtTrigBinLambda0vsSumPtClusterConeMCNoOverlap[binmc]) ;
3617 
3619  (Form("hPtTrigBin_SumPtTrackConeVSLambda0_Bin%d_MC_1Overlap%s",ibin,mcPartName[imc].Data()),
3620  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{track}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC, 1 Overlap %s, %s",
3621  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRCh.Data()),
3622  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3623  fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap[binmc]->SetYTitle("#lambda_{0}^{2}");
3624  fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{track} (GeV/#it{c})");
3625  outputContainer->Add(fhPtTrigBinLambda0vsSumPtTrackConeMC1Overlap[binmc]) ;
3626 
3628  (Form("hPtTrigBin_SumPtClusterConeVSLambda0_Bin%d_MC_1Overlap%s",ibin,mcPartName[imc].Data()),
3629  Form("#lambda_{0} vs #Sigma #it{p}_{T}^{in cone}_{cluster}, %2.2f <#it{p}_{T}^{cand}< %2.2f GeV/#it{c}, MC, 1 Overlap %s, %s",
3630  fPtTrigBinLimit[ibin],fPtTrigBinLimit[ibin+1], mcPartType[imc].Data(), parTitleRNe.Data()),
3631  nptsumbins,ptsummin,ptsummax,ssbins,ssmin,ssmax);
3632  fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[binmc]->SetYTitle("#lambda_{0}^{2}");
3633  fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[binmc]->SetXTitle("#Sigma #it{p}_{T}^{in cone}_{cluster} (GeV/#it{c})");
3634  outputContainer->Add(fhPtTrigBinLambda0vsSumPtClusterConeMC1Overlap[binmc]) ;
3635 
3636  }
3637  } // Overlap histograms
3638  } // MC particle loop
3639  } // MC
3640  } // SS histo
3641  } // pt trig bin loop
3642  } // pt trig bin histograms
3643 
3645  {
3646  fhPtInConeCent = new TH2F("hPtInConeCent",
3647  Form("#it{p}_{T} in isolation cone for %s",parTitleR.Data()),
3648  100,0,100,nptinconebins,ptinconemin,ptinconemax);
3649  fhPtInConeCent->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
3650  fhPtInConeCent->SetXTitle("centrality");
3651  outputContainer->Add(fhPtInConeCent) ;
3652  }
3653 
3654  // Cluster only histograms
3655  if(GetIsolationCut()->GetParticleTypeInCone()!=AliIsolationCut::kOnlyCharged)
3656  {
3657  fhConeSumPtCluster = new TH2F
3658  ("hConePtSumCluster",
3659  Form("Cluster #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f",r),
3660  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3661  fhConeSumPtCluster->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3662  fhConeSumPtCluster->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3663  outputContainer->Add(fhConeSumPtCluster) ;
3664 
3666  {
3668  ("hConePtSumClusterExoTrigger",
3669  Form("Cluster #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, exo trigger",r),
3670  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3671  fhConeSumPtClusterExoTrigger->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3672  fhConeSumPtClusterExoTrigger->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3673  outputContainer->Add(fhConeSumPtClusterExoTrigger) ;
3674  }
3675 
3676  if(fStudyPtCutInCone)
3677  {
3679  ("hConeNClusterPerMinPtCut",
3680  Form("N clusters, different min #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f",r),
3681  fNPtCutsInCone,-0.5,fNPtCutsInCone-0.5,nmultbin,multmin,multmax);
3682  fhConeNClusterPerMinPtCut->SetYTitle("#it{N}^{cluster}");
3683  fhConeNClusterPerMinPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
3684  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
3685  fhConeNClusterPerMinPtCut->GetXaxis()->SetBinLabel(i ,Form("%2.1f",fMinPtCutInCone[i-1]));
3686  outputContainer->Add(fhConeNClusterPerMinPtCut) ;
3687 
3689  ("hConeNClusterPerMinPtCutLargePtTrig",
3690  Form("N cluster, different min #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
3691  fNPtCutsInCone,-0.5,fNPtCutsInCone-0.5,nmultbin,multmin,multmax);
3692  fhConeNClusterPerMinPtCutLargePtTrig->SetYTitle("#it{N}^{cluster}");
3693  fhConeNClusterPerMinPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
3694  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
3695  fhConeNClusterPerMinPtCutLargePtTrig->GetXaxis()->SetBinLabel(i ,Form("%2.1f",fMinPtCutInCone[i-1]));
3696  outputContainer->Add(fhConeNClusterPerMinPtCutLargePtTrig) ;
3697 
3699  ("hConePtSumClusterPerMinPtCut",
3700  Form("Cluster #Sigma #it{p}_{T}, different min #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f",r),
3701  fNPtCutsInCone,-0.5,fNPtCutsInCone-0.5,nptsumbins,ptsummin,ptsummax);
3702  fhConeSumPtClusterPerMinPtCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3703  fhConeSumPtClusterPerMinPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
3704  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
3705  fhConeSumPtClusterPerMinPtCut->GetXaxis()->SetBinLabel(i ,Form("%2.1f",fMinPtCutInCone[i-1]));
3706  outputContainer->Add(fhConeSumPtClusterPerMinPtCut) ;
3707 
3709  ("hConePtSumClusterPerMinPtCutLargePtTrig",
3710  Form("Cluster #Sigma #it{p}_{T}, different min #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
3711  fNPtCutsInCone,-0.5,fNPtCutsInCone-0.5,nptsumbins,ptsummin,ptsummax);
3712  fhConeSumPtClusterPerMinPtCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3713  fhConeSumPtClusterPerMinPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
3714  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
3715  fhConeSumPtClusterPerMinPtCutLargePtTrig->GetXaxis()->SetBinLabel(i ,Form("%2.1f",fMinPtCutInCone[i-1]));
3716  outputContainer->Add(fhConeSumPtClusterPerMinPtCutLargePtTrig) ;
3717 
3718 
3720  ("hConePtSumClusterPerMaxPtCut",
3721  Form("Cluster #Sigma #it{p}_{T}, different max #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f",r),
3722  fNPtCutsInCone,-0.5,fNPtCutsInCone-0.5,nptsumbins,ptsummin,ptsummax);
3723  fhConeSumPtClusterPerMaxPtCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3724  fhConeSumPtClusterPerMaxPtCut->SetXTitle("#it{p}_{T, max} (GeV/#it{c})");
3725  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
3726  fhConeSumPtClusterPerMaxPtCut->GetXaxis()->SetBinLabel(i ,Form("%2.1f",fMaxPtCutInCone[i-1]));
3727  outputContainer->Add(fhConeSumPtClusterPerMaxPtCut) ;
3728 
3730  ("hConePtSumClusterPerMaxPtCutLargePtTrig",
3731  Form("Cluster #Sigma #it{p}_{T}, different max #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
3732  fNPtCutsInCone,-0.5,fNPtCutsInCone-0.5,nptsumbins,ptsummin,ptsummax);
3733  fhConeSumPtClusterPerMaxPtCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3734  fhConeSumPtClusterPerMaxPtCutLargePtTrig->SetXTitle("#it{p}_{T, max} (GeV/#it{c})");
3735  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
3736  fhConeSumPtClusterPerMaxPtCutLargePtTrig->GetXaxis()->SetBinLabel(i ,Form("%2.1f",fMaxPtCutInCone[i-1]));
3737  outputContainer->Add(fhConeSumPtClusterPerMaxPtCutLargePtTrig) ;
3738  }
3739 
3740  if(fStudyRCutInCone)
3741  {
3743  ("hConePtSumClusterPerRCut","Cluster #Sigma #it{p}_{T}, different #it{R} cuts",
3744  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
3745  fhConeSumPtClusterPerRCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3746  fhConeSumPtClusterPerRCut->SetXTitle("#it{R}");
3747  for(Int_t i = 1; i <= fNRCutsInCone; i++)
3748  fhConeSumPtClusterPerRCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
3749  outputContainer->Add(fhConeSumPtClusterPerRCut) ;
3750 
3752  ("hConePtSumClusterPerRCutLargePtTrig","Cluster #Sigma #it{p}_{T}, different #it{R} cuts, #it{p}_{T}^{trig} > 10 GeV",
3753  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
3754  fhConeSumPtClusterPerRCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3755  fhConeSumPtClusterPerRCutLargePtTrig->SetXTitle("#it{R}");
3756  for(Int_t i = 1; i <= fNRCutsInCone; i++)
3757  fhConeSumPtClusterPerRCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
3758  outputContainer->Add(fhConeSumPtClusterPerRCutLargePtTrig) ;
3759 
3761  ("hPtClusterInConePerRCut","Cluster #it{p}_{T}, different #it{R} cuts",
3762  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
3763  fhPtClusterInConePerRCut->SetYTitle("#it{p}_{T}^{cluster} (GeV/#it{c})");
3764  fhPtClusterInConePerRCut->SetXTitle("#it{R}");
3765  for(Int_t i = 1; i <= fNRCutsInCone; i++)
3766  fhPtClusterInConePerRCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
3767  outputContainer->Add(fhPtClusterInConePerRCut) ;
3768 
3770  ("hPtClusterInConePerRCutLargePtTrig","Cluster #it{p}_{T}, different #it{R} cuts, #it{p}_{T}^{trig} > 10 GeV",
3771  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
3772  fhPtClusterInConePerRCutLargePtTrig->SetYTitle("#it{p}_{T}^{cluster} (GeV/#it{c})");
3773  fhPtClusterInConePerRCutLargePtTrig->SetXTitle("#it{R}");
3774  for(Int_t i = 1; i <= fNRCutsInCone; i++)
3775  fhPtClusterInConePerRCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
3776  outputContainer->Add(fhPtClusterInConePerRCutLargePtTrig) ;
3777  }
3778 
3780  {
3782  ("hConePtSumClusterPerNCellCut","Cluster #Sigma #it{p}_{T}, different #it{N}_{cell} cuts",
3783  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3784  fhConeSumPtClusterPerNCellCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3785  fhConeSumPtClusterPerNCellCut->SetXTitle("#it{N}_{cell}^{min}");
3786  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
3787  fhConeSumPtClusterPerNCellCut->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
3788  outputContainer->Add(fhConeSumPtClusterPerNCellCut) ;
3789 
3791  ("hConePtSumClusterPerNCellCutLargePtTrig","Cluster #Sigma #it{p}_{T}, different #it{N}_{cell} cuts, #it{p}_{T}^{trig} > 10 GeV",
3792  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3793  fhConeSumPtClusterPerNCellCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3794  fhConeSumPtClusterPerNCellCutLargePtTrig->SetXTitle("#it{N}_{cell}^{min}");
3795  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
3796  fhConeSumPtClusterPerNCellCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
3797  outputContainer->Add(fhConeSumPtClusterPerNCellCutLargePtTrig) ;
3798 
3800  ("hPtClusterInConePerNCellCut","Cluster #it{p}_{T}, different #it{N}_{cell} cuts",
3801  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3802  fhPtClusterInConePerNCellCut->SetYTitle("#it{p}_{T}^{cluster} (GeV/#it{c})");
3803  fhPtClusterInConePerNCellCut->SetXTitle("#it{N}_{cell}^{min}");
3804  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
3805  fhPtClusterInConePerNCellCut->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
3806  outputContainer->Add(fhPtClusterInConePerNCellCut) ;
3807 
3809  ("hPtClusterInConePerNCellCutLargePtTrig","Cluster #it{p}_{T}, different #it{N}_{cell} cuts, #it{p}_{T}^{trig} > 10 GeV",
3810  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3811  fhPtClusterInConePerNCellCutLargePtTrig->SetYTitle("#it{p}_{T}^{cluster} (GeV/#it{c})");
3812  fhPtClusterInConePerNCellCutLargePtTrig->SetXTitle("#it{N}_{cell}^{min}");
3813  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
3814  fhPtClusterInConePerNCellCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
3815  outputContainer->Add(fhPtClusterInConePerNCellCutLargePtTrig) ;
3816 
3817 
3819  ("hConePtSumClusterPerExoCut","Cluster #Sigma #it{p}_{T}, different exoticity cuts",
3820  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3821  fhConeSumPtClusterPerExoCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3822  fhConeSumPtClusterPerExoCut->SetXTitle("exoticity");
3823  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
3824  fhConeSumPtClusterPerExoCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
3825  outputContainer->Add(fhConeSumPtClusterPerExoCut) ;
3826 
3828  ("hConePtSumClusterPerExoCutLargePtTrig","Cluster #Sigma #it{p}_{T}, different exoticity cuts, #it{p}_{T}^{trig} > 10 GeV",
3829  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3830  fhConeSumPtClusterPerExoCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3831  fhConeSumPtClusterPerExoCutLargePtTrig->SetXTitle("exoticity");
3832  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
3833  fhConeSumPtClusterPerExoCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
3834  outputContainer->Add(fhConeSumPtClusterPerExoCutLargePtTrig) ;
3835 
3837  ("hPtClusterInConePerExoCut","Cluster #it{p}_{T}, different exoticity cuts",
3838  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3839  fhPtClusterInConePerExoCut->SetYTitle("#it{p}_{T}^{cluster} (GeV/#it{c})");
3840  fhPtClusterInConePerExoCut->SetXTitle("exoticity");
3841  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
3842  fhPtClusterInConePerExoCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
3843  outputContainer->Add(fhPtClusterInConePerExoCut) ;
3844 
3846  ("hPtClusterInConePerExoCutLargePtTrig","Cluster #it{p}_{T}, different exoticity cuts, #it{p}_{T}^{trig} > 10 GeV",
3847  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
3848  fhPtClusterInConePerExoCutLargePtTrig->SetYTitle("#it{p}_{T}^{cluster} (GeV/#it{c})");
3849  fhPtClusterInConePerExoCutLargePtTrig->SetXTitle("exoticity");
3850  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
3851  fhPtClusterInConePerExoCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
3852  outputContainer->Add(fhPtClusterInConePerExoCutLargePtTrig) ;
3853  }
3854 
3855  fhConePtLeadCluster = new TH2F("hConeLeadPtCluster",
3856  Form("Cluster leading in isolation cone for #it{R} = %2.2f",r),
3857  nptbins,ptmin,ptmax,nptbins,ptmin,ptmax);
3858  fhConePtLeadCluster->SetYTitle("#it{p}_{T, leading} (GeV/#it{c})");
3859  fhConePtLeadCluster->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3860  outputContainer->Add(fhConePtLeadCluster) ;
3861 
3862 
3864  {
3865  fhConeSumPtCell = new TH2F("hConePtSumCell",
3866  Form("Cell #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f",r),
3867  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3868  fhConeSumPtCell->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3869  fhConeSumPtCell->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3870  outputContainer->Add(fhConeSumPtCell) ;
3871  }
3872 
3874  {
3875  fhConeSumPtEtaBandUECluster = new TH2F("hConePtSumEtaBandUECluster",
3876  "#Sigma cluster #it{p}_{T} in UE Eta Band",
3877  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3878  fhConeSumPtEtaBandUECluster->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3879  fhConeSumPtEtaBandUECluster->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3880  outputContainer->Add(fhConeSumPtEtaBandUECluster) ;
3881 
3882  fhConeSumPtPhiBandUECluster = new TH2F("hConePtSumPhiBandUECluster",
3883  "#Sigma cluster #it{p}_{T} UE Phi Band",
3884  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3885  fhConeSumPtPhiBandUECluster->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3886  fhConeSumPtPhiBandUECluster->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3887  outputContainer->Add(fhConeSumPtPhiBandUECluster) ;
3888 
3890  {
3891  fhConeSumPtEtaBandUEClusterTrigEtaPhi = new TH2F("hConePtSumEtaBandUEClusterTrigEtaPhi",
3892  "Trigger #eta vs #varphi, #Sigma cluster #it{p}_{T} in UE Eta Band",
3893  netabins,etamin,etamax,nphibins,phimin,phimax);
3894  fhConeSumPtEtaBandUEClusterTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
3895  fhConeSumPtEtaBandUEClusterTrigEtaPhi->SetXTitle("#eta_{trigger}");
3896  fhConeSumPtEtaBandUEClusterTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
3897  outputContainer->Add(fhConeSumPtEtaBandUEClusterTrigEtaPhi) ;
3898 
3899  fhConeSumPtPhiBandUEClusterTrigEtaPhi = new TH2F("hConePtSumPhiBandUEClusterTrigEtaPhi",
3900  "Trigger #eta vs #varphi, #Sigma cluster #it{p}_{T} UE Phi Band",
3901  netabins,etamin,etamax,nphibins,phimin,phimax);
3902  fhConeSumPtPhiBandUEClusterTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
3903  fhConeSumPtPhiBandUEClusterTrigEtaPhi->SetXTitle("#eta_{trigger}");
3904  fhConeSumPtPhiBandUEClusterTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
3905  outputContainer->Add(fhConeSumPtPhiBandUEClusterTrigEtaPhi) ;
3906 
3907  fhEtaBandClusterEtaPhi = new TH2F("hEtaBandClusterEtaPhi",
3908  Form("#eta vs #varphi of clusters in #eta band isolation cone for #it{R} = %2.2f",r),
3909  netabins,-1,1,nphibins,0,TMath::TwoPi());
3910  fhEtaBandClusterEtaPhi->SetXTitle("#eta");
3911  fhEtaBandClusterEtaPhi->SetYTitle("#varphi (rad)");
3912  outputContainer->Add(fhEtaBandClusterEtaPhi) ;
3913 
3914  fhPhiBandClusterEtaPhi = new TH2F("hPhiBandClusterEtaPhi",
3915  Form("#eta vs #varphi of clusters in #varphi band isolation cone for #it{R} = %2.2f",r),
3916  netabins,-1,1,nphibins,0,TMath::TwoPi());
3917  fhPhiBandClusterEtaPhi->SetXTitle("#eta");
3918  fhPhiBandClusterEtaPhi->SetYTitle("#varphi (rad)");
3919  outputContainer->Add(fhPhiBandClusterEtaPhi) ;
3920 
3921  fhEtaPhiInConeCluster= new TH2F("hEtaPhiInConeCluster",
3922  Form("#eta vs #varphi of clusters in cone for #it{R} = %2.2f",r),
3923  netabins,-1,1,nphibins,0,TMath::TwoPi());
3924  fhEtaPhiInConeCluster->SetXTitle("#eta");
3925  fhEtaPhiInConeCluster->SetYTitle("#varphi (rad)");
3926  outputContainer->Add(fhEtaPhiInConeCluster) ;
3927 
3928  fhEtaPhiCluster= new TH2F("hEtaPhiCluster",
3929  Form("#eta vs #varphi of all clusters"),
3930  netabins,-1,1,nphibins,0,TMath::TwoPi());
3931  fhEtaPhiCluster->SetXTitle("#eta");
3932  fhEtaPhiCluster->SetYTitle("#varphi (rad)");
3933  outputContainer->Add(fhEtaPhiCluster) ;
3934  }
3935 
3937  {
3938  fhConeSumPtEtaBandUECell = new TH2F("hConePtSumEtaBandUECell",
3939  "#Sigma cell #it{p}_{T} in UE Eta Band",
3940  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3941  fhConeSumPtEtaBandUECell->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3942  fhConeSumPtEtaBandUECell->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3943  outputContainer->Add(fhConeSumPtEtaBandUECell) ;
3944 
3945  fhConeSumPtPhiBandUECell = new TH2F("hConePtSumPhiBandUECell",
3946  "#Sigma cell #it{p}_{T} UE Phi Band",
3947  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
3948  fhConeSumPtPhiBandUECell->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
3949  fhConeSumPtPhiBandUECell->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
3950  outputContainer->Add(fhConeSumPtPhiBandUECell) ;
3951 
3952  fhConeSumPtEtaBandUECellTrigEtaPhi = new TH2F("hConePtSumEtaBandUECellTrigEtaPhi",
3953  "Trigger #eta vs #varphi, #Sigma cell #it{p}_{T} in UE Eta Band",
3954  netabins,etamin,etamax,nphibins,phimin,phimax);
3955  fhConeSumPtEtaBandUECellTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
3956  fhConeSumPtEtaBandUECellTrigEtaPhi->SetXTitle("#eta_{trigger}");
3957  fhConeSumPtEtaBandUECellTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
3958  outputContainer->Add(fhConeSumPtEtaBandUECellTrigEtaPhi) ;
3959 
3960  fhConeSumPtPhiBandUECellTrigEtaPhi = new TH2F("hConePtSumPhiBandUECellTrigEtaPhi",
3961  "Trigger #eta vs #varphi, #Sigma cell #it{p}_{T} UE Phi Band",
3962  netabins,etamin,etamax,nphibins,phimin,phimax);
3963  fhConeSumPtPhiBandUECellTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
3964  fhConeSumPtPhiBandUECellTrigEtaPhi->SetXTitle("#eta_{trigger}");
3965  fhConeSumPtPhiBandUECellTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
3966  outputContainer->Add(fhConeSumPtPhiBandUECellTrigEtaPhi) ;
3967  }
3968 
3969  fhEtaBandClusterPt = new TH2F("hEtaBandClusterPt",
3970  Form("#it{p}_{T} of clusters in #eta band isolation cone for #it{R} = %2.2f",r),
3971  nptbins,ptmin,ptmax,nptbins,ptmin,ptmax);
3972  fhEtaBandClusterPt->SetXTitle("#it{p}_{T}^{trig} (GeV/#it{c})");
3973  fhEtaBandClusterPt->SetYTitle("#it{p}_{T}^{cluster-band} (GeV/#it{c})");
3974  outputContainer->Add(fhEtaBandClusterPt) ;
3975 
3976  fhPhiBandClusterPt = new TH2F("hPhiBandClusterPt",
3977  Form("#it{p}_{T} of clusters in #varphi band isolation cone for #it{R} = %2.2f",r),
3978  nptbins,ptmin,ptmax,nptbins,ptmin,ptmax);
3979  fhPhiBandClusterPt->SetXTitle("#it{p}_{T}^{trig} (GeV/#it{c})");
3980  fhPhiBandClusterPt->SetYTitle("#it{p}_{T}^{cluster-band} (GeV/#it{c})");
3981  outputContainer->Add(fhPhiBandClusterPt) ;
3982  }
3983 
3984  fhPtClusterInCone = new TH2F("hPtClusterInCone",
3985  Form("#it{p}_{T} of clusters in isolation cone for #it{R} = %2.2f",r),
3986  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
3987  fhPtClusterInCone->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
3988  fhPtClusterInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3989  outputContainer->Add(fhPtClusterInCone) ;
3990 
3992  {
3993  fhPtClusterInConeExoTrigger = new TH2F("hPtClusterInConeExoTrigger",
3994  Form("#it{p}_{T} of clusters in isolation cone for #it{R} = %2.2f, exotic trigger",r),
3995  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
3996  fhPtClusterInConeExoTrigger->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
3997  fhPtClusterInConeExoTrigger->SetXTitle("#it{p}_{T} (GeV/#it{c})");
3998  outputContainer->Add(fhPtClusterInConeExoTrigger) ;
3999  }
4000 
4002  {
4003  fhPtCellInCone = new TH2F("hPtCellInCone",
4004  Form("#it{p}_{T} of cells in isolation cone for #it{R} = %2.2f",r),
4005  nptbins,ptmin,ptmax,1000,0,50);
4006  fhPtCellInCone->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4007  fhPtCellInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4008  outputContainer->Add(fhPtCellInCone) ;
4009 
4010  fhEtaBandCell = new TH2F("hEtaBandCell",
4011  Form("#col vs #row of cells in #eta band isolation cone for #it{R} = %2.2f",r),
4012  96,0,95,128,0,127);
4013  fhEtaBandCell->SetXTitle("#col");
4014  fhEtaBandCell->SetYTitle("#row");
4015  outputContainer->Add(fhEtaBandCell) ;
4016 
4017  fhPhiBandCell = new TH2F("hPhiBandCell",
4018  Form("#col vs #row of cells in #varphi band isolation cone for #it{R} = %2.2f",r),
4019  96,0,95,128,0,127);
4020  fhPhiBandCell->SetXTitle("#col");
4021  fhPhiBandCell->SetYTitle("#row");
4022  outputContainer->Add(fhPhiBandCell) ;
4023  }
4024 
4026  {
4027  fhConeSumPtEtaUENormCluster = new TH2F("hConeSumPtEtaUENormCluster",
4028  Form("Clusters #Sigma #it{p}_{T} in normalized #eta band, #it{R} = %2.2f",r),
4029  nptbins,ptmin,ptmax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4030  fhConeSumPtEtaUENormCluster->SetYTitle("#Sigma #it{p}_{T}^{#eta-band}_{norm} (GeV/#it{c})");
4031  fhConeSumPtEtaUENormCluster->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4032  outputContainer->Add(fhConeSumPtEtaUENormCluster) ;
4033 
4034  fhConeSumPtPhiUENormCluster = new TH2F("hConeSumPtPhiUENormCluster",
4035  Form("Clusters #Sigma #it{p}_{T} in normalized #varphi band, #it{R} = %2.2f",r),
4036  nptbins,ptmin,ptmax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4037  fhConeSumPtPhiUENormCluster->SetYTitle("#Sigma #it{p}_{T}^{#varphi-band}_{norm} (GeV/#it{c})");
4038  fhConeSumPtPhiUENormCluster->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4039  outputContainer->Add(fhConeSumPtPhiUENormCluster) ;
4040 
4041  fhConeSumPtEtaUESubCluster = new TH2F("hConeSumPtEtaUESubCluster",
4042  Form("Clusters #Sigma #it{p}_{T} after bkg subtraction from #eta band in the isolation cone for #it{R} = %2.2f",r),
4043  nptbins,ptmin,ptmax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4044  fhConeSumPtEtaUESubCluster->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4045  fhConeSumPtEtaUESubCluster->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4046  outputContainer->Add(fhConeSumPtEtaUESubCluster) ;
4047 
4048  fhConeSumPtPhiUESubCluster = new TH2F("hConeSumPtPhiUESubCluster",
4049  Form("Clusters #Sigma #it{p}_{T} after bkg subtraction from #varphi band in the isolation cone for #it{R} = %2.2f",r),
4050  nptbins,ptmin,ptmax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4051  fhConeSumPtPhiUESubCluster->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4052  fhConeSumPtPhiUESubCluster->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4053  outputContainer->Add(fhConeSumPtPhiUESubCluster) ;
4054 
4056  {
4057  fhConeSumPtEtaUESubClusterTrigEtaPhi = new TH2F("hConeSumPtEtaUESubClusterTrigEtaPhi",
4058  Form("Trigger #eta vs #varphi, Clusters #Sigma #it{p}_{T} after bkg subtraction from #eta band in the isolation cone for #it{R} = %2.2f",r),
4059  netabins,etamin,etamax,nphibins,phimin,phimax);
4060  fhConeSumPtEtaUESubClusterTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
4061  fhConeSumPtEtaUESubClusterTrigEtaPhi->SetXTitle("#eta_{trigger}");
4062  fhConeSumPtEtaUESubClusterTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4063  outputContainer->Add(fhConeSumPtEtaUESubClusterTrigEtaPhi) ;
4064 
4065  fhConeSumPtPhiUESubClusterTrigEtaPhi = new TH2F("hConeSumPtPhiUESubClusterTrigEtaPhi",
4066  Form("Trigger #eta vs #varphi, Clusters #Sigma #it{p}_{T} after bkg subtraction from #varphi band in the isolation cone for #it{R} = %2.2f",r),
4067  netabins,etamin,etamax,nphibins,phimin,phimax);
4068  fhConeSumPtPhiUESubClusterTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
4069  fhConeSumPtPhiUESubClusterTrigEtaPhi->SetXTitle("#eta_{trigger}");
4070  fhConeSumPtPhiUESubClusterTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4071  outputContainer->Add(fhConeSumPtPhiUESubClusterTrigEtaPhi) ;
4072  }
4073 
4075  {
4076  fhConeSumPtEtaUESubCell = new TH2F("hConeSumPtEtaUESubCell",
4077  Form("Cells #Sigma #it{p}_{T} after bkg subtraction from #eta band in the isolation cone for #it{R} = %2.2f",r),
4078  nptbins,ptmin,ptmax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4079  fhConeSumPtEtaUESubCell->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4080  fhConeSumPtEtaUESubCell->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4081  outputContainer->Add(fhConeSumPtEtaUESubCell) ;
4082 
4083  fhConeSumPtPhiUESubCell = new TH2F("hConeSumPtPhiUESubCell",
4084  Form("Cells #Sigma #it{p}_{T} after bkg subtraction from #varphi band in the isolation cone for #it{R} = %2.2f",r),
4085  nptbins,ptmin,ptmax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4086  fhConeSumPtPhiUESubCell->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4087  fhConeSumPtPhiUESubCell->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4088  outputContainer->Add(fhConeSumPtPhiUESubCell) ;
4089 
4090  fhConeSumPtEtaUESubCellTrigEtaPhi = new TH2F("hConeSumPtEtaUESubCellTrigEtaPhi",
4091  Form("Trigger #eta vs #varphi, Cells #Sigma #it{p}_{T} after bkg subtraction from #eta band in the isolation cone for #it{R} = %2.2f",r),
4092  netabins,etamin,etamax,nphibins,phimin,phimax);
4093  fhConeSumPtEtaUESubCellTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
4094  fhConeSumPtEtaUESubCellTrigEtaPhi->SetXTitle("#eta_{trigger}");
4095  fhConeSumPtEtaUESubCellTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4096  outputContainer->Add(fhConeSumPtEtaUESubCellTrigEtaPhi) ;
4097 
4098  fhConeSumPtPhiUESubCellTrigEtaPhi = new TH2F("hConeSumPtPhiUESubCellTrigEtaPhi",
4099  Form("Trigger #eta vs #varphi, Cells #Sigma #it{p}_{T} after bkg subtraction from #varphi band in the isolation cone for #it{R} = %2.2f",r),
4100  netabins,etamin,etamax,nphibins,phimin,phimax);
4101  fhConeSumPtPhiUESubCellTrigEtaPhi->SetZTitle("#Sigma #it{p}_{T}");
4102  fhConeSumPtPhiUESubCellTrigEtaPhi->SetXTitle("#eta_{trigger}");
4103  fhConeSumPtPhiUESubCellTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4104  outputContainer->Add(fhConeSumPtPhiUESubCellTrigEtaPhi) ;
4105  }
4106 
4108  {
4109  fhFractionClusterOutConeEta = new TH2F("hFractionClusterOutConeEta",
4110  Form("Fraction of the isolation cone #it{R} = %2.2f, out of clusters #eta acceptance",r),
4111  nptbins,ptmin,ptmax,100,0,1);
4112  fhFractionClusterOutConeEta->SetYTitle("#it{fraction}");
4113  fhFractionClusterOutConeEta->SetXTitle("#it{p}_{T,trigger} (GeV/#it{c})");
4114  outputContainer->Add(fhFractionClusterOutConeEta) ;
4115 
4116  fhFractionClusterOutConeEtaTrigEtaPhi = new TH2F("hFractionClusterOutConeEtaTrigEtaPhi",
4117  Form("Fraction of the isolation cone #it{R} = %2.2f, out of clusters #eta acceptance, in trigger #eta-#varphi ",r),
4118  netabins,etamin,etamax,nphibins,phimin,phimax);
4119  fhFractionClusterOutConeEtaTrigEtaPhi->SetZTitle("#it{fraction}");
4120  fhFractionClusterOutConeEtaTrigEtaPhi->SetXTitle("#eta_{trigger}");
4121  fhFractionClusterOutConeEtaTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4122  outputContainer->Add(fhFractionClusterOutConeEtaTrigEtaPhi) ;
4123 
4124  fhFractionClusterOutConePhi = new TH2F("hFractionClusterOutConePhi",
4125  Form("Fraction of the isolation cone #it{R} = %2.2f, out of clusters #varphi acceptance",r),
4126  nptbins,ptmin,ptmax,100,0,1);
4127  fhFractionClusterOutConePhi->SetYTitle("#it{fraction}");
4128  fhFractionClusterOutConePhi->SetXTitle("#it{p}_{T,trigger} (GeV/#it{c})");
4129  outputContainer->Add(fhFractionClusterOutConePhi) ;
4130 
4131  fhFractionClusterOutConePhiTrigEtaPhi = new TH2F("hFractionClusterOutConePhiTrigEtaPhi",
4132  Form("Fraction of the isolation cone #it{R} = %2.2f, out of clusters #varphi acceptance, in trigger #eta-#varphi ",r),
4133  netabins,etamin,etamax,nphibins,phimin,phimax);
4134  fhFractionClusterOutConePhiTrigEtaPhi->SetZTitle("#it{fraction}");
4135  fhFractionClusterOutConePhiTrigEtaPhi->SetXTitle("#eta_{trigger}");
4136  fhFractionClusterOutConePhiTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4137  outputContainer->Add(fhFractionClusterOutConePhiTrigEtaPhi) ;
4138 
4139 
4140  fhConeSumPtSubvsConeSumPtTotPhiCluster = new TH2F("hConeSumPtSubvsConeSumPtTotPhiCluster",
4141  Form("#Sigma #it{p}_{T} in cone after bkg sub from #varphi band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4142  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4143  fhConeSumPtSubvsConeSumPtTotPhiCluster->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4144  fhConeSumPtSubvsConeSumPtTotPhiCluster->SetYTitle("#Sigma #it{p}_{T, sub} (GeV/#it{c})");
4145  outputContainer->Add(fhConeSumPtSubvsConeSumPtTotPhiCluster);
4146 
4147  fhConeSumPtSubNormvsConeSumPtTotPhiCluster = new TH2F("hConeSumPtSubNormvsConeSumPtTotPhiCluster",
4148  Form("#Sigma #it{p}_{T, norm} in cone after bkg sub from #varphi band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4149  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4150  fhConeSumPtSubNormvsConeSumPtTotPhiCluster->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4151  fhConeSumPtSubNormvsConeSumPtTotPhiCluster->SetYTitle("#Sigma #it{p}_{T, sub norm} (GeV/#it{c})");
4152  outputContainer->Add(fhConeSumPtSubNormvsConeSumPtTotPhiCluster);
4153 
4154  fhConeSumPtSubvsConeSumPtTotEtaCluster = new TH2F("hConeSumPtSubvsConeSumPtTotEtaCluster",
4155  Form("#Sigma #it{p}_{T} in cone after bkg sub from #eta band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4156  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4157  fhConeSumPtSubvsConeSumPtTotEtaCluster->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4158  fhConeSumPtSubvsConeSumPtTotEtaCluster->SetYTitle("#Sigma #it{p}_{T, sub} (GeV/#it{c})");
4159  outputContainer->Add(fhConeSumPtSubvsConeSumPtTotEtaCluster);
4160 
4161  fhConeSumPtSubNormvsConeSumPtTotEtaCluster = new TH2F("hConeSumPtSubNormvsConeSumPtTotEtaCluster",
4162  Form("#Sigma #it{p}_{T, norm} in cone after bkg sub from #eta band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4163  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4164  fhConeSumPtSubNormvsConeSumPtTotEtaCluster->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4165  fhConeSumPtSubNormvsConeSumPtTotEtaCluster->SetYTitle("#Sigma #it{p}_{T, sub norm} (GeV/#it{c})");
4166  outputContainer->Add(fhConeSumPtSubNormvsConeSumPtTotEtaCluster);
4167 
4168  fhConeSumPtVSUEClusterEtaBand = new TH2F("hConeSumPtVSUEClusterEtaBand",
4169  Form("#Sigma #it{p}_{T} in cone versus #Sigma #it{p}_{T} in #eta band for cluster (before normalization), R=%2.2f",r),
4170  nptsumbins,ptsummin,ptsummax,2*nptsumbins,ptsummin,2*ptsummax);
4171  fhConeSumPtVSUEClusterEtaBand->SetXTitle("#Sigma #it{p}_{T} cone (GeV/#it{c})");
4172  fhConeSumPtVSUEClusterEtaBand->SetYTitle("#Sigma #it{p}_{T} UE (GeV/#it{c})");
4173  outputContainer->Add(fhConeSumPtVSUEClusterEtaBand);
4174 
4175  fhConeSumPtVSUEClusterPhiBand = new TH2F("hConeSumPtVSUEClusterPhiBand",
4176  Form("#Sigma #it{p}_{T} in cone versus #Sigma #it{p}_{T} in #varphi band for cluster (before normalization), R=%2.2f",r),
4177  nptsumbins,ptsummin,ptsummax,8*nptsumbins,ptsummin,8*ptsummax);
4178  fhConeSumPtVSUEClusterPhiBand->SetXTitle("#Sigma #it{p}_{T} cone (GeV/#it{c})");
4179  fhConeSumPtVSUEClusterPhiBand->SetYTitle("#Sigma #it{p}_{T} UE (GeV/#it{c})");
4180  outputContainer->Add(fhConeSumPtVSUEClusterPhiBand);
4181  }
4182 
4184  {
4185  fhFractionCellOutConeEta = new TH2F("hFractionCellOutConeEta",
4186  Form("Fraction of the isolation cone #it{R} = %2.2f, out of cells #eta acceptance",r),
4187  nptbins,ptmin,ptmax,100,0,1);
4188  fhFractionCellOutConeEta->SetYTitle("#it{fraction}");
4189  fhFractionCellOutConeEta->SetXTitle("#it{p}_{T,trigger} (GeV/#it{c})");
4190  outputContainer->Add(fhFractionCellOutConeEta) ;
4191 
4192  fhFractionCellOutConeEtaTrigEtaPhi = new TH2F("hFractionCellOutConeEtaTrigEtaPhi",
4193  Form("Fraction of the isolation cone #it{R} = %2.2f, out of cells #eta acceptance, in trigger #eta-#varphi ",r),
4194  netabins,etamin,etamax,nphibins,phimin,phimax);
4195  fhFractionCellOutConeEtaTrigEtaPhi->SetZTitle("#it{fraction}");
4196  fhFractionCellOutConeEtaTrigEtaPhi->SetXTitle("#eta_{trigger}");
4197  fhFractionCellOutConeEtaTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4198  outputContainer->Add(fhFractionCellOutConeEtaTrigEtaPhi) ;
4199 
4200  fhFractionCellOutConePhi = new TH2F("hFractionCellOutConePhi",
4201  Form("Fraction of the isolation cone #it{R} = %2.2f, out of cells #varphi acceptance",r),
4202  nptbins,ptmin,ptmax,100,0,1);
4203  fhFractionCellOutConePhi->SetYTitle("#it{fraction}");
4204  fhFractionCellOutConePhi->SetXTitle("#it{p}_{T,trigger} (GeV/#it{c})");
4205  outputContainer->Add(fhFractionCellOutConePhi) ;
4206 
4207  fhFractionCellOutConePhiTrigEtaPhi = new TH2F("hFractionCellOutConePhiTrigEtaPhi",
4208  Form("Fraction of the isolation cone #it{R} = %2.2f, out of cells #varphi acceptance, in trigger #eta-#varphi ",r),
4209  netabins,etamin,etamax,nphibins,phimin,phimax);
4210  fhFractionCellOutConePhiTrigEtaPhi->SetZTitle("#it{fraction}");
4211  fhFractionCellOutConePhiTrigEtaPhi->SetXTitle("#eta_{trigger}");
4212  fhFractionCellOutConePhiTrigEtaPhi->SetYTitle("#varphi_{trigger} (rad)");
4213  outputContainer->Add(fhFractionCellOutConePhiTrigEtaPhi) ;
4214 
4215 
4216  fhConeSumPtSubvsConeSumPtTotPhiCell = new TH2F("hConeSumPtSubvsConeSumPtTotPhiCell",
4217  Form("#Sigma #it{p}_{T} in cone after bkg sub from #varphi band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4218  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4219  fhConeSumPtSubvsConeSumPtTotPhiCell->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4220  fhConeSumPtSubvsConeSumPtTotPhiCell->SetYTitle("#Sigma #it{p}_{T, sub} (GeV/#it{c})");
4221  outputContainer->Add(fhConeSumPtSubvsConeSumPtTotPhiCell);
4222 
4223  fhConeSumPtSubNormvsConeSumPtTotPhiCell = new TH2F("hConeSumPtSubNormvsConeSumPtTotPhiCell",
4224  Form("#Sigma #it{p}_{T, norm} in cone after bkg sub from #varphi band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4225  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4226  fhConeSumPtSubNormvsConeSumPtTotPhiCell->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4227  fhConeSumPtSubNormvsConeSumPtTotPhiCell->SetYTitle("#Sigma #it{p}_{T, sub norm} (GeV/#it{c})");
4228  outputContainer->Add(fhConeSumPtSubNormvsConeSumPtTotPhiCell);
4229 
4230  fhConeSumPtSubvsConeSumPtTotEtaCell = new TH2F("hConeSumPtSubvsConeSumPtTotEtaCell",
4231  Form("#Sigma #it{p}_{T} in cone after bkg sub from #eta band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4232  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4233  fhConeSumPtSubvsConeSumPtTotEtaCell->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4234  fhConeSumPtSubvsConeSumPtTotEtaCell->SetYTitle("#Sigma #it{p}_{T, sub} (GeV/#it{c})");
4235  outputContainer->Add(fhConeSumPtSubvsConeSumPtTotEtaCell);
4236 
4237  fhConeSumPtSubNormvsConeSumPtTotEtaCell = new TH2F("hConeSumPtSubNormvsConeSumPtTotEtaCell",
4238  Form("#Sigma #it{p}_{T, norm} in cone after bkg sub from #eta band vs #Sigma #it{p}_{T} in cone before bkg sub, R=%2.2f",r),
4239  nptsumbins,ptsummin,ptsummax,1.2*nptsumbins,-ptsummax*0.2,ptsummax);
4240  fhConeSumPtSubNormvsConeSumPtTotEtaCell->SetXTitle("#Sigma #it{p}_{T, tot} (GeV/#it{c})");
4241  fhConeSumPtSubNormvsConeSumPtTotEtaCell->SetYTitle("#Sigma #it{p}_{T, sub norm} (GeV/#it{c})");
4242  outputContainer->Add(fhConeSumPtSubNormvsConeSumPtTotEtaCell);
4243  }
4244  }
4245  }
4246 
4247  // Track only histograms
4248  if(GetIsolationCut()->GetParticleTypeInCone()!=AliIsolationCut::kOnlyNeutral)
4249  {
4250  fhConePtLeadTrack = new TH2F
4251  ("hConeLeadPtTrack",
4252  Form("Track leading in isolation cone for #it{R} = %2.2f",r),
4253  nptbins,ptmin,ptmax,nptbins,ptmin,ptmax);
4254  fhConePtLeadTrack->SetYTitle("#it{p}_{T, leading} (GeV/#it{c})");
4255  fhConePtLeadTrack->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4256  outputContainer->Add(fhConePtLeadTrack) ;
4257 
4258  fhPtTrackInCone = new TH2F
4259  ("hPtTrackInCone",
4260  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f",r),
4261  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4262  fhPtTrackInCone->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4263  fhPtTrackInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4264  outputContainer->Add(fhPtTrackInCone) ;
4265 
4266  if(IsDataMC())
4267  {
4268  TString mcChPartName[] = {"Pion","Kaon","Proton","Other"};
4269  for(Int_t imc = 0; imc < 4; imc++)
4270  {
4271  fhPtTrackInConeMCPrimary[imc] = new TH2F
4272  (Form("hPtTrackInCone_Primary_%s",mcChPartName[imc].Data()),
4273  Form("reconstructed #it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, primary MC %s",r,mcChPartName[imc].Data()),
4274  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4275  fhPtTrackInConeMCPrimary[imc]->SetYTitle("#it{p}_{T in cone}^{reco} (GeV/#it{c})");
4276  fhPtTrackInConeMCPrimary[imc]->SetXTitle("#it{p}_{T}^{reco} (GeV/#it{c})");
4277  outputContainer->Add(fhPtTrackInConeMCPrimary[imc]) ;
4278 
4279  fhPtTrackInConeMCSecondary[imc] = new TH2F
4280  (Form("hPtTrackInCone_Secondary_%s",mcChPartName[imc].Data()),
4281  Form("reconstructed #it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, secondary MC %s",r,mcChPartName[imc].Data()),
4282  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4283  fhPtTrackInConeMCSecondary[imc]->SetYTitle("#it{p}_{T in cone}^{reco} (GeV/#it{c})");
4284  fhPtTrackInConeMCSecondary[imc]->SetXTitle("#it{p}_{T}^{reco} (GeV/#it{c})");
4285  outputContainer->Add(fhPtTrackInConeMCSecondary[imc]) ;
4286 
4288  (Form("hPtTrackInCone_Gener_Primary_%s",mcChPartName[imc].Data()),
4289  Form("generated #it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, primary MC %s",r,mcChPartName[imc].Data()),
4290  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4291  fhPtTrackInConeMCPrimaryGener[imc]->SetYTitle("#it{p}_{T in cone}^{gener} (GeV/#it{c})");
4292  fhPtTrackInConeMCPrimaryGener[imc]->SetXTitle("#it{p}_{T}^{gener} (GeV/#it{c})");
4293  outputContainer->Add(fhPtTrackInConeMCPrimaryGener[imc]) ;
4294 
4296  (Form("hPtTrackInCone_Gener_Secondary_%s",mcChPartName[imc].Data()),
4297  Form("generated #it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, secondary MC %s",r,mcChPartName[imc].Data()),
4298  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4299  fhPtTrackInConeMCSecondaryGener[imc]->SetYTitle("#it{p}_{T in cone}^{gener} (GeV/#it{c})");
4300  fhPtTrackInConeMCSecondaryGener[imc]->SetXTitle("#it{p}_{T}^{gener} (GeV/#it{c})");
4301  outputContainer->Add(fhPtTrackInConeMCSecondaryGener[imc]) ;
4302  }
4303 
4304  }
4305 
4307  {
4308  fhPtTrackInConeExoTrigger = new TH2F("hPtTrackInConeExoTrigger",
4309  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, exotic trigger",r),
4310  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4311  fhPtTrackInConeExoTrigger->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4312  fhPtTrackInConeExoTrigger->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4313  outputContainer->Add(fhPtTrackInConeExoTrigger) ;
4314  }
4315 
4316  if(fStudyPtCutInCone)
4317  {
4319  ("hConeNTrackPerMinPtCut",
4320  Form("N tracks, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f",r),
4321  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nmultbin,multmin,multmax);
4322  fhConeNTrackPerMinPtCut->SetYTitle("#it{N}^{track}");
4323  fhConeNTrackPerMinPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4324  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4325  fhConeNTrackPerMinPtCut->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4326  outputContainer->Add(fhConeNTrackPerMinPtCut) ;
4327 
4329  ("hConeNTrackPerMinPtCutLargePtTrig",
4330  Form("N tracks, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
4331  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nmultbin,multmin,multmax);
4332  fhConeNTrackPerMinPtCutLargePtTrig->SetYTitle("#it{N}^{track}");
4333  fhConeNTrackPerMinPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4334  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4335  fhConeNTrackPerMinPtCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4336  outputContainer->Add(fhConeNTrackPerMinPtCutLargePtTrig) ;
4337 
4339  ("hConePtSumTrackPerMinPtCut",
4340  Form("Track #Sigma #it{p}_{T}, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f",r),
4341  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4342  fhConeSumPtTrackPerMinPtCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4343  fhConeSumPtTrackPerMinPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4344  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4345  fhConeSumPtTrackPerMinPtCut->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4346  outputContainer->Add(fhConeSumPtTrackPerMinPtCut) ;
4347 
4349  ("hConePtSumTrackPerMinPtCutLargePtTrig",
4350  Form("Track #Sigma #it{p}_{T}, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
4351  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4352  fhConeSumPtTrackPerMinPtCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4353  fhConeSumPtTrackPerMinPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4354  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4355  fhConeSumPtTrackPerMinPtCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4356  outputContainer->Add(fhConeSumPtTrackPerMinPtCutLargePtTrig) ;
4357 
4359  {
4361  ("hPerpConeNTrackPerMinPtCut",
4362  Form("N tracks, different #it{p}_{T} cuts in perpendicular cone for #it{R} = %2.2f",r),
4363  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nmultbin,multmin,multmax);
4364  fhPerpConeNTrackPerMinPtCut->SetYTitle("#it{N}^{track}");
4365  fhPerpConeNTrackPerMinPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4366  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4367  fhPerpConeNTrackPerMinPtCut->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4368  outputContainer->Add(fhPerpConeNTrackPerMinPtCut) ;
4369 
4371  ("hPerpConeNTrackPerMinPtCutLargePtTrig",
4372  Form("N tracks, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
4373  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nmultbin,multmin,multmax);
4374  fhPerpConeNTrackPerMinPtCutLargePtTrig->SetYTitle("#it{N}^{track}");
4375  fhPerpConeNTrackPerMinPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4376  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4377  fhPerpConeNTrackPerMinPtCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4378  outputContainer->Add(fhPerpConeNTrackPerMinPtCutLargePtTrig) ;
4379 
4381  ("hPerpConePtSumTrackPerMinPtCut",
4382  Form("Track #Sigma #it{p}_{T}, different #it{p}_{T} cuts in perpendicular cone for #it{R} = %2.2f",r),
4383  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4384  fhPerpConeSumPtTrackPerMinPtCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4385  fhPerpConeSumPtTrackPerMinPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4386  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4387  fhPerpConeSumPtTrackPerMinPtCut->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4388  outputContainer->Add(fhPerpConeSumPtTrackPerMinPtCut) ;
4389 
4391  ("hPerpConePtSumTrackPerMinPtCutLargePtTrig",
4392  Form("Track #Sigma #it{p}_{T}, different #it{p}_{T} cuts in perpendicular cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
4393  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4394  fhPerpConeSumPtTrackPerMinPtCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4395  fhPerpConeSumPtTrackPerMinPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4396  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4397  fhPerpConeSumPtTrackPerMinPtCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMinPtCutInCone[i-1]));
4398  outputContainer->Add(fhPerpConeSumPtTrackPerMinPtCutLargePtTrig) ;
4399  }
4400 
4402  ("hConePtSumTrackPerMaxPtCut",
4403  Form("Track #Sigma #it{p}_{T}, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f",r),
4404  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4405  fhConeSumPtTrackPerMaxPtCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4406  fhConeSumPtTrackPerMaxPtCut->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4407  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4408  fhConeSumPtTrackPerMaxPtCut->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMaxPtCutInCone[i-1]));
4409  outputContainer->Add(fhConeSumPtTrackPerMaxPtCut) ;
4410 
4412  ("hConePtSumTrackPerMaxPtCutLargePtTrig",
4413  Form("Track #Sigma #it{p}_{T}, different #it{p}_{T} cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
4414  fNPtCutsInCone,0.5,fNPtCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4415  fhConeSumPtTrackPerMaxPtCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4416  fhConeSumPtTrackPerMaxPtCutLargePtTrig->SetXTitle("#it{p}_{T, min} (GeV/#it{c})");
4417  for(Int_t i = 1; i <= fNPtCutsInCone; i++)
4418  fhConeSumPtTrackPerMaxPtCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.1f",fMaxPtCutInCone[i-1]));
4419  outputContainer->Add(fhConeSumPtTrackPerMaxPtCutLargePtTrig) ;
4420  }
4421 
4422  if(fStudyEtaCutInCone)
4423  {
4424  fhConeSumPtTrackPerEtaCut = new TH2F("hConePtSumTrackPerEtaCut",
4425  Form("Track #Sigma #it{p}_{T}, different #eta cuts in isolation cone for #it{R} = %2.2f",r),
4426  fNEtaCutsInCone,0.5,fNEtaCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4427  fhConeSumPtTrackPerEtaCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4428  fhConeSumPtTrackPerEtaCut->SetXTitle("#eta_{max}");
4429  for(Int_t i = 1; i <= fNEtaCutsInCone; i++)
4430  fhConeSumPtTrackPerEtaCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fEtaCutInCone[i-1]));
4431  outputContainer->Add(fhConeSumPtTrackPerEtaCut) ;
4432 
4433  fhConeSumPtTrackPerEtaCutLargePtTrig = new TH2F("hConePtSumTrackPerEtaCutLargePtTrig",
4434  Form("Track #Sigma #it{p}_{T}, different #eta cuts in isolation cone for #it{R} = %2.2f, #it{p}_{T}^{trig} > 10 GeV",r),
4435  fNEtaCutsInCone,0.5,fNEtaCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4436  fhConeSumPtTrackPerEtaCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4437  fhConeSumPtTrackPerEtaCutLargePtTrig->SetXTitle("#eta_{max}");
4438  for(Int_t i = 1; i <= fNEtaCutsInCone; i++)
4439  fhConeSumPtTrackPerEtaCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fEtaCutInCone[i-1]));
4440  outputContainer->Add(fhConeSumPtTrackPerEtaCutLargePtTrig) ;
4441  }
4442 
4443  if(fStudyRCutInCone)
4444  {
4446  ("hConePtSumTrackPerRCut","Track #Sigma #it{p}_{T}, different #it{R} cuts",
4447  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4448  fhConeSumPtTrackPerRCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4449  fhConeSumPtTrackPerRCut->SetXTitle("#it{R}");
4450  for(Int_t i = 1; i <= fNRCutsInCone; i++)
4451  fhConeSumPtTrackPerRCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
4452  outputContainer->Add(fhConeSumPtTrackPerRCut) ;
4453 
4455  ("hConePtSumTrackPerRCutLargePtTrig","Track #Sigma #it{p}_{T}, different #it{R} cuts, #it{p}_{T}^{trig} > 10 GeV",
4456  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4457  fhConeSumPtTrackPerRCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4458  fhConeSumPtTrackPerRCutLargePtTrig->SetXTitle("#it{R}");
4459  for(Int_t i = 1; i <= fNRCutsInCone; i++)
4460  fhConeSumPtTrackPerRCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
4461  outputContainer->Add(fhConeSumPtTrackPerRCutLargePtTrig) ;
4462 
4464  ("hPtTrackInConePerRCut","Track #it{p}_{T}, different #it{R} cuts",
4465  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4466  fhPtTrackInConePerRCut->SetYTitle("#it{p}_{T}^{track} (GeV/#it{c})");
4467  fhPtTrackInConePerRCut->SetXTitle("#it{R}");
4468  for(Int_t i = 1; i <= fNRCutsInCone; i++)
4469  fhPtTrackInConePerRCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
4470  outputContainer->Add(fhPtTrackInConePerRCut) ;
4471 
4473  ("hPtTrackInConePerRCutLargePtTrig","Track #it{p}_{T}, different #it{R} cuts, #it{p}_{T}^{trig} > 10 GeV",
4474  fNRCutsInCone,0.5,fNRCutsInCone+0.5,nptsumbins,ptsummin,ptsummax);
4475  fhPtTrackInConePerRCutLargePtTrig->SetYTitle("#it{p}_{T}^{track} (GeV/#it{c})");
4476  fhPtTrackInConePerRCutLargePtTrig->SetXTitle("#it{R}");
4477  for(Int_t i = 1; i <= fNRCutsInCone; i++)
4478  fhPtTrackInConePerRCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fRCutInCone[i-1]));
4479  outputContainer->Add(fhPtTrackInConePerRCutLargePtTrig) ;
4480  }
4481 
4483  {
4485  ("hConePtSumTrackPerNCellCut","Track #Sigma #it{p}_{T}, different #it{N}_{cell} cuts",
4486  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4487  fhConeSumPtTrackPerNCellCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4488  fhConeSumPtTrackPerNCellCut->SetXTitle("#it{N}_{cell}^{min}");
4489  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
4490  fhConeSumPtTrackPerNCellCut->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
4491  outputContainer->Add(fhConeSumPtTrackPerNCellCut) ;
4492 
4494  ("hConePtSumTrackPerNCellCutLargePtTrig","Track #Sigma #it{p}_{T}, different #it{N}_{cell} cuts, #it{p}_{T}^{trig} > 10 GeV",
4495  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4496  fhConeSumPtTrackPerNCellCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4497  fhConeSumPtTrackPerNCellCutLargePtTrig->SetXTitle("#it{N}_{cell}^{min}");
4498  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
4499  fhConeSumPtTrackPerNCellCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
4500  outputContainer->Add(fhConeSumPtTrackPerNCellCutLargePtTrig) ;
4501 
4503  ("hPtTrackInConePerNCellCut","Track #it{p}_{T}, different #it{N}_{cell} cuts",
4504  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4505  fhPtTrackInConePerNCellCut->SetYTitle("#it{p}_{T}^{track} (GeV/#it{c})");
4506  fhPtTrackInConePerNCellCut->SetXTitle("#it{N}_{cell}^{min}");
4507  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
4508  fhPtTrackInConePerNCellCut->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
4509  outputContainer->Add(fhPtTrackInConePerNCellCut) ;
4510 
4512  ("hPtTrackInConePerNCellCutLargePtTrig","Track #it{p}_{T}, different #it{N}_{cell} cuts, #it{p}_{T}^{trig} > 10 GeV",
4513  fNNCellsInCandidate,0.5,fNNCellsInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4514  fhPtTrackInConePerNCellCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T}^{track} (GeV/#it{c})");
4515  fhPtTrackInConePerNCellCutLargePtTrig->SetXTitle("#it{N}_{cell}^{min}");
4516  for(Int_t i = 1; i <= fNNCellsInCandidate; i++)
4517  fhPtTrackInConePerNCellCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%d",fNCellsInCandidate[i-1]));
4518  outputContainer->Add(fhPtTrackInConePerNCellCutLargePtTrig) ;
4519 
4521  ("hConePtSumTrackPerExoCut","Track #Sigma #it{p}_{T}, different exoticity cuts",
4522  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4523  fhConeSumPtTrackPerExoCut->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4524  fhConeSumPtTrackPerExoCut->SetXTitle("exoticity");
4525  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
4526  fhConeSumPtTrackPerExoCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
4527  outputContainer->Add(fhConeSumPtTrackPerExoCut) ;
4528 
4530  ("hConePtSumTrackPerExoCutLargePtTrig","Track #Sigma #it{p}_{T}, different exoticity cuts, #it{p}_{T}^{trig} > 10 GeV",
4531  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4532  fhConeSumPtTrackPerExoCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4533  fhConeSumPtTrackPerExoCutLargePtTrig->SetXTitle("exoticity");
4534  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
4535  fhConeSumPtTrackPerExoCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
4536  outputContainer->Add(fhConeSumPtTrackPerExoCutLargePtTrig) ;
4537 
4539  ("hPtTrackInConePerExoCut","Track #it{p}_{T}, different exoticity cuts",
4540  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4541  fhPtTrackInConePerExoCut->SetYTitle("#it{p}_{T}^{track} (GeV/#it{c})");
4542  fhPtTrackInConePerExoCut->SetXTitle("exoticity");
4543  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
4544  fhPtTrackInConePerExoCut->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
4545  outputContainer->Add(fhPtTrackInConePerExoCut) ;
4546 
4548  ("hPtTrackInConePerExoCutLargePtTrig","Track #it{p}_{T}, different exoticity cuts, #it{p}_{T}^{trig} > 10 GeV",
4549  fNExoCutInCandidate,0.5,fNExoCutInCandidate+0.5,nptsumbins,ptsummin,ptsummax);
4550  fhPtTrackInConePerExoCutLargePtTrig->SetYTitle("#Sigma #it{p}_{T}^{track} (GeV/#it{c})");
4551  fhPtTrackInConePerExoCutLargePtTrig->SetXTitle("exoticity");
4552  for(Int_t i = 1; i <= fNExoCutInCandidate; i++)
4553  fhPtTrackInConePerExoCutLargePtTrig->GetXaxis()->SetBinLabel(i, Form("%2.2f",fExoCutInCandidate[i-1]));
4554  outputContainer->Add(fhPtTrackInConePerExoCutLargePtTrig) ;
4555  }
4556 
4557 
4558  fhConeSumPtTrack = new TH2F
4559  ("hConePtSumTrack",
4560  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f",r),
4561  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4562  fhConeSumPtTrack->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4563  fhConeSumPtTrack->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4564  outputContainer->Add(fhConeSumPtTrack) ;
4565 
4567  {
4569  ("hConePtSumTrackExoTrigger",
4570  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, exo trigger",r),
4571  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4572  fhConeSumPtTrackExoTrigger->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4573  fhConeSumPtTrackExoTrigger->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4574  outputContainer->Add(fhConeSumPtTrackExoTrigger) ;
4575  }
4576 
4577  if(fStudyTracksInCone)
4578  {
4579  Int_t ntofbins = 1000;
4580  Int_t mintof = -500;
4581  Int_t maxtof = 500;
4582 
4583  fhTrackTOFInCone = new TH2F
4584  ("hTrackTOFInCone","TOF signal vs track #it{p}_{T}",
4585  nptbins,ptmin,ptmax,ntofbins,mintof,maxtof);
4586  fhTrackTOFInCone->SetYTitle("TOF signal (ns)");
4587  fhTrackTOFInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4588  outputContainer->Add(fhTrackTOFInCone);
4589 
4591  {
4593  ("hTrackTOFInConeExoTrigger","TOF signal vs track #it{p}_{T}, exoticity > 0.97",
4594  nptbins,ptmin,ptmax,ntofbins,mintof,maxtof);
4595  fhTrackTOFInConeExoTrigger->SetYTitle("TOF signal (ns)");
4596  fhTrackTOFInConeExoTrigger->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4597  outputContainer->Add(fhTrackTOFInConeExoTrigger);
4598  }
4599 
4600  fhTrackTOFInConeBC0 = new TH2F
4601  ("hTrackTOFInConeBC0","TOF signal vs track #it{p}_{T}, BC=0",
4602  nptbins,ptmin,ptmax,ntofbins,mintof,maxtof);
4603  fhTrackTOFInConeBC0->SetYTitle("TOF signal (ns)");
4604  fhTrackTOFInConeBC0->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4605  outputContainer->Add(fhTrackTOFInConeBC0);
4606 
4607  fhPtTrackInConeVtxBC0 = new TH2F("hPtTrackInConeVtxBC0",
4608  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, TOF from BC==0",r),
4609  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4610  fhPtTrackInConeVtxBC0->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4611  fhPtTrackInConeVtxBC0->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4612  outputContainer->Add(fhPtTrackInConeVtxBC0) ;
4613 
4614  fhEtaPhiTrackInCone = new TH2F("hEtaPhiTrackInCone",
4615  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f",r),
4616  netabins,-1,1,nphibins,0,TMath::TwoPi());
4617  fhEtaPhiTrackInCone->SetXTitle("#eta");
4618  fhEtaPhiTrackInCone->SetYTitle("#varphi (rad)");
4619  outputContainer->Add(fhEtaPhiTrackInCone) ;
4620 
4621  fhEtaTrackInCone = new TH2F("hEtaTrackInCone",
4622  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f",r),
4623  nptbins,ptmin,ptmax,netabins,-1,1);
4624  fhEtaTrackInCone->SetYTitle("#eta");
4625  fhEtaTrackInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4626  outputContainer->Add(fhEtaTrackInCone) ;
4627 
4628  fhPhiTrackInCone = new TH2F("hPhiTrackInCone",
4629  Form("#varphi vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f",r),
4630  nptbins,ptmin,ptmax,nphibins,0,TMath::TwoPi());
4631  fhPhiTrackInCone->SetYTitle("#varphi (rad)");
4632  fhPhiTrackInCone->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4633  outputContainer->Add(fhPhiTrackInCone) ;
4634 
4635  //
4636  // Different track cuts:
4637  //
4638  // TOF info
4639  //
4640  fhConeSumPtTrackTOFBC0 = new TH2F("hConePtSumTrackTOFBC0",
4641  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, track TOF BC=0",r),
4642  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4643  fhConeSumPtTrackTOFBC0->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4644  fhConeSumPtTrackTOFBC0->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4645  outputContainer->Add(fhConeSumPtTrackTOFBC0) ;
4646 
4647  fhConeSumPtTrackTOFBCN = new TH2F("hConePtSumTrackTOFBCN",
4648  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, track TOF BC!=0",r),
4649  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4650  fhConeSumPtTrackTOFBCN->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4651  fhConeSumPtTrackTOFBCN->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4652  outputContainer->Add(fhConeSumPtTrackTOFBCN) ;
4653 
4654  fhConeSumPtTrackTOFNo = new TH2F("hConePtSumTrackTOFNo",
4655  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, track no TOF",r),
4656  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4657  fhConeSumPtTrackTOFNo->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4658  fhConeSumPtTrackTOFNo->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4659  outputContainer->Add(fhConeSumPtTrackTOFNo) ;
4660 
4661  fhPtTrackInConeTOFBC0 = new TH2F("hPtTrackInConeTOFBC0",
4662  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, TOF from BC=0",r),
4663  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4664  fhPtTrackInConeTOFBC0->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4665  fhPtTrackInConeTOFBC0->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4666  outputContainer->Add(fhPtTrackInConeTOFBC0) ;
4667 
4668  fhPtTrackInConeTOFBCN = new TH2F("hPtTrackInConeTOFBCN",
4669  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, TOF from BC!=0",r),
4670  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4671  fhPtTrackInConeTOFBCN->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4672  fhPtTrackInConeTOFBCN->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4673  outputContainer->Add(fhPtTrackInConeTOFBCN) ;
4674 
4675  fhPtTrackInConeTOFNo = new TH2F("hPtTrackInConeTOFNo",
4676  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, no TOF",r),
4677  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4678  fhPtTrackInConeTOFNo->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4679  fhPtTrackInConeTOFNo->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4680  outputContainer->Add(fhPtTrackInConeTOFNo) ;
4681 
4682 
4683  fhEtaPhiTrackInConeTOFBC0 = new TH2F("hEtaPhiTrackInConeTOFBC0",
4684  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f, TOF BC=0",r),
4685  netabins,-1,1,nphibins,0,TMath::TwoPi());
4686  fhEtaPhiTrackInConeTOFBC0->SetXTitle("#eta");
4687  fhEtaPhiTrackInConeTOFBC0->SetYTitle("#varphi (rad)");
4688  outputContainer->Add(fhEtaPhiTrackInConeTOFBC0) ;
4689 
4690  fhEtaPhiTrackInConeTOFBCN = new TH2F("hEtaPhiTrackInConeTOFBCN",
4691  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f, TOF BC!=0",r),
4692  netabins,-1,1,nphibins,0,TMath::TwoPi());
4693  fhEtaPhiTrackInConeTOFBCN->SetXTitle("#eta");
4694  fhEtaPhiTrackInConeTOFBCN->SetYTitle("#varphi (rad)");
4695  outputContainer->Add(fhEtaPhiTrackInConeTOFBCN) ;
4696 
4697  fhEtaPhiTrackInConeTOFNo = new TH2F("hEtaPhiTrackInConeTOFNo",
4698  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f, no TOF",r),
4699  netabins,-1,1,nphibins,0,TMath::TwoPi());
4700  fhEtaPhiTrackInConeTOFNo->SetXTitle("#eta");
4701  fhEtaPhiTrackInConeTOFNo->SetYTitle("#varphi (rad)");
4702  outputContainer->Add(fhEtaPhiTrackInConeTOFNo) ;
4703 
4704  fhEtaTrackInConeTOFBC0 = new TH2F("hEtaTrackInConeTOFBC0",
4705  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, TOF BC=0",r),
4706  nptbins,ptmin,ptmax,netabins,-1,1);
4707  fhEtaTrackInConeTOFBC0->SetYTitle("#eta");
4708  fhEtaTrackInConeTOFBC0->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4709  outputContainer->Add(fhEtaTrackInConeTOFBC0) ;
4710 
4711  fhEtaTrackInConeTOFBCN = new TH2F("hEtaTrackInConeTOFBCN",
4712  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, TOF BC!=0",r),
4713  nptbins,ptmin,ptmax,netabins,-1,1);
4714  fhEtaTrackInConeTOFBCN->SetYTitle("#eta");
4715  fhEtaTrackInConeTOFBCN->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4716  outputContainer->Add(fhEtaTrackInConeTOFBCN) ;
4717 
4718  fhEtaTrackInConeTOFNo = new TH2F("hEtaTrackInConeTOFNo",
4719  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, no TOF",r),
4720  nptbins,ptmin,ptmax,netabins,-1,1);
4721  fhEtaTrackInConeTOFNo->SetYTitle("#eta");
4722  fhEtaTrackInConeTOFNo->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4723  outputContainer->Add(fhEtaTrackInConeTOFNo) ;
4724 
4725  fhPhiTrackInConeTOFBC0 = new TH2F("hPhiTrackInConeTOFBC0",
4726  Form("#varphi vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, TOF BC=0",r),
4727  nptbins,ptmin,ptmax,nphibins,0,TMath::TwoPi());
4728  fhPhiTrackInConeTOFBC0->SetYTitle("#varphi (rad)");
4729  fhPhiTrackInConeTOFBC0->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4730  outputContainer->Add(fhPhiTrackInConeTOFBC0) ;
4731 
4732  fhPhiTrackInConeTOFBCN = new TH2F("hPhiTrackInConeTOFBCN",
4733  Form("#varphi vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, TOF BC!=0",r),
4734  nptbins,ptmin,ptmax,nphibins,0,TMath::TwoPi());
4735  fhPhiTrackInConeTOFBCN->SetYTitle("#varphi (rad)");
4736  fhPhiTrackInConeTOFBCN->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4737  outputContainer->Add(fhPhiTrackInConeTOFBCN) ;
4738 
4739  fhPhiTrackInConeTOFNo = new TH2F("hPhiTrackInConeTOFNo",
4740  Form("#varphi vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, no TOF",r),
4741  nptbins,ptmin,ptmax,nphibins,0,TMath::TwoPi());
4742  fhPhiTrackInConeTOFNo->SetYTitle("#varphi (rad)");
4743  fhPhiTrackInConeTOFNo->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4744  outputContainer->Add(fhPhiTrackInConeTOFNo) ;
4745 
4746  //
4747  // ITS info
4748  //
4749  fhConeSumPtTrackITSRefitOnSPDOn = new TH2F("hConePtSumTrackITSRefitOnSPDOn",
4750  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, track ITS Refit SPD On",r),
4751  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4752  fhConeSumPtTrackITSRefitOnSPDOn->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4753  fhConeSumPtTrackITSRefitOnSPDOn->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4754  outputContainer->Add(fhConeSumPtTrackITSRefitOnSPDOn) ;
4755 
4756  fhConeSumPtTrackITSRefitOnSPDOff = new TH2F("hConePtSumTrackITSRefitOnSPDOff",
4757  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, track ITS Refit SPD Off",r),
4758  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4759  fhConeSumPtTrackITSRefitOnSPDOff->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4760  fhConeSumPtTrackITSRefitOnSPDOff->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4761  outputContainer->Add(fhConeSumPtTrackITSRefitOnSPDOff) ;
4762 
4763  fhConeSumPtTrackITSRefitOffSPDOff = new TH2F("hConePtSumTrackITSRefitOffSPDOff",
4764  Form("Track #Sigma #it{p}_{T} in isolation cone for #it{R} = %2.2f, track no ITS Refit SPD Off",r),
4765  nptbins,ptmin,ptmax,nptsumbins,ptsummin,ptsummax);
4766  fhConeSumPtTrackITSRefitOffSPDOff->SetYTitle("#Sigma #it{p}_{T} (GeV/#it{c})");
4767  fhConeSumPtTrackITSRefitOffSPDOff->SetXTitle("#it{p}_{T, trigger} (GeV/#it{c})");
4768  outputContainer->Add(fhConeSumPtTrackITSRefitOffSPDOff) ;
4769 
4770  fhPtTrackInConeITSRefitOnSPDOn = new TH2F("hPtTrackInConeITSRefitOnSPDOn",
4771  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, TOF from BC=0",r),
4772  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4773  fhPtTrackInConeITSRefitOnSPDOn->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4774  fhPtTrackInConeITSRefitOnSPDOn->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4775  outputContainer->Add(fhPtTrackInConeITSRefitOnSPDOn) ;
4776 
4777  fhPtTrackInConeITSRefitOnSPDOff = new TH2F("hPtTrackInConeITSRefitOnSPDOff",
4778  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, TOF from BC!=0",r),
4779  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4780  fhPtTrackInConeITSRefitOnSPDOff->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4781  fhPtTrackInConeITSRefitOnSPDOff->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4782  outputContainer->Add(fhPtTrackInConeITSRefitOnSPDOff) ;
4783 
4784  fhPtTrackInConeITSRefitOffSPDOff = new TH2F("hPtTrackInConeITSRefitOffSPDOff",
4785  Form("#it{p}_{T} of tracks in isolation cone for #it{R} = %2.2f, no ITS Refit SPD Off",r),
4786  nptbins,ptmin,ptmax,nptinconebins,ptinconemin,ptinconemax);
4787  fhPtTrackInConeITSRefitOffSPDOff->SetYTitle("#it{p}_{T in cone} (GeV/#it{c})");
4788  fhPtTrackInConeITSRefitOffSPDOff->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4789  outputContainer->Add(fhPtTrackInConeITSRefitOffSPDOff) ;
4790 
4791 
4792  fhEtaPhiTrackInConeITSRefitOnSPDOn = new TH2F("hEtaPhiTrackInConeITSRefitOnSPDOn",
4793  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f, ITS Refit SPD On",r),
4794  netabins,-1,1,nphibins,0,TMath::TwoPi());
4795  fhEtaPhiTrackInConeITSRefitOnSPDOn->SetXTitle("#eta");
4796  fhEtaPhiTrackInConeITSRefitOnSPDOn->SetYTitle("#varphi (rad)");
4797  outputContainer->Add(fhEtaPhiTrackInConeITSRefitOnSPDOn) ;
4798 
4799  fhEtaPhiTrackInConeITSRefitOnSPDOff = new TH2F("hEtaPhiTrackInConeITSRefitOnSPDOff",
4800  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f, ITS Refit SPD Off",r),
4801  netabins,-1,1,nphibins,0,TMath::TwoPi());
4802  fhEtaPhiTrackInConeITSRefitOnSPDOff->SetXTitle("#eta");
4803  fhEtaPhiTrackInConeITSRefitOnSPDOff->SetYTitle("#varphi (rad)");
4804  outputContainer->Add(fhEtaPhiTrackInConeITSRefitOnSPDOff) ;
4805 
4806  fhEtaPhiTrackInConeITSRefitOffSPDOff = new TH2F("hEtaPhiTrackInConeITSRefitOffSPDOff",
4807  Form("#eta vs #varphi of Tracks in cone for #it{R} = %2.2f, no ITS Refit SPD Off",r),
4808  netabins,-1,1,nphibins,0,TMath::TwoPi());
4809  fhEtaPhiTrackInConeITSRefitOffSPDOff->SetXTitle("#eta");
4810  fhEtaPhiTrackInConeITSRefitOffSPDOff->SetYTitle("#varphi (rad)");
4811  outputContainer->Add(fhEtaPhiTrackInConeITSRefitOffSPDOff) ;
4812 
4813  fhEtaTrackInConeITSRefitOnSPDOn = new TH2F("hEtaTrackInConeITSRefitOnSPDOn",
4814  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, ITS Refit SPD On",r),
4815  nptbins,ptmin,ptmax,netabins,-1,1);
4816  fhEtaTrackInConeITSRefitOnSPDOn->SetYTitle("#eta");
4817  fhEtaTrackInConeITSRefitOnSPDOn->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4818  outputContainer->Add(fhEtaTrackInConeITSRefitOnSPDOn) ;
4819 
4820  fhEtaTrackInConeITSRefitOnSPDOff = new TH2F("hEtaTrackInConeITSRefitOnSPDOff",
4821  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, ITS Refit SPD Off",r),
4822  nptbins,ptmin,ptmax,netabins,-1,1);
4823  fhEtaTrackInConeITSRefitOnSPDOff->SetYTitle("#eta");
4824  fhEtaTrackInConeITSRefitOnSPDOff->SetXTitle("#it{p}_{T} (GeV/#it{c})");
4825  outputContainer->Add(fhEtaTrackInConeITSRefitOnSPDOff) ;
4826 
4827  fhEtaTrackInConeITSRefitOffSPDOff = new TH2F("hEtaTrackInConeITSRefitOffSPDOff",
4828  Form("#eta vs #it{p}_{T} of Tracks in cone for #it{R} = %2.2f, no ITS Refit SPD Off",r),
4829  nptbins,ptmin,ptmax,netabins,-1,1);