AliPhysics  master (3d17d9d)
AliAnaCaloExotics.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 is hereby granted *
9  * without fee, provided that the above copyright notice appears in all *
10  * copies and that both the copyright notice and this permission notice *
11  * appear in the supporting documentation. The authors make no claims *
12  * about the suitability of this software for any purpose. It is *
13  * provided "as is" without express or implied warranty. *
14  **************************************************************************/
15 
16 // --- ROOT system ---
17 #include <TObjArray.h>
18 #include <TDatabasePDG.h>
19 #include <TH3F.h>
20 #include <TObjString.h>
21 
22 //---- AliRoot system ----
23 #include "AliAnaCaloExotics.h"
24 #include "AliCaloTrackReader.h"
25 #include "AliVCaloCells.h"
26 #include "AliFiducialCut.h"
27 #include "AliVCluster.h"
28 #include "AliVTrack.h"
29 #include "AliVEvent.h"
30 #include "AliMCEvent.h"
31 #include "AliVEventHandler.h"
32 #include "AliVParticle.h"
33 #include "AliMCAnalysisUtils.h"
34 #include "TCustomBinning.h"
35 
36 // --- Detectors ---
37 #include "AliPHOSGeoUtils.h"
38 #include "AliEMCALGeometry.h"
39 
41 ClassImp(AliAnaCaloExotics) ;
43 
44 //__________________________________________
47 //__________________________________________
50 
51 fCellAmpMin(), fEMinForExo(0),
52 fExoCut(0), fNCellHighCut(0),
53 fTimeCutMin(-10000), fTimeCutMax(10000),
54 fHighEnergyCutSM(0), fHighNCellsCutSM(0),
55 fLowEnergyCutSM3(0), fLowNCellsCutSM3(0),
56 fEventMaxNumberOfStrips(0),
57 fLowEnergyCutSM3Strip(0), fLowNCellsCutSM3Strip(0),
58 fCellEnMax(0), fConstantTimeShift(0),
59 fClusterMomentum(),
60 
61 fLED20(0), fLED12(0),
62 fLED20Time(0), fLED12Time(0),
63 fAcceptEvent(1), fEventNStripActive(0),
64 
65 fFillCellHisto(1), fFillAllCellEventParamHisto(1),
66 fFill1CellHisto(0),
67 fFillStripHisto(1),
68 fFillMatchingHisto(0), fFillSameDiffFracHisto(0),
69 fFillExoEnMinCut(0), fFillAllCellSameTCardHisto(0),
70 fFillPerSMHisto(0), fFillClusterColRowHisto(0),
71 fFillOpenTimeHisto(1), fFillExo50ns(0),
72 fFillClusterHistoAfterEventCut(1),
73 
74 // Histograms
75 fhNClusterPerEventNCellHigh20(0), fhNClusterPerEventNCellHigh12(0),
76 fhNClusterPerEventExotic(0),
77 fhNClusterPerEventExotic1Cell(0), fhNClusterPerEventExoticNCell(0),
78 
79 fh2NClusterPerEventNCellHigh20(0), fh2NClusterPerEventNCellHigh12(0),
80 fh2NClusterPerEventExotic(0),
81 fh2NClusterPerEventExotic1Cell(0), fh2NClusterPerEventExoticNCell(0),
82 fh2NClusterPerEventExoticAmpMax(0),
83 
84 fhExoticityEClus(0),
85 fhExoticityEClusPerSM(0), fhExoticityEMaxCell(0),
86 fhExoticityEClusTrackMatch(0), fhExoticity1Cell(0),
87 
88 fhNCellsPerCluster(0), fhNCellsPerClusterW(0), fhNCellsPerClusterTimeDiff(0),
89 fhNCellsPerClusterEMaxCell(0), fhNCellsPerClusterWEMaxCell(0),
90 fhNCellsPerClusterOpenTime(0), fhNCellsPerClusterWOpenTime(0),
91 fhNCellsPerClusterEMaxCellOpenTime(0), fhNCellsPerClusterWEMaxCellOpenTime(0),
92 fhNCellsPerClusterExo(0),
93 fhNCellsPerClusterPerSM(0), fhNCellsPerClusterWPerSM(0),
94 fhNCellsPerClusterTrackMatch(0), fhNCellsPerClusterExoTrackMatch(0),
95 fhNCellsPerClusterM02(0),
96 
97 fhEtaPhiGridExoEnCut(0),
98 fhEtaPhiGridEnExoCut(0), fhEtaPhiGridEn1Cell(0),
99 fhEtaPhiGridEnHighNCells(0), fhEtaPhiGridNCellEnCut(0),
100 
101 fhTimeEnergyExo(0), fhTimeEnergy1Cell(0),
102 fhTimeDiffClusCellExo(0), fhTimeDiffClusCellDiffTCardExo(0), fhTimeDiffClusCellSameTCardExo(0),
103 fhTimeDiffWClusCellExo(0), fhTimeDiffAmpClusCellExo(0),
104 fhTimeEnergyM02(0), fhTimeDiffClusCellM02(0),
105 fhTimeEnergyNCells(0), fhTimeEnergyNCellsW(0),
106 fhTimeNCellCut(0),
107 
108 fhM02EnergyExo(0), fhM20EnergyExoM02MinCut(0),
109 
110 // Other ncell
111 fhNCellsPerClusterSame(0), fhNCellsPerClusterDiff(0),
112 fhNCellsPerClusterSame5(0), fhNCellsPerClusterDiff5(0),
113 fhNCellsPerClusterSameW (0), fhNCellsPerClusterDiffW (0),
114 fhNCellsPerClusterSameDiff(0), fhNCellsPerClusterSameDiffW(0), fhNCellsPerClusterSameDiffTimeDiff(0),
115 fhNCellsPerClusterSameFrac(0), fhNCellsPerClusterSameFracExo(0),
116 fhNCellsPerClusterSameFracW(0), fhNCellsPerClusterSameFracWExo(0),
117 
118 // Other Exoticity definitions
119 fhExoSame(0), fhExoDiff(0),
120 fhExoSame5(0), fhExoDiff5(0),
121 
122 fhFracEnDiffSame(0), fhFracNCellDiffSame(0), fhFracEnNCellDiffSame(0),
123 fhFracEnDiffSameW(0), fhFracNCellDiffSameW(0), fhFracEnNCellDiffSameW(0),
124 fhFracEnDiffSame5(0), fhFracNCellDiffSame5(0), fhFracEnNCellDiffSame5(0),
125 
126 fhFracEnDiffSameExo(0), fhFracNCellDiffSameExo(0), fhFracEnNCellDiffSameExo(0),
127 fhFracEnDiffSameWExo(0), fhFracNCellDiffSameWExo(0), fhFracEnNCellDiffSameWExo(0),
128 fhFracEnDiffSame5Exo(0), fhFracNCellDiffSame5Exo(0), fhFracEnNCellDiffSame5Exo(0),
129 
130 fhFracEnDiffSameEnCut(0), fhFracNCellDiffSameEnCut(0), fhFracEnNCellDiffSameEnCut(0),
131 fhFracEnDiffSameWEnCut(0), fhFracNCellDiffSameWEnCut(0), fhFracEnNCellDiffSameWEnCut(0),
132 fhFracEnDiffSame5EnCut(0), fhFracNCellDiffSame5EnCut(0), fhFracEnNCellDiffSame5EnCut(0),
133 
134 fhCellEnSameExo(0), fhCellEnDiffExo(0),
135 fhCellEnNCellWOpenTime(0), fhCellEnNCellW(0),
136 fhCellEnNCellWEMaxOpenTime(0), fhCellEnNCellWEMax(0),
137 fhCellTimeDiffNCellWOpenTime(0), fhCellTimeDiffNCellW(0),
138 fhCellTimeDiffNCellWEMaxOpenTime(0), fhCellTimeDiffNCellWEMax(0),
139 
140 fhCellMaxClusterEnOpenTime(0), fhCellMaxClusterEn(0),
141 fhCellMaxClusterEnRatioOpenTime(0), fhCellMaxClusterEnRatio(0),
142 fhCellMaxClusterEnRatioNCellWOpenTime(0), fhCellMaxClusterEnRatioNCellW(0),
143 fhCellMaxClusterEnRatioExo(0),
144 
145 // Exoticity for different E min cut
146 fhExoticityWEClus(0), fhNCellsPerClusterExoW(0),
147 fhTimeEnergyExoW(0), fhM02EnergyExoW(0),
148 fhExoticityECellMinCut(0),
149 
150 fhNCellsPerClusterMinEnCut(0),
151 fhNCellsPerClusterDiffMinEnCut(0), fhNCellsPerClusterSameMinEnCut(0),
152 
153 // All cells in same T-Card
154 fhExoticityEClusAllSameTCard(0), fhM02EnergyAllSameTCard(0),
155 fhNCellsPerClusterAllSameTCard(0), fhEtaPhiGridExoEnCutSameFracCut(0),
156 fhExoticityEClusAllSameTCardW(0), fhM02EnergyAllSameTCardW(0),
157 fhNCellsPerClusterAllSameTCardW(0), fhEtaPhiGridExoEnCutSameFracCutW(0),
158 fhExoticityEClusAllSameTCardMinEnCut(0), fhM02EnergyAllSameTCardMinEnCut(0),
159 fhNCellsPerClusterAllSameTCardMinEnCut(0),
160 
161 // 50 ns cut
162 
163 fhExoticity50nsEClus(0), fhExoticity50ns1Cell(0),
164 fhExoticity50nsEClusAllSameTCard(0),
165 fhNCellsPerClusterExo50ns(0), fhM02EnergyExo50ns(0),
166 
167 // Track matching vs exoticity
168 fhTrackMatchedDEtaNegExo(0), fhTrackMatchedDPhiNegExo(0), fhTrackMatchedDEtaDPhiNegExo(0),
169 fhTrackMatchedDEtaPosExo(0), fhTrackMatchedDPhiPosExo(0), fhTrackMatchedDEtaDPhiPosExo(0),
170 fhEOverPExo(0),
171 
172 // Track matching of 1 cell clusters
173 fhTrackMatchedDEtaNeg1Cell(0), fhTrackMatchedDPhiNeg1Cell(0), fhTrackMatchedDEtaDPhiNeg1Cell(0),
174 fhTrackMatchedDEtaPos1Cell(0), fhTrackMatchedDPhiPos1Cell(0), fhTrackMatchedDEtaDPhiPos1Cell(0),
175 fhEOverP1Cell(0),
176 
177 // Cells
178 fhCellExoAmp(0),
179 fhCellExoAmpTime(0), fhCellExoGrid(0),
180 fhCellGridTimeHighNCell20(0), fhCellGridTimeHighNCell12(0),
181 fhNStripsPerEvent(0), fhNStripsPerEventPerSM(0),
182 fhNStripsPerEventAccept(0), fhNStripsPerEventAcceptPerSM(0),
183 fhSM3NCellsSumEnSuspiciousEvents(0),
184 fhSumEnCellsPerSMEventSuspicious(0), fhNCellsPerSMEventSuspicious(0),
185 fhNStripsPerEventSuspicious(0), fhNStripsPerEventSuspiciousPerSM(0)
186 {
187  AddToHistogramsName("AnaCaloExotic_");
188 
189  // Init main cuts
190  //
191  fCellAmpMin = 0.5;
192  fEMinForExo = 10.0;
193  fExoCut = 0.97;
194  fNCellHighCut = 20;
195 
196  fEnergyBins [0] = 7; fEnergyBins [1] = 10; fEnergyBins [2] = 16;
197  fEnergyBins [3] = 22; fEnergyBins [4] = 30; fEnergyBins [5] = 50;
198  fEnergyBins [6] = 75; fEnergyBins [7] = 100; fEnergyBins [8] = 125;
199  fEnergyBins [9] = 150; fEnergyBins[10] = 175; fEnergyBins[11] = 200;
200  fEnergyBins [12]= 250; fEnergyBins[13] = 300;
201 
202  fCellEnMins[0] = 0.5; fCellEnMins[1] = 1.0; fCellEnMins[2] = 2.0;
203  fCellEnMax = 15;
204 
205  fHighEnergyCutSM = 500.; fHighNCellsCutSM = 100;
206  fLowEnergyCutSM3 = 20. ; fLowNCellsCutSM3 = 20;
207 
209  fHighEnergyCutStrip[0] = 80; fHighEnergyCutStrip[1] = 55;
210  fHighNCellsCutStrip[0] = 24; fHighNCellsCutStrip[1] = 15;
211  fLowEnergyCutSM3Strip = 100; // open
212  fLowNCellsCutSM3Strip = 100; // open
213 
214  // Init to zero
215  //
216  for(Int_t i = 0; i < fgkNEBins; i++)
217  {
218  fhM02ExoNCells [i] = 0;
220  fhM02Exo50nsNCells [i] = 0;
221  fhClusterColRowExo [0][i] = 0;
222  fhClusterColRowExo [1][i] = 0;
223 // fhClusterColRowExoW[0][i] = 0;
224 // fhClusterColRowExoW[1][i] = 0;
225 // fhClusterColRow [0][i] = 0;
226 // fhClusterColRow [1][i] = 0;
228  fhNCellsSameDiffExo [i] = 0;
229  fhEnSameDiffExo [i] = 0;
230  fhEnNCellsSameDiffExo [i] = 0;
231  }
232 
233  for(Int_t i = 0; i < 20; i++)
234  {
236  fEventNStripActiveSM [i] = 0;
237  }
238 
239  for(Int_t iemin = 0; iemin < fgkNCellEnMinBins; iemin++)
240  {
241  fhCellGridTime [iemin] = 0;
242  fhSumEnCells [iemin] = 0;
243  fhNCells [iemin] = 0;
244  fhAverSumEnCells [iemin] = 0;
245  fhSumEnCellsNHigh20 [iemin] = 0;
246  fhNCellsNHigh20 [iemin] = 0;
247  fhAverSumEnCellsNHigh20 [iemin] = 0;
248  fhSumEnCellsAcceptEvent [iemin] = 0;
249  fhNCellsAcceptEvent [iemin] = 0;
250  fhAverSumEnCellsAcceptEvent [iemin] = 0;
251  fhSumEnCellsPerSM [iemin] = 0;
252  fhNCellsPerSM [iemin] = 0;
253  fhAverSumEnCellsPerSM [iemin] = 0;
254  fhSumEnCellsPerSMNHigh20 [iemin] = 0;
255  fhNCellsPerSMNHigh20 [iemin] = 0;
256  fhAverSumEnCellsPerSMNHigh20[iemin] = 0;
257  fhSumEnCellsPerSMAcceptEvent [iemin] = 0;
258  fhNCellsPerSMAcceptEvent [iemin] = 0;
260 
261  fhSumEnCellsAcceptEventStrip[iemin] = 0;
262  fhNCellsAcceptEventStrip [iemin] = 0;
265 
266  fhSumEnCellsAcceptEventBoth[iemin] = 0;
267  fhNCellsAcceptEventBoth [iemin] = 0;
269  fhNCellsPerSMAcceptEventBoth[iemin] = 0;
270 
271  fhSumEnCellsPerStrip [iemin] = 0;
272  fhNCellsPerStrip [iemin] = 0;
273  fhSumEnCellsPerStripPerSM [iemin] = 0;
274  fhNCellsPerStripPerSM [iemin] = 0;
275 
276  fhSumEnCellsPerStripNHigh20 [iemin] = 0;
277  fhNCellsPerStripNHigh20 [iemin] = 0;
279  fhNCellsPerStripPerSMNHigh20 [iemin] = 0;
280 
285 
290 
291  fhNSumEnCells [iemin] = 0;
292  fhNSumEnCellsAcceptEvent [iemin] = 0;
293  fhNSumEnCellsAcceptEventStrip[iemin] = 0;
294  fhNSumEnCellsAcceptEventBoth[iemin] = 0;
295 
296  fhNSumEnCellsPerSM [iemin] = 0;
297  fhNSumEnCellsPerSMAcceptEvent [iemin] = 0;
300 
301  fhNSumEnCellsPerStrip [iemin] = 0;
305 
306  fhNSumEnCellsPerStripPerSM [iemin] = 0;
310 
311  if ( iemin == 3 ) continue;
312 
313  fhFracNCells [iemin] = 0;
314  fhFracSumEnCells [iemin] = 0;
315  fhFracNCellsNHigh20 [iemin] = 0;
316  fhFracSumEnCellsNHigh20 [iemin] = 0;
317  fhFracNCellsAcceptEvent [iemin] = 0;
318  fhFracSumEnCellsAcceptEvent [iemin] = 0;
319  fhFracNCellsPerSM [iemin] = 0;
320  fhFracSumEnCellsPerSM [iemin] = 0;
321  fhFracNCellsPerSMNHigh20 [iemin] = 0;
322  fhFracSumEnCellsPerSMNHigh20[iemin] = 0;
323  fhFracNCellsPerSMAcceptEvent [iemin] = 0;
325  }
326 
327  for(Int_t i = 0; i < 4; i++)
328  {
329  for(Int_t j = 0; j < 4; j++)
330  {
331  fhCellEnDiffColRowDiff [i][j] = 0;
332  fhCellEnSameColRowDiff [i][j] = 0;
335 
340  }
341  }
342 
343  for (Int_t ieta = 0; ieta < 24; ieta++)
344  {
345  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
346  {
347  for (Int_t ism = 0; ism < 20; ism++)
348  {
349  fEnCellsStrip[icut][ism][ieta] = 0.;
350  fnCellsStrip [icut][ism][ieta] = 0 ;
351  }
352  }
353  }
354 
355  for (Int_t icase = 0; icase < 4; icase++)
356  {
357  fhEventCutClusterEnergyTime [icase] = 0;
358  fhEventCutClusterEnergy [icase] = 0;
360  fhEventCutClusterEtaPhiGrid [icase] = 0;
361  fhEventCutBunchCrossing [icase] = 0;
362  }
363 }
364 
365 //
366 //____________________________________________________________
369 //____________________________________________________________
370 void AliAnaCaloExotics::CellHistograms(AliVCaloCells *cells)
371 {
372  Int_t ncells = cells->GetNumberOfCells();
373  if( ncells <= 0 ) return;
374 
375  AliDebug(1,Form("%s cell entries %d", GetCalorimeterString().Data(), ncells));
376 
377  Int_t icol = -1, icolAbs = -1;
378  Int_t irow = -1, irowAbs = -1;
379  Int_t iRCU = -1;
380  Float_t amp = 0.;
381  Double_t time = 0.;
382  Int_t id = -1;
383  //Bool_t highG = kFALSE;
384  Float_t exoticity = -1000;
385  Float_t exoticity50ns = -1000;
386 
387  Int_t bc = GetReader()->GetInputEvent()->GetBunchCrossNumber();
388 
389  Int_t nCells[fgkNCellEnMinBins] ;
390  Float_t eCells[fgkNCellEnMinBins] ;
391 
392  Int_t nCellsPerSM[fgkNCellEnMinBins][20] ;
393  Float_t eCellsPerSM[fgkNCellEnMinBins][20] ;
394 
395  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
396  {
397  nCells[icut] = 0 ;
398  eCells[icut] = 0 ;
399  for(Int_t ism = 0; ism < 20; ism++)
400  {
401  nCellsPerSM[icut][ism] = 0 ;
402  eCellsPerSM[icut][ism] = 0 ;
403  }
404  }
405 
406  for (Int_t iCell = 0; iCell < cells->GetNumberOfCells(); iCell++)
407  {
408  if ( cells->GetCellNumber(iCell) < 0 || cells->GetAmplitude(iCell) < fCellAmpMin ) continue;
409 
410  AliDebug(2,Form("Cell : amp %f, absId %d", cells->GetAmplitude(iCell), cells->GetCellNumber(iCell)));
411 
412  Int_t nModule = GetModuleNumberCellIndexesAbsCaloMap(cells->GetCellNumber(iCell),GetCalorimeter(),
413  icol , irow, iRCU,
414  icolAbs, irowAbs );
415 
416  AliDebug(2,Form("\t module %d, column %d (%d), row %d (%d)", nModule,icolAbs,icol,irowAbs,irow));
417 
418  amp = cells->GetAmplitude(iCell);
419 
420  time = cells->GetTime(iCell);
421  time *= 1.0e9;
422  time-=fConstantTimeShift;
423 
424  id = cells->GetCellNumber(iCell);
425 
426  //highG = cells->GetCellHighGain(id);
427 
428  exoticity = 1-GetCaloUtils()->GetECross(id,cells,bc)/amp;
429 
431  exoticity50ns = 1-GetCaloUtils()->GetECross(id,cells,bc)/amp;
432  GetReader()->GetCaloUtils()->GetEMCALRecoUtils()->SetExoticCellDiffTimeCut(1e6); // Back to default
433 
434  // Fill histograms
435 
436  fhCellExoAmp ->Fill(amp , exoticity, GetEventWeight());
437  fhCellExoAmpTime->Fill(amp , time, exoticity, GetEventWeight());
438 
439  if ( fFillExo50ns )
440  fhCellExo50nsAmp->Fill(amp, exoticity50ns, GetEventWeight());
441 
442  if ( amp > fEMinForExo )
443  fhCellExoGrid->Fill(icolAbs, irowAbs, exoticity, GetEventWeight());
444 
445  // If there is at least one cluster with nCellW>20 or 12, check the cell distribution
446  if ( fLED20 )
447  {
448  fhCellGridTimeHighNCell20->Fill(icolAbs, irowAbs, fLED20Time, GetEventWeight());
449  }
450 
451  if ( fLED12 )
452  {
453  fhCellGridTimeHighNCell12->Fill(icolAbs, irowAbs, fLED12Time, GetEventWeight());
454  }
455 
456  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
457  {
458  if ( amp > fCellEnMins[icut] && amp < fCellEnMax )
459  {
460  fhCellGridTime[icut]->Fill(icolAbs, irowAbs, time, GetEventWeight());
461 
462  nCells[icut]++;
463  eCells[icut]+=amp;
464  nCellsPerSM[icut][nModule]++;
465  eCellsPerSM[icut][nModule]+=amp;
466  }
467  }
468  } // Cell loop
469 
470 // if ( nCellsPerSM[0][3] < 2 || eCellsPerSM[0][3] < 1 )
471 // printf("SM3 nCells %d, sum E cells %2.2f \n",nCellsPerSM[0][3],eCellsPerSM[0][3] );
472 
473  // LED event rejection trial
474  // use the total N cells or E sum for E cell > 0.5
475  // Low activity in SM3 and very large activiy on any of the other SM
476  //
477  fAcceptEvent = kTRUE;
478  if ( nCellsPerSM[0][3] <= fLowNCellsCutSM3 || eCellsPerSM[0][3] <= fLowEnergyCutSM3 )
479  {
480  for(Int_t ism = 0; ism < 20; ism++)
481  {
482  if ( ism == 3 ) continue;
483 
484  if ( nCellsPerSM[0][ism] >= fHighNCellsCutSM ) fAcceptEvent = kFALSE;
485  if ( eCellsPerSM[0][ism] >= fHighEnergyCutSM ) fAcceptEvent = kFALSE;
486  }
487 
488  if ( !fAcceptEvent )
489  {
490  printf("Reject event: ");
491  for(Int_t jsm = 0; jsm < 20; jsm++)
492  {
493  if ( nCellsPerSM[0][jsm] > 0 )
494  printf("\t SM%d: ncells %d; sum E %3.1f \n",jsm,nCellsPerSM[0][jsm],eCellsPerSM[0][jsm]);
495 
496  }
497  }
498  }
499  else
500  {
501  Bool_t suspiciousEvent = kFALSE;
502 
503  for(Int_t ism = 0; ism < 20; ism++)
504  {
505  if ( ism == 3 ) continue;
506 
507  if ( nCellsPerSM[0][ism] >= fHighNCellsCutSM ) suspiciousEvent = kTRUE;
508  if ( eCellsPerSM[0][ism] >= fHighEnergyCutSM ) suspiciousEvent = kTRUE;
509  }
510 
511  if ( suspiciousEvent )
512  {
513  fhSM3NCellsSumEnSuspiciousEvents->Fill(nCellsPerSM[0][3], eCellsPerSM[0][3], GetEventWeight());
514  if ( fFillStripHisto )
516  for(Int_t ism = 0; ism < 20; ism++)
517  {
518  fhSumEnCellsPerSMEventSuspicious->Fill(eCellsPerSM[0][ism], ism, GetEventWeight());
519  fhNCellsPerSMEventSuspicious ->Fill(nCellsPerSM[0][ism], ism, GetEventWeight());
520  if ( fFillStripHisto )
522  }
523  }
524  }
525 
526  if ( fAcceptEvent && fFillStripHisto )
527  {
529  for (Int_t ism = 0; ism < 20; ism++)
531 
532 
533  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
534  {
535  for (Int_t ieta = 0; ieta < 24; ieta++)
536  {
537  for (Int_t ism = 0; ism < 20; ism++)
538  {
539  fhSumEnCellsPerStripEventAccept[icut]->Fill(fEnCellsStrip[icut][ism][ieta], GetEventWeight());
540  fhNCellsPerStripEventAccept [icut]->Fill(fnCellsStrip [icut][ism][ieta], GetEventWeight());
541 
542  fhSumEnCellsPerStripPerSMEventAccept[icut]->Fill(fEnCellsStrip[icut][ism][ieta], ism, GetEventWeight());
543  fhNCellsPerStripPerSMEventAccept [icut]->Fill(fnCellsStrip [icut][ism][ieta], ism, GetEventWeight());
544 
545  fhNSumEnCellsPerStripAcceptEvent [icut]->Fill(fEnCellsStrip[icut][ism][ieta],fnCellsStrip[icut][ism][ieta], GetEventWeight());
546  fhNSumEnCellsPerStripPerSMAcceptEvent[icut]->Fill(fEnCellsStrip[icut][ism][ieta],fnCellsStrip[icut][ism][ieta], ism, GetEventWeight());
547 
549  {
550  fhSumEnCellsPerStripAcceptEventBoth [icut]->Fill(fEnCellsStrip[icut][ism][ieta], GetEventWeight());
551  fhNCellsPerStripAcceptEventBoth [icut]->Fill(fnCellsStrip [icut][ism][ieta], GetEventWeight());
552 
553  fhSumEnCellsPerStripPerSMAcceptEventBoth[icut]->Fill(fEnCellsStrip[icut][ism][ieta], ism, GetEventWeight());
554  fhNCellsPerStripPerSMAcceptEventBoth [icut]->Fill(fnCellsStrip [icut][ism][ieta], ism, GetEventWeight());
555 
556  fhNSumEnCellsPerStripAcceptEventBoth [icut]->Fill(fEnCellsStrip[icut][ism][ieta],fnCellsStrip[icut][ism][ieta], GetEventWeight());
557  fhNSumEnCellsPerStripPerSMAcceptEventBoth[icut]->Fill(fEnCellsStrip[icut][ism][ieta],fnCellsStrip[icut][ism][ieta], ism, GetEventWeight());
558  }
559  } // ism
560  } // ieta
561  } // cut
562  }
563 
564  // LED Event rejection
565  //
566 
567  if ( fFillAllCellEventParamHisto < 1 ) return;
568 
569  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
570  {
571  Float_t averECells = 0;
572  if ( nCells[icut] > 0 ) averECells = eCells[icut] / nCells[icut];
573 
574  fhSumEnCells [icut]->Fill(eCells[icut], GetEventWeight());
575  fhNCells [icut]->Fill(nCells[icut], GetEventWeight());
576  fhNSumEnCells[icut]->Fill(eCells[icut],nCells[icut], GetEventWeight());
577 
578  if ( fFillAllCellEventParamHisto > 1 )
579  fhAverSumEnCells[icut]->Fill(averECells , GetEventWeight());
580 
581  if ( fLED20 )
582  {
583  fhSumEnCellsNHigh20[icut]->Fill(eCells[icut], GetEventWeight());
584  fhNCellsNHigh20 [icut]->Fill(nCells[icut], GetEventWeight());
585  if ( fFillAllCellEventParamHisto > 1 )
586  fhAverSumEnCellsNHigh20[icut]->Fill(averECells , GetEventWeight());
587  }
588 
589  if ( fAcceptEvent )
590  {
591  fhSumEnCellsAcceptEvent [icut]->Fill(eCells[icut], GetEventWeight());
592  fhNCellsAcceptEvent [icut]->Fill(nCells[icut], GetEventWeight());
593  fhNSumEnCellsAcceptEvent[icut]->Fill(eCells[icut],nCells[icut], GetEventWeight());
594 
595  if ( fFillAllCellEventParamHisto > 1 )
596  fhAverSumEnCellsAcceptEvent[icut]->Fill(averECells, GetEventWeight());
597  }
598 
600  {
601  fhSumEnCellsAcceptEventStrip [icut]->Fill(eCells[icut], GetEventWeight());
602  fhNCellsAcceptEventStrip [icut]->Fill(nCells[icut], GetEventWeight());
603  fhNSumEnCellsAcceptEventStrip[icut]->Fill(eCells[icut],nCells[icut], GetEventWeight());
604  if ( fAcceptEvent )
605  {
606  fhSumEnCellsAcceptEventBoth [icut]->Fill(eCells[icut], GetEventWeight());
607  fhNCellsAcceptEventBoth [icut]->Fill(nCells[icut], GetEventWeight());
608  fhNSumEnCellsAcceptEventBoth[icut]->Fill(eCells[icut],nCells[icut], GetEventWeight());
609  }
610  }
611 
612  for(Int_t ism = 0; ism < 20; ism++)
613  {
614  averECells = 0;
615  if ( nCellsPerSM[icut][ism] > 0 )
616  averECells = eCellsPerSM[icut][ism] / nCellsPerSM[icut][ism];
617 
618  fhSumEnCellsPerSM [icut]->Fill(eCellsPerSM[icut][ism], ism, GetEventWeight());
619  fhNCellsPerSM [icut]->Fill(nCellsPerSM[icut][ism], ism, GetEventWeight());
620  fhNSumEnCellsPerSM[icut]->Fill(eCellsPerSM[icut][ism],nCellsPerSM[icut][ism], ism, GetEventWeight());
621 
622  if ( fFillAllCellEventParamHisto > 1 )
623  fhAverSumEnCellsPerSM[icut]->Fill(averECells, ism, GetEventWeight());
624 
625  if ( fLED20 )
626  {
627  fhSumEnCellsPerSMNHigh20[icut]->Fill(eCellsPerSM[icut][ism], ism, GetEventWeight());
628  fhNCellsPerSMNHigh20 [icut]->Fill(nCellsPerSM[icut][ism], ism, GetEventWeight());
629  if ( fFillAllCellEventParamHisto > 1 )
630  fhAverSumEnCellsPerSMNHigh20[icut]->Fill(averECells, ism, GetEventWeight());
631  }
632 
633  if ( fAcceptEvent )
634  {
635  fhSumEnCellsPerSMAcceptEvent [icut]->Fill(eCellsPerSM[icut][ism], ism, GetEventWeight());
636  fhNCellsPerSMAcceptEvent [icut]->Fill(nCellsPerSM[icut][ism], ism, GetEventWeight());
637  fhNSumEnCellsPerSMAcceptEvent[icut]->Fill(eCellsPerSM[icut][ism],nCellsPerSM[icut][ism], ism, GetEventWeight());
638 
639  if ( fFillAllCellEventParamHisto > 1 )
640  fhAverSumEnCellsPerSMAcceptEvent[icut]->Fill(averECells, ism, GetEventWeight());
641  }
642 
644  {
645  fhSumEnCellsPerSMAcceptEventStrip [icut]->Fill(eCellsPerSM[icut][ism], ism, GetEventWeight());
646  fhNCellsPerSMAcceptEventStrip [icut]->Fill(nCellsPerSM[icut][ism], ism, GetEventWeight());
647  fhNSumEnCellsPerSMAcceptEventStrip[icut]->Fill(eCellsPerSM[icut][ism],nCellsPerSM[icut][ism], ism, GetEventWeight());
648 
649  if ( fAcceptEvent )
650  {
651  fhSumEnCellsPerSMAcceptEventBoth [icut]->Fill(eCellsPerSM[icut][ism], ism, GetEventWeight());
652  fhNCellsPerSMAcceptEventBoth [icut]->Fill(nCellsPerSM[icut][ism], ism, GetEventWeight());
653  fhNSumEnCellsPerSMAcceptEventBoth[icut]->Fill(eCellsPerSM[icut][ism],nCellsPerSM[icut][ism], ism, GetEventWeight());
654  }
655  }
656  } // Per SM
657 
658  if ( fFillAllCellEventParamHisto < 2 ) continue;
659 
660  if ( icut == 0 ) continue;
661 
662  Float_t frNCells = 0;
663  if ( nCells[0] > 0 ) frNCells = (1.*nCells[icut]) / nCells[0];
664 
665  Float_t frEnCells = 0;
666  if ( eCells[0] > 0 ) frEnCells = eCells[icut] / eCells[0];
667 
668  fhFracNCells [icut-1]->Fill(frNCells , GetEventWeight());
669  fhFracSumEnCells[icut-1]->Fill(frEnCells, GetEventWeight());
670 
671  if ( fLED20 )
672  {
673  fhFracNCellsNHigh20 [icut-1]->Fill(frNCells , GetEventWeight());
674  fhFracSumEnCellsNHigh20[icut-1]->Fill(frEnCells, GetEventWeight());
675  }
676 
677  if ( fAcceptEvent )
678  {
679  fhFracNCellsAcceptEvent [icut-1]->Fill(frNCells , GetEventWeight());
680  fhFracSumEnCellsAcceptEvent[icut-1]->Fill(frEnCells, GetEventWeight());
681  }
682 
683  for(Int_t ism = 0; ism < 20; ism++)
684  {
685  frNCells = 0;
686  if ( nCellsPerSM[0][ism] > 0 )
687  frNCells = (1.*nCellsPerSM[icut][ism]) / nCellsPerSM[0][ism];
688 
689  Float_t frEnCells = 0;
690  if ( eCellsPerSM[0][ism] > 0 )
691  frEnCells = eCellsPerSM[icut][ism] / eCellsPerSM[0][ism];
692 
693  fhFracNCellsPerSM [icut-1]->Fill(frNCells , ism, GetEventWeight());
694  fhFracSumEnCellsPerSM[icut-1]->Fill(frEnCells, ism, GetEventWeight());
695 
696  if ( fLED20 )
697  {
698  fhFracNCellsPerSMNHigh20 [icut-1]->Fill(frNCells , ism, GetEventWeight());
699  fhFracSumEnCellsPerSMNHigh20[icut-1]->Fill(frEnCells, ism, GetEventWeight());
700  }
701 
702  if ( fAcceptEvent )
703  {
704  fhFracNCellsPerSMAcceptEvent [icut-1]->Fill(frNCells , ism, GetEventWeight());
705  fhFracSumEnCellsPerSMAcceptEvent[icut-1]->Fill(frEnCells, ism, GetEventWeight());
706  }
707  } // Per SM
708  }
709 }
710 
711 //
712 //____________________________________________________________
715 //____________________________________________________________
716 void AliAnaCaloExotics::StripHistograms(AliVCaloCells *cells)
717 {
718  Int_t ncells = cells->GetNumberOfCells();
719  if( ncells <= 0 ) return;
720 
721  fEventNStripActive = 0;
722 
723  Float_t amp1 = 0., amp2 = 0. ;
724  Int_t absId1 = -1, absId2 = -1 ;
725 
726  for (Int_t ism = 0; ism < 20; ism++)
727  {
728  fEventNStripActiveSM[ism] = 0;
729 
730  for (Int_t ieta = 0; ieta < 48; ieta=ieta+2)
731  {
732  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
733  {
734  fEnCellsStrip[icut][ism][ieta/2] = 0.;
735  fnCellsStrip [icut][ism][ieta/2] = 0 ;
736  }
737 
738  for (Int_t iphi = 0; iphi < 24; iphi++)
739  {
740  absId1 = GetEMCALGeometry()->GetAbsCellIdFromCellIndexes(ism, iphi, ieta);
741  if ( absId1 < 0 || absId1 > 17664 ) continue;
742 
743  absId2 = GetEMCALGeometry()->GetAbsCellIdFromCellIndexes(ism, iphi, ieta+1);
744  if ( absId2 < 0 || absId2 > 17664 ) continue;
745 
746  amp1 = cells->GetCellAmplitude(absId1);
747  amp2 = cells->GetCellAmplitude(absId2);
748 // printf("ieta %d iphi %d: a) id %d amp %2.2f; b) id %d amp %2.2f\n",
749 // ieta, iphi,absId1,amp1,absId2,amp2);
750 
751  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
752  {
753  if ( amp1 > fCellEnMins[icut] && amp1 < fCellEnMax )
754  {
755  fnCellsStrip [icut][ism][ieta/2]++;
756  fEnCellsStrip[icut][ism][ieta/2]+=amp1;
757 // if( icut == 0 && (fnCellsStrip [icut][ism][ieta/2] > 0 || fEnCellsStrip[icut][ism][ieta/2] > 0))
758 // printf("Task: cell1 %d amp %f; SM %d, strip %d, n cells %d, sum E %f \n",
759 // absId1, amp1,
760 // ism,ieta,
761 // fnCellsStrip [0][ism][ieta/2],
762 // fEnCellsStrip[0][ism][ieta/2]
763 // );
764  }
765 
766  if ( amp2 > fCellEnMins[icut] && amp2 < fCellEnMax )
767  {
768  fnCellsStrip [icut][ism][ieta/2]++;
769  fEnCellsStrip[icut][ism][ieta/2]+=amp2;
770 // if( icut == 0 && (fnCellsStrip [icut][ism][ieta/2] > 0 || fEnCellsStrip[icut][ism][ieta/2] > 0))
771 // printf("Task: cell2 %d amp %f; SM %d, strip %d, n cells %d , sum E %f \n",
772 // absId2, amp2,
773 // ism,ieta,
774 // fnCellsStrip [0][ism][ieta/2],
775 // fEnCellsStrip[0][ism][ieta/2]
776 // );
777  }
778  } // e cut
779 
780  }// iphi
781 
782  // Fill histograms per Strip
783  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
784  {
785  fhSumEnCellsPerStrip [icut]->Fill(fEnCellsStrip[icut][ism][ieta/2], GetEventWeight());
786  fhNCellsPerStrip [icut]->Fill(fnCellsStrip [icut][ism][ieta/2], GetEventWeight());
787 
788  fhSumEnCellsPerStripPerSM[icut]->Fill(fEnCellsStrip[icut][ism][ieta/2], ism, GetEventWeight());
789  fhNCellsPerStripPerSM [icut]->Fill(fnCellsStrip [icut][ism][ieta/2], ism, GetEventWeight());
790 
791  fhNSumEnCellsPerStrip [icut]->Fill(fEnCellsStrip[icut][ism][ieta/2],fnCellsStrip[icut][ism][ieta/2], GetEventWeight());
792  fhNSumEnCellsPerStripPerSM[icut]->Fill(fEnCellsStrip[icut][ism][ieta/2],fnCellsStrip[icut][ism][ieta/2], ism, GetEventWeight());
793 
794  if ( fLED20 )
795  {
796  fhSumEnCellsPerStripNHigh20 [icut]->Fill(fEnCellsStrip[icut][ism][ieta/2], GetEventWeight());
797  fhNCellsPerStripNHigh20 [icut]->Fill(fnCellsStrip [icut][ism][ieta/2], GetEventWeight());
798 
799  fhSumEnCellsPerStripPerSMNHigh20[icut]->Fill(fEnCellsStrip[icut][ism][ieta/2], ism, GetEventWeight());
800  fhNCellsPerStripPerSMNHigh20 [icut]->Fill(fnCellsStrip [icut][ism][ieta/2], ism, GetEventWeight());
801  }
802  }
803  } // ieta
804  }// sm
805 
806  // Count per event over event cut
807  // Low activity on SM3 for emin = 0.5
808  Bool_t bSM3StripsLowActivity = kTRUE;
809  for (Int_t ieta = 0; ieta < 24; ieta++)
810  {
811  if ( fEnCellsStrip[0][3][ieta] > fLowEnergyCutSM3Strip ||
812  fnCellsStrip [0][3][ieta] > fLowNCellsCutSM3Strip )
813  bSM3StripsLowActivity = kFALSE;
814  }
815 
816  if ( bSM3StripsLowActivity )
817  {
818 
819  Int_t maxNCells = 20;
820  Float_t maxECells = 45;
821  for (Int_t ism = 0; ism < 20; ism++)
822  {
823  if ( ism == 3 ) continue ;
824 
825  maxNCells = fHighNCellsCutStrip[0];
826  maxECells = fHighEnergyCutStrip[0];
827  if ( ism == 10 || ism == 11 ||
828  ism == 18 || ism == 19 )
829  {
830  maxNCells = fHighNCellsCutStrip[1];
831  maxECells = fHighEnergyCutStrip[1];
832  }
833 
834  for (Int_t ieta = 0; ieta < 24; ieta++)
835  {
836 // if(fnCellsStrip[0][ism][ieta] > 0 || fEnCellsStrip[0][ism][ieta] > 0 )
837 // printf("Task: SM %d, strip %d, n cells %d < %d , sum E %f < %f \n",
838 // ism,ieta,
839 // fnCellsStrip [0][ism][ieta],maxNCells,
840 // fEnCellsStrip[0][ism][ieta],maxECells
841 // );
842  if( fEnCellsStrip[0][ism][ieta] >= maxECells ||
843  fnCellsStrip [0][ism][ieta] >= maxNCells )
844  {
846  fEventNStripActiveSM[ism]++;
847  }
848  } // ieta
849  } // ism
850  } // bSM03
851 
853  for (Int_t ism = 0; ism < 20; ism++)
855 
856  //printf("Task: Number of strips %d\n",fEventNStripActive);
857 
858  // Strip activity if cut on number of active strips
860  {
861  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
862  {
863  for (Int_t ieta = 0; ieta < 24; ieta++)
864  {
865  for (Int_t ism = 0; ism < 20; ism++)
866  {
867  fhSumEnCellsPerStripAcceptEventStrip [icut]->Fill(fEnCellsStrip[icut][ism][ieta], GetEventWeight());
868  fhNCellsPerStripAcceptEventStrip [icut]->Fill(fnCellsStrip [icut][ism][ieta], GetEventWeight());
869 
870  fhSumEnCellsPerStripPerSMAcceptEventStrip[icut]->Fill(fEnCellsStrip[icut][ism][ieta], ism, GetEventWeight());
871  fhNCellsPerStripPerSMAcceptEventStrip [icut]->Fill(fnCellsStrip [icut][ism][ieta], ism, GetEventWeight());
872 
873  fhNSumEnCellsPerStripAcceptEventStrip [icut]->Fill(fEnCellsStrip[icut][ism][ieta],fnCellsStrip[icut][ism][ieta], GetEventWeight());
874  fhNSumEnCellsPerStripPerSMAcceptEventStrip[icut]->Fill(fEnCellsStrip[icut][ism][ieta],fnCellsStrip[icut][ism][ieta], ism, GetEventWeight());
875  } // icut
876  } // ieta
877  } // sm
878 
879  } // strip event cut
880 
881 }
882 
883 //____________________________________________________________________________
895 //____________________________________________________________________________
897  AliVCaloCells* cells)
898 {
899  fLED20 = kFALSE;
900  fLED12 = kFALSE;
901  fLED20Time = -1e6;
902  fLED12Time = -1e6;
903 
904  Int_t nCaloClusters = caloClusters->GetEntriesFast() ;
905  Int_t bc = GetReader()->GetInputEvent()->GetBunchCrossNumber();
906 
907  // Get vertex, not needed.
908  Double_t v[3] = {0,0,0};
909  //GetReader()->GetVertex(v);
910  Int_t nNCellW20 = 0;
911  Int_t nNCellW12 = 0;
912  Int_t nExotic = 0;
913  Int_t nExotic1Cell = 0;
914  Int_t nExoticNCell = 0;
915 
916  Float_t highestAmpMaxExo = 0;
917 
918  AliDebug(1,Form("In %s there are %d clusters", GetCalorimeterString().Data(), nCaloClusters));
919 
920  // Loop over CaloClusters
921  for(Int_t iclus = 0; iclus < nCaloClusters; iclus++)
922  {
923  AliDebug(1,Form("Cluster: %d/%d, data %d",iclus+1,nCaloClusters,GetReader()->GetDataType()));
924 
925  AliVCluster* clus = (AliVCluster*) caloClusters->At(iclus);
926 
927  // Get cluster kinematics
928  clus->GetMomentum(fClusterMomentum,v);
929 
930  Float_t en = fClusterMomentum.E();
931  Float_t eta = fClusterMomentum.Eta();
932  Float_t phi = GetPhi(fClusterMomentum.Phi());
933 
934  // Check only certain regions
935  Bool_t in = kTRUE;
936  if ( IsFiducialCutOn() )
938 
939  if ( !in )
940  {
941  AliDebug(1,Form("Remove cluster with phi %2.2f and eta %2.2f",phi*TMath::RadToDeg(),eta));
942  continue;
943  }
944 
945  Int_t nCaloCellsPerCluster = clus->GetNCells();
946  //Int_t nLabel = clus->GetNLabels();
947  //Int_t *labels = clus->GetLabels();
948 
949  // Cluster mathed with track?
950  //
951  Bool_t matched = 0;
952  AliVTrack *track = 0;
953  Double_t eOverP = 0;
954  Double_t tmom = 0;
955  Bool_t positive = kFALSE;
956  if ( fFillMatchingHisto )
957  {
958  matched = GetCaloPID()->IsTrackMatched(clus,GetCaloUtils(), GetReader()->GetInputEvent());
959  track = GetCaloUtils()->GetMatchedTrack(clus, GetReader()->GetInputEvent());
960 
961  if ( track )
962  {
963  tmom = track->P();
964  eOverP = en/tmom;
965 
966  positive = (track->Charge()>0);
967  }
968  }
969 
970  // Residuals
971  Float_t deta = clus->GetTrackDz();
972  Float_t dphi = clus->GetTrackDx();
973 
974  // Get the 1-fraction of the cluster energy that carries the cell with highest energy and its absId
975  Float_t maxCellFraction = 0.;
976  Int_t absIdMax = GetCaloUtils()->GetMaxEnergyCell(cells, clus,maxCellFraction);
977 
978  Int_t icolMax = -1, icolMaxAbs = -1;
979  Int_t irowMax = -1, irowMaxAbs = -1;
980  Int_t iRCU = -1;
982  icolMax , irowMax, iRCU,
983  icolMaxAbs, irowMaxAbs );
984 
985  // Get time of max cell/cluster
986  Double_t tmax = cells->GetCellTime(absIdMax);
987  tmax*=1.e9;
988  tmax-=fConstantTimeShift;
989 
990  Float_t ampMax = cells->GetCellAmplitude(absIdMax);
991  Float_t enOrg = ampMax/(1-maxCellFraction); // cluster energy without non linearity correction
992 
993  Float_t exoticity = 1-GetCaloUtils()->GetECross(absIdMax,cells,bc)/ampMax;
994 
995  Float_t exoticity50ns = -1;
996  if ( fFillExo50ns )
997  {
999  exoticity50ns = 1-GetCaloUtils()->GetECross(absIdMax,cells,bc)/ampMax;
1000  GetReader()->GetCaloUtils()->GetEMCALRecoUtils()->SetExoticCellDiffTimeCut(1e6); // Back to default
1001  }
1002 
1003  Float_t m02 = clus->GetM02();
1004  Float_t m20 = clus->GetM20();
1005 
1006  Int_t ebin = -1;
1007  for(Int_t i = 0; i < fgkNEBins-1; i++)
1008  {
1009  if(en >= fEnergyBins[i] && en < fEnergyBins[i+1] ) ebin = i;
1010  }
1011 
1012  // Cell cluster loop
1013  //
1014  Int_t nCellSame = 0, nCellSame5 = 0;
1015  Int_t nCellDiff = 0, nCellDiff5 = 0;
1016  Int_t nCellW = 0, nCellSameW = 0, nCellDiffW = 0;
1017  Int_t nCellTimeDiff = 0, nCellSameTimeDiff = 0, nCellDiffTimeDiff = 0;
1018  Int_t rowDiff = -100, colDiff = -100;
1019  Int_t rowDiffAbs = -100, colDiffAbs = -100;
1020  Float_t enSame = 0, enDiff = 0;
1021  Float_t enSame5 = 0, enDiff5 = 0;
1022  Float_t enSameW = 0, enDiffW = 0;
1023  Float_t enSameTimeDiff = 0, enDiffTimeDiff = 0;
1024 
1025  const Int_t nMinEnCut = 18;
1026  Int_t nCellSameMinEn[nMinEnCut], nCellDiffMinEn[nMinEnCut];
1027  for(Int_t imin = 0; imin < 20; imin++)
1028  {
1029  nCellSameMinEn[imin] = 0;
1030  nCellDiffMinEn[imin] = 0;
1031  }
1032 
1033  for (Int_t ipos = 0; ipos < nCaloCellsPerCluster; ipos++)
1034  {
1035  Int_t absId = clus->GetCellsAbsId()[ipos];
1036 
1037  Float_t amp = cells->GetCellAmplitude(absId);
1038 
1039  if ( absId == absIdMax || amp < 0.1 ) continue;
1040 
1041  Bool_t sameTCard = GetCaloUtils()->IsAbsIDsFromTCard(absIdMax,absId,rowDiff,colDiff);
1042  colDiffAbs = TMath::Abs(colDiff);
1043  rowDiffAbs = TMath::Abs(rowDiff);
1044 
1045  if ( sameTCard )
1046  {
1047  nCellSame ++;
1048  enSame += amp;
1049  if ( rowDiffAbs <= 1 && colDiffAbs <= 1 )
1050  {
1051  enSame5 += amp;
1052  nCellSame5++;
1053  }
1054  }
1055  else
1056  {
1057  nCellDiff ++;
1058  enDiff += amp;
1059  if ( rowDiffAbs <= 1 && colDiffAbs <= 1 )
1060  {
1061  enDiff5 += amp;
1062  nCellDiff5++;
1063  }
1064  }
1065 
1066  for(Int_t imin = 0; imin < nMinEnCut; imin++)
1067  {
1068  Float_t enCellMin = 0.2 + imin*0.1;
1069  if ( amp > enCellMin )
1070  {
1071  if ( sameTCard ) nCellSameMinEn[imin]++;
1072  else nCellDiffMinEn[imin]++;
1073  }
1074  }
1075 
1076  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(amp, en);
1077 
1078  if( weight > 0.01 )
1079  {
1080  nCellW++;
1081  if ( sameTCard ) { nCellSameW++; enSameW+=amp; }
1082  else { nCellDiffW++; enDiffW+=amp; }
1083  }
1084 
1085  Double_t time = cells->GetCellTime(absId);
1086  time*=1.e9;
1087  time-=fConstantTimeShift;
1088 
1089  Float_t tdiff = tmax-time;
1090  if( tdiff < 50 )
1091  {
1092  nCellTimeDiff++;
1093  if ( sameTCard ) { nCellSameTimeDiff++; enSameTimeDiff+=amp; }
1094  else { nCellDiffTimeDiff++; enDiffTimeDiff+=amp; }
1095  }
1096  } // cells in cluster loop
1097 
1098  Float_t fracEnDiffSame = 0, fracNCellDiffSame = 0, fracEnNCellDiffSame = 0;
1099  Float_t fracEnDiffSameW = 0, fracNCellDiffSameW = 0, fracEnNCellDiffSameW = 0;
1100  Float_t fracEnDiffSame5 = 0, fracNCellDiffSame5 = 0, fracEnNCellDiffSame5 = 0;
1101 
1102  if ( fFillSameDiffFracHisto )
1103  {
1104  if ( enSame > 0 ) fracEnDiffSame = enDiff / enSame;
1105  if ( nCellSame > 0 ) fracNCellDiffSame = nCellDiff*1. / nCellSame*1.;
1106  if ( nCellDiff > 0 && nCellSame > 0 && enSame > 0)
1107  fracEnNCellDiffSame = (enDiff/nCellDiff*1.) / (enSame/nCellSame*1.);
1108 
1109  if ( enSameW > 0 ) fracEnDiffSameW = enDiffW / enSameW;
1110  if ( nCellSameW > 0 ) fracNCellDiffSameW = nCellDiffW*1. / nCellSameW*1.;
1111  if ( nCellDiffW > 0 && nCellSameW > 0 && enSameW > 0)
1112  fracEnNCellDiffSameW = (enDiffW/nCellDiffW) / (enSameW/nCellSameW);
1113 
1114  if ( enSame5 > 0 ) fracEnDiffSame5 = enDiff5 / enSame5;
1115  if ( nCellSame5 > 0 ) fracNCellDiffSame5 = nCellDiff5*1. / nCellSame5*1.;
1116  if ( nCellDiff5 > 0 && nCellSame5 > 0 && enSame5 > 0)
1117  fracEnNCellDiffSame5 = (enDiff5/nCellDiff5*1.) / (enSame5/nCellSame5*1.);
1118  }
1119 
1120  AliDebug(1,Form("cluster: E %2.3f, F+ %2.3f, eta %2.3f, phi %2.3f, col %d, row %d, ncells %d,"
1121  "match %d; cell max: id %d, en %2.3f, time %2.3f, m02 %2.2f",
1122  en,exoticity,eta,phi*TMath::RadToDeg(), icolMaxAbs, irowMaxAbs, nCaloCellsPerCluster,
1123  matched, absIdMax,ampMax,tmax,m02));
1124 
1125  // Counters
1126  if ( nCellW > 20 ) { nNCellW20++; fLED20 = kTRUE; fLED20Time = tmax; }
1127  if ( nCellW > 12 ) { nNCellW12++; fLED12 = kTRUE; fLED12Time = tmax; }
1128  if ( en > 5 )
1129  {
1130  if ( exoticity > fExoCut ) nExotic++;
1131  if ( nCaloCellsPerCluster == 1 ) nExotic1Cell++;
1132  if ( exoticity > fExoCut && nCaloCellsPerCluster > 1 ) nExoticNCell++;
1133  }
1134 
1135  if ( exoticity > fExoCut && ampMax > highestAmpMaxExo )
1136  {
1137  //printf("Exotic en %f, amp %f\n",en,ampMax);
1138  highestAmpMaxExo = ampMax;
1139  }
1140 
1141  //
1142  // Fill histograms related to single cluster
1143  //
1144 
1145  // Cluster/Cell max Time
1146  //
1147  fhTimeEnergyNCells ->Fill(en, tmax, nCaloCellsPerCluster, GetEventWeight());
1148  fhTimeEnergyNCellsW->Fill(en, tmax, nCellW , GetEventWeight());
1149 
1150  if ( nCellW > fNCellHighCut )
1151  fhTimeNCellCut->Fill(tmax, GetEventWeight());
1152 
1153  if ( nCaloCellsPerCluster > 1 )
1154  {
1155  fhTimeEnergyExo ->Fill(en, tmax, exoticity , GetEventWeight());
1156  fhTimeEnergyM02 ->Fill(en, tmax, m02 , GetEventWeight());
1157  }
1158  else if ( fFill1CellHisto )
1159  fhTimeEnergy1Cell->Fill(en, tmax, GetEventWeight());
1160 
1161 // if(maxCellFraction < 0.2) printf("frac %2.2f, en cell %2.2f, en cluster %2.2f, refrac %2.2f\n",
1162 // maxCellFraction,ampMax,en,ampMax/en);
1163 
1164  if ( fFillOpenTimeHisto )
1165  {
1166  if ( nCaloCellsPerCluster > 1 )
1167  {
1168  //if(en > 10) printf("Amp %f, en %f, enOrg %f, frac %f\n",ampMax,en,enOrg,1-maxCellFraction);
1169  fhCellMaxClusterEnOpenTime ->Fill(enOrg, ampMax , GetEventWeight());
1170  fhCellMaxClusterEnRatioOpenTime ->Fill(en , 1-maxCellFraction , GetEventWeight());
1171  fhCellMaxClusterEnRatioNCellWOpenTime->Fill(en , 1-maxCellFraction, nCellW, GetEventWeight());
1172  }
1173 
1174  fhNCellsPerClusterOpenTime ->Fill(en , nCaloCellsPerCluster , GetEventWeight());
1175  fhNCellsPerClusterWOpenTime ->Fill(en , nCellW , GetEventWeight());
1176  fhNCellsPerClusterEMaxCellOpenTime ->Fill(ampMax, nCaloCellsPerCluster , GetEventWeight());
1177  fhNCellsPerClusterWEMaxCellOpenTime ->Fill(ampMax, nCellW , GetEventWeight());
1178 
1179  for (Int_t ipos = 0; ipos < nCaloCellsPerCluster; ipos++)
1180  {
1181  Int_t absId = clus->GetCellsAbsId()[ipos];
1182 
1183  Float_t amp = cells->GetCellAmplitude(absId);
1184 
1185  if ( absId == absIdMax || amp < 0.1 ) continue;
1186 
1187  fhCellEnNCellWOpenTime ->Fill(en , amp, nCellW, GetEventWeight());
1188  fhCellEnNCellWEMaxOpenTime->Fill(ampMax, amp, nCellW, GetEventWeight());
1189 
1190  Double_t time = cells->GetCellTime(absId);
1191  time*=1.e9;
1192  time-=fConstantTimeShift;
1193 
1194  Float_t tdiff = tmax-time;
1195 
1196  fhCellTimeDiffNCellWOpenTime ->Fill(en , tdiff, nCellW, GetEventWeight());
1197  fhCellTimeDiffNCellWEMaxOpenTime->Fill(ampMax, tdiff, nCellW, GetEventWeight());
1198  }
1199  }
1200 
1201  //----------------------------------------
1202  // Apply time cut
1203  //----------------------------------------
1204  //
1205  if ( tmax < fTimeCutMin || tmax> fTimeCutMax ) continue;
1206 
1207  // N cells per cluster
1208  //
1209  fhNCellsPerCluster ->Fill(en, nCaloCellsPerCluster , GetEventWeight());
1210  fhNCellsPerClusterW ->Fill(en, nCellW , GetEventWeight());
1211  fhNCellsPerClusterTimeDiff ->Fill(en, nCellTimeDiff , GetEventWeight());
1212  fhNCellsPerClusterExo ->Fill(en, nCaloCellsPerCluster, exoticity, GetEventWeight());
1213  if ( fFillExo50ns )
1214  fhNCellsPerClusterExo50ns ->Fill(en, nCaloCellsPerCluster, exoticity50ns, GetEventWeight());
1215 
1216  fhNCellsPerClusterM02 ->Fill(en, nCaloCellsPerCluster, m02 , GetEventWeight());
1217 
1218  fhNCellsPerClusterEMaxCell ->Fill(ampMax, nCaloCellsPerCluster , GetEventWeight());
1219  fhNCellsPerClusterWEMaxCell ->Fill(ampMax, nCellW , GetEventWeight());
1220 
1221  if ( fFillPerSMHisto )
1222  {
1223  fhNCellsPerClusterPerSM ->Fill(en, nCaloCellsPerCluster, nSM , GetEventWeight());
1224  fhNCellsPerClusterWPerSM ->Fill(en, nCellW , nSM , GetEventWeight());
1225  fhNCellsPerClusterExoPerSM[nSM]->Fill(en, nCaloCellsPerCluster, exoticity, GetEventWeight());
1226  }
1227 
1228  if ( matched && fFillMatchingHisto && track )
1229  {
1230  fhNCellsPerClusterTrackMatch ->Fill(en, nCaloCellsPerCluster , GetEventWeight());
1231  fhNCellsPerClusterExoTrackMatch->Fill(en, nCaloCellsPerCluster, exoticity, GetEventWeight());
1232  }
1233 
1234  // Fill histograms for clusters with 1 cell
1235  //
1236  if ( nCaloCellsPerCluster == 1 )
1237  {
1238  if ( fFill1CellHisto )
1239  {
1240  fhExoticity1Cell->Fill(en, exoticity, GetEventWeight());
1241  if ( fFillExo50ns )
1242  fhExoticity50ns1Cell->Fill(en, exoticity50ns, GetEventWeight());
1243 
1244  fhEtaPhiGridEn1Cell->Fill(icolMaxAbs, irowMaxAbs, en, GetEventWeight());
1245 
1246  if ( matched && fFillMatchingHisto && track )
1247  {
1248  fhEOverP1Cell->Fill(en, eOverP, GetEventWeight());
1249 
1250  if ( positive )
1251  {
1252  fhTrackMatchedDEtaPos1Cell->Fill(en, deta, GetEventWeight());
1253  fhTrackMatchedDPhiPos1Cell->Fill(en, dphi, GetEventWeight());
1254 
1255  if ( en > fEMinForExo )
1256  {
1257  fhTrackMatchedDEtaDPhiPos1Cell->Fill(deta, dphi, GetEventWeight());
1258  }
1259  }
1260  else
1261  {
1262  fhTrackMatchedDEtaNeg1Cell->Fill(en, deta, GetEventWeight());
1263  fhTrackMatchedDPhiNeg1Cell->Fill(en, dphi, GetEventWeight());
1264 
1265  if(en > fEMinForExo)
1266  {
1267  fhTrackMatchedDEtaDPhiNeg1Cell->Fill(deta, dphi, GetEventWeight());
1268  }
1269  }
1270  } // matched 1 cell histograms
1271  } // 1 cell histograms
1272 
1273  continue;
1274  }
1275 
1276  //----------------------------------------
1277  // Now only clusters with more than 1 cell
1278  //----------------------------------------
1279 
1280  // Exoticity
1281  //
1282  fhExoticityEClus ->Fill(en , exoticity , GetEventWeight());
1283  fhExoticityEMaxCell->Fill(ampMax, exoticity , GetEventWeight());
1284 
1285  if ( fFillPerSMHisto )
1286  fhExoticityEClusPerSM ->Fill(en, exoticity, nSM, GetEventWeight());
1287 
1288  if ( matched && fFillMatchingHisto && track )
1289  fhExoticityEClusTrackMatch->Fill(en, exoticity, GetEventWeight());
1290 
1291  if ( fFillExo50ns )
1292  fhExoticity50nsEClus->Fill(en, exoticity50ns, GetEventWeight());
1293 
1294  // Calculate exoticity for different E min cuts
1295  //
1296  if ( fFillExoEnMinCut )
1297  {
1298  // Recalculate exoticity with different cell minimum energy thresholds
1299  for(Int_t imin = 0; imin < 41; imin++)
1300  {
1301  Float_t enCellMin = 0.1 + imin*0.05;
1302  Float_t exoMod = 1-GetCaloUtils()->GetECross(absIdMax,cells,bc,enCellMin)/ampMax;
1303  // if(en > 5 && exoticity > 0.97 && imin == 0)
1304  // {
1305  // printf("en %f, imin %d, emin %f exo org %f; exoW %f, exo recalc %f\n",
1306  // en, imin, enCellMin,exoticity,exoticityW, exoMod);
1307  // }
1308 
1309  fhExoticityECellMinCut->Fill(en, exoMod, enCellMin, GetEventWeight());
1310  }
1311 
1312  // Calculate exoticity with cut on w
1313  //
1314  Float_t exoticityW = 1-GetCaloUtils()->GetECross(absIdMax,cells,bc,0,kTRUE,en)/ampMax;
1315 
1316  fhExoticityWEClus ->Fill(en, exoticityW , GetEventWeight());
1317  fhTimeEnergyExoW ->Fill(en, tmax, exoticityW, GetEventWeight());
1318  fhM02EnergyExoW ->Fill(en, m02 , exoticityW, GetEventWeight());
1319  fhNCellsPerClusterExoW->Fill(en, nCaloCellsPerCluster, exoticityW, GetEventWeight());
1320  }
1321 
1322  // Acceptance
1323  //
1324  if ( en > fEMinForExo )
1325  {
1326  fhEtaPhiGridExoEnCut ->Fill(icolMaxAbs, irowMaxAbs, exoticity, GetEventWeight());
1327  fhEtaPhiGridNCellEnCut->Fill(icolMaxAbs, irowMaxAbs, nCaloCellsPerCluster, GetEventWeight());
1328  }
1329 
1330  if ( exoticity > fExoCut )
1331  fhEtaPhiGridEnExoCut ->Fill(icolMaxAbs, irowMaxAbs, en , GetEventWeight());
1332 
1333  if ( nCellW > fNCellHighCut )
1334  fhEtaPhiGridEnHighNCells->Fill(icolMaxAbs, irowMaxAbs, en , GetEventWeight());
1335 
1336  // Cluster energy vs cell max energy
1337  //
1338  fhCellMaxClusterEn ->Fill(enOrg, ampMax , GetEventWeight());
1339  fhCellMaxClusterEnRatio ->Fill(en , 1-maxCellFraction , GetEventWeight());
1340  fhCellMaxClusterEnRatioNCellW->Fill(en , 1-maxCellFraction, nCellW , GetEventWeight());
1341  fhCellMaxClusterEnRatioExo ->Fill(en , 1-maxCellFraction, exoticity, GetEventWeight());
1342 
1343  // Cell cluster loop
1344  //
1345  for (Int_t ipos = 0; ipos < nCaloCellsPerCluster; ipos++)
1346  {
1347  Int_t absId = clus->GetCellsAbsId()[ipos];
1348 
1349  Float_t amp = cells->GetCellAmplitude(absId);
1350 
1351  if ( absId == absIdMax || amp < 0.1 ) continue;
1352 
1353  fhCellEnNCellW ->Fill(en , amp, nCellW, GetEventWeight());
1354  fhCellEnNCellWEMax->Fill(ampMax, amp, nCellW, GetEventWeight());
1355 
1356  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(amp, en);
1357  //
1358  // if( weight > 0.01 )
1359  // {
1360  // if ( ebin >= 0 && ebin < fgkNEBins-1 )
1361  // {
1362  // fhClusterColRowExoW[icolMax%2][ebin]->Fill(colDiff, rowDiff, exoticity, GetEventWeight());
1363  // }
1364  // }
1365 
1366  Double_t time = cells->GetCellTime(absId);
1367  time*=1.e9;
1368  time-=fConstantTimeShift;
1369 
1370  Float_t tdiff = tmax-time;
1371 
1372  fhTimeDiffClusCellExo->Fill(en , tdiff, exoticity, GetEventWeight());
1373  fhTimeDiffClusCellM02->Fill(en , tdiff, m02 , GetEventWeight());
1374 
1375  if ( weight > 0.01 )
1376  fhTimeDiffWClusCellExo->Fill(en , tdiff, exoticity, GetEventWeight());
1377 
1378  fhCellTimeDiffNCellW ->Fill(en , tdiff, nCellW, GetEventWeight());
1379  fhCellTimeDiffNCellWEMax->Fill(ampMax, tdiff, nCellW, GetEventWeight());
1380 
1381  if ( en > fEMinForExo )
1382  fhTimeDiffAmpClusCellExo->Fill(amp, tdiff, exoticity, GetEventWeight());
1383 
1384  Bool_t sameTCard = GetCaloUtils()->IsAbsIDsFromTCard(absIdMax,absId,rowDiff,colDiff);
1385  colDiffAbs = TMath::Abs(colDiff);
1386  rowDiffAbs = TMath::Abs(rowDiff);
1387 
1388  if ( fFillClusterColRowHisto && ebin >= 0 && ebin < fgkNEBins-1 )
1389  {
1390  fhClusterColRowExo[icolMax%2][ebin]->Fill(colDiff, rowDiff, exoticity, GetEventWeight());
1391  //if(exoticity < fExoCut)
1392  // fhClusterColRow [icolMax%2][ebin]->Fill(colDiff, rowDiff, GetEventWeight());
1393  if ( fFillPerSMHisto && nCellW > fNCellHighCut )
1394  fhClusterColRowPerSMHighNCell[ebin]->Fill(colDiff, rowDiff, nSM, GetEventWeight());
1395  }
1396 
1397  if ( sameTCard )
1398  {
1399  fhCellEnSameExo->Fill(en, amp, exoticity, GetEventWeight());
1400  fhTimeDiffClusCellSameTCardExo->Fill(en , tdiff, exoticity, GetEventWeight());
1401 
1402  if( colDiffAbs < 4 && rowDiffAbs < 4 )
1403  {
1404  if(colDiffAbs > 1) printf("Same colDiff %d rowDiff %d\n",colDiffAbs,rowDiffAbs);
1405 
1406  if ( exoticity > fExoCut )
1407  {
1408  fhCellEnSameColRowDiffExoCut[colDiffAbs][rowDiffAbs]->Fill(en, amp, GetEventWeight());
1409  fhTimeDiffClusSameCellColRowDiffExoCut[colDiffAbs][rowDiffAbs]->Fill(en, tdiff, GetEventWeight());
1410  }
1411  else
1412  {
1413  fhCellEnSameColRowDiff[colDiffAbs][rowDiffAbs]->Fill(en, amp, GetEventWeight());
1414  fhTimeDiffClusSameCellColRowDiff[colDiffAbs][rowDiffAbs]->Fill(en, tdiff, GetEventWeight());
1415  }
1416  }
1417 
1418  }
1419  else
1420  {
1421  fhCellEnDiffExo->Fill(en, amp, exoticity, GetEventWeight());
1422  fhTimeDiffClusCellDiffTCardExo->Fill(en , tdiff, exoticity, GetEventWeight());
1423 
1424  if( colDiffAbs < 4 && rowDiffAbs < 4 )
1425  {
1426  if ( exoticity > fExoCut )
1427  {
1428  fhCellEnDiffColRowDiffExoCut[colDiffAbs][rowDiffAbs]->Fill(en, amp, GetEventWeight());
1429  fhTimeDiffClusDiffCellColRowDiffExoCut[colDiffAbs][rowDiffAbs]->Fill(en, tdiff, GetEventWeight());
1430  }
1431  else
1432  {
1433  fhCellEnDiffColRowDiff[colDiffAbs][rowDiffAbs]->Fill(en, amp, GetEventWeight());
1434  fhTimeDiffClusDiffCellColRowDiff[colDiffAbs][rowDiffAbs]->Fill(en, tdiff, GetEventWeight());
1435  }
1436  }
1437  } // diff T-Card
1438 
1439  } // Fill cell-cluster histogram loop
1440 
1441 // if ( en > 10 )
1442 // {
1443 // printf("total %d, same %d, diff %d, same5 %d, diff3 %d, same5+diff3 %d\n",
1444 // nCaloCellsPerCluster,nCellSame,nCellDiff,nCellSame5,nCellDiff5,nCellSame5+nCellDiff5);
1445 //
1446 // printf("E %2.2f, Esame %2.2f, Ediff %2.2f, Esame5 %2.2f, Ediff3 %2.2f\n",
1447 // en,enSame,enDiff,enSame5,enDiff5);
1448 // }
1449 
1450  fhNCellsPerClusterSameDiff ->Fill(en, nCellSame , nCellDiff , GetEventWeight());
1451  fhNCellsPerClusterSameDiffW->Fill(en, nCellSameW, nCellDiffW, GetEventWeight());
1452 
1453  Float_t frac = (1.*nCellSame) /(nCaloCellsPerCluster-1.);
1454 
1455  fhNCellsPerClusterSameFrac ->Fill(en, frac , GetEventWeight());
1456  fhNCellsPerClusterSameFracExo ->Fill(en, frac , exoticity, GetEventWeight());
1457 
1459  {
1460  Float_t fracW = 0;
1461  if ( nCellW > 0 ) fracW = (1.*nCellSameW)/(nCellW);
1462 
1463  fhNCellsPerClusterSameFracW ->Fill(en, fracW, GetEventWeight());
1464  fhNCellsPerClusterSameFracWExo->Fill(en, fracW, exoticity, GetEventWeight());
1465 
1466  if ( nCellDiff == 0 )
1467  {
1468  fhNCellsPerClusterAllSameTCard->Fill(en, nCaloCellsPerCluster, GetEventWeight());
1469  fhExoticityEClusAllSameTCard ->Fill(en, exoticity , GetEventWeight());
1470  if ( fFillExo50ns )
1471  fhExoticity50nsEClusAllSameTCard ->Fill(en, exoticity50ns , GetEventWeight());
1472 
1473  fhM02EnergyAllSameTCard ->Fill(en, m02 , GetEventWeight());
1474  if ( en > fEMinForExo )
1475  fhEtaPhiGridExoEnCutSameFracCut->Fill(icolMaxAbs, irowMaxAbs, exoticity, GetEventWeight());
1476  }
1477  else
1478  {
1479  if ( ebin >= 0 && ebin < fgkNEBins-1 )
1480  fhM02ExoNCellsNotAllSameTCard[ebin]->Fill(m02, exoticity, nCaloCellsPerCluster, GetEventWeight()); ;
1481  }
1482 
1483  if ( nCellDiffW == 0 )
1484  {
1485  fhNCellsPerClusterAllSameTCardW->Fill(en, nCaloCellsPerCluster, GetEventWeight());
1486  fhExoticityEClusAllSameTCardW ->Fill(en, exoticity , GetEventWeight());
1487  fhM02EnergyAllSameTCardW ->Fill(en, m02 , GetEventWeight());
1488  if ( en > fEMinForExo )
1489  fhEtaPhiGridExoEnCutSameFracCutW->Fill(icolMaxAbs, irowMaxAbs, exoticity, GetEventWeight());
1490  }
1491 
1492  for(Int_t imin = 0; imin < nMinEnCut; imin++)
1493  {
1494  Float_t enCellMin = 0.2 + imin*0.1;
1495  fhNCellsPerClusterMinEnCut ->Fill(en, nCellDiffMinEn[imin]+nCellSameMinEn[imin], enCellMin, GetEventWeight());
1496  fhNCellsPerClusterDiffMinEnCut->Fill(en, nCellDiffMinEn[imin], enCellMin, GetEventWeight());
1497  fhNCellsPerClusterSameMinEnCut->Fill(en, nCellSameMinEn[imin], enCellMin, GetEventWeight());
1498 
1499  if ( nCellDiffMinEn[imin] == 0 )
1500  {
1501  fhNCellsPerClusterAllSameTCardMinEnCut->Fill(en, nCaloCellsPerCluster, enCellMin, GetEventWeight());
1502  fhExoticityEClusAllSameTCardMinEnCut ->Fill(en, exoticity , enCellMin, GetEventWeight());
1503  fhM02EnergyAllSameTCardMinEnCut ->Fill(en, m02 , enCellMin, GetEventWeight());
1504  }
1505  }
1506  } // fFillAllCellSameTCardHisto
1507 
1508  fhNCellsPerClusterSame ->Fill(en, nCellSame , GetEventWeight());
1509  fhNCellsPerClusterDiff ->Fill(en, nCellDiff , GetEventWeight());
1510  if ( ebin >= 0 && ebin < fgkNEBins-1 )
1511  {
1512  fhNCellsSameDiffExo[ebin]->Fill(nCellSame, nCellDiff, exoticity, GetEventWeight());
1513  fhEnSameDiffExo [ebin]->Fill(enSame , enDiff , exoticity, GetEventWeight());
1514  }
1515 
1517  {
1518  fhNCellsPerClusterSame5 ->Fill(en, nCellSame5 , GetEventWeight());
1519  fhNCellsPerClusterDiff5 ->Fill(en, nCellDiff5 , GetEventWeight());
1520  fhNCellsPerClusterSameW ->Fill(en, nCellSameW , GetEventWeight());
1521  fhNCellsPerClusterDiffW ->Fill(en, nCellDiffW , GetEventWeight());
1522 
1523  fhNCellsPerClusterSameTimeDiff ->Fill(en, nCellSameTimeDiff, GetEventWeight());
1524  fhNCellsPerClusterDiffTimeDiff ->Fill(en, nCellDiffTimeDiff, GetEventWeight());
1525  fhNCellsPerClusterSameDiffTimeDiff->Fill(en, nCellSameTimeDiff, nCellDiffTimeDiff, GetEventWeight());
1526 
1527  fhFracEnDiffSame ->Fill(en, fracEnDiffSame , GetEventWeight());
1528  fhFracNCellDiffSame ->Fill(en, fracNCellDiffSame , GetEventWeight());
1529  fhFracEnNCellDiffSame ->Fill(en, fracEnNCellDiffSame , GetEventWeight());
1530 
1531  fhFracEnDiffSameW ->Fill(en, fracEnDiffSameW , GetEventWeight());
1532  fhFracNCellDiffSameW ->Fill(en, fracNCellDiffSameW , GetEventWeight());
1533  fhFracEnNCellDiffSameW->Fill(en, fracEnNCellDiffSameW, GetEventWeight());
1534 
1535  fhFracEnDiffSame5 ->Fill(en, fracEnDiffSame5 , GetEventWeight());
1536  fhFracNCellDiffSame5 ->Fill(en, fracNCellDiffSame5 , GetEventWeight());
1537  fhFracEnNCellDiffSame5->Fill(en, fracEnNCellDiffSame5, GetEventWeight());
1538 
1539  fhFracEnDiffSameExo ->Fill(en, fracEnDiffSame , exoticity, GetEventWeight());
1540  fhFracNCellDiffSameExo ->Fill(en, fracNCellDiffSame , exoticity, GetEventWeight());
1541  fhFracEnNCellDiffSameExo ->Fill(en, fracEnNCellDiffSame , exoticity, GetEventWeight());
1542 
1543  fhFracEnDiffSameWExo ->Fill(en, fracEnDiffSameW , exoticity, GetEventWeight());
1544  fhFracNCellDiffSameWExo ->Fill(en, fracNCellDiffSameW , exoticity, GetEventWeight());
1545  fhFracEnNCellDiffSameWExo->Fill(en, fracEnNCellDiffSameW, exoticity, GetEventWeight());
1546 
1547  fhFracEnDiffSame5Exo ->Fill(en, fracEnDiffSame5 , exoticity, GetEventWeight());
1548  fhFracNCellDiffSame5Exo ->Fill(en, fracNCellDiffSame5 , exoticity, GetEventWeight());
1549  fhFracEnNCellDiffSame5Exo->Fill(en, fracEnNCellDiffSame5, exoticity, GetEventWeight());
1550 
1551  if ( en > fEMinForExo )
1552  {
1553  fhFracEnDiffSameEnCut ->Fill(fracEnDiffSame , GetEventWeight());
1554  fhFracNCellDiffSameEnCut ->Fill(fracNCellDiffSame , GetEventWeight());
1555  fhFracEnNCellDiffSameEnCut ->Fill(fracEnNCellDiffSame , GetEventWeight());
1556 
1557  fhFracEnDiffSameWEnCut ->Fill(fracEnDiffSameW , GetEventWeight());
1558  fhFracNCellDiffSameWEnCut ->Fill(fracNCellDiffSameW , GetEventWeight());
1559  fhFracEnNCellDiffSameWEnCut->Fill(fracEnNCellDiffSameW, GetEventWeight());
1560 
1561  fhFracEnDiffSame5EnCut ->Fill(fracEnDiffSame5 , GetEventWeight());
1562  fhFracNCellDiffSame5EnCut ->Fill(fracNCellDiffSame5 , GetEventWeight());
1563  fhFracEnNCellDiffSame5EnCut->Fill(fracEnNCellDiffSame5, GetEventWeight());
1564  }
1565 
1566  Float_t rEnSame = 1-enSame /ampMax;
1567  Float_t rEnDiff = 1-enDiff /ampMax;
1568  Float_t rEnSame5 = 1-enSame5/ampMax;
1569  Float_t rEnDiff5 = 1-enDiff5/ampMax;
1570 
1571  fhExoSame ->Fill(en, rEnSame , GetEventWeight());
1572  fhExoDiff ->Fill(en, rEnDiff , GetEventWeight());
1573  fhExoSame5->Fill(en, rEnSame5, GetEventWeight());
1574  fhExoDiff5->Fill(en, rEnDiff5, GetEventWeight());
1575 
1576  if ( ebin >= 0 && ebin < fgkNEBins-1 )
1577  {
1578  if ( nCellSame > 0 && nCellDiff > 0 )
1579  fhEnNCellsSameDiffExo[ebin]->Fill(enSame/nCellSame, enDiff/nCellDiff, exoticity, GetEventWeight());
1580  }
1581  }
1582 
1583  // Shower shape
1584  //
1585  fhM02EnergyExo ->Fill(en, m02, exoticity , GetEventWeight());
1586 
1587  if ( m02 > 0.1 )
1588  fhM20EnergyExoM02MinCut->Fill(en, m20, exoticity, GetEventWeight());
1589 
1590  if ( ebin >= 0 && ebin < fgkNEBins-1 )
1591  fhM02ExoNCells[ebin]->Fill(m02, exoticity, nCaloCellsPerCluster, GetEventWeight());
1592 
1593  if ( fFillExo50ns )
1594  {
1595  fhM02EnergyExo50ns ->Fill(en, m02, exoticity50ns, GetEventWeight());
1596  if ( ebin >= 0 && ebin < fgkNEBins-1 )
1597  fhM02Exo50nsNCells[ebin]->Fill(m02, exoticity50ns, nCaloCellsPerCluster, GetEventWeight());
1598  }
1599 
1600  // Track matching
1601  //
1602  if ( matched && fFillMatchingHisto && track )
1603  {
1604  fhEOverPExo->Fill(en, eOverP, exoticity, GetEventWeight());
1605 
1606  if ( positive )
1607  {
1608  fhTrackMatchedDEtaPosExo->Fill(en, deta, exoticity, GetEventWeight());
1609  fhTrackMatchedDPhiPosExo->Fill(en, dphi, exoticity, GetEventWeight());
1610 
1611  if ( en > fEMinForExo )
1612  {
1613  fhTrackMatchedDEtaDPhiPosExo->Fill(deta, dphi, exoticity, GetEventWeight());
1614  }
1615  }
1616  else
1617  {
1618  fhTrackMatchedDEtaNegExo->Fill(en, deta, exoticity, GetEventWeight());
1619  fhTrackMatchedDPhiNegExo->Fill(en, dphi, exoticity, GetEventWeight());
1620 
1621  if ( en > fEMinForExo )
1622  {
1623  fhTrackMatchedDEtaDPhiNegExo->Fill(deta, dphi, exoticity, GetEventWeight());
1624  }
1625  }
1626 
1627  } // matched
1628 
1629  } // Cluster loop
1630 
1631  // Counters per event
1632  fhNClusterPerEventNCellHigh20->Fill(nNCellW20 , GetEventWeight());
1633  fhNClusterPerEventNCellHigh12->Fill(nNCellW12 , GetEventWeight());
1634  fhNClusterPerEventExotic ->Fill(nExotic , GetEventWeight());
1635  fhNClusterPerEventExotic1Cell->Fill(nExotic1Cell, GetEventWeight());
1636  fhNClusterPerEventExoticNCell->Fill(nExoticNCell, GetEventWeight());
1637 
1638  fh2NClusterPerEventNCellHigh20->Fill(nCaloClusters, nNCellW20 , GetEventWeight());
1639  fh2NClusterPerEventNCellHigh12->Fill(nCaloClusters, nNCellW12 , GetEventWeight());
1640  fh2NClusterPerEventExotic ->Fill(nCaloClusters, nExotic , GetEventWeight());
1641  fh2NClusterPerEventExotic1Cell->Fill(nCaloClusters, nExotic1Cell, GetEventWeight());
1642  fh2NClusterPerEventExoticNCell->Fill(nCaloClusters, nExoticNCell, GetEventWeight());
1643 
1644  //if ( highestAmpMaxExo > 0 ) printf("Exotic final amp %f\n",highestAmpMaxExo);
1645 
1646  fh2NClusterPerEventExoticAmpMax->Fill(highestAmpMaxExo, nCaloClusters, GetEventWeight());
1647 
1648 }
1649 
1650 //____________________________________________________________________________
1655 //____________________________________________________________________________
1657 (const TObjArray *caloClusters, AliVCaloCells* cells)
1658 {
1659  Int_t nCaloClusters = caloClusters->GetEntriesFast() ;
1660  Int_t bc = GetReader()->GetInputEvent()->GetBunchCrossNumber();
1661 
1662  // Get vertex, not needed.
1663  Double_t v[3] = {0,0,0};
1664 
1665  AliDebug(1,Form("In %s there are %d clusters", GetCalorimeterString().Data(), nCaloClusters));
1666 
1667  //if ( bc < 0 || bc > 3563 ) printf("Unexpected BC: %d\n", bc);
1668 
1669  fhEventCutBunchCrossing[0]->Fill(bc, GetEventWeight());
1670 
1671  if ( fAcceptEvent )
1672  fhEventCutBunchCrossing[1]->Fill(bc, GetEventWeight());
1673 
1675  {
1676  fhEventCutBunchCrossing[2]->Fill(bc, GetEventWeight());
1677 
1678  if ( fAcceptEvent )
1679  fhEventCutBunchCrossing[3]->Fill(bc, GetEventWeight());
1680  }
1681 
1682  // Loop over CaloClusters
1683  for(Int_t iclus = 0; iclus < nCaloClusters; iclus++)
1684  {
1685  AliDebug(1,Form("Cluster: %d/%d, data %d",iclus+1,nCaloClusters,GetReader()->GetDataType()));
1686 
1687  AliVCluster* clus = (AliVCluster*) caloClusters->At(iclus);
1688 
1689  // Get cluster kinematics
1690  clus->GetMomentum(fClusterMomentum,v);
1691 
1692  Float_t en = fClusterMomentum.E();
1693 
1694  Int_t nCaloCellsPerCluster = clus->GetNCells();
1695  //Int_t nLabel = clus->GetNLabels();
1696  //Int_t *labels = clus->GetLabels();
1697 
1698  // Get the 1-fraction of the cluster energy that carries the cell with highest energy and its absId
1699  Float_t maxCellFraction = 0.;
1700  Int_t absIdMax = GetCaloUtils()->GetMaxEnergyCell(cells, clus,maxCellFraction);
1701 
1702  Int_t icolMax = -1, icolMaxAbs = -1;
1703  Int_t irowMax = -1, irowMaxAbs = -1;
1704  Int_t iRCU = -1;
1705  //Int_t nSM =
1707  icolMax , irowMax, iRCU,
1708  icolMaxAbs, irowMaxAbs );
1709 
1710  // Get time of max cell/cluster
1711  Double_t tmax = cells->GetCellTime(absIdMax);
1712  tmax*=1.e9;
1713  tmax-=fConstantTimeShift;
1714 
1715  Float_t ampMax = cells->GetCellAmplitude(absIdMax);
1716  Float_t enOrg = ampMax/(1-maxCellFraction); // cluster energy without non linearity correction
1717 
1718  Float_t exoticity = 1-GetCaloUtils()->GetECross(absIdMax,cells,bc)/ampMax;
1719 
1720  Float_t m02 = clus->GetM02();
1721 
1722 // if(fAcceptEvent)
1723 // if ( fEventNStripActive <= fEventMaxNumberOfStrips )
1724 // if ( fAcceptEvent && fEventNStripActive <= fEventMaxNumberOfStrips )
1725 //
1726 
1727  // Take only non exotic clusters
1728  if ( exoticity > 0.95 || m02 < 0.15 || nCaloCellsPerCluster < 3 ) continue;
1729 
1730  fhEventCutClusterEnergyTime[0]->Fill(en, tmax, GetEventWeight());
1731 
1732  if ( fAcceptEvent )
1733  fhEventCutClusterEnergyTime[1]->Fill(en, tmax, GetEventWeight());
1734 
1736  {
1737  fhEventCutClusterEnergyTime[2]->Fill(en, tmax, GetEventWeight());
1738 
1739  if ( fAcceptEvent )
1740  fhEventCutClusterEnergyTime[3]->Fill(en, tmax, GetEventWeight());
1741  }
1742 
1743  // Take clusters within good time window
1744  if ( tmax < fTimeCutMin || tmax> fTimeCutMax ) continue;
1745 
1746  fhEventCutClusterEnergy[0]->Fill(en, GetEventWeight());
1747  fhEventCutClusterEnergyECellMax[0]->Fill(enOrg, ampMax, GetEventWeight());
1748 
1749  if ( en > fEMinForExo )
1750  fhEventCutClusterEtaPhiGrid[0]->Fill(icolMaxAbs, irowMaxAbs, GetEventWeight());
1751 
1752  if ( fAcceptEvent )
1753  {
1754  fhEventCutClusterEnergy[1]->Fill(en, GetEventWeight());
1755  fhEventCutClusterEnergyECellMax[1]->Fill(enOrg, ampMax, GetEventWeight());
1756 
1757  if ( en > fEMinForExo )
1758  fhEventCutClusterEtaPhiGrid[1]->Fill(icolMaxAbs, irowMaxAbs, GetEventWeight());
1759  }
1760 
1762  {
1763  fhEventCutClusterEnergy[2]->Fill(en, GetEventWeight());
1764  fhEventCutClusterEnergyECellMax[2]->Fill(enOrg, ampMax, GetEventWeight());
1765 
1766  if ( en > fEMinForExo )
1767  fhEventCutClusterEtaPhiGrid[2]->Fill(icolMaxAbs, irowMaxAbs, GetEventWeight());
1768 
1769  if ( fAcceptEvent )
1770  {
1771  fhEventCutClusterEnergy[3]->Fill(en, GetEventWeight());
1772  fhEventCutClusterEnergyECellMax[3]->Fill(enOrg, ampMax, GetEventWeight());
1773 
1774  if ( en > fEMinForExo )
1775  fhEventCutClusterEtaPhiGrid[3]->Fill(icolMaxAbs, irowMaxAbs, GetEventWeight());
1776  } // fAcceptEvent
1777  } // good strips
1778 
1779  } // cluster loop
1780 
1781 }
1782 
1783 //_________________________________________________
1785 //_________________________________________________
1787 {
1788  TString parList ; //this will be list of parameters used for this analysis.
1789  const Int_t buffersize = 255;
1790  char onePar[buffersize] ;
1791 
1792  snprintf(onePar,buffersize,"--- AliAnaCaloExotics ---:") ;
1793  parList+=onePar ;
1794  snprintf(onePar,buffersize,"Calorimeter: %s;",GetCalorimeterString().Data()) ;
1795  parList+=onePar ;
1796 
1797  snprintf(onePar,buffersize,"Cell Amplitude > %2.1f GeV;",fCellAmpMin) ;
1798  parList+=onePar ;
1799 
1800  snprintf(onePar,buffersize,"E min Exo > %2.1f GeV;",fEMinForExo) ;
1801  parList+=onePar ;
1802 
1803  snprintf(onePar,buffersize,"F+ > %0.2f GeV;",fExoCut) ;
1804  parList+=onePar ;
1805 
1806  snprintf(onePar,buffersize,"NcellsW > %d;",fNCellHighCut) ;
1807  parList+=onePar ;
1808 
1809  snprintf(onePar,buffersize,"SM: nCell > %d, Sum E > %2.0f;",fHighNCellsCutSM,fHighEnergyCutSM) ;
1810  parList+=onePar ;
1811 
1812  snprintf(onePar,buffersize,"SM3: nCell < %d, Sum E < %2.0f;",fLowNCellsCutSM3,fLowEnergyCutSM3) ;
1813  parList+=onePar ;
1814 
1815  snprintf(onePar,buffersize,"Strip: nCell > %d-%d, Sum E > %2.0f-%2.0f; Event N Strips < %d;",
1818  parList+=onePar ;
1819 
1820  snprintf(onePar,buffersize,"SM3 strips: nCell < %d, Sum E < %2.0f;",fLowNCellsCutSM3Strip,fLowEnergyCutSM3Strip) ;
1821  parList+=onePar ;
1822 
1823  snprintf(onePar,buffersize,"%2.0f < time < %2.0f ns;",fTimeCutMin,fTimeCutMax) ;
1824  parList+=onePar ;
1825 
1826  snprintf(onePar,buffersize,"time shift = %2.0f;",fConstantTimeShift) ;
1827  parList+=onePar ;
1828 
1829  snprintf(onePar,buffersize,"fill cell histo: %d;",fFillCellHisto) ;
1830  parList+=onePar ;
1831 
1832  snprintf(onePar,buffersize,"fill cluster with 1 cell histo: %d;",fFill1CellHisto) ;
1833  parList+=onePar ;
1834 
1835  snprintf(onePar,buffersize,"fill cells in event histo: %d;",fFillAllCellEventParamHisto) ;
1836  parList+=onePar ;
1837 
1838  snprintf(onePar,buffersize,"fill strip histo: %d;",fFillStripHisto) ;
1839  parList+=onePar ;
1840 
1841  snprintf(onePar,buffersize,"fill cluster track-matching histo: %d;",fFillMatchingHisto) ;
1842  parList+=onePar ;
1843 
1844  snprintf(onePar,buffersize,"fill cluster exoticity 50ns histo: %d;",fFillExo50ns) ;
1845  parList+=onePar ;
1846 
1847  snprintf(onePar,buffersize,"fill cluster histo after event cuts: %d;",fFillClusterHistoAfterEventCut) ;
1848  parList+=onePar ;
1849 
1850  //Get parameters set in base class.
1851  //parList += GetBaseParametersList() ;
1852 
1853  //Get parameters set in FiducialCut class (not available yet)
1854  //parlist += GetFidCut()->GetFidCutParametersList()
1855 
1856  return new TObjString(parList) ;
1857 }
1858 
1859 //___________________________________________________
1862 //___________________________________________________
1864 {
1865  TList * outputContainer = new TList() ;
1866  outputContainer->SetName("ExoticHistos") ;
1867 
1868  // Init the number of modules, set in the class AliCalorimeterUtils
1869  //
1870  InitCaloParameters(); // See AliCaloTrackCorrBaseClass
1871 
1872  // Histogram binning and ranges
1873  //
1874 
1875  // Energy bins
1879 
1880  TCustomBinning eBinning;
1881  eBinning.SetMinimum(0);
1882  eBinning.AddStep(15,0.5); // 30
1883  if(ptmax > 15) eBinning.AddStep( 30, 1.0); // 15
1884  if(ptmax > 30) eBinning.AddStep( 60, 2.5); // 12
1885  if(ptmax > 60) eBinning.AddStep(100, 5.0); // 8
1886  if(ptmax > 100) eBinning.AddStep(200,10.0); // 10
1887  if(ptmax > 200) eBinning.AddStep(300,20.0); // 5
1888  TArrayD eBinsArray;
1889  eBinning.CreateBinEdges(eBinsArray);
1890 
1891  TCustomBinning e2Binning;
1892  e2Binning.SetMinimum(0.1);
1893  e2Binning.AddStep( 2,0.10); // 19
1894  e2Binning.AddStep( 5,0.25); // 12
1895  if(ptmax > 5) e2Binning.AddStep( 10, 0.50); // 10
1896  if(ptmax > 10) e2Binning.AddStep( 25, 1.00); // 15
1897  if(ptmax > 25) e2Binning.AddStep( 50, 2.50); // 8
1898  if(ptmax > 50) e2Binning.AddStep(100, 5.00); // 10
1899  if(ptmax > 100)e2Binning.AddStep(200,10.00); // 10
1900  if(ptmax > 200)e2Binning.AddStep(300,25.00); // 4
1901  TArrayD e2BinsArray;
1902  e2Binning.CreateBinEdges(e2BinsArray);
1903 
1904  TCustomBinning eminBinning;
1905  eminBinning.SetMinimum(0.15);
1906  eminBinning.AddStep(2.05,0.1);
1907  TArrayD eminBinsArray;
1908  eminBinning.CreateBinEdges(eminBinsArray);
1909 
1910  // Exoticity
1911 //Int_t nexobins = 201; Float_t exomin = -1 ; Float_t exomax = 1.01;
1912 
1913  TCustomBinning fBinning;
1914  fBinning.SetMinimum(-1.0);
1915  fBinning.AddStep(0.000,0.2000); // 5
1916  fBinning.AddStep(0.500,0.1000); // 5
1917  fBinning.AddStep(0.700,0.0500); // 4
1918  fBinning.AddStep(0.800,0.0200); // 5
1919  fBinning.AddStep(0.850,0.0100); // 5
1920  fBinning.AddStep(0.900,0.0050); // 20
1921  fBinning.AddStep(1.002,0.0020); // 51
1922  TArrayD fBinsArray;
1923  fBinning.CreateBinEdges(fBinsArray);
1924 
1925  // N cells in cluster
1926 //Int_t nceclbins = GetHistogramRanges()->GetHistoNClusterCellBins();
1929 
1930  TCustomBinning nBinning;
1931  nBinning.SetMinimum(nceclmin-0.5);
1932  nBinning.AddStep(nceclmax+0.5,1);
1933  TArrayD nBinsArray;
1934  nBinning.CreateBinEdges(nBinsArray);
1935 
1936  TCustomBinning n2Binning;
1937  n2Binning.SetMinimum(nceclmin-0.5);
1938  n2Binning.AddStep(2*nceclmax+0.5,1);
1939  TArrayD n2BinsArray;
1940  n2Binning.CreateBinEdges(n2BinsArray);
1941 
1942  TCustomBinning nsameBinning;
1943  nsameBinning.SetMinimum(-0.5);
1944  nsameBinning.AddStep(16.5,1);
1945  TArrayD nsameBinsArray;
1946  nsameBinning.CreateBinEdges(nsameBinsArray);
1947 
1948  // Super-module bins
1949  Int_t totalSM = fLastModule-fFirstModule+1;
1950 
1951  TCustomBinning smBinning;
1952  smBinning.SetMinimum(fFirstModule-0.5);
1953  smBinning.AddStep(fLastModule+0.5,1);
1954  TArrayD smBinsArray;
1955  smBinning.CreateBinEdges(smBinsArray);
1956 
1957  // Cell column-row histograms, see base class for data members setting
1958 //Int_t ncolcell = fNMaxColsFull+2;
1959  Float_t colcellmin = -1.5;
1960  Float_t colcellmax = fNMaxColsFull+0.5;
1961 
1962 //Int_t nrowcell = fNMaxRowsFullMax-fNMaxRowsFullMin+2;
1963  Float_t rowcellmin = fNMaxRowsFullMin-1.5;
1964  Float_t rowcellmax = fNMaxRowsFullMax+0.5;
1965 
1966  TCustomBinning rowBinning;
1967  rowBinning.SetMinimum(rowcellmin-1.5);
1968  rowBinning.AddStep(rowcellmax+0.5,1);
1969  TArrayD rowBinsArray;
1970  rowBinning.CreateBinEdges(rowBinsArray);
1971 
1972  TCustomBinning colBinning;
1973  colBinning.SetMinimum(colcellmin-1.5);
1974  colBinning.AddStep(colcellmax+0.5,1);
1975  TArrayD colBinsArray;
1976  colBinning.CreateBinEdges(colBinsArray);
1977 
1978  // Shower shape
1979 // Int_t ssbins = GetHistogramRanges()->GetHistoShowerShapeBins();
1980 // Float_t ssmax = GetHistogramRanges()->GetHistoShowerShapeMax();
1981 // Float_t ssmin = GetHistogramRanges()->GetHistoShowerShapeMin();
1982 
1983  TCustomBinning ssBinning;
1984  ssBinning.SetMinimum(-0.005);
1985  ssBinning.AddStep(0.505,0.005); //101
1986  ssBinning.AddStep(1.005,0.025); // 20
1987  ssBinning.AddStep(3.05,0.1); // 20
1988  TArrayD ssBinsArray;
1989  ssBinning.CreateBinEdges(ssBinsArray);
1990 
1991  // Fractions
1992  TCustomBinning fracBinning;
1993  fracBinning.SetMinimum(-0.1);
1994  fracBinning.AddStep(1.1,0.01);
1995  TArrayD fracBinsArray;
1996  fracBinning.CreateBinEdges(fracBinsArray);
1997 
1998  TCustomBinning frac2Binning;
1999  frac2Binning.SetMinimum(-0.1);
2000  frac2Binning.AddStep(2.1,0.01);
2001  TArrayD frac2BinsArray;
2002  frac2Binning.CreateBinEdges(frac2BinsArray);
2003 
2004  // Cluster time bins
2005  Int_t ntimebins = GetHistogramRanges()->GetHistoTimeBins();
2006  Float_t timemax = GetHistogramRanges()->GetHistoTimeMax();
2007  Float_t timemin = GetHistogramRanges()->GetHistoTimeMin();
2008 
2009  TCustomBinning tBinning;
2010  tBinning.SetMinimum(timemin);
2011  tBinning.AddStep(timemax,(timemax-timemin)/ntimebins);
2012  TArrayD tBinsArray;
2013  tBinning.CreateBinEdges(tBinsArray);
2014 
2015  TCustomBinning t2Binning;
2016  t2Binning.SetMinimum(-610);
2017  t2Binning.AddStep(610,20);
2018  TArrayD t2BinsArray;
2019  t2Binning.CreateBinEdges(t2BinsArray);
2020 
2021  // Difference in time within cluster
2025 
2026  TCustomBinning tdBinning;
2027  tdBinning.SetMinimum(tdmin);
2028  tdBinning.AddStep(tdmax,(tdmax-tdmin)/tdbins);
2029  TArrayD tdBinsArray;
2030  tdBinning.CreateBinEdges(tdBinsArray);
2031 
2032  // TM residuals
2039 
2040  TCustomBinning retaBinning;
2041  retaBinning.SetMinimum(resetamin);
2042  retaBinning.AddStep(resetamax,(resetamax-resetamin)/nresetabins);
2043  TArrayD retaBinsArray;
2044  retaBinning.CreateBinEdges(retaBinsArray);
2045 
2046  TCustomBinning rphiBinning;
2047  rphiBinning.SetMinimum(resphimin);
2048  rphiBinning.AddStep(resphimax,(resphimax-resphimin)/nresphibins);
2049  TArrayD rphiBinsArray;
2050  rphiBinning.CreateBinEdges(rphiBinsArray);
2051 
2052  // E over p bins
2053  Int_t nPoverEbins = GetHistogramRanges()->GetHistoEOverPBins();
2054  Float_t eOverPmax = GetHistogramRanges()->GetHistoEOverPMax();
2055  Float_t eOverPmin = GetHistogramRanges()->GetHistoEOverPMin();
2056 
2057  TCustomBinning eopBinning;
2058  eopBinning.SetMinimum(eOverPmin);
2059  eopBinning.AddStep(resphimax,(eOverPmax-eOverPmin)/nPoverEbins);
2060  TArrayD eopBinsArray;
2061  eopBinning.CreateBinEdges(eopBinsArray);
2062 
2063  // Cluster size
2064  TCustomBinning sizeBinning;
2065  sizeBinning.SetMinimum(-8.5);
2066  sizeBinning.AddStep(8.5,1);
2067  TArrayD sizeBinsArray;
2068  sizeBinning.CreateBinEdges(sizeBinsArray);
2069 
2070  //
2071  // Init histograms
2072  //
2073 
2074  // Event counters
2075  fhNClusterPerEventNCellHigh20 = new TH1F
2076  ("hNClusterPerEventNCellHigh20",
2077  "#it{n}_{cluster} per event with #it{n}_{cell}^{#it{w}} > 20",
2078  1000,0,1000);
2079  fhNClusterPerEventNCellHigh20->SetXTitle("#it{n}_{cluster}^{#it{n}_{cell}^{#it{w}} > 20}");
2080  fhNClusterPerEventNCellHigh20->SetYTitle("Counts per event");
2081  outputContainer->Add(fhNClusterPerEventNCellHigh20);
2082 
2083  fhNClusterPerEventNCellHigh12 = new TH1F
2084  ("hNClusterPerEventNCellHigh12",
2085  "#it{n}_{cluster} per event with #it{n}_{cell}^{#it{w}} > 12",
2086  1000,0,1000);
2087  fhNClusterPerEventNCellHigh12->SetXTitle("#it{n}_{cluster}^{#it{n}_{cell}^{#it{w}} > 12}");
2088  fhNClusterPerEventNCellHigh12->SetYTitle("Counts per event");
2089  outputContainer->Add(fhNClusterPerEventNCellHigh12);
2090 
2091  fhNClusterPerEventExotic = new TH1F
2092  ("hNClusterPerEventExotic",
2093  "#it{n}_{cluster} per event with #it{E} > 5 GeV, #it{F}_{+} > 0.97",
2094  200,0,200);
2095  fhNClusterPerEventExotic->SetXTitle("#it{n}_{cluster}^{#it{F}_{+} > 0.97}");
2096  fhNClusterPerEventExotic->SetYTitle("Counts per event");
2097  outputContainer->Add(fhNClusterPerEventExotic);
2098 
2099  fhNClusterPerEventExotic1Cell = new TH1F
2100  ("hNClusterPerEventExotic1Cell",
2101  "#it{n}_{cluster} per event with #it{E} > 5 GeV, #it{n}_{cells} = 1",
2102  200,0,200);
2103  fhNClusterPerEventExotic1Cell->SetXTitle("#it{n}_{cluster}^{#it{n}_{cells} = 1}");
2104  fhNClusterPerEventExotic1Cell->SetYTitle("Counts per event");
2105  outputContainer->Add(fhNClusterPerEventExotic1Cell);
2106 
2107  fhNClusterPerEventExoticNCell = new TH1F
2108  ("hNClusterPerEventExoticNCell",
2109  "#it{n}_{cluster} per event with #it{E} > 5 GeV, #it{n}_{cells} > 1, #it{F}_{+} > 0.97",
2110  200,0,200);
2111  fhNClusterPerEventExoticNCell->SetXTitle("#it{n}_{cluster}^{#it{F}_{+} > 0.97, #it{n}_{cells} > 1}");
2112  fhNClusterPerEventExoticNCell->SetYTitle("Counts per event");
2113  outputContainer->Add(fhNClusterPerEventExoticNCell);
2114 
2116 
2118  ("h2NClusterPerEventNCellHigh20",
2119  "#it{n}_{cluster} per event with #it{n}_{cell}^{#it{w}} > 20",
2120  500,0,500,500,0,500);
2121  fh2NClusterPerEventNCellHigh20->SetXTitle("#it{n}_{cluster}");
2122  fh2NClusterPerEventNCellHigh20->SetYTitle("#it{n}_{cluster}^{#it{n}_{cell}^{#it{w}} > 20}");
2123  fh2NClusterPerEventNCellHigh20->SetZTitle("Counts per event");
2124  outputContainer->Add(fh2NClusterPerEventNCellHigh20);
2125 
2127  ("h2NClusterPerEventNCellHigh12",
2128  "#it{n}_{cluster} per event, total vs with #it{n}_{cell}^{#it{w}} > 12",
2129  500,0,500,500,0,500);
2130  fh2NClusterPerEventNCellHigh12->SetXTitle("#it{n}_{cluster}");
2131  fh2NClusterPerEventNCellHigh12->SetYTitle("#it{n}_{cluster}^{#it{n}_{cell}^{#it{w}} > 12}");
2132  fh2NClusterPerEventNCellHigh12->SetZTitle("Counts per event");
2133  outputContainer->Add(fh2NClusterPerEventNCellHigh12);
2134 
2136  ("h2NClusterPerEventExotic",
2137  "#it{n}_{cluster} per event, total vs with #it{E} > 5 GeV, #it{F}_{+} > 0.97",
2138  200,0,200,200,0,200);
2139  fh2NClusterPerEventExotic->SetXTitle("#it{n}_{cluster}");
2140  fh2NClusterPerEventExotic->SetYTitle("#it{n}_{cluster}^{#it{F}_{+} > 0.97}");
2141  fh2NClusterPerEventExotic->SetZTitle("Counts per event");
2142  outputContainer->Add(fh2NClusterPerEventExotic);
2143 
2145  ("h2NClusterPerEventExotic1Cell",
2146  "#it{n}_{cluster} per event, total vs with #it{E} > 5 GeV, #it{n}_{cells} = 1",
2147  200,0,200,200,0,200);
2148  fh2NClusterPerEventExotic1Cell->SetXTitle("#it{n}_{cluster}");
2149  fh2NClusterPerEventExotic1Cell->SetYTitle("#it{n}_{cluster}^{#it{n}_{cells} = 1}");
2150  fh2NClusterPerEventExotic1Cell->SetZTitle("Counts per event");
2151  outputContainer->Add(fh2NClusterPerEventExotic1Cell);
2152 
2154  ("h2NClusterPerEventExoticNCell",
2155  "#it{n}_{cluster} per event, total vs with #it{E} > 5 GeV, #it{n}_{cells} > 1, #it{F}_{+} > 0.97",
2156  200,0,200,200,0,200);
2157  fh2NClusterPerEventExoticNCell->SetXTitle("#it{n}_{cluster}");
2158  fh2NClusterPerEventExoticNCell->SetYTitle("#it{n}_{cluster}^{#it{F}_{+} > 0.97, #it{n}_{cells} > 1}");
2159  fh2NClusterPerEventExoticNCell->SetZTitle("Counts per event");
2160  outputContainer->Add(fh2NClusterPerEventExoticNCell);
2161 
2163  ("h2NClusterPerEventExoticAmpMax",
2164  "#it{n}_{cluster} per event vs highest energy cluster cell with #it{F}_{+} > 0.97",
2165  nptbins,ptmin,ptmax,100,0,100);
2166  fh2NClusterPerEventExoticAmpMax->SetXTitle("#it{E}_{cell}^{#it{F}_{+} > 0.97}");
2167  fh2NClusterPerEventExoticAmpMax->SetYTitle("#it{n}_{cluster}");
2168  fh2NClusterPerEventExoticAmpMax->SetZTitle("Counts per event");
2169  outputContainer->Add(fh2NClusterPerEventExoticAmpMax);
2170 
2171  // Cluster Exoticity 2D
2172  //
2173  fhExoticityEClus = new TH2F
2174  ("hExoticityEClus","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2175  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2176  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2177  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2178  fhExoticityEClus->SetXTitle("#it{E}_{cluster} (GeV) ");
2179  fhExoticityEClus->SetYTitle("#it{F}_{+}");
2180  outputContainer->Add(fhExoticityEClus);
2181 
2182  fhExoticityEMaxCell = new TH2F
2183  ("hExoticityEMaxCell","cell #it{F}_{+} vs #it{E}_{cell}^{max}, #it{n}_{cluster}^{cell} > 1",
2184  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2185  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2186  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2187  fhExoticityEMaxCell->SetXTitle("#it{E}_{cell}^{max} (GeV) ");
2188  fhExoticityEMaxCell->SetYTitle("#it{F}_{+}");
2189  outputContainer->Add(fhExoticityEMaxCell);
2190 
2191  if ( fFillPerSMHisto )
2192  {
2194  ("hExoticityEClusPerSM","cell #it{F}_{+} vs #it{E}_{cluster}, vs SM, #it{n}_{cluster}^{cell} > 1",
2195  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2196  fBinsArray.GetSize() - 1, fBinsArray.GetArray(),
2197  smBinsArray.GetSize() - 1, smBinsArray.GetArray());
2198  //nptbins,ptmin,ptmax, nexobins,exomin,exomax, totalSM,fFirstModule-0.5,fLastModule+0.5);
2199  fhExoticityEClusPerSM->SetXTitle("#it{E}_{cluster} (GeV) ");
2200  fhExoticityEClusPerSM->SetYTitle("#it{F}_{+}");
2201  fhExoticityEClusPerSM->SetZTitle("SM");
2202  outputContainer->Add(fhExoticityEClusPerSM);
2203  }
2204 
2205  if ( fFill1CellHisto )
2206  {
2207  fhExoticity1Cell = new TH2F
2208  ("hExoticity1Cell","cell #it{F}_{+} vs #it{E}, #it{n}_{cluster}^{cell} = 1",
2209  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2210  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2211  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2212  fhExoticity1Cell->SetXTitle("#it{E} (GeV) ");
2213  fhExoticity1Cell->SetYTitle("#it{F}_{+}");
2214  outputContainer->Add(fhExoticity1Cell);
2215  }
2216 
2217  if ( fFillExo50ns )
2218  {
2219  fhExoticity50nsEClus = new TH2F
2220  ("hExoticity50nsEClus","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2221  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2222  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2223  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2224  fhExoticity50nsEClus->SetXTitle("#it{E}_{cluster} (GeV) ");
2225  fhExoticity50nsEClus->SetYTitle("#it{F}_{+}");
2226  outputContainer->Add(fhExoticity50nsEClus);
2227 
2228  if ( fFill1CellHisto )
2229  {
2230  fhExoticity50ns1Cell = new TH2F
2231  ("hExoticity50ns1Cell","cell #it{F}_{+} vs #it{E}, #it{n}_{cluster}^{cell} = 1",
2232  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2233  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2234  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2235  fhExoticity50ns1Cell->SetXTitle("#it{E} (GeV) ");
2236  fhExoticity50ns1Cell->SetYTitle("#it{F}_{+}");
2237  outputContainer->Add(fhExoticity50ns1Cell);
2238  }
2239  }
2240 
2241  // N cells per cluster
2242  //
2243  if ( fFillOpenTimeHisto )
2244  {
2246  ("hNCellsPerClusterOpenTime","#it{n}_{cells} vs #it{E}_{cluster}, no time cut",
2247  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2248  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2249  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2250  fhNCellsPerClusterOpenTime->SetXTitle("#it{E}_{cluster} (GeV)");
2251  fhNCellsPerClusterOpenTime->SetYTitle("#it{n}_{cells}");
2252  outputContainer->Add(fhNCellsPerClusterOpenTime);
2253 
2255  ("hNCellsPerClusterWOpenTime","#it{n}_{cells} with w > 0 vs #it{E}_{cluster}, no time cut",
2256  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2257  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2258  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2259  fhNCellsPerClusterWOpenTime->SetXTitle("#it{E}_{cluster} (GeV)");
2260  fhNCellsPerClusterWOpenTime->SetYTitle("#it{n}_{cells}");
2261  outputContainer->Add(fhNCellsPerClusterWOpenTime);
2262 
2264  ("hNCellsPerClusterEMaxCellOpenTime","#it{n}_{cells} vs #it{E}_{cell}^{max}, no time cut",
2265  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2266  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2267  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2268  fhNCellsPerClusterEMaxCellOpenTime->SetXTitle("#it{E}_{cell}^{max} (GeV)");
2269  fhNCellsPerClusterEMaxCellOpenTime->SetYTitle("#it{n}_{cells}");
2270  outputContainer->Add(fhNCellsPerClusterEMaxCellOpenTime);
2271 
2273  ("hNCellsPerClusterWEMaxCellOpenTime","#it{n}_{cells} with w > 0 vs #it{E}_{cell}^{max}, no time cut",
2274  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2275  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2276  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2277  fhNCellsPerClusterWEMaxCellOpenTime->SetXTitle("#it{E}_{cell}^{max} (GeV)");
2278  fhNCellsPerClusterWEMaxCellOpenTime->SetYTitle("#it{n}_{cells}");
2279  outputContainer->Add(fhNCellsPerClusterWEMaxCellOpenTime);
2280  }
2281 
2282  fhNCellsPerCluster = new TH2F
2283  ("hNCellsPerCluster","#it{n}_{cells} vs #it{E}_{cluster}",
2284  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2285  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2286  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2287  fhNCellsPerCluster->SetXTitle("#it{E}_{cluster} (GeV)");
2288  fhNCellsPerCluster->SetYTitle("#it{n}_{cells}");
2289  outputContainer->Add(fhNCellsPerCluster);
2290 
2291  fhNCellsPerClusterW = new TH2F
2292  ("hNCellsPerClusterW","#it{n}_{cells} with w > 0 vs #it{E}_{cluster}",
2293  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2294  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2295  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2296  fhNCellsPerClusterW->SetXTitle("#it{E}_{cluster} (GeV)");
2297  fhNCellsPerClusterW->SetYTitle("#it{n}^{#it{w}}_{cells}");
2298  outputContainer->Add(fhNCellsPerClusterW);
2299 
2301  ("hNCellsPerClusterTimeDiff","#it{n}_{cells} with #Delta #it{t} < 50 vs #it{E}_{cluster}",
2302  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2303  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2304  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2305  fhNCellsPerClusterTimeDiff->SetXTitle("#it{E}_{cluster} (GeV)");
2306  fhNCellsPerClusterTimeDiff->SetYTitle("#it{n}^{#Delta #it{t} < 50}_{cells}");
2307  outputContainer->Add(fhNCellsPerClusterTimeDiff);
2308 
2310  ("hNCellsPerClusterEMaxCell","#it{n}_{cells} vs #it{E}_{cell}^{max}",
2311  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2312  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2313  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2314  fhNCellsPerClusterEMaxCell->SetXTitle("#it{E}_{cell}^{max} (GeV)");
2315  fhNCellsPerClusterEMaxCell->SetYTitle("#it{n}_{cells}");
2316  outputContainer->Add(fhNCellsPerClusterEMaxCell);
2317 
2319  ("hNCellsPerClusterWEMaxCell","#it{n}_{cells} with w > 0 vs #it{E}_{cell}^{max}",
2320  //nptbins,ptmin,ptmax, nceclbins*2,nceclmin,nceclmax*2);
2321  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2322  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2323  fhNCellsPerClusterWEMaxCell->SetXTitle("#it{E}_{cell}^{max} (GeV)");
2324  fhNCellsPerClusterWEMaxCell->SetYTitle("#it{n}_{cells}^{#it{w}}");
2325  outputContainer->Add(fhNCellsPerClusterWEMaxCell);
2326 
2328  ("hNCellsPerClusterExo","# cells per cluster vs #it{E}_{cluster} vs #it{F}_{+}",
2329  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2330  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2331  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2332  //nptbins/2,ptmin,ptmax, nceclbins,nceclmin,nceclmax,nexobinsS,exominS,exomaxS);
2333  fhNCellsPerClusterExo->SetXTitle("#it{E}_{cluster} (GeV)");
2334  fhNCellsPerClusterExo->SetYTitle("#it{n}_{cells}");
2335  fhNCellsPerClusterExo->SetZTitle("#it{F}_{+}");
2336  outputContainer->Add(fhNCellsPerClusterExo);
2337 
2338  if ( fFillExo50ns )
2339  {
2341  ("hNCellsPerClusterExo50ns","# cells per cluster vs #it{E}_{cluster} vs #it{F}_{+}",
2342  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2343  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2344  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2345  //nptbins/2,ptmin,ptmax, nceclbins,nceclmin,nceclmax,nexobinsS,exominS,exomaxS);
2346  fhNCellsPerClusterExo50ns->SetXTitle("#it{E}_{cluster} (GeV)");
2347  fhNCellsPerClusterExo50ns->SetYTitle("#it{n}_{cells}");
2348  fhNCellsPerClusterExo50ns->SetZTitle("#it{F}_{+}");
2349  outputContainer->Add(fhNCellsPerClusterExo50ns);
2350  }
2351 
2352  if ( fFillPerSMHisto )
2353  {
2355  ("hNCellsPerClusterPerSM","# cells per cluster vs #it{E}_{cluster} vs #it{F}_{+}",
2356  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2357  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2358  smBinsArray.GetSize() - 1, smBinsArray.GetArray());
2359  //nptbins/2,ptmin,ptmax, nceclbins,nceclmin,nceclmax,totalSM,fFirstModule-0.5,fLastModule+0.5);
2360  fhNCellsPerClusterPerSM->SetXTitle("#it{E}_{cluster} (GeV)");
2361  fhNCellsPerClusterPerSM->SetYTitle("#it{n}_{cells}");
2362  fhNCellsPerClusterPerSM->SetZTitle("SM");
2363  outputContainer->Add(fhNCellsPerClusterPerSM);
2364 
2366  ("hNCellsPerClusterWPerSM","# cells per cluster vs #it{E}_{cluster} vs #it{F}_{+}",
2367  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2368  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2369  smBinsArray.GetSize() - 1, smBinsArray.GetArray());
2370  //nptbins/2,ptmin,ptmax, nceclbins,nceclmin,nceclmax,totalSM,fFirstModule-0.5,fLastModule+0.5);
2371  fhNCellsPerClusterWPerSM->SetXTitle("#it{E}_{cluster} (GeV)");
2372  fhNCellsPerClusterWPerSM->SetYTitle("#it{n}_{cells}^{#it{w}}");
2373  fhNCellsPerClusterWPerSM->SetZTitle("SM");
2374  outputContainer->Add(fhNCellsPerClusterWPerSM);
2375 
2376  for(Int_t imod = 0; imod < totalSM; imod++)
2377  {
2378  if(imod < fFirstModule || imod > fLastModule) continue;
2379 
2380  fhNCellsPerClusterExoPerSM[imod] = new TH3F
2381  (Form("hNCellsPerClusterExo_SM%d",imod),
2382  Form("# cells per cluster vs #it{E}_{cluster} vs exoticity, SM%d",imod),
2383  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2384  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2385  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2386  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax,nexobinsS,exominS,exomaxS);
2387  fhNCellsPerClusterExoPerSM[imod]->SetXTitle("#it{E}_{cluster} (GeV)");
2388  fhNCellsPerClusterExoPerSM[imod]->SetYTitle("#it{n}_{cells}");
2389  fhNCellsPerClusterExoPerSM[imod]->SetZTitle("#it{F}_{+}");
2390  outputContainer->Add(fhNCellsPerClusterExoPerSM[imod]);
2391  }
2392  }
2393 
2394  if ( fFillMatchingHisto )
2395  {
2397  ("hExoticityEClusTrackMatch","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1, track matched",
2398  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2399  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2400  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2401  fhExoticityEClusTrackMatch->SetXTitle("#it{E}_{cluster} (GeV) ");
2402  fhExoticityEClusTrackMatch->SetYTitle("#it{F}_{+}");
2403  outputContainer->Add(fhExoticityEClusTrackMatch);
2404 
2406  ("hNCellsPerClusterTrackMatch","# cells per cluster vs #it{E}_{cluster}, track-matched",
2407  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
2408  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2409  n2BinsArray.GetSize() - 1, n2BinsArray.GetArray());
2410  fhNCellsPerClusterTrackMatch->SetXTitle("#it{E}_{cluster} (GeV)");
2411  fhNCellsPerClusterTrackMatch->SetYTitle("#it{n}_{cells}");
2412  outputContainer->Add(fhNCellsPerClusterTrackMatch);
2413 
2415  ("hNCellsPerClusterExoTrackMatch","# cells per cluster vs #it{E}_{cluster}, track-matched",
2416  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax, nexobinsS,exominS,exomaxS);
2417  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2418  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2419  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2420  fhNCellsPerClusterExoTrackMatch->SetXTitle("#it{E}_{cluster} (GeV)");
2421  fhNCellsPerClusterExoTrackMatch->SetYTitle("#it{n}_{cells}");
2422  fhNCellsPerClusterExoTrackMatch->SetZTitle("#it{F}_{+}");
2423  outputContainer->Add(fhNCellsPerClusterExoTrackMatch);
2424  }
2425 
2427  ("hNCellsPerClusterM02","# cells per cluster vs #it{E}_{cluster} vs #sigma^{2}_{long}",
2428  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax,100,0,0.5);
2429  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2430  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2431  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray());
2432  fhNCellsPerClusterM02->SetXTitle("#it{E}_{cluster} (GeV)");
2433  fhNCellsPerClusterM02->SetYTitle("#it{n}_{cells}");
2434  fhNCellsPerClusterM02->SetZTitle("#sigma^{2}_{long}");
2435  outputContainer->Add(fhNCellsPerClusterM02);
2436 
2437  // Different n cells in cluster depending T-Card
2438  //
2440  ("hNCellsPerClusterSameDiff","#it{n}_{cells} in same vs different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2441  //nptbins,ptmin,ptmax, 17,0,17,nceclbins,nceclmin,nceclmax);
2442  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2443  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray(),
2444  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
2445  fhNCellsPerClusterSameDiff->SetXTitle("#it{E}_{cluster} (GeV)");
2446  fhNCellsPerClusterSameDiff->SetYTitle("#it{n}_{cells, same T-Card}");
2447  fhNCellsPerClusterSameDiff->SetZTitle("#it{n}_{cells, diff T-Card}");
2448  outputContainer->Add(fhNCellsPerClusterSameDiff);
2449 
2451  ("hNCellsPerClusterSame","# cells per cluster in same T-Card as max #it{E} cell vs #it{E}_{cluster}",
2452  //nptbins,ptmin,ptmax, 17,0,17);
2453  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2454  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray());
2455  fhNCellsPerClusterSame->SetXTitle("#it{E}_{cluster} (GeV)");
2456  fhNCellsPerClusterSame->SetYTitle("#it{n}_{cells, same T-Card}");
2457  outputContainer->Add(fhNCellsPerClusterSame);
2458 
2460  ("hNCellsPerClusterDiff","# cells per cluster in different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2461  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
2462  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2463  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
2464  fhNCellsPerClusterDiff->SetXTitle("#it{E}_{cluster} (GeV)");
2465  fhNCellsPerClusterDiff->SetYTitle("#it{n}_{cells, diff T-Card}");
2466  outputContainer->Add(fhNCellsPerClusterDiff);
2467 
2468  for(Int_t i = 0; i < fgkNEBins-1; i++)
2469  {
2470  fhNCellsSameDiffExo[i] = new TH3F
2471  (Form("hNCellsSameDiffExo_Ebin%d",i),
2472  Form("#it{n}_{cells-same} vs #it{n}_{cells-diff}, %2.1f < #it{E} < %2.1f GeV",fEnergyBins[i],fEnergyBins[i+1]),
2473  //17,0,17,nceclbins,nceclmin,nceclmax,nexobinsS,exominS,exomaxS);
2474  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray(),
2475  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
2476  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2477  fhNCellsSameDiffExo[i]->SetXTitle("#it{n}_{cells}^{same}");
2478  fhNCellsSameDiffExo[i]->SetYTitle("#it{n}_{cells}^{diff}");
2479  fhNCellsSameDiffExo[i]->SetZTitle("#it{F}_{+}");
2480  outputContainer->Add(fhNCellsSameDiffExo[i]);
2481 
2482  fhEnSameDiffExo[i] = new TH3F
2483  (Form("hEnSameDiffExo_Ebin%d",i),
2484  Form("#Sigma #it{E}_{same}^{cells} vs #Sigma #it{E}_{diff}^{cells}, %2.1f < #it{E} < %2.1f GeV",fEnergyBins[i],fEnergyBins[i+1]),
2485  //200, 0, 20, 200, 0, 20, nexobinsS,exominS,exomaxS);
2486  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
2487  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
2488  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2489  fhEnSameDiffExo[i]->SetXTitle("#Sigma #it{E}_{same}^{cells} (GeV)");
2490  fhEnSameDiffExo[i]->SetYTitle("#Sigma #it{E}_{diff}^{cells} (GeV)");
2491  fhEnSameDiffExo[i]->SetZTitle("#it{F}_{+}");
2492  outputContainer->Add(fhEnSameDiffExo[i]);
2493  }
2494 
2495  // Only cells with weight
2497  ("hNCellsPerClusterSameDiffW","#it{n}^{#it{w}}_{cells} in same vs different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2498  //nptbins,ptmin,ptmax, 17,0,17,nceclbins,nceclmin,nceclmax);
2499  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2500  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray(),
2501  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
2502  fhNCellsPerClusterSameDiffW->SetXTitle("#it{E}_{cluster} (GeV)");
2503  fhNCellsPerClusterSameDiffW->SetYTitle("#it{n}_{cells, same T-Card}^{#it{w}}");
2504  fhNCellsPerClusterSameDiffW->SetZTitle("#it{n}_{cells, diff T-Card}^{#it{w}}");
2505  outputContainer->Add(fhNCellsPerClusterSameDiffW);
2506 
2508  ("hNCellsPerClusterSameFrac","Fraction of # cells per cluster in same T-Card as max #it{E} cell vs #it{E}_{cluster}",
2509  //nptbins,ptmin,ptmax, 101,-0.005,1.005);
2510  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2511  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray());
2512  fhNCellsPerClusterSameFrac->SetXTitle("#it{E}_{cluster} (GeV)");
2513  fhNCellsPerClusterSameFrac->SetYTitle("#it{n}_{cells, same T-Card} / (#it{n}_{cells}-1)");
2514  outputContainer->Add(fhNCellsPerClusterSameFrac);
2515 
2517  ("hNCellsPerClusterSameFracExo","Fraction of # cells per cluster in same T-Card as max #it{E} cell vs #it{E}_{cluster} vs #it{F}_{+}",
2518  //nptbins,ptmin,ptmax, 101,-0.005,1.005, nexobins,exomin,exomax);
2519  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2520  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray(),
2521  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2522  fhNCellsPerClusterSameFracExo->SetXTitle("#it{E}_{cluster} (GeV)");
2523  fhNCellsPerClusterSameFracExo->SetYTitle("#it{n}_{cells, same T-Card} / (#it{n}_{cells}-1)");
2524  fhNCellsPerClusterSameFracExo->SetZTitle("#it{F}_{+}");
2525  outputContainer->Add(fhNCellsPerClusterSameFracExo);
2526 
2527  if ( fFillSameDiffFracHisto )
2528  {
2530  ("hNCellsPerClusterSameFracW","Fraction of #it{n}^{#it{w}}_{cells} in same T-Card as max #it{E} cell vs #it{E}_{cluster}",
2531  //nptbins,ptmin,ptmax, 101,-0.005,1.005);
2532  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2533  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray());
2534  fhNCellsPerClusterSameFracW->SetXTitle("#it{E}_{cluster} (GeV)");
2535  fhNCellsPerClusterSameFracW->SetYTitle("#it{n}^{#it{w}}_{cells, same T-Card} / #it{n}^{#it{w}}_{cells}");
2536  outputContainer->Add(fhNCellsPerClusterSameFracW);
2537 
2539  ("hNCellsPerClusterSameFracWExo","Fraction of #it{n}^{#it{w}}_{cells} in same T-Card as max #it{E} cell vs #it{E}_{cluster} vs #it{F}_{+}",
2540  //nptbins,ptmin,ptmax, 101,-0.005,1.005, nexobins,exomin,exomax);
2541  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2542  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray(),
2543  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2544  fhNCellsPerClusterSameFracWExo->SetXTitle("#it{E}_{cluster} (GeV)");
2545  fhNCellsPerClusterSameFracWExo->SetYTitle("#it{n}^{#it{w}}_{cells, same T-Card} / #it{n}^{#it{w}}_{cells}");
2546  fhNCellsPerClusterSameFracWExo->SetZTitle("#it{F}_{+}");
2547  outputContainer->Add(fhNCellsPerClusterSameFracWExo);
2548 
2550  ("hNCellsPerClusterSame5","# cells per cluster in same T-Card as max #it{E} cell vs #it{E}_{cluster}",
2551  nptbins,ptmin,ptmax, 7,0,7);
2552  fhNCellsPerClusterSame5->SetXTitle("#it{E}_{cluster} (GeV)");
2553  fhNCellsPerClusterSame5->SetYTitle("#it{n}_{cells, same T-Card}");
2554  outputContainer->Add(fhNCellsPerClusterSame5);
2555 
2557  ("hNCellsPerClusterDiff5","# cells per cluster in different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2558  nptbins,ptmin,ptmax, 7,0,7);
2559  fhNCellsPerClusterDiff5->SetXTitle("#it{E}_{cluster} (GeV)");
2560  fhNCellsPerClusterDiff5->SetYTitle("#it{n}_{cells, diff T-Card}");
2561  outputContainer->Add(fhNCellsPerClusterDiff5);
2562 
2564  ("hNCellsPerClusterSameW","# cells per cluster with #it{w} in same T-Card as max #it{E} cell vs #it{E}_{cluster}",
2565  //nptbins,ptmin,ptmax, 17,0,17);
2566  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2567  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray());
2568  fhNCellsPerClusterSameW ->SetXTitle("#it{E}_{cluster} (GeV)");
2569  fhNCellsPerClusterSameW ->SetYTitle("#it{n}_{cells, same T-Card}^{#it{w}}");
2570  outputContainer->Add(fhNCellsPerClusterSameW );
2571 
2573  ("hNCellsPerClusterDiffW","# cells per cluster with #it{w} in different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2574  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
2575  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2576  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
2577  fhNCellsPerClusterDiffW ->SetXTitle("#it{E}_{cluster} (GeV)");
2578  fhNCellsPerClusterDiffW ->SetYTitle("#it{n}_{cells, diff T-Card}^{#it{w}}");
2579  outputContainer->Add(fhNCellsPerClusterDiffW );
2580 
2582  ("hNCellsPerClusterSameTimeDiff","# cells per cluster with #Delta #it{t}_{diff}<50 ns in same T-Card as max #it{E} cell vs #it{E}_{cluster}",
2583  //nptbins,ptmin,ptmax, 17,0,17);
2584  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2585  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray());
2586  fhNCellsPerClusterSameTimeDiff ->SetXTitle("#it{E}_{cluster} (GeV)");
2587  fhNCellsPerClusterSameTimeDiff ->SetYTitle("#it{n}_{cells, same T-Card}^{#it{w}}");
2588  outputContainer->Add(fhNCellsPerClusterSameTimeDiff );
2589 
2591  ("hNCellsPerClusterDiffTimeDiff","# cells per cluster with #Delta #it{t}_{diff}<50 in different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2592  //nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
2593  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2594  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
2595  fhNCellsPerClusterDiffTimeDiff ->SetXTitle("#it{E}_{cluster} (GeV)");
2596  fhNCellsPerClusterDiffTimeDiff ->SetYTitle("#it{n}_{cells, diff T-Card}^{#it{w}}");
2597  outputContainer->Add(fhNCellsPerClusterDiffTimeDiff );
2598 
2600  ("hNCellsPerClusterSameDiffTimeDiff","#it{n}^{#it{w}}_{cells} in same vs different T-Card as max #it{E} cell vs #it{E}_{cluster}",
2601  //nptbins,ptmin,ptmax, 17,0,17,nceclbins,nceclmin,nceclmax);
2602  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2603  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray(),
2604  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
2605  fhNCellsPerClusterSameDiffTimeDiff->SetXTitle("#it{E}_{cluster} (GeV)");
2606  fhNCellsPerClusterSameDiffTimeDiff->SetYTitle("#it{n}_{cells, same T-Card}^{#Delta #it{t}<50}");
2607  fhNCellsPerClusterSameDiffTimeDiff->SetZTitle("#it{n}_{cells, diff T-Card}^{#Delta #it{t}<50}");
2608  outputContainer->Add(fhNCellsPerClusterSameDiffTimeDiff);
2609 
2610  // Cluster Exoticity other definitions
2611  //
2612 
2613  fhExoSame = new TH2F
2614  ("hExoSame","cell #it{F}_{same} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2615  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2616  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2617  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2618  fhExoSame->SetXTitle("#it{E}_{cluster} (GeV)");
2619  fhExoSame->SetYTitle("#it{F}_{same}");
2620  outputContainer->Add(fhExoSame);
2621 
2622  fhExoDiff = new TH2F
2623  ("hExoDiff","cell #it{F}_{diff} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2624  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2625  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2626  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2627  fhExoDiff->SetXTitle("#it{E}_{cluster} (GeV)");
2628  fhExoDiff->SetYTitle("#it{F}_{diff}");
2629  outputContainer->Add(fhExoDiff);
2630 
2631  fhExoSame5 = new TH2F
2632  ("hExoSame5","cell #it{F}_{same-5} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2633  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2634  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2635  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2636  fhExoSame5->SetXTitle("#it{E}_{cluster} (GeV)");
2637  fhExoSame5->SetYTitle("#it{F}_{same-5}");
2638  outputContainer->Add(fhExoSame5);
2639 
2640  fhExoDiff5 = new TH2F
2641  ("hExoDiff5","cell #it{F}_{diff} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2642  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
2643  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2644  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2645  fhExoDiff5->SetXTitle("#it{E}_{cluster} (GeV)");
2646  fhExoDiff5->SetYTitle("#it{F}_{diff-5}");
2647  outputContainer->Add(fhExoDiff5);
2648 
2649  //
2650  fhFracEnDiffSame = new TH2F
2651  ("hFracEnDiffSame","cell #Sigma #it{E}_{diff}/#Sigma #it{E}_{same} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2652  nptbins,ptmin,ptmax, 200,0,2);
2653  fhFracEnDiffSame->SetXTitle("#it{E}_{cluster} (GeV)");
2654  fhFracEnDiffSame->SetYTitle("#Sigma #it{E}_{diff}/#Sigma #it{E}_{same}");
2655  outputContainer->Add(fhFracEnDiffSame);
2656 
2657  fhFracNCellDiffSame = new TH2F
2658  ("hFracNCellDiffSame","cell #it{n}_{diff}/#it{n}_{same} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2659  nptbins,ptmin,ptmax, 200,0,2);
2660  fhFracNCellDiffSame->SetXTitle("#it{E}_{cluster} (GeV)");
2661  fhFracNCellDiffSame->SetYTitle("#it{n}_{diff}/#it{n}_{same}");
2662  outputContainer->Add(fhFracNCellDiffSame);
2663 
2665  ("hFracEnNCellDiffSame","cell (#Sigma #it{E}_{diff}/#it{n}_{diff})/(#Sigma #it{E}_{same}/#it{n}_{same}) vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2666  nptbins,ptmin,ptmax, 200,0,2);
2667  fhFracEnNCellDiffSame->SetXTitle("#it{E}_{cluster} (GeV)");
2668  fhFracEnNCellDiffSame->SetYTitle("(#Sigma #it{E}_{diff}/#it{n}_{diff})/(#Sigma #it{E}_{same}/#it{n}_{same})");
2669  outputContainer->Add(fhFracEnNCellDiffSame);
2670 
2671  fhFracEnDiffSameW = new TH2F
2672  ("hFracEnDiffSameW","cell #Sigma #it{E}_{diff}^{#it{w}}/#Sigma #it{E}_{same}^{#it{w}} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2673  nptbins,ptmin,ptmax, 200,0,2);
2674  fhFracEnDiffSameW->SetXTitle("#it{E}_{cluster} (GeV)");
2675  fhFracEnDiffSameW->SetYTitle("#Sigma #it{E}_{diff}^{#it{w}}/#Sigma #it{E}_{same}^{#it{w}}");
2676  outputContainer->Add(fhFracEnDiffSameW);
2677 
2678  fhFracNCellDiffSameW = new TH2F
2679  ("hFracNCellDiffSameW","cell #it{n}_{diff}^{#it{w}}/#it{n}_{same}^{#it{w}} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2680  nptbins,ptmin,ptmax, 200,0,2);
2681  fhFracNCellDiffSameW->SetXTitle("#it{E}_{cluster} (GeV)");
2682  fhFracNCellDiffSameW->SetYTitle("#it{n}_{diff}^{#it{w}}/#it{n}_{same}^{#it{w}}");
2683  outputContainer->Add(fhFracNCellDiffSameW);
2684 
2686  ("hFracEnNCellDiffSameW","cell (#Sigma #it{E}_{diff}^{#it{w}}/#it{n}_{diff}^{#it{w}})/(#Sigma #it{E}_{same}^{#it{w}}/#it{n}_{same}^{#it{w}}) vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2687  nptbins,ptmin,ptmax, 200,0,2);
2688  fhFracEnNCellDiffSameW->SetXTitle("#it{E}_{cluster} (GeV)");
2689  fhFracEnNCellDiffSameW->SetYTitle("(#Sigma #it{E}_{diff}^{#it{w}}/#it{n}_{diff}^{#it{w}})/(#Sigma #it{E}_{same}^{#it{w}}/#it{n}_{same}^{#it{w}})");
2690  outputContainer->Add(fhFracEnNCellDiffSameW);
2691 
2692  fhFracEnDiffSame5 = new TH2F
2693  ("hFracEnDiffSame5","cell #Sigma #it{E}_{diff}^{next}/#Sigma #it{E}_{same}^{next} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2694  nptbins,ptmin,ptmax, 200,0,2);
2695  fhFracEnDiffSame5->SetXTitle("#it{E}_{cluster} (GeV)");
2696  fhFracEnDiffSame5->SetYTitle("#Sigma #it{E}_{diff}^{next}/#Sigma #it{E}_{same}^{next}");
2697  outputContainer->Add(fhFracEnDiffSame5);
2698 
2699  fhFracNCellDiffSame5 = new TH2F
2700  ("hFracNCellDiffSame5","cell #it{n}_{diff}^{next}/#it{n}_{same}^{next} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2701  nptbins,ptmin,ptmax, 200,0,2);
2702  fhFracNCellDiffSame5->SetXTitle("#it{E}_{cluster} (GeV)");
2703  fhFracNCellDiffSame5->SetYTitle("#it{n}_{diff}^{next}/#it{n}_{same}^{next}");
2704  outputContainer->Add(fhFracNCellDiffSame5);
2705 
2707  ("hFracEnNCellDiffSame5","cell (#Sigma #it{E}_{diff}^{next}/#it{n}_{diff}^{next})/(#Sigma #it{E}_{same}^{next}/#it{n}_{same}^{next}) vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
2708  nptbins,ptmin,ptmax, 200,0,2);
2709  fhFracEnNCellDiffSame5->SetXTitle("#it{E}_{cluster} (GeV)");
2710  fhFracEnNCellDiffSame5->SetYTitle("(#Sigma #it{E}_{diff}^{next}/#it{n}_{diff}^{next})/(#Sigma #it{E}_{same}^{next}/#it{n}_{same}^{next})");
2711  outputContainer->Add(fhFracEnNCellDiffSame5);
2712 
2713  //
2714  fhFracEnDiffSameExo = new TH3F
2715  ("hFracEnDiffSameExo","cell #Sigma #it{E}_{diff}/#Sigma #it{E}_{same} vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2716  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2717  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2718  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2719  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2720  fhFracEnDiffSameExo->SetXTitle("#it{E}_{cluster} (GeV)");
2721  fhFracEnDiffSameExo->SetYTitle("#Sigma #it{E}_{diff}/#Sigma #it{E}_{same}");
2722  fhFracEnDiffSameExo->SetZTitle("#it{F}_{+}");
2723  outputContainer->Add(fhFracEnDiffSameExo);
2724 
2726  ("hFracNCellDiffSameExo","cell #it{n}_{diff}/#it{n}_{same} vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2727  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2728  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2729  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2730  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2731  fhFracNCellDiffSameExo->SetXTitle("#it{E}_{cluster} (GeV)");
2732  fhFracNCellDiffSameExo->SetYTitle("#it{n}_{diff}/#it{n}_{same}");
2733  fhFracNCellDiffSameExo->SetZTitle("#it{F}_{+}");
2734  outputContainer->Add(fhFracNCellDiffSameExo);
2735 
2737  ("hFracEnNCellDiffSameExo","cell (#Sigma #it{E}_{diff}/#it{n}_{diff})/(#Sigma #it{E}_{same}/#it{n}_{same}) vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2738  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2739  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2740  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2741  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2742 
2743  fhFracEnNCellDiffSameExo->SetXTitle("#it{E}_{cluster} (GeV)");
2744  fhFracEnNCellDiffSameExo->SetYTitle("(#Sigma #it{E}_{diff}/#it{n}_{diff})/(#Sigma #it{E}_{same}/#it{n}_{same})");
2745  fhFracEnNCellDiffSameExo->SetZTitle("#it{F}_{+}");
2746  outputContainer->Add(fhFracEnNCellDiffSameExo);
2747 
2748  fhFracEnDiffSameWExo = new TH3F
2749  ("hFracEnDiffSameWExo","cell #Sigma #it{E}_{diff}^{#it{w}}/#Sigma #it{E}_{same}^{#it{w}} vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2750  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2751  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2752  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2753  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2754  fhFracEnDiffSameWExo->SetXTitle("#it{E}_{cluster} (GeV)");
2755  fhFracEnDiffSameWExo->SetYTitle("#Sigma #it{E}_{diff}^{#it{w}}/#Sigma #it{E}_{same}^{#it{w}}");
2756  fhFracEnDiffSameWExo->SetZTitle("#it{F}_{+}");
2757  outputContainer->Add(fhFracEnDiffSameWExo);
2758 
2760  ("hFracNCellDiffSameWExo","cell #it{n}_{diff}^{#it{w}}/#it{n}_{same}^{#it{w}} vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2761  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2762  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2763  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2764  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2765  fhFracNCellDiffSameWExo->SetXTitle("#it{E}_{cluster} (GeV)");
2766  fhFracNCellDiffSameWExo->SetYTitle("#it{n}_{diff}^{#it{w}}/#it{n}_{same}^{#it{w}}");
2767  fhFracNCellDiffSameWExo->SetZTitle("#it{F}_{+}");
2768  outputContainer->Add(fhFracNCellDiffSameWExo);
2769 
2771  ("hFracEnNCellDiffSameWExo","cell (#Sigma #it{E}_{diff}^{#it{w}}/#it{n}_{diff}^{#it{w}})/(#Sigma #it{E}_{same}^{#it{w}}/#it{n}_{same}^{#it{w}}) vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2772  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2773  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2774  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2775  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2776  fhFracEnNCellDiffSameWExo->SetXTitle("#it{E}_{cluster} (GeV)");
2777  fhFracEnNCellDiffSameWExo->SetYTitle("(#Sigma #it{E}_{diff}^{#it{w}}/#it{n}_{diff}^{#it{w}})/(#Sigma #it{E}_{same}^{#it{w}}/#it{n}_{same}^{#it{w}})");
2778  fhFracEnNCellDiffSameWExo->SetZTitle("#it{F}_{+}");
2779  outputContainer->Add(fhFracEnNCellDiffSameWExo);
2780 
2781  fhFracEnDiffSame5Exo = new TH3F
2782  ("hFracEnDiffSame5Exo","cell #Sigma #it{E}_{diff}^{next}/#Sigma #it{E}_{same}^{next} vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2783  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2784  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2785  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2786  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2787  fhFracEnDiffSame5Exo->SetXTitle("#it{E}_{cluster} (GeV)");
2788  fhFracEnDiffSame5Exo->SetYTitle("#Sigma #it{E}_{diff}^{next}/#Sigma #it{E}_{same}^{next}");
2789  fhFracEnDiffSame5Exo->SetZTitle("#it{F}_{+}");
2790  outputContainer->Add(fhFracEnDiffSame5Exo);
2791 
2793  ("hFracNCellDiffSame5Exo","cell #it{n}_{diff}^{next}/#it{n}_{same}^{next} vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2794  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2795  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2796  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2797  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2798  fhFracNCellDiffSame5Exo->SetXTitle("#it{E}_{cluster} (GeV)");
2799  fhFracNCellDiffSame5Exo->SetYTitle("#it{n}_{diff}^{next}/#it{n}_{same}^{next}");
2800  fhFracNCellDiffSame5Exo->SetZTitle("#it{F}_{+}");
2801  outputContainer->Add(fhFracNCellDiffSame5Exo);
2802 
2804  ("hFracEnNCellDiffSame5Exo","cell (#Sigma #it{E}_{diff}^{next}/#it{n}_{diff}^{next})/(#Sigma #it{E}_{same}^{next}/#it{n}_{same}^{next}) vs #it{E}_{cluster} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
2805  //nptbins,ptmin,ptmax, 101,0,1.01,nexobins,exomin,exomax);
2806  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2807  frac2BinsArray.GetSize() - 1, frac2BinsArray.GetArray(),
2808  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2809  fhFracEnNCellDiffSame5Exo->SetXTitle("#it{E}_{cluster} (GeV)");
2810  fhFracEnNCellDiffSame5Exo->SetYTitle("(#Sigma #it{E}_{diff}^{next}/#it{n}_{diff}^{next})/(#Sigma #it{E}_{same}^{next}/#it{n}_{same}^{next})");
2811  fhFracEnNCellDiffSame5Exo->SetZTitle("#it{F}_{+}");
2812  outputContainer->Add(fhFracEnNCellDiffSame5Exo);
2813 
2814  //
2815  fhFracEnDiffSameEnCut = new TH1F
2816  ("hFracEnDiffSameEnCut",
2817  Form("cell #Sigma #it{E}_{diff}/#Sigma #it{E}_{same}, #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2818  1000,0,10);
2819  fhFracEnDiffSameEnCut->SetXTitle("#Sigma #it{E}_{diff}/#Sigma #it{E}_{same}");
2820  outputContainer->Add(fhFracEnDiffSameEnCut);
2821 
2822  fhFracNCellDiffSameEnCut = new TH1F
2823  ("hFracNCellDiffSameEnCut",
2824  Form("cell #it{n}_{diff}/#it{n}_{same}, #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2825  1000,0,10);
2826  fhFracNCellDiffSameEnCut->SetXTitle("#it{n}_{diff}/#it{n}_{same}");
2827  outputContainer->Add(fhFracNCellDiffSameEnCut);
2828 
2829  fhFracEnNCellDiffSameEnCut = new TH1F
2830  ("hFracEnNCellDiffSameEncut",
2831  Form("cell (#Sigma #it{E}_{diff}/#it{n}_{diff})/(#Sigma #it{E}_{same}/#it{n}_{same}), #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2832  1000,0,10);
2833  fhFracEnNCellDiffSameEnCut->SetXTitle("(#Sigma #it{E}_{diff}/#it{n}_{diff})/(#Sigma #it{E}_{same}/#it{n}_{same})");
2834  outputContainer->Add(fhFracEnNCellDiffSameEnCut);
2835 
2836  fhFracEnDiffSameWEnCut = new TH1F
2837  ("hFracEnDiffSameWEnCut",
2838  Form("cell #Sigma #it{E}_{diff}^{#it{w}}/#Sigma #it{E}_{same}^{#it{w}} #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2839  1000,0,10);
2840  fhFracEnDiffSameWEnCut->SetXTitle("#Sigma #it{E}_{diff}^{#it{w}}/#Sigma #it{E}_{same}^{#it{w}}");
2841  outputContainer->Add(fhFracEnDiffSameWEnCut);
2842 
2843  fhFracNCellDiffSameWEnCut = new TH1F
2844  ("hFracNCellDiffSameWEnCut",
2845  Form("cell #it{n}_{diff}^{#it{w}}/#it{n}_{same}^{#it{w}} #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2846  1000,0,10);
2847  fhFracNCellDiffSameWEnCut->SetXTitle("#it{n}_{diff}^{#it{w}}/#it{n}_{same}^{#it{w}}");
2848  outputContainer->Add(fhFracNCellDiffSameWEnCut);
2849 
2850  fhFracEnNCellDiffSameWEnCut = new TH1F
2851  ("hFracEnNCellDiffSameWEnCut",
2852  Form("cell (#Sigma #it{E}_{diff}^{#it{w}}/#it{n}_{diff}^{#it{w}})/(#Sigma #it{E}_{same}^{#it{w}}/#it{n}_{same}^{#it{w}})#it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2853  1000,0,10);
2854  fhFracEnNCellDiffSameWEnCut->SetXTitle("(#Sigma #it{E}_{diff}^{#it{w}}/#it{n}_{diff}^{#it{w}})/(#Sigma #it{E}_{same}^{#it{w}}/#it{n}_{same}^{#it{w}})");
2855  outputContainer->Add(fhFracEnNCellDiffSameWEnCut);
2856 
2857  fhFracEnDiffSame5EnCut = new TH1F
2858  ("hFracEnDiffSame5EnCut",
2859  Form("cell #Sigma #it{E}_{diff}^{next}/#Sigma #it{E}_{same}^{next}, #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2860  1000,0,10);
2861  fhFracEnDiffSame5EnCut->SetXTitle("#Sigma #it{E}_{diff}^{next}/#Sigma #it{E}_{same}^{next}");
2862  outputContainer->Add(fhFracEnDiffSame5EnCut);
2863 
2864  fhFracNCellDiffSame5EnCut = new TH1F
2865  ("hFracNCellDiffSame5EnCut",
2866  Form("cell #it{n}_{diff}^{next}/#it{n}_{same}^{next}, #it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2867  1000,0,10);
2868  fhFracNCellDiffSame5EnCut->SetXTitle("#it{n}_{diff}^{next}/#it{n}_{same}^{next}");
2869  outputContainer->Add(fhFracNCellDiffSame5EnCut);
2870 
2871  fhFracEnNCellDiffSame5EnCut = new TH1F
2872  ("hFracEnNCellDiffSame5EnCut",
2873  Form("cell (#Sigma #it{E}_{diff}^{next}/#it{n}_{diff}^{next})/(#Sigma #it{E}_{same}^{next}/#it{n}_{same}^{next})#it{E}_{cluster} > %2.1f, #it{n}_{cluster}^{cell} > 1",fEMinForExo),
2874  1000,0,10);
2875  fhFracEnNCellDiffSame5EnCut->SetXTitle("(#Sigma #it{E}_{diff}^{next}/#it{n}_{diff}^{next})/(#Sigma #it{E}_{same}^{next}/#it{n}_{same}^{next})");
2876  outputContainer->Add(fhFracEnNCellDiffSame5EnCut);
2877 
2878  for(Int_t i = 0; i < fgkNEBins-1; i++)
2879  {
2880  fhEnNCellsSameDiffExo[i] = new TH3F
2881  (Form("hEnNCellsSameDiffExo_Ebin%d",i),
2882  Form("#Sigma #it{E}_{same}^{cells}/#it{n}_{cells}^{same} vs #Sigma #it{E}_{diff}^{cells}/#it{n}_{cells}^{diff}, %2.1f < #it{E} < %2.1f GeV",
2883  fEnergyBins[i],fEnergyBins[i+1]),
2884  //100, 0, 10, 100, 0, 10, nexobinsS,exominS,exomaxS);
2885  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
2886  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
2887  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2888  fhEnNCellsSameDiffExo[i]->SetXTitle("#Sigma #it{E}_{same}^{cells}/#it{n}_{cells}^{same} (GeV)");
2889  fhEnNCellsSameDiffExo[i]->SetYTitle("#Sigma #it{E}_{diff}^{cells}/#it{n}_{cells}^{diff} (GeV)");
2890  fhEnNCellsSameDiffExo[i]->SetZTitle("#it{F}_{+}");
2891  outputContainer->Add(fhEnNCellsSameDiffExo[i]);
2892  }
2893  }
2894 
2895  fhCellEnSameExo = new TH3F
2896  ("hCellEnSameExo","#it{E}_{cluster} vs #it{E}_{cell}^{same} vs #it{F}_{+}",
2897  //nptbins,ptmin,ptmax, 200,0,20, nexobins,exomin,exomax);
2898  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2899  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
2900  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2901  fhCellEnSameExo->SetXTitle("#it{E}_{cluster} (GeV)");
2902  fhCellEnSameExo->SetYTitle("#it{E}_{cell}^{same} (GeV)");
2903  fhCellEnSameExo->SetZTitle("#it{F}_{+}");
2904  outputContainer->Add(fhCellEnSameExo);
2905 
2906  fhCellEnDiffExo = new TH3F
2907  ("hCellEnDiffExo","#it{E}_{cluster} vs #it{E}_{cell}^{diff} vs #it{F}_{+}",
2908  //nptbins,ptmin,ptmax, 200,0,20, nexobins,exomin,exomax);
2909  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2910  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
2911  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
2912  fhCellEnDiffExo->SetXTitle("#it{E}_{cluster} (GeV)");
2913  fhCellEnDiffExo->SetYTitle("#it{E}_{cell}^{diff} (GeV)");
2914  fhCellEnDiffExo->SetZTitle("#it{F}_{+}");
2915  outputContainer->Add(fhCellEnDiffExo);
2916 
2917  for(Int_t icoldiff = 0; icoldiff < 4; icoldiff++)
2918  {
2919  for(Int_t irowdiff = 0; irowdiff < 4; irowdiff++)
2920  {
2921  if ( irowdiff == 0 && icoldiff == 0 ) continue;
2922 
2923  fhCellEnDiffColRowDiff[icoldiff][irowdiff] = new TH2F
2924  (Form("hCellEnDiff_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2925  Form("#it{E}_{cluster} vs #it{E}_{cell}^{diff}, #Delta col=%d - #Delta row=%d, #it{F}_{+}<%0.2f",icoldiff,irowdiff,fExoCut),
2926  //nptbins,ptmin,ptmax, 200,0,20, nexobins,exomin,exomax);
2927  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2928  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray());
2929  fhCellEnDiffColRowDiff[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2930  fhCellEnDiffColRowDiff[icoldiff][irowdiff] ->SetYTitle("#it{E}_{cell}^{diff} (GeV)");
2931  outputContainer->Add(fhCellEnDiffColRowDiff[icoldiff][irowdiff] );
2932 
2933  fhCellEnDiffColRowDiffExoCut[icoldiff][irowdiff] = new TH2F
2934  (Form("hCellEnDiffExo_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2935  Form("#it{E}_{cluster} vs #it{E}_{cell}^{diff}, #Delta col=%d - #Delta row=%d, #it{F}_{+}>%0.2f",icoldiff,irowdiff,fExoCut),
2936  //nptbins,ptmin,ptmax, 200,0,20, nexobins,exomin,exomax);
2937  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2938  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray());
2939  fhCellEnDiffColRowDiffExoCut[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2940  fhCellEnDiffColRowDiffExoCut[icoldiff][irowdiff] ->SetYTitle("#it{E}_{cell}^{diff} (GeV)");
2941  outputContainer->Add(fhCellEnDiffColRowDiffExoCut[icoldiff][irowdiff] );
2942 
2943  fhTimeDiffClusDiffCellColRowDiff[icoldiff][irowdiff] = new TH2F
2944  (Form("hTimeDiffClusDiffCell_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2945  Form("#it{E}_{cluster} vs #it{E}_{cell}^{diff}, #Delta col=%d - #Delta row=%d, #it{F}_{+}<%0.2f",icoldiff,irowdiff,fExoCut),
2946  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2947  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray());
2948  fhTimeDiffClusDiffCellColRowDiff[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2949  fhTimeDiffClusDiffCellColRowDiff[icoldiff][irowdiff] ->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
2950  outputContainer->Add(fhTimeDiffClusDiffCellColRowDiff[icoldiff][irowdiff] );
2951 
2952  fhTimeDiffClusDiffCellColRowDiffExoCut[icoldiff][irowdiff] = new TH2F
2953  (Form("hTimeDiffClusDiffCellExo_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2954  Form("#it{E}_{cluster} vs #Delta #it{t}^{max-sec}, #Delta col=%d - #Delta row=%d, #it{F}_{+}>%0.2f",icoldiff,irowdiff,fExoCut),
2955  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2956  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray());
2957  fhTimeDiffClusDiffCellColRowDiffExoCut[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2958  fhTimeDiffClusDiffCellColRowDiffExoCut[icoldiff][irowdiff] ->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
2959  outputContainer->Add(fhTimeDiffClusDiffCellColRowDiffExoCut[icoldiff][irowdiff] );
2960 
2961  if ( icoldiff > 1 ) continue;
2962 
2963  fhCellEnSameColRowDiff[icoldiff][irowdiff] = new TH2F
2964  (Form("hCellEnSame_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2965  Form("#it{E}_{cluster} vs #it{E}_{cell}^{same}, #Delta col=%d - #Delta row=%d, #it{F}_{+}<%0.2f",icoldiff,irowdiff,fExoCut),
2966  //nptbins,ptmin,ptmax, 200,0,20, nexobins,exomin,exomax);
2967  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2968  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray());
2969  fhCellEnSameColRowDiff[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2970  fhCellEnSameColRowDiff[icoldiff][irowdiff] ->SetYTitle("#it{E}_{cell}^{same} (GeV)");
2971  outputContainer->Add(fhCellEnSameColRowDiff[icoldiff][irowdiff] );
2972 
2973  fhCellEnSameColRowDiffExoCut[icoldiff][irowdiff] = new TH2F
2974  (Form("hCellEnSameExo_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2975  Form("#it{E}_{cluster} vs #it{E}_{cell}^{same}, #Delta col=%d - #Delta row=%d, #it{F}_{+}>%0.2f",icoldiff,irowdiff,fExoCut),
2976  //nptbins,ptmin,ptmax, 200,0,20, nexobins,exomin,exomax);
2977  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2978  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray());
2979  fhCellEnSameColRowDiffExoCut[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2980  fhCellEnSameColRowDiffExoCut[icoldiff][irowdiff] ->SetYTitle("#it{E}_{cell}^{same} (GeV)");
2981  outputContainer->Add(fhCellEnSameColRowDiffExoCut[icoldiff][irowdiff] );
2982 
2983  fhTimeDiffClusSameCellColRowDiff[icoldiff][irowdiff] = new TH2F
2984  (Form("hTimeDiffClusSameCell_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2985  Form("#it{E}_{cluster} vs #it{E}_{cell}^{diff}, #Delta col=%d - #Delta row=%d, #it{F}_{+}<%0.2f",icoldiff,irowdiff,fExoCut),
2986  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2987  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray());
2988  fhTimeDiffClusSameCellColRowDiff[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2989  fhTimeDiffClusSameCellColRowDiff[icoldiff][irowdiff] ->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
2990  outputContainer->Add(fhTimeDiffClusSameCellColRowDiff[icoldiff][irowdiff] );
2991 
2992  fhTimeDiffClusSameCellColRowDiffExoCut[icoldiff][irowdiff] = new TH2F
2993  (Form("hTimeDiffClusSameCellExo_DiffCol%d_DiffRow%d",icoldiff,irowdiff),
2994  Form("#it{E}_{cluster} vs #Delta #it{t}^{max-sec}, #Delta col=%d - #Delta row=%d, #it{F}_{+}>%0.2f",icoldiff,irowdiff,fExoCut),
2995  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
2996  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray());
2997  fhTimeDiffClusSameCellColRowDiffExoCut[icoldiff][irowdiff] ->SetXTitle("#it{E}_{cluster} (GeV)");
2998  fhTimeDiffClusSameCellColRowDiffExoCut[icoldiff][irowdiff] ->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
2999  outputContainer->Add(fhTimeDiffClusSameCellColRowDiffExoCut[icoldiff][irowdiff] );
3000  }
3001  }
3002 
3003  if ( fFillOpenTimeHisto )
3004  {
3006  ("hCellEnNCellWOpenTime","#it{E}_{cluster} vs #it{E}_{cell} vs #it{n}_{cell}^{#it{w}}, no time cut",
3007  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3008  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3009  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
3010  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3011  fhCellEnNCellWOpenTime->SetXTitle("#it{E}_{cluster} (GeV)");
3012  fhCellEnNCellWOpenTime->SetYTitle("#it{E}_{cell} (GeV)");
3013  fhCellEnNCellWOpenTime->SetZTitle("#it{n}_{cell}^{#it{w}}");
3014  outputContainer->Add(fhCellEnNCellWOpenTime);
3015 
3017  ("hCellEnNCellWEMaxOpenTime","#it{E}_{cell}^{max} vs #it{E}_{cell} vs #it{n}_{cell}^{#it{w}}, no time cut",
3018  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3019  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3020  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
3021  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3022  fhCellEnNCellWEMaxOpenTime->SetXTitle("#it{E}_{cell}^{max} (GeV)");
3023  fhCellEnNCellWEMaxOpenTime->SetYTitle("#it{E}_{cell} (GeV)");
3024  fhCellEnNCellWEMaxOpenTime->SetZTitle("#it{n}_{cell}^{#it{w}}");
3025  outputContainer->Add(fhCellEnNCellWEMaxOpenTime);
3026  }
3027 
3028  fhCellEnNCellW = new TH3F
3029  ("hCellEnNCellW","#it{E}_{cluster} vs #it{E}_{cell} vs #it{n}_{cell}^{#it{w}}",
3030  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3031  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3032  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
3033  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3034  fhCellEnNCellW->SetXTitle("#it{E}_{cluster} (GeV)");
3035  fhCellEnNCellW->SetYTitle("#it{E}_{cell} (GeV)");
3036  fhCellEnNCellW->SetZTitle("#it{n}_{cell}^{#it{w}}");
3037  outputContainer->Add(fhCellEnNCellW);
3038 
3039  fhCellEnNCellWEMax = new TH3F
3040  ("hCellEnNCellWEMax","#it{E}_{cell}^{max} vs #it{E}_{cell} vs #it{n}_{cell}^{#it{w}}",
3041  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3042  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3043  e2BinsArray.GetSize() - 1, e2BinsArray.GetArray(),
3044  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3045  fhCellEnNCellWEMax->SetXTitle("#it{E}_{cell}^{max} (GeV)");
3046  fhCellEnNCellWEMax->SetYTitle("#it{E}_{cell} (GeV)");
3047  fhCellEnNCellWEMax->SetZTitle("#it{n}_{cell}^{#it{w}}");
3048  outputContainer->Add(fhCellEnNCellWEMax);
3049 
3050  if ( fFillOpenTimeHisto )
3051  {
3053  ("hCellTimeDiffNCellWOpenTime","#it{E}_{cluster} vs #Delta #it{t}^{max-sec} vs #it{n}_{cell}^{#it{w}}, no time cut",
3054  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3055  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3056  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3057  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3058  fhCellTimeDiffNCellWOpenTime->SetXTitle("#it{E}_{cluster} (GeV)");
3059  fhCellTimeDiffNCellWOpenTime->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
3060  fhCellTimeDiffNCellWOpenTime->SetZTitle("#it{n}_{cell}^{#it{w}}");
3061  outputContainer->Add(fhCellTimeDiffNCellWOpenTime);
3062 
3064  ("hCellTimeDiffNCellWEMaxOpenTime","#it{E}_{cell}^{max} vs #Delta #it{t}^{max-sec} vs #it{n}_{cell}^{#it{w}}, no time cut",
3065  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3066  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3067  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3068  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3069  fhCellTimeDiffNCellWEMaxOpenTime->SetXTitle("#it{E}_{cell}^{max} (GeV)");
3070  fhCellTimeDiffNCellWEMaxOpenTime->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
3071  fhCellTimeDiffNCellWEMaxOpenTime->SetZTitle("#it{n}_{cell}^{#it{w}}");
3072  outputContainer->Add(fhCellTimeDiffNCellWEMaxOpenTime);
3073  }
3074 
3075  fhCellTimeDiffNCellW = new TH3F
3076  ("hCellTimeDiffNCellW","#it{E}_{cluster} vs #Delta #it{t}^{max-sec} vs #it{n}_{cell}^{#it{w}}",
3077  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3078  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3079  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3080  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3081  fhCellTimeDiffNCellW->SetXTitle("#it{E}_{cluster} (GeV)");
3082  fhCellTimeDiffNCellW->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
3083  fhCellTimeDiffNCellW->SetZTitle("#it{n}_{cell}^{#it{w}}");
3084  outputContainer->Add(fhCellTimeDiffNCellW);
3085 
3087  ("hCellTimeDiffNCellWEMax","#it{E}_{cell}^{max} vs #Delta #it{t}^{max-sec} vs #it{n}_{cell}^{#it{w}}",
3088  //nptbins,ptmin,ptmax, 200,0,20, nceclbins,nceclmin,nceclmax);
3089  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3090  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3091  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3092  fhCellTimeDiffNCellWEMax->SetXTitle("#it{E}_{cell}^{max} (GeV)");
3093  fhCellTimeDiffNCellWEMax->SetYTitle("#Delta #it{t}^{max-sec} (ns)");
3094  fhCellTimeDiffNCellWEMax->SetZTitle("#it{n}_{cell}^{#it{w}}");
3095  outputContainer->Add(fhCellTimeDiffNCellWEMax);
3096 
3097  fhCellMaxClusterEn = new TH2F
3098  ("hCellMaxClusterEn","#it{E}_{cluster}^{org} vs #it{E}_{cell}^{max}, #it{n}_{cluster}^{cell} > 1",
3099  //nptbins,ptmin,ptmax, nptbins,ptmin,ptmax);
3100  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3101  eBinsArray.GetSize() - 1, eBinsArray.GetArray());
3102  fhCellMaxClusterEn->SetXTitle("#it{E}_{cluster}^{org} (GeV)");
3103  fhCellMaxClusterEn->SetYTitle("#it{E}_{cell}^{max} (GeV)");
3104  outputContainer->Add(fhCellMaxClusterEn);
3105 
3107  ("hCellMaxClusterEnRatio","#it{E}_{cluster} vs #it{E}_{cell}^{max}/#it{E}_{cluster}^{org}, #it{n}_{cluster}^{cell} > 1",
3108  //nptbins,ptmin,ptmax, 202,0,1.01);
3109  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3110  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray());
3111  fhCellMaxClusterEnRatio->SetXTitle("#it{E}_{cluster} (GeV)");
3112  fhCellMaxClusterEnRatio->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}^{org}");
3113  outputContainer->Add(fhCellMaxClusterEnRatio);
3114 
3115  if ( fFillOpenTimeHisto )
3116  {
3118  ("hCellMaxClusterEnOpenTime","#it{E}_{cluster}^{org} vs #it{E}_{cell}^{max}, #it{n}_{cluster}^{cell} > 1, no time cut",
3119  //nptbins,ptmin,ptmax, nptbins,ptmin,ptmax);
3120  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3121  eBinsArray.GetSize() - 1, eBinsArray.GetArray());
3122  fhCellMaxClusterEnOpenTime->SetXTitle("#it{E}_{cluster}^{org} (GeV)");
3123  fhCellMaxClusterEnOpenTime->SetYTitle("#it{E}_{cell}^{max} (GeV)");
3124  outputContainer->Add(fhCellMaxClusterEnOpenTime);
3125 
3127  ("hCellMaxClusterEnRatioOpenTime","#it{E}_{cluster} vs #it{E}_{cell}^{max}/#it{E}_{cluster}^{org}, #it{n}_{cluster}^{cell} > 1, no time cut",
3128  //nptbins,ptmin,ptmax, 202,0,1.01);
3129  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3130  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray());
3131  fhCellMaxClusterEnRatioOpenTime->SetXTitle("#it{E}_{cluster} (GeV)");
3132  fhCellMaxClusterEnRatioOpenTime->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}^{org}");
3133  outputContainer->Add(fhCellMaxClusterEnRatioOpenTime);
3134 
3136  ("hCellMaxClusterEnRatioNCellWOpenTime","#it{E}_{cluster}vs #it{E}_{cell}^{max}/#it{E}_{cluster}^{org} vs #it{n}_{cell}^{#it{w}}, #it{n}_{cluster}^{cell} > 1, no time cut",
3137  //nptbins,ptmin,ptmax, 101,0,1.01, nceclbins,nceclmin,nceclmax);
3138  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3139  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray(),
3140  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3141  fhCellMaxClusterEnRatioNCellWOpenTime->SetXTitle("#it{E}_{cluster} (GeV)");
3142  fhCellMaxClusterEnRatioNCellWOpenTime->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}^{org}");
3143  fhCellMaxClusterEnRatioNCellWOpenTime->SetZTitle("#it{n}_{cell}^{#it{w}}");
3144  outputContainer->Add(fhCellMaxClusterEnRatioNCellWOpenTime);
3145  }
3146 
3148  ("hCellMaxClusterEnRatioNCellW","#it{E}_{cluster} vs #it{E}_{cell}^{max}/#it{E}_{cluster}^{org} vs #it{n}_{cell}^{#it{w}}, #it{n}_{cluster}^{cell} > 1",
3149  //nptbins,ptmin,ptmax, 101,0,1.01, nceclbins,nceclmin,nceclmax);
3150  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3151  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray(),
3152  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3153  fhCellMaxClusterEnRatioNCellW->SetXTitle("#it{E}_{cluster} (GeV)");
3154  fhCellMaxClusterEnRatioNCellW->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}^{org}");
3155  fhCellMaxClusterEnRatioNCellW->SetZTitle("#it{n}_{cell}^{#it{w}}");
3156  outputContainer->Add(fhCellMaxClusterEnRatioNCellW);
3157 
3159  ("hCellMaxClusterEnRatioExo","#it{E}_{cluster} vs #it{E}_{cell}^{max}/#it{E}_{cluster}^{org} vs #it{F}_{+}, #it{n}_{cluster}^{cell} > 1",
3160  //nptbins,ptmin,ptmax, 101,0,1.01, nexobins,exomin,exomax);
3161  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3162  fracBinsArray.GetSize() - 1, fracBinsArray.GetArray(),
3163  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3164  fhCellMaxClusterEnRatioExo->SetXTitle("#it{E}_{cluster} (GeV)");
3165  fhCellMaxClusterEnRatioExo->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}^{org}");
3166  fhCellMaxClusterEnRatioExo->SetZTitle("#it{F}_{+}");
3167  outputContainer->Add(fhCellMaxClusterEnRatioExo);
3168 
3169  // Cluster acceptance
3170  //
3171  fhEtaPhiGridExoEnCut = new TH3F
3172  ("hEtaPhiGridExoEnCut",
3173  Form("colum (#eta) vs row (#varphi) vs #it{F}_{+}, #it{E}_{cluster}> %2.1f, #it{n}_{cells}>1",fEMinForExo),
3174  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nexobinsS,exominS,exomaxS);
3175  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3176  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3177  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3178  fhEtaPhiGridExoEnCut->SetXTitle("column-#eta");
3179  fhEtaPhiGridExoEnCut->SetYTitle("row-#varphi (rad)");
3180  fhEtaPhiGridExoEnCut->SetZTitle("#it{F}_{+}");
3181  outputContainer->Add(fhEtaPhiGridExoEnCut);
3182 
3183  fhEtaPhiGridEnExoCut = new TH3F
3184  ("hEtaPhiGridEnExoCut", Form("colum (#eta) vs row (#varphi) vs #it{E}, #it{F}_{+} > %2.2f",fExoCut),
3185  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nptbins/2,ptmin,ptmax);
3186  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3187  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3188  eBinsArray.GetSize() - 1, eBinsArray.GetArray());
3189  fhEtaPhiGridEnExoCut->SetXTitle("column-#eta");
3190  fhEtaPhiGridEnExoCut->SetYTitle("row-#varphi (rad)");
3191  fhEtaPhiGridEnExoCut->SetZTitle("#it{E} (GeV)");
3192  outputContainer->Add(fhEtaPhiGridEnExoCut);
3193 
3195  ("hEtaPhiGridEnHighNCells", Form("colum (#eta) vs row (#varphi) vs #it{E}, #it{n}_{cells}^{#it{w}} > %d",fNCellHighCut),
3196  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nptbins/2,ptmin,ptmax);
3197  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3198  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3199  eBinsArray.GetSize() - 1, eBinsArray.GetArray());
3200  fhEtaPhiGridEnHighNCells->SetXTitle("column-#eta");
3201  fhEtaPhiGridEnHighNCells->SetYTitle("row-#varphi (rad)");
3202  fhEtaPhiGridEnHighNCells->SetZTitle("#it{E} (GeV)");
3203  outputContainer->Add(fhEtaPhiGridEnHighNCells);
3204 
3206  ("hEtaPhiGridNCellEnCut",
3207  Form("colum (#eta) vs row (#varphi) vs #it{n}_{cells}, #it{E}_{cluster}> %2.1f, #it{n}_{cells}>1",fEMinForExo),
3208  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nceclbins,nceclmin,nceclmax);
3209  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3210  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3211  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3212  fhEtaPhiGridNCellEnCut->SetXTitle("column-#eta");
3213  fhEtaPhiGridNCellEnCut->SetYTitle("row-#varphi (rad)");
3214  fhEtaPhiGridNCellEnCut->SetZTitle("#it{n}_{cells}");
3215  outputContainer->Add(fhEtaPhiGridNCellEnCut);
3216 
3217  if ( fFill1CellHisto )
3218  {
3219  fhEtaPhiGridEn1Cell = new TH3F
3220  ("hEtaPhiGridEn1Cell","colum (#eta) vs row (#varphi) vs #it{E}, #it{n}_{cells}=1",
3221  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nptbins,ptmin,ptmax);
3222  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3223  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3224  eBinsArray.GetSize() - 1, eBinsArray.GetArray());
3225  fhEtaPhiGridEn1Cell->SetXTitle("column-#eta");
3226  fhEtaPhiGridEn1Cell->SetYTitle("row-#varphi (rad)");
3227  fhEtaPhiGridEn1Cell->SetZTitle("#it{E} (GeV)");
3228  outputContainer->Add(fhEtaPhiGridEn1Cell);
3229  }
3230 
3231  // Timing and energy
3232  fhTimeEnergyExo = new TH3F
3233  ("hTimeEnergyExo","#it{E}_{cluster} vs #it{t}_{cluster} vs #it{F}_{+}, #it{n}_{cells}>1",
3234  //nptbins,ptmin,ptmax, ntimebins,timemin,timemax, nexobinsS,exominS,exomaxS);
3235  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3236  tBinsArray.GetSize() - 1, tBinsArray.GetArray(),
3237  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3238  fhTimeEnergyExo->SetXTitle("#it{E} (GeV)");
3239  fhTimeEnergyExo->SetYTitle("#it{t}_{cluster} (ns)");
3240  fhTimeEnergyExo->SetZTitle("#it{F}_{+}");
3241  outputContainer->Add(fhTimeEnergyExo);
3242 
3243  if ( fFill1CellHisto )
3244  {
3245  fhTimeEnergy1Cell = new TH2F
3246  ("hTimeEnergy1Cell","#it{E}_{cluster} vs #it{t}_{cluster} vs #it{F}_{+}, #it{n}_{cells}=1",
3247  //nptbins,ptmin,ptmax, ntimebins,timemin,timemax);
3248  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3249  tBinsArray.GetSize() - 1, tBinsArray.GetArray());
3250  fhTimeEnergy1Cell->SetXTitle("#it{E} (GeV)");
3251  fhTimeEnergy1Cell->SetYTitle("#it{t}_{cluster} (ns)");
3252  outputContainer->Add(fhTimeEnergy1Cell);
3253  }
3254 
3256  ("hTimeDiffClusCellExo","#it{E}_{cluster} vs #it{t}_{cell max}-#it{t}_{cell i} vs #it{F}_{+}, #it{n}_{cells}>1",
3257  //nptbins,ptmin,ptmax, tdbins,tdmin,tdmax, nexobinsS,exominS,exomaxS);
3258  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3259  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3260  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3261  fhTimeDiffClusCellExo->SetXTitle("#it{E}_{cluster} (GeV)");
3262  fhTimeDiffClusCellExo->SetYTitle("#Delta #it{t}_{cell max-i} (ns)");
3263  fhTimeDiffClusCellExo->SetZTitle("#it{F}_{+}");
3264  outputContainer->Add(fhTimeDiffClusCellExo);
3265 
3267  ("hTimeDiffClusCellDiffTCardExo","#it{E}_{cluster} vs #it{t}_{cell max}-#it{t}_{cell i} vs #it{F}_{+}, #it{n}_{cells}>1, diff T-Card",
3268  //nptbins,ptmin,ptmax, tdbins,tdmin,tdmax, nexobinsS,exominS,exomaxS);
3269  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3270  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3271  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3272  fhTimeDiffClusCellDiffTCardExo->SetXTitle("#it{E}_{cluster} (GeV)");
3273  fhTimeDiffClusCellDiffTCardExo->SetYTitle("#Delta #it{t}_{cell max-i} (ns)");
3274  fhTimeDiffClusCellDiffTCardExo->SetZTitle("#it{F}_{+}");
3275  outputContainer->Add(fhTimeDiffClusCellDiffTCardExo);
3276 
3278  ("hTimeDiffClusCellSameTCardExo","#it{E}_{cluster} vs #it{t}_{cell max}-#it{t}_{cell i} vs #it{F}_{+}, #it{n}_{cells}>1, same T-Card",
3279  //nptbins,ptmin,ptmax, tdbins,tdmin,tdmax, nexobinsS,exominS,exomaxS);
3280  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3281  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3282  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3283  fhTimeDiffClusCellSameTCardExo->SetXTitle("#it{E}_{cluster} (GeV)");
3284  fhTimeDiffClusCellSameTCardExo->SetYTitle("#Delta #it{t}_{cell max-i} (ns)");
3285  fhTimeDiffClusCellSameTCardExo->SetZTitle("#it{F}_{+}");
3286  outputContainer->Add(fhTimeDiffClusCellSameTCardExo);
3287 
3289  ("hTimeDiffWClusCellExo","#it{E}_{cluster} vs #it{t}_{cell max}-#it{t}_{cell i} for cells with w>0 vs #it{F}_{+}, #it{n}_{cells}>1",
3290  //nptbins,ptmin,ptmax, tdbins,tdmin,tdmax, nexobinsS,exominS,exomaxS);
3291  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3292  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3293  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3294  fhTimeDiffWClusCellExo->SetXTitle("#it{E}_{cluster} (GeV)");
3295  fhTimeDiffWClusCellExo->SetYTitle("#Delta #it{t}_{cell max-i} (ns)");
3296  fhTimeDiffWClusCellExo->SetZTitle("#it{F}_{+}");
3297  outputContainer->Add(fhTimeDiffWClusCellExo);
3298 
3300  ("hTimeDiffAmpClusCellExo",
3301  Form("#it{E}_{cell i} vs #it{t}_{cell max}-#it{t}_{cell i} vs #it{F}_{+}, #it{n}_{cells}>1, #it{E}_{cluster}>%2.1f GeV",fEMinForExo),
3302  //nptbins,ptmin,ptmax, tdbins,tdmin,tdmax, nexobinsS,exominS,exomaxS);
3303  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3304  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3305  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3306  fhTimeDiffAmpClusCellExo->SetXTitle("#it{E}_{cell i} (GeV)");
3307  fhTimeDiffAmpClusCellExo->SetYTitle("#Delta #it{t}_{cell max-i} (ns)");
3308  fhTimeDiffAmpClusCellExo->SetZTitle("#it{F}_{+}");
3309  outputContainer->Add(fhTimeDiffAmpClusCellExo);
3310 
3311  fhTimeEnergyM02 = new TH3F
3312  ("hTimeEnergyM02","#it{E}_{cluster} vs #it{t}_{cluster} vs #sigma^{2}_{long}, #it{n}_{cells}>1",
3313  //nptbins,ptmin,ptmax, ntimebins,timemin,timemax, 100,0,0.5);
3314  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3315  tBinsArray.GetSize() - 1, tBinsArray.GetArray(),
3316  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray());
3317  fhTimeEnergyM02->SetXTitle("#it{E} (GeV)");
3318  fhTimeEnergyM02->SetYTitle("#it{t}_{cluster} (ns)");
3319  fhTimeEnergyM02->SetZTitle("#sigma^{2}_{long}");
3320  outputContainer->Add(fhTimeEnergyM02);
3321 
3323  ("hTimeDiffClusCellM02","#it{E}_{cluster} vs #it{t}_{cell max}-#it{t}_{cell i} vs #sigma^{2}_{long}, #it{n}_{cells}>1",
3324  //nptbins,ptmin,ptmax, tdbins,tdmin,tdmax, 100,0,0.5);
3325  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3326  tdBinsArray.GetSize() - 1, tdBinsArray.GetArray(),
3327  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray());
3328  fhTimeDiffClusCellM02->SetXTitle("#it{E}_{cluster} (GeV)");
3329  fhTimeDiffClusCellM02->SetYTitle("#Delta #it{t}_{cell max-i} (ns)");
3330  fhTimeDiffClusCellM02->SetZTitle("#sigma^{2}_{long}");
3331  outputContainer->Add(fhTimeDiffClusCellM02);
3332 
3333  fhTimeEnergyNCells = new TH3F
3334  ("hTimeEnergyNCells","#it{E}_{cluster} vs #it{t}_{cluster} vs #it{n}_{cells}",
3335  //nptbins,ptmin,ptmax, ntimebins,timemin,timemax, nceclbins,nceclmin,nceclmax);
3336  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3337  tBinsArray.GetSize() - 1, tBinsArray.GetArray(),
3338  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3339  fhTimeEnergyNCells->SetXTitle("#it{E} (GeV)");
3340  fhTimeEnergyNCells->SetYTitle("#it{t}_{cluster} (ns)");
3341  fhTimeEnergyNCells->SetZTitle("#it{n}_{cells}");
3342  outputContainer->Add(fhTimeEnergyNCells);
3343 
3344  fhTimeEnergyNCellsW = new TH3F
3345  ("hTimeEnergyNCellsW","#it{E}_{cluster} vs #it{t}_{cluster} vs #it{n}_{cells} with #it{w} > 0",
3346  //nptbins,ptmin,ptmax, ntimebins,timemin,timemax, nceclbins,nceclmin,nceclmax);
3347  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3348  tBinsArray.GetSize() - 1, tBinsArray.GetArray(),
3349  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3350  fhTimeEnergyNCellsW->SetXTitle("#it{E} (GeV)");
3351  fhTimeEnergyNCellsW->SetYTitle("#it{t}_{cluster} (ns)");
3352  fhTimeEnergyNCellsW->SetZTitle("#it{n}_{cells}^{#it{w}}");
3353  outputContainer->Add(fhTimeEnergyNCellsW);
3354 
3355  fhTimeNCellCut = new TH1F
3356  ("hTimeNCellCut",Form("#it{t}_{cluster} for #it{n}_{cells}^{#it{w}} > %d",fNCellHighCut),
3357  4000,-1000,1000);
3358  fhTimeNCellCut->SetXTitle("#it{t}_{cluster} (ns)");
3359  outputContainer->Add(fhTimeNCellCut);
3360 
3361  // Shower shape
3362  //
3363  fhM02EnergyExo = new TH3F
3364  ("hM02EnergyExo","#sigma^{2}_{long} vs #it{E}_{cluster} vs #it{F}_{+}",
3365  //nptbins,ptmin,ptmax,ssbins,ssmin,ssmax, nexobinsS,exominS,exomaxS);
3366  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3367  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3368  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3369  fhM02EnergyExo->SetXTitle("#it{E}_{cluster} (GeV)");
3370  fhM02EnergyExo->SetYTitle("#sigma^{2}_{long}");
3371  fhM02EnergyExo->SetZTitle("#it{F}_{+}");
3372  outputContainer->Add(fhM02EnergyExo);
3373 
3374  if ( fFillExo50ns )
3375  {
3376  fhM02EnergyExo50ns = new TH3F
3377  ("hM02EnergyExo50ns","#sigma^{2}_{long} vs #it{E}_{cluster} vs #it{F}_{+}",
3378  //nptbins,ptmin,ptmax,ssbins,ssmin,ssmax, nexobinsS,exominS,exomaxS);
3379  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3380  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3381  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3382  fhM02EnergyExo50ns->SetXTitle("#it{E}_{cluster} (GeV)");
3383  fhM02EnergyExo50ns->SetYTitle("#sigma^{2}_{long}");
3384  fhM02EnergyExo50ns->SetZTitle("#it{F}_{+}");
3385  outputContainer->Add(fhM02EnergyExo50ns);
3386  }
3387 
3389  ("hM20EnergyExoM02MinCut","#sigma^{2}_{short} vs #it{E}_{cluster} vs #it{F}_{+}, #sigma^{2}_{long} > 0.1",
3390  //nptbins,ptmin,ptmax,ssbins,ssmin,ssmax/2, nexobinsS,exominS,exomaxS);
3391  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3392  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3393  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3394  fhM20EnergyExoM02MinCut->SetXTitle("#it{E}_{cluster} (GeV)");
3395  fhM20EnergyExoM02MinCut->SetYTitle("#sigma^{2}_{short}");
3396  fhM20EnergyExoM02MinCut->SetZTitle("#it{F}_{+}");
3397  outputContainer->Add(fhM20EnergyExoM02MinCut);
3398 
3399  for(Int_t i = 0; i < fgkNEBins-1; i++)
3400  {
3401  fhM02ExoNCells[i] = new TH3F
3402  (Form("hM02ExoNCells_Ebin%d",i),
3403  Form("#sigma^{2}_{long} vs #it{F}_{+} vs #it{n}_{cells}, %2.1f < #it{E} < %2.1f GeV",fEnergyBins[i],fEnergyBins[i+1]),
3404  //100,0,0.5,nexobinsS,exominS,exomaxS,nceclbins,nceclmin,nceclmax);
3405  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3406  fBinsArray.GetSize() - 1, fBinsArray.GetArray(),
3407  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3408  fhM02ExoNCells[i]->SetXTitle("#sigma^{2}_{long}");
3409  fhM02ExoNCells[i]->SetYTitle("#it{F}_{+}");
3410  fhM02ExoNCells[i]->SetZTitle("#it{n}_{cells}");
3411  outputContainer->Add(fhM02ExoNCells[i]);
3412 
3413  if ( fFillExo50ns )
3414  {
3415  fhM02Exo50nsNCells[i] = new TH3F
3416  (Form("hM02Exo50nsNCells_Ebin%d",i),
3417  Form("#sigma^{2}_{long} vs #it{F}_{+} vs #it{n}_{cells}, %2.1f < #it{E} < %2.1f GeV",fEnergyBins[i],fEnergyBins[i+1]),
3418  //100,0,0.5,nexobinsS,exominS,exomaxS,nceclbins,nceclmin,nceclmax);
3419  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3420  fBinsArray.GetSize() - 1, fBinsArray.GetArray(),
3421  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3422  fhM02Exo50nsNCells[i]->SetXTitle("#sigma^{2}_{long}");
3423  fhM02Exo50nsNCells[i]->SetYTitle("#it{F}_{+}");
3424  fhM02Exo50nsNCells[i]->SetZTitle("#it{n}_{cells}");
3425  outputContainer->Add(fhM02Exo50nsNCells[i]);
3426  }
3427  }
3428 
3430  {
3431  if ( fFillPerSMHisto )
3432  {
3433  for(Int_t i = 0; i < fgkNEBins-1; i++)
3434  {
3436  (Form("hClusterColRowPerSMHighNCell_Ebin%d",i),
3437  Form("column vs row vs SM, %2.1f < #it{E} < %2.1f GeV, #it{n}_{cells}^{#it{w}} > %d",
3439  //17,-8.5,8.5,17,-8.5,8.5,totalSM,fFirstModule-0.5,fLastModule+0.5);
3440  sizeBinsArray.GetSize() - 1, sizeBinsArray.GetArray(),
3441  sizeBinsArray.GetSize() - 1, sizeBinsArray.GetArray(),
3442  smBinsArray.GetSize() - 1, smBinsArray.GetArray());
3443  fhClusterColRowPerSMHighNCell[i]->SetXTitle("column");
3444  fhClusterColRowPerSMHighNCell[i]->SetYTitle("row");
3445  fhClusterColRowPerSMHighNCell[i]->SetZTitle("SM");
3446  outputContainer->Add(fhClusterColRowPerSMHighNCell[i]);
3447  }
3448  }
3449 
3450  for(Int_t i = 0; i < fgkNEBins-1; i++)
3451  {
3452  for(Int_t j = 0; j < 2; j++)
3453  {
3454  fhClusterColRowExo[j][i] = new TH3F
3455  (Form("hClusterColRowExo_Ebin%d_Col%d",i,j),
3456  Form("column vs row vs #it{F}_{+}, %2.1f < #it{E} < %2.1f GeV, column %d",fEnergyBins[i],fEnergyBins[i+1],j),
3457  //17,-8.5,8.5,17,-8.5,8.5,nexobinsS,exominS,exomaxS);
3458  sizeBinsArray.GetSize() - 1, sizeBinsArray.GetArray(),
3459  sizeBinsArray.GetSize() - 1, sizeBinsArray.GetArray(),
3460  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3461  fhClusterColRowExo[j][i]->SetXTitle("column");
3462  fhClusterColRowExo[j][i]->SetYTitle("row");
3463  fhClusterColRowExo[j][i]->SetZTitle("#it{F}_{+}");
3464  outputContainer->Add(fhClusterColRowExo[j][i]);
3465 
3466  // fhClusterColRow[j][i] = new TH2F
3467  // (Form("hClusterColRow_Ebin%d_Col%d",i,j),
3468  // Form("column vs row, #it{F}_{+}<%2.2f, %2.1f < #it{E} < %2.1f GeV, column %d",fExoCut, fEnergyBins[i],fEnergyBins[i+1],j),
3469  // 17,-8.5,8.5,17,-8.5,8.5);
3470  // fhClusterColRow[j][i]->SetXTitle("column");
3471  // fhClusterColRow[j][i]->SetYTitle("row");
3472  // outputContainer->Add(fhClusterColRow[j][i]);
3473 
3474  // fhClusterColRowExoW [j][i] = new TH3F
3475  // (Form("hClusterColRowExoW_Ebin%d_Col%d",i,j),
3476  // Form("column vs row vs #it{F}_{+}, %2.1f < #it{E} < %2.1f GeV, #it{w} > 0, column %d",fEnergyBins[i],fEnergyBins[i+1],j),
3477  // 17,-8.5,8.5,17,-8.5,8.5,nexobinsS,exominS,exomaxS);
3478  // fhClusterColRowExoW [j][i]->SetXTitle("column");
3479  // fhClusterColRowExoW [j][i]->SetYTitle("row");
3480  // fhClusterColRowExoW [j][i]->SetZTitle("#it{F}_{+}");
3481  // outputContainer->Add(fhClusterColRowExoW [j][i]);
3482  }
3483  }
3484  }
3485 
3486  if ( fFillExoEnMinCut )
3487  {
3489  ("hExoticityECellMinCut","cell #it{F}_{+} for different #it{E}_{cell}^{min} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
3490  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3491  fBinsArray.GetSize() - 1, fBinsArray.GetArray(),
3492  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3493  //nptbins,ptmin,ptmax, nexobins,exomin,exomax, 40,0.075,2.075);
3494  fhExoticityECellMinCut->SetXTitle("#it{E}_{cluster} (GeV)");
3495  fhExoticityECellMinCut->SetYTitle("#it{F}_{+}");
3496  fhExoticityECellMinCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3497  outputContainer->Add(fhExoticityECellMinCut);
3498 
3499  fhExoticityWEClus = new TH2F
3500  ("hExoticityWEClus","cell #it{F}_{+}^{#it{w}} vs #it{E}_{cluster}, #it{n}_{cluster}^{cell} > 1",
3501  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
3502  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3503  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3504  fhExoticityWEClus->SetXTitle("#it{E}_{cluster} (GeV)");
3505  fhExoticityWEClus->SetYTitle("#it{F}_{+}^{#it{w}}");
3506  outputContainer->Add(fhExoticityWEClus);
3507 
3509  ("hNCellsPerClusterExoW","# cells per cluster vs #it{E}_{cluster} vs #it{F}_{+}^{#it{w}}",
3510  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3511  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
3512  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3513  //nptbins/2,ptmin,ptmax, nceclbins,nceclmin,nceclmax,nexobinsS,exominS,exomaxS);
3514  fhNCellsPerClusterExoW->SetXTitle("#it{E}_{cluster} (GeV)");
3515  fhNCellsPerClusterExoW->SetYTitle("#it{n}_{cells}");
3516  fhNCellsPerClusterExoW->SetZTitle("#it{F}_{+}^{#it{w}}");
3517  outputContainer->Add(fhNCellsPerClusterExoW);
3518 
3519  fhTimeEnergyExoW = new TH3F
3520  ("hTimeEnergyExoW","#it{E}_{cluster} vs #it{t}_{cluster} vs #it{F}_{+}^{#it{w}}, #it{n}_{cells}>1",
3521  //nptbins,ptmin,ptmax, ntimebins,timemin,timemax, nexobinsS,exominS,exomaxS);
3522  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3523  tBinsArray.GetSize() - 1, tBinsArray.GetArray(),
3524  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3525  fhTimeEnergyExoW->SetXTitle("#it{E} (GeV)");
3526  fhTimeEnergyExoW->SetYTitle("#it{t}_{cluster} (ns)");
3527  fhTimeEnergyExoW->SetZTitle("#it{F}_{+}^{#it{w}}");
3528  outputContainer->Add(fhTimeEnergyExoW);
3529 
3530  fhM02EnergyExoW = new TH3F
3531  ("hM02EnergyExoW","#sigma^{2}_{long} vs #it{E}_{cluster} vs #it{F}_{+}^{#it{w}}",
3532  //nptbins,ptmin,ptmax,ssbins,ssmin,ssmax, nexobinsS,exominS,exomaxS);
3533  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3534  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3535  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3536  fhM02EnergyExoW->SetXTitle("#it{E}_{cluster} (GeV)");
3537  fhM02EnergyExoW->SetYTitle("#sigma^{2}_{long}");
3538  fhM02EnergyExoW->SetZTitle("#it{F}_{+}^{#it{w}}");
3539  outputContainer->Add(fhM02EnergyExoW);
3540  }
3541 
3543  ("hNCellsPerClusterMinEnCut","# cells per cluster vs #it{E}_{cluster} vs #it{E}_{cell}^{min}",
3544  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3545  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
3546  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3547  fhNCellsPerClusterMinEnCut->SetXTitle("#it{E}_{cluster} (GeV)");
3548  fhNCellsPerClusterMinEnCut->SetYTitle("#it{n}_{cells}");
3549  fhNCellsPerClusterMinEnCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3550  outputContainer->Add(fhNCellsPerClusterMinEnCut);
3551 
3553  ("hNCellsPerClusterSameMinEnCut","# cells per cluster in same T-Card vs #it{E}_{cluster} vs #it{E}_{cell}^{min}",
3554  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3555  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray(),
3556  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3557  fhNCellsPerClusterSameMinEnCut->SetXTitle("#it{E}_{cluster} (GeV)");
3558  fhNCellsPerClusterSameMinEnCut->SetYTitle("#it{n}_{cells}^{same}");
3559  fhNCellsPerClusterSameMinEnCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3560  outputContainer->Add(fhNCellsPerClusterSameMinEnCut);
3561 
3563  ("hNCellsPerClusterDiffMinEnCut","# cells per cluster in diff. T-Card vs #it{E}_{cluster} vs #it{E}_{cell}^{min}",
3564  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3565  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
3566  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3567  fhNCellsPerClusterDiffMinEnCut->SetXTitle("#it{E}_{cluster} (GeV)");
3568  fhNCellsPerClusterDiffMinEnCut->SetYTitle("#it{n}_{cells}^{diff}");
3569  fhNCellsPerClusterDiffMinEnCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3570  outputContainer->Add(fhNCellsPerClusterDiffMinEnCut);
3571 
3573  {
3574  for(Int_t i = 0; i < fgkNEBins-1; i++)
3575  {
3577  (Form("hM02ExoNCellsNotAllSameTCard_Ebin%d",i),
3578  Form("#sigma^{2}_{long} vs #it{F}_{+} vs #it{n}_{cells}, %2.1f < #it{E} < %2.1f GeV, #it{n}_{cells-diff}^{#it{w}} > 0",fEnergyBins[i],fEnergyBins[i+1]),
3579  //100,0,0.5,nexobinsS,exominS,exomaxS,nceclbins,nceclmin,nceclmax);
3580  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3581  fBinsArray.GetSize() - 1, fBinsArray.GetArray(),
3582  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3583  fhM02ExoNCellsNotAllSameTCard[i]->SetXTitle("#sigma^{2}_{long}");
3584  fhM02ExoNCellsNotAllSameTCard[i]->SetYTitle("#it{F}_{+}");
3585  fhM02ExoNCellsNotAllSameTCard[i]->SetZTitle("#it{n}_{cells}");
3586  outputContainer->Add(fhM02ExoNCellsNotAllSameTCard[i]);
3587  }
3588 
3590  ("hExoticityEClusAllSameTCard","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cell} > 1, #it{n}_{cells} = #it{n}_{cells-same}",
3591  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
3592  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3593  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3594  fhExoticityEClusAllSameTCard->SetXTitle("#it{E}_{cluster} (GeV)");
3595  fhExoticityEClusAllSameTCard->SetYTitle("#it{F}_{+}");
3596  outputContainer->Add(fhExoticityEClusAllSameTCard);
3597 
3598  if ( fFillExo50ns )
3599  {
3601  ("hExoticity50nsEClusAllSameTCard","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cell} > 1, #it{n}_{cells} = #it{n}_{cells-same}",
3602  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
3603  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3604  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3605  fhExoticity50nsEClusAllSameTCard->SetXTitle("#it{E}_{cluster} (GeV)");
3606  fhExoticity50nsEClusAllSameTCard->SetYTitle("#it{F}_{+}");
3607  outputContainer->Add(fhExoticity50nsEClusAllSameTCard);
3608  }
3609 
3611  ("hNCellsPerClusterAllSameTCard","# cells per cluster vs #it{E}_{cluster}, #it{n}_{cells}=#it{n}_{cells-same}",
3612  //nptbins,ptmin,ptmax, 17,0,17);
3613  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3614  nsameBinsArray.GetSize() - 1, nsameBinsArray.GetArray());
3615  fhNCellsPerClusterAllSameTCard->SetXTitle("#it{E}_{cluster} (GeV)");
3616  fhNCellsPerClusterAllSameTCard->SetYTitle("#it{n}_{cells}");
3617  outputContainer->Add(fhNCellsPerClusterAllSameTCard);
3618 
3620  ("hM02EnergyNCellAllSameTCard","#sigma^{2}_{long} vs #it{E}_{cluster}, #it{n}_{cells} = #it{n}_{cells-same}",
3621  //nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3622  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3623  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray());
3624  fhM02EnergyAllSameTCard->SetXTitle("#it{E}_{cluster} (GeV)");
3625  fhM02EnergyAllSameTCard->SetYTitle("#sigma^{2}_{long}");
3626  outputContainer->Add(fhM02EnergyAllSameTCard);
3627 
3629  ("hEtaPhiGridExoEnCutSameFracCut",
3630  Form("colum (#eta) vs row (#varphi) vs #it{F}_{+}, #it{E}_{cluster}> %2.1f, #it{n}_{cells}>1, #it{n}_{cells-diff}^{#it{w}} = 0",fEMinForExo),
3631  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nexobinsS,exominS,exomaxS);
3632  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3633  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3634  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3635  fhEtaPhiGridExoEnCutSameFracCut->SetXTitle("column-#eta");
3636  fhEtaPhiGridExoEnCutSameFracCut->SetYTitle("row-#varphi (rad)");
3637  fhEtaPhiGridExoEnCutSameFracCut->SetZTitle("#it{F}_{+}");
3638  outputContainer->Add(fhEtaPhiGridExoEnCutSameFracCut);
3639 
3640  //
3641 
3643  ("hExoticityEClusAllSameTCardW","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cell} > 1, #it{n}_{cells} = #it{n}_{cells-same}, #it{n}_{cells-diff}^{#it{w}} = 0",
3644  //nptbins,ptmin,ptmax, nexobins,exomin,exomax);
3645  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3646  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3647  fhExoticityEClusAllSameTCardW->SetXTitle("#it{E}_{cluster} (GeV)");
3648  fhExoticityEClusAllSameTCardW->SetYTitle("#it{F}_{+}");
3649  outputContainer->Add(fhExoticityEClusAllSameTCardW);
3650 
3652  ("hNCellsPerClusterAllSameTCardW","# cells per cluster vs #it{E}_{cluster}, #it{n}_{cells}=#it{n}_{cells-same}, #it{n}_{cells-diff}^{#it{w}} = 0",
3653  //nptbins,ptmin,ptmax, 17,0,17);
3654  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3655  nBinsArray.GetSize() - 1, nBinsArray.GetArray());
3656  fhNCellsPerClusterAllSameTCardW->SetXTitle("#it{E}_{cluster} (GeV)");
3657  fhNCellsPerClusterAllSameTCardW->SetYTitle("#it{n}_{cells}");
3658  outputContainer->Add(fhNCellsPerClusterAllSameTCardW);
3659 
3661  ("hM02EnergyNCellAllSameTCardW","#sigma^{2}_{long} vs #it{E}_{cluster}, #it{n}_{cells} = #it{n}_{cells-same}, #it{n}_{cells-diff}^{#it{w}} = 0",
3662  //nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3663  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3664  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray());
3665  fhM02EnergyAllSameTCardW->SetXTitle("#it{E}_{cluster} (GeV)");
3666  fhM02EnergyAllSameTCardW->SetYTitle("#sigma^{2}_{long}");
3667  outputContainer->Add(fhM02EnergyAllSameTCardW);
3668 
3670  ("hEtaPhiGridExoEnCutSameFracCutW",
3671  Form("colum (#eta) vs row (#varphi) vs #it{F}_{+}, #it{E}_{cluster}> %2.1f, #it{n}_{cells}>1, #it{n}_{cells-diff}^{#it{w}} = 0",fEMinForExo),
3672  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,nexobinsS,exominS,exomaxS);
3673  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3674  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3675  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3676  fhEtaPhiGridExoEnCutSameFracCutW->SetXTitle("column-#eta");
3677  fhEtaPhiGridExoEnCutSameFracCutW->SetYTitle("row-#varphi (rad)");
3678  fhEtaPhiGridExoEnCutSameFracCutW->SetZTitle("#it{F}_{+}");
3679  outputContainer->Add(fhEtaPhiGridExoEnCutSameFracCutW);
3680 
3681  //
3682 
3684  ("hExoticityEClusAllSameTCardMinEnCut","cell #it{F}_{+} vs #it{E}_{cluster}, #it{n}_{cell} > 1, #it{n}_{cells} = #it{n}_{cells-same}, #it{n}_{cells-diff}^{E cut} = 0",
3685  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3686  fBinsArray.GetSize() - 1, fBinsArray.GetArray(),
3687  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3688  fhExoticityEClusAllSameTCardMinEnCut->SetXTitle("#it{E}_{cluster} (GeV)");
3689  fhExoticityEClusAllSameTCardMinEnCut->SetYTitle("#it{F}_{+}");
3690  fhExoticityEClusAllSameTCardMinEnCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3691  outputContainer->Add(fhExoticityEClusAllSameTCardMinEnCut);
3692 
3694  ("hNCellsPerClusterAllSameTCardMinEnCut","# cells per cluster vs #it{E}_{cluster}, #it{n}_{cells}=#it{n}_{cells-same}, #it{n}_{cells-diff}^{E cut} = 0",
3695  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3696  nBinsArray.GetSize() - 1, nBinsArray.GetArray(),
3697  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3698  fhNCellsPerClusterAllSameTCardMinEnCut->SetXTitle("#it{E}_{cluster} (GeV)");
3699  fhNCellsPerClusterAllSameTCardMinEnCut->SetYTitle("#it{n}_{cells}");
3700  fhNCellsPerClusterAllSameTCardMinEnCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3701  outputContainer->Add(fhNCellsPerClusterAllSameTCardMinEnCut);
3702 
3704  ("hM02EnergyNCellAllSameTCardMinEnCut","#sigma^{2}_{long} vs #it{E}_{cluster}, #it{n}_{cells} = #it{n}_{cells-same}, #it{n}_{cells-diff}^{E cut} = 0",
3705  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3706  ssBinsArray.GetSize() - 1, ssBinsArray.GetArray(),
3707  eminBinsArray.GetSize() - 1, eminBinsArray.GetArray());
3708  fhM02EnergyAllSameTCardMinEnCut->SetXTitle("#it{E}_{cluster} (GeV)");
3709  fhM02EnergyAllSameTCardMinEnCut->SetYTitle("#sigma^{2}_{long}");
3710  fhM02EnergyAllSameTCardMinEnCut->SetZTitle("#it{E}_{cell}^{min} (GeV)");
3711  outputContainer->Add(fhM02EnergyAllSameTCardMinEnCut);
3712  }
3713 
3714  // Track matching
3715  //
3716  if ( fFillMatchingHisto )
3717  {
3719  ("hTrackMatchedDEtaNegExo","d#eta of cluster-negative track vs cluster energy vs #it{F}_{+}",
3720  //nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax, nexobinsS,exominS,exomaxS);
3721  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3722  retaBinsArray.GetSize() - 1, retaBinsArray.GetArray(),
3723  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3724  fhTrackMatchedDEtaNegExo->SetYTitle("d#eta");
3725  fhTrackMatchedDEtaNegExo->SetXTitle("#it{E}_{cluster} (GeV)");
3726  fhTrackMatchedDEtaNegExo->SetZTitle("#it{F}_{+}");
3727 
3729  ("hTrackMatchedDPhiNegExo","d#varphi of cluster-negative track vs cluster energy vs #it{F}_{+}",
3730  //nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax, nexobinsS,exominS,exomaxS);
3731  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3732  rphiBinsArray.GetSize() - 1, rphiBinsArray.GetArray(),
3733  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3734  fhTrackMatchedDPhiNegExo->SetYTitle("d#varphi (rad)");
3735  fhTrackMatchedDPhiNegExo->SetXTitle("#it{E}_{cluster} (GeV)");
3736  fhTrackMatchedDPhiNegExo->SetZTitle("#it{F}_{+}");
3737 
3739  ("hTrackMatchedDEtaDPhiNegExo",
3740  Form("d#eta vs d#varphi of cluster- negative track vs #it{F}_{+}, E > %2.1f GeV",fEMinForExo),
3741  //nresetabins,resetamin,resetamax,nresphibins,resphimin,resphimax, nexobinsS,exominS,exomaxS);
3742  retaBinsArray.GetSize() - 1, retaBinsArray.GetArray(),
3743  rphiBinsArray.GetSize() - 1, rphiBinsArray.GetArray(),
3744  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3745  fhTrackMatchedDEtaDPhiNegExo->SetYTitle("d#varphi (rad)");
3746  fhTrackMatchedDEtaDPhiNegExo->SetXTitle("d#eta");
3747  fhTrackMatchedDEtaDPhiNegExo->SetZTitle("#it{F}_{+}");
3748 
3750  ("hTrackMatchedDEtaPosExo","d#eta of cluster-positive track vs cluster energy vs #it{F}_{+}",
3751  //nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax, nexobinsS,exominS,exomaxS);
3752  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3753  retaBinsArray.GetSize() - 1, retaBinsArray.GetArray(),
3754  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3755  fhTrackMatchedDEtaPosExo->SetYTitle("d#eta");
3756  fhTrackMatchedDEtaPosExo->SetXTitle("#it{E}_{cluster} (GeV)");
3757  fhTrackMatchedDEtaPosExo->SetZTitle("#it{F}_{+}");
3758 
3760  ("hTrackMatchedDPhiPosExo","d#varphi of cluster-positive track vs cluster energy vs #it{F}_{+}",
3761  //nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax, nexobinsS,exominS,exomaxS);
3762  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3763  rphiBinsArray.GetSize() - 1, rphiBinsArray.GetArray(),
3764  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3765  fhTrackMatchedDPhiPosExo->SetYTitle("d#varphi (rad)");
3766  fhTrackMatchedDPhiPosExo->SetXTitle("#it{E}_{cluster} (GeV)");
3767  fhTrackMatchedDPhiNegExo->SetZTitle("#it{F}_{+}");
3768 
3770  ("hTrackMatchedDEtaDPhiPosExo",
3771  Form("d#eta vs d#varphi of cluster-positive track vs #it{F}_{+}, E > %2.1f GeV",fEMinForExo),
3772  //nresetabins,resetamin,resetamax,nresphibins,resphimin,resphimax, nexobinsS,exominS,exomaxS);
3773  retaBinsArray.GetSize() - 1, retaBinsArray.GetArray(),
3774  rphiBinsArray.GetSize() - 1, rphiBinsArray.GetArray(),
3775  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3776  fhTrackMatchedDEtaDPhiPosExo->SetYTitle("d#varphi (rad)");
3777  fhTrackMatchedDEtaDPhiPosExo->SetXTitle("d#eta");
3778  fhTrackMatchedDEtaDPhiNegExo->SetZTitle("#it{F}_{+}");
3779 
3780  fhEOverPExo = new TH3F
3781  ("hEOverPExo",
3782  "Track matches #it{E}/#it{p} vs #it{F}_{+}",
3783  //nptbins,ptmin,ptmax, nPoverEbins,eOverPmin,eOverPmax, nexobinsS,exominS,exomaxS);
3784  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3785  eopBinsArray.GetSize() - 1, eopBinsArray.GetArray(),
3786  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3787  fhEOverPExo->SetYTitle("#it{E}/#it{p}");
3788  fhEOverPExo->SetXTitle("#it{E}_{cluster} (GeV)");
3789  fhEOverPExo->SetZTitle("#it{F}_{+}");
3790 
3791  outputContainer->Add(fhTrackMatchedDEtaNegExo) ;
3792  outputContainer->Add(fhTrackMatchedDPhiNegExo) ;
3793  outputContainer->Add(fhTrackMatchedDEtaPosExo) ;
3794  outputContainer->Add(fhTrackMatchedDPhiPosExo) ;
3795  outputContainer->Add(fhTrackMatchedDEtaDPhiNegExo) ;
3796  outputContainer->Add(fhTrackMatchedDEtaDPhiPosExo) ;
3797  outputContainer->Add(fhEOverPExo);
3798 
3799 
3800  if ( fFill1CellHisto )
3801  {
3803  ("hTrackMatchedDEtaNeg1Cell",
3804  "d#eta of cluster-negative track vs cluster energy, #it{n}_{cell}=1",
3805  nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax);
3806  fhTrackMatchedDEtaNeg1Cell->SetYTitle("d#eta");
3807  fhTrackMatchedDEtaNeg1Cell->SetXTitle("#it{E}_{cluster} (GeV)");
3808 
3810  ("hTrackMatchedDPhiNeg1Cell",
3811  "d#varphi of cluster-negative track vs cluster energy, #it{n}_{cell}=1",
3812  nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax);
3813  fhTrackMatchedDPhiNeg1Cell->SetYTitle("d#varphi (rad)");
3814  fhTrackMatchedDPhiNeg1Cell->SetXTitle("#it{E}_{cluster} (GeV)");
3815 
3817  ("hTrackMatchedDEtaDPhiNeg1Cell",
3818  Form("d#eta vs d#varphi of cluster-negative track, E > %2.2f, #it{n}_{cell}=1",fEMinForExo),
3819  nresetabins,resetamin,resetamax,nresphibins,resphimin,resphimax);
3820  fhTrackMatchedDEtaDPhiNeg1Cell->SetYTitle("d#varphi (rad)");
3821  fhTrackMatchedDEtaDPhiNeg1Cell->SetXTitle("d#eta");
3822 
3824  ("hTrackMatchedDEtaPos1Cell",
3825  "d#eta of cluster-positive track vs cluster energy, #it{n}_{cell}=1",
3826  nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax);
3827  fhTrackMatchedDEtaPos1Cell->SetYTitle("d#eta");
3828  fhTrackMatchedDEtaPos1Cell->SetXTitle("#it{E}_{cluster} (GeV)");
3829 
3831  ("hTrackMatchedDPhiPos1Cell",
3832  "d#varphi of cluster-positive track vs cluster energy, #it{n}_{cell}=1",
3833  nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax);
3834  fhTrackMatchedDPhiPos1Cell->SetYTitle("d#varphi (rad)");
3835  fhTrackMatchedDPhiPos1Cell->SetXTitle("#it{E}_{cluster} (GeV)");
3836 
3838  ("hTrackMatchedDEtaDPhiPos1Cell",
3839  Form("d#eta vs d#varphi of cluster-positive track, E > %2.2f, #it{n}_{cell}=1",fEMinForExo),
3840  nresetabins,resetamin,resetamax,nresphibins,resphimin,resphimax);
3841  fhTrackMatchedDEtaDPhiPos1Cell->SetYTitle("d#varphi (rad)");
3842  fhTrackMatchedDEtaDPhiPos1Cell->SetXTitle("d#eta");
3843 
3844  fhEOverP1Cell = new TH2F
3845  ("hEOverP1Cell",
3846  "Track matches #it{E}/#it{p}, #it{n}_{cell}=1",
3847  nptbins,ptmin,ptmax, nPoverEbins,eOverPmin,eOverPmax);
3848  fhEOverP1Cell->SetYTitle("#it{E}/#it{p}");
3849  fhEOverP1Cell->SetXTitle("#it{E}_{cluster} (GeV)");
3850 
3851  outputContainer->Add(fhTrackMatchedDEtaNeg1Cell) ;
3852  outputContainer->Add(fhTrackMatchedDPhiNeg1Cell) ;
3853  outputContainer->Add(fhTrackMatchedDEtaPos1Cell) ;
3854  outputContainer->Add(fhTrackMatchedDPhiPos1Cell) ;
3855  outputContainer->Add(fhTrackMatchedDEtaDPhiNeg1Cell) ;
3856  outputContainer->Add(fhTrackMatchedDEtaDPhiPos1Cell) ;
3857  outputContainer->Add(fhEOverP1Cell);
3858  }
3859  }
3860 
3861  // Calorimeter cells
3862  //
3863  if ( fFillCellHisto )
3864  {
3865  fhCellExoAmp = new TH2F
3866  ("hCellExoAmp","cell #it{F}_{+} vs #it{E}_{cell}",
3867  //nptbins,ptmin,ptmax/2, nexobins,exomin,exomax);
3868  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3869  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3870  fhCellExoAmp->SetXTitle("#it{E}_{cell} (GeV)");
3871  fhCellExoAmp->SetYTitle("#it{F}_{+}");
3872  outputContainer->Add(fhCellExoAmp);
3873 
3874  if ( fFillExo50ns )
3875  {
3876  fhCellExo50nsAmp = new TH2F
3877  ("hCellExo50nsAmp","cell #it{F}_{+} vs #it{E}_{cell}",
3878  //nptbins,ptmin,ptmax/2, nexobins,exomin,exomax);
3879  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3880  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3881  fhCellExo50nsAmp->SetXTitle("#it{E}_{cell} (GeV)");
3882  fhCellExo50nsAmp->SetYTitle("#it{F}_{+}");
3883  outputContainer->Add(fhCellExo50nsAmp);
3884  }
3885 
3886  fhCellExoAmpTime = new TH3F
3887  ("hCellExoAmpTime","Cell #it{F}_{+} vs #it{E}_{cell} vs time",
3888  //nptbins,ptmin,ptmax/2, ntimebins,timemin,timemax, nexobinsS,exominS,exomaxS);
3889  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
3890  tBinsArray.GetSize() - 1, tBinsArray.GetArray(),
3891  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3892  fhCellExoAmpTime->SetXTitle("#it{E}_{cell} (GeV)");
3893  fhCellExoAmpTime->SetYTitle("#it{t}_{cell} (ns)");
3894  fhCellExoAmpTime->SetZTitle("#it{F}_{+}");
3895  outputContainer->Add(fhCellExoAmpTime);
3896 
3897  fhCellExoGrid = new TH3F
3898  ("hCellExoGrid",
3899  Form("Cell hits row-column vs #it{F}_{+} for #it{E}_{cell} > %2.1f",fEMinForExo),
3900  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax, nexobinsS,exominS,exomaxS);
3901  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3902  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3903  fBinsArray.GetSize() - 1, fBinsArray.GetArray());
3904  fhCellExoGrid->SetYTitle("row (phi direction)");
3905  fhCellExoGrid->SetXTitle("column (eta direction)");
3906  fhCellExoGrid->SetZTitle("#it{F}_{+}");
3907  outputContainer->Add(fhCellExoGrid);
3908 
3910  ("hCellGridTimeHighNCell20",
3911  "Cell hits row-column vs cluster time for #it{n}_{cell}^{#it{w}} > 20",
3912  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax, 61,-610,610);
3913  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3914  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3915  t2BinsArray.GetSize() - 1, t2BinsArray.GetArray());
3916  fhCellGridTimeHighNCell20->SetYTitle("row (phi direction)");
3917  fhCellGridTimeHighNCell20->SetXTitle("column (eta direction)");
3918  fhCellGridTimeHighNCell20->SetZTitle("#it{t}_{cluster} (ns)");
3919  outputContainer->Add(fhCellGridTimeHighNCell20);
3920 
3922  ("hCellGridTimeHighNCell12",
3923  "Cell hits row-column vs cluster time for #it{n}_{cell}^{#it{w}} > 12",
3924  //ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax, 61,-610,610);
3925  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3926  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3927  t2BinsArray.GetSize() - 1, t2BinsArray.GetArray());
3928  fhCellGridTimeHighNCell12->SetYTitle("row (phi direction)");
3929  fhCellGridTimeHighNCell12->SetXTitle("column (eta direction)");
3930  fhCellGridTimeHighNCell12->SetZTitle("#it{t}_{cluster} (ns)");
3931  outputContainer->Add(fhCellGridTimeHighNCell12);
3932 
3933  for(Int_t icut = 0; icut < fgkNCellEnMinBins; icut++)
3934  {
3935  fhCellGridTime[icut] = new TH3F
3936  (Form("hCellGridTime_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3937  Form("Cell hits row-column vs cell time for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
3938  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
3939  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray(),
3940  t2BinsArray.GetSize() - 1, t2BinsArray.GetArray());
3941  fhCellGridTime[icut]->SetYTitle("row (phi direction)");
3942  fhCellGridTime[icut]->SetXTitle("column (eta direction)");
3943  fhCellGridTime[icut]->SetZTitle("#it{t}_{cell} (ns)");
3944  outputContainer->Add(fhCellGridTime[icut]);
3945 
3946  // Per Strip
3947  //
3948  if ( fFillStripHisto )
3949  {
3950  // Count cells in strip
3951  fhNCellsPerStrip[icut] = new TH1F
3952  (Form("hNCellsPerStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3953  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
3954  48,-0.5,47.5);
3955  fhNCellsPerStrip[icut]->SetYTitle("Counts per event");
3956  fhNCellsPerStrip[icut]->SetXTitle("#it{n}_{cells}^{strip}");
3957  outputContainer->Add(fhNCellsPerStrip[icut]);
3958 
3959  fhNCellsPerStripAcceptEventStrip[icut] = new TH1F
3960  (Form("hNCellsPerStripAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3961  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
3962  48,-0.5,47.5);
3963  fhNCellsPerStripAcceptEventStrip[icut]->SetYTitle("Counts per event");
3964  fhNCellsPerStripAcceptEventStrip[icut]->SetXTitle("#it{n}_{cells}^{strip}");
3965  outputContainer->Add(fhNCellsPerStripAcceptEventStrip[icut]);
3966 
3967  fhNCellsPerStripAcceptEventBoth[icut] = new TH1F
3968  (Form("hNCellsPerStripAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3969  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
3970  48,-0.5,47.5);
3971  fhNCellsPerStripAcceptEventBoth[icut]->SetYTitle("Counts per event");
3972  fhNCellsPerStripAcceptEventBoth[icut]->SetXTitle("#it{n}_{cells}^{strip}");
3973  outputContainer->Add(fhNCellsPerStripAcceptEventBoth[icut]);
3974 
3975  fhNCellsPerStripEventAccept[icut] = new TH1F
3976  (Form("hNCellsPerStripEventAccept_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3977  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
3978  48,-0.5,47.5);
3979  fhNCellsPerStripEventAccept[icut]->SetYTitle("Counts per event");
3980  fhNCellsPerStripEventAccept[icut]->SetXTitle("#it{n}_{cells}^{strip}");
3981  outputContainer->Add(fhNCellsPerStripEventAccept[icut]);
3982 
3983  fhNCellsPerStripNHigh20[icut] = new TH1F
3984  (Form("hNCellsPerStripNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3985  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
3986  48,-0.5,47.5);
3987  fhNCellsPerStripNHigh20[icut]->SetYTitle("Counts per event");
3988  fhNCellsPerStripNHigh20[icut]->SetXTitle("#it{n}_{cells}^{strip}");
3989  outputContainer->Add(fhNCellsPerStripNHigh20[icut]);
3990 
3991  // Per SM
3992  fhNCellsPerStripPerSM[icut] = new TH2F
3993  (Form("hNCellsPerStripPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
3994  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
3995  48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
3996  fhNCellsPerStripPerSM[icut]->SetZTitle("Counts per event");
3997  fhNCellsPerStripPerSM[icut]->SetYTitle("SM");
3998  fhNCellsPerStripPerSM[icut]->SetXTitle("#it{n}_{cells}^{strip}");
3999  outputContainer->Add(fhNCellsPerStripPerSM[icut]);
4000 
4002  (Form("hNCellsPerStripPerSMAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4003  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4004  48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4005  fhNCellsPerStripPerSMAcceptEventStrip[icut]->SetZTitle("Counts per event");
4006  fhNCellsPerStripPerSMAcceptEventStrip[icut]->SetYTitle("SM");
4007  fhNCellsPerStripPerSMAcceptEventStrip[icut]->SetXTitle("#it{n}_{cells}^{strip}");
4008  outputContainer->Add(fhNCellsPerStripPerSMAcceptEventStrip[icut]);
4009 
4011  (Form("hNCellsPerStripPerSMAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4012  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4013  48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4014  fhNCellsPerStripPerSMAcceptEventBoth[icut]->SetZTitle("Counts per event");
4015  fhNCellsPerStripPerSMAcceptEventBoth[icut]->SetYTitle("SM");
4016  fhNCellsPerStripPerSMAcceptEventBoth[icut]->SetXTitle("#it{n}_{cells}^{strip}");
4017  outputContainer->Add(fhNCellsPerStripPerSMAcceptEventBoth[icut]);
4018 
4020  (Form("hNCellsPerStripPerSMEventAccept_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4021  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4022  48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4023  fhNCellsPerStripPerSMEventAccept[icut]->SetZTitle("Counts per event");
4024  fhNCellsPerStripPerSMEventAccept[icut]->SetYTitle("SM");
4025  fhNCellsPerStripPerSMEventAccept[icut]->SetXTitle("#it{n}_{cells}^{strip}");
4026  outputContainer->Add(fhNCellsPerStripPerSMEventAccept[icut]);
4027 
4028  fhNCellsPerStripPerSMNHigh20[icut] = new TH2F
4029  (Form("hNCellsPerStripPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4030  Form("#it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
4031  48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4032  fhNCellsPerStripPerSMNHigh20[icut]->SetZTitle("Counts per event");
4033  fhNCellsPerStripPerSMNHigh20[icut]->SetYTitle("SM");
4034  fhNCellsPerStripPerSMNHigh20[icut]->SetXTitle("#it{n}_{cells}^{strip}");
4035  outputContainer->Add(fhNCellsPerStripPerSMNHigh20[icut]);
4036 
4037  // Sum strip cells energy
4038  //
4039  fhSumEnCellsPerStrip[icut] = new TH1F
4040  (Form("hSumEnCellsPerStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4041  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4042  1500,0,1500);
4043  fhSumEnCellsPerStrip[icut]->SetYTitle("Counts per event");
4044  fhSumEnCellsPerStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4045  outputContainer->Add(fhSumEnCellsPerStrip[icut]);
4046 
4047  fhSumEnCellsPerStripAcceptEventStrip[icut] = new TH1F
4048  (Form("hSumEnCellsPerStripAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4049  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4050  1500,0,1500);
4051  fhSumEnCellsPerStripAcceptEventStrip[icut]->SetYTitle("Counts per event");
4052  fhSumEnCellsPerStripAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4053  outputContainer->Add(fhSumEnCellsPerStripAcceptEventStrip[icut]);
4054 
4055  fhSumEnCellsPerStripAcceptEventBoth[icut] = new TH1F
4056  (Form("hSumEnCellsPerStripAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4057  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4058  1500,0,1500);
4059  fhSumEnCellsPerStripAcceptEventBoth[icut]->SetYTitle("Counts per event");
4060  fhSumEnCellsPerStripAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4061  outputContainer->Add(fhSumEnCellsPerStripAcceptEventBoth[icut]);
4062 
4063  fhSumEnCellsPerStripEventAccept[icut] = new TH1F
4064  (Form("hSumEnCellsPerStripEventAccept_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4065  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4066  1500,0,1500);
4067  fhSumEnCellsPerStripEventAccept[icut]->SetYTitle("Counts per event");
4068  fhSumEnCellsPerStripEventAccept[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4069  outputContainer->Add(fhSumEnCellsPerStripEventAccept[icut]);
4070 
4071  fhSumEnCellsPerStripNHigh20[icut] = new TH1F
4072  (Form("hSumEnCellsPerStripNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4073  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV,at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
4074  1500,0,1500);
4075  fhSumEnCellsPerStripNHigh20[icut]->SetYTitle("Counts per event");
4076  fhSumEnCellsPerStripNHigh20[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4077  outputContainer->Add(fhSumEnCellsPerStripNHigh20[icut]);
4078 
4079  // Per Strip per SM
4080  fhSumEnCellsPerStripPerSM[icut] = new TH2F
4081  (Form("hSumEnCellsPerStripPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4082  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4083  1500,0,1500, totalSM, fFirstModule-0.5, fLastModule+0.5);
4084  fhSumEnCellsPerStripPerSM[icut]->SetZTitle("Counts per event");
4085  fhSumEnCellsPerStripPerSM[icut]->SetYTitle("SM");
4086  fhSumEnCellsPerStripPerSM[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4087  outputContainer->Add(fhSumEnCellsPerStripPerSM[icut]);
4088 
4090  (Form("hSumEnCellsPerStripPerSMAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4091  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4092  1500,0,1500, totalSM, fFirstModule-0.5, fLastModule+0.5);
4093  fhSumEnCellsPerStripPerSMAcceptEventStrip[icut]->SetZTitle("Counts per event");
4094  fhSumEnCellsPerStripPerSMAcceptEventStrip[icut]->SetYTitle("SM");
4095  fhSumEnCellsPerStripPerSMAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4096  outputContainer->Add(fhSumEnCellsPerStripPerSMAcceptEventStrip[icut]);
4097 
4099  (Form("hSumEnCellsPerStripPerSMAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4100  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4101  1500,0,1500, totalSM, fFirstModule-0.5, fLastModule+0.5);
4102  fhSumEnCellsPerStripPerSMAcceptEventBoth[icut]->SetZTitle("Counts per event");
4103  fhSumEnCellsPerStripPerSMAcceptEventBoth[icut]->SetYTitle("SM");
4104  fhSumEnCellsPerStripPerSMAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4105  outputContainer->Add(fhSumEnCellsPerStripPerSMAcceptEventBoth[icut]);
4106 
4108  (Form("hSumEnCellsPerStripPerSMEventAccept_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4109  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4110  1500,0,1500, totalSM, fFirstModule-0.5, fLastModule+0.5);
4111  fhSumEnCellsPerStripPerSMEventAccept[icut]->SetZTitle("Counts per event");
4112  fhSumEnCellsPerStripPerSMEventAccept[icut]->SetYTitle("SM");
4113  fhSumEnCellsPerStripPerSMEventAccept[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4114  outputContainer->Add(fhSumEnCellsPerStripPerSMEventAccept[icut]);
4115 
4117  (Form("hSumEnCellsPerStripPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4118  Form("#Sigma #it{E}_{#it{i}} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV,at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
4119  1500,0,1500, totalSM, fFirstModule-0.5, fLastModule+0.5);
4120  fhSumEnCellsPerStripPerSMNHigh20[icut]->SetZTitle("Counts per event");
4121  fhSumEnCellsPerStripPerSMNHigh20[icut]->SetYTitle("SM");
4122  fhSumEnCellsPerStripPerSMNHigh20[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4123  outputContainer->Add(fhSumEnCellsPerStripPerSMNHigh20[icut]);
4124 
4125  // N vs Sum strip cells energy
4126  //
4127  fhNSumEnCellsPerStrip[icut] = new TH2F
4128  (Form("hNSumEnCellsPerStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4129  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4130  150,0,1500, 48,-0.5,47.5);
4131  fhNSumEnCellsPerStrip[icut]->SetZTitle("Counts per event");
4132  fhNSumEnCellsPerStrip[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4133  fhNSumEnCellsPerStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4134  outputContainer->Add(fhNSumEnCellsPerStrip[icut]);
4135 
4137  (Form("hNSumEnCellsPerStripAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4138  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4139  150,0,1500, 48,-0.5,47.5);
4140  fhNSumEnCellsPerStripAcceptEvent[icut]->SetZTitle("Counts per event");
4141  fhNSumEnCellsPerStripAcceptEvent[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4142  fhNSumEnCellsPerStripAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4143  outputContainer->Add(fhNSumEnCellsPerStripAcceptEvent[icut]);
4144 
4146  (Form("hNSumEnCellsPerStripAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4147  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4148  150,0,1500, 48,-0.5,47.5);
4149  fhNSumEnCellsPerStripAcceptEventStrip[icut]->SetZTitle("Counts per event");
4150  fhNSumEnCellsPerStripAcceptEventStrip[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4151  fhNSumEnCellsPerStripAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4152  outputContainer->Add(fhNSumEnCellsPerStripAcceptEventStrip[icut]);
4153 
4155  (Form("hNSumEnCellsPerStripAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4156  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4157  150,0,1500, 48,-0.5,47.5);
4158  fhNSumEnCellsPerStripAcceptEventBoth[icut]->SetZTitle("Counts per event");
4159  fhNSumEnCellsPerStripAcceptEventBoth[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4160  fhNSumEnCellsPerStripAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4161  outputContainer->Add(fhNSumEnCellsPerStripAcceptEventBoth[icut]);
4162 
4163  fhNSumEnCellsPerStripPerSM[icut] = new TH3F
4164  (Form("hNSumEnCellsPerStripPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4165  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4166  150,0,1500, 48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4167  fhNSumEnCellsPerStripPerSM[icut]->SetZTitle("SM");
4168  fhNSumEnCellsPerStripPerSM[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4169  fhNSumEnCellsPerStripPerSM[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4170  outputContainer->Add(fhNSumEnCellsPerStripPerSM[icut]);
4171 
4173  (Form("hNSumEnCellsPerStripPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4174  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4175  150,0,1500, 48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4176  fhNSumEnCellsPerStripPerSMAcceptEvent[icut]->SetZTitle("SM");
4177  fhNSumEnCellsPerStripPerSMAcceptEvent[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4178  fhNSumEnCellsPerStripPerSMAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4179  outputContainer->Add(fhNSumEnCellsPerStripPerSMAcceptEvent[icut]);
4180 
4182  (Form("hNSumEnCellsPerStripPerSMAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4183  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4184  150,0,1500, 48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4185  fhNSumEnCellsPerStripPerSMAcceptEventStrip[icut]->SetZTitle("SM");
4186  fhNSumEnCellsPerStripPerSMAcceptEventStrip[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4187  fhNSumEnCellsPerStripPerSMAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4188  outputContainer->Add(fhNSumEnCellsPerStripPerSMAcceptEventStrip[icut]);
4189 
4191  (Form("hNSumEnCellsPerStripPerSMAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4192  Form("#Sigma #it{E}_{#it{i}} vs #it{n}_{cells} in strip for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4193  150,0,1500, 48,-0.5,47.5, totalSM, fFirstModule-0.5, fLastModule+0.5);
4194  fhNSumEnCellsPerStripPerSMAcceptEventBoth[icut]->SetZTitle("SM");
4195  fhNSumEnCellsPerStripPerSMAcceptEventBoth[icut]->SetYTitle("#it{n}_{cells}^{strip}");
4196  fhNSumEnCellsPerStripPerSMAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}}^{strip} (GeV)");
4197  outputContainer->Add(fhNSumEnCellsPerStripPerSMAcceptEventBoth[icut]);
4198  }
4199 
4200  if ( fFillAllCellEventParamHisto < 1 ) continue;
4201 
4202  // N cells in event
4203  //
4204  fhNCells[icut] = new TH1F
4205  (Form("hNCells_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4206  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4207  17664,0,17664);
4208  fhNCells[icut]->SetYTitle("Counts per event");
4209  fhNCells[icut]->SetXTitle("#it{n}_{cells}");
4210  outputContainer->Add(fhNCells[icut]);
4211 
4212  fhNCellsNHigh20[icut] = new TH1F
4213  (Form("hNCellsNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4214  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
4215  17664,0,17664);
4216  fhNCellsNHigh20[icut]->SetYTitle("Counts per event");
4217  fhNCellsNHigh20[icut]->SetXTitle("#it{n}_{cells}");
4218  outputContainer->Add(fhNCellsNHigh20[icut]);
4219 
4220  fhNCellsAcceptEvent[icut] = new TH1F
4221  (Form("hNCellsAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4222  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4223  17664,0,17664);
4224  fhNCellsAcceptEvent[icut]->SetYTitle("Counts per event");
4225  fhNCellsAcceptEvent[icut]->SetXTitle("#it{n}_{cells}");
4226  outputContainer->Add(fhNCellsAcceptEvent[icut]);
4227 
4228  fhNCellsAcceptEventStrip[icut] = new TH1F
4229  (Form("hNCellsAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4230  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4231  17664,0,17664);
4232  fhNCellsAcceptEventStrip[icut]->SetYTitle("Counts per event");
4233  fhNCellsAcceptEventStrip[icut]->SetXTitle("#it{n}_{cells}");
4234  outputContainer->Add(fhNCellsAcceptEventStrip[icut]);
4235 
4236  fhNCellsAcceptEventBoth[icut] = new TH1F
4237  (Form("hNCellsAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4238  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4239  17664,0,17664);
4240  fhNCellsAcceptEventBoth[icut]->SetYTitle("Counts per event");
4241  fhNCellsAcceptEventBoth[icut]->SetXTitle("#it{n}_{cells}");
4242  outputContainer->Add(fhNCellsAcceptEventBoth[icut]);
4243 
4244  // Per SM
4245  fhNCellsPerSM[icut] = new TH2F
4246  (Form("hNCellsPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4247  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, per SM",fCellEnMins[icut],fCellEnMax),
4248  1152, 0, 1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4249  fhNCellsPerSM[icut]->SetZTitle("Counts per event");
4250  fhNCellsPerSM[icut]->SetYTitle("SM");
4251  fhNCellsPerSM[icut]->SetXTitle("#it{n}_{cells}");
4252  outputContainer->Add(fhNCellsPerSM[icut]);
4253 
4254  fhNCellsPerSMNHigh20[icut] = new TH2F
4255  (Form("hNCellsPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4256  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20, per SM",fCellEnMins[icut],fCellEnMax),
4257  1152, 0, 1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4258  fhNCellsPerSMNHigh20[icut]->SetZTitle("Counts per event");
4259  fhNCellsPerSMNHigh20[icut]->SetYTitle("SM");
4260  fhNCellsPerSMNHigh20[icut]->SetXTitle("#it{n}_{cells}");
4261  outputContainer->Add(fhNCellsPerSMNHigh20[icut]);
4262 
4263  fhNCellsPerSMAcceptEvent[icut] = new TH2F
4264  (Form("hNCellsPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4265  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3, per SM",fCellEnMins[icut],fCellEnMax),
4266  1152, 0, 1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4267  fhNCellsPerSMAcceptEvent[icut]->SetZTitle("Counts per event");
4268  fhNCellsPerSMAcceptEvent[icut]->SetYTitle("SM");
4269  fhNCellsPerSMAcceptEvent[icut]->SetXTitle("#it{n}_{cells}");
4270  outputContainer->Add(fhNCellsPerSMAcceptEvent[icut]);
4271 
4272  fhNCellsPerSMAcceptEventStrip[icut] = new TH2F
4273  (Form("hNCellsPerSMAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4274  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3, per SM",fCellEnMins[icut],fCellEnMax),
4275  1152, 0, 1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4276  fhNCellsPerSMAcceptEventStrip[icut]->SetZTitle("Counts per event");
4277  fhNCellsPerSMAcceptEventStrip[icut]->SetYTitle("SM");
4278  fhNCellsPerSMAcceptEventStrip[icut]->SetXTitle("#it{n}_{cells}");
4279  outputContainer->Add(fhNCellsPerSMAcceptEventStrip[icut]);
4280 
4281  fhNCellsPerSMAcceptEventBoth[icut] = new TH2F
4282  (Form("hNCellsPerSMAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4283  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3, per SM",fCellEnMins[icut],fCellEnMax),
4284  1152, 0, 1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4285  fhNCellsPerSMAcceptEventBoth[icut]->SetZTitle("Counts per event");
4286  fhNCellsPerSMAcceptEventBoth[icut]->SetYTitle("SM");
4287  fhNCellsPerSMAcceptEventBoth[icut]->SetXTitle("#it{n}_{cells}");
4288  outputContainer->Add(fhNCellsPerSMAcceptEventBoth[icut]);
4289 
4290  // Sum of cells energy in event
4291  fhSumEnCells[icut] = new TH1F
4292  (Form("hSumEnCells_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4293  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4294  10000,0,10000);
4295  fhSumEnCells[icut]->SetYTitle("Counts per event");
4296  fhSumEnCells[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4297  outputContainer->Add(fhSumEnCells[icut]);
4298 
4299  fhSumEnCellsNHigh20[icut] = new TH1F
4300  (Form("hSumEnCellsNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4301  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
4302  10000,0,10000);
4303  fhSumEnCellsNHigh20[icut]->SetYTitle("Counts per event");
4304  fhSumEnCellsNHigh20[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4305  outputContainer->Add(fhSumEnCellsNHigh20[icut]);
4306 
4307  fhSumEnCellsAcceptEvent[icut] = new TH1F
4308  (Form("hSumEnCellsAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4309  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4310  10000,0,10000);
4311  fhSumEnCellsAcceptEvent[icut]->SetYTitle("Counts per event");
4312  fhSumEnCellsAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4313  outputContainer->Add(fhSumEnCellsAcceptEvent[icut]);
4314 
4315  fhSumEnCellsAcceptEventStrip[icut] = new TH1F
4316  (Form("hSumEnCellsAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4317  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4318  10000,0,10000);
4319  fhSumEnCellsAcceptEventStrip[icut]->SetYTitle("Counts per event");
4320  fhSumEnCellsAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4321  outputContainer->Add(fhSumEnCellsAcceptEventStrip[icut]);
4322 
4323  fhSumEnCellsAcceptEventBoth[icut] = new TH1F
4324  (Form("hSumEnCellsAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4325  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4326  10000,0,10000);
4327  fhSumEnCellsAcceptEventBoth[icut]->SetYTitle("Counts per event");
4328  fhSumEnCellsAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4329  outputContainer->Add(fhSumEnCellsAcceptEventBoth[icut]);
4330 
4331  // Sum En vs N cells
4332 
4333  fhNSumEnCells[icut] = new TH2F
4334  (Form("hNSumEnCells_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4335  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4336  200,0,2000, 1104,0,17664);
4337  fhNSumEnCells[icut]->SetZTitle("Counts per event");
4338  fhNSumEnCells[icut]->SetYTitle("#it{n}_{cells}");
4339  fhNSumEnCells[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4340  outputContainer->Add(fhNSumEnCells[icut]);
4341 
4342  fhNSumEnCellsAcceptEvent[icut] = new TH2F
4343  (Form("hNSumEnCellsAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4344  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4345  200,0,2000, 1104,0,17664);
4346  fhNSumEnCellsAcceptEvent[icut]->SetZTitle("Counts per event");
4347  fhNSumEnCellsAcceptEvent[icut]->SetYTitle("#it{n}_{cells}");
4348  fhNSumEnCellsAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4349  outputContainer->Add(fhNSumEnCellsAcceptEvent[icut]);
4350 
4351  fhNSumEnCellsAcceptEventStrip[icut] = new TH2F
4352  (Form("hNSumEnCellsAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4353  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4354  200,0,2000, 1104,0,17664);
4355  fhNSumEnCellsAcceptEventStrip[icut]->SetZTitle("Counts per event");
4356  fhNSumEnCellsAcceptEventStrip[icut]->SetYTitle("#it{n}_{cells}");
4357  fhNSumEnCellsAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4358  outputContainer->Add(fhNSumEnCellsAcceptEventStrip[icut]);
4359 
4360  fhNSumEnCellsAcceptEventBoth[icut] = new TH2F
4361  (Form("hNSumEnCellsAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4362  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4363  200,0,2000, 1104,0,17664);
4364  fhNSumEnCellsAcceptEventBoth[icut]->SetZTitle("Counts per event");
4365  fhNSumEnCellsAcceptEventBoth[icut]->SetYTitle("#it{n}_{cells}");
4366  fhNSumEnCellsAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4367  outputContainer->Add(fhNSumEnCellsAcceptEventBoth[icut]);
4368 
4369  // Per SM
4370  fhSumEnCellsPerSM[icut] = new TH2F
4371  (Form("hSumEnCellsPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4372  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, per SM",fCellEnMins[icut],fCellEnMax),
4373  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4374  fhSumEnCellsPerSM[icut]->SetZTitle("Counts per event");
4375  fhSumEnCellsPerSM[icut]->SetYTitle("SM");
4376  fhSumEnCellsPerSM[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4377  outputContainer->Add(fhSumEnCellsPerSM[icut]);
4378 
4379  fhSumEnCellsPerSMNHigh20[icut] = new TH2F
4380  (Form("hSumEnCellsPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4381  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20, per SM",fCellEnMins[icut],fCellEnMax),
4382  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4383  fhSumEnCellsPerSMNHigh20[icut]->SetZTitle("Counts per event");
4384  fhSumEnCellsPerSMNHigh20[icut]->SetYTitle("SM");
4385  fhSumEnCellsPerSMNHigh20[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4386  outputContainer->Add(fhSumEnCellsPerSMNHigh20[icut]);
4387 
4388  fhSumEnCellsPerSMAcceptEvent[icut] = new TH2F
4389  (Form("hSumEnCellsPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4390  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, low Activity SM3, per SM",fCellEnMins[icut],fCellEnMax),
4391  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4392  fhSumEnCellsPerSMAcceptEvent[icut]->SetZTitle("Counts per event");
4393  fhSumEnCellsPerSMAcceptEvent[icut]->SetYTitle("SM");
4394  fhSumEnCellsPerSMAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4395  outputContainer->Add(fhSumEnCellsPerSMAcceptEvent[icut]);
4396 
4398  (Form("hSumEnCellsPerSMAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4399  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, low Activity SM3, per SM",fCellEnMins[icut],fCellEnMax),
4400  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4401  fhSumEnCellsPerSMAcceptEventStrip[icut]->SetZTitle("Counts per event");
4402  fhSumEnCellsPerSMAcceptEventStrip[icut]->SetYTitle("SM");
4403  fhSumEnCellsPerSMAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4404  outputContainer->Add(fhSumEnCellsPerSMAcceptEventStrip[icut]);
4405 
4407  (Form("hSumEnCellsPerSMAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4408  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, low Activity SM3, per SM",fCellEnMins[icut],fCellEnMax),
4409  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4410  fhSumEnCellsPerSMAcceptEventBoth[icut]->SetZTitle("Counts per event");
4411  fhSumEnCellsPerSMAcceptEventBoth[icut]->SetYTitle("SM");
4412  fhSumEnCellsPerSMAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4413  outputContainer->Add(fhSumEnCellsPerSMAcceptEventBoth[icut]);
4414 
4415  // Sum En vs N cells
4416 
4417  fhNSumEnCellsPerSM[icut] = new TH3F
4418  (Form("hNSumEnCellsPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4419  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4420  200,0,2000, 144,0,1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4421  fhNSumEnCellsPerSM[icut]->SetZTitle("SM");
4422  fhNSumEnCellsPerSM[icut]->SetYTitle("#it{n}_{cells}");
4423  fhNSumEnCellsPerSM[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4424  outputContainer->Add(fhNSumEnCellsPerSM[icut]);
4425 
4426  fhNSumEnCellsPerSMAcceptEvent[icut] = new TH3F
4427  (Form("hNSumEnCellsPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4428  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4429  200,0,2000, 144,0,1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4430  fhNSumEnCellsPerSMAcceptEvent[icut]->SetZTitle("SM");
4431  fhNSumEnCellsPerSMAcceptEvent[icut]->SetYTitle("#it{n}_{cells}");
4432  fhNSumEnCellsPerSMAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4433  outputContainer->Add(fhNSumEnCellsPerSMAcceptEvent[icut]);
4434 
4436  (Form("hNSumEnCellsPerSMAcceptEventStrip_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4437  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4438  200,0,2000, 144,0,1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4439  fhNSumEnCellsPerSMAcceptEventStrip[icut]->SetZTitle("SM");
4440  fhNSumEnCellsPerSMAcceptEventStrip[icut]->SetYTitle("#it{n}_{cells}");
4441  fhNSumEnCellsPerSMAcceptEventStrip[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4442  outputContainer->Add(fhNSumEnCellsPerSMAcceptEventStrip[icut]);
4443 
4445  (Form("hNSumEnCellsPerSMAcceptEventBoth_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4446  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4447  200,0,2000, 144,0,1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4448  fhNSumEnCellsPerSMAcceptEventBoth[icut]->SetZTitle("SM");
4449  fhNSumEnCellsPerSMAcceptEventBoth[icut]->SetYTitle("#it{n}_{cells}");
4450  fhNSumEnCellsPerSMAcceptEventBoth[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4451  outputContainer->Add(fhNSumEnCellsPerSMAcceptEventBoth[icut]);
4452 
4453  if ( fFillAllCellEventParamHisto < 2 ) continue ;
4454 
4455  // Average energy
4456  //
4457  fhAverSumEnCells[icut] = new TH1F
4458  (Form("hAverSumEnCells_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4459  Form("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[icut],fCellEnMax),
4460  10000,0,10000);
4461  fhAverSumEnCells[icut]->SetYTitle("Counts per event");
4462  fhAverSumEnCells[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} (GeV)");
4463  outputContainer->Add(fhAverSumEnCells[icut]);
4464 
4465  fhAverSumEnCellsNHigh20[icut] = new TH1F
4466  (Form("hAverSumEnCellsNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4467  Form("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",fCellEnMins[icut],fCellEnMax),
4468  10000,0,10000);
4469  fhAverSumEnCellsNHigh20[icut]->SetYTitle("Counts per event");
4470  fhAverSumEnCellsNHigh20[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} (GeV)");
4471  outputContainer->Add(fhAverSumEnCellsNHigh20[icut]);
4472 
4473  fhAverSumEnCellsAcceptEvent[icut] = new TH1F
4474  (Form("hAverSumEnCellsAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4475  Form("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3",fCellEnMins[icut],fCellEnMax),
4476  10000,0,10000);
4477  fhAverSumEnCellsAcceptEvent[icut]->SetYTitle("Counts per event");
4478  fhAverSumEnCellsAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} (GeV)");
4479  outputContainer->Add(fhAverSumEnCellsAcceptEvent[icut]);
4480 
4481  fhAverSumEnCellsPerSM[icut] = new TH2F
4482  (Form("hAverSumEnCellsPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4483  Form("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, per SM",fCellEnMins[icut],fCellEnMax),
4484  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4485  fhAverSumEnCellsPerSM[icut]->SetZTitle("Counts per event");
4486  fhAverSumEnCellsPerSM[icut]->SetYTitle("SM");
4487  fhAverSumEnCellsPerSM[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} (GeV)");
4488  outputContainer->Add(fhAverSumEnCellsPerSM[icut]);
4489 
4490  fhAverSumEnCellsPerSMNHigh20[icut] = new TH2F
4491  (Form("hAverSumEnCellsPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4492  Form("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20, per SM",fCellEnMins[icut],fCellEnMax),
4493  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4494  fhAverSumEnCellsPerSMNHigh20[icut]->SetZTitle("Counts per event");
4495  fhAverSumEnCellsPerSMNHigh20[icut]->SetYTitle("SM");
4496  fhAverSumEnCellsPerSMNHigh20[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} (GeV)");
4497  outputContainer->Add(fhAverSumEnCellsPerSMNHigh20[icut]);
4498 
4500  (Form("hAverSumEnCellsPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4501  Form("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, reject high activity events in any SM but SM3, per SM",fCellEnMins[icut],fCellEnMax),
4502  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4503  fhAverSumEnCellsPerSMAcceptEvent[icut]->SetZTitle("Counts per event");
4504  fhAverSumEnCellsPerSMAcceptEvent[icut]->SetYTitle("SM");
4505  fhAverSumEnCellsPerSMAcceptEvent[icut]->SetXTitle("#Sigma #it{E}_{#it{i}} / #it{n}_{cells} (GeV)");
4506  outputContainer->Add(fhAverSumEnCellsPerSMAcceptEvent[icut]);
4507 
4508  if ( icut == 0 ) continue ;
4509 
4510  // Fraction of n cells
4511  //
4512  fhFracNCells[icut-1] = new TH1F
4513  (Form("hFracNCells_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4514  Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4515  fCellEnMins[icut], fCellEnMins[0]),
4516  201,0,1.005);
4517  fhFracNCells[icut-1]->SetYTitle("Counts per event");
4518  fhFracNCells[icut-1]->SetXTitle(Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4519  fCellEnMins[icut], fCellEnMins[0]));
4520  outputContainer->Add(fhFracNCells[icut-1]);
4521 
4522  fhFracNCellsNHigh20[icut-1] = new TH1F
4523  (Form("hFracNCellsNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4524  Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20",
4525  fCellEnMins[icut], fCellEnMins[0]),
4526  201,0,1.005);
4527  fhFracNCellsNHigh20[icut-1]->SetYTitle("Counts per event");
4528  fhFracNCellsNHigh20[icut-1]->SetXTitle(Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4529  fCellEnMins[icut], fCellEnMins[0]));
4530  outputContainer->Add(fhFracNCellsNHigh20[icut-1]);
4531 
4532  fhFracNCellsAcceptEvent[icut-1] = new TH1F
4533  (Form("hFracNCellsAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4534  Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}, reject high activity events in any SM but SM3",
4535  fCellEnMins[icut], fCellEnMins[0]),
4536  201,0,1.005);
4537  fhFracNCellsAcceptEvent[icut-1]->SetYTitle("Counts per event");
4538  fhFracNCellsAcceptEvent[icut-1]->SetXTitle(Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4539  fCellEnMins[icut], fCellEnMins[0]));
4540  outputContainer->Add(fhFracNCellsAcceptEvent[icut-1]);
4541 
4542  // Per SM
4543 
4544  fhFracNCellsPerSM[icut-1] = new TH2F
4545  (Form("hFracNCellsPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4546  Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}, per SM",
4547  fCellEnMins[icut], fCellEnMins[0]),
4548  201,0,1.005, totalSM, fFirstModule-0.5, fLastModule+0.5);
4549  fhFracNCellsPerSM[icut-1]->SetZTitle("Counts per event");
4550  fhFracNCellsPerSM[icut-1]->SetYTitle("SM");
4551  fhFracNCellsPerSM[icut-1]->SetXTitle(Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4552  fCellEnMins[icut], fCellEnMins[0]));
4553  outputContainer->Add(fhFracNCellsPerSM[icut-1]);
4554 
4555  fhFracNCellsPerSMNHigh20[icut-1] = new TH2F
4556  (Form("hFracNCellsPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4557  Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20, per SM",
4558  fCellEnMins[icut], fCellEnMins[0]),
4559  201,0,1.005, totalSM, fFirstModule-0.5, fLastModule+0.5);
4560  fhFracNCellsPerSMNHigh20[icut-1]->SetZTitle("Counts per event");
4561  fhFracNCellsPerSMNHigh20[icut-1]->SetYTitle("SM");
4562  fhFracNCellsPerSMNHigh20[icut-1]->SetXTitle(Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4563  fCellEnMins[icut], fCellEnMins[0]));
4564  outputContainer->Add(fhFracNCellsPerSMNHigh20[icut-1]);
4565 
4566  fhFracNCellsPerSMAcceptEvent[icut-1] = new TH2F
4567  (Form("hFracNCellsPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4568  Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}, reject high activity events in any SM but SM3, per SM",
4569  fCellEnMins[icut], fCellEnMins[0]),
4570  201,0,1.005, totalSM, fFirstModule-0.5, fLastModule+0.5);
4571  fhFracNCellsPerSMAcceptEvent[icut-1]->SetZTitle("Counts per event");
4572  fhFracNCellsPerSMAcceptEvent[icut-1]->SetYTitle("SM");
4573  fhFracNCellsPerSMAcceptEvent[icut-1]->SetXTitle(Form("#it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f} / #it{n}_{cells}^{#it{E}_{#it{i}}>%1.1f}",
4574  fCellEnMins[icut], fCellEnMins[0]));
4575  outputContainer->Add(fhFracNCellsPerSMAcceptEvent[icut-1]);
4576 
4577  // Fraction of summed energy
4578  //
4579  fhFracSumEnCells[icut-1] = new TH1F
4580  (Form("hFracSumEnCells_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4581  Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",
4582  fCellEnMins[icut], fCellEnMins[0]),
4583  201,0,1.005);
4584  fhFracSumEnCells[icut-1]->SetYTitle("Counts per event");
4585  fhFracSumEnCells[icut-1]->SetXTitle(Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",
4586  fCellEnMins[icut], fCellEnMins[0]));
4587  outputContainer->Add(fhFracSumEnCells[icut-1]);
4588 
4589  fhFracSumEnCellsNHigh20[icut-1] = new TH1F
4590  (Form("hFracSumEnCellsNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4591  Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20", fCellEnMins[icut], fCellEnMins[0]),
4592  201,0,1.005);
4593  fhFracSumEnCellsNHigh20[icut-1]->SetYTitle("Counts per event");
4594  fhFracSumEnCellsNHigh20[icut-1]->SetXTitle(Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",
4595  fCellEnMins[icut], fCellEnMins[0]));
4596  outputContainer->Add(fhFracSumEnCellsNHigh20[icut-1]);
4597 
4598  fhFracSumEnCellsAcceptEvent[icut-1] = new TH1F
4599  (Form("hFracSumEnCellsAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4600  Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}, reject high activity events in any SM but SM3",
4601  fCellEnMins[icut], fCellEnMins[0]),
4602  201,0,1.005);
4603  fhFracSumEnCellsAcceptEvent[icut-1]->SetYTitle("Counts per event");
4604  fhFracSumEnCellsAcceptEvent[icut-1]->SetXTitle(Form("#Sigma #it{E}_{#it{i}} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",fCellEnMins[icut]));
4605  outputContainer->Add(fhFracSumEnCellsAcceptEvent[icut-1]);
4606 
4607  // Per SM
4608 
4609  fhFracSumEnCellsPerSM[icut-1] = new TH2F
4610  (Form("hFracSumEnCellsPerSM_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4611  Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}, per SM",
4612  fCellEnMins[icut], fCellEnMins[0]),
4613  201,0,1.005, totalSM, fFirstModule-0.5, fLastModule+0.5);
4614  fhFracSumEnCellsPerSM[icut-1]->SetZTitle("Counts per event");
4615  fhFracSumEnCellsPerSM[icut-1]->SetYTitle("SM");
4616  fhFracSumEnCellsPerSM[icut-1]->SetXTitle(Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",
4617  fCellEnMins[icut], fCellEnMins[0]));
4618  outputContainer->Add(fhFracSumEnCellsPerSM[icut-1]);
4619 
4620  fhFracSumEnCellsPerSMNHigh20[icut-1] = new TH2F
4621  (Form("hFracSumEnCellsPerSMNHigh20_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4622  Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}, at least 1 cluster with #it{n}_{cells}^{#it{w}}>20, per SM",
4623  fCellEnMins[icut], fCellEnMins[0]),
4624  201,0,1.005, totalSM, fFirstModule-0.5, fLastModule+0.5);
4625  fhFracSumEnCellsPerSMNHigh20[icut-1]->SetZTitle("Counts per event");
4626  fhFracSumEnCellsPerSMNHigh20[icut-1]->SetYTitle("SM");
4627  fhFracSumEnCellsPerSMNHigh20[icut-1]->SetXTitle(Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",
4628  fCellEnMins[icut], fCellEnMins[0]));
4629  outputContainer->Add(fhFracSumEnCellsPerSMNHigh20[icut-1]);
4630 
4631  fhFracSumEnCellsPerSMAcceptEvent[icut-1] = new TH2F
4632  (Form("hFracSumEnCellsPerSMAcceptEvent_EnMin%1.1f_Max%2.0f",fCellEnMins[icut],fCellEnMax),
4633  Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}, reject high activity events in any SM but SM3, per SM",
4634  fCellEnMins[icut], fCellEnMins[0]),
4635  201,0,1.005, totalSM, fFirstModule-0.5, fLastModule+0.5);
4636  fhFracSumEnCellsPerSMAcceptEvent[icut-1]->SetZTitle("Counts per event");
4637  fhFracSumEnCellsPerSMAcceptEvent[icut-1]->SetYTitle("SM");
4638  fhFracSumEnCellsPerSMAcceptEvent[icut-1]->SetXTitle(Form("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f} / #Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>%1.1f}",
4639  fCellEnMins[icut], fCellEnMins[0]));
4640  outputContainer->Add(fhFracSumEnCellsPerSMAcceptEvent[icut-1]);
4641 
4642  }
4643 
4645  (Form("hSM3NCellsSumEnSuspiciousEvents_EnMin%1.1f_Max%2.0f",fCellEnMins[0],fCellEnMax),
4646  Form("After event rejection, SM3 activity when high energy events in other SM, for %1.1f < #it{E}_{cell} < %2.0f GeV",fCellEnMins[0],fCellEnMax),
4647  1152,0,1152,100,0,100);
4648  fhSM3NCellsSumEnSuspiciousEvents->SetZTitle("Counts");
4649  fhSM3NCellsSumEnSuspiciousEvents->SetYTitle("#it{n}_{cells}^{#it{E}_{#it{i}}>0.5}");
4650  fhSM3NCellsSumEnSuspiciousEvents->SetXTitle("#Sigma #it{E}_{#it{i}}^{#it{E}_{#it{i}}>0.5}");
4651  outputContainer->Add(fhSM3NCellsSumEnSuspiciousEvents);
4652 
4654  (Form("hSumEnCellsPerSMEventSuspicious_EnMin%1.1f_Max%2.0f",fCellEnMins[0],fCellEnMax),
4655  Form("#Sigma #it{E}_{#it{i}} for %1.1f < #it{E}_{cell} < %2.0f GeV, per SM, suspicious",fCellEnMins[0],fCellEnMax),
4656  10000,0,10000, totalSM, fFirstModule-0.5, fLastModule+0.5);
4657  fhSumEnCellsPerSMEventSuspicious->SetZTitle("Counts per event");
4658  fhSumEnCellsPerSMEventSuspicious->SetYTitle("SM");
4659  fhSumEnCellsPerSMEventSuspicious->SetXTitle("#Sigma #it{E}_{#it{i}} (GeV)");
4660  outputContainer->Add(fhSumEnCellsPerSMEventSuspicious);
4661 
4663  (Form("hNCellsPerSMEventSuspicious_EnMin%1.1f_Max%2.0f",fCellEnMins[0],fCellEnMax),
4664  Form("#it{n}_{cells} for %1.1f < #it{E}_{cell} < %2.0f GeV, per SM",fCellEnMins[0],fCellEnMax),
4665  1152, 0, 1152, totalSM, fFirstModule-0.5, fLastModule+0.5);
4666  fhNCellsPerSMEventSuspicious->SetZTitle("Counts per event");
4667  fhNCellsPerSMEventSuspicious->SetYTitle("SM");
4668  fhNCellsPerSMEventSuspicious->SetXTitle("#it{n}_{cells}");
4669  outputContainer->Add(fhNCellsPerSMEventSuspicious);
4670 
4671  if ( fFillStripHisto )
4672  {
4673  fhNStripsPerEventSuspicious = new TH1F
4674  ("hNStripsPerEventSuspicious","#it{n}_{strips} active, Low SM3 activity and high energy strips in other SM",450,0,450);
4675  fhNStripsPerEventSuspicious->SetYTitle("Counts");
4676  fhNStripsPerEventSuspicious->SetXTitle("#it{n}_{strips}^{high activity}");
4677  outputContainer->Add(fhNStripsPerEventSuspicious);
4678 
4680  ("hNStripsPerEventSuspiciousPerSM","#it{n}_{strips} active per SM, Low SM3 activity and high energy strips in other SM",
4681  24,0,24,totalSM,fFirstModule-0.5, fLastModule+0.5);
4682  fhNStripsPerEventSuspiciousPerSM->SetZTitle("Counts");
4683  fhNStripsPerEventSuspiciousPerSM->SetYTitle("SM");
4684  fhNStripsPerEventSuspiciousPerSM->SetXTitle("#it{n}_{strips}^{high activity}");
4685  outputContainer->Add(fhNStripsPerEventSuspiciousPerSM);
4686  }
4687  }
4688 
4689  if ( fFillStripHisto )
4690  {
4691  fhNStripsPerEvent = new TH1F
4692  ("hNStripsPerEvent","#it{n}_{strips} active, Low SM3 activity and high energy strips in other SM",450,0,450);
4693  fhNStripsPerEvent->SetYTitle("Counts");
4694  fhNStripsPerEvent->SetXTitle("#it{n}_{strips}^{high activity}");
4695  outputContainer->Add(fhNStripsPerEvent);
4696 
4698  ("hNStripsPerEventPerSM","#it{n}_{strips} active per SM, Low SM3 activity and high energy strips in other SM",
4699  24,0,24,totalSM,fFirstModule-0.5, fLastModule+0.5);
4700  fhNStripsPerEventPerSM->SetZTitle("Counts");
4701  fhNStripsPerEventPerSM->SetYTitle("SM");
4702  fhNStripsPerEventPerSM->SetXTitle("#it{n}_{strips}^{high activity}");
4703  outputContainer->Add(fhNStripsPerEventPerSM);
4704 
4706  {
4707  fhNStripsPerEventAccept = new TH1F
4708  ("hNStripsPerEventAccept","#it{n}_{strips} active, Low SM3 activity and high energy strips in other SM, event accepted",450,0,450);
4709  fhNStripsPerEventAccept->SetYTitle("Counts");
4710  fhNStripsPerEventAccept->SetXTitle("#it{n}_{strips}^{high activity}");
4711  outputContainer->Add(fhNStripsPerEventAccept);
4712 
4714  ("hNStripsPerEventAcceptPerSM","#it{n}_{strips} active per SM, Low SM3 activity and high energy strips in other SM, event accepted",
4715  24,0,24,totalSM,fFirstModule-0.5, fLastModule+0.5);
4716  fhNStripsPerEventAcceptPerSM->SetZTitle("Counts");
4717  fhNStripsPerEventAcceptPerSM->SetYTitle("SM");
4718  fhNStripsPerEventAcceptPerSM->SetXTitle("#it{n}_{strips}^{high activity}");
4719  outputContainer->Add(fhNStripsPerEventAcceptPerSM);
4720  }
4721  }
4722 
4724  {
4725  TString evtSelName[] = {"Open","PassLEDSM","PassLEDStrip","PassLEDBoth"};
4726  for (Int_t icase = 0; icase < 4; icase++)
4727  {
4728  fhEventCutClusterEnergyTime[icase] = new TH2F
4729  (Form("hEventCutClusterEnergyTime_%s",evtSelName[icase].Data()),
4730  Form("#it{E}_{cluster} vs #it{t}_{cluster} after exotic cuts, %s",evtSelName[icase].Data()),
4731  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
4732  tBinsArray.GetSize() - 1, tBinsArray.GetArray());
4733  fhEventCutClusterEnergyTime[icase]->SetXTitle("#it{E} (GeV)");
4734  fhEventCutClusterEnergyTime[icase]->SetYTitle("#it{t}_{cluster} (ns)");
4735  outputContainer->Add(fhEventCutClusterEnergyTime[icase]);
4736 
4737  fhEventCutClusterEnergy[icase] = new TH1F
4738  (Form("hEventCutClusterEnergy_%s",evtSelName[icase].Data()),
4739  Form("#it{E}_{cluster} after time and exotic cuts, %s",evtSelName[icase].Data()),
4740  eBinsArray.GetSize() - 1, eBinsArray.GetArray()) ;
4741  fhEventCutClusterEnergy[icase]->SetXTitle("#it{E} (GeV)");
4742  outputContainer->Add(fhEventCutClusterEnergy[icase]);
4743 
4745  (Form("hEventCutClusterEnergyECellMax_%s",evtSelName[icase].Data()),
4746  Form("#it{E}_{cluster} vs #it{E}^{max}_{cell} after time and exotic cuts, %s",evtSelName[icase].Data()),
4747  eBinsArray.GetSize() - 1, eBinsArray.GetArray(),
4748  eBinsArray.GetSize() - 1, eBinsArray.GetArray());
4749  fhEventCutClusterEnergyECellMax[icase]->SetXTitle("#it{E}^{org}_{cluster} (GeV)");
4750  fhEventCutClusterEnergyECellMax[icase]->SetYTitle("#it{E}^{max}_{cell} (GeV)");
4751  outputContainer->Add(fhEventCutClusterEnergyECellMax[icase]);
4752 
4753  fhEventCutClusterEtaPhiGrid[icase] = new TH2F
4754  (Form("hEventCutClusterEtaPhiGrid_%s",evtSelName[icase].Data()),
4755  Form("colum (#eta) vs row (#varphi) after time and exotic cuts, #it{E}_{cluster}> %2.1f, %s",
4756  fEMinForExo,evtSelName[icase].Data()),
4757  colBinsArray.GetSize() - 1, colBinsArray.GetArray(),
4758  rowBinsArray.GetSize() - 1, rowBinsArray.GetArray());
4759  fhEventCutClusterEtaPhiGrid[icase]->SetXTitle("column-#eta");
4760  fhEventCutClusterEtaPhiGrid[icase]->SetYTitle("row-#varphi (rad)");
4761  outputContainer->Add(fhEventCutClusterEtaPhiGrid[icase]);
4762 
4763  fhEventCutBunchCrossing[icase] = new TH1I
4764  (Form("hEventCutBunchCrossing_%s" ,evtSelName[icase].Data()),
4765  Form("Selected event bunch crossing, %s",evtSelName[icase].Data()),
4766  3564, -0.5, 3563.5) ;
4767  fhEventCutBunchCrossing[icase]->SetXTitle("Bunch Crossing");
4768  outputContainer->Add(fhEventCutBunchCrossing[icase]);
4769  }
4770  }
4771 
4772  // for(Int_t i = 0; i < outputContainer->GetEntries() ; i++)
4773  // printf("i=%d, name= %s\n",i,outputContainer->At(i)->GetName());
4774 
4775  return outputContainer;
4776 }
4777 
4778 
4779 //______________________________
4781 //______________________________
4783 {
4784  if(GetCalorimeter() != kPHOS && GetCalorimeter() !=kEMCAL)
4785  AliFatal(Form("Wrong calorimeter name <%s>", GetCalorimeterString().Data()));
4786 
4787  if(GetReader()->GetDataType()== AliCaloTrackReader::kMC)
4788  AliFatal("Analysis of reconstructed data, MC reader not aplicable");
4789 }
4790 
4791 
4792 //_________________________________________________________
4794 //_________________________________________________________
4796 {
4797  if(! opt)
4798  return;
4799 
4800  printf("**** Print %s %s ****\n", GetName(), GetTitle() ) ;
4802 
4803  printf("Select Calorimeter %s \n",GetCalorimeterString().Data());
4804  printf("Min Amplitude : %2.1f GeV/c\n", fCellAmpMin) ;
4805  printf("Min Energy for exotic : %2.1f GeV/c\n", fEMinForExo) ;
4806  printf("Exoticity cut: %0.2f \n", fExoCut) ;
4807  printf("NCell cut: %d \n", fNCellHighCut) ;
4808  printf("Time range: [%2.2f,%2.2f] ns\n",fTimeCutMin,fTimeCutMax);
4809 
4810  printf("SM : nCell >= %d - Sum E >= %2.0f\n",fHighNCellsCutSM,fHighEnergyCutSM) ;
4811  printf("SM3: nCell <= %d - Sum E <= %2.0f\n",fLowNCellsCutSM3,fLowEnergyCutSM3) ;
4812  printf("Strip: nCell > %d-%d - Sum E > %2.0f-%2.0f; Event N Strips <= %d\n",
4815  printf("SM3 strips: nCell <= %d - Sum E <= %2.0f\n",fLowNCellsCutSM3Strip,fLowEnergyCutSM3Strip) ;
4816 
4817  printf("Min Cell Energy cut: ");
4818  for(Int_t i = 0; i < fgkNCellEnMinBins; i++) printf("%d) E %1.2f; ", i,fCellEnMins[i] );
4819  printf("\n");
4820 
4821  printf("Fill cell histo: %d\n" , fFillCellHisto) ;
4822  printf("Fill all cell event histo: %d\n", fFillAllCellEventParamHisto) ;
4823  printf("Fill strip histo : %d\n" , fFillStripHisto) ;
4824  printf("Fill 1 cell cluster histo: %d\n", fFill1CellHisto) ;
4825  printf("Fill Matching histo: %d\n" , fFillMatchingHisto) ;
4826  printf("Fill Exoticity 50ns cut: %d\n" , fFillExo50ns) ;
4827  printf("Fill cluster histo after event cut: %d\n" , fFillClusterHistoAfterEventCut) ;
4828 }
4829 
4830 
4831 //_____________________________________________________
4833 //_____________________________________________________
4835 {
4836  AliDebug(1,"Start");
4837 
4838  // Get List with CaloClusters , calo Cells, init min amplitude
4839  TObjArray * caloClusters = NULL;
4840  AliVCaloCells * cells = 0x0;
4841 
4842  if (GetCalorimeter() == kPHOS)
4843  {
4844  caloClusters = GetPHOSClusters();
4845  cells = GetPHOSCells();
4846  }
4847  else if (GetCalorimeter() == kEMCAL)
4848  {
4849  caloClusters = GetEMCALClusters();
4850  cells = GetEMCALCells();
4851  }
4852 
4853  if( !caloClusters || !cells )
4854  {
4855  AliWarning(Form("AliAnaCaloExotics::MakeAnalysisFillHistograms() - No CaloClusters or CaloCells available"));
4856  return;
4857  }
4858 
4859  if(caloClusters->GetEntriesFast() == 0) return ;
4860 
4861  //printf("Exotic Task: N cells %d, N clusters %d \n",cells->GetNumberOfCells(),caloClusters->GetEntriesFast());
4862 
4863  // Clusters
4864  ClusterHistograms(caloClusters,cells);
4865 
4866  // Strips of cells 2x24
4867  if ( fFillStripHisto ) StripHistograms(cells);
4868 
4869  // Cells
4870  if (