Skip to content

Commit ba02103

Browse files
[PWGHF] Acceptance cut on D+ daughters (#13748)
Co-authored-by: ALICE Action Bot <alibuild@cern.ch>
1 parent 636a66d commit ba02103

File tree

1 file changed

+20
-5
lines changed

1 file changed

+20
-5
lines changed

PWGHF/HFC/TableProducer/correlatorDplusHadrons.cxx

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,7 @@ struct HfCorrelatorDplusHadrons {
182182
Produces<aod::Dplus> entryDplus;
183183
Produces<aod::Hadron> entryHadron;
184184
static constexpr std::size_t NDaughters{3u};
185+
static constexpr float kEtaDaughtersMax = 0.8f; // Eta cut on daughters of D+ meson as Run2
185186

186187
Configurable<int> selectionFlagDplus{"selectionFlagDplus", 7, "Selection Flag for Dplus"}; // 7 corresponds to topo+PID cuts
187188
Configurable<int> numberEventsMixed{"numberEventsMixed", 5, "Number of events mixed in ME process"};
@@ -432,6 +433,13 @@ struct HfCorrelatorDplusHadrons {
432433
if (std::abs(HfHelper::yDplus(candidate)) >= yCandMax || candidate.pt() <= ptCandMin || candidate.pt() >= ptCandMax) {
433434
continue;
434435
}
436+
// Remove D+ candidates for which at least one daughter has |eta| > 0.8
437+
double etaDaugh1 = RecoDecay::eta(std::array{candidate.pxProng0(), candidate.pyProng0(), candidate.pzProng0()});
438+
double etaDaugh2 = RecoDecay::eta(std::array{candidate.pxProng1(), candidate.pyProng1(), candidate.pzProng1()});
439+
double etaDaugh3 = RecoDecay::eta(std::array{candidate.pxProng2(), candidate.pyProng2(), candidate.pzProng2()});
440+
if (std::abs(etaDaugh1) >= kEtaDaughtersMax || std::abs(etaDaugh2) >= kEtaDaughtersMax || std::abs(etaDaugh3) >= kEtaDaughtersMax) {
441+
continue;
442+
}
435443
// efficiency weight determination
436444
int const effBinD = o2::analysis::findBin(binsPtEfficiencyD, candidate.pt());
437445
double efficiencyWeightD = 1.;
@@ -577,13 +585,20 @@ struct HfCorrelatorDplusHadrons {
577585
listDaughters.clear();
578586
RecoDecay::getDaughters(particle1, &listDaughters, arrDaughDplusPDG, 2);
579587
int counterDaughters = 0;
580-
if (listDaughters.size() == NDaughters) {
581-
for (const auto& dauIdx : listDaughters) {
582-
auto daughI = mcParticles.rawIteratorAt(dauIdx - mcParticles.offset());
583-
counterDaughters += 1;
584-
prongsId[counterDaughters - 1] = daughI.globalIndex();
588+
if (listDaughters.size() != NDaughters)
589+
continue;
590+
bool isDaughtersOk = true;
591+
for (const auto& dauIdx : listDaughters) {
592+
auto daughI = mcParticles.rawIteratorAt(dauIdx - mcParticles.offset());
593+
if (std::abs(daughI.eta()) >= kEtaDaughtersMax) {
594+
isDaughtersOk = false;
595+
break;
585596
}
597+
counterDaughters += 1;
598+
prongsId[counterDaughters - 1] = daughI.globalIndex();
586599
}
600+
if (!isDaughtersOk)
601+
continue; // Skip this D+ candidate if any daughter fails eta cut
587602
counterDplusHadron++;
588603
// Dplus Hadron correlation dedicated section
589604
// if it's a Dplus particle, search for Hadron and evaluate correlations

0 commit comments

Comments
 (0)