HomeHEPForge

Fix recently introduced bug in EvtDalitzReso for parent with significant…

Description

Fix recently introduced bug in EvtDalitzReso for parent with significant natural width

Summary:
In !22 (c51a5f79), which was cherry-picked into both D119 and D124, several changes were made to EvtDalitzReso to make the evaluate method const.
The previous code was not const because a data member was modified in a particular case where the parent mass had changed.
Following the changes, the data member was left unmodified and a warning was printed instead.
The warning was never seen in any existing tests. However, the existing tests did not cover the case where the parent particle has a natural width, which implies that the per-event mass of the parent is not constant.

Here we:

  • Add a test for just such a case: eta_c -> K+ K- pi0
  • Modify the code to restore the correct behaviour
  • Make other general improvements to the EvtDalitzReso class:
    • Fix use of references to basic types as function arguments
    • Expand use of const where appropriate
    • Avoid unnecessary sqrts etc.

See also CERN Gitlab !32.

Test Plan:
The introduced test gives identical results when run on d67a94dc (before the bug was introduced) and with this fix, while after the introduction of the bug but before this fix there are clear differences.
The other general improvements result in much faster execution time, despite the fix necessitating additional instantiations of EvtTwoBodyVertex objects that were previously cached.

Reviewers: jback, abudinen, kreps

Reviewed By: jback, abudinen

Subscribers: #evtgen_admins

Tags: #evtgen

Differential Revision: https://phab.hepforge.org/D130

Details

Provenance
tlathamAuthored on Sep 18 2024, 11:33 AM
tlathamPushed on Sep 18 2024, 11:35 AM
Reviewer
jback
Differential Revision
D130: Fix recently introduced bug in EvtDalitzReso for parent with significant natural width
Parents
rEVTGEN268d81f86873: Improvements in EvtId and EvtPDL
Branches
Unknown
Tags
Unknown