Skip to content

Commit

Permalink
PWGHF: Ds-h correlations secondary particles (AliceO2Group#5457)
Browse files Browse the repository at this point in the history
* Added secondary particles histograms and multiplicity MC in eff

* clang-format

* Post processing macros minor error adjustment
  • Loading branch information
scattaru authored Apr 3, 2024
1 parent 4af0469 commit 52b4f40
Show file tree
Hide file tree
Showing 4 changed files with 167 additions and 115 deletions.
20 changes: 11 additions & 9 deletions PWGHF/HFC/DataModel/CorrelationTables.h
Original file line number Diff line number Diff line change
Expand Up @@ -118,14 +118,15 @@ DECLARE_SOA_TABLE(LcHadronRecoInfo, "AOD", "LCHRECOINFO", //! Lc-Hadrons pairs R
// definition of columns and tables for Ds-Hadron correlation pairs
namespace hf_correlation_ds_hadron
{
DECLARE_SOA_COLUMN(DeltaPhi, deltaPhi, float); //! DeltaPhi between Ds and Hadrons
DECLARE_SOA_COLUMN(DeltaEta, deltaEta, float); //! DeltaEta between Ds and Hadrons
DECLARE_SOA_COLUMN(PtD, ptD, float); //! Transverse momentum of Ds
DECLARE_SOA_COLUMN(PtHadron, ptHadron, float); //! Transverse momentum of Hadron
DECLARE_SOA_COLUMN(MD, mD, float); //! Invariant mass of Ds
DECLARE_SOA_COLUMN(PoolBin, poolBin, int); //! Pool Bin for the MixedEvent
DECLARE_SOA_COLUMN(IsSignal, isSignal, bool); //! Used in MC-Rec, Ds Signal
DECLARE_SOA_COLUMN(IsPrompt, isPrompt, bool); //! Used in MC-Rec, Ds Prompt or Non-Prompt
DECLARE_SOA_COLUMN(DeltaPhi, deltaPhi, float); //! DeltaPhi between Ds and Hadrons
DECLARE_SOA_COLUMN(DeltaEta, deltaEta, float); //! DeltaEta between Ds and Hadrons
DECLARE_SOA_COLUMN(PtD, ptD, float); //! Transverse momentum of Ds
DECLARE_SOA_COLUMN(PtHadron, ptHadron, float); //! Transverse momentum of Hadron
DECLARE_SOA_COLUMN(MD, mD, float); //! Invariant mass of Ds
DECLARE_SOA_COLUMN(PoolBin, poolBin, int); //! Pool Bin for the MixedEvent
DECLARE_SOA_COLUMN(IsSignal, isSignal, bool); //! Used in MC-Rec, Ds Signal
DECLARE_SOA_COLUMN(IsPrompt, isPrompt, bool); //! Used in MC-Rec, Ds Prompt or Non-Prompt
DECLARE_SOA_COLUMN(IsPhysicalPrimary, isPhysicalPrimary, bool); //! Used in MC-Rec, primary associated particles
} // namespace hf_correlation_ds_hadron

DECLARE_SOA_TABLE(DsHadronPair, "AOD", "DSHPAIR", //! Ds-Hadrons pairs Informations
Expand All @@ -140,7 +141,8 @@ DECLARE_SOA_TABLE(DsHadronRecoInfo, "AOD", "DSHRECOINFO", //! Ds-Hadrons pairs R
aod::hf_correlation_ds_hadron::IsSignal);

DECLARE_SOA_TABLE(DsHadronGenInfo, "AOD", "DSHGENINFO", //! Ds-Hadrons pairs Generated Informations
aod::hf_correlation_ds_hadron::IsPrompt);
aod::hf_correlation_ds_hadron::IsPrompt,
aod::hf_correlation_ds_hadron::IsPhysicalPrimary);

// definition of columns and tables for Dplus properties
namespace hf_dplus_meson
Expand Down
13 changes: 8 additions & 5 deletions PWGHF/HFC/Macros/DhCorrelationExtraction.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -485,14 +485,17 @@ void DhCorrelationExtraction::NormalizeMEplot(TH2D*& histoME, TH2D*& histoMEsoft

// evaluate the normalization (from ALL tracks, including possible fake softpions) -> **histoME indeed includes bin1+bin2 of THnSparse, i.e. all the tracks**
Double_t factorNorm = 0;
for (int in = -1; in <= 0; in++)
factorNorm += histoME->GetBinContent(bin0phi + in, bin0eta);
for (int in = -1; in <= 0; in++)
factorNorm += histoME->GetBinContent(bin0phi + in, bin0eta - 1);
for (int in = -1; in <= 0; in++) {
factorNorm += histoME->GetBinContent(bin0eta, bin0phi + in);
}
for (int in = -1; in <= 0; in++) {
factorNorm += histoME->GetBinContent(bin0eta - 1, bin0phi + in);
}
factorNorm /= 4.;

if (fSubtractSoftPiME)
if (fSubtractSoftPiME) {
histoME->Add(histoMEsoftPi, -1); // remove the tracks compatible with soft pion (if requested)
}

// apply the normalization
histoME->Scale(1. / factorNorm);
Expand Down
Loading

0 comments on commit 52b4f40

Please sign in to comment.