-
Notifications
You must be signed in to change notification settings - Fork 0
/
CombineMesonMeasurementsPbPbLHC11h.C
9971 lines (8345 loc) · 674 KB
/
CombineMesonMeasurementsPbPbLHC11h.C
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/****************************************************************************************************************************
******** provided by Gamma Conversion Group, PWGGA, *****
******** Lucia Leardini, [email protected] *****
*****************************************************************************************************************************/
#include <Riostream.h>
#include "TMath.h"
#include <stdlib.h>
#include <fstream>
#include <math.h>
#include <TROOT.h>
#include <TApplication.h>
#include <TPaveLabel.h>
#include <TSystem.h>
#include <TFrame.h>
#include <TStyle.h>
#include <TString.h>
#include "TGaxis.h"
#include "TFile.h"
#include "TH1F.h"
#include "TH1D.h"
#include "TH2F.h"
#include "TF1.h"
#include "TVirtualFitter.h"
#include "TObject.h"
#include "TCanvas.h"
#include "TMultiGraph.h"
#include "TLegend.h"
#include "TDatabasePDG.h"
#include "TMinuit.h"
#include "TBenchmark.h"
#include "TRandom.h"
#include "TLatex.h"
#include "TASImage.h"
#include "TPostScript.h"
#include "TGraphErrors.h"
#include "TArrow.h"
#include "TGraphAsymmErrors.h"
#include "TGaxis.h"
#include "TMarker.h"
#include "Math/WrappedTF1.h"
#include "Math/BrentRootFinder.h"
#include "TFitResultPtr.h"
#include "TFitResult.h"
#include "CommonHeaders/PlottingGammaConversionHistos.h"
#include "CommonHeaders/PlottingGammaConversionAdditional.h"
#include "CommonHeaders/FittingGammaConversion.h"
#include "CommonHeaders/ConversionFunctionsBasicsAndLabeling.h"
#include "CommonHeaders/ConversionFunctions.h"
#include "CommonHeaders/CombinationFunctions.h"
#include "CombineMesonMeasurementsPbPbLHC11h.h"
void CombineMesonMeasurementsPbPbLHC11h(TString meson = "Pi0",
Bool_t noXerrorBars = kTRUE,
TString thisthesis="", //"This thesis",//"ALICE work in progress", //"This thesis",
Bool_t PaperPi0 = kFALSE,//kTRUE,
// Bool_t thesisPlotting = kFALSE, //kTRUE,
TString suffix = "pdf",
TString bWCorrection="X",
Bool_t quietMode = kTRUE){
gROOT->Reset();
gROOT->SetStyle("Plain");
gStyle->SetEndErrorSize(0);
StyleSettingsThesis();
SetPlotStyle();
TString dateForOutput = ReturnDateStringForOutput();
cout << dateForOutput.Data() << endl;
//___________________________________ Labels definition _____________________________________________
// TLatex *labelFactorPi0104 = new TLatex(0.85,0.405,"#times 4#times10^{2}");
// SetStyleTLatex( labelFactorPi0104,FontSize,4,colorCombo0010);
// TLatex *labelFactorPi0100 = new TLatex(0.85,0.34,"#times 10^{2}");
// SetStyleTLatex( labelFactorPi0100,FontSize,4,colorCombo2050);
// TLatex *labelFactorEta4 = new TLatex(0.85,0.247,"#times 4");
// SetStyleTLatex( labelFactorEta4,FontSize,4,colorCombo0010);
// TLatex *labelFactorEta = new TLatex(0.85,0.2,"#times 10^{-1}");
// SetStyleTLatex( labelFactorEta,FontSize,4,colorCombo2050);
TLatex *labelFactorPi0104 = new TLatex(0.83,0.41,"#times 4#times10^{2}");
SetStyleTLatex( labelFactorPi0104,FontSize,4,colorCombo0010);
TLatex *labelFactorPi0100 = new TLatex(0.83,0.35,"#times 10^{2}");
SetStyleTLatex( labelFactorPi0100,FontSize,4,colorCombo2050);
TLatex *labelFactorEta = new TLatex(0.83,0.16,"#times 2#times10^{-1}");
SetStyleTLatex( labelFactorEta,FontSize,4,colorCombo2050);
Bool_t thesisPlotting;
if(thisthesis.CompareTo("")==0) thesisPlotting = kFALSE;
else thesisPlotting = kTRUE;
Double_t maxX, minX;
if(thesisPlotting || PaperPi0){
maxX = 35;
minX = 0.5;
} else {
maxX = 35;
minX = 0.25;
}
TLatex *thesisLabelHigh = new TLatex(0.8,0.9,thisthesis.Data());
SetStyleTLatex( thesisLabelHigh,FontSize,4);
TLatex *thesisLabelHighRight = new TLatex(0.73,0.927,thisthesis.Data());
SetStyleTLatex( thesisLabelHighRight,FontSize,4);
TLatex *thesisLabelHighLeft = new TLatex(0.17,0.88,thisthesis.Data());
SetStyleTLatex( thesisLabelHighLeft,FontSize,4);
TLatex *thesisLabelHighLeft2 = new TLatex(0.132,0.91,thisthesis.Data());
SetStyleTLatex( thesisLabelHighLeft2,FontSize,4);
TLatex *thesisLabelLowRight = new TLatex(0.8,0.12,thisthesis.Data());
SetStyleTLatex( thesisLabelLowRight,FontSize,4);
TLatex *thesisLabelLowLeft = new TLatex(0.205,0.11,thisthesis.Data());
SetStyleTLatex( thesisLabelLowLeft,FontSize,4);
TLatex *sublabelA = new TLatex(11.25,1.8E-3,"(a)");
SetStyleTLatex( sublabelA, FontSize,4,kBlack,42,kFALSE);
TLatex *sublabelB = new TLatex(11.25,1.8E-3,"(b)");
SetStyleTLatex( sublabelB, FontSize,4,kBlack,42,kFALSE);
if(meson.CompareTo("Pi0")==0){ labelFactorLower = new TLatex(0.81,0.4615,"#times 4");}
else if(meson.CompareTo("Eta")==0){labelFactorLower = new TLatex(0.81,0.382,"#times 4");}
SetStyleTLatex( labelFactorLower, FontSize,4,colorCombo0010);
if(meson.CompareTo("Pi0")==0){ labelFactorLowerOnlyPbPb = new TLatex(0.81,0.268,"#times 4");}
else if(meson.CompareTo("Eta")==0){labelFactorLowerOnlyPbPb = new TLatex(0.81,0.32,"#times 4");}
SetStyleTLatex( labelFactorLowerOnlyPbPb,FontSize,4,colorCombo0010);
if(meson.CompareTo("Pi0")==0){ labelFactorUpper = new TLatex(0.415,0.89,"#times 4");}
else if(meson.CompareTo("Eta")==0){labelFactorUpper = new TLatex(0.43,0.835,"#times 4");}
SetStyleTLatex( labelFactorUpper,FontSize,4,colorCombo0010);
if(meson.CompareTo("Pi0")==0){ labelSystOnlyPbPb= new TLatex(0.75,0.93,"#pi^{0} #rightarrow #gamma#gamma");}
else if(meson.CompareTo("Eta")==0){labelSystOnlyPbPb= new TLatex(0.75,0.93,"#eta #rightarrow #gamma#gamma");}
SetStyleTLatex(labelSystOnlyPbPb,FontSize,4);
if(meson.CompareTo("Pi0")==0){ labelSyst= new TLatex(0.6,0.93,"#pi^{0} #rightarrow #gamma#gamma");}
else if(meson.CompareTo("Eta")==0){labelSyst= new TLatex(0.6,0.93,"#eta #rightarrow #gamma#gamma");}
SetStyleTLatex(labelSyst,FontSize,4);
if(meson.CompareTo("Pi0")==0){ labelSystRaa= new TLatex(0.6,0.89,"#pi^{0} #rightarrow #gamma#gamma");}
else if(meson.CompareTo("Eta")==0){labelSystRaa= new TLatex(0.6,0.89,"#eta #rightarrow #gamma#gamma ");}
SetStyleTLatex( labelSystRaa,FontSize,4);
TLatex *labelEnergyIndMeasRAA0010 = new TLatex(0.15,0.88,collisionSystemPbPb0010.Data());
SetStyleTLatex( labelEnergyIndMeasRAA0010,FontSize,4);
TLatex *labelEnergyIndMeasRAA2050 = new TLatex(0.15,0.88,collisionSystemPbPb2050.Data());
SetStyleTLatex( labelEnergyIndMeasRAA2050,FontSize,4);
TLatex *labelDetSysIndMeasRAA = new TLatex(0.15,0.84,"#pi^{0} #rightarrow #gamma#gamma");
if(meson.CompareTo("Eta")==0) labelDetSysIndMeasRAA= new TLatex(0.15,0.84,"#eta #rightarrow #gamma#gamma");
SetStyleTLatex( labelDetSysIndMeasRAA, FontSize,4);
TLatex *labelEnergyInvYieldSectionPi0LHC11h = new TLatex(0.6,0.88,collisionSystem2760GeV.Data());
SetStyleTLatex( labelEnergyInvYieldSectionPi0LHC11h,FontSize,4);
if(meson.CompareTo("Pi0")==0){
labelDetSysInvYieldSectionPi0LHC11h= new TLatex(0.6,0.84,"#pi^{0} #rightarrow #gamma#gamma");
} else if(meson.CompareTo("Eta")==0){
labelDetSysInvYieldSectionPi0LHC11h= new TLatex(0.6,0.84,"#eta #rightarrow #gamma#gamma");
}
SetStyleTLatex( labelDetSysInvYieldSectionPi0LHC11h, FontSize,4);
TLatex *labelEnergyInvYieldSectionPi0LHC11hnoPrelim = new TLatex(0.6,0.92,collisionSystem2760GeV.Data());
SetStyleTLatex( labelEnergyInvYieldSectionPi0LHC11hnoPrelim, 0.035,4);
if(meson.CompareTo("Pi0")==0){
labelDetSysInvYieldSectionPi0LHC11hnoPrelim= new TLatex(0.6,0.88,"#pi^{0} #rightarrow #gamma#gamma");
} else if(meson.CompareTo("Eta")==0){
labelDetSysInvYieldSectionPi0LHC11hnoPrelim= new TLatex(0.6,0.88,"#eta #rightarrow #gamma#gamma");
}
SetStyleTLatex( labelDetSysInvYieldSectionPi0LHC11hnoPrelim, 0.035,4);
if(meson.CompareTo("Pi0")==0){
labelDetSysInvYieldSectionPi0LHC11hwithPP= new TLatex(0.62,0.88,"#pi^{0} #rightarrow #gamma#gamma");
} else if(meson.CompareTo("Eta")==0){
labelDetSysInvYieldSectionPi0LHC11hwithPP= new TLatex(0.62,0.88,"#eta #rightarrow #gamma#gamma");
}
SetStyleTLatex( labelDetSysInvYieldSectionPi0LHC11hwithPP, 0.035,4);
TLatex *labelEtaToPi0Energy = new TLatex(0.12,0.89,collisionSystem2760GeV.Data());
SetStyleTLatex( labelEtaToPi0Energy,0.04,4);
for (Int_t i = 0; i < 11; i++){
colorDet[i] = GetDefaultColorDiffDetectors(nameMeasGlobal[i].Data(), kFALSE, kFALSE, kTRUE);
colorDetMC[i] = GetDefaultColorDiffDetectors(nameMeasGlobal[i].Data(), kTRUE, kFALSE, kTRUE);
markerStyleDet[i] = GetDefaultMarkerStyleDiffDetectors(nameMeasGlobal[i].Data(), kFALSE);
markerStyleDetMC[i] = GetDefaultMarkerStyleDiffDetectors(nameMeasGlobal[i].Data(), kTRUE);
markerSizeDet[i] = GetDefaultMarkerSizeDiffDetectors(nameMeasGlobal[i].Data(), kFALSE)*2;
markerSizeDetMC[i] = GetDefaultMarkerSizeDiffDetectors(nameMeasGlobal[i].Data(), kTRUE)*2;
}
Double_t mesonMassExpectPi0 = TDatabasePDG::Instance()->GetParticle(111)->Mass();
Double_t mesonMassExpectEta = TDatabasePDG::Instance()->GetParticle(221)->Mass();
Double_t mass = 0.;
if (meson.CompareTo("Pi0")==0){
mass = TDatabasePDG::Instance()->GetParticle(111)->Mass();
} else if (meson.CompareTo("Eta")==0){
mass = TDatabasePDG::Instance()->GetParticle(221)->Mass();
}
Double_t normErr0010 = pow(pow(xSection2760GeVErrpp/(xSection2760GeVpp*1e3),2)+pow((tAAErr0010/tAA0010),2)+pow((commonCentralityErr0010/100),2),0.5);
Double_t normErr2040 = pow(pow(xSection2760GeVErrpp/(xSection2760GeVpp*1e3),2)+pow((tAAErr2040/tAA2040),2)+pow((commonCentralityErr2040/100),2),0.5);
Double_t normErr2050 = pow(pow(xSection2760GeVErrpp/(xSection2760GeVpp*1e3),2)+pow((tAAErr2050/tAA2050),2)+pow((commonCentralityErr2040/100),2),0.5);
cout << "0010 taa: " << tAA0010 << " norm error " << normErr0010 << endl;
cout << "2040 taa: " << tAA2040 << " norm error " << normErr2040 << endl;
cout << "2050 taa: " << tAA2050 << " norm error " << normErr2050 << endl;
// return;
TBox* boxErrorNorm0010 = CreateBoxConv(kRed-7, 0.25, 1.-normErr0010 , 0.5, 1.+normErr0010);
TBox* boxErrorNorm2050 = CreateBoxConv(kAzure-4, 0.5, 1.-normErr2050 , 0.75, 1.+normErr2050);
TBox* boxErrorNorm0010_Single = CreateBoxConv(colorComb0005Box, 0.2, 1.-normErr0010 , 0.5, 1.+normErr0010);
TBox* boxErrorNorm2040_Single = CreateBoxConv(colorComb2040Box, 0.2, 1.-normErr2040 , 0.5, 1.+normErr2040);
TBox* boxErrorNorm2050_Single = CreateBoxConv(colorCombo2050, 0.2, 1.-normErr2050 , 0.5, 1.+normErr2050);
TBox* boxErrorNorm0010Only = CreateBoxConv(kRed-7, 0.25, 1.-normErr0010 , 0.5, 1.+normErr0010);
TBox* boxErrorNorm2050Only = CreateBoxConv(kAzure-4, 0.25, 1.-normErr2050 , 0.5, 1.+normErr2050);
TBox* boxErrorNorm2050EPOnly = CreateBoxConv(kBlue-7, 0.25, 1.-normErr2050 , 0.5, 1.+normErr2050);
//___________________________________ Declaration of files _____________________________________________
TString fileNameTheory = "ExternalInputPbPb/Theory/TheoryCompilationPbPb.root";
TString fileNameALICEData = Form("%s/%s/CombineMesonMeasurementsPbPb2760GeVX/InputALICEResultsPbPb2760GeV_%s.root",suffix.Data(),dateForOutput.Data(),dateForOutput.Data());
TString fileNameDataOtherEnergyInput = "ExternalInputPbPb/OtherExperiments/DataCompilationFromOtherEnergiesPbPbPi0andEta.root";
TString fileNameMesonpPb = "ExternalInputpPb/CombNeutralMesons/CombinedResultsPaper_pPb_5023GeV_2017_12_18.root";
TString outputDir = Form("%s/%s/CombineMesonMeasurementsPbPb2760GeV%s",suffix.Data(),dateForOutput.Data(),bWCorrection.Data());
TString paperPlots = Form("%s/PaperPlots_%s",outputDir.Data(),dateForOutput.Data());
TString PubNotePlots = Form("%s/PubNotePlots_%s",outputDir.Data(),dateForOutput.Data());
TString rootFiles = Form("%s/rootFiles",outputDir.Data());
TString nameFinalResDat = Form("%s/CombinedResults%s_FitResults.dat",outputDir.Data(),bWCorrection.Data());
gSystem->Exec("mkdir -p "+outputDir);
gSystem->Exec("mkdir -p "+paperPlots);
gSystem->Exec("mkdir -p "+PubNotePlots);
gSystem->Exec("mkdir -p "+rootFiles);
gSystem->Exec(Form("cp %s %s/Theory.root", fileNameTheory.Data(), rootFiles.Data()));
gSystem->Exec(Form("cp %s %s/InputALICEData.root", fileNameALICEData.Data(), rootFiles.Data()));
gSystem->Exec(Form("cp %s %s/OtherExperimentsInput.root", fileNameDataOtherEnergyInput.Data(), rootFiles.Data()));
//*********************************************************************************************************//
//************************************* Theory inputs *****************************************//
//*********************************************************************************************************//
TFile* fileTheoryGraphs = new TFile(fileNameTheory);
//**************************** pQCD calculation ****************************//
//inv yield = inv cross sec/xSection2760GeVppINEL
//**************************** Pi0 DSS14 ****************************//
TGraphAsymmErrors *graphNLOCalcmuHalfDSS14InvSecPi02760GeV = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphNLOCalcmuHalfDSS14InvSecPi02760GeV");
TGraphAsymmErrors *graphNLOCalcmuTwoDSS14InvSecPi02760GeV = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphNLOCalcmuTwoDSS14InvSecPi02760GeV");
TGraphAsymmErrors *graphNLOCalcDSS14InvSecPi02760GeV = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphNLOCalcDSS14InvCrossSecPi02760GeV");
TGraphAsymmErrors* graphNLOCalcDSS14InvYieldPi0Band = (TGraphAsymmErrors*)graphNLOCalcDSS14InvSecPi02760GeV->Clone("graphNLOCalcDSS14InvYieldPi0Band");
Double_t *yPi0PointDSS14muHalf = graphNLOCalcmuHalfDSS14InvSecPi02760GeV->GetY();
Double_t *yPi0PointDSS14muOne = graphNLOCalcDSS14InvSecPi02760GeV->GetY();
Double_t *yPi0PointDSS14muTwo = graphNLOCalcmuTwoDSS14InvSecPi02760GeV->GetY();
for(Int_t i =0; i<graphNLOCalcDSS14InvYieldPi0Band->GetN(); i++){
graphNLOCalcDSS14InvYieldPi0Band->SetPointEYhigh(i,yPi0PointDSS14muTwo[i]-yPi0PointDSS14muOne[i]);
graphNLOCalcDSS14InvYieldPi0Band->SetPointEYlow(i,yPi0PointDSS14muOne[i]-yPi0PointDSS14muHalf[i]);
}
graphNLOCalcDSS14InvYieldPi0Band->RemovePoint(0);
graphNLOCalcDSS14InvYieldPi0Band = ScaleGraph(graphNLOCalcDSS14InvYieldPi0Band,1./xSection2760GeVppINEL);
//**************************** Eta DSS07 ****************************//
TGraphAsymmErrors* graphNLOCalcmuHalfDSS07InvSecEta2760GeV = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphNLOCalcmuHalfDSS07InvSecEta2760GeV");
TGraphAsymmErrors* graphNLOCalcmuTwoDSS07InvSecEta2760GeV = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphNLOCalcmuTwoDSS07InvSecEta2760GeV");
TGraphAsymmErrors* graphNLOCalcDSS07InvSecEta2760GeV = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphNLOCalcDSS07InvCrossSecEta2760GeV");
TGraphAsymmErrors* graphNLOCalcDSS07InvYieldEtaBand = (TGraphAsymmErrors*)graphNLOCalcDSS07InvSecEta2760GeV->Clone("graphNLOCalcDSS07InvYieldEtaBand");
Double_t *yEtaPointDSS07muHalf = graphNLOCalcmuHalfDSS07InvSecEta2760GeV->GetY();
Double_t *yEtaPointDSS07muOne = graphNLOCalcDSS07InvSecEta2760GeV->GetY();
Double_t *yEtaPointDSS07muTwo = graphNLOCalcmuTwoDSS07InvSecEta2760GeV->GetY();
for(Int_t i =0; i<graphNLOCalcDSS07InvYieldEtaBand->GetN(); i++){
graphNLOCalcDSS07InvYieldEtaBand->SetPointEYhigh(i,yEtaPointDSS07muTwo[i]-yEtaPointDSS07muOne[i]);
graphNLOCalcDSS07InvYieldEtaBand->SetPointEYlow(i,yEtaPointDSS07muOne[i]-yEtaPointDSS07muHalf[i]);
}
graphNLOCalcDSS07InvYieldEtaBand->RemovePoint(0);
graphNLOCalcDSS07InvYieldEtaBand = ScaleGraph(graphNLOCalcDSS07InvYieldEtaBand,1./xSection2760GeVppINEL);
//**************************************** EPOS **********************************************
//New EPOS (2?) (file from Anders email of the 19th Feb. 2016)
TGraphErrors *graphEPOSPi0_0010 = (TGraphErrors*)fileTheoryGraphs->Get("graphEPOS_Pi0_0010");
TGraphErrors *graphEPOSEta_0010 = (TGraphErrors*)fileTheoryGraphs->Get("graphEPOS_Eta_0010");
TGraphErrors *graphEPOSPi0_2050 = (TGraphErrors*)fileTheoryGraphs->Get("graphEPOS_Pi0_2050");
TGraphErrors *graphEPOSEta_2050 = (TGraphErrors*)fileTheoryGraphs->Get("graphEPOS_Eta_2050");
TGraphErrors *graphEPOSEtaToPi0_0010 = (TGraphErrors*)fileTheoryGraphs->Get("graphEPOS_EtaToPi0_0010");
TGraphErrors *graphEPOSEtaToPi0_2050 = (TGraphErrors*)fileTheoryGraphs->Get("graphEPOS_EtaToPi0_2050");
DrawGammaSetMarkerTGraphErr(graphEPOSPi0_0010, 0, 0, colorEPOS0010,colorEPOS0010, 2, kFALSE, colorEPOS0010);
graphEPOSPi0_0010->SetLineStyle(5);
DrawGammaSetMarkerTGraphErr(graphEPOSPi0_2050, 0, 0, colorEPOS2050,colorEPOS2050, 2, kFALSE, colorEPOS2050);
graphEPOSPi0_2050->SetLineStyle(5);
DrawGammaSetMarkerTGraphErr(graphEPOSEta_0010, 0, 0, colorEPOS0010,colorEPOS0010, 2, kFALSE, colorEPOS0010);
graphEPOSEta_0010->SetLineStyle(5);
DrawGammaSetMarkerTGraphErr(graphEPOSEta_2050, 0, 0, colorEPOS2050,colorEPOS2050, 2, kFALSE, colorEPOS2050);
graphEPOSEta_2050->SetLineStyle(5);
if(meson.CompareTo("Pi0")==0){
graphEPOSpred_0010 = (TGraphErrors*)graphEPOSPi0_0010->Clone("graphEPOSpred_0010");
graphEPOSpred_2050 = (TGraphErrors*)graphEPOSPi0_2050->Clone("graphEPOSpred_2050");
} else if(meson.CompareTo("Eta")==0){
graphEPOSpred_0010 = (TGraphErrors*)graphEPOSEta_0010->Clone("graphEPOSpred_0010");
graphEPOSpred_2050 = (TGraphErrors*)graphEPOSEta_2050->Clone("graphEPOSpred_2050");
}
DrawGammaSetMarkerTGraphErr(graphEPOSpred_0010, 0, 0, colorEPOS0010,colorEPOS0010, 2, kTRUE, colorEPOS0010);
ProduceGraphErrWithoutXErrors(graphEPOSpred_0010);
graphEPOSpred_0010->SetLineStyle(5);
TGraphErrors *graphEPOSpredScaledforPlot_0010 = (TGraphErrors*)graphEPOSpred_0010->Clone("graphEPOSpredScaledforPlot_0010");
graphEPOSpredScaledforPlot_0010 = ScaleGraph(graphEPOSpredScaledforPlot_0010,4);
DrawGammaSetMarkerTGraphErr(graphEPOSpredScaledforPlot_0010, 0, 0, colorEPOS0010,colorEPOS0010, 2, kTRUE, colorEPOS0010);
ProduceGraphErrWithoutXErrors(graphEPOSpredScaledforPlot_0010);
graphEPOSpredScaledforPlot_0010->SetLineStyle(5);
DrawGammaSetMarkerTGraphErr(graphEPOSpred_2050, 0, 0, colorEPOS2050,colorEPOS2050, 2, kTRUE, colorEPOS2050);
ProduceGraphErrWithoutXErrors(graphEPOSpred_2050);
graphEPOSpred_2050->SetLineStyle(5);
DrawGammaSetMarkerTGraphErr(graphEPOSEtaToPi0_0010, 0, 0, colorEPOSEtaToPi00010,colorEPOSEtaToPi00010, 2, kTRUE, colorEPOS0010);
ProduceGraphErrWithoutXErrors(graphEPOSEtaToPi0_0010);
graphEPOSEtaToPi0_0010->SetLineStyle(5);
DrawGammaSetMarkerTGraphErr(graphEPOSEtaToPi0_2050, 0, 0, colorEPOS2050,colorEPOS2050, 2, kTRUE, colorEPOS2050);
ProduceGraphErrWithoutXErrors(graphEPOSEtaToPi0_2050);
graphEPOSEtaToPi0_2050->SetLineStyle(5);
//**************************************** Cracow **********************************************
TGraphAsymmErrors *TheoryCracowPi0LowPt_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowPi0LowPt_0010");
TGraphAsymmErrors *TheoryCracowPi0LowPt_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowPi0LowPt_2050");
TGraphAsymmErrors *TheoryCracowEtaLowPt_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowEtaLowPt_0010");
TGraphAsymmErrors *TheoryCracowEtaLowPt_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowEtaLowPt_2050");
TGraphAsymmErrors* TheoryCracowEtaToPi0LowPt_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowEtaToPi0LowPt_0010");
TGraphAsymmErrors* TheoryCracowEtaToPi0LowPt_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowEtaToPi0LowPt_2050");
TGraphAsymmErrors *TheoryCracowChargedPionLowPt_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowChargedPionLowPt_0010");
TGraphAsymmErrors *TheoryCracowChargedKaonLowPt_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryCracowChargedKaonLowPt_0010");
while(TheoryCracowPi0LowPt_0010->GetX()[TheoryCracowPi0LowPt_0010->GetN()-1]>3.) TheoryCracowPi0LowPt_0010->RemovePoint(TheoryCracowPi0LowPt_0010->GetN()-1);
while(TheoryCracowPi0LowPt_2050->GetX()[TheoryCracowPi0LowPt_2050->GetN()-1]>3.) TheoryCracowPi0LowPt_2050->RemovePoint(TheoryCracowPi0LowPt_2050->GetN()-1);
while(TheoryCracowEtaLowPt_0010->GetX()[TheoryCracowEtaLowPt_0010->GetN()-1]>3.) TheoryCracowEtaLowPt_0010->RemovePoint(TheoryCracowEtaLowPt_0010->GetN()-1);
while(TheoryCracowEtaLowPt_2050->GetX()[TheoryCracowEtaLowPt_2050->GetN()-1]>3.) TheoryCracowEtaLowPt_2050->RemovePoint(TheoryCracowEtaLowPt_2050->GetN()-1);
while(TheoryCracowEtaToPi0LowPt_0010->GetX()[TheoryCracowEtaToPi0LowPt_0010->GetN()-1]>3.) TheoryCracowEtaToPi0LowPt_0010->RemovePoint(TheoryCracowEtaToPi0LowPt_0010->GetN()-1);
while(TheoryCracowEtaToPi0LowPt_2050->GetX()[TheoryCracowEtaToPi0LowPt_2050->GetN()-1]>3.) TheoryCracowEtaToPi0LowPt_2050->RemovePoint(TheoryCracowEtaToPi0LowPt_2050->GetN()-1);
TGraphAsymmErrors *TheoryBegunEQPi0_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryBegunEQPi0_0010");
TGraphAsymmErrors *TheoryBegunEQPi0_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryBegunEQPi0_2050");
TGraphAsymmErrors *TheoryBegunEQEta_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryBegunEQEta_0010");
TGraphAsymmErrors *TheoryBegunEQEta_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryBegunEQEta_2050");
while(TheoryBegunEQPi0_0010->GetX()[TheoryBegunEQPi0_0010->GetN()-1]>3.) TheoryBegunEQPi0_0010->RemovePoint(TheoryBegunEQPi0_0010->GetN()-1);
while(TheoryBegunEQPi0_2050->GetX()[TheoryBegunEQPi0_2050->GetN()-1]>3.) TheoryBegunEQPi0_2050->RemovePoint(TheoryBegunEQPi0_2050->GetN()-1);
while(TheoryBegunEQEta_0010->GetX()[TheoryBegunEQEta_0010->GetN()-1]>3.) TheoryBegunEQEta_0010->RemovePoint(TheoryBegunEQEta_0010->GetN()-1);
while(TheoryBegunEQEta_2050->GetX()[TheoryBegunEQEta_2050->GetN()-1]>3.) TheoryBegunEQEta_2050->RemovePoint(TheoryBegunEQEta_2050->GetN()-1);
DrawGammaSetMarkerTGraph(TheoryBegunEQPi0_0010, 0, 0, kViolet+1,kViolet+1, 5, kTRUE, kViolet+1);
DrawGammaSetMarkerTGraph(TheoryBegunEQPi0_2050, 0, 0, kCyan+3,kCyan+3, 5, kTRUE, kCyan+3);
DrawGammaSetMarkerTGraph(TheoryBegunEQEta_0010, 0, 0, kPink+10,kPink+10, 5, kTRUE, kPink+10);
DrawGammaSetMarkerTGraph(TheoryBegunEQEta_2050, 0, 0, kTeal-7,kTeal-7, 5, kTRUE,kTeal-7);
TGraphAsymmErrors* TheoryCracowLowPt_0010 = NULL;
TGraphAsymmErrors* TheoryCracowLowPt_2050 = NULL;
TGraphAsymmErrors* TheoryBegunEQ_0010 = NULL;
TGraphAsymmErrors* TheoryBegunEQ_2050 = NULL;
if(meson.CompareTo("Pi0")==0){
TheoryCracowLowPt_0010 = (TGraphAsymmErrors*)TheoryCracowPi0LowPt_0010->Clone("TheoryCracowLowPt_0010");
TheoryCracowLowPt_2050 = (TGraphAsymmErrors*)TheoryCracowPi0LowPt_2050->Clone("TheoryCracowLowPt_2050");
TheoryBegunEQ_0010 = (TGraphAsymmErrors*)TheoryBegunEQPi0_0010->Clone("TheoryBegunEQ_0010");
TheoryBegunEQ_2050 = (TGraphAsymmErrors*)TheoryBegunEQPi0_2050->Clone("TheoryBegunEQ_2050");
} else if(meson.CompareTo("Eta")==0){
TheoryCracowLowPt_0010 = (TGraphAsymmErrors*)TheoryCracowEtaLowPt_0010->Clone("TheoryCracowLowPt_0010");
TheoryCracowLowPt_2050 = (TGraphAsymmErrors*)TheoryCracowEtaLowPt_2050->Clone("TheoryCracowLowPt_2050");
TheoryBegunEQ_0010 = (TGraphAsymmErrors*)TheoryBegunEQEta_0010->Clone("TheoryBegunEQ_0010");
TheoryBegunEQ_2050 = (TGraphAsymmErrors*)TheoryBegunEQEta_2050->Clone("TheoryBegunEQ_2050");
}
TGraphAsymmErrors *TheoryCracowLowPtScaledforPlot_0010 = (TGraphAsymmErrors*)TheoryCracowLowPt_0010->Clone("TheoryCracowLowPtScaledforPlot_0010");
TheoryCracowLowPtScaledforPlot_0010 = ScaleGraph(TheoryCracowLowPtScaledforPlot_0010,4);
DrawGammaSetMarkerTGraphAsym(TheoryCracowLowPtScaledforPlot_0010, 0, 0, colorCracow0010,colorCracow0010, 5, kTRUE, colorCracow0010);
DrawGammaSetMarkerTGraphAsym(TheoryCracowLowPt_0010, 0, 0, colorCracow0010,colorCracow0010, 5, kTRUE,colorCracow0010);
DrawGammaSetMarkerTGraphAsym(TheoryCracowLowPt_2050, 0, 0, colorCracow2050,colorCracow2050, 5, kTRUE,colorCracow2050);
DrawGammaSetMarkerTGraphAsym(TheoryCracowPi0LowPt_0010, 0, 0, kBlue+1,kBlue+1, 5, kTRUE, kBlue+1);
DrawGammaSetMarkerTGraphAsym(TheoryCracowEtaLowPt_0010, 0, 0, kRed+1,kRed+1, 5, kTRUE, kRed+1);
DrawGammaSetMarkerTGraphAsym(TheoryCracowChargedPionLowPt_0010, 0, 0, kCyan+2,kCyan+2, 5, kTRUE, kCyan+2);
DrawGammaSetMarkerTGraphAsym(TheoryCracowChargedKaonLowPt_0010, 0, 0, kMagenta+1,kMagenta+1, 5, kTRUE, kMagenta+1);
Int_t nBins = TheoryCracowPi0LowPt_0010->GetN();
Double_t *xBins = TheoryCracowPi0LowPt_0010->GetX();
Double_t *yKaons = TheoryCracowChargedKaonLowPt_0010->GetY();
Double_t *yPions = TheoryCracowChargedPionLowPt_0010->GetY();
Double_t *yPi0 = TheoryCracowPi0LowPt_0010->GetY();
Double_t *yEta = TheoryCracowEtaLowPt_0010->GetY();
Double_t *yPi0_2050 = TheoryCracowPi0LowPt_2050->GetY();
Double_t *yEta_2050 = TheoryCracowEtaLowPt_2050->GetY();
Double_t yKaonsToPions[nBins];
Double_t yEtaToPi0[nBins];
Double_t yEtaToPi0_2050[nBins];
Double_t yEtaToKaon[nBins];
Double_t yPi0ToPions[nBins];
for(Int_t n=0; n<TheoryCracowPi0LowPt_0010->GetN(); n++){
yKaonsToPions[n] = yKaons[n]/yPions[n];
yEtaToPi0[n] = yEta[n]/yPi0[n];
yEtaToPi0_2050[n] = yEta_2050[n]/yPi0_2050[n];
yEtaToKaon[n] = yEta[n]/yKaons[n];
yPi0ToPions[n] = yPi0[n]/yPions[n];
}
TGraphAsymmErrors *TheoryCracowChargedKaonToPionLowPt_0010 = new TGraphAsymmErrors(nBins,xBins,yKaonsToPions,0,0,0,0);
TGraphAsymmErrors *TheoryCracowEtaToPi0_0010 = new TGraphAsymmErrors(nBins,xBins,yEtaToPi0,0,0,0,0);
TGraphAsymmErrors *TheoryCracowEtaToPi0_2050 = new TGraphAsymmErrors(nBins,xBins,yEtaToPi0_2050,0,0,0,0);
TGraphAsymmErrors *TheoryCracowChargedEtaToKaonLowPt_0010 = new TGraphAsymmErrors(nBins,xBins,yEtaToKaon,0,0,0,0);
TGraphAsymmErrors *TheoryCracowPi0ToChargedPionLowPt_0010 = new TGraphAsymmErrors(nBins,xBins,yPi0ToPions,0,0,0,0);
while(TheoryBegunEQ_0010->GetX()[TheoryBegunEQ_0010->GetN()-1]>3.) TheoryBegunEQ_0010->RemovePoint(TheoryBegunEQ_0010->GetN()-1);
while(TheoryBegunEQ_2050->GetX()[TheoryBegunEQ_2050->GetN()-1]>3.) TheoryBegunEQ_2050->RemovePoint(TheoryBegunEQ_2050->GetN()-1);
TGraphAsymmErrors *TheoryBegunEQ_0010ScaledforPlot = (TGraphAsymmErrors*)TheoryBegunEQ_0010->Clone("TheoryBegunEQ_0010ScaledforPlot");
TheoryBegunEQ_0010ScaledforPlot = ScaleGraph(TheoryBegunEQ_0010ScaledforPlot,4);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQ_0010ScaledforPlot, 0, 0, colorBegun0010,colorBegun0010, 5, kTRUE, colorBegun0010);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQ_0010, 0, 0, colorBegun0010,colorBegun0010, 5, kTRUE, colorBegun0010);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQ_2050, 0, 0, colorBegun2050,colorBegun2050, 5, kTRUE, colorBegun2050);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQPi0_0010, 0, 0, colorBegun0010,colorBegun0010, 5, kTRUE, colorBegun0010);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQPi0_2050, 0, 0, colorBegun2050,colorBegun2050, 5, kTRUE, colorBegun2050);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQEta_0010, 0, 0, kOrange-4,kOrange-4, 5, kTRUE, kOrange-4);
DrawGammaSetMarkerTGraphAsym(TheoryBegunEQEta_2050, 0, 0, kAzure+6,kAzure+6, 5, kTRUE,kAzure+6);
TGraphAsymmErrors* TheoryBegunEQEtaToPi0_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryBegunEQEtaToPi0_0010");
TGraphAsymmErrors* TheoryBegunEQEtaToPi0_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("TheoryBegunEQEtaToPi0_2050");
while(TheoryBegunEQEtaToPi0_0010->GetX()[TheoryBegunEQEtaToPi0_0010->GetN()-1]>3.) TheoryBegunEQEtaToPi0_0010->RemovePoint(TheoryBegunEQEtaToPi0_0010->GetN()-1);
while(TheoryBegunEQEtaToPi0_2050->GetX()[TheoryBegunEQEtaToPi0_2050->GetN()-1]>3.) TheoryBegunEQEtaToPi0_2050->RemovePoint(TheoryBegunEQEtaToPi0_2050->GetN()-1);
DrawGammaSetMarkerTGraph(TheoryBegunEQEtaToPi0_0010, 0, 0, kViolet+1,kViolet+1, 5, kTRUE, kViolet+1);
DrawGammaSetMarkerTGraph(TheoryBegunEQEtaToPi0_2050, 0, 0, kCyan+1,kCyan+1, 5, kTRUE, kCyan+1);
//**************************** Jet Quenching NLO arXiv:1506.00838 ****************************//
TGraphAsymmErrors* graphPi0RAAJetQuenching_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphPi0RAAJetQuenching_0010");
TGraphAsymmErrors* graphEtaRAAJetQuenching_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphEtaRAAJetQuenching_0010");
TGraphAsymmErrors* graphEtaToPi0JetQuenching_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphEtaToPi0JetQuenching_0010");
//**************************** WHDG ****************************//
gWHDG_Pi0_Raa_0510 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphWHDGRAA0510");
gWHDG_Pi0_Raa_0005 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphWHDGRAA0005");
gWHDG_Pi0_Raa_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphWHDGRAA0010");
gWHDG_Pi0_Raa_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphWHDGRAA2050");
gWHDG_Eta_Raa_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphWHDGetaRAA0010");
gWHDG_Eta_Raa_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphWHDGetaRAA2050");
//**************************** Djordjevic ****************************//
TGraphAsymmErrors* graphPi0Djordjevic_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphPi0Djordjevic_0010");
TGraphAsymmErrors* graphPi0Djordjevic_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphPi0Djordjevic_2050");
//**************************** Vitev ****************************//
TGraphAsymmErrors* graphPi0VitevNew_0010 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphVitevNewRAA0010");
TGraphAsymmErrors* graphPi0VitevNew_2050 = (TGraphAsymmErrors*)fileTheoryGraphs->Get("graphVitevNewRAA2050");
//*********************************************************************************************************//
//******************************** Other experiment inputs *************************************//
//*********************************************************************************************************//
TFile* fileDataOtherEnergies = new TFile(fileNameDataOtherEnergyInput);
TGraphErrors* graphPHENIX200GeVInvYield_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVInvYield_0010");
TGraphErrors* graphPHENIX200GeVInvYield_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVInvYield_2040");
TGraphErrors* graphPHENIX200GeVInvYield_2050 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVInvYield_2050");
TGraphErrors* graphPHENIX200GeVEtaInvYield_0020 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaInvYield_0020");
TGraphErrors* graphPHENIX200GeVEtaInvYield_2060 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaInvYield_2060");
TGraphErrors* graphPHENIX39GeVInvYield_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX39GeVInvYield_0010");
TGraphErrors* graphPHENIX39GeVInvYield_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX39GeVInvYield_2040");
TGraphErrors* graphPHENIX62GeVInvYield_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX62GeVInvYield_0010");
TGraphErrors* graphPHENIX62GeVInvYield_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX62GeVInvYield_2040");
graphWA98_17_3GeVPi0RAA_0013 = (TGraphErrors*)fileDataOtherEnergies->Get("graphWA98RAA_0013");
graphPHENIX200GeVPi0RAA_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVRAA_0010");
graphPHENIX200GeVPi0RAA_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVRAA_2040");
graphPHENIX39GeVPi0RAA_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX39GeVRAA_0010");
graphPHENIX39GeVPi0RAA_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX39GeVRAA_2040");
graphPHENIX62GeVPi0RAA_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX62GeVRAA_0010");
graphPHENIX62GeVPi0RAA_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX62GeVRAA_2040");
graphPHENIX200GeVEtaToPi0Ratio_0020 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaToPi0Ratio_0020");
graphPHENIX200GeVEtaToPi0Ratio_2060 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaToPi0Ratio_2060");
graphPHENIX200GeVEtaRAA_0020 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaRAA_0020");
graphPHENIX200GeVEtaRAA_2060 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaRAA_2060");
graphPHENIX200GeVEtaRAA_0010 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaRAA_0010");
graphPHENIX200GeVEtaRAA_2040 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaRAA_2040");
graphPHENIX200GeVEtaHighPtRAA_2060 = (TGraphErrors*)fileDataOtherEnergies->Get("graphPHENIX200GeVEtaRAAHighPt_2060");
TFile* fileDataALICE = new TFile(fileNameALICEData);
//*********************************************************************************************************//
//********************************** Charged pions and kaons **************************************//
//*********************************************************************************************************//
TDirectoryFile* directoryChargedPbPb = (TDirectoryFile*)fileDataALICE->Get("ChargedParticles_PbPb_2.76TeV");
histoChargedPionSpectraStat0010 = (TH1D*)directoryChargedPbPb->Get("histoChargedPionSpectraStat0010");
histoChargedPionSpectraSyst0010 = (TH1D*)directoryChargedPbPb->Get("histoChargedPionSpectraSyst0010");
histoChargedPionSpectraStat2040 = (TH1D*)directoryChargedPbPb->Get("histoChargedPionSpectraStat2040");
histoChargedPionSpectraSyst2040 = (TH1D*)directoryChargedPbPb->Get("histoChargedPionSpectraSyst2040");
histoChargedKaonSpectraStat0010 = (TH1D*)directoryChargedPbPb->Get("histoChargedKaonSpectraStat0010");
histoChargedKaonSpectraSyst0010 = (TH1D*)directoryChargedPbPb->Get("histoChargedKaonSpectraSyst0010");
histoChargedKaonSpectraStat2040 = (TH1D*)directoryChargedPbPb->Get("histoChargedKaonSpectraStat2040");
histoChargedKaonSpectraSyst2040 = (TH1D*)directoryChargedPbPb->Get("histoChargedKaonSpectraSyst2040");
graphChargedRatioKaonToPion0010 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedRatioKaonToPion0010");
graphChargedRatioKaonToPionSys0010 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedRatioKaonToPionSys0010");
DrawGammaSetMarkerTGraphAsym(graphChargedRatioKaonToPion0010, 24,markerSizeComb, colorCharged, colorCharged);
DrawGammaSetMarkerTGraphAsym(graphChargedRatioKaonToPionSys0010,24,markerSizeComb, colorCharged, colorCharged, 1, kTRUE);
graphChargedRatioKaonToPion2040 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedRatioKaonToPion2040");
graphChargedRatioKaonToPionSys2040 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedRatioKaonToPionSys2040");
graphChargedPionRAA0010 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedPionRAA0010");
graphChargedPionRAASys0010 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedPionRAASys0010");
graphChargedPionRAA2040 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedPionRAA2040");
graphChargedPionRAASys2040 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedPionRAASys2040");
graphChargedKaonRAA0010 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedKaonRAA0010");
graphChargedKaonRAASys0010 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedKaonRAASys0010");
graphChargedKaonRAA2040 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedKaonRAA2040");
graphChargedKaonRAASys2040 = (TGraphAsymmErrors*)directoryChargedPbPb->Get("graphChargedKaonRAASys2040");
while(graphChargedKaonRAA0010->GetX()[0] < .3){
graphChargedKaonRAA0010->RemovePoint(0);
graphChargedKaonRAASys0010->RemovePoint(0);
graphChargedKaonRAA2040->RemovePoint(0);
graphChargedKaonRAASys2040->RemovePoint(0);
graphChargedPionRAA0010->RemovePoint(0);
graphChargedPionRAASys0010->RemovePoint(0);
graphChargedPionRAA2040->RemovePoint(0);
graphChargedPionRAASys2040->RemovePoint(0);
}
TGraphAsymmErrors* graphChargedPionRAATotErr0010 = AddErrorsOfGraphsQuadratically(graphChargedPionRAA0010,graphChargedPionRAASys0010);
DrawGammaSetMarkerTGraphAsym(graphChargedPionRAATotErr0010, 27,3, colorCharged,colorCharged, 0.1, kFALSE);
TGraphAsymmErrors* graphChargedKaonRAATotErr0010 = AddErrorsOfGraphsQuadratically(graphChargedKaonRAA0010,graphChargedKaonRAASys0010);
DrawGammaSetMarkerTGraphAsym(graphChargedKaonRAATotErr0010, 33,3, colorCharged,colorCharged, 0.1, kFALSE);
TGraphAsymmErrors* graphChargedPionRAATotErr2040 = AddErrorsOfGraphsQuadratically(graphChargedPionRAA2040,graphChargedPionRAASys2040);
DrawGammaSetMarkerTGraphAsym(graphChargedPionRAATotErr2040, 27,3, colorCharged,colorCharged, 0.1, kFALSE);
TGraphAsymmErrors* graphChargedKaonRAATotErr2040 = AddErrorsOfGraphsQuadratically(graphChargedKaonRAA2040,graphChargedKaonRAASys2040);
DrawGammaSetMarkerTGraphAsym(graphChargedKaonRAATotErr2040, 33,3, colorCharged,colorCharged, 0.1, kFALSE);
TDirectoryFile* directoryPerformancePbPb = (TDirectoryFile*)fileDataALICE->Get("Performance_PbPb_2.76TeV");
TH1D *histoPCMPi0MassData0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0MassData0010");
TH1D *histoPCMPi0MassMC0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0MassMC0010");
TH1D *histoPCMPi0WidthData0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0WidthData0010");
TH1D *histoPCMPi0WidthMC0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0WidthMC0010");
TH1D *histoPCMPi0MassData2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0MassData2050");
TH1D *histoPCMPi0MassMC2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0MassMC2050");
TH1D *histoPCMPi0WidthData2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0WidthData2050");
TH1D *histoPCMPi0WidthMC2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMPi0WidthMC2050");
TH1D *histoPCMEtaMassData0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaMassData0010");
TH1D *histoPCMEtaMassMC0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaMassMC0010");
TH1D *histoPCMEtaWidthData0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaWidthData0010");
TH1D *histoPCMEtaWidthMC0010 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaWidthMC0010");
TH1D *histoPCMEtaMassData2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaMassData2050");
TH1D *histoPCMEtaMassMC2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaMassMC2050");
TH1D *histoPCMEtaWidthData2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaWidthData2050");
TH1D *histoPCMEtaWidthMC2050 = (TH1D*)directoryPerformancePbPb->Get("histoPCMEtaWidthMC2050");
//*********************************************************************************************************//
//***************************************** Neutral mesons *********************************************//
//*********************************************************************************************************//
TDirectoryFile* directoryNeutralMesonPP7TeV = (TDirectoryFile*)fileDataALICE->Get("NeutralMesons_PP_7TeV");
graphCombEtaToPi0Ratiopp7TeVNoXErrors = (TGraphAsymmErrors*)directoryNeutralMesonPP7TeV->Get("graphCombEtaToPi0Ratiopp7TeVNoXErrors");
graphCombEtaToPi0RatioSysErrpp7TeV = (TGraphAsymmErrors*)directoryNeutralMesonPP7TeV->Get("graphCombEtaToPi0RatioSysErrpp7TeV");
DrawGammaSetMarkerTGraphAsym(graphCombEtaToPi0RatioSysErrpp7TeV, markerStylepp, markerSizepp, kBlack, kBlack, 1, kTRUE);
DrawGammaSetMarkerTGraphAsym(graphCombEtaToPi0Ratiopp7TeVNoXErrors, markerStylepp, markerSizepp, kBlack, kBlack, 1, kTRUE);
TDirectoryFile* directoryNeutralMesonPP = (TDirectoryFile*)fileDataALICE->Get("NeutralMesons_PP_2.76TeV");
//already scaled by 1./xSection2760GeVppINEL
graphInvSectionCombStatPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0Comb2760GeVAStatErr");
graphInvSectionCombSysPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0Comb2760GeVASysErr");
graphInvSectionCombStatPi02760GeVPlot = (TGraphAsymmErrors*)graphInvSectionCombStatPi02760GeV->Clone("graphInvSectionCombStatPi02760GeVPlot");
graphInvSectionCombSysPi02760GeVPlot = (TGraphAsymmErrors*)graphInvSectionCombSysPi02760GeV->Clone("graphInvSectionCombSysPi02760GeVPlot");
DrawGammaSetMarkerTGraphAsym(graphInvSectionCombStatPi02760GeVPlot, markerStylepp,markerSizepp, kBlack , kBlack);
if(noXerrorBars) ProduceGraphAsymmWithoutXErrors(graphInvSectionCombStatPi02760GeVPlot);
DrawGammaSetMarkerTGraphAsym(graphInvSectionCombSysPi02760GeVPlot, markerStylepp,markerSizepp, kBlack , kBlack, widthLinesBoxes, kTRUE);
TF1 *fitInvCrossSectionTsallisPi0Comb2760GeV = (TF1*)directoryNeutralMesonPP->Get("TsallisFitPi0");// ---> Tsallis fit is used for both bin-shifts
TF1 *fitInvCrossSectionTCMPi0Comb2760GeV = (TF1*)directoryNeutralMesonPP->Get("TwoComponentModelFitPi0");
graphInvSectionCombStatPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0Comb2760GeVAStatErr_yShifted");
graphInvSectionCombSysPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0Comb2760GeVASysErr_yShifted");
graphInvSectionPCMStatPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PCM2760GeVStatErr");
graphInvSectionPCMSysPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PCM2760GeVSysErr");
graphInvSectionPCMStatPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PCM2760GeVStatErr_yShifted");
graphInvSectionPCMSysPi02760GeV_yShifted = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PCM2760GeVSysErr_yShifted");//WITH material budget error
graphInvSectionPCMSysPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PCM2760GeVSysErr_forRAA");//WITHOUT common errors
graphInvSectionPHOSStatPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PHOS2760GeVStatErr");
graphInvSectionPHOSSysPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PHOS2760GeVSysErr");
graphInvSectionPHOSStatPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PHOS2760GeVStatErr_yShifted");
graphInvSectionPHOSSysPi02760GeV_yShifted = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PHOS2760GeVSysErr_yShifted");//WITH common errors
graphInvSectionPHOSSysPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0PHOS2760GeVSysErr_forRAA");//WITHOUT common errors
graphInvSectionEMCalStatPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0EMCAL2760GeVStatErr");
graphInvSectionEMCalSysPi02760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0EMCAL2760GeVSysErr");
graphInvSectionEMCalStatPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0EMCAL2760GeVStatErr_yShifted");
graphInvSectionEMCalSysPi02760GeV_yShifted = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0EMCAL2760GeVSysErr_yShifted");//WITH common errors
graphInvSectionEMCalSysPi02760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionPi0EMCAL2760GeVSysErr_forRAA");//WITHOUT common errors
graphInvSectionCombStatEta2760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaComb2760GeVAStatErr");
graphInvSectionCombSysEta2760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaComb2760GeVASysErr");
graphInvSectionCombStatEta2760GeVPlot = (TGraphAsymmErrors*)graphInvSectionCombStatEta2760GeV->Clone("graphInvSectionCombStatEta2760GeVPlot");
graphInvSectionCombSysEta2760GeVPlot = (TGraphAsymmErrors*)graphInvSectionCombSysEta2760GeV->Clone("graphInvSectionCombSysEta2760GeVPlot");
DrawGammaSetMarkerTGraphAsym(graphInvSectionCombStatEta2760GeVPlot, markerStylepp,markerSizepp, kBlack , kBlack);
if(noXerrorBars) ProduceGraphAsymmWithoutXErrors(graphInvSectionCombStatEta2760GeVPlot);
DrawGammaSetMarkerTGraphAsym(graphInvSectionCombSysEta2760GeVPlot, markerStylepp,markerSizepp, kBlack , kBlack, widthLinesBoxes, kTRUE);
TF1 *fitInvCrossSectionTsallisEtaComb2760GeV = (TF1*)directoryNeutralMesonPP->Get("TsallisFitEta");// ---> Tsallis fit is used for both bin-shifts
TF1 *fitInvCrossSectionTCMEtaComb2760GeV = (TF1*)directoryNeutralMesonPP->Get("TwoComponentModelFitEta");
graphInvSectionCombStatEta2760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaComb2760GeVAStatErr_yShifted");
graphInvSectionCombSysEta2760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaComb2760GeVASysErr_yShifted");
graphInvSectionPCMStatEta2760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaPCM2760GeVStatErr");
graphInvSectionPCMSysEta2760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaPCM2760GeVSysErr");
graphInvSectionPCMStatEta2760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaPCM2760GeVStatErr_yShifted");
graphInvSectionPCMSysEta2760GeV_yShifted = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaPCM2760GeVSysErr_yShifted");//WITH material budget error
graphInvSectionPCMSysEta2760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaPCM2760GeVSysErr_forRAA");//WITHOUT material budget error
graphInvSectionEMCalStatEta2760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaEMCAL2760GeVStatErr");
graphInvSectionEMCalSysEta2760GeV = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaEMCAL2760GeVSysErr");
graphInvSectionEMCalStatEta2760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaEMCAL2760GeVStatErr_yShifted");
graphInvSectionEMCalSysEta2760GeV_yShifted = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaEMCAL2760GeVSysErr_yShifted");//WITH common errors
graphInvSectionEMCalSysEta2760GeVforRAA = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphInvCrossSectionEtaEMCAL2760GeVSysErr_forRAA");//WITHOUT common errors
graphRatioEtaToPi0Comb2760GeVStatErr = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphRatioEtaToPi0Comb2760GeVStatErr");
graphRatioEtaToPi0Comb2760GeVSysErr = (TGraphAsymmErrors*)directoryNeutralMesonPP->Get("graphRatioEtaToPi0Comb2760GeVSysErr");
DrawGammaSetMarkerTGraphAsym(graphRatioEtaToPi0Comb2760GeVSysErr, markerStylepp, markerSizepp, kBlack, kBlack, 1, kTRUE);
DrawGammaSetMarkerTGraphAsym(graphRatioEtaToPi0Comb2760GeVStatErr, markerStylepp, markerSizepp, kBlack, kBlack, 1, kTRUE);
if(noXerrorBars) ProduceGraphAsymmWithoutXErrors(graphRatioEtaToPi0Comb2760GeVStatErr);
TDirectoryFile* directoryNeutralMesonPbPb = (TDirectoryFile*)fileDataALICE->Get("NeutralMesons_PbPb_2.76TeV");
TGraphAsymmErrors* graphPCMEtaRAAStatPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaPCMPbPb2760GeVStatErr_2040");
TGraphAsymmErrors* graphPCMEtaRAASysPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaPCMPbPb2760GeVSysErr_2040");
TGraphAsymmErrors* graphPCMPi0RAAStatPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0PCMPbPb2760GeVStatErr_2040");
TGraphAsymmErrors* graphPCMPi0RAASysPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0PCMPbPb2760GeVSysErr_2040");
TF1 *etapi0RatioFromMtScalingPCMPbPb2760GeV_0010 = (TF1*)directoryNeutralMesonPbPb->Get("etapi0RatioFromMtScalingPCMPbPb2760GeV_0010");
TF1 *etapi0RatioFromMtScalingCombPbPb2760GeV_0010 = (TF1*)directoryNeutralMesonPbPb->Get("etapi0RatioFromMtScalingCombPbPb2760GeV_0010");
TF1 *etapi0RatioFromMtScalingPCMPbPb2760GeV_2050 = (TF1*)directoryNeutralMesonPbPb->Get("etapi0RatioFromMtScalingPCMPbPb2760GeV_2050");
TF1 *etapi0RatioFromMtScalingCombPbPb2760GeV_2050 = (TF1*)directoryNeutralMesonPbPb->Get("etapi0RatioFromMtScalingCombPbPb2760GeV_2050");
graphPCMPubPi0InvYieldStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPubPbPb2760GeVStatErr_0010");
graphPCMPubPi0InvYieldSysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPubPbPb2760GeVSysErr_0010");
graphPCMPubPi0InvYieldStatPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPubPbPb2760GeVStatErr_2040");
graphPCMPubPi0InvYieldSysPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPubPbPb2760GeVSysErr_2040");
histoPi0PHOSPbPb0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldPi0PHOSPbPb2760GeVStatErr_0010");
graphPHOSPi0InvYieldStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PHOSPbPb2760GeVStatErr_0010");
graphPHOSPi0InvYieldSysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PHOSPbPb2760GeVSysErr_0010");
graphSysErrRAAYieldPi0PHOSPbPb0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PHOSPbPb2760GeVSysErr_forRAA_0010");
// cout << __LINE__ << endl;
// graphPHOSPi0InvYieldStatPbPb2760GeV_0010->Print();
// graphPHOSPi0InvYieldSysPbPb2760GeV_0010->Print();
// graphSysErrRAAYieldPi0PHOSPbPb0010->Print();
// return;
histoPCMPi0InvYieldPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldPi0PCMPbPb2760GeVStatErr_0010");
graphPCMPi0InvYieldStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVStatErr_0010");
graphPCMPi0InvYieldSysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVSysErr_0010");
graphPCMPi0InvYieldStatPbPb2760GeVwithYshift_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVStatErr_yShifted_0010");
graphPCMPi0InvYieldSysWOMat2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVSysErr_forRAA_0010");
histoPCMPi0RAAStatPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAPi0PCMPbPb2760GeVStatErr_0010");
graphPCMPi0RAAStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0PCMPbPb2760GeVStatErr_0010");
graphPCMPi0RAASysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0PCMPbPb2760GeVSysErr_0010");
// cout << __LINE__ << endl;
// graphPCMPi0InvYieldStatPbPb2760GeV_0010->Print();
// graphPCMPi0InvYieldSysPbPb2760GeV_0010->Print();
// graphPCMPi0InvYieldStatPbPb2760GeVwithYshift_0010->Print();
// graphPCMPi0InvYieldSysWOMat2760GeV_0010->Print();
// graphPCMPi0RAAStatPbPb2760GeV_0010->Print();
// graphPCMPi0RAASysPbPb2760GeV_0010->Print();
// return;
histoPCMPi0InvYieldPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldPi0PCMPbPb2760GeVStatErr_2050");
graphPCMPi0InvYieldStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVStatErr_2050");
graphPCMPi0InvYieldSysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVSysErr_2050");
graphPCMPi0InvYieldStatPbPb2760GeVwithYshift_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVStatErr_yShifted_2050");
graphPCMPi0InvYieldSysWOMat2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVSysErr_forRAA_2050");
histoPCMPi0RAAStatPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAPi0PCMPbPb2760GeVStatErr_2050");
graphPCMPi0RAAStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0PCMPbPb2760GeVStatErr_2050");
graphPCMPi0RAASysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0PCMPbPb2760GeVSysErr_2050");
// cout << __LINE__ << endl;
// graphPCMPi0InvYieldStatPbPb2760GeV_2050->Print();
// graphPCMPi0InvYieldSysPbPb2760GeV_2050->Print();
// graphPCMPi0InvYieldStatPbPb2760GeVwithYshift_2050->Print();
// graphPCMPi0InvYieldSysWOMat2760GeV_2050->Print();
// graphPCMPi0RAAStatPbPb2760GeV_2050->Print();
// graphPCMPi0RAASysPbPb2760GeV_2050->Print();
// return;
histoPCMPi0InvYieldPbPb2760GeV_2040 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldPi0PCMPbPb2760GeVStatErr_2040");
graphPCMPi0InvYieldStatPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVStatErr_2040");
graphPCMPi0InvYieldSysPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0PCMPbPb2760GeVSysErr_2040");
histoPCMEtaInvYieldPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldEtaPCMPbPb2760GeVStatErr_0010");
graphPCMEtaInvYieldStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVStatErr_0010");
graphPCMEtaInvYieldSysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVSysErr_0010");
graphPCMEtaInvYieldStatPbPb2760GeVwithYshift_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVStatErr_yShifted_0010");
graphPCMEtaInvYieldSysWOMat2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVSysErr_forRAA_0010");
histoPCMEtaRAAStatPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAEtaPCMPbPb2760GeVStatErr_0010");
graphPCMEtaRAAStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaPCMPbPb2760GeVStatErr_0010");
graphPCMEtaRAASysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaPCMPbPb2760GeVSysErr_0010");
histoPCMEtatoPi0Stat2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoEtaToPi0RatioPCMPbPb2760GeVStatErr_0010");
graphPCMEtatoPi0Stat2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioPCMPbPb2760GeVStatErr_0010");
graphPCMEtatoPi0Sys2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioPCMPbPb2760GeVSysErr_0010");
histoPCMEtaInvYieldPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldEtaPCMPbPb2760GeVStatErr_2050");
graphPCMEtaInvYieldStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVStatErr_2050");
graphPCMEtaInvYieldSysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVSysErr_2050");
graphPCMEtaInvYieldStatPbPb2760GeVwithYshift_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVStatErr_yShifted_2050");
graphPCMEtaInvYieldSysWOMat2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVSysErr_forRAA_2050");
histoPCMEtaRAAStatPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAEtaPCMPbPb2760GeVStatErr_2050");
graphPCMEtaRAAStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaPCMPbPb2760GeVStatErr_2050");
graphPCMEtaRAASysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaPCMPbPb2760GeVSysErr_2050");
histoPCMEtatoPi0Stat2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoEtaToPi0RatioPCMPbPb2760GeVStatErr_2050");
graphPCMEtatoPi0Stat2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioPCMPbPb2760GeVStatErr_2050");
graphPCMEtatoPi0Sys2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioPCMPbPb2760GeVSysErr_2050");
histoPCMEtaInvYieldPbPb2760GeV_2040 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldEtaPCMPbPb2760GeVStatErr_2040");
graphPCMEtaInvYieldStatPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVStatErr_2040");
graphPCMEtaInvYieldSysPbPb2760GeV_2040 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaPCMPbPb2760GeVSysErr_2040");
histoEMCalPi0InvYieldStatPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldPi0EMCalPbPb2760GeVStatErr_0010");
graphEMCalPi0InvYieldStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0EMCalPbPb2760GeVStatErr_0010");
graphEMCalPi0InvYieldSysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0EMCalPbPb2760GeVSysErr_0010");
graphEMCalPi0InvYieldSysPbPb2760GeVforRAA_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0EMCalPbPb2760GeVSysErr_forRAA_0010");
histoEMCalPi0RAAStatPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAPi0EMCalPbPb2760GeVStatErr_0010");
// graphEMCalPi0RAAStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0EMCalPbPb2760GeVStatErr_0010");
// graphEMCalPi0RAASysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0EMCalPbPb2760GeVSysErr_0010");
histoEMCalPi0InvYieldStatPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldPi0EMCalPbPb2760GeVStatErr_2050");
graphEMCalPi0InvYieldStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0EMCalPbPb2760GeVStatErr_2050");
graphEMCalPi0InvYieldSysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0EMCalPbPb2760GeVSysErr_2050");
graphEMCalPi0InvYieldSysPbPb2760GeVforRAA_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldPi0EMCalPbPb2760GeVSysErr_forRAA_2050");
histoEMCalPi0RAAStatPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAPi0EMCalPbPb2760GeVStatErr_2050");
// graphEMCalPi0RAAStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0EMCalPbPb2760GeVStatErr_2050");
// graphEMCalPi0RAASysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAPi0EMCalPbPb2760GeVSysErr_2050");
histoEMCalEtaInvYieldStatPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldEtaEMCalPbPb2760GeVStatErr_0010");
graphEMCalEtaInvYieldStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaEMCalPbPb2760GeVStatErr_0010");
graphEMCalEtaInvYieldSysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaEMCalPbPb2760GeVSysErr_0010");
graphEMCalEtaInvYieldSysPbPb2760GeVforRAA_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaEMCalPbPb2760GeVSysErr_forRAA_0010");
histoEMCalEtaRAAStatPbPb2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAEtaEMCalPbPb2760GeVStatErr_0010");
// graphEMCalEtaRAAStatPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaEMCalPbPb2760GeVStatErr_0010");
// graphEMCalEtaRAASysPbPb2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaEMCalPbPb2760GeVSysErr_0010");
histoEMCalEtatoPi0Stat2760GeV_0010 = (TH1D*)directoryNeutralMesonPbPb->Get("histoEtaToPi0RatioEMCalPbPb2760GeVStatErr_0010");
graphEMCalEtatoPi0Stat2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioEMCalPbPb2760GeVStatErr_0010");
graphEMCalEtatoPi0Sys2760GeV_0010 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioEMCalPbPb2760GeVSysErr_0010");
histoEMCalEtaInvYieldStatPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoInvYieldEtaEMCalPbPb2760GeVStatErr_2050");
graphEMCalEtaInvYieldStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaEMCalPbPb2760GeVStatErr_2050");
graphEMCalEtaInvYieldSysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaEMCalPbPb2760GeVSysErr_2050");
graphEMCalEtaInvYieldSysPbPb2760GeVforRAA_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphInvYieldEtaEMCalPbPb2760GeVSysErr_forRAA_2050");
histoEMCalEtaRAAStatPbPb2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoRAAEtaEMCalPbPb2760GeVStatErr_2050");
// graphEMCalEtaRAAStatPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaEMCalPbPb2760GeVStatErr_2050");
// graphEMCalEtaRAASysPbPb2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphRAAEtaEMCalPbPb2760GeVSysErr_2050");
histoEMCalEtatoPi0Stat2760GeV_2050 = (TH1D*)directoryNeutralMesonPbPb->Get("histoEtaToPi0RatioEMCalPbPb2760GeVStatErr_2050");
graphEMCalEtatoPi0Stat2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioEMCalPbPb2760GeVStatErr_2050");
graphEMCalEtatoPi0Sys2760GeV_2050 = (TGraphAsymmErrors*)directoryNeutralMesonPbPb->Get("graphEtaToPi0RatioEMCalPbPb2760GeVSysErr_2050");
TH1D * ratioRCSC = (TH1D*)histoEMCalPi0InvYieldStatPbPb2760GeV_0010->Clone();
ratioRCSC->Divide(histoEMCalPi0InvYieldStatPbPb2760GeV_0010,histoEMCalPi0InvYieldStatPbPb2760GeV_2050,nColl2050,nColl0010,"");
// *******************************************************************************************************
// ************************** Combination of different measurements **************************************
// *******************************************************************************************************
// REMARKS:
// - order of measurements defined in CombinePtPointsSpectraFullCorrMat from CombinationFunctions.h
// - correlations are defined in CombinePtPointsSpectraFullCorrMat from CombinationFunctions.h
// - currently only PCM - EMCal vs others fully implemeted energy independent
// - extendable to other energies
// - offsets have to be determined manually, see cout's in shell from combination function, more can be uncommented
// definition of array of histograms (NULL - means we have no measurement at this energy for this rec-method)
// for statistical error and final value from respective method
for (Int_t i = 0; i< 11; i++){
statErrorCollectionLHC11h_0010[i] = NULL;
statErrorCollectionLHC11h_2050[i] = NULL;
statErrorCollectionEtatoPi0LHC11h_0010[i] = NULL;
statErrorCollectionEtatoPi0LHC11h_2050[i] = NULL;
statErrorCollectionRaaLHC11h_0010[i] = NULL;
statErrorCollectionRaaLHC11h_2050[i] = NULL;
}
if(meson.CompareTo("Pi0")==0){
statErrorCollectionLHC11h_0010[0] = (TH1D*)histoPCMPi0InvYieldPbPb2760GeV_0010->Clone("statErrPCMPi0_0010");
statErrorCollectionLHC11h_0010[1] = (TH1D*)histoPi0PHOSPbPb0010->Clone("statErrPHOSPi0_0010");
statErrorCollectionLHC11h_0010[2] = (TH1D*)histoEMCalPi0InvYieldStatPbPb2760GeV_0010->Clone("statErrEMCalPi0_0010");
statErrorCollectionLHC11h_2050[0] = (TH1D*)histoPCMPi0InvYieldPbPb2760GeV_2050->Clone("statErrPCMPi0_2050");
statErrorCollectionLHC11h_2050[2] = (TH1D*)histoEMCalPi0InvYieldStatPbPb2760GeV_2050->Clone("statErrEMCalPi0_2050");
statErrorCollectionRaaLHC11h_0010[0] = (TH1D*)histoPCMPi0RAAStatPbPb2760GeV_0010->Clone("statErrPCMPi0RAA_0010");
statErrorCollectionRaaLHC11h_0010[2] = (TH1D*)histoEMCalPi0RAAStatPbPb2760GeV_0010->Clone("statErrEMCalPi0RAA_0010");
statErrorCollectionRaaLHC11h_2050[0] = (TH1D*)histoPCMPi0RAAStatPbPb2760GeV_2050->Clone("statErrPCMPi0RAA_2050");
statErrorCollectionRaaLHC11h_2050[2] = (TH1D*)histoEMCalPi0RAAStatPbPb2760GeV_2050->Clone("statErrEMCalPi0RAA_2050");
} else if(meson.CompareTo("Eta")==0) {
statErrorCollectionLHC11h_0010[0] = (TH1D*)histoPCMEtaInvYieldPbPb2760GeV_0010->Clone("statErrPCMEta_0010");
statErrorCollectionLHC11h_0010[2] = (TH1D*)histoEMCalEtaInvYieldStatPbPb2760GeV_0010->Clone("statErrEMCalEta_0010");
statErrorCollectionLHC11h_2050[0] = (TH1D*)histoPCMEtaInvYieldPbPb2760GeV_2050->Clone("statErrPCMEta_2050");
statErrorCollectionLHC11h_2050[2] = (TH1D*)histoEMCalEtaInvYieldStatPbPb2760GeV_2050->Clone("statErrEMCalEta_2050");
statErrorCollectionEtatoPi0LHC11h_0010[0] = (TH1D*)histoPCMEtatoPi0Stat2760GeV_0010->Clone("statErrPCMEtatoPi0_0010");
statErrorCollectionEtatoPi0LHC11h_0010[2] = (TH1D*)histoEMCalEtatoPi0Stat2760GeV_0010->Clone("statErrEMCalEtatoPi0_0010");
statErrorCollectionEtatoPi0LHC11h_2050[0] = (TH1D*)histoPCMEtatoPi0Stat2760GeV_2050->Clone("statErrPCMEtatoPi0_2050");
statErrorCollectionEtatoPi0LHC11h_2050[2] = (TH1D*)histoEMCalEtatoPi0Stat2760GeV_2050->Clone("statErrEMCalEtatoPi0_2050");
statErrorCollectionRaaLHC11h_0010[0] = (TH1D*)histoPCMEtaRAAStatPbPb2760GeV_0010->Clone("statErrPCMEtaRAA_0010");
statErrorCollectionRaaLHC11h_0010[2] = (TH1D*)histoEMCalEtaRAAStatPbPb2760GeV_0010->Clone("statErrEMCalEtaRAA_0010");
statErrorCollectionRaaLHC11h_2050[0] = (TH1D*)histoPCMEtaRAAStatPbPb2760GeV_2050->Clone("statErrPCMEtaRAA_2050");
statErrorCollectionRaaLHC11h_2050[2] = (TH1D*)histoEMCalEtaRAAStatPbPb2760GeV_2050->Clone("statErrEMCalEtaRAA_2050");
}
// definition of array of TGraphAsymmErrors (NULL - means we have no measurement at this energy for this rec-method)
// for systematic error from respective method
for (Int_t i = 0; i< 11; i++){
sysErrorCollectionLHC11h_0010[i] = NULL;
sysErrorCollectionLHC11h_2050[i] = NULL;
sysErrorCollectionforRatiosLHC11h_0010[i] = NULL;
sysErrorCollectionforRatiosLHC11h_2050[i] = NULL;
sysErrorCollectionEtatoPi0LHC11h_0010[i] = NULL;
sysErrorCollectionEtatoPi0LHC11h_2050[i] = NULL;
sysErrorCollectionRaaLHC11h_0010[i] = NULL;
sysErrorCollectionRaaLHC11h_2050[i] = NULL;
}
if(meson.CompareTo("Pi0")==0){
sysErrorCollectionLHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMPi0InvYieldSysPbPb2760GeV_0010->Clone("sysErrPCMPi0_0010");
sysErrorCollectionLHC11h_0010[1] = (TGraphAsymmErrors*)graphPHOSPi0InvYieldSysPbPb2760GeV_0010->Clone("sysErrPHOSPi0_0010");
sysErrorCollectionLHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalPi0InvYieldSysPbPb2760GeV_0010->Clone("sysErrEMCalPi0_0010");
sysErrorCollectionLHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMPi0InvYieldSysPbPb2760GeV_2050->Clone("sysErrPCMPi0_2050");
sysErrorCollectionLHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalPi0InvYieldSysPbPb2760GeV_2050->Clone("sysErrEMCalPi0_2050");
sysErrorCollectionforRatiosLHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMPi0InvYieldSysWOMat2760GeV_0010->Clone("sysErrPCMWOMatPi0_0010");
sysErrorCollectionforRatiosLHC11h_0010[1] = (TGraphAsymmErrors*)graphSysErrRAAYieldPi0PHOSPbPb0010->Clone("sysErrPHOSTypeBPi0_0010");
sysErrorCollectionforRatiosLHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalPi0InvYieldSysPbPb2760GeVforRAA_0010->Clone("sysErrEMCalforRAAPi0_0010");
sysErrorCollectionforRatiosLHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMPi0InvYieldSysWOMat2760GeV_2050->Clone("sysErrPCMWOMatPi0_2050");
sysErrorCollectionforRatiosLHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalPi0InvYieldSysPbPb2760GeVforRAA_2050->Clone("sysErrEMCalforRAAPi0_2050");
// sysErrorCollectionRaaLHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMPi0RAASysPbPb2760GeV_0010->Clone("sysErrPCMPi0Raa_0010");
// sysErrorCollectionRaaLHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalPi0RAASysPbPb2760GeV_0010->Clone("sysErrEMCalPi0Raa_0010");
// sysErrorCollectionRaaLHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMPi0RAASysPbPb2760GeV_2050->Clone("sysErrPCMPi0Raa_2050");
// sysErrorCollectionRaaLHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalPi0RAASysPbPb2760GeV_2050->Clone("sysErrEMCalPi0Raa_2050");
} else if(meson.CompareTo("Eta")==0) {
sysErrorCollectionLHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMEtaInvYieldSysPbPb2760GeV_0010->Clone("sysErrPCMEta_0010");
sysErrorCollectionLHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalEtaInvYieldSysPbPb2760GeV_0010->Clone("sysErrEMCalEta_0010");
sysErrorCollectionLHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMEtaInvYieldSysPbPb2760GeV_2050->Clone("sysErrPCMEta_2050");
sysErrorCollectionLHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalEtaInvYieldSysPbPb2760GeV_2050->Clone("sysErrEMCalEta_2050");
sysErrorCollectionforRatiosLHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMEtaInvYieldSysWOMat2760GeV_0010->Clone("sysErrPCMWOMatEta_0010");
sysErrorCollectionforRatiosLHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalEtaInvYieldSysPbPb2760GeVforRAA_0010->Clone("sysErrEMCalforRAAEta_0010");
sysErrorCollectionforRatiosLHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMEtaInvYieldSysWOMat2760GeV_2050->Clone("sysErrPCMWOMatEta_2050");
sysErrorCollectionforRatiosLHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalEtaInvYieldSysPbPb2760GeVforRAA_2050->Clone("sysErrEMCalforRAAEta_2050");
sysErrorCollectionEtatoPi0LHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMEtatoPi0Sys2760GeV_0010->Clone("sysErrPCMEtatoPi0_0010");
sysErrorCollectionEtatoPi0LHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalEtatoPi0Sys2760GeV_0010->Clone("sysErrEMCalEtatoPi0_0010");
sysErrorCollectionEtatoPi0LHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMEtatoPi0Sys2760GeV_2050->Clone("sysErrPCMEtatoPi0_2050");
sysErrorCollectionEtatoPi0LHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalEtatoPi0Sys2760GeV_2050->Clone("sysErrEMCalEtatoPi0_2050");
// sysErrorCollectionRaaLHC11h_0010[0] = (TGraphAsymmErrors*)graphPCMEtaRAASysPbPb2760GeV_0010->Clone("sysErrPCMEtaRaa_0010");
// sysErrorCollectionRaaLHC11h_0010[2] = (TGraphAsymmErrors*)graphEMCalEtaRAASysPbPb2760GeV_0010->Clone("sysErrEMCalEtaRaa_0010");
// sysErrorCollectionRaaLHC11h_2050[0] = (TGraphAsymmErrors*)graphPCMEtaRAASysPbPb2760GeV_2050->Clone("sysErrPCMEtaRaa_2050");
// sysErrorCollectionRaaLHC11h_2050[2] = (TGraphAsymmErrors*)graphEMCalEtaRAASysPbPb2760GeV_2050->Clone("sysErrEMCalEtaRaa_2050");
}
cout << __LINE__ << endl;
Int_t textSizeLabelsPixel = 900*0.04;
TCanvas* canvasWeights = new TCanvas("canvasWeights","",200,10,1350,900); // gives the page size
DrawGammaCanvasSettings( canvasWeights, 0.08, 0.02, 0.035, 0.09);
canvasWeights->SetLogx();
TH2F * histo2DWeights = new TH2F("histo2DWeights","histo2DWeights",11000,0.23,70.,1000,-0.6,1.1);
SetStyleHistoTH2ForGraphs(histo2DWeights, "#it{p}_{T} (GeV/#it{c})","#omega_{a} for BLUE",0.035,0.04, 0.035,0.04, 1.,1.);
histo2DWeights->GetXaxis()->SetMoreLogLabels();
histo2DWeights->GetXaxis()->SetLabelOffset(-0.01);
histo2DWeights->Draw("copy");
TLatex *labelWeightsEnergy = new TLatex(0.7,0.20,collisionSystem2760GeV.Data());
SetStyleTLatex( labelWeightsEnergy, 0.85*textSizeLabelsPixel,4);
labelWeightsEnergy->SetTextFont(43);
if(meson.CompareTo("Pi0")==0){
labelWeightsPi0 = new TLatex(0.7,0.16,"#pi^{0} #rightarrow #gamma#gamma");
} else if(meson.CompareTo("Eta")==0){
labelWeightsPi0 = new TLatex(0.7,0.16,"#eta #rightarrow #gamma#gamma");
}
SetStyleTLatex( labelWeightsPi0, 0.85*textSizeLabelsPixel,4);
labelWeightsPi0->SetTextFont(43);
//**********************************************************************************************************************//
//**************************************** Combination WITHOUT common errors ********************************************//
//**********************************************************************************************************************//
for (Int_t i = 0; i< 11; i++){
graphWeightsALHC11h_0010[i] = NULL;
graphWeightsALHC11h_2050[i] = NULL;
}
TString fileNameOutputWeightingALHC11h_0010 = Form("%s/0010LHC11h_WeightingMethodA%s.dat",outputDir.Data(),meson.Data());
TString fileNameOutputWeightingALHC11h_2050 = Form("%s/2050LHC11h_WeightingMethodA%s.dat",outputDir.Data(),meson.Data());
cout << __LINE__ << endl;
if(meson.CompareTo("Pi0")==0){
// Declaration & calculation of combined spectrum
graphCombInvYieldTotPbPb2760GeVA_0010 = CombinePtPointsSpectraFullCorrMat( statErrorCollectionLHC11h_0010, sysErrorCollectionforRatiosLHC11h_0010,
xPtLimitsPi0, 23, offSetsPi0, offSetsPi0Sys,
graphCombInvYieldStatPbPb2760GeVA_0010, graphCombInvYieldSysPbPb2760GeVA_0010,
fileNameOutputWeightingALHC11h_0010);
graphCombInvYieldTotPbPb2760GeVA_2050 = CombinePtPointsSpectraFullCorrMat( statErrorCollectionLHC11h_2050, sysErrorCollectionforRatiosLHC11h_2050,
xPtLimitsPi0, 23, offSetsPi0, offSetsPi0Sys,
graphCombInvYieldStatPbPb2760GeVA_2050, graphCombInvYieldSysPbPb2760GeVA_2050,
fileNameOutputWeightingALHC11h_2050);
while(graphCombInvYieldTotPbPb2760GeVA_0010->GetY()[0] < 1e-14){
graphCombInvYieldTotPbPb2760GeVA_0010->RemovePoint(0);
graphCombInvYieldStatPbPb2760GeVA_0010->RemovePoint(0);
graphCombInvYieldSysPbPb2760GeVA_0010->RemovePoint(0);
graphCombInvYieldTotPbPb2760GeVA_2050->RemovePoint(0);
graphCombInvYieldStatPbPb2760GeVA_2050->RemovePoint(0);
graphCombInvYieldSysPbPb2760GeVA_2050->RemovePoint(0);
}
// graphCombInvYieldSysPbPb2760GeVA_0010->Print();
// graphCombInvYieldSysPbPb2760GeVA_2050->Print();
// return;
} else if(meson.CompareTo("Eta")==0){
cout << __LINE__ << endl;
// Declaration & calculation of combined spectrum
graphCombInvYieldTotPbPb2760GeVA_0010 = CombinePtPointsSpectraFullCorrMat( statErrorCollectionLHC11h_0010, sysErrorCollectionforRatiosLHC11h_0010,
xPtLimitsEta, 13, offSetsEta, offSetsEtaSys,
graphCombInvYieldStatPbPb2760GeVA_0010, graphCombInvYieldSysPbPb2760GeVA_0010,
fileNameOutputWeightingALHC11h_0010);
graphCombInvYieldTotPbPb2760GeVA_2050 = CombinePtPointsSpectraFullCorrMat( statErrorCollectionLHC11h_2050, sysErrorCollectionforRatiosLHC11h_2050,
xPtLimitsEta, 13, offSetsEta, offSetsEtaSys,
graphCombInvYieldStatPbPb2760GeVA_2050, graphCombInvYieldSysPbPb2760GeVA_2050,
fileNameOutputWeightingALHC11h_2050);
while(graphCombInvYieldTotPbPb2760GeVA_0010->GetY()[0] < 1e-14){
graphCombInvYieldTotPbPb2760GeVA_0010->RemovePoint(0);
graphCombInvYieldTotPbPb2760GeVA_2050->RemovePoint(0);
graphCombInvYieldStatPbPb2760GeVA_0010->RemovePoint(0);
graphCombInvYieldStatPbPb2760GeVA_2050->RemovePoint(0);
graphCombInvYieldSysPbPb2760GeVA_0010->RemovePoint(0);
graphCombInvYieldSysPbPb2760GeVA_2050->RemovePoint(0);
}
// graphCombInvYieldTotPbPb2760GeVA_0010->Print();
// graphCombInvYieldTotPbPb2760GeVA_2050->Print();
// return;
}
// Reading weights from output file for plotting
ifstream fileWeightsReadALHC11h_0010;
fileWeightsReadALHC11h_0010.open(fileNameOutputWeightingALHC11h_0010,ios_base::in);
ifstream fileWeightsReadALHC11h_2050;
fileWeightsReadALHC11h_2050.open(fileNameOutputWeightingALHC11h_2050,ios_base::in);
cout << "reading " << fileNameOutputWeightingALHC11h_0010 << " and " << fileNameOutputWeightingALHC11h_2050 << endl;
Double_t xValuesReadALHC11h_0010[50];
Double_t weightsReadALHC11h_0010[11][50];
Int_t availableMeasALHC11h_0010[11] = {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1};
Double_t xValuesReadALHC11h_2050[50];
Double_t weightsReadALHC11h_2050[11][50];
Int_t availableMeasALHC11h_2050[11] = {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1};
Int_t nMeasSetALHC11h0010;
Int_t nMeasSetALHC11h2050 = 2;
if(meson.CompareTo("Eta")==0) nMeasSetALHC11h0010 = 2;
else nMeasSetALHC11h0010 = 3;
Int_t nPtBinsReadALHC11h = 0;
while(!fileWeightsReadALHC11h_0010.eof() && nPtBinsReadALHC11h < 50){
TString garbage = "";
if (nPtBinsReadALHC11h == 0){
fileWeightsReadALHC11h_0010 >> garbage ;//>> availableMeas[0] >> availableMeas[1] >> availableMeas[2] >> availableMeas[3];
fileWeightsReadALHC11h_2050 >> garbage ;//>> availableMeas[0] >> availableMeas[1] >> availableMeas[2] >> availableMeas[3];
for (Int_t i = 0; i < nMeasSetALHC11h0010; i++){
fileWeightsReadALHC11h_0010 >> availableMeasALHC11h_0010[i] ;
}
for (Int_t i = 0; i < nMeasSetALHC11h2050; i++){
fileWeightsReadALHC11h_2050 >> availableMeasALHC11h_2050[i] ;
}
cout << "read following measurements: ";
for (Int_t i = 0; i < 11; i++){
cout << availableMeasALHC11h_0010[i] << "\t" ;
cout << availableMeasALHC11h_2050[i] << "\t" ;
}
cout << endl;
} else {
fileWeightsReadALHC11h_0010 >> xValuesReadALHC11h_0010[nPtBinsReadALHC11h-1];
fileWeightsReadALHC11h_2050 >> xValuesReadALHC11h_2050[nPtBinsReadALHC11h-1];
for (Int_t i = 0; i < nMeasSetALHC11h0010; i++){
fileWeightsReadALHC11h_0010 >> weightsReadALHC11h_0010[availableMeasALHC11h_0010[i]][nPtBinsReadALHC11h-1] ;
}
for (Int_t i = 0; i < nMeasSetALHC11h2050; i++){