62 m_b = rate_vec[1].asDouble();
63 if (rate_vec.size() > 2) {
66 if (rate_vec.size() > 3) {
90 node[
"__unconvertible__"] =
true;
104 if (!node.
hasKey(
"rate-constant")) {
113 node[
"negative-A"] =
true;
117 if (!rateNode.
empty()) {
119 node[
"rate-constant"] = std::move(rateNode);
126 if (equation ==
"") {
128 "Detected negative pre-exponential factor (A={}).\n"
129 "Enable 'allowNegativePreExponentialFactor' to suppress "
130 "this message.",
m_A);
133 "Undeclared negative pre-exponential factor found in reaction '{}'",
142 "Rate object for reaction '{}' is not configured.", equation);
Header for reaction rates that involve Arrhenius-type kinetics.
Header file for class ThermoPhase, the base class for phases with thermodynamic properties,...
A map of string keys to values whose type can vary at runtime.
bool hasKey(const string &key) const
Returns true if the map contains an item named key.
const UnitSystem & units() const
Return the default units that should be used to convert stored values.
bool empty() const
Return boolean indicating whether AnyMap is empty.
void setFlowStyle(bool flow=true)
Use "flow" style when outputting this AnyMap to YAML.
bool getBool(const string &key, bool default_) const
If key exists, return it as a bool, otherwise return default_.
A wrapper for a variable whose type is determined at runtime.
bool empty() const
Return boolean indicating whether AnyValue is empty.
bool is() const
Returns true if the held value is of the specified type.
const vector< T > & asVector(size_t nMin=npos, size_t nMax=npos) const
Return the held value, if it is a vector of type T.
const T & as() const
Get the value of this key as the specified type.
void setParameters(const AnyMap &node, const UnitStack &rate_units) override
Set parameters.
string m_b_str
The string for temperature exponent.
string m_E4_str
The string for an optional 4th parameter.
double m_E4_R
Optional 4th energy parameter (in temperature units)
void getRateParameters(AnyMap &node) const
Get Arrhenius parameters used to populate the rate-coefficient or equivalent field.
void validate(const string &equation, const Kinetics &kin) override
Validate the reaction rate expression.
string m_Ea_str
The string for activation energy.
void getParameters(AnyMap &node) const override
Get parameters.
double m_A
Pre-exponential factor.
void setRateParameters(const AnyValue &rate, const UnitSystem &units, const UnitStack &rate_units)
Perform object setup based on AnyValue node information.
bool m_negativeA_ok
Permissible negative A values.
string m_A_str
The string for the pre-exponential factor.
double m_b
Temperature exponent.
void check(const string &equation) override
Check rate expression.
void setRateUnits(const UnitStack &rate_units) override
Set units of the reaction rate expression.
ArrheniusBase()
Default constructor.
double m_logA
Logarithm of pre-exponential factor.
double m_Ea_R
Activation energy (in temperature units)
Base class for exceptions thrown by Cantera classes.
Public interface for kinetics managers.
double temperature() const
Temperature (K).
virtual void setParameters(const AnyMap &node, const UnitStack &units)
Set parameters.
const Units & conversionUnits() const
Get the units for converting the leading term in the reaction rate expression.
bool valid() const
Get flag indicating whether reaction rate is set up correctly.
bool m_valid
Flag indicating whether reaction rate is set up correctly.
AnyMap m_input
Input data used for specific models.
Base class for a phase with thermodynamic properties.
double convertRateCoeff(const AnyValue &val, const Units &dest) const
Convert a generic AnyValue node representing a reaction rate coefficient to the units specified in de...
double convertActivationEnergy(double value, const string &src, const string &dest) const
Convert value from the units of src to the units of dest, allowing for the different dimensions that ...
A representation of the units associated with a dimensional quantity.
const double GasConstant
Universal Gas Constant [J/kmol/K].
Namespace for the Cantera kernel.
bool update(const ThermoPhase &phase, const Kinetics &kin) override
Update data container based on thermodynamic phase state.
double temperature
temperature
Unit aggregation utility.