Closed LeanderSchlegel closed 6 months ago
Looks good to me. Let's wait for more comments otherwise I will merge in the next days.
Thank you very much for your feedback!
As suggested by Julien and in discussion with him, I added two small tests in testCore,
one extending the test of addSecondary to also check their masses and one new test, covering the new function particleMass(int id)
.
Dear all,
with this PR we try to fix #483. @lukasmerten, @JulienDoerner and me discussed it and introduced a new function particleMass(int id) in ParticleMass.cpp to fix the bug by calling it in setId(int newId) in ParticleState.cpp. It gives all particles other than nuclei or electrons/positrons a zero rest-mass and could possibly be extended for other particles when needed.