@@ -154,6 +154,16 @@ static const std::unordered_map<DecayChannelResonant, const std::array<int, 2>>
154154 {DecayChannelResonant::XicToPPhi, {+PDG_t::kProton , +o2::constants::physics::Pdg::kPhi }},
155155};
156156
157+ // cd+
158+
159+ static const std::unordered_map<DecayChannelMain, const std::vector<int >> daughtersCDeuteronMain{
160+ {DecayChannelMain::CDeuteronToDeKPi, {+o2::constants::physics::Pdg::kDeuteron , +PDG_t::kKMinus , +PDG_t::kPiPlus }}};
161+
162+ // / resonances in c-deuteron decay are not stored in the particle stack for c-deuteron, but tagged with specific status codes
163+ static constexpr int StatusCodeCDeuteronToDeKstar0{95 };
164+ static constexpr int StatusCodeCDeuteronToNeDeltaplusK{96 };
165+ static constexpr int StatusCodeCDeuteronToNeL1520Pi{97 };
166+
157167// / Returns a map of the possible final states for a specific 3-prong particle specie
158168// / \param pdgMother PDG code of the mother particle
159169// / \return a map of final states with their corresponding PDG codes
@@ -170,6 +180,8 @@ inline std::unordered_map<DecayChannelMain, const std::vector<int>> getDecayChan
170180 return daughtersLcMain;
171181 case o2::constants::physics::Pdg::kXiCPlus :
172182 return daughtersXicMain;
183+ case o2::constants::physics::Pdg::kCDeuteron :
184+ return daughtersCDeuteronMain;
173185 default :
174186 LOG (fatal) << " Unknown PDG code for 3-prong final states: " << pdgMother;
175187 return {};
@@ -317,6 +329,27 @@ inline void flipPdgSign(const int pdgMother, const int pdgToFlip, std::array<int
317329 }
318330 }
319331}
332+ // / Get resonant channel for c-deuteron
333+ // / resonances are not stored in the particle stack for c-deuteron, but tagged with specific status codes
334+ // / \tparam particle is the c-deuteron
335+ // / \param pdgMother PDG code of the mother particle
336+ // / \param pdgToFlip PDG code to be flipped
337+ // / \param arrPdg array of PDG codes to be modified
338+ template <typename Part>
339+ inline int getResonantDecayCDeuteron (Part const & particle)
340+ {
341+ auto statusCode = std::abs (particle.getGenStatusCode ());
342+ if (statusCode == o2::hf_decay::hf_cand_3prong::StatusCodeCDeuteronToDeKstar0) {
343+ return o2::hf_decay::hf_cand_3prong::DecayChannelResonant::CDeuteronToDeKstar0;
344+ }
345+ if (statusCode == o2::hf_decay::hf_cand_3prong::StatusCodeCDeuteronToNeDeltaplusK) {
346+ return o2::hf_decay::hf_cand_3prong::DecayChannelResonant::CDeuteronToNeDeltaplusK;
347+ }
348+ if (statusCode == o2::hf_decay::hf_cand_3prong::StatusCodeCDeuteronToNeL1520Pi) {
349+ return o2::hf_decay::hf_cand_3prong::DecayChannelResonant::CDeuteronToNeL1520Pi;
350+ }
351+ return 0 ;
352+ }
320353} // namespace o2::hf_decay
321354
322355#endif // PWGHF_UTILS_UTILSMCMATCHING_H_
0 commit comments