From 8792db9a96651aeba66c0c829ad2b3ba0df52559 Mon Sep 17 00:00:00 2001 From: Fabrizio Grosa Date: Thu, 11 Jun 2026 23:04:25 +0200 Subject: [PATCH 1/2] Fix normalisation --- PWGHF/Macros/computeFonllPlusPythiaPredictions.C | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PWGHF/Macros/computeFonllPlusPythiaPredictions.C b/PWGHF/Macros/computeFonllPlusPythiaPredictions.C index 605e0a8f446..c0b4a0fca1f 100644 --- a/PWGHF/Macros/computeFonllPlusPythiaPredictions.C +++ b/PWGHF/Macros/computeFonllPlusPythiaPredictions.C @@ -316,12 +316,12 @@ void computeFonllPlusPythiaPredictions(int nDecays, int seed, std::string inFile std::array normCrossSec{}; for (auto iFonll{0}; iFonll < 3; ++iFonll) { - normCrossSec[iFonll] = hFonllBhad[iFonll]->Integral(); + normCrossSec[iFonll] = hFonllBhad[iFonll]->Integral(1, hFonllBhad[iFonll]->GetNbinsX()+1, "width"); for (auto iChad{0}; iChad < NCharmHadrons; ++iChad) { hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][NBeautyHadrons][iFonll] = reinterpret_cast(hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][0][iFonll]->Clone(Form("hFonllNonPrompt%s%s", charmHadNames[iChad].data(), namesFonll[iFonll].data()))); hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][NBeautyHadrons][iFonll]->Reset(); for (auto iBHad{0}; iBHad < NBeautyHadrons; ++iBHad) { - hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][iBHad][iFonll]->Scale(normCrossSec[iFonll] / nDecays); + hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][iBHad][iFonll]->Scale(normCrossSec[iFonll] / nDecays, "width"); hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][NBeautyHadrons][iFonll]->Add(hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][iBHad][iFonll]); } } From 948c0ea8f3455108a4a4bdffaa04210e54cb2ba8 Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Thu, 11 Jun 2026 21:05:52 +0000 Subject: [PATCH 2/2] Please consider the following formatting changes --- PWGHF/Macros/computeFonllPlusPythiaPredictions.C | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGHF/Macros/computeFonllPlusPythiaPredictions.C b/PWGHF/Macros/computeFonllPlusPythiaPredictions.C index c0b4a0fca1f..9d3dab4d407 100644 --- a/PWGHF/Macros/computeFonllPlusPythiaPredictions.C +++ b/PWGHF/Macros/computeFonllPlusPythiaPredictions.C @@ -316,7 +316,7 @@ void computeFonllPlusPythiaPredictions(int nDecays, int seed, std::string inFile std::array normCrossSec{}; for (auto iFonll{0}; iFonll < 3; ++iFonll) { - normCrossSec[iFonll] = hFonllBhad[iFonll]->Integral(1, hFonllBhad[iFonll]->GetNbinsX()+1, "width"); + normCrossSec[iFonll] = hFonllBhad[iFonll]->Integral(1, hFonllBhad[iFonll]->GetNbinsX() + 1, "width"); for (auto iChad{0}; iChad < NCharmHadrons; ++iChad) { hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][NBeautyHadrons][iFonll] = reinterpret_cast(hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][0][iFonll]->Clone(Form("hFonllNonPrompt%s%s", charmHadNames[iChad].data(), namesFonll[iFonll].data()))); hFonllPythiaNonPromptChad[charmHadPdgs[iChad]][NBeautyHadrons][iFonll]->Reset();