23#include "marley/NuclearReaction.hh"
24#include "marley/TabulatedXSec.hh"
40 int pdg_b,
int pdg_c,
int pdg_d,
int q_d,
41 const std::shared_ptr<TabulatedXSec>& txsec,
44 virtual std::shared_ptr< HepMC3::GenEvent >
create_event(
47 virtual double total_xs(
int pdg_a,
double KEa )
const override;
59 static SubContinuumMode sub_continuum_mode_from_string(
60 const std::string& sc_mode_str );
62 static std::string string_from_sub_continuum_mode(
63 const SubContinuumMode sc_mode );
83 const double KEa )
const;
95 const double KEa,
double* jacobian =
nullptr)
const;
98 std::shared_ptr< TabulatedXSec >
xsec_;
virtual void set_description() override
Creates the description string based on the PDG code values for the initial and final particles.
static SubContinuumMode sc_mode_
Indicates the desired method for handling events with excitation energies originally sampled below th...
virtual std::shared_ptr< HepMC3::GenEvent > create_event(int particle_id_a, double KEa, marley::Generator &gen) const override
Create an event object for this reaction.
virtual double total_xs(int pdg_a, double KEa) const override
Compute the reaction's total cross section (MeV -2)
static SubContinuumMode sub_continuum_mode()
Gets the approach to handling sub-continuum cross-section strength.
bool reassign_sub_continuum(double &w, const double ctl, const double KEa) const
Helper function for create_event() that potentially reassigns the value of the energy transfer.
std::shared_ptr< TabulatedXSec > xsec_
Helper object that handles cross section calculations.
static const std::map< SubContinuumMode, std::string > sc_mode_string_map_
Helper map used for conversions between a SubContinuumMode value and a std::string.
static void set_sub_continuum_mode(SubContinuumMode scm)
Sets the approach to handling sub-continuum cross-section strength.
double get_Ec_from_Ex(const double Ex, const double cos_theta, const double KEa, double *jacobian=nullptr) const
Helper function for reassign_sub_continuum() that solves for the outgoing lepton total energy that co...
The MARLEY Event generator.
NuclearReaction(ProcessType pt, int pdg_a, int pdg_b, int pdg_c, int pdg_d, int q_d, const std::string &source_file)
ProcessType
Enumerated type describing the kind of scattering process represented by a Reaction.
const std::string & source_file() const
Get the resolved path of the reaction data file used to construct this Reaction.
int pdg_a() const
Get the projectile PDG code.
int pdg_b() const
Get the target PDG code.
Computes inclusive lepton-nucleus cross sections using tabulated nuclear response functions.