AliPhysics  608b256 (608b256)
AliAnaClusterShapeCorrelStudies.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 <TH3F.h>
19 #include <TObjString.h>
20 
21 //---- AliRoot system ----
23 #include "AliCaloTrackReader.h"
24 #include "AliVCaloCells.h"
25 #include "AliFiducialCut.h"
26 #include "AliVCluster.h"
27 #include "AliVTrack.h"
28 #include "AliVEvent.h"
29 
30 // --- Detectors ---
31 #include "AliEMCALGeometry.h"
32 
36 
37 //__________________________________________
40 //__________________________________________
43 
44 // Switches
45 fStudyShape(kFALSE), fStudyShapeParam(kFALSE),
46 fStudyWeight(kFALSE),
47 fStudyTCardCorrelation(kFALSE), fStudyExotic(kFALSE),
48 fStudyColRowFromCellMax(kFALSE), fStudyInvMass(kFALSE),
49 fStudyTimeCellHisto(kFALSE), fStudyModuleCells(kTRUE),
50 fFillNLocMaxHistos(kTRUE),
51 
52 // Parameters and cuts
53 fM02Min(0), fNCellMin(0),
54 fMinDistToBad(0), fNEBinCuts(0),
55 fEMinShape(0), fEMaxShape(100),
56 fNCellMinShape(-1), fNCellsBins(3),
57 
58 fNMatchPIDCases(1),
59 fdEdXMinEle(0), fdEdXMaxEle(0),
60 fdEdXMinHad(0), fdEdXMaxHad(0),
61 
62 // Invariant mass
63 fInvMassMinECut(0), fInvMassMaxECut(0),
64 fInvMassMinM02Cut(0), fInvMassMaxM02Cut(0),
65 fInvMassMaxOpenAngle(0), fInvMassMaxTimeDifference(0),
66 
67 fConstantTimeShift(0),
68 
69 fClusterMomentum(), fClusterMomentum2(),
70 fCaloCellList(NULL), fCaloClusList(NULL),
71 
72 // Histograms
73 
74 // TCard correl and shape and exoticity
75 fhEnergyTMEtaResidual1Cell(0), fhEnergyTMPhiResidual1Cell(0),
76 fhColRowExoticHighE1CellPosTime(0), fhColRowExoticHighE1CellNegTime(0), fhColRowExoticHighE1CellNulTime(0),
77 fhEnergyTMEtaResidualExotic(0), fhEnergyTMPhiResidualExotic(0),
78 fhColRowExoticHighEPosTime(0), fhColRowExoticHighENegTime(0), fhColRowExoticHighENulTime(0),
79 fhColRowHighEPosTime(0), fhColRowHighENegTime(0), fhColRowHighENulTime(0),
80 fhEnergyTMEtaResidualTCardCorrNoSelection1Cell(0), fhEnergyTMPhiResidualTCardCorrNoSelection1Cell(0),
81 fhEnergyTMEtaResidualTCardCorrNoSelectionExotic(0), fhEnergyTMPhiResidualTCardCorrNoSelectionExotic(0),
82 
83 // Shape studies
84 //fhCellTimeSpreadRespectToCellMaxM02(0),
85 //fhClusterMaxCellCloseCellDiffM02(0),
86 fhClusterMaxCellCloseCellRatioM02(0), fhClusterMaxCellECrossM02(0),
87 fhInvMassNCellSM(0), fhInvMassNCellSMSame(0),
88 fhColRowM02(0), fhColRowM02NCellCut(0),
89 fhEMaxCellTimeM02SM(0), fhEMaxCellTimeNCellSM(0), fhESecCellTimeNCellSM(0),
90 // Module
91 fhSMNCellModuleMax(0), fhSMNCellModuleOut(0),
92 fhSMNCellModuleOutModSame(0), fhSMNCellModuleOutModDiff(0),
93 fhSMECellModuleMax(0), fhSMECellModuleMaxTot(0),
94 fhSMECellModuleOut(0), fhSMECellModuleOutModSame(0), fhSMECellModuleOutModDiff(0),
95 fhSMNCellModuleMaxOutRat(0), fhSMNCellModuleMaxOutModSameRat(0), fhSMNCellModuleMaxOutModDiffRat(0),
96 fhSMECellModuleMaxRat(0), fhSMECellModuleMaxTotRat(0), fhSMECellModuleMaxTotRatClus(0),
97 fhSMECellModuleMaxOutRat(0), fhSMECellModuleMaxOutModSameRat(0), fhSMECellModuleMaxOutModDiffRat(0),
98 
99 fhSMNCellModuleMaxLowM02(0), fhSMNCellModuleOutLowM02(0),
100 fhSMNCellModuleOutModSameLowM02(0), fhSMNCellModuleOutModDiffLowM02(0),
101 fhSMECellModuleMaxLowM02(0), fhSMECellModuleMaxTotLowM02(0),
102 fhSMECellModuleOutLowM02(0), fhSMECellModuleOutModSameLowM02(0), fhSMECellModuleOutModDiffLowM02(0),
103 fhSMNCellModuleMaxOutRatLowM02(0), fhSMNCellModuleMaxOutModSameRatLowM02(0),fhSMNCellModuleMaxOutModDiffRatLowM02(0),
104 fhSMECellModuleMaxRatLowM02(0), fhSMECellModuleMaxTotRatLowM02(0), fhSMECellModuleMaxTotRatClusLowM02(0),
105 fhSMECellModuleMaxOutRatLowM02(0), fhSMECellModuleMaxOutModSameRatLowM02(0),fhSMECellModuleMaxOutModDiffRatLowM02(0),
106 
107 fhSMNCellModuleMaxHighM02(0), fhSMNCellModuleOutHighM02(0),
108 fhSMNCellModuleOutModSameHighM02(0), fhSMNCellModuleOutModDiffHighM02(0),
109 fhSMECellModuleMaxHighM02(0), fhSMECellModuleMaxTotHighM02(0),
110 fhSMECellModuleOutHighM02(0), fhSMECellModuleOutModSameHighM02(0), fhSMECellModuleOutModDiffHighM02(0),
111 fhSMNCellModuleMaxOutRatHighM02(0), fhSMNCellModuleMaxOutModSameRatHighM02(0),fhSMNCellModuleMaxOutModDiffRatHighM02(0),
112 fhSMECellModuleMaxRatHighM02(0), fhSMECellModuleMaxTotRatHighM02(0), fhSMECellModuleMaxTotRatClusHighM02(0),
113 fhSMECellModuleMaxOutRatHighM02(0), fhSMECellModuleMaxOutModSameRatHighM02(0),fhSMECellModuleMaxOutModDiffRatHighM02(0),
114 
115 fhSMEMaxEClusterRat(0),
116 fhSMEMaxEClusterRatLowM02(0), fhSMEMaxEClusterRatHighM02(0),
117 
118 fhTCardChannelM02(0), fhTCardChannelM02NoCut(0),
119 fhTCardChannelNCellModMax(0), fhTCardChannelNCell(0),
120 
121 // Weight studies
122 fhECellClusterRatio(0), fhECellClusterLogRatio(0),
123 fhEMaxCellClusterRatio(0), fhEMaxCellClusterLogRatio(0),
124 fhECellTotalRatio(0), fhECellTotalLogRatio(0),
125 fhECellTotalRatioMod(0), fhECellTotalLogRatioMod(0)
126 {
127  for(Int_t i=0; i < 3; i++)
128  {
129  // Shower shape dependence
130  fhClusterTimeEnergyM02 [i] = 0;
132  fhNCellsPerClusterM02 [i] = 0;
133  fhNCellsPerClusterM20 [i] = 0;
134  fhNCellsPerClusterNLM [i] = 0;
135 
136  fhNCellsPerClusterMEta [i] = 0;
137  fhNCellsPerClusterMPhi [i] = 0;
140 
141  fhSMNLocMax [i] = 0;
142  fhSMNCell [i] = 0;
143  fhSMNCellLowM02 [i] = 0;
144  fhSMNCellHighM02 [i] = 0;
145  fhSMNCellM02 [i] = 0;
146  fhSMM02 [i] = 0;
147  fhSMM02NoCut [i] = 0;
148 
149  fhSMMEta [i] = 0;
150  fhSMMEtaNoCut [i] = 0;
151  fhSMMPhi [i] = 0;
152  fhSMMPhiNoCut [i] = 0;
153  fhSMMEtaPhi [i] = 0;
154  fhSMMEtaPhiNoCut [i] = 0;
155  fhSMMEtaPhiA [i] = 0;
156  fhSMMEtaPhiANoCut [i] = 0;
157 
158  fhSMM20LowM02 [i] = 0;
159  fhSMM20LowM02NoCut [i] = 0;
160  fhSMM20HighM02 [i] = 0;
161  fhSMM20HighM02NoCut [i] = 0;
162 
163  fhColM02 [i] = 0;
164  fhRowM02 [i] = 0;
165 
166  fhOriginE [i] = 0;
167  fhOriginM02 [i] = 0;
168  fhOriginENoCut [i] = 0;
169  fhOriginM02NoCut [i] = 0;
170  fhOriginEOverlap [i] = 0;
171  fhOriginM02Overlap [i] = 0;
172  fhOriginENoCutOverlap [i] = 0;
174 
175  // Cluster asymmetry
176  fhDeltaIEtaDeltaIPhi [i] = 0;
177  fhDeltaIA [i] = 0;
178  fhDeltaIAM02 [i] = 0;
179  fhDeltaIAM20 [i] = 0;
180  fhDeltaIANCells [i] = 0;
181  fhDeltaIAOrigin [i] = 0;
182 
184  fhDeltaIATot [i] = 0;
185  fhDeltaIATotM02 [i] = 0;
186  fhDeltaIATotM20 [i] = 0;
187  fhDeltaIATotNCells [i] = 0;
188  fhDeltaIATotOrigin [i] = 0;
189  }
190 
191  // Weight studies
192  for(Int_t i =0; i < 12; i++)
193  {
194  for(Int_t j = 0; j < 4; j++)
195  {
196  for(Int_t k = 0; k < 3; k++)
197  {
198  fhLambda0ForW0AndCellCuts [i][j][k] = 0;
199 // fhLambda1ForW0AndCellCuts [i][j][k] = 0;
200  fhLambda0ForW0AndCellCutsEta0[i][j][k] = 0;
201  }
202  }
203  for(Int_t j = 0; j < 5; j++)
204  {
205  fhLambda0ForW0MC[i][j] = 0;
206 // fhLambda1ForW0MC[i][j] = 0;
207  }
208  }
209 
210  // TCard correl studies
211  for(Int_t tm = 0; tm < 2; tm++)
212  {
213  fhEnergyTime1Cell [tm] = 0;
214  fhColRowExoticLowE1Cell [tm] = 0;
215  fhColRowExoticHighE1Cell[tm] = 0;
216 
217  fhEnergyTimeExotic [tm] = 0;
218  fhColRowExoticLowE [tm] = 0 ;
219  fhColRowExoticHighE[tm] = 0 ;
224 
227 
230 
235 
240 
243 
252 
262 
269 
279 
289 
290 
291  fhNCellsTCardCorrNoSelection [tm] = 0 ;
294  fhExoticTCardCorrNoSelection [tm] = 0 ;
297 
306 
307  for(Int_t i = 0; i < 6; i++)
308  {
309  for(Int_t j = 0; j < 6; j++)
310  {
311  fhLambda0TCardCorrelNCell[i][j][tm] = 0 ;
312  fhLambda1TCardCorrelNCell[i][j][tm] = 0 ;
313  fhLambda0NLM1TCardCorrelNCell[i][j][tm] = 0 ;
314  fhLambda1NLM1TCardCorrelNCell[i][j][tm] = 0 ;
315  fhLambda0NLM2TCardCorrelNCell[i][j][tm] = 0 ;
316  fhLambda1NLM2TCardCorrelNCell[i][j][tm] = 0 ;
317 // fhLambdaRTCardCorrelNCell[i][j][tm] = 0 ;
318  fhNLocMaxTCardCorrelNCell[i][j][tm] = 0 ;
319 
320  fhEMaxRatNLM1TCardCorrelNCell[i][j][tm] = 0 ;
321  fhEMaxRatNLM2TCardCorrelNCell[i][j][tm] = 0 ;
322  fhEMaxRatNLM3TCardCorrelNCell[i][j][tm] = 0 ;
323  fhE2ndRatNLM1TCardCorrelNCell[i][j][tm] = 0 ;
324  fhE2ndRatNLM2TCardCorrelNCell[i][j][tm] = 0 ;
325  fhE2ndRatNLM3TCardCorrelNCell[i][j][tm] = 0 ;
326  fhE2ndEMaxRatNLM1TCardCorrelNCell[i][j][tm] = 0 ;
327  fhE2ndEMaxRatNLM2TCardCorrelNCell[i][j][tm] = 0 ;
328  fhE2ndEMaxRatNLM3TCardCorrelNCell[i][j][tm] = 0 ;
329 
330  fhECellClusRatNLM1TCardCorrelNCell[i][j][tm] = 0 ;
331  fhECellClusRatNLM2TCardCorrelNCell[i][j][tm] = 0 ;
332  fhECellClusRatNLM3TCardCorrelNCell[i][j][tm] = 0 ;
333  fhLogECellNLM1TCardCorrelNCell[i][j][tm] = 0 ;
334  fhLogECellNLM2TCardCorrelNCell[i][j][tm] = 0 ;
335  fhLogECellNLM3TCardCorrelNCell[i][j][tm] = 0 ;
336  fhECellWeightNLM1TCardCorrelNCell [i][j][tm] = 0 ;
337  fhECellWeightNLM2TCardCorrelNCell [i][j][tm] = 0 ;
338  fhECellWeightNLM3TCardCorrelNCell [i][j][tm] = 0 ;
339 
340  fhMassEClusTCardCorrelNCell[i][j][tm] = 0 ;
341 // fhMassEPairTCardCorrelNCell[i][j][tm] = 0 ;
342  fhExoticTCardCorrelNCell [i][j][tm] = 0 ;
343  fhTimeDiffTCardCorrelNCell [i][j][tm] = 0 ;
344  fhTimeDiffExoTCardCorrelNCell[i][j][tm] = 0 ;
345  fhColRowTCardCorrelNCellLowE [i][j][tm] = 0 ;
346  fhColRowTCardCorrelNCellHighE[i][j][tm] = 0 ;
347  }
348 
349 // fhLambda0TCardCorrelN[i][tm] = 0 ;
350 // fhNCellsTCardCorrelN [i][tm] = 0 ;
351 // fhExoticTCardCorrelN [i][tm] = 0 ;
352 // fhColRowTCardCorrelNLowE [i][tm] = 0 ;
353 // fhColRowTCardCorrelNHighE[i][tm] = 0 ;
354 //
355 // fhLambda0TCardCorrelNAllSameTCard[i][tm] = 0 ;
356 // fhNCellsTCardCorrelNAllSameTCard [i][tm] = 0 ;
357 // fhExoticTCardCorrelNAllSameTCard [i][tm] = 0 ;
358 // fhColRowTCardCorrelNAllSameTCardLowE [i][tm] = 0 ;
359 // fhColRowTCardCorrelNAllSameTCardHighE[i][tm] = 0 ;
360 //
361 // fhLambda0TCardCorrelNExotic[i][tm] = 0 ;
362 // fhNCellsTCardCorrelNExotic [i][tm] = 0 ;
363 // fhColRowTCardCorrelNLowEExotic [i][tm] = 0 ;
364 // fhColRowTCardCorrelNHighEExotic[i][tm] = 0 ;
365 //
366 // fhLambda0TCardCorrelNAllSameTCardExotic[i][tm] = 0 ;
367 // fhNCellsTCardCorrelNAllSameTCardExotic [i][tm] = 0 ;
368 // fhColRowTCardCorrelNAllSameTCardLowEExotic [i][tm] = 0 ;
369 // fhColRowTCardCorrelNAllSameTCardHighEExotic[i][tm] = 0 ;
370 // fhLambda0TCardCorrelNearRow[i][tm] = 0 ;
371 // fhNCellsTCardCorrelNearRow [i][tm] = 0 ;
372  }
373 
374 // for(Int_t i = 0; i < 4; i++)
375 // {
376 // fhLambda0TCardCorrel2ndMax[i][tm] = 0 ;
377 // fhNCellsTCardCorrel2ndMax [i][tm] = 0 ;
378 // fhLambda0TCardCorrelExotic[i][tm] = 0 ;
379 // fhNCellsTCardCorrelExotic [i][tm] = 0 ;
380 // }
381 
382  for(Int_t i = 0; i < 14; i++)
383  {
384  fhLambda0Exoticity[i][tm] = 0;
385  fhLambda1Exoticity[i][tm] = 0;
386 // fhLambdaRExoticity[i][tm] = 0;
387  fhNCellsExoticity [i][tm] = 0;
388  fhTimeExoticity [i][tm] = 0;
389  fhLambda0Lambda1 [i][tm] = 0;
390 
391 // fhLambda0ExoticityAllSameTCard[i][tm] = 0;
392 // fhLambda1ExoticityAllSameTCard[i][tm] = 0;
393 // fhLambdaRExoticityAllSameTCard[i][tm] = 0;
394 // fhNCellsExoticityAllSameTCard [i][tm] = 0;
395 // fhLambda0Lambda1AllSameTCard [i][tm] = 0;
396 
397  fhNCellsTCardSameAndDiff [i][tm] = 0;
399  }
400 
401  for(Int_t j = 0; j < 6; j++)
402  {
403  for(Int_t k = 0; k < 6; k++)
404  {
405  fhLambda0ExoticityPerNCell[j][k][tm] = 0;
406  fhLambda1ExoticityPerNCell[j][k][tm] = 0;
407 // fhLambdaRExoticityPerNCell[j][k][tm] = 0;
408  }
409  }
410 
411 // for(Int_t i = 0; i < 7; i++)
412 // {
413 // fhLambda0TCardCorrel[i][tm] = 0 ;
414 // fhNCellsTCardCorrel [i][tm] = 0 ;
415 // fhExoticTCardCorrel [i][tm] = 0 ;
416 //
417 // fhLambda0TCardCorrelOtherTCard[i][tm] = 0 ;
418 // fhNCellsTCardCorrelOtherTCard [i][tm] = 0 ;
419 // fhExoticTCardCorrelOtherTCard [i][tm] = 0 ;
420 // fhColRowTCardCorrelOtherTCardLowE [i][tm] = 0 ;
421 // fhColRowTCardCorrelOtherTCardHighE[i][tm] = 0 ;
422 // }
423 
424  for(Int_t i = 0; i < 12; i++)
425  {
426  fhTCardCorrECellMaxDiff[i][tm]=0;
427  fhTCardCorrEClusterDiff[i][tm]=0;
428 // fhTCardCorrECellMaxRat [i][tm]=0;
429 // fhTCardCorrEClusterRat [i][tm]=0;
430  fhTCardCorrTCellMaxDiff[i][tm]=0;
431 
432  fhTCardCorrECellMaxDiffExo[i][tm]=0;
433  fhTCardCorrEClusterDiffExo[i][tm]=0;
434 // fhTCardCorrECellMaxRatExo [i][tm]=0;
435 // fhTCardCorrEClusterRatExo [i][tm]=0;
436  fhTCardCorrTCellMaxDiffExo[i][tm]=0;
437  }
438  }
439 
440  for(Int_t i = 0; i < fNEBinCuts; i++)
441  {
446 // fhTMPhiResidualExoticityAllSameTCard[i] = 0;
447 // fhTMEtaResidualExoticityAllSameTCard[i] = 0;
448  }
449 
450  for(Int_t i = 0; i < 20; i++)
451  {
456  //fhESecCellLogM02NCellPerSM [i] = 0;
457 
459  //fhEMaxCellLogM02NCellPerSM [i] = 0;
460 
465 
468 
471 
478 
479  for(Int_t j = 0; j < 4; j++)
480  {
485 
490 
495  }
496  }
497 
500 
503 
504  InitParameters();
505 }
506 
507 
508 //___________________________________________________
517 //___________________________________________________
519 (AliVCluster* clus, Bool_t matched,Int_t absIdMax, Float_t exoticity)
520 {
521  // Get the col and row of the leading cluster cell
522 
523  Int_t icol = -1, irow = -1, iRCU = -1, icolAbs = -1, irowAbs = -1;
524  GetModuleNumberCellIndexesAbsCaloMap(absIdMax,GetCalorimeter(), icol, irow, iRCU, icolAbs, irowAbs);
525 
526  Float_t energy = clus->E();
527  Int_t ebin = -1;
528  for(Int_t ie = 0; ie < fNEBinCuts; ie++)
529  {
530  if( energy >= fEBinCuts[ie] && energy < fEBinCuts[ie+1] ) ebin = ie;
531  }
532 
533  Int_t ncells = clus->GetNCells();
534  Double_t time = clus->GetTOF()*1.e9;
535  if(time>400) time-=fConstantTimeShift;
536 
537  Float_t deta = clus->GetTrackDz();
538  Float_t dphi = clus->GetTrackDx();
539 
540  //if(clus->GetNCells()==1 && clus->E() > 4)printf("TCard E %f, NCells %d\n",energy,clus->GetNCells());
541 
542  if(fStudyExotic)
543  {
544  if ( ncells == 1 )
545  {
546  if(energy >= 5 && energy < 8)
547  fhColRowExoticLowE1Cell [matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
548  else if(energy >= 8)
549  {
550  fhColRowExoticHighE1Cell[matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
551 
552  if ( time > 5) fhColRowExoticHighE1CellPosTime->Fill(icolAbs,irowAbs,GetEventWeight());
553  else if( time < -5) fhColRowExoticHighE1CellNegTime->Fill(icolAbs,irowAbs,GetEventWeight());
554  else fhColRowExoticHighE1CellNulTime->Fill(icolAbs,irowAbs,GetEventWeight());
555  }
556 
557  fhEnergyTime1Cell[matched]->Fill(energy,time,GetEventWeight());
558  fhEnergyTMEtaResidual1Cell->Fill(energy,deta,GetEventWeight());
559  fhEnergyTMPhiResidual1Cell->Fill(energy,dphi,GetEventWeight());
560  }
561  else if(exoticity > 0.97)
562  {
563  if(energy >= 5 && energy < 8)
564  fhColRowExoticLowE [matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
565  else if(energy >= 8)
566  {
567  fhColRowExoticHighE[matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
568 
569  if ( time > 5) fhColRowExoticHighEPosTime->Fill(icolAbs,irowAbs,GetEventWeight());
570  else if( time < -5) fhColRowExoticHighENegTime->Fill(icolAbs,irowAbs,GetEventWeight());
571  else fhColRowExoticHighENulTime->Fill(icolAbs,irowAbs,GetEventWeight());
572  }
573 
574  fhEnergyTimeExotic[matched]->Fill(energy,time,GetEventWeight());
575  fhEnergyTMEtaResidualExotic->Fill(energy,deta,GetEventWeight());
576  fhEnergyTMPhiResidualExotic->Fill(energy,dphi,GetEventWeight());
577 
578  for (Int_t ipos = 0; ipos < ncells; ipos++)
579  {
580  Int_t absId = clus->GetCellsAbsId()[ipos];
581 
582  Float_t eCell = fCaloCellList->GetCellAmplitude(absId);
584 
585  // consider cells with enough energy weight and not the reference one
586  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(eCell, energy);
587 
588  if( absId == absIdMax || weight < 0.01 ) continue;
589 
590  Int_t rowDiff = -100, colDiff = -100;
591  Bool_t sameTCard = GetCaloUtils()->IsAbsIDsFromTCard(absIdMax,absId,rowDiff,colDiff);
592 
593  // Get the col and row of the secondary cluster cell
594  Int_t icol2 = -1, irow2 = -1, iRCU2 = -1, icolAbs2 = -1, irowAbs2 = -1;
595  GetModuleNumberCellIndexesAbsCaloMap(absId,GetCalorimeter(), icol2, irow2, iRCU2, icolAbs2, irowAbs2);
596 
597  if ( !sameTCard )
598  {
599  if(energy >= 5 && energy < 8)
600  fhColRowExotic2ndCellDiffLowE [matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
601  else if(energy >= 8)
602  fhColRowExotic2ndCellDiffHighE[matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
603  }
604  else
605  {
606  if(energy >= 5 && energy < 8)
607  fhColRowExotic2ndCellSameLowE [matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
608  else if(energy >= 8)
609  fhColRowExotic2ndCellSameHighE[matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
610  }
611  }
612 
613  }
614  else if ( energy > 8 )
615  {
616  if ( time > 5) fhColRowHighEPosTime->Fill(icolAbs,irowAbs,GetEventWeight());
617  else if( time < -5) fhColRowHighENegTime->Fill(icolAbs,irowAbs,GetEventWeight());
618  else fhColRowHighENulTime->Fill(icolAbs,irowAbs,GetEventWeight());
619  }
620 
621  if(ebin > -1)
622  {
623  fhTMPhiResidualExoticityLooseCut[ebin]->Fill(exoticity,dphi);
624  fhTMEtaResidualExoticityLooseCut[ebin]->Fill(exoticity,deta);
625  }
626  }
627  else if ( energy > 8 && ncells > 1 && exoticity < 0.97)
628  {
629  if ( time > 5) fhColRowHighEPosTime->Fill(icolAbs,irowAbs,GetEventWeight());
630  else if( time < -5) fhColRowHighENegTime->Fill(icolAbs,irowAbs,GetEventWeight());
631  else fhColRowHighENulTime->Fill(icolAbs,irowAbs,GetEventWeight());
632  }
633 
634  // Clean the sample
635 
636  // in center of SM
637  Int_t etaRegion = -1, phiRegion = -1;
638  GetCaloUtils()->GetEMCALSubregion(clus,fCaloCellList,etaRegion,phiRegion);
639  // Region 0: center of SM ~0.18<|eta|<0.55
640  if ( etaRegion !=0 ) return ;
641 
642  if(fStudyExotic)
643  {
644  if ( ncells == 1 )
645  {
646  fhEnergyTimeTCardCorrNoSelection1Cell[matched]->Fill(energy,time,GetEventWeight());
649  }
650  else if(exoticity > 0.97)
651  {
652  fhEnergyTimeTCardCorrNoSelectionExotic[matched]->Fill(energy,time,GetEventWeight());
655  }
656  }
657 
658  Float_t m02 = clus->GetM02();
659  Float_t m20 = clus->GetM20();
660  Float_t lamR = 0;
661  if ( m02 > 0.001 ) lamR = m20/m02;
662 
663  Int_t absIdList[ncells];
664  Float_t maxEList [ncells];
665  Int_t nlm = GetCaloUtils()->GetNumberOfLocalMaxima(clus, fCaloCellList, absIdList, maxEList) ;
666 //Int_t nlm = GetCaloUtils()->GetNumberOfLocalMaxima(clus,fCaloCellList);
667 
668  //
669  // Correlation to max
670  //
671  Int_t nCellWithWeight = 1;
672  Bool_t nearRow = kFALSE;
673  Bool_t nearCol = kFALSE;
674  Int_t nCorr = 0;
675  Int_t nCorrNo = 0;
676  Int_t sameCol = 0;
677  Int_t other = 0;
678  Int_t sameRow = 0;
679  Float_t eCellMax = fCaloCellList->GetCellAmplitude(absIdMax);
680  //printf("Org E %2.2f, t %2.2f\n",eCellMax,tCellMax*1e9);
681  GetCaloUtils()->RecalibrateCellAmplitude(eCellMax, GetCalorimeter(), absIdMax);
682  //printf("New E %2.2f, t %2.2f\n",eCellMax,tCellMax*1e9);
683 
684  Double_t tCellMax = -1000;
685  if( fStudyTimeCellHisto )
686  {
687  tCellMax = fCaloCellList->GetCellTime(absIdMax);
688 
689  GetCaloUtils()->RecalibrateCellTime(tCellMax, GetCalorimeter(), absIdMax, GetReader()->GetInputEvent()->GetBunchCrossNumber());
690  tCellMax *= 1.0e9;
691  if(tCellMax>400) tCellMax-=fConstantTimeShift;
692  }
693 
694  // correlation not max cells
695 // Int_t nCorr2 = 0;
696 // Int_t sameCol2 = 0;
697 // Int_t other2 = 0;
698 // Int_t sameRow2 = 0;
699 
700  // Get second highest energy cell
701 // Int_t absId2ndMax = -1;
702  Float_t emax2nd = 0;
703  Bool_t sameTCard2ndMax = kFALSE;
704 //Int_t rowDiff2 = -100;
705 //Int_t colDiff2 = -100;
706 
707  Float_t eCellSameRowSameTCardNearCol = 0.;
708  Float_t eCellSameRowDiffTCardNearCol = 0.;
709  Double_t tCellSameRowSameTCardNearCol = 0.;
710  Double_t tCellSameRowDiffTCardNearCol = 0.;
711 
712  //printf("Cluster E %2.2f, ncells %d, absIdMax %d, eCell Max %2.2f\n", energy, ncells, absIdMax, fCaloCellList->GetCellAmplitude(absIdMax));
713 
714  //
715  // Loop on the cluster cells, define correlations
716  //
717  for (Int_t ipos = 0; ipos < ncells; ipos++)
718  {
719  Int_t absId = clus->GetCellsAbsId()[ipos];
720 
721  Float_t eCell = fCaloCellList->GetCellAmplitude(absId);
723 
724  Double_t tCell = 0;
726  {
727  tCell = fCaloCellList->GetCellTime(absId);
728  GetCaloUtils()->RecalibrateCellTime(tCell, GetCalorimeter(), absId, GetReader()->GetInputEvent()->GetBunchCrossNumber());
729  tCell *= 1.0e9;
730  if(tCell>400) tCell-=fConstantTimeShift;
731  }
732 
733  // consider cells with enough energy weight and not the reference one
734  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(eCell, energy);
735 
736  if( absId == absIdMax || weight < 0.01 ) continue;
737 
739  {
740  if (nlm==1)
741  {
742  fhECellClusRatNLM1TCardCorrNoSelection[matched]->Fill(energy, eCell/energy, GetEventWeight());
743  fhLogECellNLM1TCardCorrNoSelection [matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
744  fhECellWeightNLM1TCardCorrNoSelection [matched]->Fill(energy, weight, GetEventWeight());
745  }
746  else if(nlm==2)
747  {
748  fhECellClusRatNLM2TCardCorrNoSelection[matched]->Fill(energy, eCell/energy, GetEventWeight());
749  fhLogECellNLM2TCardCorrNoSelection [matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
750  fhECellWeightNLM2TCardCorrNoSelection [matched]->Fill(energy, weight, GetEventWeight());
751  }
752  else
753  {
754  fhECellClusRatNLM3TCardCorrNoSelection[matched]->Fill(energy, eCell/energy, GetEventWeight());
755  fhLogECellNLM3TCardCorrNoSelection [matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
756  fhECellWeightNLM3TCardCorrNoSelection [matched]->Fill(energy, weight, GetEventWeight());
757  }
758  }
759 
760  Int_t rowDiff = -100, colDiff = -100;
761  Bool_t sameTCard = GetCaloUtils()->IsAbsIDsFromTCard(absIdMax,absId,rowDiff,colDiff);
762 
763  if ( sameTCard && fFillNLocMaxHistos )
764  {
765  if (nlm==1)
766  {
767  fhECellSameClusRatNLM1TCardCorrNoSelection[matched]->Fill(energy, eCell/energy, GetEventWeight());
768  fhLogECellSameNLM1TCardCorrNoSelection [matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
769  fhECellSameWeightNLM1TCardCorrNoSelection [matched]->Fill(energy, weight, GetEventWeight());
770  }
771  else if(nlm==2)
772  {
773  fhECellSameClusRatNLM2TCardCorrNoSelection[matched]->Fill(energy, eCell/energy, GetEventWeight());
774  fhLogECellSameNLM2TCardCorrNoSelection [matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
775  fhECellSameWeightNLM2TCardCorrNoSelection [matched]->Fill(energy, weight, GetEventWeight());
776  }
777  else
778  {
779  fhECellSameClusRatNLM3TCardCorrNoSelection[matched]->Fill(energy, eCell/energy, GetEventWeight());
780  fhLogECellSameNLM3TCardCorrNoSelection [matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
781  fhECellSameWeightNLM3TCardCorrNoSelection [matched]->Fill(energy, weight, GetEventWeight());
782  }
783  }
784 
785  //if(eCellMax < eCell) printf("Check: E max %f (id %d), E sec %f (id %d)\n",eCellMax,absIdMax, eCell,absId);
786 
787  nCellWithWeight++;
788 
789  //printf("\t cell %d, absId %d, E %2.2f, w %2.2f, tcard %d\n", ipos, absId, eCell, weight, sameTCard);
790 
791  Int_t indexType = -1;
792  if ( sameTCard )
793  {
794  nCorr++;
795 
796  if(TMath::Abs(rowDiff) == 1) nearRow = kTRUE;
797  if(TMath::Abs(colDiff) == 1) nearCol = kTRUE;
798 
799  if ( rowDiff == 0 && colDiff != 0 )
800  {
801  if ( nearCol ) indexType = 6;
802  else indexType = 7;
803 
804  sameRow++;
805  /*printf("\t \t E %2.2f, Same row, diff row %d, col %d\n",eCell,rowDiff,colDiff);*/
806  }
807  else if ( rowDiff != 0 && colDiff == 0 )
808  {
809  if ( nearRow ) indexType = 8;
810  else indexType = 9;
811 
812  sameCol++;
813  /*printf("\t \t E %2.2f, Same col, diff row %d, col %d\n",eCell,rowDiff,colDiff);*/
814  }
815  else
816  {
817  if ( nearRow && nearCol) indexType = 10;
818  else indexType = 11;
819 
820  other++;
821  /*printf("\t \t E %2.2f, Diff row/col, diff row %d, col %d\n",eCell,rowDiff,colDiff);*/
822  }
823  }
824  else
825  {
826  nCorrNo++;
827 
828  if ( rowDiff == 0 && colDiff != 0 )
829  {
830  if ( nearCol ) indexType = 0;
831  else indexType = 1;
832 
833  }
834  else if ( rowDiff != 0 && colDiff == 0 )
835  {
836  if ( nearRow ) indexType = 2;
837  else indexType = 3;
838  }
839  else
840  {
841  if ( nearCol && nearRow ) indexType = 4;
842  else indexType = 5;
843  }
844  }
845 
846  if ( rowDiff == 0 && TMath::Abs(colDiff) == 1 )
847  {
848  if(sameTCard)
849  {
850  eCellSameRowSameTCardNearCol = eCell;
851  tCellSameRowSameTCardNearCol = tCell;
852  }
853  else
854  {
855  eCellSameRowDiffTCardNearCol = eCell;
856  tCellSameRowDiffTCardNearCol = tCell;
857  }
858  }
859 
860  if( indexType >=0 )
861  {
862  Float_t eCellDiff = eCellMax - eCell;
863  Float_t eClusDiff = energy - eCell;
864 // Float_t eCellRat = eCell / eCellMax;
865 // Float_t eClusRat = eCell / energy ;
866  Float_t tCellDiff = tCellMax - tCell;
867 
868  fhTCardCorrECellMaxDiff[indexType][matched]->Fill(energy, eCellDiff, GetEventWeight());
869  fhTCardCorrEClusterDiff[indexType][matched]->Fill(energy, eClusDiff, GetEventWeight());
870 // fhTCardCorrECellMaxRat [indexType][matched]->Fill(energy, eCellRat , GetEventWeight());
871 // fhTCardCorrEClusterRat [indexType][matched]->Fill(energy, eClusRat , GetEventWeight());
872  fhTCardCorrTCellMaxDiff[indexType][matched]->Fill(energy, tCellDiff, GetEventWeight());
873 
874  if ( fStudyExotic && exoticity > 0.97 )
875  {
876  fhTCardCorrECellMaxDiffExo[indexType][matched]->Fill(energy, eCellDiff, GetEventWeight());
877  fhTCardCorrEClusterDiffExo[indexType][matched]->Fill(energy, eClusDiff, GetEventWeight());
878 // fhTCardCorrECellMaxRatExo [indexType][matched]->Fill(energy, eCellRat , GetEventWeight());
879 // fhTCardCorrEClusterRatExo [indexType][matched]->Fill(energy, eClusRat , GetEventWeight());
880  fhTCardCorrTCellMaxDiffExo[indexType][matched]->Fill(energy, tCellDiff, GetEventWeight());
881  }
882  }
883 
884  if ( fStudyExotic && exoticity > 0.97 )
885  {
886  // Get the col and row of the secondary cluster cell
887  Int_t icol2 = -1, irow2 = -1, iRCU2 = -1, icolAbs2 = -1, irowAbs2 = -1;
888  GetModuleNumberCellIndexesAbsCaloMap(absId,GetCalorimeter(), icol2, irow2, iRCU2, icolAbs2, irowAbs2);
889 
890  if ( !sameTCard )
891  {
892  if(energy >= 5 && energy < 8)
893  fhColRowTCardCorrNoSelectionExotic2ndCellDiffLowE [matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
894  else if(energy >= 8)
895  fhColRowTCardCorrNoSelectionExotic2ndCellDiffHighE[matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
896  }
897  else
898  {
899  if(energy >= 5 && energy < 8)
900  fhColRowTCardCorrNoSelectionExotic2ndCellSameLowE [matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
901  else if(energy >= 8)
902  fhColRowTCardCorrNoSelectionExotic2ndCellSameHighE[matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
903  }
904  }
905 
906  if ( eCell > emax2nd )
907  {
908  emax2nd = eCell;
909 // absId2ndMax = absId;
910  if(sameTCard)
911  {
912  sameTCard2ndMax = kTRUE;
913 // rowDiff2 = rowDiff;
914 // colDiff2 = colDiff;
915  }
916  else
917  {
918  sameTCard2ndMax = kFALSE;
919 // rowDiff2 = -100;
920 // colDiff2 = -100;
921  }
922  }
923 
924 // //
925 // // Other TCard correlations
926 // //
927 // if ( sameTCard ) continue;
928 //
929 // for (Int_t ipos2 = 0; ipos2 < ncells; ipos2++)
930 // {
931 // Int_t absId2 = clus->GetCellsAbsId()[ipos2];
932 //
933 // eCell = fCaloCellList->GetCellAmplitude(absId2);
934 // // consider cells with enough energy weight and not the reference one
935 // weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(eCell, energy);
936 //
937 // if( absId2 == absIdMax || absId2 == absId || weight < 0.01 ) continue;
938 //
939 // rowDiff = -100, colDiff = -100;
940 // Bool_t sameTCard2 = GetCaloUtils()->IsAbsIDsFromTCard(absId,absId2,rowDiff,colDiff);
941 //
942 // if(sameTCard2)
943 // {
944 // nCorr2++;
945 // if ( rowDiff == 0 && colDiff != 0 ) sameRow2++;
946 // else if ( rowDiff != 0 && colDiff == 0 ) sameCol2++;
947 // else other2++;
948 // }
949 // //printf("\t cell %d, absId %d, E %2.2f, w %2.2f, tcard %d\n", ipos, absId, eCell, weight, sameTCard);
950 // } // second cluster cell lopp for secondary TCard correlations
951  } // cluster cell loop
952 
953  Float_t ratioNcells = nCellWithWeight/(ncells*1.);
954  fhNCellsTCardCorrRatioWithWeightNoSelection[matched]->Fill(energy, ratioNcells, GetEventWeight());
955  //printf("E %2.2f, ncells %d, nCellWithWeight %d, ratio %2.2f\n",energy,ncells,nCellWithWeight,ratioNcells);
956 
957  // If only one relevant cell, it makes no sense to continue
958  if ( nCellWithWeight <= 1 ) return;
959 
960  // It should not happen, unless very exotic clusters
961  if ( m02 < 0.001 )
962  {
963  printf("AliAnaClusterShapeCorrelStudies: M02 %f, M20 %f, E %2.3f, ncell %d, n with weight %d; max cell E %2.3f\n",
964  m02,m20,energy,ncells,nCellWithWeight,eCellMax);
965  }
966 
967  //printf("\t Same col %d, same row %d, diff other %d\n",sameCol,sameRow,other);
968  //printf("\t Second cell: E %2.2f, absId %d, correl %d, rowDiff %d, rowCol %d\n",emax,absId2ndMax,sameTCard2,rowDiff2, colDiff2);
969 
970  //
971  // Fill histograms for different cell correlation criteria
972  //
973  if(energy >= 5 && energy < 8)
974  fhColRowTCardCorrNoSelectionLowE [matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
975  else if(energy >= 8)
976  fhColRowTCardCorrNoSelectionHighE[matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
977 
978  if ( fStudyExotic && exoticity > 0.97 )
979  {
980  if(energy >= 5 && energy < 8)
981  fhColRowTCardCorrNoSelectionExoticLowE [matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
982  else if(energy >= 8)
983  fhColRowTCardCorrNoSelectionExoticHighE[matched]->Fill(icolAbs,irowAbs,GetEventWeight()) ;
984  }
985 
986  fhTimeTCardCorrNoSelection [matched]->Fill(energy,time, GetEventWeight());
987  fhLambda0TCardCorrNoSelection[matched]->Fill(energy, m02, GetEventWeight());
988  fhLambda1TCardCorrNoSelection[matched]->Fill(energy, m20, GetEventWeight());
989 
990  fhLambdaRTCardCorrNoSelection[matched]->Fill(energy,lamR, GetEventWeight());
991  fhExoticTCardCorrNoSelection [matched]->Fill(energy, exoticity, GetEventWeight());
992 
993  if ( fFillNLocMaxHistos )
994  {
995  fhNLocMaxTCardCorrNoSelection[matched]->Fill(energy, nlm, GetEventWeight());
996 
997  if ( nlm == 1 )
998  {
999  fhLambda0NLM1TCardCorrNoSelection[matched]->Fill(energy, m02, GetEventWeight());
1000  fhLambda1NLM1TCardCorrNoSelection[matched]->Fill(energy, m20, GetEventWeight());
1001 
1002  fhEMaxRatNLM1TCardCorrNoSelection [matched]->Fill(energy, eCellMax/energy , GetEventWeight());
1003  fhE2ndRatNLM1TCardCorrNoSelection [matched]->Fill(energy, emax2nd/energy , GetEventWeight());
1004  fhE2ndEMaxRatNLM1TCardCorrNoSelection[matched]->Fill(energy, emax2nd/eCellMax, GetEventWeight());
1005  }
1006  else if ( nlm==2 )
1007  {
1008  fhLambda0NLM2TCardCorrNoSelection[matched]->Fill(energy, m02, GetEventWeight());
1009  fhLambda1NLM2TCardCorrNoSelection[matched]->Fill(energy, m20, GetEventWeight());
1010 
1011  fhEMaxRatNLM2TCardCorrNoSelection [matched]->Fill(energy, eCellMax/energy , GetEventWeight());
1012  fhE2ndRatNLM2TCardCorrNoSelection [matched]->Fill(energy, maxEList[1]/energy , GetEventWeight());
1013  fhE2ndEMaxRatNLM2TCardCorrNoSelection[matched]->Fill(energy, maxEList[1]/eCellMax, GetEventWeight());
1014  }
1015  else
1016  {
1017  fhEMaxRatNLM3TCardCorrNoSelection [matched]->Fill(energy, eCellMax/energy , GetEventWeight());
1018  fhE2ndRatNLM3TCardCorrNoSelection [matched]->Fill(energy, maxEList[1]/energy , GetEventWeight());
1019  fhE2ndEMaxRatNLM3TCardCorrNoSelection[matched]->Fill(energy, maxEList[1]/eCellMax, GetEventWeight());
1020  }
1021 
1022  if ( sameTCard2ndMax )
1023  {
1024  if (nlm==1)
1025  {
1026  fhE2ndSameRatNLM1TCardCorrNoSelection [matched]->Fill(energy, emax2nd/energy , GetEventWeight());
1027  fhE2ndSameEMaxRatNLM1TCardCorrNoSelection[matched]->Fill(energy, emax2nd/eCellMax, GetEventWeight());
1028  }
1029  else if(nlm==2)
1030  {
1031  fhE2ndSameRatNLM2TCardCorrNoSelection [matched]->Fill(energy, maxEList[1]/energy , GetEventWeight());
1032  fhE2ndSameEMaxRatNLM2TCardCorrNoSelection[matched]->Fill(energy, maxEList[1]/eCellMax, GetEventWeight());
1033  }
1034  else
1035  {
1036  fhE2ndSameRatNLM3TCardCorrNoSelection [matched]->Fill(energy, maxEList[1]/energy , GetEventWeight());
1037  fhE2ndSameEMaxRatNLM3TCardCorrNoSelection[matched]->Fill(energy, maxEList[1]/eCellMax, GetEventWeight());
1038  }
1039  } // sameTCard2ndMax
1040  } // NLM histos
1041 
1042  fhNCellsTCardCorrNoSelection [matched]->Fill(energy, ncells, GetEventWeight());
1043  fhNCellsTCardCorrWithWeightNoSelection[matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1044 
1045  if(eCellSameRowSameTCardNearCol > 0 && eCellSameRowDiffTCardNearCol > 0)
1046  {
1047  Float_t eDiff = eCellSameRowSameTCardNearCol - eCellSameRowDiffTCardNearCol ;
1048  Float_t tDiff = tCellSameRowSameTCardNearCol - tCellSameRowDiffTCardNearCol ;
1049 
1050  fhSameRowDiffColAndTCardCellsEnergyDiffClusterE[matched]->Fill(energy , eDiff, GetEventWeight());
1051  fhSameRowDiffColAndTCardCellsTimeDiffClusterE [matched]->Fill(energy , tDiff, GetEventWeight());
1052  fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxE[matched]->Fill(eCellMax, eDiff, GetEventWeight());
1053  fhSameRowDiffColAndTCardCellsTimeDiffCellMaxE [matched]->Fill(eCellMax, tDiff, GetEventWeight());
1054 
1055  if ( fStudyExotic && exoticity > 0.97 )
1056  {
1057  fhSameRowDiffColAndTCardCellsEnergyDiffClusterEExo[matched]->Fill(energy , eDiff, GetEventWeight());
1058  fhSameRowDiffColAndTCardCellsTimeDiffClusterEExo [matched]->Fill(energy , tDiff, GetEventWeight());
1059  fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxEExo[matched]->Fill(eCellMax, eDiff, GetEventWeight());
1060  fhSameRowDiffColAndTCardCellsTimeDiffCellMaxEExo [matched]->Fill(eCellMax, tDiff, GetEventWeight());
1061  }
1062  }
1063 
1065  Int_t nCorrInd = nCorr;
1066  if(nCorr > 4) nCorrInd = 5;
1067 
1068  Int_t nCorrNoInd = nCorrNo;
1069  if(nCorrNoInd > 4) nCorrNoInd = 5;
1070 
1071 // fhLambda0TCardCorrelN[nCorrInd][matched]->Fill(energy, m02, GetEventWeight());
1072 // fhNCellsTCardCorrelN [nCorrInd][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1073 // fhExoticTCardCorrelN [nCorrInd][matched]->Fill(energy, exoticity, GetEventWeight());
1074 //
1075 // if ( energy >= 2 && energy < 8 )
1076 // fhColRowTCardCorrelNLowE [nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1077 // if ( energy >= 8 )
1078 // fhColRowTCardCorrelNHighE[nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1079 
1080  if ( fFillNLocMaxHistos)
1081  {
1082  if ( nlm == 1 )
1083  {
1084  fhLambda0NLM1TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, m02, GetEventWeight());
1085  fhLambda1NLM1TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, m20, GetEventWeight());
1086 
1087  fhEMaxRatNLM1TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, eCellMax/energy , GetEventWeight());
1088  fhE2ndRatNLM1TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, emax2nd/energy , GetEventWeight());
1089  fhE2ndEMaxRatNLM1TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, emax2nd/eCellMax, GetEventWeight());
1090  }
1091  else if( nlm == 2 )
1092  {
1093  fhLambda0NLM2TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, m02, GetEventWeight());
1094  fhLambda1NLM2TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, m20, GetEventWeight());
1095 
1096  fhEMaxRatNLM2TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, eCellMax/energy, GetEventWeight());
1097  fhE2ndRatNLM2TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, maxEList[1]/energy , GetEventWeight());
1098  fhE2ndEMaxRatNLM2TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, maxEList[1]/eCellMax, GetEventWeight());
1099  }
1100  else
1101  {
1102  fhEMaxRatNLM3TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, eCellMax/energy, GetEventWeight());
1103  fhE2ndRatNLM3TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, maxEList[1]/energy , GetEventWeight());
1104  fhE2ndEMaxRatNLM3TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, maxEList[1]/eCellMax, GetEventWeight());
1105  }
1106 
1107  fhNLocMaxTCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, nlm, GetEventWeight());
1108  } // NLM histos
1109 
1110  fhLambda0TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, m02, GetEventWeight());
1111  fhLambda1TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, m20, GetEventWeight());
1112 //fhLambdaRTCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy,lamR, GetEventWeight());
1113 
1114  if(fStudyExotic)
1115  fhExoticTCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, exoticity, GetEventWeight());
1116 
1117  // Time diff in cluster, depending nCells
1118  for (Int_t ipos = 0; ipos < ncells; ipos++)
1119  {
1120  Int_t absId = clus->GetCellsAbsId()[ipos];
1121 
1122  Float_t eCell = fCaloCellList->GetCellAmplitude(absId);
1124 
1125  Double_t tCell = 0;
1126 
1127  if ( fStudyTimeCellHisto )
1128  {
1129  tCell = fCaloCellList->GetCellTime(absId);
1130 
1131  GetCaloUtils()->RecalibrateCellTime(tCell, GetCalorimeter(), absId, GetReader()->GetInputEvent()->GetBunchCrossNumber());
1132  tCell *= 1.0e9;
1133  if(tCell>400) tCell-=fConstantTimeShift;
1134  }
1135 
1136  // consider cells with enough energy weight and not the reference one
1137  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(eCell, energy);
1138 
1139  if( absId == absIdMax || weight < 0.01 ) continue;
1140 
1141  Float_t tDiffMaxSecondary = tCellMax - tCell;
1142  //printf("Time max %f, second %f, diff %f\n",tCellMax,tCell,tDiffMaxSecondary);
1143  fhTimeDiffTCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, tDiffMaxSecondary, GetEventWeight());
1144  if ( fStudyExotic && exoticity > 0.97 )
1145  {
1146  fhTimeDiffExoTCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, tDiffMaxSecondary, GetEventWeight());
1147  // Get the col and row of the secondary cluster cell
1148  Int_t icol2 = -1, irow2 = -1, iRCU2 = -1, icolAbs2 = -1, irowAbs2 = -1;
1149  GetModuleNumberCellIndexesAbsCaloMap(absId,GetCalorimeter(), icol2, irow2, iRCU2, icolAbs2, irowAbs2);
1150 
1151  Int_t rowDiff = -100, colDiff = -100;
1152  Bool_t sameTCard = GetCaloUtils()->IsAbsIDsFromTCard(absIdMax,absId,rowDiff,colDiff);
1153 
1154  if ( !sameTCard )
1155  {
1156  if ( energy >= 5 && energy < 8 && nCorr == 0 )
1157  fhColRowTCardCorrNoSelectionExotic2ndCellDiffNoSameLowE [matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
1158  else if ( energy >= 8 && nCorr == 0 )
1159  fhColRowTCardCorrNoSelectionExotic2ndCellDiffNoSameHighE[matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
1160  }
1161  else
1162  {
1163  if ( energy >= 5 && energy < 8 && nCorrNo == 0 )
1164  fhColRowTCardCorrNoSelectionExotic2ndCellSameNoDiffLowE [matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
1165  else if ( energy >= 8 && nCorrNo == 0 )
1166  fhColRowTCardCorrNoSelectionExotic2ndCellSameNoDiffHighE[matched]->Fill(icolAbs2,irowAbs2,GetEventWeight()) ;
1167  }
1168  } // exotic
1169 
1170  if ( fFillNLocMaxHistos )
1171  {
1172  if (nlm==1)
1173  {
1174  fhECellClusRatNLM1TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, eCell/energy, GetEventWeight());
1175  fhLogECellNLM1TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
1176  fhECellWeightNLM1TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, weight, GetEventWeight());
1177  }
1178  else if(nlm==2)
1179  {
1180  fhECellClusRatNLM2TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, eCell/energy, GetEventWeight());
1181  fhLogECellNLM2TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
1182  fhECellWeightNLM2TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, weight, GetEventWeight());
1183  }
1184  else
1185  {
1186  fhECellClusRatNLM3TCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, eCell/energy, GetEventWeight());
1187  fhLogECellNLM3TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, TMath::Log(eCell), GetEventWeight());
1188  fhECellWeightNLM3TCardCorrelNCell [nCorrInd][nCorrNoInd][matched]->Fill(energy, weight, GetEventWeight());
1189  }
1190  } // NLM histos
1191 
1192  } //cell loop
1193 
1194  // Invariant mass for clusters looking like photons, depending number of cells
1195  if ( fStudyInvMass && m02 > fInvMassMinM02Cut && m02 < fInvMassMaxM02Cut )
1196  {
1197  for(Int_t jclus = 0 ; jclus < fCaloClusList->GetEntriesFast() ; jclus++)
1198  {
1199  AliVCluster* clus2 = (AliVCluster*) fCaloClusList->At(jclus);
1200 
1201  Float_t maxCellFraction = 0.;
1202  Int_t absIdMax2 = GetCaloUtils()->GetMaxEnergyCell(fCaloCellList, clus2, maxCellFraction);
1203 
1204  Double_t tof2 = clus2->GetTOF()*1.e9;
1205  if(tof2>400) tof2-=fConstantTimeShift;
1206 
1207  Double_t diffTof = tCellMax-tof2;
1208 
1209  // Try to reduce background with a mild shower shape cut and no more
1210  // than 1 local maximum in cluster and remove low energy clusters
1211 
1212  if( absIdMax == absIdMax2
1213  || !IsGoodCluster(absIdMax2, clus2->GetM02(), clus2->GetNCells())
1215  || clus2->GetM02() > fInvMassMaxM02Cut
1216  || clus2->GetM02() < fInvMassMinM02Cut
1217  || clus2->E() < fInvMassMinECut
1218  || clus2->E() > fInvMassMaxECut
1219  || TMath::Abs(diffTof) > fInvMassMaxTimeDifference
1220  ) continue;
1221 
1222  // Get cluster kinematics
1223  Double_t v[3] = {0,0,0}; //vertex ;
1224  clus2->GetMomentum(fClusterMomentum2,v);
1225 
1226  // Check only certain regions
1227  Bool_t in2 = kTRUE;
1229  if(!in2) continue;
1230 
1231  //Float_t pairE = (fClusterMomentum+fClusterMomentum2).E();
1232 
1233  // Opening angle cut, avoid combination of DCal and EMCal clusters
1234  Double_t angle = fClusterMomentum.Angle(fClusterMomentum2.Vect());
1235 
1236  if( angle > fInvMassMaxOpenAngle ) continue;
1237 
1238  // Fill histograms
1240  fhMassEClusTCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(energy, mass, GetEventWeight());
1241  //fhMassEPairTCardCorrelNCell[nCorrInd][nCorrNoInd][matched]->Fill(pairE , mass, GetEventWeight());
1242  }
1243  }
1244 
1245  if ( energy >= 5 && energy < 8)
1246  fhColRowTCardCorrelNCellLowE [nCorrInd][nCorrNoInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1247  else if ( energy >= 8 )
1248  fhColRowTCardCorrelNCellHighE[nCorrInd][nCorrNoInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1249 
1250 // if(nCorrNo == 0)
1251 // {
1252 // fhLambda0TCardCorrelNAllSameTCard[nCorrInd][matched]->Fill(energy, m02, GetEventWeight());
1253 // fhNCellsTCardCorrelNAllSameTCard [nCorrInd][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1254 // fhExoticTCardCorrelNAllSameTCard [nCorrInd][matched]->Fill(energy, exoticity, GetEventWeight());
1255 // if ( energy >= 2 && energy < 8 )
1256 // fhColRowTCardCorrelNAllSameTCardLowE[nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1257 // else if ( energy >= 8 )
1258 // fhColRowTCardCorrelNAllSameTCardHighE[nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1259 // }
1260 
1262 
1263  if ( fStudyExotic && exoticity > 0.97 )
1264  {
1265  if ( energy >= 5 && energy < 8)
1266  fhColRowTCardCorrelNCellExoticLowE [nCorrInd][nCorrNoInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1267  else if ( energy >= 8 )
1268  fhColRowTCardCorrelNCellExoticHighE[nCorrInd][nCorrNoInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1269 
1270 // fhLambda0TCardCorrelNExotic[nCorrInd][matched]->Fill(energy, m02, GetEventWeight());
1271 // fhNCellsTCardCorrelNExotic [nCorrInd][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1272 //
1273 // if ( energy > 5 && energy <= 8 )
1274 // fhColRowTCardCorrelNLowEExotic [nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1275 // if ( energy > 8 )
1276 // fhColRowTCardCorrelNHighEExotic[nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1277 //
1278 // if(nCorrNo == 0)
1279 // {
1280 // fhLambda0TCardCorrelNAllSameTCardExotic[nCorrInd][matched]->Fill(energy, m02, GetEventWeight());
1281 // fhNCellsTCardCorrelNAllSameTCardExotic [nCorrInd][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1282 //
1283 // if ( energy > 2 && energy <=8 )
1284 // fhColRowTCardCorrelNAllSameTCardLowEExotic [nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1285 // if ( energy > 8 )
1286 // fhColRowTCardCorrelNAllSameTCardHighEExotic[nCorrInd][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1287 // }
1288 //
1289 // Int_t indexExo = -1;
1290 // if (!nearRow && nearCol ) indexExo = 0;
1291 // else if (!nearRow && !nearCol ) indexExo = 1;
1292 // else if ( nearRow && nearCol ) indexExo = 2;
1293 // else if ( nearRow && !nearCol ) indexExo = 3;
1294 //
1295 // if(indexExo >= 0)
1296 // {
1297 // fhLambda0TCardCorrelExotic[indexExo][matched]->Fill(energy, m02, GetEventWeight());
1298 // fhNCellsTCardCorrelExotic [indexExo][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1299 // }
1300  }
1301 
1302 
1303  if( ebin > -1 )
1304  {
1305  fhLambda0Lambda1 [ebin][matched]->Fill(m20, m02, GetEventWeight());
1306  fhNCellsTCardSameAndDiff[ebin][matched]->Fill(nCorrNo, nCorr, GetEventWeight());
1307  // if(nCorrNo == 0)
1308  // fhLambda0Lambda1AllSameTCard [ebin][matched]->Fill(m20, m02, GetEventWeight());
1309 
1310  if(fStudyExotic)
1311  {
1312  fhLambda0Exoticity[ebin][matched]->Fill(exoticity, m02, GetEventWeight());
1313  fhLambda1Exoticity[ebin][matched]->Fill(exoticity, m20, GetEventWeight());
1314  //fhLambdaRExoticity[ebin][matched]->Fill(exoticity,lamR, GetEventWeight());
1315  fhNCellsExoticity [ebin][matched]->Fill(exoticity, nCellWithWeight, GetEventWeight());
1316  fhTimeExoticity [ebin][matched]->Fill(exoticity, tCellMax, GetEventWeight());
1317 
1318  if(energy > 8)
1319  {
1320  fhLambda0ExoticityPerNCell[nCorrInd][nCorrNoInd][matched]->Fill(exoticity, m02, GetEventWeight());
1321  fhLambda1ExoticityPerNCell[nCorrInd][nCorrNoInd][matched]->Fill(exoticity, m20, GetEventWeight());
1322  //fhLambdaRExoticityPerNCell[nCorrInd][nCorrNoInd][matched]->Fill(exoticity,lamR, GetEventWeight());
1323  }
1324 
1325  // if(nCorrNo == 0)
1326  // {
1327  // fhLambda0ExoticityAllSameTCard[ebin][matched]->Fill(exoticity, m02, GetEventWeight());
1328  // fhLambda1ExoticityAllSameTCard[ebin][matched]->Fill(exoticity, m20, GetEventWeight());
1329  // fhLambdaRExoticityAllSameTCard[ebin][matched]->Fill(exoticity,lamR, GetEventWeight());
1330  // fhNCellsExoticityAllSameTCard [ebin][matched]->Fill(exoticity, nCellWithWeight, GetEventWeight());
1331  // }
1332 
1333  if ( exoticity > 0.97 )
1334  fhNCellsTCardSameAndDiffExotic[ebin][matched]->Fill(nCorrNo, nCorr, GetEventWeight());
1335 
1336  // Track matching residuals
1337  fhTMPhiResidualExoticity[ebin]->Fill(exoticity,dphi);
1338  fhTMEtaResidualExoticity[ebin]->Fill(exoticity,deta);
1339 
1340  // if(nCorrNo==0)
1341  // {
1342  // fhTMPhiResidualExoticityAllSameTCard[ebin]->Fill(exoticity,dphi);
1343  // fhTMEtaResidualExoticityAllSameTCard[ebin]->Fill(exoticity,deta);
1344  // }
1345  }
1346  }
1347 
1348  Float_t nCellRat = nCorr*1. / ((nCorr+nCorrNo)*1.);
1349  fhNCellsTCardSameAndDiffFraction[matched]->Fill(energy, nCellRat, GetEventWeight());
1350  if ( fStudyExotic && exoticity > 0.97 )
1351  fhNCellsTCardSameAndDiffFractionExotic[matched]->Fill(energy, nCellRat, GetEventWeight());
1352 
1353 // if(nCorr > 0)
1354 // {
1355 // Int_t index = -1;
1356 // if (!sameRow && sameCol && !other ) index = 0;
1357 // else if (!sameRow && !sameCol && other ) index = 1;
1358 // else if (!sameRow && sameCol && other ) index = 2;
1359 // else if ( sameRow && sameCol && !other ) index = 3;
1360 // else if ( sameRow && !sameCol && other ) index = 4;
1361 // else if ( sameRow && sameCol && other ) index = 5;
1362 // else if ( sameRow && !sameCol && !other ) index = 6;
1363 // else printf("case not considered: sameRow %d, sameCol %d, other %d, nearRow %d\n",sameRow,sameCol,other,nearRow);
1364 //
1365 // if(index >= 0)
1366 // {
1367 // fhLambda0TCardCorrel[index][matched]->Fill(energy, m02, GetEventWeight());
1368 // fhNCellsTCardCorrel [index][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1369 // fhExoticTCardCorrel [index][matched]->Fill(energy, exoticity, GetEventWeight());
1370 // }
1371 //
1372 // // Comment out, no special effect observed
1373 // Int_t indexNR = -1;
1374 // if ( nearRow )
1375 // {
1376 // if (!sameRow && sameCol && !other ) indexNR = 0;
1377 // else if (!sameRow && !sameCol && other ) indexNR = 1;
1378 // else if (!sameRow && sameCol && other ) indexNR = 2;
1379 // else if ( sameRow && sameCol && !other ) indexNR = 3;
1380 // else if ( sameRow && !sameCol && other ) indexNR = 4;
1381 // else if ( sameRow && sameCol && other ) indexNR = 5;
1382 // else printf("\t near row case not considered!: sameRow %d, sameCol %d, other %d\n",sameRow,sameCol,other);
1383 // }
1384 //
1385 // if ( indexNR >= 0 )
1386 // {
1387 // fhLambda0TCardCorrelNearRow[indexNR][matched]->Fill(energy, m02, GetEventWeight());
1388 // fhNCellsTCardCorrelNearRow [indexNR][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1389 // }
1390 //
1391 // if ( sameTCard2ndMax )
1392 // {
1393 // Int_t index2nd = -1;
1394 // if ( TMath::Abs(rowDiff2) == 1 && TMath::Abs(colDiff2) != 1 ) index2nd = 0;
1395 // else if( TMath::Abs(rowDiff2) != 1 && TMath::Abs(colDiff2) == 1 ) index2nd = 1;
1396 // else if( TMath::Abs(rowDiff2) == 1 && TMath::Abs(colDiff2) == 1 ) index2nd = 2;
1397 // else index2nd = 3;
1398 //
1399 // fhLambda0TCardCorrel2ndMax[index2nd][matched]->Fill(energy, m02, GetEventWeight());
1400 // fhNCellsTCardCorrel2ndMax [index2nd][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1401 // }
1402 // }
1403 //
1404 // Int_t indexOtherTCard = -1;
1405 // if ( nCorr == 0 && nCorr2 == 0 ) indexOtherTCard = 6;
1406 // else if ( nCorr == 0 && nCorr2 > 0 )
1407 // {
1408 // if ( sameRow2 && !sameCol2 && !other2) indexOtherTCard = 0;
1409 // else if ( !sameRow2 && sameCol2 && !other2) indexOtherTCard = 1;
1410 // else indexOtherTCard = 2;
1411 // }
1412 // else if ( nCorr > 0 && nCorr2 > 0 )
1413 // {
1414 // if ( sameRow2 && !sameCol2 && !other2) indexOtherTCard = 3;
1415 // else if ( !sameRow2 && sameCol2 && !other2) indexOtherTCard = 4;
1416 // else indexOtherTCard = 5;
1417 // }
1418 //
1419 // if ( indexOtherTCard >= 0 )
1420 // {
1421 // fhLambda0TCardCorrelOtherTCard[indexOtherTCard][matched]->Fill(energy, m02, GetEventWeight());
1422 // fhNCellsTCardCorrelOtherTCard [indexOtherTCard][matched]->Fill(energy, nCellWithWeight, GetEventWeight());
1423 // fhExoticTCardCorrelOtherTCard [indexOtherTCard][matched]->Fill(energy, exoticity, GetEventWeight());
1424 // if ( energy >= 2 && energy < 8 )
1425 // fhColRowTCardCorrelOtherTCardLowE[indexOtherTCard][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1426 // else if ( energy >= 8 )
1427 // fhColRowTCardCorrelOtherTCardHighE[indexOtherTCard][matched]->Fill(icolAbs, irowAbs, GetEventWeight());
1428 // }
1429 }
1430 
1431 //__________________________________________________________________________________________________________________
1441 //__________________________________________________________________________________________________________________
1443 (AliVCluster* clus , Int_t absIdMax, Double_t maxFrac ,
1444  Float_t eCrossFrac, Float_t eCellMax, Double_t tmax ,
1445  Int_t matchedPID, Int_t mcIndex, Int_t noverlaps )
1446 {
1447  // By definition a cluster has at least 1 cell,
1448  // and shape only makes sense with at least 2
1449  // in case fNCellMin was open, check again the size
1450  Int_t nCaloCellsPerCluster = clus->GetNCells();
1451  if ( nCaloCellsPerCluster < 2 ) return;
1452 
1453  Float_t energy = clus->E();
1454  Float_t m02 = clus->GetM02();
1455  Float_t m20 = clus->GetM20();
1457 
1458  Int_t nCell = 0;
1459 
1460  Int_t dIeta = 0;
1461  Int_t dIphi = 0;
1462  Int_t dIetaNeg = 0;
1463  Int_t dIphiNeg = 0;
1464  Int_t dIetaPos = 0;
1465  Int_t dIphiPos = 0;
1466 
1467  // Loop on cells in cluster to get number of cells with significant energy
1468  for (Int_t ipos = 0; ipos < nCaloCellsPerCluster; ipos++)
1469  {
1470  Int_t absId = clus ->GetCellsAbsId()[ipos];
1471  Float_t eCell = fCaloCellList->GetCellAmplitude(absId) ;
1472 
1474 
1475  if( absId == absIdMax || eCell < 0.01 ) continue;
1476 
1477  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(eCell, energy);
1478 
1479  if( weight < 0.01 ) continue;
1480 
1481  nCell++;
1482  }
1483 
1484  if ( nCell < 1 ) return;
1485 
1486  // For histograms classified in bins depending number of cells
1487  Int_t nCellBin = -1;
1488  for(Int_t ic = 0; ic < fNCellsBins; ic++)
1489  {
1490  if ( nCell >= fNCellsBinsLimits[ic] && nCell < fNCellsBinsLimits[ic+1] )
1491  {
1492  nCellBin = ic;
1493  break;
1494  }
1495  }
1496 
1497  //printf("nCell %d, bin %d\n",nCell,nCellBin);
1498 
1499  //
1500  // Cluster location
1501  //
1502  Int_t ietaMax=-1, iphiMax = 0, rcuMax = 0, icolAbs = -1, irowAbs = -1;
1504  ietaMax, iphiMax, rcuMax, icolAbs, irowAbs);
1505 
1506  Int_t iTowerMax = -1, iIphiMax = -1, iIetaMax = -1;
1507  if ( fStudyModuleCells && GetCalorimeter() == kEMCAL )
1508  GetEMCALGeometry()->GetCellIndex(absIdMax,smMax,iTowerMax,iIphiMax,iIetaMax);
1509 
1510  if ( matchedPID == 0 && energy > fEMinShape && energy < fEMaxShape )
1511  {
1512  fhColRowM02->Fill(icolAbs,irowAbs,m02,GetEventWeight()) ;
1513 
1514  if ( nCell > fNCellMinShape )
1515  fhColRowM02NCellCut->Fill(icolAbs,irowAbs,m02,GetEventWeight()) ;
1516  }
1517  //
1518 
1519  //
1520  // Clean the sample with very strict cut on acceptance, select only
1521  // in center of SM
1522  //
1523  Int_t etaRegion = -1, phiRegion = -1;
1524  GetCaloUtils()->GetEMCALSubregion(clus,fCaloCellList,etaRegion,phiRegion);
1525  // Region 0: center of SM ~0.18<|eta|<0.55
1526  if ( etaRegion !=0 ) return ;
1527 
1528  // Loop on cells in cluster to get cell cluster asymmetry and
1529  // other correlation parameters
1530  Int_t nPerModule = 0;
1531  Int_t nPerModuleOut = 0;
1532  Int_t nPerModuleOutD = 0;
1533  Int_t nPerModuleOutS = 0;
1534  Float_t ePerModule = 0.;
1535  Float_t ePerModuleOut = 0.;
1536  Float_t ePerModuleOutD = 0.;
1537  Float_t ePerModuleOutS = 0.;
1538  for (Int_t ipos = 0; ipos < nCaloCellsPerCluster; ipos++)
1539  {
1540  Int_t absId = clus ->GetCellsAbsId()[ipos];
1541  Float_t eCell = fCaloCellList->GetCellAmplitude(absId) ;
1542 
1544 
1545  if( absId == absIdMax || eCell < 0.01 ) continue;
1546 
1547  Int_t ieta=-1; Int_t iphi = 0; Int_t rcu = 0;
1548  Int_t sm = GetModuleNumberCellIndexes(absId,GetCalorimeter(), ieta, iphi, rcu);
1549 
1550  // Module vs cell max
1551  //
1552  if ( fStudyModuleCells && GetCalorimeter() == kEMCAL )
1553  {
1554  Int_t iTower = -1, iIphi = -1, iIeta = -1;
1555  GetEMCALGeometry()->GetCellIndex(absId,sm,iTower,iIphi,iIeta);
1556 
1557  //printf("Max: SM %d Tower %d, absId %d, amp %2.2f\n",smMax,iTowerMax,absIdMax,eCellMax);
1558 
1559  if ( iTowerMax == iTower )
1560  {
1561  //printf("Secondary: Tower %d, absId %d, amp %2.2f\n",iTower,absId,eCell);
1562  nPerModule++;
1563  ePerModule+=eCell;
1564  }
1565  else
1566  {
1567  //printf("Secondary: Tower %d, absId %d, amp %2.2f\n",iTower,absId,eCell);
1568  nPerModuleOut++;
1569  ePerModuleOut+=eCell;
1570 
1571  if(TMath::Abs(iphiMax-iphi) == 1 || TMath::Abs(ietaMax-ieta) == 1)
1572  {
1573  Int_t rowDiff = -100, colDiff = -100;
1574  Bool_t sameTCard = GetCaloUtils()->IsAbsIDsFromTCard(absIdMax,absId,rowDiff,colDiff);
1575  if(sameTCard)
1576  {
1577  nPerModuleOutS++;
1578  ePerModuleOutS+=eCell;
1579  }
1580  else
1581  {
1582  nPerModuleOutD++;
1583  ePerModuleOutD+=eCell;
1584  }
1585  }
1586  }
1587  }
1588 
1589  // Select only cells with weight
1590  //
1591  Float_t weight = GetCaloUtils()->GetEMCALRecoUtils()->GetCellWeight(eCell, energy);
1592 
1593  if ( weight < 0.01 ) continue;
1594 
1595  Float_t fracCell = eCell/eCellMax;
1596  fhClusterMaxCellCloseCellRatioM02->Fill(energy, fracCell, m02, GetEventWeight());
1597 
1598  Float_t fracClus = (energy-eCell)/energy;
1599 
1600  //Float_t logECell = TMath::Log(eCell);
1601 
1602  //Float_t ampDiff = fCaloCellList->GetCellAmplitude(absIdMax)-fCaloCellList->GetCellAmplitude(absId);
1603  //fhClusterMaxCellCloseCellDiffM02 ->Fill(energy,ampDiff, m02,GetEventWeight());
1604 
1605  //Double_t time = fCaloCellList->GetCellTime(absId);
1606  //GetCaloUtils()->RecalibrateCellTime(time, GetCalorimeter(), absId,GetReader()->GetInputEvent()->GetBunchCrossNumber());
1607  //
1608  //Float_t tdiff = (tmax-(time*1.0e9-fConstantTimeShift));
1609  //fhCellTimeSpreadRespectToCellMaxM02->Fill(energy, tdiff, m02, GetEventWeight());
1610 
1611  if ( energy > fEMinShape && energy < fEMaxShape && matchedPID == 0 )
1612  {
1613  fhESecCellEMaxCellM02NCellPerSM[smMax]->Fill(fracCell, nCell, m02, GetEventWeight());
1614  fhESecCellEClusterM02NCellPerSM[smMax]->Fill(fracClus, nCell, m02, GetEventWeight());
1615  //fhESecCellLogM02NCellPerSM [smMax]->Fill(logECell, nCell, m02, GetEventWeight());
1616 
1617  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1618  {
1619  fhEMaxESecCellNCellLowM02PerSM [smMax]->Fill(eCellMax, eCell , nCell, GetEventWeight());
1620  fhEMaxECrossNCellLowM02PerSM [smMax]->Fill(eCellMax, eCrossFrac, nCell, GetEventWeight());
1621 
1622  if ( fStudyTimeCellHisto )
1623  {
1624  Double_t time = fCaloCellList->GetCellTime(absId);
1625  GetCaloUtils()->RecalibrateCellTime(time, GetCalorimeter(), absId,GetReader()->GetInputEvent()->GetBunchCrossNumber());
1626  time*=1.e9;
1627  if(time>400) time-=fConstantTimeShift;
1628 
1629  fhESecCellTimeNCellSM->Fill(time, smMax, nCell, GetEventWeight());
1630  }
1631  }
1632  else if ( m02 > fM02HighBin[0] && m02 <= fM02HighBin[1] )
1633  {
1634  fhEMaxESecCellNCellHighM02PerSM[smMax]->Fill(eCellMax, eCell , nCell, GetEventWeight());
1635  fhEMaxECrossNCellHighM02PerSM [smMax]->Fill(eCellMax, eCrossFrac, nCell, GetEventWeight());
1636  }
1637  }
1638 
1640  // Cluster asymmetry in cell units
1642  if(fStudyShapeParam)
1643  {
1644  if(dIphi < TMath::Abs(iphi-iphiMax)) dIphi = TMath::Abs(iphi-iphiMax);
1645  if(iphi-iphiMax < 0 && dIphiNeg > iphi-iphiMax) dIphiNeg = iphi-iphiMax;
1646  if(iphi-iphiMax > 0 && dIphiPos < iphi-iphiMax) dIphiPos = iphi-iphiMax;
1647 
1648  if(dIeta < TMath::Abs(ieta-ietaMax)) dIeta = TMath::Abs(ieta-ietaMax);
1649  if(ieta-ietaMax < 0 && dIetaNeg > ieta-ietaMax) dIetaNeg = ieta-ietaMax;
1650  if(ieta-ietaMax > 0 && dIetaPos < ieta-ietaMax) dIetaPos = ieta-ietaMax;
1651 
1652  if ( smMax !=sm )
1653  {
1654  Int_t ietaShift = ieta;
1655  Int_t ietaMaxShift = ietaMax;
1656 
1657  if (ieta > ietaMax) ietaMaxShift+=48;
1658  else ietaShift +=48;
1659 
1660  if(dIeta < TMath::Abs(ietaShift-ietaMaxShift)) dIeta = TMath::Abs(ietaShift-ietaMaxShift);
1661  if(ietaShift-ietaMaxShift < 0 && dIetaNeg > ietaShift-ietaMaxShift) dIetaNeg = ietaShift-ietaMaxShift;
1662  if(ietaShift-ietaMaxShift > 0 && dIetaPos < ietaShift-ietaMaxShift) dIetaPos = ietaShift-ietaMaxShift;
1663  }
1664  } // if(fStudyShapeParam)
1665 
1666  // cells in same SM as cell max and within an E range and neutral
1667  if ( fStudyColRowFromCellMax && smMax == sm &&
1668  energy > fEMinShape && energy < fEMaxShape && matchedPID == 0 )
1669  {
1670  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1671  {
1672  fhColRowFromCellMaxLowM02PerSM[smMax][ietaMax%2]->Fill(ietaMax-ieta, iphiMax-iphi, nCell, GetEventWeight());
1673  fhColRowFromCellMaxLowM02 [ietaMax%2]->Fill(ietaMax-ieta, iphiMax-iphi, GetEventWeight());
1674 
1675  if ( nCellBin >= 0 && nCellBin < fNCellsBins )
1676  {
1677  fhColRowFromCellMaxEMaxSecDiffFracLowM02PerSM[smMax][ietaMax%2][nCellBin]->Fill(ietaMax-ieta, iphiMax-iphi,(eCellMax-eCell)/eCellMax, GetEventWeight());
1678  fhColRowFromCellMaxEMaxSecDiffLowM02PerSM [smMax][ietaMax%2][nCellBin]->Fill(ietaMax-ieta, iphiMax-iphi, eCellMax-eCell, GetEventWeight());
1679  fhColRowFromCellMaxECellClusterRatLowM02PerSM[smMax][ietaMax%2][nCellBin]->Fill(ietaMax-ieta, iphiMax-iphi, eCell/energy , GetEventWeight());
1680  }
1681  }
1682  else if ( m02 > fM02HighBin[0] && m02 <= fM02HighBin[1] )
1683  {
1684  fhColRowFromCellMaxHighM02PerSM[smMax][ietaMax%2]->Fill(ietaMax-ieta, iphiMax-iphi, nCell, GetEventWeight());
1685  fhColRowFromCellMaxHighM02 [ietaMax%2]->Fill(ietaMax-ieta, iphiMax-iphi, GetEventWeight());
1686 
1687  if ( nCellBin >= 0 && nCellBin < fNCellsBins )
1688  {
1689  fhColRowFromCellMaxEMaxSecDiffFracHighM02PerSM[smMax][ietaMax%2][nCellBin]->Fill(ietaMax-ieta, iphiMax-iphi,(eCellMax-eCell)/eCellMax, GetEventWeight());
1690  fhColRowFromCellMaxEMaxSecDiffHighM02PerSM [smMax][ietaMax%2][nCellBin]->Fill(ietaMax-ieta, iphiMax-iphi, eCellMax-eCell, GetEventWeight());
1691  fhColRowFromCellMaxECellClusterRatHighM02PerSM[smMax][ietaMax%2][nCellBin]->Fill(ietaMax-ieta, iphiMax-iphi, eCell/energy , GetEventWeight());
1692  }
1693  }
1694 
1695  } // cells in sm SM as cell max and within an E range and neutral
1696 
1697  } // Fill cell-cluster histogram loop
1698 
1699  if ( fStudyModuleCells && GetCalorimeter() == kEMCAL )
1700  {
1701  Int_t rowTCard = Int_t(iphiMax%8);
1702  Int_t colTCard = Int_t(ietaMax%2);
1703  Int_t iTCard = rowTCard+8*colTCard;
1704  //printf("row TCard %d, col TCard %d, iTCard %d\n",rowTCard,colTCard,iTCard);
1705 
1706  fhTCardChannelNCellModMax->Fill(energy, iTCard, nPerModule, GetEventWeight());
1707  fhTCardChannelNCell ->Fill(energy, iTCard, nCell , GetEventWeight());
1708  fhTCardChannelM02NoCut ->Fill(energy, iTCard, m02 , GetEventWeight());
1709  if( nCell > 4) fhTCardChannelM02->Fill(energy, iTCard, m02, GetEventWeight());
1710 
1711  Float_t ePerModuleTot = ePerModule+eCellMax;
1712 
1713  fhSMNCellModuleMax->Fill(energy, smMax, nPerModule , GetEventWeight());
1714  fhSMNCellModuleOut->Fill(energy, smMax, nPerModuleOut, GetEventWeight());
1715  fhSMECellModuleMax->Fill(energy, smMax, ePerModule , GetEventWeight());
1716  fhSMECellModuleOut->Fill(energy, smMax, ePerModuleOut, GetEventWeight());
1717 
1718  fhSMNCellModuleMaxOutRat->Fill(energy, smMax, nPerModuleOut/(nPerModule+1.), GetEventWeight());
1719  fhSMECellModuleMaxRat ->Fill(energy, smMax, ePerModule /eCellMax , GetEventWeight());
1720  fhSMECellModuleMaxOutRat->Fill(energy, smMax, ePerModuleOut/eCellMax , GetEventWeight());
1721 
1722  fhSMECellModuleMaxTot ->Fill(energy, smMax, ePerModuleTot , GetEventWeight());
1723  fhSMECellModuleMaxTotRat->Fill(energy, smMax, ePerModuleTot/eCellMax , GetEventWeight());
1724  fhSMECellModuleMaxTotRatClus->Fill(energy, smMax, ePerModuleTot/energy, GetEventWeight());
1725 
1726  fhSMNCellModuleOutModSame ->Fill(energy, smMax, nPerModuleOutS, GetEventWeight());
1727  fhSMNCellModuleOutModDiff ->Fill(energy, smMax, nPerModuleOutD, GetEventWeight());
1728  fhSMECellModuleOutModSame ->Fill(energy, smMax, ePerModuleOutS, GetEventWeight());
1729  fhSMECellModuleOutModDiff ->Fill(energy, smMax, ePerModuleOutD, GetEventWeight());
1730 
1731  fhSMNCellModuleMaxOutModSameRat->Fill(energy, smMax, nPerModuleOutS/(nPerModule+1.), GetEventWeight());
1732  fhSMNCellModuleMaxOutModDiffRat->Fill(energy, smMax, nPerModuleOutD/(nPerModule+1.), GetEventWeight());
1733  fhSMECellModuleMaxOutModSameRat->Fill(energy, smMax, ePerModuleOutS/eCellMax , GetEventWeight());
1734  fhSMECellModuleMaxOutModDiffRat->Fill(energy, smMax, ePerModuleOutD/eCellMax , GetEventWeight());
1735 
1736  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1737  {
1738  fhSMNCellModuleMaxLowM02->Fill(energy, smMax, nPerModule , GetEventWeight());
1739  fhSMNCellModuleOutLowM02->Fill(energy, smMax, nPerModuleOut, GetEventWeight());
1740  fhSMECellModuleMaxLowM02->Fill(energy, smMax, ePerModule , GetEventWeight());
1741  fhSMECellModuleOutLowM02->Fill(energy, smMax, ePerModuleOut, GetEventWeight());
1742 
1743  fhSMNCellModuleMaxOutRatLowM02->Fill(energy, smMax, nPerModuleOut/(nPerModule+1.), GetEventWeight());
1744  fhSMECellModuleMaxRatLowM02 ->Fill(energy, smMax, ePerModule /eCellMax , GetEventWeight());
1745  fhSMECellModuleMaxOutRatLowM02->Fill(energy, smMax, ePerModuleOut/eCellMax , GetEventWeight());
1746 
1747  fhSMECellModuleMaxTotLowM02 ->Fill(energy, smMax, ePerModuleTot , GetEventWeight());
1748  fhSMECellModuleMaxTotRatLowM02->Fill(energy, smMax, ePerModuleTot/eCellMax , GetEventWeight());
1749  fhSMECellModuleMaxTotRatClusLowM02->Fill(energy, smMax, ePerModuleTot/energy, GetEventWeight());
1750 
1751  fhSMNCellModuleOutModSameLowM02 ->Fill(energy, smMax, nPerModuleOutS, GetEventWeight());
1752  fhSMNCellModuleOutModDiffLowM02 ->Fill(energy, smMax, nPerModuleOutD, GetEventWeight());
1753  fhSMECellModuleOutModSameLowM02 ->Fill(energy, smMax, ePerModuleOutS, GetEventWeight());
1754  fhSMECellModuleOutModDiffLowM02 ->Fill(energy, smMax, ePerModuleOutD, GetEventWeight());
1755 
1756  fhSMNCellModuleMaxOutModSameRatLowM02->Fill(energy, smMax, nPerModuleOutS/(nPerModule+1.), GetEventWeight());
1757  fhSMNCellModuleMaxOutModDiffRatLowM02->Fill(energy, smMax, nPerModuleOutD/(nPerModule+1.), GetEventWeight());
1758  fhSMECellModuleMaxOutModSameRatLowM02->Fill(energy, smMax, ePerModuleOutS/eCellMax , GetEventWeight());
1759  fhSMECellModuleMaxOutModDiffRatLowM02->Fill(energy, smMax, ePerModuleOutD/eCellMax , GetEventWeight());
1760 
1761 // if(energy > 8) printf("SM %d, E %2.2f, E max %2.2f;\n"
1762 // " \t nMod %d, nModOut %d, nMod/nModOut %2.2f;\n"
1763 // " \t eMod %2.2f, eModOut %2.2f, eMod/eMax %2.2f, eModOut/eMax %2.2f\n",
1764 // smMax,energy,eCellMax,
1765 // nPerModule,nPerModuleOut,nPerModuleOut/(nPerModule+1.),
1766 // ePerModule,ePerModuleOut,ePerModule/eCellMax,ePerModuleOut/eCellMax);
1767  }
1768  else if ( m02 > fM02HighBin[0] && m02 <= fM02HighBin[1] )
1769  {
1770  fhSMNCellModuleMaxHighM02->Fill(energy, smMax, nPerModule , GetEventWeight());
1771  fhSMNCellModuleOutHighM02->Fill(energy, smMax, nPerModuleOut, GetEventWeight());
1772  fhSMECellModuleMaxHighM02->Fill(energy, smMax, ePerModule , GetEventWeight());
1773  fhSMECellModuleOutHighM02->Fill(energy, smMax, ePerModuleOut, GetEventWeight());
1774 
1775  fhSMNCellModuleMaxOutRatHighM02->Fill(energy, smMax, nPerModuleOut/(nPerModule+1.), GetEventWeight());
1776  fhSMECellModuleMaxRatHighM02 ->Fill(energy, smMax, ePerModule /eCellMax , GetEventWeight());
1777  fhSMECellModuleMaxOutRatHighM02->Fill(energy, smMax, ePerModuleOut/eCellMax , GetEventWeight());
1778 
1779  fhSMECellModuleMaxTotHighM02 ->Fill(energy, smMax, ePerModuleTot , GetEventWeight());
1780  fhSMECellModuleMaxTotRatHighM02->Fill(energy, smMax, ePerModuleTot/eCellMax , GetEventWeight());
1781  fhSMECellModuleMaxTotRatClusHighM02->Fill(energy, smMax, ePerModuleTot/energy, GetEventWeight());
1782 
1783  fhSMNCellModuleOutModSameHighM02 ->Fill(energy, smMax, nPerModuleOutS, GetEventWeight());
1784  fhSMNCellModuleOutModDiffHighM02 ->Fill(energy, smMax, nPerModuleOutD, GetEventWeight());
1785  fhSMECellModuleOutModSameHighM02 ->Fill(energy, smMax, ePerModuleOutS, GetEventWeight());
1786  fhSMECellModuleOutModDiffHighM02 ->Fill(energy, smMax, ePerModuleOutD, GetEventWeight());
1787 
1788  fhSMNCellModuleMaxOutModSameRatHighM02->Fill(energy, smMax, nPerModuleOutS/(nPerModule+1.), GetEventWeight());
1789  fhSMNCellModuleMaxOutModDiffRatHighM02->Fill(energy, smMax, nPerModuleOutD/(nPerModule+1.), GetEventWeight());
1790  fhSMECellModuleMaxOutModSameRatHighM02->Fill(energy, smMax, ePerModuleOutS/eCellMax , GetEventWeight());
1791  fhSMECellModuleMaxOutModDiffRatHighM02->Fill(energy, smMax, ePerModuleOutD/eCellMax , GetEventWeight());
1792  }
1793 
1794  }
1795 
1796  if ( energy > fEMinShape && energy < fEMaxShape && matchedPID == 0 )
1797  {
1798  fhNCellsPerClusterM02M20PerSM[smMax]->Fill(m20, nCell, m02, GetEventWeight());
1799  if ( fFillNLocMaxHistos )
1800  fhNCellsPerClusterM02NLMPerSM[smMax]->Fill(nlm, nCell, m02, GetEventWeight());
1801 
1802  // Col-Row histogram, fill emax/ecluster ratio for highest energy cell.
1803  if ( fStudyColRowFromCellMax && fNCellsBins > 0 &&
1804  nCellBin >= 0 && nCellBin < fNCellsBins )
1805  {
1806  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1807  fhColRowFromCellMaxECellClusterRatLowM02PerSM [smMax][ietaMax%2][nCellBin]->Fill(0., 0., eCellMax/energy, GetEventWeight());
1808  else if ( m02 > fM02HighBin[0] && m02 <= fM02HighBin[1] )
1809  fhColRowFromCellMaxECellClusterRatHighM02PerSM[smMax][ietaMax%2][nCellBin]->Fill(0., 0., eCellMax/energy, GetEventWeight());
1810  }
1811  }
1812 
1813  if(fStudyExotic)
1814  fhClusterMaxCellECrossM02->Fill(energy, eCrossFrac, m02, GetEventWeight());
1815 
1816  //
1817  // Fill histograms only for PID
1818  //
1819  fhClusterMaxCellDiffM02[matchedPID]->Fill(energy, maxFrac, m02, GetEventWeight());
1820  fhClusterTimeEnergyM02 [matchedPID]->Fill(energy, tmax , m02, GetEventWeight());
1821  fhNCellsPerClusterM02 [matchedPID]->Fill(energy, nCell , m02, GetEventWeight());
1822  fhNCellsPerClusterM20 [matchedPID]->Fill(energy, nCell , m20, GetEventWeight());
1823  if ( fFillNLocMaxHistos )
1824  fhNCellsPerClusterNLM [matchedPID]->Fill(energy, nCell , nlm, GetEventWeight());
1825 
1826  if ( matchedPID == 0 && fStudyColRowFromCellMax )
1827  {
1828  fhNCellsPerClusterM02PerSMPerCol[smMax][ietaMax%2]->Fill(energy, nCell, m02, GetEventWeight());
1829  fhNCellsPerClusterM20PerSMPerCol[smMax][ietaMax%2]->Fill(energy, nCell, m20, GetEventWeight());
1830  if ( fFillNLocMaxHistos )
1831  fhNCellsPerClusterNLMPerSMPerCol[smMax][ietaMax%2]->Fill(energy, nCell, nlm, GetEventWeight());
1832  }
1833 
1834  if ( fFillNLocMaxHistos )
1835  fhSMNLocMax [matchedPID]->Fill(energy, smMax , nlm , GetEventWeight());
1836  fhSMNCell [matchedPID]->Fill(energy, smMax , nCell, GetEventWeight());
1837  fhSMM02NoCut [matchedPID]->Fill(energy, smMax , m02 , GetEventWeight());
1838  fhSMEMaxEClusterRat ->Fill(energy, smMax , eCellMax/energy , GetEventWeight());
1839 
1840  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1841  {
1842  fhSMNCellLowM02 [matchedPID]->Fill(energy, smMax , nCell, GetEventWeight());
1843  fhSMM20LowM02NoCut [matchedPID]->Fill(energy, smMax , m20 , GetEventWeight());
1844  fhSMEMaxEClusterRatLowM02 ->Fill(energy, smMax , eCellMax/energy , GetEventWeight());
1845  }
1846  else if ( m02 > fM02HighBin[0] && m02 <= fM02HighBin[1] )
1847  {
1848  fhSMNCellHighM02 [matchedPID]->Fill(energy, smMax , nCell, GetEventWeight());
1849  fhSMM20HighM02NoCut[matchedPID]->Fill(energy, smMax , m20 , GetEventWeight());
1850  fhSMEMaxEClusterRatHighM02 ->Fill(energy, smMax , eCellMax/energy , GetEventWeight());
1851  }
1852 
1853  if ( energy > fEMinShape && energy < fEMaxShape )
1854  {
1855  fhSMNCellM02[matchedPID]->Fill(smMax , nCell, m02, GetEventWeight());
1856 
1857  if ( matchedPID == 0 )
1858  {
1859  if ( fStudyTimeCellHisto )
1860  {
1861  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1862  fhEMaxCellTimeNCellSM->Fill(tmax, smMax, nCell, GetEventWeight());
1863 
1864  fhEMaxCellTimeM02SM->Fill(tmax, smMax, m02, GetEventWeight());
1865  }
1866 
1867  fhEMaxCellEClusterM02NCellPerSM[smMax]->Fill(maxFrac, nCell, m02, GetEventWeight());
1868  // fhEMaxCellLogM02NCellPerSM [smMax]->Fill(TMath::Log(eCellMax), nCell, m02, GetEventWeight());
1869  }
1870  } // energy bin
1871 
1872  // Select clusters with significant size
1873  if ( nCell > fNCellMinShape )
1874  {
1875  if ( m02 > fM02LowBin[0] && m02 <= fM02LowBin[1] )
1876  fhSMM20LowM02 [matchedPID]->Fill(energy, smMax , m20 , GetEventWeight());
1877  else if ( m02 > fM02HighBin[0] && m02 <= fM02HighBin[1] )
1878  fhSMM20HighM02[matchedPID]->Fill(energy, smMax , m20 , GetEventWeight());
1879 
1880  fhSMM02 [matchedPID]->Fill(energy, smMax , m02, GetEventWeight());
1881  fhColM02[matchedPID]->Fill(energy, ietaMax, m02, GetEventWeight());
1882  fhRowM02[matchedPID]->Fill(energy, iphiMax, m02, GetEventWeight());
1883  }
1884 
1885  //
1886  // Different shower shape parameters
1887  //
1888  if ( fStudyShapeParam )
1889  {
1890  // cluster asymmetry
1891  Float_t dIA = 1.*(dIphi-dIeta)/(dIeta+dIphi);
1892  Float_t dIATot = 1.*((dIphiPos-dIphiNeg)-(dIetaPos-dIetaNeg))/((dIetaPos-dIetaNeg)+(dIphiPos-dIphiNeg));
1893 
1894  // Int_t dIphiMin = TMath::Abs(dIphiNeg);
1895  // Int_t dIetaMin = TMath::Abs(dIetaNeg);
1896  // if(dIphiMin > dIphiPos) dIphiMin = dIphiPos ;
1897  // if(dIetaMin > dIetaPos) dIetaMin = dIetaPos ;
1898  // Float_t dIAMin = 0;
1899  // if(dIphiMin > 0 && dIetaMin > 0) dIAMin = 1.*(dIphiMin-dIetaMin)/(dIetaMin+dIphiMin);
1900 
1901  AliDebug(1,Form("E %2.2f, nCell %d, dPhi %d, dEta %d, dIA %2.2f, match %d",energy,nCell, dIphi,dIeta,dIA,matchedPID));
1902 
1903  // if(nCell > 5)
1904  // {
1905  // printf("E %2.2f, nCell %d, dPhi %d, dEta %d, dIA %2.2f, match %d\n",
1906  // energy,nCell, dIphi,dIeta,dIA,matchedPID);
1907  // printf("\t dPhiNeg %d, dPhiPos %d, dEtaNeg %d, dEtaPos %d, dIATot %2.2f, dIAMin %2.2f\n",
1908  // dIphiNeg,dIphiPos,dIetaNeg,dIetaPos,dIATot,dIAMin);
1909  // }
1910 
1911  fhDeltaIANCells [matchedPID]->Fill(energy, nCell , dIA , GetEventWeight());
1912  fhDeltaIATotNCells [matchedPID]->Fill(energy, nCell , dIATot, GetEventWeight());
1913 
1914  if ( nCell > fNCellMinShape ) // it makes sense only for significant size histograms
1915  {
1916  fhDeltaIEtaDeltaIPhi[matchedPID]->Fill(energy, dIeta, dIphi, GetEventWeight());
1917  fhDeltaIA [matchedPID]->Fill(energy, dIA , GetEventWeight());
1918  fhDeltaIAM02 [matchedPID]->Fill(energy, m02 , dIA , GetEventWeight());
1919  fhDeltaIAM20 [matchedPID]->Fill(energy, m20 , dIA , GetEventWeight());
1920 
1921  fhDeltaIEtaDeltaIPhiTot[matchedPID]->Fill(energy,dIetaPos-dIetaNeg, dIphiPos-dIphiNeg, GetEventWeight());
1922  fhDeltaIATot [matchedPID]->Fill(energy, dIATot , GetEventWeight());
1923  fhDeltaIATotM02 [matchedPID]->Fill(energy, m02 , dIATot, GetEventWeight());
1924  fhDeltaIATotM20 [matchedPID]->Fill(energy, m20 , dIATot, GetEventWeight());
1925  }
1926 
1927  if ( IsDataMC() && mcIndex > -1 && mcIndex < 10 && nCell > fNCellMinShape )
1928  {
1929  fhDeltaIAOrigin [matchedPID]->Fill(energy, mcIndex, dIA , GetEventWeight());
1930  fhDeltaIATotOrigin[matchedPID]->Fill(energy, mcIndex, dIATot, GetEventWeight());
1931  }
1932 
1933  Float_t l0 = 0., l1 = 0.;
1934  Float_t dispp= 0., dEta = 0., dPhi = 0.;
1935  Float_t sEta = 0., sPhi = 0., sEtaPhi = 0.;
1936  if ( GetCalorimeter() == kEMCAL )
1937  {
1939  l0, l1, dispp, dEta, dPhi, sEta, sPhi, sEtaPhi);
1940 
1941  Float_t sEtaPhiA = -1000.;
1942  if(sEta+sPhi>0.0001) sEtaPhiA = (sPhi-sEta)/(sEta+sPhi);
1943 
1944  AliDebug(2,Form("Recalculate shower shape org: m02 %2.2f, m20 %2.2f, disp %2.2f;"
1945  " new: m02 %2.2f, m20 %2.2f, disp %2.2f; "
1946  "mEta %2.2f, mPhi %2.2f, mEtaPhi %2.2f, A_EtaPhi %2.2f; dEta %2.2f dPhi %2.2f",
1947  m02,m20,clus->GetDispersion(),l0,l1,dispp,sEta,sPhi,sEtaPhi,sEtaPhiA,dEta,dPhi));
1948 
1949  fhNCellsPerClusterMEta [matchedPID]->Fill(energy, nCell, sEta , GetEventWeight());
1950  fhNCellsPerClusterMPhi [matchedPID]->Fill(energy, nCell, sPhi , GetEventWeight());
1951  fhNCellsPerClusterMEtaPhi [matchedPID]->Fill(energy, nCell, sEtaPhi , GetEventWeight());
1952  fhNCellsPerClusterMEtaPhiA[matchedPID]->Fill(energy, nCell, sEtaPhiA, GetEventWeight());
1953 
1954  fhSMMEtaNoCut [matchedPID]->Fill(energy, smMax, sEta , GetEventWeight());
1955  fhSMMPhiNoCut [matchedPID]->Fill(energy, smMax, sPhi , GetEventWeight());
1956  fhSMMEtaPhiNoCut [matchedPID]->Fill(energy, smMax, sEtaPhi , GetEventWeight());
1957  fhSMMEtaPhiANoCut[matchedPID]->Fill(energy, smMax, sEtaPhiA, GetEventWeight());
1958 
1959  // Select clusters with significant size
1960  if ( nCell > fNCellMinShape )
1961  {
1962  fhSMMEta [matchedPID]->Fill(energy, smMax, sEta , GetEventWeight());
1963  fhSMMPhi [matchedPID]->Fill(energy, smMax, sPhi , GetEventWeight());
1964  fhSMMEtaPhi [matchedPID]->Fill(energy, smMax, sEtaPhi , GetEventWeight());
1965  fhSMMEtaPhiA[matchedPID]->Fill(energy, smMax, sEtaPhiA, GetEventWeight());
1966  }
1967  } // EMCal
1968  } // fStudyShapeParam
1969 
1970  //
1971  // Invariant mass for clusters looking like photons, depending number of cells
1972  //
1973  if ( fStudyInvMass &&
1974  matchedPID == 0 && energy > fEMinShape && energy < fEMaxShape &&
1975  m02 > fInvMassMinM02Cut && m02 < fInvMassMaxM02Cut )
1976  {
1977  for(Int_t jclus = 0 ; jclus < fCaloClusList->GetEntriesFast() ; jclus++)
1978  {
1979  AliVCluster* clus2 = (AliVCluster*) fCaloClusList->At(jclus);
1980 
1981  Float_t maxCellFraction = 0.;
1982  Int_t absIdMax2 = GetCaloUtils()->GetMaxEnergyCell(fCaloCellList, clus2, maxCellFraction);
1983 
1984  Double_t tof2 = clus2->GetTOF()*1.e9;
1985  if(tof2>400) tof2-=fConstantTimeShift;
1986 
1987  Double_t diffTof = tmax-tof2;
1988 
1989  // Try to reduce background with a mild shower shape cut and no more
1990  // than 1 local maximum in cluster and remove low energy clusters
1991 
1992  if( absIdMax == absIdMax2
1993  || !IsGoodCluster(absIdMax2, clus2->GetM02(), clus2->GetNCells())
1995  || clus2->GetM02() > fInvMassMaxM02Cut
1996  || clus2->GetM02() < fInvMassMinM02Cut
1997  || clus2->E() < fInvMassMinECut
1998  || clus2->E() > fInvMassMaxECut
1999  || TMath::Abs(diffTof) > fInvMassMaxTimeDifference
2000  ) continue;
2001 
2002  // Get cluster kinematics
2003  Double_t v[3] = {0,0,0}; //vertex ;
2004  clus2->GetMomentum(fClusterMomentum2,v);
2005 
2006  // Check only certain regions
2007  Bool_t in2 = kTRUE;
2009  if(!in2) continue;
2010 
2011  //Float_t pairE = (fClusterMomentum+fClusterMomentum2).E();
2012 
2013  // Opening angle cut, avoid combination of DCal and EMCal clusters
2014  Double_t angle = fClusterMomentum.Angle(fClusterMomentum2.Vect());
2015 
2016  if( angle > fInvMassMaxOpenAngle ) continue;
2017 
2018  // Fill histograms
2020  fhInvMassNCellSM->Fill(mass, nCell, smMax, GetEventWeight());
2021 
2022  Int_t smMax2 = GetModuleNumber(clus2);
2023  if(smMax == smMax2) fhInvMassNCellSMSame->Fill(mass, nCell, smMax, GetEventWeight());
2024  }
2025  }
2026 
2027  //
2028  // Check the origin.
2029  //
2030  if ( IsDataMC() && mcIndex > -1 && mcIndex < 10)
2031  {
2032  fhOriginENoCut [matchedPID]->Fill(energy, mcIndex, GetEventWeight());
2033  fhOriginM02NoCut[matchedPID]->Fill(energy, mcIndex, m02, GetEventWeight());
2034 
2035  if(nCell > fNCellMinShape)
2036  {
2037  fhOriginE [matchedPID]->Fill(energy, mcIndex, GetEventWeight());
2038  fhOriginM02[matchedPID]->Fill(energy, mcIndex, m02, GetEventWeight());
2039  }
2040 
2041  if(noverlaps > 0)
2042  {
2043  fhOriginENoCutOverlap [matchedPID]->Fill(energy, mcIndex, GetEventWeight());
2044  fhOriginM02NoCutOverlap[matchedPID]->Fill(energy, mcIndex, m02, GetEventWeight());
2045 
2046  if(nCell > fNCellMinShape)
2047  {
2048  fhOriginEOverlap [matchedPID]->Fill(energy, mcIndex, GetEventWeight());
2049  fhOriginM02Overlap[matchedPID]->Fill(energy, mcIndex, m02, GetEventWeight());
2050  }
2051  }
2052  } // MC
2053 }
2054 
2055 //____________________________________________________________________________
2062 //____________________________________________________________________________
2064 (AliVCluster *clus, Int_t & matchedPID)
2065 {
2066 
2067  AliVTrack *track = GetCaloUtils()->GetMatchedTrack(clus, GetReader()->GetInputEvent());
2068 
2069  if(!track)
2070  {
2071  matchedPID = -1;
2072  AliDebug(1,Form("No track found with matches %d",clus->GetNTracksMatched()));
2073  return ;
2074  }
2075 
2076 // Double_t tpt = track->Pt();
2077 // Double_t tmom = track->P();
2078  Double_t dedx = track->GetTPCsignal();
2079 // Int_t nITS = track->GetNcls(0);
2080 // Int_t nTPC = track->GetNcls(1);
2081 // Bool_t positive = kFALSE;
2082 // if(track) positive = (track->Charge()>0);
2083 
2084  // Residuals
2085 // Float_t deta = clus->GetTrackDz();
2086 // Float_t dphi = clus->GetTrackDx();
2087 // Double_t dR = TMath::Sqrt(dphi*dphi + deta*deta);
2088 // Int_t nModule = GetModuleNumber(clus);
2089 
2090  // Electron or else?
2091 
2092  // Init at least once
2093  if(fdEdXMinEle == 0 || fdEdXMaxEle == 0 || fdEdXMinHad == 0 || fdEdXMaxHad == 0)
2095 
2096  if ( dedx >= fdEdXMinEle && dedx < fdEdXMaxEle ) matchedPID = 1;
2097  else if ( dedx >= fdEdXMinHad && dedx < fdEdXMaxHad ) matchedPID = 2;
2098  else matchedPID =-1;
2099 
2100  AliDebug(1,Form("matches %d; dEdX %2.2f; matched PID %d",clus->GetNTracksMatched(),dedx,matchedPID));
2101 }
2102 
2103 //____________________________________________________________________________
2112 //____________________________________________________________________________
2114 {
2115  Int_t nCaloClusters = fCaloClusList->GetEntriesFast() ;
2116  Int_t nCaloCellsPerCluster = 0 ;
2117  Bool_t matched = kFALSE;
2118  Int_t nModule =-1 ;
2119 
2120  // Get vertex for photon momentum calculation and event selection
2121  Double_t v[3] = {0,0,0}; //vertex ;
2122  //GetReader()->GetVertex(v);
2123 
2124  AliDebug(1,Form("In %s there are %d clusters", GetCalorimeterString().Data(), nCaloClusters));
2125 
2126  // Loop over CaloClusters
2127  for(Int_t iclus = 0; iclus < nCaloClusters; iclus++)
2128  {
2129  AliDebug(1,Form("Cluster: %d/%d, data %d",iclus+1,nCaloClusters,GetReader()->GetDataType()));
2130 
2131  AliVCluster* clus = (AliVCluster*) fCaloClusList->At(iclus);
2132 
2133  // away from dead region
2134  if ( clus->GetDistanceToBadChannel() > -1 && // in case it was not calculated
2135  clus->GetDistanceToBadChannel() < fMinDistToBad )
2136  {
2137  AliDebug(1,Form("Small distance to bad channel %2.2f < %2.2f",clus->GetDistanceToBadChannel(),fMinDistToBad));
2138  continue ;
2139  }
2140 
2141  // SuperModule number of cluster
2142  nModule = GetModuleNumber(clus);
2143  if ( nModule < fFirstModule || nModule > fLastModule )
2144  {
2145  AliDebug(1,Form("Cluster module out of range %d",nModule));
2146  continue ;
2147  }
2148 
2149  // Get the fraction of the cluster energy that carries the cell with highest energy and its absId
2150  //
2151  Float_t maxCellFraction = 0.;
2152  Int_t absIdMax = GetCaloUtils()->GetMaxEnergyCell(fCaloCellList, clus, maxCellFraction);
2153 
2154  // Cut on time of clusters
2155  Double_t tof = clus->GetTOF()*1.e9;
2156  if(tof>400) tof-=fConstantTimeShift;
2157 
2158  // Get cluster kinematics
2159  clus->GetMomentum(fClusterMomentum,v);
2160 
2161  Float_t e = fClusterMomentum.E();
2162  Float_t pt = fClusterMomentum.Pt();
2163  Float_t eta = fClusterMomentum.Eta();
2164  Float_t phi = GetPhi(fClusterMomentum.Phi());
2165 
2166  // Check only certain regions
2167  Bool_t in = kTRUE;
2168  if(IsFiducialCutOn())
2170 
2171  if(!in)
2172  {
2173  AliDebug(1,Form("Remove cluster with phi %2.2f and eta %2.2f", phi*TMath::RadToDeg(), eta));
2174  continue;
2175  }
2176 
2177  AliDebug(1,Form("cluster: E %2.3f, pT %2.3f, eta %2.3f, phi %2.3f",e,pt,eta,phi*TMath::RadToDeg()));
2178 
2179  // Select the cluster
2180  //
2181  nCaloCellsPerCluster = clus->GetNCells();
2182 
2183  Bool_t goodCluster = IsGoodCluster(absIdMax, clus->GetM02(), nCaloCellsPerCluster);
2184 
2185  AliDebug(1,Form("Accept cluster? %d",goodCluster));
2186 
2187  if(!goodCluster) continue;
2188 
2189  // MC origin finding
2190  //
2191  Int_t mcTag = 0;
2192  Int_t mcIndex = -1;
2193  Int_t noverlaps =0;
2194  if ( IsDataMC() && fStudyShape )
2195  {
2196  mcTag = GetMCAnalysisUtils()->CheckOrigin(clus->GetLabels(),
2197  clus->GetClusterMCEdepFraction(),
2198  clus->GetNLabels(), GetMC(),
2200  e);
2201 
2203  GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCEta ) ) mcIndex = 0;
2207  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCPhoton ) ) mcIndex = 2;
2208  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCElectron ) ) mcIndex = 3;
2209  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCPion ) ) mcIndex = 4;
2210  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCKaon ) ) mcIndex = 5;
2211  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCProton ) ) mcIndex = 6;
2212  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCAntiProton ) ) mcIndex = 7;
2213  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCNeutron ) ) mcIndex = 8;
2214  else if ( GetMCAnalysisUtils()->CheckTagBit(mcTag, AliMCAnalysisUtils::kMCAntiNeutron) ) mcIndex = 9;
2215 
2216  const UInt_t nlabels = clus->GetNLabels();
2217  Int_t overpdg[nlabels];
2218  Int_t overlab[nlabels];
2219  noverlaps = GetMCAnalysisUtils()->GetNOverlaps(clus->GetLabels(), nlabels, mcTag, -1,
2220  GetMC(), overpdg, overlab);
2221  }
2222 
2223  // Cluster mathed with track? and what kind?
2224  //
2225  matched = GetCaloPID()->IsTrackMatched(clus,GetCaloUtils(), GetReader()->GetInputEvent());
2226 
2227  Int_t matchedPID = -1;
2228  if ( !matched )
2229  {
2230  matchedPID = 0;
2231  }
2232  else if ( fStudyShape && fNMatchPIDCases > 1 )
2233  {
2234  ClusterMatchedToTrackPID(clus, matchedPID);
2235  }
2236 
2237  // Get amp and time of max cell, recalibrate and calculate things
2238  //
2239  Int_t bc = (GetReader()->GetInputEvent())->GetBunchCrossNumber();
2240  Double_t tmax = fCaloCellList->GetCellTime(absIdMax);
2241  Float_t ampMax = fCaloCellList->GetCellAmplitude(absIdMax);
2242 
2243  GetCaloUtils()->RecalibrateCellTime(tmax, GetCalorimeter(), absIdMax, bc);
2244  tmax*=1.e9;
2245  if(tmax>400) tmax-=fConstantTimeShift;
2246 
2247  GetCaloUtils()->RecalibrateCellAmplitude(ampMax, GetCalorimeter(), absIdMax);
2248 
2249  Float_t eCrossFrac = 0;
2250  if ( ampMax > 0.01 )
2251  eCrossFrac = 1-GetCaloUtils()->GetECross(absIdMax,fCaloCellList,bc)/ampMax;
2252 
2253 
2254  // Call analysis method filling histograms
2255  //
2256 
2257  //
2258  if ( fStudyShape && matchedPID >= 0 && matchedPID < 3 )
2259  ClusterShapeHistograms(clus, absIdMax, maxCellFraction, eCrossFrac, ampMax, tmax, matchedPID, mcIndex, noverlaps);
2260 
2261  //
2262  if ( fStudyTCardCorrelation )
2263  ChannelCorrelationInTCard(clus, matched, absIdMax, eCrossFrac);
2264 
2265  //
2266  if ( fStudyWeight )
2267  WeightHistograms(clus, mcTag);
2268 
2269  } // Cluster loop
2270 
2271 }
2272 
2273 //_________________________________________________
2275 //_________________________________________________
2277 {
2278  TString parList ; //this will be list of parameters used for this analysis.
2279  const Int_t buffersize = 255;
2280  char onePar[buffersize] ;
2281 
2282  snprintf(onePar,buffersize,"--- AliAnaClusterShapeCorrelStudies ---:") ;
2283  parList+=onePar ;
2284  snprintf(onePar,buffersize,"Calorimeter: %s;",GetCalorimeterString().Data()) ;
2285  parList+=onePar ;
2286  snprintf(onePar,buffersize,"Cluster M02: > %2.2f ; n cells > %d; dist to bad>%2.1f;",fM02Min, fNCellMin, fMinDistToBad) ;
2287  parList+=onePar ;
2288  snprintf(onePar,buffersize,"Inv. Mass %2.1f < E_cl < %2.1f GeV;",fInvMassMinECut, fInvMassMaxECut) ;
2289  parList+=onePar ;
2290  snprintf(onePar,buffersize,"Inv. Mass %2.1f < M02 < %2.1f GeV;",fInvMassMinM02Cut, fInvMassMaxM02Cut) ;
2291  parList+=onePar ;
2292  snprintf(onePar,buffersize,"Cluster pair opening angle < %2.1f rad;",fInvMassMaxOpenAngle) ;
2293  parList+=onePar ;
2294  snprintf(onePar,buffersize,"Cluster pair time difference < %2.1f rad;",fInvMassMaxTimeDifference) ;
2295  parList+=onePar ;
2296 
2297  //Get parameters set in base class.
2298  //parList += GetBaseParametersList() ;
2299 
2300  //Get parameters set in FiducialCut class (not available yet)
2301  //parlist += GetFidCut()->GetFidCutParametersList()
2302 
2303  return new TObjString(parList) ;
2304 }
2305 
2306 //___________________________________________________
2309 //___________________________________________________
2311 {
2312  TList * outputContainer = new TList() ;
2313  outputContainer->SetName("ClusterShapeStudies") ;
2314 
2315  // Init the number of modules, set in the class AliCalorimeterUtils
2316  //
2317  InitCaloParameters(); // See AliCaloTrackCorrBaseClass
2318 
2319  //Int_t totalSM = fLastModule-fFirstModule+1;
2320  //printf("N SM %d, first SM %d, last SM %d, total %d\n",fNModules,fFirstModule,fLastModule, totalSM);
2321 
2322 
2323  // MC origin
2324  TString mcParticleStringLabel[] = {"Merged #gamma#gamma","Decay #gamma","Direct #gamma","e^{#pm}","#pi^{#pm}","k^{#pm}","p","#bar{p}","n","#bar{n}"};
2325  //TString mcParticleStringTitle[] = {"MergedPhoton","DecayPhoton","DirectPhoton","Electron","Pion","Kaon","Proton","AntiProton","Neutron","AntiNeutron"};
2326 
2327  // track-match PID matching
2328  TString matchCase[] = {"Neutral","Electron","Hadron"};
2329 
2330  // Histogram binning and ranges
2331  //
2334 
2337 
2340 
2341  // TM residuals
2348 
2349  // Cell column-row histograms, see base class for data members setting
2350  //fNMaxColsFull+2,-1.5,fNMaxColsFull+0.5, fNMaxRowsFull+2,-1.5,fNMaxRowsFull+0.5
2351  Int_t ncolcell = fNMaxColsFull+2;
2352  Float_t colcellmin = -1.5;
2353  Float_t colcellmax = fNMaxColsFull+0.5;
2354 
2356  Float_t rowcellmin = fNMaxRowsFullMin-1.5;
2357  Float_t rowcellmax = fNMaxRowsFullMax+0.5;
2358 
2359  // E bins in TH3
2360  Int_t nEbins = 48;//16 ;
2361  Float_t minE = 2.5;
2362  Float_t maxE = 50.5;//18.5;
2363 
2364  // shower shape bins in TH3
2365  Int_t nShShBins = 200;
2366  Float_t minShSh = 0.;
2367  Float_t maxShSh = 2.;
2368 
2369  // Asymmetry bins
2370  Int_t asyBins = 21;
2371  Float_t asyMax = 1.05;
2372  Float_t asyMin = -1*asyMax;
2373 
2374  // n cell bins for TH3
2375  Int_t cellBins = 15;
2376  Float_t cellMax = 15;
2377  Float_t cellMin = 0;
2378 
2379  //
2380  // Init histograms
2381  //
2383  {
2385  ("hColRowHighEPosTime",
2386  "column vs row, exo < 0.97, E > 8 GeV, t > 5 ns",
2387  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2388  fhColRowHighEPosTime->SetYTitle("row");
2389  fhColRowHighEPosTime->SetXTitle("column");
2390  outputContainer->Add(fhColRowHighEPosTime) ;
2391 
2393  ("hColRowHighENegTime",
2394  "column vs row, exo < 0.97, E > 8 GeV, t < -5 ns",
2395  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2396  fhColRowHighENegTime->SetYTitle("row");
2397  fhColRowHighENegTime->SetXTitle("column");
2398  outputContainer->Add(fhColRowHighENegTime) ;
2399 
2401  ("hColRowHighENulTime",
2402  "column vs row, exo < 0.97, E > 8 GeV, -5 < t < 5 ns",
2403  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2404  fhColRowHighENulTime->SetYTitle("row");
2405  fhColRowHighENulTime->SetXTitle("column");
2406  outputContainer->Add(fhColRowHighENulTime) ;
2407 
2408  if(fStudyExotic)
2409  {
2411  ("hColRowExoticHighE1CellPosTime",
2412  "column vs row, 1 cell, E > 8 GeV, t > 5 ns",
2413  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2414  fhColRowExoticHighE1CellPosTime->SetYTitle("row");
2415  fhColRowExoticHighE1CellPosTime->SetXTitle("column");
2416  outputContainer->Add(fhColRowExoticHighE1CellPosTime) ;
2417 
2419  ("hColRowExoticHighEPosTime",
2420  "column vs row, exo > 0.97, E > 8 GeV, t > 5 ns",
2421  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2422  fhColRowExoticHighEPosTime->SetYTitle("row");
2423  fhColRowExoticHighEPosTime->SetXTitle("column");
2424  outputContainer->Add(fhColRowExoticHighEPosTime) ;
2425 
2427  ("hColRowExoticHighE1CellNegTime",
2428  "column vs row, 1 cell, E > 8 GeV, t < -5 ns",
2429  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2430  fhColRowExoticHighE1CellNegTime->SetYTitle("row");
2431  fhColRowExoticHighE1CellNegTime->SetXTitle("column");
2432  outputContainer->Add(fhColRowExoticHighE1CellNegTime) ;
2433 
2435  ("hColRowExoticHighENegTime",
2436  "column vs row, exo > 0.97, E > 8 GeV, t < -5 ns",
2437  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2438  fhColRowExoticHighENegTime->SetYTitle("row");
2439  fhColRowExoticHighENegTime->SetXTitle("column");
2440  outputContainer->Add(fhColRowExoticHighENegTime) ;
2441 
2443  ("hColRowExoticHighE1CellNulTime",
2444  "column vs row, 1 cell, E > 8 GeV, -5 < t < 5 ns",
2445  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2446  fhColRowExoticHighE1CellNulTime->SetYTitle("row");
2447  fhColRowExoticHighE1CellNulTime->SetXTitle("column");
2448  outputContainer->Add(fhColRowExoticHighE1CellNulTime) ;
2449 
2451  ("hColRowExoticHighENulTime",
2452  "column vs row, exo > 0.97, E > 8 GeV, -5 < t < 5 ns",
2453  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2454  fhColRowExoticHighENulTime->SetYTitle("row");
2455  fhColRowExoticHighENulTime->SetXTitle("column");
2456  outputContainer->Add(fhColRowExoticHighENulTime) ;
2457  }
2458 
2459  TString add[] = {"","TrackMatched"};
2460  for(Int_t tm = 0; tm < 2; tm++)
2461  {
2463  (Form("hColRowTCardCorrNoSelectionLowE%s",add[tm].Data()),
2464  Form("column vs row, max E cell for TCard correlation selected clusters, 5 < E < 8 GeV %s",add[tm].Data()),
2465  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2466  fhColRowTCardCorrNoSelectionLowE[tm]->SetYTitle("row");
2467  fhColRowTCardCorrNoSelectionLowE[tm]->SetXTitle("column");
2468  outputContainer->Add(fhColRowTCardCorrNoSelectionLowE[tm]) ;
2469 
2471  (Form("hColRowTCardCorrNoSelectionHighE%s",add[tm].Data()),
2472  Form("column vs row, max E cell for TCard correlation selected clusters, E > 8 GeV %s",add[tm].Data()),
2473  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2474  fhColRowTCardCorrNoSelectionHighE[tm]->SetYTitle("row");
2475  fhColRowTCardCorrNoSelectionHighE[tm]->SetXTitle("column");
2476  outputContainer->Add(fhColRowTCardCorrNoSelectionHighE[tm]) ;
2477 
2478  //
2479 
2481  (Form("hNCellsTCardCorrNoSelection%s",add[tm].Data()),
2482  Form("# custer # cells vs #it{E} %s",add[tm].Data()),
2483  nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
2484  fhNCellsTCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2485  fhNCellsTCardCorrNoSelection[tm]->SetYTitle("#it{n}_{cells}");
2486  outputContainer->Add(fhNCellsTCardCorrNoSelection[tm]);
2487 
2489  (Form("hNCellsTCardCorrWithWeightNoSelection%s",add[tm].Data()),
2490  Form("custer # cells vs #it{E}, w > 0.01 %s",add[tm].Data()),
2491  nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
2492  fhNCellsTCardCorrWithWeightNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2493  fhNCellsTCardCorrWithWeightNoSelection[tm]->SetYTitle("#it{n}_{cells}");
2494  outputContainer->Add(fhNCellsTCardCorrWithWeightNoSelection[tm]);
2495 
2497  (Form("hNCellsTCardCorrRatioWithWeightNoSelection%s",add[tm].Data()),
2498  Form("custer # cells vs #it{E}, w > 0.01 %s",add[tm].Data()),
2499  nptbins,ptmin,ptmax, 100,0,1);
2500  fhNCellsTCardCorrRatioWithWeightNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2501  fhNCellsTCardCorrRatioWithWeightNoSelection[tm]->SetYTitle("#it{n}^{w>0.01}_{cells} / #it{n}_{cells}");
2502  outputContainer->Add(fhNCellsTCardCorrRatioWithWeightNoSelection[tm]);
2503 
2504  fhTimeTCardCorrNoSelection[tm] = new TH2F
2505  (Form("hTimeTCardCorrNoSelection%s",add[tm].Data()),
2506  Form("#it{time} vs #it{E} %s",add[tm].Data()),
2507  nptbins,ptmin,ptmax,ntimebins,timemin,timemax);
2508  fhTimeTCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2509  fhTimeTCardCorrNoSelection[tm]->SetYTitle("#it{time} (ns)");
2510  outputContainer->Add(fhTimeTCardCorrNoSelection[tm]);
2511 
2513  (Form("hLambda0TCardCorrNoSelection%s",add[tm].Data()),
2514  Form("#sigma^{2}_{long} vs #it{E} %s",add[tm].Data()),
2515  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
2516  fhLambda0TCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2517  fhLambda0TCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{long}");
2518  outputContainer->Add(fhLambda0TCardCorrNoSelection[tm]);
2519 
2521  (Form("hLambda1TCardCorrNoSelection%s",add[tm].Data()),
2522  Form("#sigma^{2}_{short} vs #it{E} %s",add[tm].Data()),
2523  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
2524  fhLambda1TCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2525  fhLambda1TCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{short}");
2526  outputContainer->Add(fhLambda1TCardCorrNoSelection[tm]);
2527 
2528  if ( fFillNLocMaxHistos )
2529  {
2531  (Form("hLambda0NLM1TCardCorrNoSelection%s",add[tm].Data()),
2532  Form("#sigma^{2}_{long} vs #it{E}, nlm=1 %s",add[tm].Data()),
2533  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
2534  fhLambda0NLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2535  fhLambda0NLM1TCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{long}");
2536  outputContainer->Add(fhLambda0NLM1TCardCorrNoSelection[tm]);
2537 
2539  (Form("hLambda1NLM1TCardCorrNoSelection%s",add[tm].Data()),
2540  Form("#sigma^{2}_{short} vs #it{E}, nlm=1 %s",add[tm].Data()),
2541  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
2542  fhLambda1NLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2543  fhLambda1NLM1TCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{short}");
2544  outputContainer->Add(fhLambda1NLM1TCardCorrNoSelection[tm]);
2545 
2547  (Form("hLambda0NLM2TCardCorrNoSelection%s",add[tm].Data()),
2548  Form("#sigma^{2}_{long} vs #it{E}, nlm=2 %s",add[tm].Data()),
2549  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
2550  fhLambda0NLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2551  fhLambda0NLM2TCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{long}");
2552  outputContainer->Add(fhLambda0NLM2TCardCorrNoSelection[tm]);
2553 
2555  (Form("hLambda1NLM2TCardCorrNoSelection%s",add[tm].Data()),
2556  Form("#sigma^{2}_{short} vs #it{E}, nlm=2 %s",add[tm].Data()),
2557  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
2558  fhLambda1NLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2559  fhLambda1NLM2TCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{short}");
2560  outputContainer->Add(fhLambda1NLM2TCardCorrNoSelection[tm]);
2561  }
2562 
2564  (Form("hLambdaRTCardCorrNoSelection%s",add[tm].Data()),
2565  Form("#sigma^{2}_{short}/#sigma^{2}_{long} vs #it{E} %s",add[tm].Data()),
2566  nptbins,ptmin,ptmax,110,0,1.1);
2567  fhLambdaRTCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2568  fhLambdaRTCardCorrNoSelection[tm]->SetYTitle("#sigma^{2}_{short}/#sigma^{2}_{long}");
2569  outputContainer->Add(fhLambdaRTCardCorrNoSelection[tm]);
2570 
2572  (Form("hNLocMaxTCardCorrNoSelection%s",add[tm].Data()),
2573  Form("#it{n}_{LM} vs E %s",add[tm].Data()),
2574  nptbins,ptmin,ptmax,10,0,10);
2575  fhNLocMaxTCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2576  fhNLocMaxTCardCorrNoSelection[tm]->SetYTitle("#it{n}_{LM}");
2577  outputContainer->Add(fhNLocMaxTCardCorrNoSelection[tm]);
2578 
2579  if ( fFillNLocMaxHistos )
2580  {
2582  (Form("hEMaxRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2583  Form("#it{E}_{cell}^{max}/#it{E}_{cluster} vs E, #it{n}_{LM}=1 %s",add[tm].Data()),
2584  nptbins,ptmin,ptmax,100,0,1);
2585  fhEMaxRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2586  fhEMaxRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}");
2587  outputContainer->Add(fhEMaxRatNLM1TCardCorrNoSelection[tm]);
2588 
2590  (Form("hEMaxRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2591  Form("#it{E}_{cell}^{max}/#it{E}_{cluster} vs E, #it{n}_{LM}=2 %s",add[tm].Data()),
2592  nptbins,ptmin,ptmax,100,0,1);
2593  fhEMaxRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2594  fhEMaxRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}");
2595  outputContainer->Add(fhEMaxRatNLM2TCardCorrNoSelection[tm]);
2596 
2598  (Form("hEMaxRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2599  Form("#it{E}_{cell}^{max}/#it{E}_{cluster} vs E, #it{n}_{LM}>2 %s",add[tm].Data()),
2600  nptbins,ptmin,ptmax,100,0,1);
2601  fhEMaxRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2602  fhEMaxRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}");
2603  outputContainer->Add(fhEMaxRatNLM3TCardCorrNoSelection[tm]);
2604 
2606  (Form("hE2ndRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2607  Form("#it{E}_{cell}^{2nd max}/#it{E}_{cluster} vs E, #it{n}_{LM}=1 %s",add[tm].Data()),
2608  nptbins,ptmin,ptmax,100,0,1);
2609  fhE2ndRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2610  fhE2ndRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd max}/#it{E}_{cluster}");
2611  outputContainer->Add(fhE2ndRatNLM1TCardCorrNoSelection[tm]);
2612 
2614  (Form("hE2ndRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2615  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs E, #it{n}_{LM}=2 %s",add[tm].Data()),
2616  nptbins,ptmin,ptmax,100,0,1);
2617  fhE2ndRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2618  fhE2ndRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster}");
2619  outputContainer->Add(fhE2ndRatNLM2TCardCorrNoSelection[tm]);
2620 
2622  (Form("hE2ndRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2623  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs E, #it{n}_{LM}>2 %s",add[tm].Data()),
2624  nptbins,ptmin,ptmax,100,0,1);
2625  fhE2ndRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2626  fhE2ndRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster}");
2627  outputContainer->Add(fhE2ndRatNLM3TCardCorrNoSelection[tm]);
2628 
2629 
2631  (Form("hE2ndEMaxRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2632  Form("#it{E}_{cell}^{2nd max}/#it{E}_{cell}^{max} vs E, #it{n}_{LM}=1 %s",add[tm].Data()),
2633  nptbins,ptmin,ptmax,100,0,1);
2634  fhE2ndEMaxRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2635  fhE2ndEMaxRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd max}/#it{E}_{cell}^{max}");
2636  outputContainer->Add(fhE2ndEMaxRatNLM1TCardCorrNoSelection[tm]);
2637 
2639  (Form("hE2ndEMaxRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2640  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max} vs E, #it{n}_{LM}=2 %s",add[tm].Data()),
2641  nptbins,ptmin,ptmax,100,0,1);
2642  fhE2ndEMaxRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2643  fhE2ndEMaxRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max}");
2644  outputContainer->Add(fhE2ndEMaxRatNLM2TCardCorrNoSelection[tm]);
2645 
2647  (Form("hE2ndEMaxRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2648  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max} vs E, #it{n}_{LM}>2 %s",add[tm].Data()),
2649  nptbins,ptmin,ptmax,100,0,1);
2650  fhE2ndEMaxRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2651  fhE2ndEMaxRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max}");
2652  outputContainer->Add(fhE2ndEMaxRatNLM3TCardCorrNoSelection[tm]);
2653 
2655 
2657  (Form("hE2ndSameRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2658  Form("#it{E}_{cell}^{2nd max}/#it{E}_{cluster} vs E, 2nd in same TCard as leading, #it{n}_{LM}=1 %s",add[tm].Data()),
2659  nptbins,ptmin,ptmax,100,0,1);
2660  fhE2ndSameRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2661  fhE2ndSameRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd max}/#it{E}_{cluster}");
2662  outputContainer->Add(fhE2ndSameRatNLM1TCardCorrNoSelection[tm]);
2663 
2665  (Form("hE2ndSameRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2666  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs E, 2nd in same TCard as leading, #it{n}_{LM}=2 %s",add[tm].Data()),
2667  nptbins,ptmin,ptmax,100,0,1);
2668  fhE2ndSameRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2669  fhE2ndSameRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster}");
2670  outputContainer->Add(fhE2ndSameRatNLM2TCardCorrNoSelection[tm]);
2671 
2673  (Form("hE2ndSameRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2674  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs E, 2nd in same TCard as leading, #it{n}_{LM}>2 %s",add[tm].Data()),
2675  nptbins,ptmin,ptmax,100,0,1);
2676  fhE2ndSameRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2677  fhE2ndSameRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster}");
2678  outputContainer->Add(fhE2ndSameRatNLM3TCardCorrNoSelection[tm]);
2679 
2680 
2682  (Form("hE2ndSameEMaxRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2683  Form("#it{E}_{cell}^{2nd max}/#it{E}_{cell}^{max} vs E, 2nd in same TCard as leading, #it{n}_{LM}=1 %s",add[tm].Data()),
2684  nptbins,ptmin,ptmax,100,0,1);
2685  fhE2ndSameEMaxRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2686  fhE2ndSameEMaxRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd max}/#it{E}_{cell}^{max}");
2687  outputContainer->Add(fhE2ndSameEMaxRatNLM1TCardCorrNoSelection[tm]);
2688 
2690  (Form("hE2ndSameEMaxRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2691  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max} vs E, 2nd in same TCard as leading, #it{n}_{LM}=2 %s",add[tm].Data()),
2692  nptbins,ptmin,ptmax,100,0,1);
2693  fhE2ndSameEMaxRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2694  fhE2ndSameEMaxRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max}");
2695  outputContainer->Add(fhE2ndSameEMaxRatNLM2TCardCorrNoSelection[tm]);
2696 
2698  (Form("hE2ndSameEMaxRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2699  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max} vs E, 2nd in same TCard as leading, #it{n}_{LM}>2 %s",add[tm].Data()),
2700  nptbins,ptmin,ptmax,100,0,1);
2701  fhE2ndSameEMaxRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2702  fhE2ndSameEMaxRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max}");
2703  outputContainer->Add(fhE2ndSameEMaxRatNLM3TCardCorrNoSelection[tm]);
2704 
2706 
2708  (Form("hECellClusRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2709  Form("#it{E}_{cell}/#it{E}_{cluster} vs E_{cluster}, #it{n}_{LM}=1 %s",add[tm].Data()),
2710  nptbins,ptmin,ptmax,100,0,1);
2711  fhECellClusRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2712  fhECellClusRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
2713  outputContainer->Add(fhECellClusRatNLM1TCardCorrNoSelection[tm]);
2714 
2716  (Form("hECellClusRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2717  Form("#it{E}_{cell}/#it{E}_{cluster} vs E, #it{n}_{LM}=2 %s",add[tm].Data()),
2718  nptbins,ptmin,ptmax,100,0,1);
2719  fhECellClusRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2720  fhECellClusRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
2721  outputContainer->Add(fhECellClusRatNLM2TCardCorrNoSelection[tm]);
2722 
2724  (Form("hECellClusRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2725  Form("#it{E}_{cell}/#it{E}_{cluster} vs E, #it{n}_{LM}>2 %s",add[tm].Data()),
2726  nptbins,ptmin,ptmax,100,0,1);
2727  fhECellClusRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2728  fhECellClusRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
2729  outputContainer->Add(fhECellClusRatNLM3TCardCorrNoSelection[tm]);
2730 
2732  (Form("hLogECellNLM1TCardCorrNoSelection%s",add[tm].Data()),
2733  Form("log(#it{E}_{cell}) vs E_{cluster}, #it{n}_{LM}=1, w > 0.01 %s",add[tm].Data()),
2734  nptbins,ptmin,ptmax,150,-3,3);
2735  fhLogECellNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2736  fhLogECellNLM1TCardCorrNoSelection[tm]->SetYTitle("log(#it{E}_{cell})");
2737  outputContainer->Add(fhLogECellNLM1TCardCorrNoSelection[tm]);
2738 
2740  (Form("hLogECellNLM2TCardCorrNoSelection%s",add[tm].Data()),
2741  Form("log(#it{E}_{cell}) vs E, #it{n}_{LM}=2, w > 0.01 %s",add[tm].Data()),
2742  nptbins,ptmin,ptmax,150,-3,3);
2743  fhLogECellNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2744  fhLogECellNLM2TCardCorrNoSelection[tm]->SetYTitle("log(#it{E}_{cell})");
2745  outputContainer->Add(fhLogECellNLM2TCardCorrNoSelection[tm]);
2746 
2748  (Form("hLogECellNLM3TCardCorrNoSelection%s",add[tm].Data()),
2749  Form("log(#it{E}_{cell}) vs E, #it{n}_{LM}>2, w > 0.01 %s",add[tm].Data()),
2750  nptbins,ptmin,ptmax,150,-3,3);
2751  fhLogECellNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2752  fhLogECellNLM3TCardCorrNoSelection[tm]->SetYTitle("log(#it{E}_{cell})");
2753  outputContainer->Add(fhLogECellNLM3TCardCorrNoSelection[tm]);
2754 
2755 
2757  (Form("hECellWeightNLM1TCardCorrNoSelection%s",add[tm].Data()),
2758  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs E_{cluster}, #it{n}_{LM}=1 %s",add[tm].Data()),
2759  nptbins,ptmin,ptmax,90,0,4.5);
2760  fhECellWeightNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2761  fhECellWeightNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
2762  outputContainer->Add(fhECellWeightNLM1TCardCorrNoSelection[tm]);
2763 
2765  (Form("hECellWeightNLM2TCardCorrNoSelection%s",add[tm].Data()),
2766  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs E, #it{n}_{LM}=2 %s",add[tm].Data()),
2767  nptbins,ptmin,ptmax,90,0,4.5);
2768  fhECellWeightNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2769  fhECellWeightNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
2770  outputContainer->Add(fhECellWeightNLM2TCardCorrNoSelection[tm]);
2771 
2773  (Form("hECellWeightNLM3TCardCorrNoSelection%s",add[tm].Data()),
2774  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))vs E, #it{n}_{LM}>2 %s",add[tm].Data()),
2775  nptbins,ptmin,ptmax,90,0,4.5);
2776  fhECellWeightNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2777  fhECellWeightNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
2778  outputContainer->Add(fhECellWeightNLM3TCardCorrNoSelection[tm]);
2779 
2780 
2782  (Form("hECellSameClusRatNLM1TCardCorrNoSelection%s",add[tm].Data()),
2783  Form("#it{E}_{cell}/#it{E}_{cluster} vs E_{cluster}, cell from same T-Card as leading, #it{n}_{LM}=1 %s",add[tm].Data()),
2784  nptbins,ptmin,ptmax,100,0,1);
2785  fhECellSameClusRatNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2786  fhECellSameClusRatNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
2787  outputContainer->Add(fhECellSameClusRatNLM1TCardCorrNoSelection[tm]);
2788 
2790  (Form("hECellSameClusRatNLM2TCardCorrNoSelection%s",add[tm].Data()),
2791  Form("#it{E}_{cell}/#it{E}_{cluster} vs E, cell from same T-Card as leading, #it{n}_{LM}=2 %s",add[tm].Data()),
2792  nptbins,ptmin,ptmax,100,0,1);
2793  fhECellSameClusRatNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2794  fhECellSameClusRatNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
2795  outputContainer->Add(fhECellSameClusRatNLM2TCardCorrNoSelection[tm]);
2796 
2798  (Form("hECellSameClusRatNLM3TCardCorrNoSelection%s",add[tm].Data()),
2799  Form("#it{E}_{cell}/#it{E}_{cluster} vs E, cell from same T-Card as leading, #it{n}_{LM}>2 %s",add[tm].Data()),
2800  nptbins,ptmin,ptmax,100,0,1);
2801  fhECellSameClusRatNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2802  fhECellSameClusRatNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
2803  outputContainer->Add(fhECellSameClusRatNLM3TCardCorrNoSelection[tm]);
2804 
2806  (Form("hLogECellSameNLM1TCardCorrNoSelection%s",add[tm].Data()),
2807  Form("log(#it{E}_{cell}) vs E_{cluster}, cell from same T-Card as leading, #it{n}_{LM}=1, w > 0.01 %s",add[tm].Data()),
2808  nptbins,ptmin,ptmax,150,-3,3);
2809  fhLogECellSameNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2810  fhLogECellSameNLM1TCardCorrNoSelection[tm]->SetYTitle("log(#it{E}_{cell})");
2811  outputContainer->Add(fhLogECellSameNLM1TCardCorrNoSelection[tm]);
2812 
2814  (Form("hLogECellSameNLM2TCardCorrNoSelection%s",add[tm].Data()),
2815  Form("log(#it{E}_{cell}) vs E, #it{n}_{LM}=2, cell from same T-Card as leading, w > 0.01 %s",add[tm].Data()),
2816  nptbins,ptmin,ptmax,150,-3,3);
2817  fhLogECellSameNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2818  fhLogECellSameNLM2TCardCorrNoSelection[tm]->SetYTitle("log(#it{E}_{cell})");
2819  outputContainer->Add(fhLogECellSameNLM2TCardCorrNoSelection[tm]);
2820 
2822  (Form("hLogECellSameNLM3TCardCorrNoSelection%s",add[tm].Data()),
2823  Form("log(#it{E}_{cell}) vs E, #it{n}_{LM}>2, cell from same T-Card as leading, w > 0.01 %s",add[tm].Data()),
2824  nptbins,ptmin,ptmax,150,-3,3);
2825  fhLogECellSameNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2826  fhLogECellSameNLM3TCardCorrNoSelection[tm]->SetYTitle("log(#it{E}_{cell})");
2827  outputContainer->Add(fhLogECellSameNLM3TCardCorrNoSelection[tm]);
2828 
2829 
2831  (Form("hECellSameWeightNLM1TCardCorrNoSelection%s",add[tm].Data()),
2832  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs E_{cluster}, cell from same T-Card as leading, #it{n}_{LM}=1 %s",add[tm].Data()),
2833  nptbins,ptmin,ptmax,90,0,4.5);
2834  fhECellSameWeightNLM1TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2835  fhECellSameWeightNLM1TCardCorrNoSelection[tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
2836  outputContainer->Add(fhECellSameWeightNLM1TCardCorrNoSelection[tm]);
2837 
2839  (Form("hECellSameWeightNLM2TCardCorrNoSelection%s",add[tm].Data()),
2840  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs E, cell from same T-Card as leading, #it{n}_{LM}=2 %s",add[tm].Data()),
2841  nptbins,ptmin,ptmax,90,0,4.5);
2842  fhECellSameWeightNLM2TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2843  fhECellSameWeightNLM2TCardCorrNoSelection[tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
2844  outputContainer->Add(fhECellSameWeightNLM2TCardCorrNoSelection[tm]);
2845 
2847  (Form("hECellSameWeightNLM3TCardCorrNoSelection%s",add[tm].Data()),
2848  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))vs E, cell from same T-Card as leading, #it{n}_{LM}>2 %s",add[tm].Data()),
2849  nptbins,ptmin,ptmax,90,0,4.5);
2850  fhECellSameWeightNLM3TCardCorrNoSelection[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2851  fhECellSameWeightNLM3TCardCorrNoSelection[tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
2852  outputContainer->Add(fhECellSameWeightNLM3TCardCorrNoSelection[tm]);
2853  } // NLM histos
2854 
2856  (Form("hExoticTCardCorrNoSelection%s",add[tm].Data()),
2857  Form("exoticity vs #it{E} %s",add[tm].Data()),
2858  nptbins,ptmin,ptmax,200,-1,1);
2859  fhExoticTCardCorrNoSelection[tm]->SetXTitle("#it{E} (GeV)");
2860  fhExoticTCardCorrNoSelection[tm]->SetYTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
2861  outputContainer->Add(fhExoticTCardCorrNoSelection[tm]);
2862 
2864  (Form("hNCellsTCardSameAndDiffFraction%s",add[tm].Data()),
2865  Form("#it{n}_{cells} same TCard vs diff TCard fraction, w > 0.01, %s",add[tm].Data()),
2866  nptbins,ptmin,ptmax,100,0,1);
2867  fhNCellsTCardSameAndDiffFraction[tm]->SetXTitle("#it{E} (GeV)");
2868  fhNCellsTCardSameAndDiffFraction[tm]->SetYTitle("#it{n}_{cells} - same TCard / #it{n}_{cells} - total");
2869  outputContainer->Add(fhNCellsTCardSameAndDiffFraction[tm]);
2870 
2872  (Form("hSameRowDiffColAndTCardCellsEnergyDiffClusterE%s",add[tm].Data()),
2873  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} vs #it{E}_{cluster} %s",add[tm].Data()),
2874  nptbins,ptmin,ptmax,200,-10,10);
2875  fhSameRowDiffColAndTCardCellsEnergyDiffClusterE[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2876  fhSameRowDiffColAndTCardCellsEnergyDiffClusterE[tm]->SetYTitle("#it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} (GeV)");
2877  outputContainer->Add(fhSameRowDiffColAndTCardCellsEnergyDiffClusterE[tm]);
2878 
2880  (Form("hSameRowDiffColAndTCardCellsTimeDiffClusterE%s",add[tm].Data()),
2881  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} vs #it{E}_{cluster} %s",add[tm].Data()),
2882  nptbins,ptmin,ptmax,tdbins,tdmin,tdmax);
2883  fhSameRowDiffColAndTCardCellsTimeDiffClusterE[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
2884  fhSameRowDiffColAndTCardCellsTimeDiffClusterE[tm]->SetYTitle("#it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} (ns)");
2885  outputContainer->Add(fhSameRowDiffColAndTCardCellsTimeDiffClusterE[tm]);
2886 
2888  (Form("hSameRowDiffColAndTCardCellsEnergyDiffCellMaxE%s",add[tm].Data()),
2889  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} vs #it{E}_{cell max} %s",add[tm].Data()),
2890  nptbins,ptmin,ptmax,200,-10,10);
2891  fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxE[tm]->SetXTitle("#it{E}_{cell max} (GeV)");
2892  fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxE[tm]->SetYTitle("#it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} (GeV)");
2893  outputContainer->Add(fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxE[tm]);
2894 
2896  (Form("hSameRowDiffColAndTCardCellsTimeDiffCellMaxE%s",add[tm].Data()),
2897  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} vs #it{E}_{cell max} %s",add[tm].Data()),
2898  nptbins,ptmin,ptmax,tdbins,tdmin,tdmax);
2899  fhSameRowDiffColAndTCardCellsTimeDiffCellMaxE[tm]->SetXTitle("#it{E}_{cell max} (GeV)");
2900  fhSameRowDiffColAndTCardCellsTimeDiffCellMaxE[tm]->SetYTitle("#it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} (ns)");
2901  outputContainer->Add(fhSameRowDiffColAndTCardCellsTimeDiffCellMaxE[tm]);
2902 
2903  if(fStudyExotic)
2904  {
2905  fhEnergyTime1Cell[tm] = new TH2F
2906  (Form("hEnergyTime1Cell%s",add[tm].Data()),
2907  Form("#it{t} vs #it{E}, 1 cells cluster %s",add[tm].Data()),
2908  nptbins,ptmin,ptmax,ntimebins,timemin,timemax);
2909  fhEnergyTime1Cell[tm]->SetXTitle("#it{E} (GeV)");
2910  fhEnergyTime1Cell[tm]->SetYTitle("#it{t} (ns)");
2911  outputContainer->Add(fhEnergyTime1Cell[tm]);
2912 
2913  fhEnergyTimeExotic[tm] = new TH2F
2914  (Form("hEnergyTimeExotic%s",add[tm].Data()),
2915  Form("#it{t} vs #it{E}, exo > 0.97, %s",add[tm].Data()),
2916  nptbins,ptmin,ptmax,ntimebins,timemin,timemax);
2917  fhEnergyTimeExotic[tm]->SetXTitle("#it{E} (GeV)");
2918  fhEnergyTimeExotic[tm]->SetYTitle("#it{t} (ns)");
2919  outputContainer->Add(fhEnergyTimeExotic[tm]);
2920 
2922  (Form("hEnergyTimeTCardCorrNoSelection1Cell%s",add[tm].Data()),
2923  Form("#it{t} vs #it{E}, 1 cells cluster %s",add[tm].Data()),
2924  nptbins,ptmin,ptmax,ntimebins,timemin,timemax);
2925  fhEnergyTimeTCardCorrNoSelection1Cell[tm]->SetXTitle("#it{E} (GeV)");
2926  fhEnergyTimeTCardCorrNoSelection1Cell[tm]->SetYTitle("#it{t} (ns)");
2927  outputContainer->Add(fhEnergyTimeTCardCorrNoSelection1Cell[tm]);
2928 
2930  (Form("hEnergyTimeTCardCorrNoSelectionExotic%s",add[tm].Data()),
2931  Form("#it{t} vs #it{E}, exo > 0.97, %s",add[tm].Data()),
2932  nptbins,ptmin,ptmax,ntimebins,timemin,timemax);
2933  fhEnergyTimeTCardCorrNoSelectionExotic[tm]->SetXTitle("#it{E} (GeV)");
2934  fhEnergyTimeTCardCorrNoSelectionExotic[tm]->SetYTitle("#it{t} (ns)");
2935  outputContainer->Add(fhEnergyTimeTCardCorrNoSelectionExotic[tm]);
2936 
2937  fhColRowExoticLowE1Cell[tm] = new TH2F
2938  (Form("hColRowExoticLowE1Cell%s",add[tm].Data()),
2939  Form("column vs row, 1 cell, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
2940  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2941  fhColRowExoticLowE1Cell[tm]->SetYTitle("row");
2942  fhColRowExoticLowE1Cell[tm]->SetXTitle("column");
2943  outputContainer->Add(fhColRowExoticLowE1Cell[tm]) ;
2944 
2945  fhColRowExoticHighE1Cell[tm] = new TH2F
2946  (Form("hColRowExoticHighE1Cell%s",add[tm].Data()),
2947  Form("column vs row, 1 cell, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
2948  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2949  fhColRowExoticHighE1Cell[tm]->SetYTitle("row");
2950  fhColRowExoticHighE1Cell[tm]->SetXTitle("column");
2951  outputContainer->Add(fhColRowExoticHighE1Cell[tm]) ;
2952 
2953  fhColRowExoticLowE[tm] = new TH2F
2954  (Form("hColRowExoticLowE%s",add[tm].Data()),
2955  Form("column vs row, max E cell, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
2956  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2957  fhColRowExoticLowE[tm]->SetYTitle("row");
2958  fhColRowExoticLowE[tm]->SetXTitle("column");
2959  outputContainer->Add(fhColRowExoticLowE[tm]) ;
2960 
2961  fhColRowExoticHighE[tm] = new TH2F
2962  (Form("hColRowExoticHighE%s",add[tm].Data()),
2963  Form("column vs row, max E cell, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
2964  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2965  fhColRowExoticHighE[tm]->SetYTitle("row");
2966  fhColRowExoticHighE[tm]->SetXTitle("column");
2967  outputContainer->Add(fhColRowExoticHighE[tm]) ;
2968 
2970  (Form("hColRowExotic2ndCellDiffLowE%s",add[tm].Data()),
2971  Form("column vs row, max E cell, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
2972  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2973  fhColRowExotic2ndCellDiffLowE[tm]->SetYTitle("row");
2974  fhColRowExotic2ndCellDiffLowE[tm]->SetXTitle("column");
2975  outputContainer->Add(fhColRowExotic2ndCellDiffLowE[tm]) ;
2976 
2978  (Form("hColRowExotic2ndCellDiffHighE%s",add[tm].Data()),
2979  Form("column vs row, max E cell, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
2980  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2981  fhColRowExotic2ndCellDiffHighE[tm]->SetYTitle("row");
2982  fhColRowExotic2ndCellDiffHighE[tm]->SetXTitle("column");
2983  outputContainer->Add(fhColRowExotic2ndCellDiffHighE[tm]) ;
2984 
2986  (Form("hColRowExotic2ndCellSameLowE%s",add[tm].Data()),
2987  Form("column vs row, max E cell, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
2988  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2989  fhColRowExotic2ndCellSameLowE[tm]->SetYTitle("row");
2990  fhColRowExotic2ndCellSameLowE[tm]->SetXTitle("column");
2991  outputContainer->Add(fhColRowExotic2ndCellSameLowE[tm]) ;
2992 
2994  (Form("hColRowExotic2ndCellSameHighE%s",add[tm].Data()),
2995  Form("column vs row, max E cell, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
2996  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
2997  fhColRowExotic2ndCellSameHighE[tm]->SetYTitle("row");
2998  fhColRowExotic2ndCellSameHighE[tm]->SetXTitle("column");
2999  outputContainer->Add(fhColRowExotic2ndCellSameHighE[tm]) ;
3000 
3002  (Form("hColRowTCardCorrNoSelectionExoticLowE%s",add[tm].Data()),
3003  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
3004  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3005  fhColRowTCardCorrNoSelectionExoticLowE[tm]->SetYTitle("row");
3006  fhColRowTCardCorrNoSelectionExoticLowE[tm]->SetXTitle("column");
3007  outputContainer->Add(fhColRowTCardCorrNoSelectionExoticLowE[tm]) ;
3008 
3010  (Form("hColRowTCardCorrNoSelectionExoticHighE%s",add[tm].Data()),
3011  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
3012  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3013  fhColRowTCardCorrNoSelectionExoticHighE[tm]->SetYTitle("row");
3014  fhColRowTCardCorrNoSelectionExoticHighE[tm]->SetXTitle("column");
3015  outputContainer->Add(fhColRowTCardCorrNoSelectionExoticHighE[tm]) ;
3016 
3018  (Form("hColRowTCardCorrNoSelectionExotic2ndCellDiffLowE%s",add[tm].Data()),
3019  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
3020  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3022  fhColRowTCardCorrNoSelectionExotic2ndCellDiffLowE[tm]->SetXTitle("column");
3023  outputContainer->Add(fhColRowTCardCorrNoSelectionExotic2ndCellDiffLowE[tm]) ;
3024 
3026  (Form("hColRowTCardCorrNoSelectionExotic2ndCellDiffHighE%s",add[tm].Data()),
3027  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
3028  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3030  fhColRowTCardCorrNoSelectionExotic2ndCellDiffHighE[tm]->SetXTitle("column");
3031  outputContainer->Add(fhColRowTCardCorrNoSelectionExotic2ndCellDiffHighE[tm]) ;
3032 
3034  (Form("hColRowTCardCorrNoSelectionExotic2ndCellSameLowE%s",add[tm].Data()),
3035  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
3036  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3038  fhColRowTCardCorrNoSelectionExotic2ndCellSameLowE[tm]->SetXTitle("column");
3039  outputContainer->Add(fhColRowTCardCorrNoSelectionExotic2ndCellSameLowE[tm]) ;
3040 
3042  (Form("hColRowTCardCorrNoSelectionExotic2ndCellSameHighE%s",add[tm].Data()),
3043  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
3044  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3046  fhColRowTCardCorrNoSelectionExotic2ndCellSameHighE[tm]->SetXTitle("column");
3047  outputContainer->Add(fhColRowTCardCorrNoSelectionExotic2ndCellSameHighE[tm]) ;
3048 
3050  (Form("hColRowTCardCorrNoSelectionExotic2ndCellDiffNoSameLowE%s",add[tm].Data()),
3051  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
3052  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3056 
3058  (Form("hColRowTCardCorrNoSelectionExotic2ndCellDiffNoSameHighE%s",add[tm].Data()),
3059  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
3060  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3064 
3066  (Form("hColRowTCardCorrNoSelectionExotic2ndCellSameNoDiffLowE%s",add[tm].Data()),
3067  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, 5 < E < 8 GeV %s",add[tm].Data()),
3068  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3072 
3074  (Form("hColRowTCardCorrNoSelectionExotic2ndCellSameNoDiffHighE%s",add[tm].Data()),
3075  Form("column vs row, max E cell for TCard correlation selected clusters, exo > 0.97, E > 8 GeV %s",add[tm].Data()),
3076  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3080 
3082  (Form("hNCellsTCardSameAndDiffFraction_Exotic%s",add[tm].Data()),
3083  Form("#it{n}_{cells} same TCard vs diff TCard fraction, w > 0.01, exo > 0.97 %s",add[tm].Data()),
3084  nptbins,ptmin,ptmax,100,0,1);
3085  fhNCellsTCardSameAndDiffFractionExotic[tm]->SetXTitle("#it{E} (GeV)");
3086  fhNCellsTCardSameAndDiffFractionExotic[tm]->SetYTitle("#it{n}_{cells} - same TCard / #it{n}_{cells} - total");
3087  outputContainer->Add(fhNCellsTCardSameAndDiffFractionExotic[tm]);
3088 
3090  (Form("hSameRowDiffColAndTCardCellsEnergyDiffClusterEExo%s",add[tm].Data()),
3091  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} vs #it{E}_{cluster}, exo > 0.97 %s",add[tm].Data()),
3092  nptbins,ptmin,ptmax,200,-10,10);
3093  fhSameRowDiffColAndTCardCellsEnergyDiffClusterEExo[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3094  fhSameRowDiffColAndTCardCellsEnergyDiffClusterEExo[tm]->SetYTitle("#it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} (GeV)");
3095  outputContainer->Add(fhSameRowDiffColAndTCardCellsEnergyDiffClusterEExo[tm]);
3096 
3098  (Form("hSameRowDiffColAndTCardCellsTimeDiffClusterEExo%s",add[tm].Data()),
3099  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} vs #it{E}_{cluster}, exo > 0.97 %s",add[tm].Data()),
3100  nptbins,ptmin,ptmax,tdbins,tdmin,tdmax);
3101  fhSameRowDiffColAndTCardCellsTimeDiffClusterEExo[tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3102  fhSameRowDiffColAndTCardCellsTimeDiffClusterEExo[tm]->SetYTitle("#it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} (ns)");
3103  outputContainer->Add(fhSameRowDiffColAndTCardCellsTimeDiffClusterEExo[tm]);
3104 
3106  (Form("hSameRowDiffColAndTCardCellsEnergyDiffCellMaxEExo%s",add[tm].Data()),
3107  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} vs #it{E}_{cell max}, exo > 0.97 %s",add[tm].Data()),
3108  nptbins,ptmin,ptmax,200,-10,10);
3109  fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxEExo[tm]->SetXTitle("#it{E}_{cell max} (GeV)");
3110  fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxEExo[tm]->SetYTitle("#it{E}_{cell}^{same TCard}-#it{E}_{cell}^{diff TCard} (GeV)");
3111  outputContainer->Add(fhSameRowDiffColAndTCardCellsEnergyDiffCellMaxEExo[tm]);
3112 
3114  (Form("hSameRowDiffColAndTCardCellsTimeDiffCellMaxEExo%s",add[tm].Data()),
3115  Form("#Delta row = 0, |#Delta col = 1|, with respect to leading cell, #it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} vs #it{E}_{cell max}, exo > 0.97 %s",add[tm].Data()),
3116  nptbins,ptmin,ptmax,tdbins,tdmin,tdmax);
3117  fhSameRowDiffColAndTCardCellsTimeDiffCellMaxEExo[tm]->SetXTitle("#it{E}_{cell max} (GeV)");
3118  fhSameRowDiffColAndTCardCellsTimeDiffCellMaxEExo[tm]->SetYTitle("#it{t}_{cell}^{same TCard}-#it{t}_{cell}^{diff TCard} (ns)");
3119  outputContainer->Add(fhSameRowDiffColAndTCardCellsTimeDiffCellMaxEExo[tm]);
3120  }
3121 
3122  for(Int_t i = 0; i < 6; i++)
3123  {
3124  for(Int_t j = 0; j < 6; j++)
3125  {
3126  fhLambda0TCardCorrelNCell[i][j][tm] = new TH2F
3127  (Form("hLambda0TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3128  Form("#sigma^{2}_{long} vs #it{E}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3129  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3130  fhLambda0TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3131  fhLambda0TCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{long}");
3132  outputContainer->Add(fhLambda0TCardCorrelNCell[i][j][tm]);
3133 
3134  fhLambda1TCardCorrelNCell[i][j][tm] = new TH2F
3135  (Form("hLambda1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3136  Form("#sigma^{2}_{short} vs #it{E}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3137  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3138  fhLambda1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3139  fhLambda1TCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{short}");
3140  outputContainer->Add(fhLambda1TCardCorrelNCell[i][j][tm]);
3141 
3142  // fhLambdaRTCardCorrelNCell[i][j][tm] = new TH2F
3143  // (Form("hLambdaRTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3144  // Form("#sigma^{2}_{short}/#sigma^{2}_{long} vs #it{E}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3145  // nptbins,ptmin,ptmax,110,0,1.1);
3146  // fhLambdaRTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3147  // fhLambdaRTCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{short}/#sigma^{2}_{long}");
3148  // outputContainer->Add(fhLambdaRTCardCorrelNCell[i][j][tm]);
3149 
3150  if ( fFillNLocMaxHistos )
3151  {
3152  fhLambda0NLM1TCardCorrelNCell[i][j][tm] = new TH2F
3153  (Form("hLambda0NLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3154  Form("#sigma^{2}_{long} vs #it{E}, nlm=1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3155  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3156  fhLambda0NLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3157  fhLambda0NLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{long}");
3158  outputContainer->Add(fhLambda0NLM1TCardCorrelNCell[i][j][tm]);
3159 
3160  fhLambda1NLM1TCardCorrelNCell[i][j][tm] = new TH2F
3161  (Form("hLambda1NLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3162  Form("#sigma^{2}_{short} vs #it{E}, nlm=1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3163  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3164  fhLambda1NLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3165  fhLambda1NLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{short}");
3166  outputContainer->Add(fhLambda1NLM1TCardCorrelNCell[i][j][tm]);
3167 
3168  fhLambda0NLM2TCardCorrelNCell[i][j][tm] = new TH2F
3169  (Form("hLambda0NLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3170  Form("#sigma^{2}_{long} vs #it{E}, nlm=2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3171  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3172  fhLambda0NLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3173  fhLambda0NLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{long}");
3174  outputContainer->Add(fhLambda0NLM2TCardCorrelNCell[i][j][tm]);
3175 
3176  fhLambda1NLM2TCardCorrelNCell[i][j][tm] = new TH2F
3177  (Form("hLambda1NLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3178  Form("#sigma^{2}_{short} vs #it{E}, nlm=2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3179  nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3180  fhLambda1NLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3181  fhLambda1NLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#sigma^{2}_{short}");
3182  outputContainer->Add(fhLambda1NLM2TCardCorrelNCell[i][j][tm]);
3183 
3184  fhNLocMaxTCardCorrelNCell[i][j][tm] = new TH2F
3185  (Form("hNLocMaxTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3186  Form("#it{n}_{LM} vs #it{E}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3187  nptbins,ptmin,ptmax,10,0,10);
3188  fhNLocMaxTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3189  fhNLocMaxTCardCorrelNCell[i][j][tm]->SetYTitle("#it{n}_{LM}");
3190  outputContainer->Add(fhNLocMaxTCardCorrelNCell[i][j][tm]);
3191 
3192  fhEMaxRatNLM1TCardCorrelNCell[i][j][tm] = new TH2F
3193  (Form("hEMaxRatNLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3194  Form("#it{E}_{cell}^{max}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} = 1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3195  nptbins,ptmin,ptmax,100,0,1);
3196  fhEMaxRatNLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3197  fhEMaxRatNLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}");
3198  outputContainer->Add(fhEMaxRatNLM1TCardCorrelNCell[i][j][tm]);
3199 
3200  fhEMaxRatNLM2TCardCorrelNCell[i][j][tm] = new TH2F
3201  (Form("hEMaxRatNLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3202  Form("#it{E}_{cell}^{max}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} = 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3203  nptbins,ptmin,ptmax,100,0,1);
3204  fhEMaxRatNLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3205  fhEMaxRatNLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}");
3206  outputContainer->Add(fhEMaxRatNLM2TCardCorrelNCell[i][j][tm]);
3207 
3208  fhEMaxRatNLM3TCardCorrelNCell[i][j][tm] = new TH2F
3209  (Form("hEMaxRatNLM3TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3210  Form("#it{E}_{cell}^{max}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} > 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3211  nptbins,ptmin,ptmax,100,0,1);
3212  fhEMaxRatNLM3TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3213  fhEMaxRatNLM3TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{max}/#it{E}_{cluster}");
3214  outputContainer->Add(fhEMaxRatNLM3TCardCorrelNCell[i][j][tm]);
3215 
3216  fhE2ndRatNLM1TCardCorrelNCell[i][j][tm] = new TH2F
3217  (Form("hE2ndRatNLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3218  Form("#it{E}_{cell}^{2nd max}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} = 1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3219  nptbins,ptmin,ptmax,100,0,1);
3220  fhE2ndRatNLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3221  fhE2ndRatNLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{2nd max}/#it{E}_{cluster}");
3222  outputContainer->Add(fhE2ndRatNLM1TCardCorrelNCell[i][j][tm]);
3223 
3224  fhE2ndRatNLM2TCardCorrelNCell[i][j][tm] = new TH2F
3225  (Form("hE2ndRatNLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3226  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} = 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3227  nptbins,ptmin,ptmax,100,0,1);
3228  fhE2ndRatNLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3229  fhE2ndRatNLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster}");
3230  outputContainer->Add(fhE2ndRatNLM2TCardCorrelNCell[i][j][tm]);
3231 
3232  fhE2ndRatNLM3TCardCorrelNCell[i][j][tm] = new TH2F
3233  (Form("hE2ndRatNLM3TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3234  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} > 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3235  nptbins,ptmin,ptmax,100,0,1);
3236  fhE2ndRatNLM3TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3237  fhE2ndRatNLM3TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster}");
3238  outputContainer->Add(fhE2ndRatNLM3TCardCorrelNCell[i][j][tm]);
3239 
3240  fhE2ndEMaxRatNLM1TCardCorrelNCell[i][j][tm] = new TH2F
3241  (Form("hE2ndEMaxRatNLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3242  Form("#it{E}_{cell}^{2nd max}/#it{E}_{cell}^{max} vs #it{E}_{cluster}, #it{n}_{LM} = 1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3243  nptbins,ptmin,ptmax,100,0,1);
3244  fhE2ndEMaxRatNLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3245  fhE2ndEMaxRatNLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{2nd max}/#it{E}_{cell}^{max}");
3246  outputContainer->Add(fhE2ndEMaxRatNLM1TCardCorrelNCell[i][j][tm]);
3247 
3248  fhE2ndEMaxRatNLM2TCardCorrelNCell[i][j][tm] = new TH2F
3249  (Form("hE2ndEMaxRatNLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3250  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max} vs #it{E}_{cluster}, #it{n}_{LM} = 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3251  nptbins,ptmin,ptmax,100,0,1);
3252  fhE2ndEMaxRatNLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3253  fhE2ndEMaxRatNLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max}");
3254  outputContainer->Add(fhE2ndEMaxRatNLM2TCardCorrelNCell[i][j][tm]);
3255 
3256  fhE2ndEMaxRatNLM3TCardCorrelNCell[i][j][tm] = new TH2F
3257  (Form("hE2ndEMaxRatNLM3TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3258  Form("#it{E}_{cell}^{2nd loc max}/#it{E}_{cluster} vs #it{E}_{cell}^{max}, #it{n}_{LM} > 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3259  nptbins,ptmin,ptmax,100,0,1);
3260  fhE2ndEMaxRatNLM3TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3261  fhE2ndEMaxRatNLM3TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}^{2nd loc max}/#it{E}_{cell}^{max}");
3262  outputContainer->Add(fhE2ndEMaxRatNLM3TCardCorrelNCell[i][j][tm]);
3263 
3264 
3265  fhECellClusRatNLM1TCardCorrelNCell[i][j][tm] = new TH2F
3266  (Form("hECellClusRatNLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3267  Form("#it{E}_{cell}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} = 1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3268  nptbins,ptmin,ptmax,100,0,1);
3269  fhECellClusRatNLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3270  fhECellClusRatNLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
3271  outputContainer->Add(fhECellClusRatNLM1TCardCorrelNCell[i][j][tm]);
3272 
3273  fhECellClusRatNLM2TCardCorrelNCell[i][j][tm] = new TH2F
3274  (Form("hECellClusRatNLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3275  Form("#it{E}_{cell}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} = 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3276  nptbins,ptmin,ptmax,100,0,1);
3277  fhECellClusRatNLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3278  fhECellClusRatNLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
3279  outputContainer->Add(fhECellClusRatNLM2TCardCorrelNCell[i][j][tm]);
3280 
3281  fhECellClusRatNLM3TCardCorrelNCell[i][j][tm] = new TH2F
3282  (Form("hECellClusRatNLM3TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3283  Form("#it{E}_{cell}/#it{E}_{cluster} vs #it{E}_{cluster}, #it{n}_{LM} > 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3284  nptbins,ptmin,ptmax,100,0,1);
3285  fhECellClusRatNLM3TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3286  fhECellClusRatNLM3TCardCorrelNCell[i][j][tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
3287  outputContainer->Add(fhECellClusRatNLM3TCardCorrelNCell[i][j][tm]);
3288 
3289  fhLogECellNLM1TCardCorrelNCell[i][j][tm] = new TH2F
3290  (Form("hLogECellNLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3291  Form("log(#it{E}_{cell}) vs #it{E}_{cluster}, #it{n}_{LM} = 1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3292  nptbins,ptmin,ptmax,150,-3,3);
3293  fhLogECellNLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3294  fhLogECellNLM1TCardCorrelNCell[i][j][tm]->SetYTitle("log(#it{E}_{cell})");
3295  outputContainer->Add(fhLogECellNLM1TCardCorrelNCell[i][j][tm]);
3296 
3297  fhLogECellNLM2TCardCorrelNCell[i][j][tm] = new TH2F
3298  (Form("hLogECellNLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3299  Form("log(#it{E}_{cell}) vs #it{E}_{cluster}, #it{n}_{LM} = 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3300  nptbins,ptmin,ptmax,150,-3,3);
3301  fhLogECellNLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3302  fhLogECellNLM2TCardCorrelNCell[i][j][tm]->SetYTitle("log(#it{E}_{cell})");
3303  outputContainer->Add(fhLogECellNLM2TCardCorrelNCell[i][j][tm]);
3304 
3305  fhLogECellNLM3TCardCorrelNCell[i][j][tm] = new TH2F
3306  (Form("hLogECellNLM3TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3307  Form("log(#it{E}_{cell}) vs #it{E}_{cluster}, #it{n}_{LM} > 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3308  nptbins,ptmin,ptmax,150,-3,3);
3309  fhLogECellNLM3TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3310  fhLogECellNLM3TCardCorrelNCell[i][j][tm]->SetYTitle("log(#it{E}_{cell})");
3311  outputContainer->Add(fhLogECellNLM3TCardCorrelNCell[i][j][tm]);
3312 
3313  fhECellWeightNLM1TCardCorrelNCell[i][j][tm] = new TH2F
3314  (Form("hECellWeightNLM1TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3315  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs #it{E}_{cluster}, #it{n}_{LM} = 1, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3316  nptbins,ptmin,ptmax,90,0,4.5);
3317  fhECellWeightNLM1TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3318  fhECellWeightNLM1TCardCorrelNCell[i][j][tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
3319  outputContainer->Add(fhECellWeightNLM1TCardCorrelNCell[i][j][tm]);
3320 
3321  fhECellWeightNLM2TCardCorrelNCell[i][j][tm] = new TH2F
3322  (Form("hECellWeightNLM2TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3323  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs #it{E}_{cluster}, #it{n}_{LM} = 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3324  nptbins,ptmin,ptmax,90,0,4.5);
3325  fhECellWeightNLM2TCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3326  fhECellWeightNLM2TCardCorrelNCell[i][j][tm]->SetYTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
3327  outputContainer->Add(fhECellWeightNLM2TCardCorrelNCell[i][j][tm]);
3328 
3329  fhECellWeightNLM3TCardCorrelNCell[i][j][tm] = new TH2F
3330  (Form("hECellWeightNLM3TCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3331  Form("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster})) vs #it{E}_{cluster}, #it{n}_{LM} > 2, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3332  nptbins,ptmin,ptmax,90,0,4.5);
3333  fhECellWeightNLM3TCardCorrelNCell[i][j][tm]->SetXTitle("#it{w}=Max(4,5+log(#it{E}_{cell}/#it{E}_{cluster}))");
3334  fhECellWeightNLM3TCardCorrelNCell[i][j][tm]->SetYTitle("Log. weight");
3335  outputContainer->Add(fhECellWeightNLM3TCardCorrelNCell[i][j][tm]);
3336  } // NLM histos
3337 
3338  if ( fStudyInvMass )
3339  {
3340  fhMassEClusTCardCorrelNCell[i][j][tm] = new TH2F
3341  (Form("hMassEClusTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3342  Form("#it{M}_{#gamma #gamma} vs #it{E}_{cluster}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3343  nptbins,ptmin,ptmax,nmassbins,massmin,massmax);
3344  fhMassEClusTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{cluster} (GeV)");
3345  fhMassEClusTCardCorrelNCell[i][j][tm]->SetYTitle("#it{M}_{#gamma #gamma}");
3346  outputContainer->Add(fhMassEClusTCardCorrelNCell[i][j][tm]);
3347 
3348  // fhMassEPairTCardCorrelNCell[i][j][tm] = new TH2F
3349  // (Form("hMassEPairTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3350  // Form("#it{M}_{#gamma #gamma} vs #it{E}_{pair}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3351  // nptbins,ptmin,ptmax,nmassbins,massmin,massmax);
3352  // fhMassEPairTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E}_{pair} (GeV)");
3353  // fhMassEPairTCardCorrelNCell[i][j][tm]->SetYTitle("#it{M}_{#gamma #gamma}");
3354  // outputContainer->Add(fhMassEPairTCardCorrelNCell[i][j][tm]);
3355  }
3356 
3357  fhTimeDiffTCardCorrelNCell[i][j][tm] = new TH2F
3358  (Form("hTimeDiffTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3359  Form("#it{t}_{cell}^{max}-#it{t}_{cell}^{other} vs #it{E}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3360  nptbins,ptmin,ptmax,tdbins,tdmin,tdmax);
3361  fhTimeDiffTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3362  fhTimeDiffTCardCorrelNCell[i][j][tm]->SetYTitle("#it{t}_{cell}^{max}-#it{t}_{cell}^{other}");
3363  outputContainer->Add(fhTimeDiffTCardCorrelNCell[i][j][tm]);
3364 
3365  fhColRowTCardCorrelNCellLowE[i][j][tm] = new TH2F
3366  (Form("hColRowTCardCorrelNCellLowE_Same%d_Diff%d%s",i,j,add[tm].Data()),
3367  Form("column vs row, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3368  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3369  fhColRowTCardCorrelNCellLowE[i][j][tm]->SetYTitle("row");
3370  fhColRowTCardCorrelNCellLowE[i][j][tm]->SetXTitle("column");
3371  outputContainer->Add(fhColRowTCardCorrelNCellLowE[i][j][tm]) ;
3372 
3373  fhColRowTCardCorrelNCellHighE[i][j][tm] = new TH2F
3374  (Form("hColRowTCardCorrelNCellHighE_Same%d_Diff%d%s",i,j,add[tm].Data()),
3375  Form("column vs row,N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3376  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3377  fhColRowTCardCorrelNCellHighE[i][j][tm]->SetYTitle("row");
3378  fhColRowTCardCorrelNCellHighE[i][j][tm]->SetXTitle("column");
3379  outputContainer->Add(fhColRowTCardCorrelNCellHighE[i][j][tm]) ;
3380 
3381  if(fStudyExotic)
3382  {
3383  fhExoticTCardCorrelNCell[i][j][tm] = new TH2F
3384  (Form("hExoticTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3385  Form("exoticity vs #it{E}, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3386  nptbins,ptmin,ptmax,200,-1,1);
3387  fhExoticTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3388  fhExoticTCardCorrelNCell[i][j][tm]->SetYTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3389  outputContainer->Add(fhExoticTCardCorrelNCell[i][j][tm]);
3390 
3391  fhTimeDiffExoTCardCorrelNCell[i][j][tm] = new TH2F
3392  (Form("hTimeDiffExoTCardCorrelNCell_Same%d_Diff%d%s",i,j,add[tm].Data()),
3393  Form("#it{t}_{cell}^{max}-#it{t}_{cell}^{other} vs #it{E}, N cells with w > 0.01, exoticity > 0.97, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3394  nptbins,ptmin,ptmax,tdbins,tdmin,tdmax);
3395  fhTimeDiffExoTCardCorrelNCell[i][j][tm]->SetXTitle("#it{E} (GeV)");
3396  fhTimeDiffExoTCardCorrelNCell[i][j][tm]->SetYTitle("#it{t}_{cell}^{max}-#it{t}_{cell}^{other}");
3397  outputContainer->Add(fhTimeDiffExoTCardCorrelNCell[i][j][tm]);
3398 
3400  (Form("hColRowTCardCorrelNCellExoticLowE_Same%d_Diff%d%s",i,j,add[tm].Data()),
3401  Form("column vs row, N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3402  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3403  fhColRowTCardCorrelNCellExoticLowE[i][j][tm]->SetYTitle("row");
3404  fhColRowTCardCorrelNCellExoticLowE[i][j][tm]->SetXTitle("column");
3405  outputContainer->Add(fhColRowTCardCorrelNCellExoticLowE[i][j][tm]) ;
3406 
3408  (Form("hColRowTCardCorrelNCellExoticHighE_Same%d_Diff%d%s",i,j,add[tm].Data()),
3409  Form("column vs row,N cells with w > 0.01, TCard same = %d, diff =%d %s",i,j,add[tm].Data()),
3410  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3411  fhColRowTCardCorrelNCellExoticHighE[i][j][tm]->SetYTitle("row");
3412  fhColRowTCardCorrelNCellExoticHighE[i][j][tm]->SetXTitle("column");
3413  outputContainer->Add(fhColRowTCardCorrelNCellExoticHighE[i][j][tm]) ;
3414  }
3415  }
3416 
3419 
3420  // fhLambda0TCardCorrelN[i][tm] = new TH2F
3421  // (Form("hLambda0TCardCorrelN_Case%d%s",i,add[tm].Data()),
3422  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, N corr = %d %s",i,add[tm].Data()),
3423  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3424  // fhLambda0TCardCorrelN[i][tm]->SetXTitle("#it{E} (GeV)");
3425  // fhLambda0TCardCorrelN[i][tm]->SetYTitle("#sigma^{2}_{long}");
3426  // outputContainer->Add(fhLambda0TCardCorrelN[i][tm]);
3427  //
3428  // fhNCellsTCardCorrelN[i][tm] = new TH2F
3429  // (Form("hNCellsTCardCorrelN_Case%d%s",i,add[tm].Data()),
3430  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, N corr = %d %s",i,add[tm].Data()),
3431  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3432  // fhNCellsTCardCorrelN[i][tm]->SetXTitle("#it{E} (GeV)");
3433  // fhNCellsTCardCorrelN[i][tm]->SetYTitle("#it{n}_{cells}");
3434  // outputContainer->Add(fhNCellsTCardCorrelN[i][tm]);
3435  //
3436  // fhExoticTCardCorrelN[i][tm] = new TH2F
3437  // (Form("hExoticTCardCorrelN_Case%d%s",i,add[tm].Data()),
3438  // Form("exoticity vs #it{E}, max E cell correl with TCard cell, N corr = %d %s",i,add[tm].Data()),
3439  // nptbins,ptmin,ptmax,200,-1,1);
3440  // fhExoticTCardCorrelN[i][tm]->SetXTitle("#it{E} (GeV)");
3441  // fhExoticTCardCorrelN[i][tm]->SetYTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3442  // outputContainer->Add(fhExoticTCardCorrelN[i][tm]);
3443  //
3444  // fhColRowTCardCorrelNLowE[i][tm] = new TH2F
3445  // (Form("hColRowTCardCorrelNLowE_Case%d%s",i,add[tm].Data()),
3446  // Form("column vs row, max E cell correl with TCard cell, E > 2 GeV, N corr = %d %s",i,add[tm].Data()),
3447  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3448  // fhColRowTCardCorrelNLowE[i][tm]->SetYTitle("row");
3449  // fhColRowTCardCorrelNLowE[i][tm]->SetXTitle("column");
3450  // outputContainer->Add(fhColRowTCardCorrelNLowE[i][tm]) ;
3451  //
3452  // fhColRowTCardCorrelNHighE[i][tm] = new TH2F
3453  // (Form("hColRowTCardCorrelNHighE_Case%d%s",i,add[tm].Data()),
3454  // Form("column vs row, max E cell correl with TCard cell, E > 8 GeV, N corr = %d %s",i,add[tm].Data()),
3455  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3456  // fhColRowTCardCorrelNHighE[i][tm]->SetYTitle("row");
3457  // fhColRowTCardCorrelNHighE[i][tm]->SetXTitle("column");
3458  // outputContainer->Add(fhColRowTCardCorrelNHighE[i][tm]) ;
3459  //
3460  // ////////
3461  // ////////
3462  //
3463  // fhLambda0TCardCorrelNExotic[i][tm] = new TH2F
3464  // (Form("hLambda0TCardCorrelN_Exotic_Case%d%s",i,add[tm].Data()),
3465  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, exo > 0.97, N corr = %d %s",i,add[tm].Data()),
3466  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3467  // fhLambda0TCardCorrelNExotic[i][tm]->SetXTitle("#it{E} (GeV)");
3468  // fhLambda0TCardCorrelNExotic[i][tm]->SetYTitle("#sigma^{2}_{long}");
3469  // outputContainer->Add(fhLambda0TCardCorrelNExotic[i][tm]);
3470  //
3471  // fhNCellsTCardCorrelNExotic[i][tm] = new TH2F
3472  // (Form("hNCellsTCardCorrelN_Exotic_Case%d%s",i,add[tm].Data()),
3473  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, exo > 0.97, N corr = %d %s",i,add[tm].Data()),
3474  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3475  // fhNCellsTCardCorrelNExotic[i][tm]->SetXTitle("#it{E} (GeV)");
3476  // fhNCellsTCardCorrelNExotic[i][tm]->SetYTitle("#it{n}_{cells}");
3477  // outputContainer->Add(fhNCellsTCardCorrelNExotic[i][tm]);
3478  //
3479  // fhColRowTCardCorrelNLowEExotic[i][tm] = new TH2F
3480  // (Form("hColRowTCardCorrelNLowEExotic_Case%d%s",i,add[tm].Data()),
3481  // Form("column vs row, max E cell correl with TCard cell, exo > 0.97, E > 2 GeV, N corr = %d %s",i,add[tm].Data()),
3482  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3483  // fhColRowTCardCorrelNLowEExotic[i][tm]->SetYTitle("row");
3484  // fhColRowTCardCorrelNLowEExotic[i][tm]->SetXTitle("column");
3485  // outputContainer->Add(fhColRowTCardCorrelNLowEExotic[i][tm]) ;
3486  //
3487  // fhColRowTCardCorrelNHighEExotic[i][tm] = new TH2F
3488  // (Form("hColRowTCardCorrelNHighEExotic_Case%d%s",i,add[tm].Data()),
3489  // Form("column vs row, max E cell correl with TCard cell, exo > 0.97, E > 8 GeV, N corr = %d %s",i,add[tm].Data()),
3490  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3491  // fhColRowTCardCorrelNHighEExotic[i][tm]->SetYTitle("row");
3492  // fhColRowTCardCorrelNHighEExotic[i][tm]->SetXTitle("column");
3493  // outputContainer->Add(fhColRowTCardCorrelNHighEExotic[i][tm]) ;
3494  //
3495  // ///////////
3496  // ///////////
3497  //
3498  // fhLambda0TCardCorrelNAllSameTCard[i][tm] = new TH2F
3499  // (Form("hLambda0TCardCorrelNAllSameTCard_Case%d%s",i,add[tm].Data()),
3500  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3501  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3502  // fhLambda0TCardCorrelNAllSameTCard[i][tm]->SetXTitle("#it{E} (GeV)");
3503  // fhLambda0TCardCorrelNAllSameTCard[i][tm]->SetYTitle("#sigma^{2}_{long}");
3504  // outputContainer->Add(fhLambda0TCardCorrelNAllSameTCard[i][tm]);
3505  //
3506  // fhNCellsTCardCorrelNAllSameTCard[i][tm] = new TH2F
3507  // (Form("hNCellsTCardCorrelNAllSameTCard_Case%d%s",i,add[tm].Data()),
3508  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3509  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3510  // fhNCellsTCardCorrelNAllSameTCard[i][tm]->SetXTitle("#it{E} (GeV)");
3511  // fhNCellsTCardCorrelNAllSameTCard[i][tm]->SetYTitle("#it{n}_{cells}");
3512  // outputContainer->Add(fhNCellsTCardCorrelNAllSameTCard[i][tm]);
3513  //
3514  // fhExoticTCardCorrelNAllSameTCard[i][tm] = new TH2F
3515  // (Form("hExoticTCardCorrelNAllSameTCard_Case%d%s",i,add[tm].Data()),
3516  // Form("exoticity vs #it{E}, max E cell correl with TCard cell, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3517  // nptbins,ptmin,ptmax,200,-1,1);
3518  // fhExoticTCardCorrelNAllSameTCard[i][tm]->SetXTitle("#it{E} (GeV)");
3519  // fhExoticTCardCorrelNAllSameTCard[i][tm]->SetYTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3520  // outputContainer->Add(fhExoticTCardCorrelNAllSameTCard[i][tm]);
3521  //
3522  // fhColRowTCardCorrelNAllSameTCardLowE[i][tm] = new TH2F
3523  // (Form("hColRowTCardCorrelNAllSameTCardLowE_Case%d%s",i,add[tm].Data()),
3524  // Form("column vs row, max E cell correl with TCard cell, E > 2 GeV, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3525  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3526  // fhColRowTCardCorrelNAllSameTCardLowE[i][tm]->SetYTitle("row");
3527  // fhColRowTCardCorrelNAllSameTCardLowE[i][tm]->SetXTitle("column");
3528  // outputContainer->Add(fhColRowTCardCorrelNAllSameTCardLowE[i][tm]) ;
3529  //
3530  // fhColRowTCardCorrelNAllSameTCardHighE[i][tm] = new TH2F
3531  // (Form("hColRowTCardCorrelNAllSameTCardHighE_Case%d%s",i,add[tm].Data()),
3532  // Form("column vs row, max E cell correl with TCard cell, E > 8 GeV, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3533  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3534  // fhColRowTCardCorrelNAllSameTCardHighE[i][tm]->SetYTitle("row");
3535  // fhColRowTCardCorrelNAllSameTCardHighE[i][tm]->SetXTitle("column");
3536  // outputContainer->Add(fhColRowTCardCorrelNAllSameTCardHighE[i][tm]) ;
3537  //
3538  // ////////
3539  //
3540  // fhLambda0TCardCorrelNAllSameTCardExotic[i][tm] = new TH2F
3541  // (Form("hLambda0TCardCorrelNAllSameTCard_Exotic_Case%d%s",i,add[tm].Data()),
3542  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, exo > 0.97, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3543  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3544  // fhLambda0TCardCorrelNAllSameTCardExotic[i][tm]->SetXTitle("#it{E} (GeV)");
3545  // fhLambda0TCardCorrelNAllSameTCardExotic[i][tm]->SetYTitle("#sigma^{2}_{long}");
3546  // outputContainer->Add(fhLambda0TCardCorrelNAllSameTCardExotic[i][tm]);
3547  //
3548  // fhNCellsTCardCorrelNAllSameTCardExotic[i][tm] = new TH2F
3549  // (Form("hNCellsTCardCorrelNAllSameTCard_Exotic_Case%d%s",i,add[tm].Data()),
3550  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, exo > 0.97, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3551  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3552  // fhNCellsTCardCorrelNAllSameTCardExotic[i][tm]->SetXTitle("#it{E} (GeV)");
3553  // fhNCellsTCardCorrelNAllSameTCardExotic[i][tm]->SetYTitle("#it{n}_{cells}");
3554  // outputContainer->Add(fhNCellsTCardCorrelNAllSameTCardExotic[i][tm]);
3555  //
3556  // fhColRowTCardCorrelNAllSameTCardLowEExotic[i][tm] = new TH2F
3557  // (Form("hColRowTCardCorrelNAllSameTCardLowEExotic_Case%d%s",i,add[tm].Data()),
3558  // Form("column vs row, max E cell correl with TCard cell, exo > 0.97, E > 2 GeV, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3559  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3560  // fhColRowTCardCorrelNAllSameTCardLowEExotic[i][tm]->SetYTitle("row");
3561  // fhColRowTCardCorrelNAllSameTCardLowEExotic[i][tm]->SetXTitle("column");
3562  // outputContainer->Add(fhColRowTCardCorrelNAllSameTCardLowEExotic[i][tm]) ;
3563  //
3564  // fhColRowTCardCorrelNAllSameTCardHighEExotic[i][tm] = new TH2F
3565  // (Form("hColRowTCardCorrelNAllSameTCardHighEExotic_Case%d%s",i,add[tm].Data()),
3566  // Form("column vs row, max E cell correl with TCard cell, exo > 0.97, E > 8 GeV, N corr = %d, no other TCard cells %s",i,add[tm].Data()),
3567  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3568  // fhColRowTCardCorrelNAllSameTCardHighEExotic[i][tm]->SetYTitle("row");
3569  // fhColRowTCardCorrelNAllSameTCardHighEExotic[i][tm]->SetXTitle("column");
3570  // outputContainer->Add(fhColRowTCardCorrelNAllSameTCardHighEExotic[i][tm]) ;
3571  }
3572 
3573  // for(Int_t i = 0; i < 7; i++)
3574  // {
3575  // fhLambda0TCardCorrel[i][tm] = new TH2F
3576  // (Form("hLambda0TCardCorrel_Case%d%s",i,add[tm].Data()),
3577  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, case %d %s",i,add[tm].Data()),
3578  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3579  // fhLambda0TCardCorrel[i][tm]->SetXTitle("#it{E} (GeV)");
3580  // fhLambda0TCardCorrel[i][tm]->SetYTitle("#sigma^{2}_{long}");
3581  // outputContainer->Add(fhLambda0TCardCorrel[i][tm]);
3582  //
3583  // fhNCellsTCardCorrel[i][tm] = new TH2F
3584  // (Form("hNCellsTCardCorrel_Case%d%s",i,add[tm].Data()),
3585  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, case %d %s",i,add[tm].Data()),
3586  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3587  // fhNCellsTCardCorrel[i][tm]->SetXTitle("#it{E} (GeV)");
3588  // fhNCellsTCardCorrel[i][tm]->SetYTitle("#it{n}_{cells}");
3589  // outputContainer->Add(fhNCellsTCardCorrel[i][tm]);
3590  //
3591  // fhExoticTCardCorrel[i][tm] = new TH2F
3592  // (Form("hExoticTCardCorrel_Case%d%s",i,add[tm].Data()),
3593  // Form("exoticity vs #it{E}, max E cell correl with TCard cell, N corr = %d %s",i,add[tm].Data()),
3594  // nptbins,ptmin,ptmax,200,-1,1);
3595  // fhExoticTCardCorrel[i][tm]->SetXTitle("#it{E} (GeV)");
3596  // fhExoticTCardCorrel[i][tm]->SetYTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3597  // outputContainer->Add(fhExoticTCardCorrel[i][tm]);
3598  // }
3599  //
3600  // for(Int_t i = 0; i < 4; i++)
3601  // {
3602  // fhLambda0TCardCorrelExotic[i][tm] = new TH2F
3603  // (Form("hLambda0TCardCorrel_Exotic_Case%d%s",i,add[tm].Data()),
3604  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, exo>0.97, case %d %s",i,add[tm].Data()),
3605  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3606  // fhLambda0TCardCorrelExotic[i][tm]->SetXTitle("#it{E} (GeV)");
3607  // fhLambda0TCardCorrelExotic[i][tm]->SetYTitle("#sigma^{2}_{long}");
3608  // outputContainer->Add(fhLambda0TCardCorrelExotic[i][tm]);
3609  //
3610  // fhNCellsTCardCorrelExotic[i][tm] = new TH2F
3611  // (Form("hNCellsTCardCorrel_Exotic_Case%d%s",i,add[tm].Data()),
3612  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, exot > 0.97,case %d %s",i,add[tm].Data()),
3613  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3614  // fhNCellsTCardCorrelExotic[i][tm]->SetXTitle("#it{E} (GeV)");
3615  // fhNCellsTCardCorrelExotic[i][tm]->SetYTitle("#it{n}_{cells}");
3616  // outputContainer->Add(fhNCellsTCardCorrelExotic[i][tm]);
3617  // }
3618 
3619 
3620  for(Int_t i = 0; i < fNEBinCuts; i++)
3621  {
3622  if(fStudyExotic)
3623  {
3624  fhLambda0Exoticity[i][tm] = new TH2F
3625  (Form("hLambda0Exoticity_EBin%d%s",i,add[tm].Data()),
3626  Form("#sigma^{2}_{long} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3627  200,-1,1,ssbins,ssmin,ssmax);
3628  fhLambda0Exoticity[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3629  fhLambda0Exoticity[i][tm]->SetYTitle("#sigma^{2}_{long}");
3630  outputContainer->Add(fhLambda0Exoticity[i][tm]);
3631 
3632  fhLambda1Exoticity[i][tm] = new TH2F
3633  (Form("hLambda1Exoticity_EBin%d%s",i,add[tm].Data()),
3634  Form("#sigma^{2}_{short} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3635  200,-1,1,ssbins,ssmin,ssmax);
3636  fhLambda1Exoticity[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3637  fhLambda1Exoticity[i][tm]->SetYTitle("#sigma^{2}_{short}");
3638  outputContainer->Add(fhLambda1Exoticity[i][tm]);
3639 
3640  // fhLambdaRExoticity[i][tm] = new TH2F
3641  // (Form("hLambdaRExoticity_EBin%d%s",i,add[tm].Data()),
3642  // Form("#sigma^{2}_{short}/#sigma^{2}_{long} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3643  // 200,-1,1,110,0,1.1);
3644  // fhLambdaRExoticity[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3645  // fhLambdaRExoticity[i][tm]->SetYTitle("#sigma^{2}_{short}/#sigma^{2}_{long}");
3646  // outputContainer->Add(fhLambdaRExoticity[i][tm]);
3647 
3648  fhNCellsExoticity[i][tm] = new TH2F
3649  (Form("hNCellsExoticity_EBin%d%s",i,add[tm].Data()),
3650  Form("#it{n}_{cells} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3651  200,-1,1,nceclbins,nceclmin,nceclmax);
3652  fhNCellsExoticity[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3653  fhNCellsExoticity[i][tm]->SetYTitle("#it{n}_{cells}");
3654  outputContainer->Add(fhNCellsExoticity[i][tm]);
3655 
3656  fhTimeExoticity[i][tm] = new TH2F
3657  (Form("hTimeExoticity_EBin%d%s",i,add[tm].Data()),
3658  Form("#it{t} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3659  200,-1,1,100,-25,25);
3660  fhTimeExoticity[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3661  fhTimeExoticity[i][tm]->SetYTitle("#it{t} (ns)");
3662  outputContainer->Add(fhTimeExoticity[i][tm]);
3663 
3664  fhNCellsTCardSameAndDiffExotic[i][tm] = new TH2F
3665  (Form("hNCellsTCardSameAndDiff_Exotic_EBin%d%s",i,add[tm].Data()),
3666  Form("#it{n}_{cells} same TCard vs diff TCard, w > 0.01, %2.2f<#it{E}<%2.2f GeV, exo > 0.97 %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3667  nceclbins,nceclmin,nceclmax,nceclbins,nceclmin,nceclmax);
3668  fhNCellsTCardSameAndDiffExotic[i][tm]->SetXTitle("#it{n}_{cells} - diff TCard");
3669  fhNCellsTCardSameAndDiffExotic[i][tm]->SetYTitle("#it{n}_{cells} - same TCard");
3670  outputContainer->Add(fhNCellsTCardSameAndDiffExotic[i][tm]);
3671 
3672  // fhLambda0ExoticityAllSameTCard[i][tm] = new TH2F
3673  // (Form("hLambda0ExoticityAllSameTCard_EBin%d%s",i,add[tm].Data()),
3674  // Form("#sigma^{2}_{long} vs #it{exoticity}, all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3675  // 200,-1,1,ssbins,ssmin,ssmax);
3676  // fhLambda0ExoticityAllSameTCard[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3677  // fhLambda0ExoticityAllSameTCard[i][tm]->SetYTitle("#sigma^{2}_{long}");
3678  // outputContainer->Add(fhLambda0ExoticityAllSameTCard[i][tm]);
3679  //
3680  // fhLambda1ExoticityAllSameTCard[i][tm] = new TH2F
3681  // (Form("hLambda1ExoticityAllSameTCard_EBin%d%s",i,add[tm].Data()),
3682  // Form("#sigma^{2}_{short} vs #it{exoticity}, all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3683  // 200,-1,1,ssbins,ssmin,ssmax);
3684  // fhLambda1ExoticityAllSameTCard[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3685  // fhLambda1ExoticityAllSameTCard[i][tm]->SetYTitle("#sigma^{2}_{short}");
3686  // outputContainer->Add(fhLambda1ExoticityAllSameTCard[i][tm]);
3687  //
3688  // fhLambdaRExoticityAllSameTCard[i][tm] = new TH2F
3689  // (Form("hLambdaRExoticityAllSameTCard_EBin%d%s",i,add[tm].Data()),
3690  // Form("#sigma^{2}_{short}/#sigma^{2}_{long} vs #it{exoticity}, all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3691  // 200,-1,1,110,0,1.1);
3692  // fhLambdaRExoticityAllSameTCard[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3693  // fhLambdaRExoticityAllSameTCard[i][tm]->SetYTitle("#sigma^{2}_{short}/#sigma^{2}_{long}");
3694  // outputContainer->Add(fhLambdaRExoticityAllSameTCard[i][tm]);
3695  //
3696  // fhNCellsExoticityAllSameTCard[i][tm] = new TH2F
3697  // (Form("hNCellsExoticityAllSameTCard_EBin%d%s",i,add[tm].Data()),
3698  // Form("#it{n}_{cells} vs #it{exoticity}, all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3699  // 200,-1,1,nceclbins,nceclmin,nceclmax);
3700  // fhNCellsExoticityAllSameTCard[i][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3701  // fhNCellsExoticityAllSameTCard[i][tm]->SetYTitle("#it{n}_{cells}");
3702  // outputContainer->Add(fhNCellsExoticityAllSameTCard[i][tm]);
3703  //
3704  }
3705 
3706  fhNCellsTCardSameAndDiff[i][tm] = new TH2F
3707  (Form("hNCellsTCardSameAndDiff_EBin%d%s",i,add[tm].Data()),
3708  Form("#it{n}_{cells} same TCard vs diff TCard, w > 0.01, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3709  nceclbins,nceclmin,nceclmax,nceclbins,nceclmin,nceclmax);
3710  fhNCellsTCardSameAndDiff[i][tm]->SetXTitle("#it{n}_{cells} - diff TCard");
3711  fhNCellsTCardSameAndDiff[i][tm]->SetYTitle("#it{n}_{cells} - same TCard");
3712  outputContainer->Add(fhNCellsTCardSameAndDiff[i][tm]);
3713 
3714  fhLambda0Lambda1[i][tm] = new TH2F
3715  (Form("hLambda0Lambda1_EBin%d%s",i,add[tm].Data()),
3716  Form("#sigma^{2}_{long} vs #sigma^{2}_{short}, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3717  ssbins,ssmin,ssmax,ssbins,ssmin,ssmax);
3718  fhLambda0Lambda1[i][tm]->SetXTitle("#sigma^{2}_{short}");
3719  fhLambda0Lambda1[i][tm]->SetYTitle("#sigma^{2}_{long}");
3720  outputContainer->Add(fhLambda0Lambda1[i][tm]);
3721 
3722  // fhLambda0Lambda1AllSameTCard[i][tm] = new TH2F
3723  // (Form("hLambda0Lambda1AllSameTCard_EBin%d%s",i,add[tm].Data()),
3724  // Form("#sigma^{2}_{long} vs #sigma^{2}_{short}, , all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV %s",fEBinCuts[i],fEBinCuts[i+1],add[tm].Data()),
3725  // ssbins,ssmin,ssmax,ssbins,ssmin,ssmax);
3726  // fhLambda0Lambda1AllSameTCard[i][tm]->SetXTitle("#sigma^{2}_{short}");
3727  // fhLambda0Lambda1AllSameTCard[i][tm]->SetYTitle("#sigma^{2}_{long}");
3728  // outputContainer->Add(fhLambda0Lambda1AllSameTCard[i][tm]);
3729  }
3730 
3731  if(fStudyExotic)
3732  {
3733  for(Int_t j = 0; j < 6; j++)
3734  {
3735  for(Int_t k = 0; k < 6; k++)
3736  {
3737  fhLambda0ExoticityPerNCell[j][k][tm] = new TH2F
3738  (Form("hLambda0Exoticity_NCell_Same%d_Diff%d%s",j,k,add[tm].Data()),
3739  Form("#sigma^{2}_{long} vs #it{exoticity}, #it{n}_{cell} TCard same = %d, diff =%d, #it{E}>8 GeV %s",j,k,add[tm].Data()),
3740  200,-1,1,ssbins,ssmin,ssmax);
3741  fhLambda0ExoticityPerNCell[j][k][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3742  fhLambda0ExoticityPerNCell[j][k][tm]->SetYTitle("#sigma^{2}_{long}");
3743  outputContainer->Add(fhLambda0ExoticityPerNCell[j][k][tm]);
3744 
3745  fhLambda1ExoticityPerNCell[j][k][tm] = new TH2F
3746  (Form("hLambda1Exoticity_NCell_Same%d_Diff%d%s",j,k,add[tm].Data()),
3747  Form("#sigma^{2}_{short} vs #it{exoticity}, #it{n}_{cell} TCard same = %d, diff =%d, #it{E}>8 GeV %s",j,k,add[tm].Data()),
3748  200,-1,1,ssbins,ssmin,ssmax);
3749  fhLambda1ExoticityPerNCell[j][k][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3750  fhLambda1ExoticityPerNCell[j][k][tm]->SetYTitle("#sigma^{2}_{short}");
3751  outputContainer->Add(fhLambda1ExoticityPerNCell[j][k][tm]);
3752 
3753  // fhLambdaRExoticityPerNCell[j][k][tm] = new TH2F
3754  // (Form("hLambdaRExoticity_NCell_Same%d_Diff%d%s",j,k,add[tm].Data()),
3755  // Form("#sigma^{2}_{short}/#sigma^{2}_{long} vs #it{exoticity}, #it{n}_{cell} TCard same = %d, diff =%d, #it{E}>8 GeV %s",j,k,add[tm].Data()),
3756  // 200,-1,1,110,0,1.1);
3757  // fhLambdaRExoticityPerNCell[j][k][tm]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3758  // fhLambdaRExoticityPerNCell[j][k][tm]->SetYTitle("#sigma^{2}_{short}/#sigma^{2}_{long}");
3759  // outputContainer->Add(fhLambdaRExoticityPerNCell[j][k][tm]);
3760  }
3761  }
3762  }
3763 
3764  // for(Int_t i = 0; i < 6; i++)
3765  // {
3766  // fhLambda0TCardCorrelNearRow[i][tm] = new TH2F
3767  // (Form("hLambda0TCardCorrelNearRow_Case%d%s",i,add[tm].Data()),
3768  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with TCard cell, one TCard cell is 1 row away, case %d %s",i,add[tm].Data()),
3769  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3770  // fhLambda0TCardCorrelNearRow[i][tm]->SetXTitle("#it{E} (GeV)");
3771  // fhLambda0TCardCorrelNearRow[i][tm]->SetYTitle("#sigma^{2}_{long}");
3772  // outputContainer->Add(fhLambda0TCardCorrelNearRow[i][tm]);
3773  //
3774  // fhNCellsTCardCorrelNearRow[i][tm] = new TH2F
3775  // (Form("hNCellsTCardCorrelNearRow_Case%d%s",i,add[tm].Data()),
3776  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with TCard cell, case %d %s",i,add[tm].Data()),
3777  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3778  // fhNCellsTCardCorrelNearRow[i][tm]->SetXTitle("#it{E} (GeV)");
3779  // fhNCellsTCardCorrelNearRow[i][tm]->SetYTitle("#it{n}_{cells}");
3780  // outputContainer->Add(fhNCellsTCardCorrelNearRow[i][tm]);
3781  // }
3782  //
3783  // for(Int_t i = 0; i < 4; i++)
3784  // {
3785  // fhLambda0TCardCorrel2ndMax[i][tm] = new TH2F
3786  // (Form("hLambda0TCardCorrel2ndMax_Case%d%s",i,add[tm].Data()),
3787  // Form("#sigma^{2}_{long} vs #it{E}, max E cell correl with 2nd max TCard cell, case %d %s",i,add[tm].Data()),
3788  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3789  // fhLambda0TCardCorrel2ndMax[i][tm]->SetXTitle("#it{E} (GeV)");
3790  // fhLambda0TCardCorrel2ndMax[i][tm]->SetYTitle("#sigma^{2}_{long}");
3791  // outputContainer->Add(fhLambda0TCardCorrel2ndMax[i][tm]);
3792  //
3793  // fhNCellsTCardCorrel2ndMax[i][tm] = new TH2F
3794  // (Form("hNCellsTCardCorrel2ndMax_Case%d%s",i,add[tm].Data()),
3795  // Form("custer # cells vs #it{E}, w > 0.01, max E cell correl with 2nd max TCard cell, case %d %s",i,add[tm].Data()),
3796  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3797  // fhNCellsTCardCorrel2ndMax[i][tm]->SetXTitle("#it{E} (GeV)");
3798  // fhNCellsTCardCorrel2ndMax[i][tm]->SetYTitle("#it{n}_{cells}");
3799  // outputContainer->Add(fhNCellsTCardCorrel2ndMax[i][tm]);
3800  // }
3801  //
3802  // for(Int_t i = 0; i < 7; i++)
3803  // {
3804  // fhLambda0TCardCorrelOtherTCard[i][tm] = new TH2F
3805  // (Form("hLambda0TCardCorrelOtherTCard_Case%d%s",i,add[tm].Data()),
3806  // Form("#sigma^{2}_{long} vs #it{E}, correlation of cells in different TCards, case %d %s",i,add[tm].Data()),
3807  // nptbins,ptmin,ptmax,ssbins,ssmin,ssmax);
3808  // fhLambda0TCardCorrelOtherTCard[i][tm]->SetXTitle("#it{E} (GeV)");
3809  // fhLambda0TCardCorrelOtherTCard[i][tm]->SetYTitle("#sigma^{2}_{long}");
3810  // outputContainer->Add(fhLambda0TCardCorrelOtherTCard[i][tm]);
3811  //
3812  // fhNCellsTCardCorrelOtherTCard[i][tm] = new TH2F
3813  // (Form("hNCellsTCardCorrelOtherTCard_Case%d%s",i,add[tm].Data()),
3814  // Form("custer # cells vs #it{E}, w > 0.01, correlation of cells in different TCards, case %d %s",i,add[tm].Data()),
3815  // nptbins,ptmin,ptmax, nceclbins,nceclmin,nceclmax);
3816  // fhNCellsTCardCorrelOtherTCard[i][tm]->SetXTitle("#it{E} (GeV)");
3817  // fhNCellsTCardCorrelOtherTCard[i][tm]->SetYTitle("#it{n}_{cells}");
3818  // outputContainer->Add(fhNCellsTCardCorrelOtherTCard[i][tm]);
3819  //
3820  // fhExoticTCardCorrelOtherTCard[i][tm] = new TH2F
3821  // (Form("hExoticTCardCorrelOtherTCard_Case%d%s",i,add[tm].Data()),
3822  // Form("exoticity vs #it{E}, w > 0.01, correlation of cells in different TCards, case %d %s",i,add[tm].Data()),
3823  // nptbins,ptmin,ptmax,200,-1,1);
3824  // fhExoticTCardCorrelOtherTCard[i][tm]->SetXTitle("#it{E} (GeV)");
3825  // fhExoticTCardCorrelOtherTCard[i][tm]->SetYTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3826  // outputContainer->Add(fhExoticTCardCorrelOtherTCard[i][tm]);
3827  //
3828  // fhColRowTCardCorrelOtherTCardLowE[i][tm] = new TH2F
3829  // (Form("hColRowTCardCorrelOtherTCardLowE_Case%d%s",i,add[tm].Data()),
3830  // Form("column vs row for different 2 TCard correlation cases, E > 2 GeV, case %d %s",i,add[tm].Data()),
3831  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3832  // fhColRowTCardCorrelOtherTCardLowE[i][tm]->SetYTitle("row");
3833  // fhColRowTCardCorrelOtherTCardLowE[i][tm]->SetXTitle("column");
3834  // outputContainer->Add(fhColRowTCardCorrelOtherTCardLowE[i][tm]) ;
3835  //
3836  // fhColRowTCardCorrelOtherTCardHighE[i][tm] = new TH2F
3837  // (Form("hColRowTCardCorrelOtherTCardHighE_Case%d%s",i,add[tm].Data()),
3838  // Form("column vs row for different 2 TCard correlation cases, E > 8 GeV, case %d %s",i,add[tm].Data()),
3839  // ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax);
3840  // fhColRowTCardCorrelOtherTCardHighE[i][tm]->SetYTitle("row");
3841  // fhColRowTCardCorrelOtherTCardHighE[i][tm]->SetXTitle("column");
3842  // outputContainer->Add(fhColRowTCardCorrelOtherTCardHighE[i][tm]) ;
3843  // }
3844 
3845  for(Int_t i = 0; i < 12; i++)
3846  {
3847  fhTCardCorrECellMaxDiff[i][tm] = new TH2F
3848  (Form("hTCardCorrECellMaxDiff_Case%d%s",i,add[tm].Data()),
3849  Form("#it{E}_{cell}^{max}-#it{E}_{cell} vs #it{E}_{cluster}, for (un)correlated cells in TCard, case %d %s",i,add[tm].Data()),
3850  nptbins,ptmin,ptmax,210,-1,20);
3851  fhTCardCorrECellMaxDiff[i][tm]->SetXTitle("#it{E} (GeV)");
3852  fhTCardCorrECellMaxDiff[i][tm]->SetYTitle("#it{E}_{cell}^{max}-#it{E}_{cell} (GeV)");
3853  outputContainer->Add(fhTCardCorrECellMaxDiff[i][tm]);
3854 
3855  fhTCardCorrEClusterDiff[i][tm] = new TH2F
3856  (Form("hTCardCorrEClusterDiff_Case%d%s",i,add[tm].Data()),
3857  Form("#it{E}_{cluster}-#it{E}_{cell} vs #it{E}_{cluster}, for (un)correlated cells in TCard, case %d %s",i,add[tm].Data()),
3858  nptbins,ptmin,ptmax,210,-1,20);
3859  fhTCardCorrEClusterDiff[i][tm]->SetXTitle("#it{E} (GeV)");
3860  fhTCardCorrEClusterDiff[i][tm]->SetYTitle("#it{E}_{cluster}-#it{E}_{cell} (GeV)");
3861  outputContainer->Add(fhTCardCorrEClusterDiff[i][tm]);
3862 
3863  // fhTCardCorrECellMaxRat[i][tm] = new TH2F
3864  // (Form("hTCardCorrECellMaxRat_Case%d%s",i,add[tm].Data()),
3865  // Form("#it{E}_{cell}/#it{E}_{cell}^{max} vs #it{E}_{cluster}, for (un)correlated cells in TCard, case %d %s",i,add[tm].Data()),
3866  // nptbins,ptmin,ptmax,110,0,1.1);
3867  // fhTCardCorrECellMaxRat[i][tm]->SetXTitle("#it{E} (GeV)");
3868  // fhTCardCorrECellMaxRat[i][tm]->SetYTitle("#it{E}_{cell}/#it{E}^{max}_{cell}");
3869  // outputContainer->Add(fhTCardCorrECellMaxRat[i][tm]);
3870  //
3871  // fhTCardCorrEClusterRat[i][tm] = new TH2F
3872  // (Form("hTCardCorrEClusterRat_Case%d%s",i,add[tm].Data()),
3873  // Form("#it{E}_{cell}/#it{E}_{cluster} vs #it{E}_{cluster}, for (un)correlated cells in TCard, case %d %s",i,add[tm].Data()),
3874  // nptbins,ptmin,ptmax,110,0,1.1);
3875  // fhTCardCorrEClusterRat[i][tm]->SetXTitle("#it{E} (GeV)");
3876  // fhTCardCorrEClusterRat[i][tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
3877  // outputContainer->Add(fhTCardCorrEClusterRat[i][tm]);
3878 
3879  fhTCardCorrTCellMaxDiff[i][tm] = new TH2F
3880  (Form("hTCardCorrTCellMaxDiff_Case%d%s",i,add[tm].Data()),
3881  Form("#it{t}_{cell}^{max}-#it{t}_{cell} vs #it{E}_{cluster}, for (un)correlated cells in TCard, case %d %s",i,add[tm].Data()),
3882  nptbins,ptmin,ptmax,1000,-100,100);
3883  fhTCardCorrTCellMaxDiff[i][tm]->SetXTitle("#it{E} (GeV)");
3884  fhTCardCorrTCellMaxDiff[i][tm]->SetYTitle("#it{t}_{cell}^{max}-#it{t}_{cell} (ns)");
3885  outputContainer->Add(fhTCardCorrTCellMaxDiff[i][tm]);
3886 
3887  if(fStudyExotic)
3888  {
3889  fhTCardCorrECellMaxDiffExo[i][tm] = new TH2F
3890  (Form("hTCardCorrECellMaxDiffExo_Case%d%s",i,add[tm].Data()),
3891  Form("#it{E}_{cell}^{max}-#it{E}_{cell} vs #it{E}_{cluster}, for (un)correlated cells in TCard, exoticity > 0.97, case %d %s",i,add[tm].Data()),
3892  nptbins,ptmin,ptmax,210,-1,20);
3893  fhTCardCorrECellMaxDiffExo[i][tm]->SetXTitle("#it{E} (GeV)");
3894  fhTCardCorrECellMaxDiffExo[i][tm]->SetYTitle("#it{E}_{cell}^{max}-#it{E}_{cell} (GeV)");
3895  outputContainer->Add(fhTCardCorrECellMaxDiffExo[i][tm]);
3896 
3897  fhTCardCorrEClusterDiffExo[i][tm] = new TH2F
3898  (Form("hTCardCorrEClusterDiffExo_Case%d%s",i,add[tm].Data()),
3899  Form("#it{E}_{cluster}-#it{E}_{cell} vs #it{E}_{cluster}, for (un)correlated cells in TCard, exoticity > 0.97, case %d %s",i,add[tm].Data()),
3900  nptbins,ptmin,ptmax,210,-1,20);
3901  fhTCardCorrEClusterDiffExo[i][tm]->SetXTitle("#it{E} (GeV)");
3902  fhTCardCorrEClusterDiffExo[i][tm]->SetYTitle("#it{E}_{cluster}-#it{E}_{cell} (GeV)");
3903  outputContainer->Add(fhTCardCorrEClusterDiffExo[i][tm]);
3904 
3905  // fhTCardCorrECellMaxRatExo[i][tm] = new TH2F
3906  // (Form("hTCardCorrECellMaxRatExo_Case%d%s",i,add[tm].Data()),
3907  // Form("#it{E}_{cell}/#it{E}_{cell}^{max} vs #it{E}_{cluster}, for (un)correlated cells in TCard, exoticity > 0.97, case %d %s",i,add[tm].Data()),
3908  // nptbins,ptmin,ptmax,110,0,1.1);
3909  // fhTCardCorrECellMaxRatExo[i][tm]->SetXTitle("#it{E} (GeV)");
3910  // fhTCardCorrECellMaxRatExo[i][tm]->SetYTitle("#it{E}_{cell}/#it{E}^{max}_{cell}");
3911  // outputContainer->Add(fhTCardCorrECellMaxRatExo[i][tm]);
3912  //
3913  // fhTCardCorrEClusterRatExo[i][tm] = new TH2F
3914  // (Form("hTCardCorrEClusterRatExo_Case%d%s",i,add[tm].Data()),
3915  // Form("#it{E}_{cell}/#it{E}_{cluster} vs #it{E}_{cluster}, for (un)correlated cells in TCard, exoticity > 0.97, case %d %s",i,add[tm].Data()),
3916  // nptbins,ptmin,ptmax,110,0,1.1);
3917  // fhTCardCorrEClusterRatExo[i][tm]->SetXTitle("#it{E} (GeV)");
3918  // fhTCardCorrEClusterRatExo[i][tm]->SetYTitle("#it{E}_{cell}/#it{E}_{cluster}");
3919  // outputContainer->Add(fhTCardCorrEClusterRatExo[i][tm]);
3920 
3921  fhTCardCorrTCellMaxDiffExo[i][tm] = new TH2F
3922  (Form("hTCardCorrTCellMaxDiffExo_Case%d%s",i,add[tm].Data()),
3923  Form("#it{t}_{cell}^{max}-#it{t}_{cell} vs #it{E}_{cluster}, for (un)correlated cells in TCard, exoticity > 0.97, case %d %s",i,add[tm].Data()),
3924  nptbins,ptmin,ptmax,1000,-100,100);
3925  fhTCardCorrTCellMaxDiffExo[i][tm]->SetXTitle("#it{E} (GeV)");
3926  fhTCardCorrTCellMaxDiffExo[i][tm]->SetYTitle("#it{t}_{cell}^{max}-#it{t}_{cell} (ns)");
3927  outputContainer->Add(fhTCardCorrTCellMaxDiffExo[i][tm]);
3928  }
3929  }
3930  } // neutral or charged
3931 
3932  if(fStudyExotic)
3933  {
3934  fhEnergyTMEtaResidual1Cell = new TH2F("hEnergyTMEtaResidual1Cell","#Delta #eta_{cluster-track} vs #it{E}, n cell = 1",
3935  nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax);
3936  fhEnergyTMEtaResidual1Cell->SetXTitle("#it{E} (GeV)");
3937  fhEnergyTMEtaResidual1Cell->SetYTitle("#Delta #eta_{cluster-track}");
3938  outputContainer->Add(fhEnergyTMEtaResidual1Cell);
3939 
3940  fhEnergyTMPhiResidual1Cell = new TH2F("hEnergyTMPhiResidual1Cell","#Delta #varphi_{cluster-track} vs #it{E}, n cell = 1",
3941  nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax);
3942  fhEnergyTMPhiResidual1Cell->SetXTitle("#it{E} (GeV)");
3943  fhEnergyTMPhiResidual1Cell->SetYTitle("#Delta #varphi_{cluster-track}");
3944  outputContainer->Add(fhEnergyTMPhiResidual1Cell);
3945 
3946  fhEnergyTMEtaResidualExotic = new TH2F("hEnergyTMEtaResidualExotic","#Delta #eta_{cluster-track} vs #it{E}, exo > 0.97",
3947  nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax);
3948  fhEnergyTMEtaResidualExotic->SetXTitle("#it{E} (GeV)");
3949  fhEnergyTMEtaResidualExotic->SetYTitle("#Delta #eta_{cluster-track}");
3950  outputContainer->Add(fhEnergyTMEtaResidualExotic);
3951 
3952  fhEnergyTMPhiResidualExotic = new TH2F("hEnergyTMPhiResidualExotic","#Delta #varphi_{cluster-track} vs #it{E}, exo > 0.97",
3953  nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax);
3954  fhEnergyTMPhiResidualExotic->SetXTitle("#it{E} (GeV)");
3955  fhEnergyTMPhiResidualExotic->SetYTitle("#Delta #varphi_{cluster-track}");
3956  outputContainer->Add(fhEnergyTMPhiResidualExotic);
3957 
3958  fhEnergyTMEtaResidualTCardCorrNoSelection1Cell = new TH2F("hEnergyTMEtaResidualTCardCorrNoSelection1Cell","#Delta #eta_{cluster-track} vs #it{E}, n cell = 1",
3959  nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax);
3960  fhEnergyTMEtaResidualTCardCorrNoSelection1Cell->SetXTitle("#it{E} (GeV)");
3961  fhEnergyTMEtaResidualTCardCorrNoSelection1Cell->SetYTitle("#Delta #eta_{cluster-track}");
3962  outputContainer->Add(fhEnergyTMEtaResidualTCardCorrNoSelection1Cell);
3963 
3964  fhEnergyTMPhiResidualTCardCorrNoSelection1Cell = new TH2F("hEnergyTMPhiResidualTCardCorrNoSelection1Cell","#Delta #varphi_{cluster-track} vs #it{E}, n cell = 1",
3965  nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax);
3966  fhEnergyTMPhiResidualTCardCorrNoSelection1Cell->SetXTitle("#it{E} (GeV)");
3967  fhEnergyTMPhiResidualTCardCorrNoSelection1Cell->SetYTitle("#Delta #varphi_{cluster-track}");
3968  outputContainer->Add(fhEnergyTMPhiResidualTCardCorrNoSelection1Cell);
3969 
3970  fhEnergyTMEtaResidualTCardCorrNoSelectionExotic = new TH2F("hEnergyTMEtaResidualTCardCorrNoSelectionExotic","#Delta #eta_{cluster-track} vs #it{E}, exo > 0.97",
3971  nptbins,ptmin,ptmax,nresetabins,resetamin,resetamax);
3972  fhEnergyTMEtaResidualTCardCorrNoSelectionExotic->SetXTitle("#it{E} (GeV)");
3973  fhEnergyTMEtaResidualTCardCorrNoSelectionExotic->SetYTitle("#Delta #eta_{cluster-track}");
3974  outputContainer->Add(fhEnergyTMEtaResidualTCardCorrNoSelectionExotic);
3975 
3976  fhEnergyTMPhiResidualTCardCorrNoSelectionExotic = new TH2F("hEnergyTMPhiResidualTCardCorrNoSelectionExotic","#Delta #varphi_{cluster-track} vs #it{E}, exo > 0.97",
3977  nptbins,ptmin,ptmax,nresphibins,resphimin,resphimax);
3978  fhEnergyTMPhiResidualTCardCorrNoSelectionExotic->SetXTitle("#it{E} (GeV)");
3979  fhEnergyTMPhiResidualTCardCorrNoSelectionExotic->SetYTitle("#Delta #varphi_{cluster-track}");
3980  outputContainer->Add(fhEnergyTMPhiResidualTCardCorrNoSelectionExotic);
3981 
3982  for(Int_t i = 0; i < fNEBinCuts; i++)
3983  {
3984  fhTMPhiResidualExoticity[i] = new TH2F
3985  (Form("hTMPhiResidual_EBin%d",i),
3986  Form("#Delta #varphi_{cluster-track} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV",fEBinCuts[i],fEBinCuts[i+1]),
3987  200,-1,1,nresphibins,resphimin,resphimax);
3988  fhTMPhiResidualExoticity[i]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3989  fhTMPhiResidualExoticity[i]->SetYTitle("#Delta #varphi_{cluster-track}");
3990  outputContainer->Add(fhTMPhiResidualExoticity[i]);
3991 
3992  fhTMEtaResidualExoticity[i] = new TH2F
3993  (Form("hTMEtaResidual_EBin%d",i),
3994  Form("#Delta #eta_{cluster-track} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV",fEBinCuts[i],fEBinCuts[i+1]),
3995  200,-1,1,nresetabins,resetamin,resetamax);
3996  fhTMEtaResidualExoticity[i]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
3997  fhTMEtaResidualExoticity[i]->SetYTitle("#Delta #eta_{cluster-track}");
3998  outputContainer->Add(fhTMEtaResidualExoticity[i]);
3999 
4001  (Form("hTMPhiResidual_LooseCut_EBin%d",i),
4002  Form("#Delta #varphi_{cluster-track} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV",fEBinCuts[i],fEBinCuts[i+1]),
4003  200,-1,1,nresphibins,resphimin,resphimax);
4004  fhTMPhiResidualExoticityLooseCut[i]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
4005  fhTMPhiResidualExoticityLooseCut[i]->SetYTitle("#Delta #varphi_{cluster-track}");
4006  outputContainer->Add(fhTMPhiResidualExoticityLooseCut[i]);
4007 
4009  (Form("hTMEtaResidual_LooseCut_EBin%d",i),
4010  Form("#Delta #eta_{cluster-track} vs #it{exoticity}, %2.2f<#it{E}<%2.2f GeV",fEBinCuts[i],fEBinCuts[i+1]),
4011  200,-1,1,nresetabins,resetamin,resetamax);
4012  fhTMEtaResidualExoticityLooseCut[i]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
4013  fhTMEtaResidualExoticityLooseCut[i]->SetYTitle("#Delta #eta_{cluster-track}");
4014  outputContainer->Add(fhTMEtaResidualExoticityLooseCut[i]);
4015 
4016  // fhTMPhiResidualExoticityAllSameTCard[i] = new TH2F
4017  // (Form("hTMPhiResidualAllSameTCard_EBin%d",i),
4018  // Form("#Delta #varphi_{cluster-track} vs #it{exoticity}, all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV",fEBinCuts[i],fEBinCuts[i+1]),
4019  // 200,-1,1,nresphibins,resphimin,resphimax);
4020  // fhTMPhiResidualExoticityAllSameTCard[i]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
4021  // fhTMPhiResidualExoticityAllSameTCard[i]->SetYTitle("#Delta #varphi_{cluster-track}");
4022  // outputContainer->Add(fhTMPhiResidualExoticityAllSameTCard[i]);
4023  //
4024  // fhTMEtaResidualExoticityAllSameTCard[i] = new TH2F
4025  // (Form("hTMEtaResidualAllSameTCard_EBin%d",i),
4026  // Form("#Delta #eta_{cluster-track} vs #it{exoticity}, all cells same TCard as leading, %2.2f<#it{E}<%2.2f GeV",fEBinCuts[i],fEBinCuts[i+1]),
4027  // 200,-1,1,nresetabins,resetamin,resetamax);
4028  // fhTMEtaResidualExoticityAllSameTCard[i]->SetXTitle("#it{F}_{+}=1-#it{E}_{+}/#it{E}_{lead cell}");
4029  // fhTMEtaResidualExoticityAllSameTCard[i]->SetYTitle("#Delta #eta_{cluster-track}");
4030  // outputContainer->Add(fhTMEtaResidualExoticityAllSameTCard[i]);
4031  }
4032  }
4033  } // TCard correlation studies
4034 
4035  // Cluster size in terms of cells and shape TH3
4036  if(fStudyShape)
4037  {
4038  fhColRowM02 = new TH3F
4039  (Form("hColRowM02"),
4040  Form("column vs row vs M02, %2.2f < #it{E} < %2.2f GeV for Neutral",fEMinShape,fEMaxShape),
4041  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,40,0.,2.);
4042  fhColRowM02->SetYTitle("row");
4043  fhColRowM02->SetXTitle("column");
4044  fhColRowM02->SetZTitle("#sigma^{2}_{long}");
4045  outputContainer->Add(fhColRowM02) ;
4046 
4048  (Form("hColRowM02NCellCut"),
4049  Form("column vs row vs M02, %2.2f<#it{E}<%2.2f GeV #it{n}_{cells}^{w>0.01} > %d for Neutral",
4051  ncolcell,colcellmin,colcellmax,nrowcell,rowcellmin,rowcellmax,40,0.,2.);
4052  fhColRowM02NCellCut->SetYTitle("row");
4053  fhColRowM02NCellCut->SetXTitle("column");
4054  fhColRowM02NCellCut->SetZTitle("#sigma^{2}_{long}");
4055  outputContainer->Add(fhColRowM02NCellCut) ;
4056 
4057  if ( fStudyInvMass )
4058  {
4059  fhInvMassNCellSM = new TH3F
4060  ("hInvMassNCellSM",
4061  Form("%2.2f<#it{E}_{1}<%2.2f GeV, %2.2f<#it{E}_{2}<%2.2f GeV, %2.2f<#sigma^{2}_{long}<%2.2f"
4062  "#it{M}_{#gamma #gamma} vs #it{n}_{1, cells}^{w>0.01} vs SM number trig cluster",
4064  nmassbins,massmin,massmax,cellBins,cellMin,cellMax,fNModules,-0.5,fNModules-0.5);
4065  fhInvMassNCellSM->SetZTitle("SM number");
4066  fhInvMassNCellSM->SetYTitle("#it{n}_{cells}^{w>0.01}");
4067  fhInvMassNCellSM->SetXTitle("#it{M}_{#gamma #gamma}");
4068  outputContainer->Add(fhInvMassNCellSM);
4069 
4070  fhInvMassNCellSMSame = new TH3F
4071  ("hInvMassNCellSMSame",
4072  Form("%2.2f<#it{E}_{1}<%2.2f GeV, %2.2f<#it{E}_{2}<%2.2f GeV, %2.2f<#sigma^{2}_{long}<%2.2f"
4073  "#it{M}_{#gamma #gamma} vs #it{n}_{1, cells}^{w>0.01} vs SM number both cluster",
4075  nmassbins,massmin,massmax,cellBins,cellMin,cellMax,fNModules,-0.5,fNModules-0.5);
4076  fhInvMassNCellSMSame->SetZTitle("SM number");
4077  fhInvMassNCellSMSame->SetYTitle("#it{n}_{cells}^{w>0.01}");
4078  fhInvMassNCellSMSame->SetXTitle("#it{M}_{#gamma #gamma}");
4079  outputContainer->Add(fhInvMassNCellSMSame);
4080  }
4081 
4082  //
4083 
4084  if ( fStudyTimeCellHisto )
4085  {
4086  fhEMaxCellTimeM02SM = new TH3F
4087  ("hEMaxCellTimeM02SM",
4088  Form("time vs #sigma^{2}_{long} vs SM number, "
4089  "%2.2f<#it{E}<%2.2f GeV, #it{n}_{cells}^{w>0.01}>%d",fEMinShape,fEMaxShape,fNCellMinShape),
4090  45,-25.5,20.5, fNModules,-0.5,fNModules-0.5,nShShBins,minShSh,maxShSh);
4091  fhEMaxCellTimeM02SM->SetZTitle("#sigma^{2}_{long}");
4092  fhEMaxCellTimeM02SM->SetYTitle("SM number");
4093  fhEMaxCellTimeM02SM->SetXTitle("time (ns)");
4094  outputContainer->Add(fhEMaxCellTimeM02SM);
4095 
4097  ("hEMaxCellTimeNCellSM",
4098  Form("time vs #it{n}_{cells}^{w>0.01} vs SM number, "
4099  "%2.2f<#it{E}<%2.2f GeV, %2.2f<#it{sigma}_{long}<%2.2f",fEMinShape,fEMaxShape,fM02LowBin[0],fM02LowBin[1]),
4100  45,-25.5,20.5, fNModules,-0.5,fNModules-0.5,cellBins,cellMin,cellMax);
4101  fhEMaxCellTimeNCellSM->SetZTitle("#it{n}_{cells}^{w>0.01}");
4102  fhEMaxCellTimeNCellSM->SetYTitle("SM number");
4103  fhEMaxCellTimeNCellSM->SetXTitle("time (ns)");
4104  outputContainer->Add(fhEMaxCellTimeNCellSM);
4105 
4107  ("hESecCellTimeNCellSM",
4108  Form("secondary cell time vs #it{n}_{cells}^{w>0.01} vs SM number, "
4109  "%2.2f<#it{E}<%2.2f GeV, %2.2f<#it{sigma}_{long}<%2.2f",fEMinShape,fEMaxShape,fM02LowBin[0],fM02LowBin[1]),
4110  50,-100,100, fNModules,-0.5,fNModules-0.5,cellBins,cellMin,cellMax);
4111  fhESecCellTimeNCellSM->SetZTitle("#it{n}_{cells}^{w>0.01}");
4112  fhESecCellTimeNCellSM->SetYTitle("SM number");
4113  fhESecCellTimeNCellSM->SetXTitle("time (ns)");
4114  outputContainer->Add(fhESecCellTimeNCellSM);
4115  }
4116 
4117  //
4118 
4119  Int_t nbinsdeltacells = 19 ;
4120  Float_t mindeltacells =-9.5;
4121  Float_t maxdeltacells = 9.5;
4122 
4124  {
4125  for(Int_t col = 0; col < 2; col++)
4126  {
4127  fhColRowFromCellMaxLowM02[col] = new TH2F
4128  (Form("hColRowFromCellMaxLowM02_Col%d",col),
4129  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #it{n}_{cells}^{w>0.01} for %2.2f < #sigma^{2}_{long} < %2.2f, "
4130  "%2.2f<#it{E}<%2.2f GeV, colum %d",fM02LowBin[0],fM02LowBin[1],fEMinShape,fEMaxShape,col),
4131  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells);
4132  fhColRowFromCellMaxLowM02[col]->SetXTitle("#Delta column_{max-secondary}");
4133  fhColRowFromCellMaxLowM02[col]->SetYTitle("#Delta row_{max-secondary}");
4134  outputContainer->Add(fhColRowFromCellMaxLowM02[col]);
4135 
4136  fhColRowFromCellMaxHighM02[col] = new TH2F
4137  (Form("hColRowFromCellMaxHighM02_Col%d",col),
4138  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #it{n}_{cells}^{w>0.01} for %2.2f < #sigma^{2}_{long} < %2.2f, "
4139  "%2.2f<#it{E}<%2.2f GeV, colum %d",fM02HighBin[0],fM02HighBin[1],fEMinShape,fEMaxShape,col),
4140  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells);
4141  fhColRowFromCellMaxHighM02[col]->SetXTitle("#Delta column_{max-secondary}");
4142  fhColRowFromCellMaxHighM02[col]->SetYTitle("#Delta row_{max-secondary}");
4143  outputContainer->Add(fhColRowFromCellMaxHighM02[col]);
4144  }//odd/pair col
4145  }
4146  //
4147 
4148  for(Int_t i = 0; i < fNModules; i++)
4149  {
4151  (Form("hNCellsPerClusterM02M20_SM%d",i),
4152  Form(" vs #sigma^{2}_{long} vs #it{n}_{cells}^{w>0.01} vs #sigma^{2}_{short}, "
4153  "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,i),
4154  (Int_t)nShShBins/1.5,0,maxShSh/1.5, cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4155  fhNCellsPerClusterM02M20PerSM[i]->SetZTitle("#sigma^{2}_{long}");
4156  fhNCellsPerClusterM02M20PerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4157  fhNCellsPerClusterM02M20PerSM[i]->SetXTitle("#sigma^{2}_{short}");
4158  outputContainer->Add(fhNCellsPerClusterM02M20PerSM[i]);
4159 
4160  if ( fFillNLocMaxHistos )
4161  {
4163  (Form("hNCellsPerClusterM02NLM_SM%d",i),
4164  Form(" vs #sigma^{2}_{long} vs #it{n}_{cells}^{w>0.01} vs N_{lm}, "
4165  "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,i),
4166  10,0,10, cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4167  fhNCellsPerClusterM02NLMPerSM[i]->SetZTitle("#sigma^{2}_{long}");
4168  fhNCellsPerClusterM02NLMPerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4169  fhNCellsPerClusterM02NLMPerSM[i]->SetXTitle("n_{lm}");
4170  outputContainer->Add(fhNCellsPerClusterM02NLMPerSM[i]);
4171  }
4172 
4174  (Form("hEMaxCellEClusterM02NCell_SM%d",i),
4175  Form("(#it{E}_{cluster} - #it{E}_{max cell})/#it{E}_{cluster} vs #sigma^{2}_{long} vs #it{n}_{cells}^{w>0.01}, "
4176  "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,i),
4177  50,0,1., cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4178  fhEMaxCellEClusterM02NCellPerSM[i]->SetZTitle("#sigma^{2}_{long}");
4179  fhEMaxCellEClusterM02NCellPerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4180  fhEMaxCellEClusterM02NCellPerSM[i]->SetXTitle("(#it{E}_{cluster} - #it{E}_{max cell})/ #it{E}_{cluster}");
4181  outputContainer->Add(fhEMaxCellEClusterM02NCellPerSM[i]);
4182 
4183 // fhEMaxCellLogM02NCellPerSM[i] = new TH3F
4184 // (Form("hEMaxCellLogM02NCell_SM%d",i),
4185 // Form("log(#it{E}_{max cell}) vs #sigma^{2}_{long} vs SM number, "
4186 // "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,i),
4187 // 150,-3,3, cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4188 // fhEMaxCellLogM02NCellPerSM[i]->SetZTitle("#sigma^{2}_{long}");
4189 // fhEMaxCellLogM02NCellPerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4190 // fhEMaxCellLogM02NCellPerSM[i]->SetXTitle("log(#it{E}_{max cell})");
4191 // outputContainer->Add(fhEMaxCellLogM02NCellPerSM[i]);
4192 
4194  (Form("hESecCellEMaxCellM02NCell_SM%d",i),
4195  Form("#it{E}_{cell}/#it{E}_{cell max} vs #sigma^{2}_{long} vs #it{n}_{cells}^{w>0.01}, "
4196  "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,i),
4197  50,0,1., cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4198  fhESecCellEMaxCellM02NCellPerSM[i]->SetZTitle("#sigma^{2}_{long}");
4199  fhESecCellEMaxCellM02NCellPerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4200  fhESecCellEMaxCellM02NCellPerSM[i]->SetXTitle("#it{E}_{cell}/#it{E}_{cell max}");
4201  outputContainer->Add(fhESecCellEMaxCellM02NCellPerSM[i]);
4202 
4204  (Form("hESecCellEClusterM02NCell_SM%d",i),
4205  Form("(#it{E}_{cluster} - #it{E}_{cell})/#it{E}_{cluster} vs #sigma^{2}_{long} vs #it{n}_{cells}^{w>0.01}, "
4206  "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,i),
4207  50,0,1., cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4208  fhESecCellEClusterM02NCellPerSM[i]->SetZTitle("#sigma^{2}_{long}");
4209  fhESecCellEClusterM02NCellPerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4210  fhESecCellEClusterM02NCellPerSM[i]->SetXTitle("(#it{E}_{cluster} - #it{E}_{cell})/ #it{E}_{cluster}");
4211  outputContainer->Add(fhESecCellEClusterM02NCellPerSM[i]);
4212 
4213 // fhESecCellLogM02NCellPerSM[i] = new TH3F
4214 // (Form("hESecCellLogM02NCell_SM%d",i),
4215 // Form("log(#it{E}_{cell}) vs #sigma^{2}_{long} vs #it{n}_{cells}^{w>0.01}, "
4216 // "%2.2f<#it{E}<%2.2f GeV, SM=%d",fEMinShape,fEMaxShape,fNCellMinShape),
4217 // 150,-3,3, cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4218 // fhESecCellLogM02NCellPerSM[i]->SetZTitle("#sigma^{2}_{long}");
4219 // fhESecCellLogM02NCellPerSM[i]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4220 // fhESecCellLogM02NCellPerSM[i]->SetXTitle("log(#it{E}_{cell})");
4221 // outputContainer->Add(fhESecCellLogM02NCellPerSM[i]);
4222 
4224  (Form("hEMaxESecCellNCellLowM02_SM%d",i),
4225  Form("#it{E}_{cell}^{max} vs #it{E}_{cell}^{secondary} vs #it{n}_{cells}^{w>0.01} vs %2.2f < #sigma^{2}_{long} < %2.2f, "
4226  "%2.2f<#it{E}<%2.2f GeV, SM=%d", fM02LowBin[0],fM02LowBin[1], fEMinShape,fEMaxShape,i),
4227  24,0,12, 48,0,12,cellBins,cellMin,cellMax);
4228  fhEMaxESecCellNCellLowM02PerSM[i]->SetZTitle("#it{n}_{cells}^{w>0.01}");
4229  fhEMaxESecCellNCellLowM02PerSM[i]->SetYTitle("#it{E}_{cell}^{secondary} (GeV)");
4230  fhEMaxESecCellNCellLowM02PerSM[i]->SetXTitle("#it{E}_{cell}^{max} (GeV)");
4231  outputContainer->Add(fhEMaxESecCellNCellLowM02PerSM[i]);
4232 
4234  (Form("hEMaxECrossNCellLowM02_SM%d",i),
4235  Form("#it{E}_{cell}^{max} vs exoticity vs #it{n}_{cells}^{w>0.01} vs %2.2f < #sigma^{2}_{long} < %2.2f, "
4236  "%2.2f<#it{E}<%2.2f GeV, SM=%d",fM02LowBin[0],fM02LowBin[1],fEMinShape,fEMaxShape,i),
4237  24,0,12, 40,0.6,1.,cellBins,cellMin,cellMax);
4238  fhEMaxECrossNCellLowM02PerSM[i]->SetZTitle("#it{n}_{cells}^{w>0.01}");
4239  fhEMaxECrossNCellLowM02PerSM[i]->SetYTitle("1- #it{E}_{cross}/#it{E}_{cell}^{max}");
4240  fhEMaxECrossNCellLowM02PerSM[i]->SetXTitle("#it{E}_{cell}^{max} (GeV)");
4241  outputContainer->Add(fhEMaxECrossNCellLowM02PerSM[i]);
4242 
4244  (Form("hEMaxESecCellNCellHighM02_SM%d",i),
4245  Form("#it{E}_{cell}^{max} vs #it{E}_{cell}^{secondary} vs #it{n}_{cells}^{w>0.01} vs "
4246  "%2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d",
4248  24,0,12, 48,0,12,cellBins,cellMin,cellMax);
4249  fhEMaxESecCellNCellHighM02PerSM[i]->SetZTitle("#it{n}_{cells}^{w>0.01}");
4250  fhEMaxESecCellNCellHighM02PerSM[i]->SetYTitle("#it{E}_{cell}^{secondary} (GeV)");
4251  fhEMaxESecCellNCellHighM02PerSM[i]->SetXTitle("#it{E}_{cell}^{max} (GeV)");
4252  outputContainer->Add(fhEMaxESecCellNCellHighM02PerSM[i]);
4253 
4255  (Form("hEMaxECrossNCellHighM02_SM%d",i),
4256  Form("#it{E}_{cell}^{max} vs exoticity vs #it{n}_{cells}^{w>0.01} "
4257  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d",
4259  24,0,12, 40,0.6,1.,cellBins,cellMin,cellMax);
4260  fhEMaxECrossNCellHighM02PerSM[i]->SetZTitle("#it{n}_{cells}^{w>0.01}");
4261  fhEMaxECrossNCellHighM02PerSM[i]->SetYTitle("1- #it{E}_{cross}/#it{E}_{cell}^{max}");
4262  fhEMaxECrossNCellHighM02PerSM[i]->SetXTitle("#it{E}_{cell}^{max} (GeV)");
4263  outputContainer->Add(fhEMaxECrossNCellHighM02PerSM[i]);
4264 
4266  {
4267  Int_t nbinsdeltacells = 19 ;
4268  Float_t mindeltacells =-9.5;
4269  Float_t maxdeltacells = 9.5;
4270  for(Int_t col = 0; col < 2; col++)
4271  {
4272  fhNCellsPerClusterM02PerSMPerCol[i][col] = new TH3F
4273  (Form("hNCellsPerClusterM02_SM%d_Col%d",i,col),
4274  Form("#it{E} vs #it{n}_{cells} vs #sigma^{2}_{long}, SM=%d, colum %d",i,col),
4275  nEbins,minE,maxE,cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4276  fhNCellsPerClusterM02PerSMPerCol[i][col]->SetXTitle("#it{E} (GeV)");
4277  fhNCellsPerClusterM02PerSMPerCol[i][col]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4278  fhNCellsPerClusterM02PerSMPerCol[i][col]->SetZTitle("#sigma^{2}_{long}");
4279  outputContainer->Add(fhNCellsPerClusterM02PerSMPerCol[i][col]);
4280 
4281  fhNCellsPerClusterM20PerSMPerCol[i][col] = new TH3F
4282  (Form("hNCellsPerClusterM20_SM%d_Col%d",i,col),
4283  Form("#it{E} vs #it{n}_{cells} vs #sigma^{2}_{short}, SM=%d, colum %d",i,col),
4284  nEbins,minE,maxE,cellBins,cellMin,cellMax,(Int_t)nShShBins/1.5,0,maxShSh/1.5);
4285  fhNCellsPerClusterM20PerSMPerCol[i][col]->SetXTitle("#it{E} (GeV)");
4286  fhNCellsPerClusterM20PerSMPerCol[i][col]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4287  fhNCellsPerClusterM20PerSMPerCol[i][col]->SetZTitle("#sigma^{2}_{short}");
4288  outputContainer->Add(fhNCellsPerClusterM20PerSMPerCol[i][col]);
4289 
4290  if ( fFillNLocMaxHistos )
4291  {
4292  fhNCellsPerClusterNLMPerSMPerCol[i][col] = new TH3F
4293  (Form("hNCellsPerClusterNLM_SM%d_Col%d",i,col),
4294  Form("#it{E} vs #it{n}_{cells} vs n_{lm}, SM=%d, colum %d",i,col),
4295  nEbins,minE,maxE,cellBins,cellMin,cellMax,10,0,10);
4296  fhNCellsPerClusterNLMPerSMPerCol[i][col]->SetXTitle("#it{E} (GeV)");
4297  fhNCellsPerClusterNLMPerSMPerCol[i][col]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4298  fhNCellsPerClusterNLMPerSMPerCol[i][col]->SetZTitle("n_{lm}");
4299  outputContainer->Add(fhNCellsPerClusterNLMPerSMPerCol[i][col]);
4300  }
4301 
4302  fhColRowFromCellMaxLowM02PerSM[i][col] = new TH3F
4303  (Form("hColRowFromCellMaxLowM02_SM%d_Col%d",i,col),
4304  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #it{n}_{cells}^{w>0.01} for %2.2f < #sigma^{2}_{long} < %2.2f, "
4305  "%2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d",
4307  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,cellBins,cellMin,cellMax);
4308  fhColRowFromCellMaxLowM02PerSM[i][col]->SetZTitle("#it{n}_{cells}^{w>0.01}");
4309  fhColRowFromCellMaxLowM02PerSM[i][col]->SetXTitle("#Delta column_{max-secondary}");
4310  fhColRowFromCellMaxLowM02PerSM[i][col]->SetYTitle("#Delta row_{max-secondary}");
4311  outputContainer->Add(fhColRowFromCellMaxLowM02PerSM[i][col]);
4312 
4313  fhColRowFromCellMaxHighM02PerSM[i][col] = new TH3F
4314  (Form("hColRowFromCellMaxHighM02_SM%d_Col%d",i,col),
4315  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #it{n}_{cells}^{w>0.01} "
4316  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d",
4318  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,cellBins,cellMin,cellMax);
4319  fhColRowFromCellMaxHighM02PerSM[i][col]->SetZTitle("#it{n}_{cells}^{w>0.01}");
4320  fhColRowFromCellMaxHighM02PerSM[i][col]->SetXTitle("#Delta column_{max-secondary}");
4321  fhColRowFromCellMaxHighM02PerSM[i][col]->SetYTitle("#Delta row_{max-secondary}");
4322  outputContainer->Add(fhColRowFromCellMaxHighM02PerSM[i][col]);
4323 
4324  for(Int_t j = 0; j < fNCellsBins; j++)
4325  {
4327  (Form("hColRowFromCellMaxEMaxSecDiffLowM02_SM%d_Col%d_NCellBin%d",i,col,j),
4328  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #Delta #it{E}_{max-secondary} "
4329  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d,%d <= #it{n}_{cells}^{w>0.01} < %d",
4331  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,120,0,12);
4332  fhColRowFromCellMaxEMaxSecDiffLowM02PerSM[i][col][j]->SetZTitle("#Delta #it{E}_{max-secondary} (GeV)");
4333  fhColRowFromCellMaxEMaxSecDiffLowM02PerSM[i][col][j]->SetXTitle("#Delta column_{max-secondary}");
4334  fhColRowFromCellMaxEMaxSecDiffLowM02PerSM[i][col][j]->SetYTitle("#Delta row_{max-secondary}");
4335  outputContainer->Add(fhColRowFromCellMaxEMaxSecDiffLowM02PerSM[i][col][j]);
4336 
4338  (Form("hColRowFromCellMaxEMaxSecDiffHighM02_SM%d_Col%d_NCellBin%d",i,col,j),
4339  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #Delta #it{E}_{max-secondary} "
4340  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d, %d <= #it{n}_{cells}^{w>0.01} < %d",
4342  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,120,0,12);
4343  fhColRowFromCellMaxEMaxSecDiffHighM02PerSM[i][col][j]->SetZTitle("#Delta #it{E}_{max-secondary} (GeV)");
4344  fhColRowFromCellMaxEMaxSecDiffHighM02PerSM[i][col][j]->SetXTitle("#Delta column_{max-secondary}");
4345  fhColRowFromCellMaxEMaxSecDiffHighM02PerSM[i][col][j]->SetYTitle("#Delta row_{max-secondary}");
4346  outputContainer->Add(fhColRowFromCellMaxEMaxSecDiffHighM02PerSM[i][col][j]);
4347 
4349  (Form("hColRowFromCellMaxEMaxSecDiffFracLowM02_SM%d_Col%d_NCellBin%d",i,col,j),
4350  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #Delta #it{E}_{max-secondary}/#it{E}_{max} "
4351  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d,%d <= #it{n}_{cells}^{w>0.01} < %d",
4353  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,40,0,1);
4354  fhColRowFromCellMaxEMaxSecDiffFracLowM02PerSM[i][col][j]->SetZTitle("#Delta #it{E}_{max-secondary}/#it{E}_{max}");
4355  fhColRowFromCellMaxEMaxSecDiffFracLowM02PerSM[i][col][j]->SetXTitle("#Delta column_{max-secondary}");
4356  fhColRowFromCellMaxEMaxSecDiffFracLowM02PerSM[i][col][j]->SetYTitle("#Delta row_{max-secondary}");
4357  outputContainer->Add(fhColRowFromCellMaxEMaxSecDiffFracLowM02PerSM[i][col][j]);
4358 
4360  (Form("hColRowFromCellMaxEMaxSecDiffFracHighM02_SM%d_Col%d_NCellBin%d",i,col,j),
4361  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #Delta #it{E}_{max-secondary}/#it{E}_{max}"
4362  " for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d, %d <= #it{n}_{cells}^{w>0.01} < %d",
4364  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,40,0,1);
4365  fhColRowFromCellMaxEMaxSecDiffFracHighM02PerSM[i][col][j]->SetZTitle("#Delta #it{E}_{max-secondary}/#it{E}_{max}");
4366  fhColRowFromCellMaxEMaxSecDiffFracHighM02PerSM[i][col][j]->SetXTitle("#Delta column_{max-secondary}");
4367  fhColRowFromCellMaxEMaxSecDiffFracHighM02PerSM[i][col][j]->SetYTitle("#Delta row_{max-secondary}");
4368  outputContainer->Add(fhColRowFromCellMaxEMaxSecDiffFracHighM02PerSM[i][col][j]);
4369 
4371  (Form("hColRowFromCellMaxECellClusterRatLowM02_SM%d_Col%d_NCellBin%d",i,col,j),
4372  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #it{E}_{cell}/#it{E}_{cluster} "
4373  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d, %d <= #it{n}_{cells}^{w>0.01} < %d",
4375  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,50,0,1);
4376  fhColRowFromCellMaxECellClusterRatLowM02PerSM[i][col][j]->SetZTitle("#it{E}_{cell}/#it{E}_{cluster}");
4377  fhColRowFromCellMaxECellClusterRatLowM02PerSM[i][col][j]->SetXTitle("#Delta column_{max-secondary}");
4378  fhColRowFromCellMaxECellClusterRatLowM02PerSM[i][col][j]->SetYTitle("#Delta row_{max-secondary}");
4379  outputContainer->Add(fhColRowFromCellMaxECellClusterRatLowM02PerSM[i][col][j]);
4380 
4382  (Form("hColRowFromCellMaxECellClusterRatHighM02_SM%d_Col%d_NCellBin%d",i,col,j),
4383  Form("cell col_{max}-#col_{secondary} vs cell #row_{max}-#row_{secondary} vs #it{E}_{cell}/#it{E}_{cluster} "
4384  "for %2.2f < #sigma^{2}_{long} < %2.2f, %2.2f<#it{E}<%2.2f GeV, SM=%d, colum %d, %d <= #it{n}_{cells}^{w>0.01} < %d",
4386  nbinsdeltacells,mindeltacells,maxdeltacells,nbinsdeltacells,mindeltacells,maxdeltacells,50,0,1);
4387  fhColRowFromCellMaxECellClusterRatHighM02PerSM[i][col][j]->SetZTitle("#it{E}_{cell}/#it{E}_{cluster}");
4388  fhColRowFromCellMaxECellClusterRatHighM02PerSM[i][col][j]->SetXTitle("#Delta column_{max-secondary}");
4389  fhColRowFromCellMaxECellClusterRatHighM02PerSM[i][col][j]->SetYTitle("#Delta row_{max-secondary}");
4390  outputContainer->Add(fhColRowFromCellMaxECellClusterRatHighM02PerSM[i][col][j]);
4391 
4392  } // 3 n cell bins
4393  } // odd/pair col
4394  } // if ( fStudyColRowFromCellMax )
4395 
4396  } // SM
4397 
4398  for(Int_t imatch = 0; imatch < fNMatchPIDCases; imatch++)
4399  {
4400  if ( fStudyShapeParam )
4401  {
4402  fhDeltaIEtaDeltaIPhi[imatch] = new TH3F
4403  (Form("hDeltaIEtaDeltaIPhi_%s",matchCase[imatch].Data()),
4404  Form("Cluster max size with respect main cell in columns vs rows vs E for %s, #it{n}_{cells}^{w>0.01}>%d",matchCase[imatch].Data(),fNCellMinShape),
4405  nEbins,minE,maxE,cellBins,cellMin,cellMax,cellBins,cellMin,cellMax);
4406  fhDeltaIEtaDeltaIPhi[imatch]->SetXTitle("#it{E}_{cluster}");
4407  fhDeltaIEtaDeltaIPhi[imatch]->SetYTitle("#Delta Column");
4408  fhDeltaIEtaDeltaIPhi[imatch]->SetZTitle("#Delta Row");
4409  outputContainer->Add(fhDeltaIEtaDeltaIPhi[imatch]);
4410 
4411  fhDeltaIEtaDeltaIPhiTot[imatch] = new TH3F
4412  (Form("hDeltaIEtaDeltaIPhiTot_%s",matchCase[imatch].Data()),
4413  Form("Cluster size in columns vs rows, minus main cell, vs E for %s, #it{n}_{cells}^{w>0.01}>%d",matchCase[imatch].Data(),fNCellMinShape),
4414  nEbins,minE,maxE,cellBins,cellMin,cellMax,cellBins,cellMin,cellMax);
4415  fhDeltaIEtaDeltaIPhiTot[imatch]->SetXTitle("#it{E}_{cluster}");
4416  fhDeltaIEtaDeltaIPhiTot[imatch]->SetYTitle("#Delta Column");
4417  fhDeltaIEtaDeltaIPhiTot[imatch]->SetZTitle("#Delta Row");
4418  outputContainer->Add(fhDeltaIEtaDeltaIPhiTot[imatch]);
4419 
4420  fhDeltaIA[imatch] = new TH2F
4421  (Form("hDeltaIA_%s",matchCase[imatch].Data()),
4422  Form("Cluster *asymmetry* in cell units vs E for %s",matchCase[imatch].Data()),
4423  nptbins,ptmin,ptmax,asyBins,asyMin,asyMax);
4424  fhDeltaIA[imatch]->SetXTitle("#it{E}_{cluster}");
4425  fhDeltaIA[imatch]->SetYTitle("#it{A}_{cell in cluster}");
4426  outputContainer->Add(fhDeltaIA[imatch]);
4427 
4428  fhDeltaIATot[imatch] = new TH2F
4429  (Form("hDeltaIATot_%s",matchCase[imatch].Data()),
4430  Form("Cluster *total asymmetry* in cell units vs E for %s",matchCase[imatch].Data()),
4431  nptbins,ptmin,ptmax,asyBins,asyMin,asyMax);
4432  fhDeltaIATot[imatch]->SetXTitle("#it{E}_{cluster}");
4433  fhDeltaIATot[imatch]->SetYTitle("#it{A}_{cell in cluster}^{total}");
4434  outputContainer->Add(fhDeltaIATot[imatch]);
4435 
4436  fhDeltaIAM02[imatch] = new TH3F
4437  (Form("hDeltaIAM02_%s",matchCase[imatch].Data()),
4438  Form("Cluster *asymmetry* in cell units vs #sigma^{2}_{long} for %s",matchCase[imatch].Data()),
4439  nEbins,minE,maxE,nShShBins,minShSh,maxShSh,asyBins,asyMin,asyMax);
4440  fhDeltaIAM02[imatch]->SetXTitle("#it{E}_{cluster}");
4441  fhDeltaIAM02[imatch]->SetYTitle("#sigma^{2}_{long}");
4442  fhDeltaIAM02[imatch]->SetZTitle("#it{A}_{cell in cluster}");
4443  outputContainer->Add(fhDeltaIAM02[imatch]);
4444 
4445  fhDeltaIATotM02[imatch] = new TH3F
4446  (Form("hDeltaIATotM02_%s",matchCase[imatch].Data()),
4447  Form("Cluster *total asymmetry* in cell units vs #sigma^{2}_{long} for %s",matchCase[imatch].Data()),
4448  nEbins,minE,maxE,nShShBins,minShSh,maxShSh,asyBins,asyMin,asyMax);
4449  fhDeltaIATotM02[imatch]->SetXTitle("#it{E}_{cluster}");
4450  fhDeltaIATotM02[imatch]->SetYTitle("#sigma^{2}_{long}");
4451  fhDeltaIATotM02[imatch]->SetZTitle("#it{A}_{cell in cluster}^{total}");
4452  outputContainer->Add(fhDeltaIATotM02[imatch]);
4453 
4454  fhDeltaIAM20[imatch] = new TH3F
4455  (Form("hDeltaIAM20_%s",matchCase[imatch].Data()),
4456  Form("Cluster *asymmetry* in cell units vs #sigma^{2}_{short} for %s",matchCase[imatch].Data()),
4457  nEbins,minE,maxE,(Int_t)nShShBins/1.5,0,maxShSh/1.5,asyBins,asyMin,asyMax);
4458  fhDeltaIAM20[imatch]->SetXTitle("#it{E}_{cluster}");
4459  fhDeltaIAM20[imatch]->SetYTitle("#sigma^{2}_{short}");
4460  fhDeltaIAM20[imatch]->SetZTitle("#it{A}_{cell in cluster}");
4461  outputContainer->Add(fhDeltaIAM20[imatch]);
4462 
4463  fhDeltaIATotM20[imatch] = new TH3F
4464  (Form("hDeltaIATotM20_%s",matchCase[imatch].Data()),
4465  Form("Cluster *total asymmetry* in cell units vs #sigma^{2}_{short} for %s",matchCase[imatch].Data()),
4466  nEbins,minE,maxE,(Int_t)nShShBins/1.5,0,maxShSh/1.5,asyBins,asyMin,asyMax);
4467  fhDeltaIATotM20[imatch]->SetXTitle("#it{E}_{cluster}");
4468  fhDeltaIATotM20[imatch]->SetYTitle("#sigma^{2}_{short}");
4469  fhDeltaIATotM20[imatch]->SetZTitle("#it{A}_{cell in cluster}^{total}");
4470  outputContainer->Add(fhDeltaIATotM20[imatch]);
4471 
4472  fhDeltaIANCells[imatch] = new TH3F
4473  (Form("hDeltaIANCells_%s",matchCase[imatch].Data()),
4474  Form("Cluster *asymmetry* in cell units vs N cells in cluster for %s",matchCase[imatch].Data()),
4475  nEbins,minE,maxE,cellBins,cellMin,cellMax,asyBins,asyMin,asyMax);
4476  fhDeltaIANCells[imatch]->SetXTitle("#it{E}_{cluster}");
4477  fhDeltaIANCells[imatch]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4478  fhDeltaIANCells[imatch]->SetZTitle("#it{A}_{cell in cluster}");
4479  outputContainer->Add(fhDeltaIANCells[imatch]);
4480 
4481  fhDeltaIATotNCells[imatch] = new TH3F
4482  (Form("hDeltaIATotNCells_%s",matchCase[imatch].Data()),
4483  Form("Cluster *total asymmetry* in cell units vs N cells in cluster for %s",matchCase[imatch].Data()),
4484  nEbins,minE,maxE,cellBins,cellMin,cellMax,asyBins,asyMin,asyMax);
4485  fhDeltaIATotNCells[imatch]->SetXTitle("#it{E}_{cluster}");
4486  fhDeltaIATotNCells[imatch]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4487  fhDeltaIATotNCells[imatch]->SetZTitle("#it{A}_{cell in cluster}^{total}");
4488  outputContainer->Add(fhDeltaIATotNCells[imatch]);
4489 
4490  if ( IsDataMC() )
4491  {
4492  fhDeltaIAOrigin[imatch] = new TH3F
4493  (Form("hDeltaIAOrigin_%s",matchCase[imatch].Data()),
4494  Form("Cluster *asymmetry* in cell units vs E vs primary ID, for ID %s",matchCase[imatch].Data()),
4495  nEbins,minE,maxE,10,-0.5,9.5,asyBins,asyMin,asyMax);
4496  fhDeltaIAOrigin[imatch]->SetXTitle("#it{E}_{cluster}");
4497  fhDeltaIAOrigin[imatch]->SetYTitle("particle");
4498  fhDeltaIAOrigin[imatch]->SetZTitle("#it{A}_{cell in cluster}");
4499  for(Int_t ilabel = 1; ilabel <=10; ilabel++)
4500  fhDeltaIAOrigin[imatch]->GetYaxis()->SetBinLabel(ilabel,mcParticleStringLabel[ilabel-1]);
4501  outputContainer->Add(fhDeltaIAOrigin[imatch]);
4502 
4503  fhDeltaIATotOrigin[imatch] = new TH3F
4504  (Form("hDeltaIATotOrigin_%s",matchCase[imatch].Data()),
4505  Form("Cluster *total asymmetry* in cell units vs E vs primary ID, for ID %s",matchCase[imatch].Data()),
4506  nEbins,minE,maxE,10,-0.5,9.5,asyBins,asyMin,asyMax);
4507  fhDeltaIATotOrigin[imatch]->SetXTitle("#it{E}_{cluster}");
4508  fhDeltaIATotOrigin[imatch]->SetYTitle("particle");
4509  fhDeltaIATotOrigin[imatch]->SetZTitle("#it{A}_{cell in cluster}");
4510  for(Int_t ilabel = 1; ilabel <=10; ilabel++)
4511  fhDeltaIATotOrigin[imatch]->GetYaxis()->SetBinLabel(ilabel,mcParticleStringLabel[ilabel-1]);
4512  outputContainer->Add(fhDeltaIATotOrigin[imatch]);
4513  }
4514  } // Cluster asymmetry
4515 
4516  fhClusterMaxCellDiffM02[imatch] = new TH3F
4517  (Form("hClusterMaxCellDiffM02_%s",matchCase[imatch].Data()),
4518  Form("#it{E}_{cluster} vs (#it{E}_{cluster} - #it{E}_{cell max})/#it{E}_{cluster} vs #sigma^{2}_{long} for ID %s",matchCase[imatch].Data()),
4519  nEbins,minE,maxE, 20,0,1.,nShShBins,minShSh,maxShSh);
4520  fhClusterMaxCellDiffM02[imatch]->SetXTitle("#it{E}_{cluster} (GeV) ");
4521  fhClusterMaxCellDiffM02[imatch]->SetYTitle("(#it{E}_{cluster} - #it{E}_{cell max})/ #it{E}_{cluster}");
4522  fhClusterMaxCellDiffM02[imatch]->SetZTitle("#sigma^{2}_{long}");
4523  outputContainer->Add(fhClusterMaxCellDiffM02[imatch]);
4524 
4525  fhClusterTimeEnergyM02[imatch] = new TH3F
4526  (Form("hClusterTimeEnergyM02_%s",matchCase[imatch].Data()),
4527  Form("#it{E} vs TOF vs #sigma^{2}_{long} for ID %s",matchCase[imatch].Data()),
4528  nEbins,minE,maxE,45,-25.5,20.5,nShShBins,minShSh,maxShSh);
4529  fhClusterTimeEnergyM02[imatch]->SetXTitle("#it{E} (GeV) ");
4530  fhClusterTimeEnergyM02[imatch]->SetYTitle("TOF (ns)");
4531  fhClusterTimeEnergyM02[imatch]->SetZTitle("#sigma^{2}_{long}");
4532  outputContainer->Add(fhClusterTimeEnergyM02[imatch]);
4533 
4534  fhNCellsPerClusterM02[imatch] = new TH3F
4535  (Form("hNCellsPerClusterM02_%s",matchCase[imatch].Data()),
4536  Form("#it{E} vs #it{n}_{cells} vs #sigma^{2}_{long} for ID %s",matchCase[imatch].Data()),
4537  nEbins,minE,maxE,cellBins,cellMin,cellMax,nShShBins,minShSh,maxShSh);
4538  fhNCellsPerClusterM02[imatch]->SetXTitle("#it{E} (GeV)");
4539  fhNCellsPerClusterM02[imatch]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4540  fhNCellsPerClusterM02[imatch]->SetZTitle("#sigma^{2}_{long}");
4541  outputContainer->Add(fhNCellsPerClusterM02[imatch]);
4542 
4543  fhNCellsPerClusterM20[imatch] = new TH3F
4544  (Form("hNCellsPerClusterM20_%s",matchCase[imatch].Data()),
4545  Form("#it{E} vs #it{n}_{cells} vs #sigma^{2}_{short} for ID %s",matchCase[imatch].Data()),
4546  nEbins,minE,maxE,cellBins,cellMin,cellMax,(Int_t)nShShBins/1.5,0,maxShSh/1.5);
4547  fhNCellsPerClusterM20[imatch]->SetXTitle("#it{E} (GeV)");
4548  fhNCellsPerClusterM20[imatch]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4549  fhNCellsPerClusterM20[imatch]->SetZTitle("#sigma^{2}_{short}");
4550  outputContainer->Add(fhNCellsPerClusterM20[imatch]);
4551 
4552  if ( fFillNLocMaxHistos )
4553  {
4554  fhNCellsPerClusterNLM[imatch] = new TH3F
4555  (Form("hNCellsPerClusterNLM_%s",matchCase[imatch].Data()),
4556  Form("#it{E} vs #it{n}_{cells} vs n_{lm} for ID %s",matchCase[imatch].Data()),
4557  nEbins,minE,maxE,cellBins,cellMin,cellMax,10,0,10);
4558  fhNCellsPerClusterNLM[imatch]->SetXTitle("#it{E} (GeV)");
4559  fhNCellsPerClusterNLM[imatch]->SetYTitle("#it{n}_{cells}^{w>0.01}");
4560  fhNCellsPerClusterNLM[imatch]->SetZTitle("n_{lm}");
4561  outputContainer->Add(fhNCellsPerClusterNLM[imatch]);
4562  }
4563 
4564  fhSMM02[imatch] = new TH3F
4565  (Form("hSMM02_%s",matchCase[imatch].Data()),
4566  Form("#it{E} vs SM number vs #sigma^{2}_{long}, #it{n}_{cells}^{w>0.01}>%d, for ID %s",fNCellMinShape,matchCase[imatch].Data()),
4567  nEbins,minE,maxE,fNModules,-0.5,fNModules-0.5,nShShBins,minShSh,maxShSh);
4568  fhSMM02[imatch]->SetXTitle("#it{E} (GeV)");
4569  fhSMM02[imatch]->SetYTitle("SM number");
4570  fhSMM02[imatch]->SetZTitle("#sigma^{2}_{long}");
4571  outputContainer->Add(fhSMM02[imatch]);
4572 
4573  fhSMM02NoCut[imatch] = new TH3F
4574  (Form("hSMM02NoCut_%s",matchCase[imatch].Data()),
4575  Form("#it{E} vs SM number vs #sigma^{2}_{long} for ID %s",matchCase[imatch].Data()),
4576  nEbins,minE,maxE,fNModules,-0.5,fNModules-0.5,nShShBins,minShSh,maxShSh);
4577  fhSMM02NoCut[imatch]->SetXTitle("#it{E} (GeV)");
4578  fhSMM02NoCut[imatch]->SetYTitle("SM number");
4579  fhSMM02NoCut[imatch]->SetZTitle("#sigma^{2}_{long}");
4580  outputContainer->Add(fhSMM02NoCut[imatch]);
4581 
4582  fhSMM20LowM02[imatch] = new TH3F
4583  (Form("hSMM20LowM02_%s",matchCase[imatch].Data()),
4584  Form("#it{E} vs SM number vs #sigma^{2}_{short}, #it{n}_{cells}^{w>0.01}>%d, for %2.2f<#sigma^{2}_{long}<%2.2f, for ID %s",
4585  fNCellMinShape, fM02LowBin[0], fM02LowBin[1], matchCase[imatch].Data()),
4586  nEbins,minE,maxE,fNModules,-0.5,fNModules-0.5,(Int_t)nShShBins/1.5,0,maxShSh/1.5);
4587  fhSMM20LowM02[imatch]->SetXTitle("#it{E} (GeV)");
4588  fhSMM20LowM02[imatch]->SetYTitle("SM number");
4589  fhSMM20LowM02[imatch]->SetZTitle("#sigma^{2}_{short}");
4590  outputContainer->Add(fhSMM20LowM02[imatch]);
4591 
4592  fhSMM20LowM02NoCut[imatch] = new TH3F
4593  (Form("hSMM20LowM02NoCut_%s",matchCase[imatch].Data()),
4594  Form("#it{E} vs SM number vs #sigma^{2}_{short}, for %2.2f<#sigma^{2}_{long}<%2.2f, for ID %s",
4595  fM02LowBin[0], fM02LowBin[1], matchCase[imatch].Data()),
4596  nEbins,minE,maxE,fNModules,-0.5,fNModules-0.5,(Int_t)nShShBins/1.5,0,maxShSh/1.5);
4597  fhSMM20LowM02NoCut[imatch]->SetXTitle("#it{E} (GeV)");
4598  fhSMM20LowM02NoCut[imatch]->SetYTitle("SM number");
4599  fhSMM20LowM02NoCut[imatch]->SetZTitle("#sigma^{2}_{short}");
4600  outputContainer->Add(fhSMM20LowM02NoCut[imatch]);
4601 
4602  fhSMM20HighM02[imatch] = new TH3F
4603  (Form("hSMM20HighM02_%s",matchCase[imatch].Data()),
4604  Form("#it{E} vs SM number vs #sigma^{2}_{short}, #it{n}_{cells}^{w>0.01}>%d, for %2.2f<#sigma^{2}_{long}<%2.2f, for ID %s",
4605  fNCellMinShape, fM02HighBin[0], fM02HighBin[1], matchCase[imatch].Data()),
4606  nEbins,minE,maxE,fNModules,-0.5,fNModules-0.5,(Int_t)nShShBins/1.5,0,maxShSh/1.5);
4607  fhSMM20HighM02[imatch]->SetXTitle("#it{E} (GeV)");
4608  fhSMM20HighM02[imatch]->SetYTitle("SM number");
4609  fhSMM20HighM02[imatch]->SetZTitle("#sigma^{2}_{short}");
4610  outputContainer->Add(fhSMM20HighM02[imatch]);
4611 
4612  fhSMM20HighM02NoCut[imatch] = new TH3F
4613  (Form("hSMM20HighM02NoCut_%s",matchCase[imatch].Data()),
4614  Form("#it{E} vs SM number vs #sigma^{2}_{short}, for %2.2f<#sigma^{2}_{long}<%2.2f, for ID %s",
4615  fM02HighBin[0], fM02HighBin[1], matchCase[imatch].Data()),
4616  nEbins,minE,maxE,fNModules,-0.5,fNModules-0.5,(Int_t)nShShBins/1.5,0,maxShSh/1.5);
4617  fhSMM20HighM02NoCut[imatch]->SetXTitle("#it{E} (GeV)");
4618  fhSMM20HighM02NoCut[imatch]->SetYTitle("SM number");
4619  fhSMM20HighM02NoCut[imatch]->SetZTitle("#sigma^{2}_{short}");
4620  outputContainer->Add(fhSMM20HighM02NoCut[imatch]);
4621 
4622  if(