32 "Missing state information: 'TwoTempPlasmaData' requires electron temperature.");
41void TwoTempPlasmaData::updateTe(
double Te)
48TwoTempPlasmaRate::TwoTempPlasmaRate()
54TwoTempPlasmaRate::TwoTempPlasmaRate(
double A,
double b,
double Ea,
double EE,
55 double bg,
double Tinv)
67TwoTempPlasmaRate::TwoTempPlasmaRate(
const AnyMap& node,
const UnitStack& rate_units)
77 if (!node.
hasKey(
"rate-constant")) {
81 auto& rateNode = node[
"rate-constant"].as<
AnyMap>();
84 rateNode[
"b-gas"] =
m_bg;
103 if (!node.
hasKey(
"rate-constant")) {
109 if (node[
"rate-constant"].is<AnyMap>()) {
112 const auto& rate = node[
"rate-constant"].as<
AnyMap>();
114 m_bg = rate.getDouble(
"b-gas", 0.0);
117 if (rate.hasKey(
"T-inv")) {
118 Tinv = rate.convert(
"T-inv",
"K");
129 const auto& rate = node[
"rate-constant"].asVector<
AnyValue>(2, 6);
132 if (rate.size() <= 4) {
140 AnyValue baseRate = node[
"rate-constant"];
146 m_bg = rate[4].asDouble();
149 if (rate.size() == 6) {
157 warn_user(
"TwoTempPlasmaRate::ddTScaledFromStruct",
158 "Temperature derivative does not consider changes of electron temperature.");
170 "TwoTempPlasmaRate does not support reversible reactions");
Header file for class ThermoPhase, the base class for phases with thermodynamic properties,...
Header for plasma reaction rates parameterized by two temperatures (gas and electron).
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.
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.
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.
void setParameters(const AnyMap &node, const UnitStack &rate_units) override
Set parameters.
string m_E4_str
The string for an optional 4th parameter.
double m_E4_R
Optional 4th energy parameter (in temperature units).
string m_Ea_str
The string for activation energy.
void getParameters(AnyMap &node) const override
Get parameters.
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.
ArrheniusBase()
Default constructor.
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 double electronTemperature() const
Electron Temperature (K).
virtual void setParameters(const AnyMap &node, const UnitStack &units)
Set parameters.
Abstract base class which stores data about a reaction and its rate parameterization so that it can b...
bool reversible
True if the current reaction is reversible. False otherwise.
AnyMap input
Input data used for specific models.
Base class for a phase with thermodynamic properties.
void setContext(const Reaction &rxn, const Kinetics &kin) override
Check that the reaction does not have the 'reversible: true' attribute.
double ddTScaledFromStruct(const TwoTempPlasmaData &shared_data) const
Evaluate derivative of reaction rate with respect to temperature divided by reaction rate.
double m_recip_Tinv
Reciprocate of the temperature scale for the optional term .
void setParameters(const AnyMap &node, const UnitStack &rate_units) override
Set parameters from an AnyMap object.
double m_bg
Gas temperature exponent.
void getParameters(AnyMap &node) const override
Get parameters.
double convert(double value, const string &src, const string &dest) const
Convert value from the units of src to the units of dest.
const double GasConstant
Universal Gas Constant [J/kmol/K].
void warn_user(const string &method, const string &msg, const Args &... args)
Print a user warning raised from method as CanteraWarning.
Namespace for the Cantera kernel.
double recipT
inverse of temperature
virtual void update(double T)
Update data container based on temperature T.
double temperature
temperature
Data container holding shared data specific to TwoTempPlasmaRate.
bool update(const ThermoPhase &phase, const Kinetics &kin) override
Update data container based on thermodynamic phase state.
double electronTemp
electron temperature
double logTe
logarithm of electron temperature
double recipTe
inverse of electron temperature
Unit aggregation utility.