Bug Description
A user posted this bug in the forum with a nice MWE. The source of the problem is that when photons generate electrons, the electron collision event producing secondary Bremsstrahlung photons is NUCLIDE_NONE resulting in an invalid nuclide pointer when setting the nuclide_id for the collision event.
|
const auto* nuclide_ptr = data::nuclides[particle.event_nuclide()].get(); |
|
std::string nuclide = nuclide_ptr->name_; |
Steps to Reproduce
Forum link with MWE: https://openmc.discourse.group/t/issues-when-using-collision-track-with-photon-transport-enabled/6331
Environment
Nuclear data ENDF/B VIII.0 (but shouldn't matter much what dataset is used)
Bug Description
A user posted this bug in the forum with a nice MWE. The source of the problem is that when photons generate electrons, the electron collision event producing secondary Bremsstrahlung photons is
NUCLIDE_NONEresulting in an invalid nuclide pointer when setting thenuclide_idfor the collision event.openmc/src/collision_track.cpp
Lines 203 to 204 in b3788f1
Steps to Reproduce
Forum link with MWE: https://openmc.discourse.group/t/issues-when-using-collision-track-with-photon-transport-enabled/6331
Environment
Nuclear data ENDF/B VIII.0 (but shouldn't matter much what dataset is used)