Skip to content

Commit a4323d8

Browse files
hero-seoJaeYoonCHO
andauthored
[PWGHF] Add histograms and mass column for Xicp analysis (#18254)
Co-authored-by: JaeYoonCHO <jaeyoon.cho@cern.ch>
1 parent 72def59 commit a4323d8

4 files changed

Lines changed: 18 additions & 4 deletions

File tree

‎PWGHF/DataModel/CandidateReconstructionTables.h‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1529,6 +1529,7 @@ DECLARE_SOA_COLUMN(NSigTofPiFromLambda, nSigTofPiFromLambda, float);
15291529
DECLARE_SOA_COLUMN(NSigTofPrFromLambda, nSigTofPrFromLambda, float);
15301530
// MC
15311531
DECLARE_SOA_COLUMN(DecayLengthMcGen, decayLengthMcGen, float);
1532+
DECLARE_SOA_COLUMN(MassMcGen, massMcGen, float);
15321533
// Residuals and pulls
15331534
DECLARE_SOA_COLUMN(PtResidual, ptResidual, float);
15341535
DECLARE_SOA_COLUMN(PResidual, pResidual, float);
@@ -1634,7 +1635,8 @@ DECLARE_SOA_TABLE(HfCandXicMcGen, "AOD", "HFCANDXICMCGEN",
16341635
hf_cand_mc_flag::FlagMcMatchGen,
16351636
hf_cand_mc_flag::OriginMcGen,
16361637
hf_cand_mc_flag::PdgBhadMotherPart,
1637-
hf_cand_xic_to_xi_pi_pi::DecayLengthMcGen);
1638+
hf_cand_xic_to_xi_pi_pi::DecayLengthMcGen,
1639+
hf_cand_xic_to_xi_pi_pi::MassMcGen);
16381640

