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