Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions DataFormats/Reconstruction/src/Decay3Body.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,14 @@ using namespace o2::dataformats;
Decay3Body::Decay3Body(const std::array<float, 3>& xyz, const std::array<float, 3>& pxyz, const std::array<float, 6>& covxyz, const Track& tr0, const Track& tr1, const Track& tr2, o2::track::PID pid)
: mProngs{tr0, tr1, tr2}
{
std::array<float, 21> cov{}, cov1{}, cov2{};
tr0.getCovXYZPxPyPzGlo(cov);
std::array<float, 21> cov{}, cov0{}, cov1{}, cov2{};
tr0.getCovXYZPxPyPzGlo(cov0);
tr1.getCovXYZPxPyPzGlo(cov1);
tr2.getCovXYZPxPyPzGlo(cov2);
for (int i = 0; i < 21; i++) {
cov[i] += cov1[i] + cov2[i];
}
constexpr int MomInd[6] = {9, 13, 14, 18, 19, 20}; // cov matrix elements for momentum component
for (int i = 0; i < 6; i++) {
cov[i] = covxyz[i];
cov[MomInd[i]] = cov0[MomInd[i]] + cov1[MomInd[i]] + cov2[MomInd[i]];
}
this->set(xyz, pxyz, cov, tr0.getCharge() + tr1.getCharge() + tr2.getCharge(), true, pid);
}
Expand Down