16391641
// table with residuals and pulls of PV
16401642
DECLARE_SOA_TABLE(HfCandXicResid, "AOD", "HFCANDXICRESID",

‎PWGHF/TableProducer/candidateCreatorXicToXiPiPi.cxx‎

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1093,6 +1093,7 @@ struct HfCandidateCreatorXicToXiPiPiExpressions {
10931093
registry.add("hDecayedPions", "hDecayedPions", {HistType::kTH1F, {{5, -0.5, 4.5}}});
10941094
registry.add("hInteractionsWithMaterial", "hInteractionsWithMaterial", {HistType::kTH1F, {{6, -0.5, 5.5}}});
10951095
registry.add("hDebugRec", "hDebugRec", {HistType::kTH1F, {{4, -0.5, 3.5}}});
1096+
registry.add("hy_pt_gen", "Generated MC", {HistType::kTH2F, {{20, -1.0, 1.0}, {200, 0, 20}}});
10961097
registry.get<TH1>(HIST("hDebugRec"))->GetXaxis()->SetBinLabel(1 + TotalRec, "total");
10971098
registry.get<TH1>(HIST("hDebugRec"))->GetXaxis()->SetBinLabel(1 + XicToFinalState, "#Xi^{+}_{c} #rightarrow #pi^{#plus} #pi^{#plus} #pi^{#minus} p #pi^{#minus}");
10981099
registry.get<TH1>(HIST("hDebugRec"))->GetXaxis()->SetBinLabel(1 + XiToPiPPi, "#Xi^{#minus} #rightarrow #pi^{#minus} p #pi^{#minus}");
@@ -1300,12 +1301,13 @@ struct HfCandidateCreatorXicToXiPiPiExpressions {
13001301
if (rejectionMask != 0) {
13011302
// at least one event selection not satisfied --> reject all particles from this collision
13021303
for (unsigned int i = 0; i < mcParticlesPerMcColl.size(); ++i) {
1303-
rowMcMatchGen(-99, -99, -99, decayLengthGen);
1304+
rowMcMatchGen(-99, -99, -99, decayLengthGen, -1.f);
13041305
}
13051306
continue;
13061307
}
13071308

13081309
for (const auto& particle : mcParticlesPerMcColl) {
1310+
const float massGen = RecoDecay::m(particle.pVector(), particle.e());
13091311
sign = 0;
13101312
flag = 0;
13111313
origin = RecoDecay::OriginType::None;
@@ -1345,6 +1347,9 @@ struct HfCandidateCreatorXicToXiPiPiExpressions {
13451347

13461348
// Check whether the charm baryon is non-prompt (from a b quark).
13471349
if (flag != 0) {
1350+
// fill inclusive generated Xic+
1351+
registry.fill(HIST("hy_pt_gen"), particle.y(), particle.pt());
1352+
13481353
origin = RecoDecay::getCharmHadronOrigin(mcParticles, particle, false, &idxBhadMothers);
13491354
// Calculate the decay length of the generated particle
13501355
auto dau0 = particle.template daughters_as<aod::McParticles>().begin();
@@ -1355,9 +1360,9 @@ struct HfCandidateCreatorXicToXiPiPiExpressions {
13551360
// Fill table
13561361
if (origin == RecoDecay::OriginType::NonPrompt) {
13571362
auto bHadMother = mcParticles.rawIteratorAt(idxBhadMothers[0]);
1358-
rowMcMatchGen(flag, origin, bHadMother.pdgCode(), decayLengthGen);
1363+
rowMcMatchGen(flag, origin, bHadMother.pdgCode(), decayLengthGen, massGen);
13591364
} else {
1360-
rowMcMatchGen(flag, origin, 0, decayLengthGen);
1365+
rowMcMatchGen(flag, origin, 0, decayLengthGen, massGen);
13611366
}
13621367
} // close loop over generated particles
13631368
} // close loop over McCollisions

‎PWGHF/TableProducer/candidateSelectorXicToXiPiPi.cxx‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,8 @@ struct HfCandidateSelectorXicToXiPiPi {
245245
registry.add("hNCrossedRowsTpcBachelorPionRecBkg", "Reconstructed background;#it{N}_{rows}^{TPC} (#pi #leftarrow #Xi);entries", {HistType::kTH1F, {{103, 49.5, 152.5}}});
246246
registry.add("hNCrossedRowsTpcV0PosDauRecBkg", "Reconstructed background;#it{N}_{rows}^{TPC} (V0 pos. dau.);entries", {HistType::kTH1F, {{103, 49.5, 152.5}}});
247247
registry.add("hNCrossedRowsTpcV0NegDauRecBkg", "Reconstructed background;#it{N}_{rows}^{TPC} (V0 neg. dau.);entries", {HistType::kTH1F, {{103, 49.5, 152.5}}});
248+
/// reconstructed MC
249+
registry.add("hmass_pt_reco_truth", "Reconstructed truth matching MC;inv.mass(#Xi#pi#pi) [GeV/c^{2}];p_{T} [GeV/c]", {HistType::kTH2F, {{40, 2.3, 2.7}, {200, 0, 20}}});
248250
}
249251
}
250252

@@ -641,6 +643,7 @@ struct HfCandidateSelectorXicToXiPiPi {
641643
if constexpr (IsMc) {
642644
if (isMatchedSignal) {
643645
registry.fill(HIST("hSelCandidatesRecSig"), PidSelected);
646+
registry.fill(HIST("hmass_pt_reco_truth"), hfCandXic.invMassXicPlus(), hfCandXic.pt());
644647
} else {
645648
registry.fill(HIST("hSelCandidatesRecBkg"), PidSelected);
646649
}

‎PWGHF/TableProducer/treeCreatorXicToXiPiPi.cxx‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -374,6 +374,7 @@ DECLARE_SOA_TABLE(HfCandXicToXiPiPiFullPs, "AOD", "HFXICXI2PIFULLP",
374374
hf_cand_mc_flag::OriginMcGen,
375375
hf_cand_mc_flag::PdgBhadMotherPart,
376376
full::Pt,
377+
full::M,
377378
full::Eta,
378379
full::Phi,
379380
full::Y,
@@ -895,6 +896,7 @@ struct HfTreeCreatorXicToXiPiPi {
895896
particle.originMcGen(),
896897
particle.pdgBhadMotherPart(),
897898
particle.pt(),
899+
particle.massMcGen(),
898900
particle.eta(),
899901
particle.phi(),
900902
RecoDecay::y(particle.pVector(), o2::constants::physics::MassXiCPlus),
@@ -967,6 +969,7 @@ struct HfTreeCreatorXicToXiPiPi {
967969
particle.originMcGen(),
968970
particle.pdgBhadMotherPart(),
969971
particle.pt(),
972+
particle.massMcGen(),
970973
particle.eta(),
971974
particle.phi(),
972975
RecoDecay::y(particle.pVector(), o2::constants::physics::MassXiCPlus),
@@ -1032,6 +1035,7 @@ struct HfTreeCreatorXicToXiPiPi {
10321035
particle.originMcGen(),
10331036
particle.pdgBhadMotherPart(),
10341037
particle.pt(),
1038+
particle.massMcGen(),
10351039
particle.eta(),
10361040
particle.phi(),
10371041
RecoDecay::y(particle.pVector(), o2::constants::physics::MassXiCPlus),

0 commit comments

Comments
 (0)