Skip to content

Commit 18d2156

Browse files
authored
PWGEM/PhotonMeson: update for q vector and reorganize to include headers (AliceO2Group#5647)
1 parent 4e97659 commit 18d2156

11 files changed

+454
-202
lines changed

PWGEM/PhotonMeson/Core/HistogramsLibrary.cxx

+82-5
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,47 @@ void o2::aod::pwgem::photon::histogram::DefineHistograms(THashList* list, const
5656
list->Add(new TH1F("hCentFT0M", "hCentFT0M;centrality FT0M (%)", 110, 0, 110));
5757
list->Add(new TH2F("hCentFT0MvsMultNTracksPV", "hCentFT0MvsMultNTracksPV;centrality FT0M (%);N_{track} to PV", 110, 0, 110, 600, 0, 6000));
5858
list->Add(new TH2F("hMultFT0MvsMultNTracksPV", "hMultFT0MvsMultNTracksPV;mult. FT0M;N_{track} to PV", 600, 0, 6000, 600, 0, 6000));
59+
60+
if (TString(subGroup).Contains("qvector")) {
61+
// q vector
62+
list->Add(new TH2F("hQ2xFT0M_CentFT0C", "hQ2xFT0M_CentFT0C;centrality FT0C (%);Q_{2,x}^{FT0M}", 110, 0, 110, 200, -10, +10));
63+
list->Add(new TH2F("hQ2yFT0M_CentFT0C", "hQ2yFT0M_CentFT0C;centrality FT0C (%);Q_{2,y}^{FT0M}", 110, 0, 110, 200, -10, +10));
64+
list->Add(new TH2F("hQ2xFT0A_CentFT0C", "hQ2xFT0A_CentFT0C;centrality FT0C (%);Q_{2,x}^{FT0A}", 110, 0, 110, 200, -10, +10));
65+
list->Add(new TH2F("hQ2yFT0A_CentFT0C", "hQ2yFT0A_CentFT0C;centrality FT0C (%);Q_{2,y}^{FT0A}", 110, 0, 110, 200, -10, +10));
66+
list->Add(new TH2F("hQ2xFT0C_CentFT0C", "hQ2xFT0C_CentFT0C;centrality FT0C (%);Q_{2,x}^{FT0C}", 110, 0, 110, 200, -10, +10));
67+
list->Add(new TH2F("hQ2yFT0C_CentFT0C", "hQ2yFT0C_CentFT0C;centrality FT0C (%);Q_{2,y}^{FT0C}", 110, 0, 110, 200, -10, +10));
68+
list->Add(new TH2F("hQ2xFV0A_CentFT0C", "hQ2xFV0A_CentFT0C;centrality FT0C (%);Q_{2,x}^{FV0A}", 110, 0, 110, 200, -10, +10));
69+
list->Add(new TH2F("hQ2yFV0A_CentFT0C", "hQ2yFV0A_CentFT0C;centrality FT0C (%);Q_{2,y}^{FV0A}", 110, 0, 110, 200, -10, +10));
70+
list->Add(new TH2F("hQ2xBPos_CentFT0C", "hQ2xBPos_CentFT0C;centrality FT0C (%);Q_{2,x}^{BPos}", 110, 0, 110, 200, -10, +10));
71+
list->Add(new TH2F("hQ2yBPos_CentFT0C", "hQ2yBPos_CentFT0C;centrality FT0C (%);Q_{2,y}^{BPos}", 110, 0, 110, 200, -10, +10));
72+
list->Add(new TH2F("hQ2xBNeg_CentFT0C", "hQ2xBNeg_CentFT0C;centrality FT0C (%);Q_{2,x}^{BNeg}", 110, 0, 110, 200, -10, +10));
73+
list->Add(new TH2F("hQ2yBNeg_CentFT0C", "hQ2yBNeg_CentFT0C;centrality FT0C (%);Q_{2,y}^{BNeg}", 110, 0, 110, 200, -10, +10));
74+
75+
// event plane
76+
list->Add(new TH2F("hEP2FT0M_CentFT0C", "2nd harmonics event plane FT0M;centrality FT0C (%);#Psi_{2}^{FT0M} (rad.)", 110, 0, 110, 180, -M_PI_2, +M_PI_2));
77+
list->Add(new TH2F("hEP2FT0A_CentFT0C", "2nd harmonics event plane FT0A;centrality FT0C (%);#Psi_{2}^{FT0A} (rad.)", 110, 0, 110, 180, -M_PI_2, +M_PI_2));
78+
list->Add(new TH2F("hEP2FT0C_CentFT0C", "2nd harmonics event plane FT0C;centrality FT0C (%);#Psi_{2}^{FT0C} (rad.)", 110, 0, 110, 180, -M_PI_2, +M_PI_2));
79+
list->Add(new TH2F("hEP2FV0A_CentFT0C", "2nd harmonics event plane FV0A;centrality FT0C (%);#Psi_{2}^{FV0A} (rad.)", 110, 0, 110, 180, -M_PI_2, +M_PI_2));
80+
list->Add(new TH2F("hEP2BPos_CentFT0C", "2nd harmonics event plane BPos;centrality FT0C (%);#Psi_{2}^{BPos} (rad.)", 110, 0, 110, 180, -M_PI_2, +M_PI_2));
81+
list->Add(new TH2F("hEP2BNeg_CentFT0C", "2nd harmonics event plane BNeg;centrality FT0C (%);#Psi_{2}^{BNeg} (rad.)", 110, 0, 110, 180, -M_PI_2, +M_PI_2));
82+
83+
// q vector resolution FT0M
84+
list->Add(new TH2F("hQ2FT0MQ2BPos_CentFT0C", "Q_{2}^{FT0M} #upoint Q_{2}^{BPos};centrality FT0C (%);Q_{2}^{FT0M} #upoint Q_{2}^{BPos}", 110, 0, 110, 200, -10, +10));
85+
list->Add(new TH2F("hQ2FT0MQ2BNeg_CentFT0C", "Q_{2}^{FT0M} #upoint Q_{2}^{BNeg};centrality FT0C (%);Q_{2}^{FT0M} #upoint Q_{2}^{BNeg}", 110, 0, 110, 200, -10, +10));
86+
list->Add(new TH2F("hQ2BPosQ2BNeg_CentFT0C", "Q_{2}^{BPos} #upoint Q_{2}^{BNeg};centrality FT0C (%);Q_{2}^{BPos} #upoint Q_{2}^{BNeg}", 110, 0, 110, 200, -10, +10)); // this is common for FT0M, FT0A, FT0C, FV0A resolution.
87+
88+
// q vector resolution FT0C
89+
list->Add(new TH2F("hQ2FT0CQ2BPos_CentFT0C", "Q_{2}^{FT0C} #upoint Q_{2}^{BPos};centrality FT0C (%);Q_{2}^{FT0C} #upoint Q_{2}^{BPos}", 110, 0, 110, 200, -10, +10));
90+
list->Add(new TH2F("hQ2FT0CQ2BNeg_CentFT0C", "Q_{2}^{FT0C} #upoint Q_{2}^{BNeg};centrality FT0C (%);Q_{2}^{FT0C} #upoint Q_{2}^{BNeg}", 110, 0, 110, 200, -10, +10));
91+
92+
// q vector resolution FT0A
93+
list->Add(new TH2F("hQ2FT0AQ2BPos_CentFT0C", "Q_{2}^{FT0A} #upoint Q_{2}^{BPos};centrality FT0C (%);Q_{2}^{FT0A} #upoint Q_{2}^{BPos}", 110, 0, 110, 200, -10, +10));
94+
list->Add(new TH2F("hQ2FT0AQ2BNeg_CentFT0C", "Q_{2}^{FT0A} #upoint Q_{2}^{BNeg};centrality FT0C (%);Q_{2}^{FT0A} #upoint Q_{2}^{BNeg}", 110, 0, 110, 200, -10, +10));
95+
96+
// q vector resolution FV0A
97+
list->Add(new TH2F("hQ2FV0AQ2BPos_CentFT0C", "Q_{2}^{FV0A} #upoint Q_{2}^{BPos};centrality FT0C (%);Q_{2}^{FV0A} #upoint Q_{2}^{BPos}", 110, 0, 110, 200, -10, +10));
98+
list->Add(new TH2F("hQ2FV0AQ2BNeg_CentFT0C", "Q_{2}^{FV0A} #upoint Q_{2}^{BNeg};centrality FT0C (%);Q_{2}^{FV0A} #upoint Q_{2}^{BNeg}", 110, 0, 110, 200, -10, +10));
99+
}
59100
}
60101
if (TString(histClass) == "V0Leg") {
61102
list->Add(new TH1F("hPt", "pT;p_{T} (GeV/c)", 1000, 0.0f, 10));
@@ -387,9 +428,24 @@ void o2::aod::pwgem::photon::histogram::DefineHistograms(THashList* list, const
387428
}
388429

389430
if (TString(histClass) == "singlephoton") {
390-
list->Add(new TH1F("hPt", "pT of photon candidates;p_{T} (GeV/c)", 2000, 0.0f, 20));
431+
if (TString(subGroup).Contains("qvector")) {
432+
list->Add(new TH2F("hPt_SPQ2FT0M", "p_{T,#gamma} vs. SP;p_{T,#gamma} (GeV/c);u_{2}^{#gamma} #upoint Q_{2}^{FT0M}", 400, 0.0f, 20, 200, -10, +10));
433+
list->Add(new TH2F("hPt_SPQ2FT0A", "p_{T,#gamma} vs. SP;p_{T,#gamma} (GeV/c);u_{2}^{#gamma} #upoint Q_{2}^{FT0A}", 400, 0.0f, 20, 200, -10, +10));
434+
list->Add(new TH2F("hPt_SPQ2FT0C", "p_{T,#gamma} vs. SP;p_{T,#gamma} (GeV/c);u_{2}^{#gamma} #upoint Q_{2}^{FT0C}", 400, 0.0f, 20, 200, -10, +10));
435+
list->Add(new TH2F("hPt_SPQ2FV0A", "p_{T,#gamma} vs. SP;p_{T,#gamma} (GeV/c);u_{2}^{#gamma} #upoint Q_{2}^{FV0A}", 400, 0.0f, 20, 200, -10, +10));
436+
reinterpret_cast<TH2F*>(list->FindObject("hPt_SPQ2FT0M"))->Sumw2();
437+
reinterpret_cast<TH2F*>(list->FindObject("hPt_SPQ2FT0A"))->Sumw2();
438+
reinterpret_cast<TH2F*>(list->FindObject("hPt_SPQ2FT0C"))->Sumw2();
439+
reinterpret_cast<TH2F*>(list->FindObject("hPt_SPQ2FV0A"))->Sumw2();
440+
} else {
441+
list->Add(new TH1F("hPt", "pT of photon candidates;p_{T,#gamma} (GeV/c)", 400, 0.0f, 20));
442+
reinterpret_cast<TH1F*>(list->FindObject("hPt"))->Sumw2();
443+
}
391444
list->Add(new TH1F("hY", "rapidity of photon candidates;y", 40, -2.0f, 2.0f));
392445
list->Add(new TH1F("hPhi", "azimuthal angle of photon candidates;#varphi (rad.)", 180, 0, 2 * M_PI));
446+
reinterpret_cast<TH1F*>(list->FindObject("hY"))->Sumw2();
447+
reinterpret_cast<TH1F*>(list->FindObject("hPhi"))->Sumw2();
448+
393449
if (TString(subGroup) == "mc") {
394450
list->Add(new TH1F("hPt_Photon_Primary", "pT;p_{T} (GeV/c)", 2000, 0.0f, 20)); // for MC efficiency
395451
list->Add(new TH1F("hY_Photon_Primary", "rapidity;y", 40, -2.0f, 2.0f)); // for MC efficiency
@@ -420,19 +476,40 @@ void o2::aod::pwgem::photon::histogram::DefineHistograms(THashList* list, const
420476
pTgg[i] = 1.0 * (i - 60) + 10.0; // from 10 to 20 GeV/c, evety 1 GeV/c
421477
}
422478
if (TString(histClass) == "gammagamma_mass_pt") {
423-
list->Add(new TH2F("hMggPt_Same", "m_{#gamma#gamma} vs. p_{T};m_{#gamma#gamma} (GeV/c^{2});p_{T,#gamma#gamma} (GeV/c)", nmgg - 1, mgg, npTgg - 1, pTgg));
479+
480+
if (TString(subGroup).Contains("qvector")) {
481+
const int ndim_sp = 3;
482+
const int nbins_sp[ndim_sp] = {nmgg - 1, npTgg - 1, 200};
483+
const double xmin_sp[ndim_sp] = {0.0, 0.0, -10.f};
484+
const double xmax_sp[ndim_sp] = {0.8, 20.0, +10.f};
485+
486+
THnSparseF* hs_same_tmp = new THnSparseF("hs_same_tmp", "hs_same_tmp;m_{#gamma#gamma} (GeV/c^{2});p_{T,#gamma#gamma} (GeV/c);u_{2}^{#gamma#gamma}#upointQ_{2}^{FT0M};", ndim_sp, nbins_sp, xmin_sp, xmax_sp);
487+
hs_same_tmp->SetBinEdges(0, mgg);
488+
hs_same_tmp->SetBinEdges(1, pTgg);
489+
hs_same_tmp->Sumw2();
490+
std::string_view sp_names[4] = {"FT0M", "FT0A", "FT0C", "FV0A"};
491+
for (int i = 0; i < 4; i++) {
492+
THnSparseF* hs = reinterpret_cast<THnSparseF*>(hs_same_tmp->Clone(Form("hs_Same_SPQ2%s", sp_names[i].data())));
493+
hs->SetTitle(Form("diphoton info %s", sp_names[i].data()));
494+
hs->GetAxis(2)->SetTitle(Form("u_{2}^{#gamma#gamma}#upointQ_{2}^{%s}", sp_names[i].data()));
495+
list->Add(hs);
496+
}
497+
} else {
498+
list->Add(new TH2F("hMggPt_Same", "m_{#gamma#gamma} vs. p_{T};m_{#gamma#gamma} (GeV/c^{2});p_{T,#gamma#gamma} (GeV/c)", nmgg - 1, mgg, npTgg - 1, pTgg));
499+
reinterpret_cast<TH2F*>(list->FindObject("hMggPt_Same"))->Sumw2();
500+
}
501+
424502
list->Add(new TH2F("hMggPt_Mixed", "m_{#gamma#gamma} vs. p_{T};m_{#gamma#gamma} (GeV/c^{2});p_{T,#gamma#gamma} (GeV/c)", nmgg - 1, mgg, npTgg - 1, pTgg));
425-
reinterpret_cast<TH2F*>(list->FindObject("hMggPt_Same"))->Sumw2();
426503
reinterpret_cast<TH2F*>(list->FindObject("hMggPt_Mixed"))->Sumw2();
427504

428-
if (TString(subGroup) == "PCMPHOS" || TString(subGroup) == "PCMEMC") {
505+
if (TString(subGroup).Contains("PCMPHOS") || TString(subGroup).Contains("PCMEMC")) {
429506
list->Add(new TH2F("hdEtadPhi", "#Delta#eta vs. #Delta#varphi;#Delta#varphi (rad.);#Delta#eta", 200, -1, +1, 200, -1, +1));
430507
list->Add(new TH2F("hdEtaPt", "#Delta#eta vs. p_{T}^{leg};p_{T}^{leg} (GeV/c);#Delta#eta", 100, 0, 10, 200, -1, +1));
431508
list->Add(new TH2F("hdPhiPt", "#Delta#varphi vs. p_{T}^{leg};p_{T}^{leg} (GeV/c);#Delta#varphi", 100, 0, 10, 200, -1, +1));
432509
list->Add(new TH2F("hEp_E", "E/p vs. matched E_{cluster};E_{cluster} (GeV);E/p", 100, 0, 10, 200, 0, 2));
433510
}
434511

435-
if (TString(subGroup) == "EMCEMC") {
512+
if (TString(subGroup).Contains("EMCEMC")) {
436513
list->Add(new TH2F("hMggPt_Same_RotatedBkg", "m_{#gamma#gamma} vs. p_{T};m_{#gamma#gamma} (GeV/c^{2});p_{T,#gamma#gamma} (GeV/c)", nmgg - 1, mgg, npTgg - 1, pTgg));
437514
reinterpret_cast<TH2F*>(list->FindObject("hMggPt_Same_RotatedBkg"))->Sumw2();
438515
}

0 commit comments

Comments
 (0)