23 const ParticleList &search_list,
double dt)
const {
29 for (
const auto &
p : search_list) {
30 if (
p.type().is_stable()) {
34 DecayBranchList processes =
p.type().get_partial_widths(
37 const double width = total_weight<DecayBranch>(processes);
44 constexpr
double one_over_hbarc = 1. /
hbarc;
51 double decay_time = random::exponential<double>(
54 one_over_hbarc *
p.inverse_gamma() * width);
57 if (
p.xsec_scaling_factor() < 1.0) {
58 decay_time +=
p.formation_time() -
p.position().x0();
60 if (decay_time < dt) {
63 auto act = make_unique<DecayAction>(
p, decay_time);
64 act->add_decays(std::move(processes));
65 actions.emplace_back(std::move(act));
75 for (
const auto &
p : search_list) {
76 if (
p.type().is_stable()) {
79 auto act = make_unique<DecayAction>(
p, 0.);
80 act->add_decays(p.type().get_partial_widths(
82 actions.emplace_back(std::move(act));
ActionList find_final_actions(const Particles &search_list, bool only_res=false) const override
Force all resonances to decay at the end of the simulation.
Collection of useful constants that are known at compile time.
constexpr double hbarc
GeV <-> fm conversion factor.
Ignore dilepton decay modes widths.
The Particles class abstracts the storage and manipulation of particles.
ActionList find_actions_in_cell(const ParticleList &search_list, double dt) const override
Check the whole particle list for decays.