12 #include "gsl/gsl_sf_coupling.h"
32 const int I_tot,
const int I_z) {
44 std::vector<int> possible_I_ab(max_I_ab - min_I_ab + 1);
45 std::iota(possible_I_ab.begin(), possible_I_ab.end(), min_I_ab);
46 std::vector<int> allowed_I_ab;
47 allowed_I_ab.reserve(possible_I_ab.size());
48 for (
const auto Iab : possible_I_ab) {
49 const auto min_I = std::abs(Iab - p_c.
isospin());
50 const auto max_I = Iab + p_c.
isospin();
52 allowed_I_ab.push_back(Iab);
55 if (allowed_I_ab.size() != 1) {
56 throw std::runtime_error(
57 "The coupled 3-body isospin state is not uniquely defined for " +
60 const auto I_ab = allowed_I_ab[0];
78 double isospin_factor = 0.;
79 for (
const int I_tot :
I_tot_range(p_a, p_b, p_c, p_d)) {
80 if (I < 0 || I_tot == I) {
83 isospin_factor = isospin_factor + cg_in * cg_in * cg_out * cg_out;
86 return isospin_factor;
static double coefficient(const int j_a, const int j_b, const int j_c, const int m_a, const int m_b, const int m_c)
Check in the Clebsch-Gordan lookup table if the requested coefficient is available.
Range of total isospin for reaction of particle a with particle b.
Particle type contains the static properties of a particle species.
const std::string & name() const
int isospin() const
Returns twice the isospin vector length .
Collection of useful constants that are known at compile time.
double isospin_clebsch_gordan_sqr_3to1(const ParticleType &p_a, const ParticleType &p_b, const ParticleType &p_c, const ParticleType &Res)
Calculate the squared isospin Clebsch-Gordan coefficient for three particles p_a, p_b and p_c couplin...
double isospin_clebsch_gordan_sqr_2to2(const ParticleType &p_a, const ParticleType &p_b, const ParticleType &p_c, const ParticleType &p_d, const int I=-1)
Calculate the squared isospin Clebsch-Gordan coefficient for a 2-to-2 reaction A + B -> C + D.
static double isospin_clebsch_gordan_2to1(const ParticleType &p_a, const ParticleType &p_b, const int I_tot, const int I_z)
Calculate isospin Clebsch-Gordan coefficient for two particles p_a and p_b coupling to a total isospi...