Go to the documentation of this file.
12 #include "cantera/kinetics/Falloff.h"
21 "Incorrect number of parameters. 0 required. Received {}.",
28 if (c.size() != 3 && c.size() != 4) {
30 "Incorrect number of parameters. 3 or 4 required. Received {}.",
35 m_rt3 = std::numeric_limits<double>::infinity();
41 m_rt1 = std::numeric_limits<double>::infinity();
49 "Unexpected parameter value T2=0. Omitting exp(T2/T) term from "
50 "falloff expression. To suppress this warning, remove value "
51 "for T2 from the input file. In the unlikely case that the "
52 "exp(T2/T) term should be included with T2 effectively equal "
53 "to 0, set T2 to a sufficiently small value "
54 "(i.e. T2 < 1e-16).");
64 Fcent += exp(-
m_t2 / T);
69 double Troe::F(
double pr,
const double* work)
const
72 double cc = -0.4 - 0.67 * (*work);
73 double nn = 0.75 - 1.27 * (*work);
74 double f1 = (lpr + cc)/ (nn - 0.14 * (lpr + cc));
75 double lgf = (*work) / (1.0 + f1 * f1);
76 return pow(10.0, lgf);
81 params[1] = 1.0/
m_rt3;
82 params[2] = 1.0/
m_rt1;
88 if (c.size() != 3 && c.size() != 5) {
90 "Incorrect number of parameters. 3 or 5 required. Received {}.",
96 "m_c parameter is less than zero: {}", c[2]);
105 "m_d parameter is less than zero: {}", c[3]);
117 *work =
m_a * exp(-
m_b / T);
119 *work += exp(- T/
m_c);
121 work[1] =
m_d * pow(T,
m_e);
124 double SRI::F(
double pr,
const double* work)
const
127 double xx = 1.0/(1.0 + lpr*lpr);
128 return pow(*work, xx) * work[1];
virtual void init(const vector_fp &c)
Initialization of the object.
const double SmallNumber
smallest number to compare to zero.
virtual void getParameters(double *params) const
Sets params to contain, in order,.
doublereal m_a
parameter a in the 5-parameter SRI falloff function. Dimensionless.
doublereal m_t2
parameter T_2 in the 4-parameter Troe falloff function. [K]
std::vector< double > vector_fp
Turn on the use of stl vectors for the basic array type within cantera Vector of doubles.
virtual doublereal F(doublereal pr, const doublereal *work) const
The falloff function.
doublereal m_rt1
parameter 1/T_1 in the 4-parameter Troe falloff function. [K^-1]
virtual void getParameters(double *params) const
Sets params to contain, in order,.
doublereal m_d
parameter d in the 5-parameter SRI falloff function. Dimensionless.
doublereal m_b
parameter b in the 5-parameter SRI falloff function. [K]
doublereal m_e
parameter d in the 5-parameter SRI falloff function. Dimensionless.
doublereal m_rt3
parameter 1/T_3 in the 4-parameter Troe falloff function. [K^-1]
virtual void updateTemp(doublereal T, doublereal *work) const
Update the temperature parameters in the representation.
virtual void init(const vector_fp &c)
Initialize.
doublereal m_a
parameter a in the 4-parameter Troe falloff function. Dimensionless
Base class for exceptions thrown by Cantera classes.
virtual void init(const vector_fp &c)
Initialization of the object.
virtual doublereal F(doublereal pr, const doublereal *work) const
The falloff function.
virtual void updateTemp(doublereal T, doublereal *work) const
Update the temperature parameters in the representation.
Namespace for the Cantera kernel.
doublereal m_c
parameter c in the 5-parameter SRI falloff function. [K]