Skip to content

Commit e8f4692

Browse files
Update HFFilter.cxx
1 parent 7daaa6d commit e8f4692

File tree

1 file changed

+28
-13
lines changed

1 file changed

+28
-13
lines changed

EventFiltering/PWGHF/HFFilter.cxx

Lines changed: 28 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -814,22 +814,37 @@ struct HfFilter { // Main struct for HF triggers
814814
}
815815
} // end beauty selection
816816

817-
// 2-prong femto
818-
if (!keepEvent[kFemto2P] && enableFemtoChannels->get(0u, 0u) && isD0CharmTagged && track.collisionId() == thisCollId) {
819-
bool isProton = helper.isSelectedTrack4Femto(track, trackParThird, activateQA, hPrDePID[0], hPrDePID[1], kProtonForFemto);
820-
if (isProton) {
821-
float relativeMomentum = helper.computeRelativeMomentum(pVecThird, pVec2Prong, massD0);
822-
if (applyOptimisation) {
823-
optimisationTreeFemto(thisCollId, o2::constants::physics::Pdg::kD0, pt2Prong, scores[0], scores[1], scores[2], relativeMomentum, track.tpcNSigmaPr(), track.tofNSigmaPr(), track.tpcNSigmaDe(), track.tofNSigmaDe());
817+
// 2-prong femto
818+
bool isProtonForCharm2Prong = helper.isSelectedTrack4Femto(track, trackParThird, activateQA, hPrDePID[0], hPrDePID[1], kProtonForFemto);
819+
bool isDeuteronForCharm2Prong = helper.isSelectedTrack4Femto(track, trackParThird, activateQA, hPrDePID[2], hPrDePID[3], kDeuteronForFemto);
820+
821+
if (track.collisionId() == thisCollId) {
822+
if (isProtonForCharm2Prong && !keepEvent[kFemto2P] && enableFemtoChannels->get(0u, 0u) && isD0CharmTagged) {
823+
float relativeMomentum = helper.computeRelativeMomentum(pVecThird, pVec2Prong, massD0);
824+
if (applyOptimisation) {
825+
optimisationTreeFemto(thisCollId, o2::constants::physics::Pdg::kD0, pt2Prong, scores[0], scores[1], scores[2], relativeMomentum, track.tpcNSigmaPr(), track.tofNSigmaPr(), track.tpcNSigmaDe(), track.tofNSigmaDe());
826+
}
827+
if (relativeMomentum < femtoMaxRelativeMomentum) {
828+
keepEvent[kFemto2P] = true;
829+
if (activateQA) {
830+
hCharmProtonKstarDistr[kD0]->Fill(relativeMomentum);
831+
}
832+
}
824833
}
825-
if (relativeMomentum < femtoMaxRelativeMomentum) {
826-
keepEvent[kFemto2P] = true;
827-
if (activateQA) {
828-
hCharmProtonKstarDistr[kD0]->Fill(relativeMomentum);
834+
835+
if (isDeuteronForCharm2Prong && !keepEvent[kFemto2P] && enableFemtoChannels->get(1u, 0u) && isD0CharmTagged) {
836+
float relativeMomentum = helper.computeRelativeMomentum(pVecThird, pVec2Prong, massD0);
837+
if (applyOptimisation) {
838+
optimisationTreeFemto(thisCollId, o2::constants::physics::Pdg::kD0, pt2Prong, scores[0], scores[1], scores[2], relativeMomentum, track.tpcNSigmaPr(), track.tofNSigmaPr(), track.tpcNSigmaDe(), track.tofNSigmaDe());
839+
}
840+
if (relativeMomentum < femtoMaxRelativeMomentum) {
841+
keepEvent[kFemto2P] = true;
842+
if (activateQA) {
843+
hCharmDeuteronKstarDistr[kD0]->Fill(relativeMomentum);
844+
}
829845
}
830846
}
831-
}
832-
} // end femto selection
847+
} // end femto charm 2prong selection
833848

834849
// Beauty with JPsi
835850
if (preselJPsiToMuMu) {

0 commit comments

Comments
 (0)