19 std::complex<double> gamma,
22 std::complex<double> res = std::norm(gamma) * g * g * phspFactor / mR;
26 if (std::isnan(res.real()) || std::isnan(res.imag()))
27 throw std::runtime_error(
"couplingToWidth() | Result is NaN!");
29 if (std::isinf(res.real()) || std::isinf(res.imag()))
30 throw std::runtime_error(
"couplingToWidth() | Result is inf!");
44 std::complex<double> gamma,
47 auto denom = gamma * std::sqrt(phspFactor);
48 auto res = std::complex<double>(sqrt(mR * width), 0) / denom;
52 if (std::isnan(res.real()) || std::isnan(res.imag()))
53 throw std::runtime_error(
"AmpAbsDynamicalFunction::widthToCoupling() | " 56 if (std::isinf(res.real()) || std::isinf(res.imag()))
57 throw std::runtime_error(
"AbstractDynamicalFunction::widthToCoupling() | " 72 const boost::property_tree::ptree tr) {
73 G = std::make_shared<ComPWA::FunctionTree::FitParameter>(tr.get_child(
""));
74 std::string nameA = tr.get<std::string>(
"ParticleA");
75 std::string nameB = tr.get<std::string>(
"ParticleB");
78 MassA = std::make_shared<ComPWA::FunctionTree::FitParameter>(mA);
79 MassB = std::make_shared<ComPWA::FunctionTree::FitParameter>(mB);
82 std::shared_ptr<ComPWA::FunctionTree::FitParameter>
G;
83 std::shared_ptr<ComPWA::FunctionTree::FitParameter>
MassA;
84 std::shared_ptr<ComPWA::FunctionTree::FitParameter>
MassB;
double phspFactor(double sqrtS, double ma, double mb)
ComPWA::FitParameter< double > getMass() const
Implementations of Parameter for various data types.
std::shared_ptr< ComPWA::FunctionTree::FitParameter > MassB
const ParticleProperties & findParticle(const ParticleList &list, pid Pid)
std::set< ParticleProperties > ParticleList
std::shared_ptr< ComPWA::FunctionTree::FitParameter > MassA
std::complex< double > widthToCoupling(double mR, double width, std::complex< double > gamma, std::complex< double > phspFactor)
Convert width to complex coupling.
std::complex< double > couplingToWidth(double mR, double g, std::complex< double > gamma, std::complex< double > phspFactor)
Convert width to complex coupling.
Coupling(double c, double massA, double massB)
std::shared_ptr< ComPWA::FunctionTree::FitParameter > G
Coupling(const ComPWA::ParticleList &partL, const boost::property_tree::ptree tr)