| Cantera 3.0.0

Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
ArrheniusBase Class Reference
Chemical Kinetics » Reactions and Reaction Rates » Arrhenius-type Parameterizations

Base class for Arrhenius-type Parameterizations. More...

`#include <Arrhenius.h>`

Inheritance diagram for ArrheniusBase:
[legend]

## Detailed Description

Base class for Arrhenius-type Parameterizations.

This base class provides a minimally functional interface that allows for parameter access from derived classes as well as classes that use Arrhenius-type expressions internally, for example FalloffRate and PlogRate.

Definition at line 43 of file Arrhenius.h.

## Public Member Functions
| ArrheniusBase ()
| Default constructor.
| ArrheniusBase (double A, double b, double Ea)
| Constructor.
| ArrheniusBase (const AnyValue &rate, const UnitSystem &units, const UnitStack &rate_units)
| Constructor based on AnyValue content.
| ArrheniusBase (const AnyMap &node, const UnitStack &rate_units={})
void | setRateParameters (const AnyValue &rate, const UnitSystem &units, const UnitStack &rate_units)
| Perform object setup based on AnyValue node information.
void | getRateParameters (AnyMap &node) const
| Get Arrhenius parameters used to populate the `rate-coefficient` or equivalent field.
void | setParameters (const AnyMap &node, const UnitStack &rate_units) override
| Set parameters.
void | getParameters (AnyMap &node) const override
| Get parameters.
void | check (const string &equation) override
| Check rate expression.
void | validate (const string &equation, const Kinetics &kin) override
| Validate the reaction rate expression.
virtual double | preExponentialFactor () const
| Return the pre-exponential factor A (in m, kmol, s to powers depending on the reaction order)
virtual double | temperatureExponent () const
| Return the temperature exponent b
virtual double | activationEnergy () const
| Return the activation energy Ea [J/kmol] The value corresponds to the constant specified by input parameters;.
double | order () const
| Return reaction order associated with the reaction rate.
void | setRateUnits (const UnitStack &rate_units) override
| Set units of the reaction rate expression.
bool | allowNegativePreExponentialFactor () const
| Get flag indicating whether negative A values are permitted.
void | setAllowNegativePreExponentialFactor (bool value)
| Set flag indicating whether negative A values are permitted.
Public Member Functions inherited from ReactionRate
| ReactionRate (const ReactionRate &other)
ReactionRate & | operator= (const ReactionRate &other)
virtual unique_ptr< MultiRateBase > | newMultiRate () const
| Create a rate evaluator for reactions of a particular derived type.
virtual const string | type () const =0
| String identifying reaction rate specialization.
virtual const string | subType () const
| String identifying sub-type of reaction rate specialization.
AnyMap | parameters () const
| Return the parameters such that an identical Reaction could be reconstructed using the newReaction() function.
const Units & | conversionUnits () const
| Get the units for converting the leading term in the reaction rate expression.
void | check (const string &equation, const AnyMap &node)
| Check basic syntax and settings of reaction rate expression.
virtual void | validate (const string &equation)
| Validate the reaction rate expression (legacy call)
size_t | rateIndex () const
| Reaction rate index within kinetics evaluator.
void | setRateIndex (size_t idx)
| Set reaction rate index within kinetics evaluator.
virtual void | setContext (const Reaction &rxn, const Kinetics &kin)
| Set context of reaction rate evaluation.
double | eval (double T)
| Evaluate reaction rate based on temperature.
double | eval (double T, double extra)
| Evaluate reaction rate based on temperature and an extra parameter.
double | eval (double T, const vector< double > &extra)
| Evaluate reaction rate based on temperature and an extra vector parameter.
bool | valid () const
| Get flag indicating whether reaction rate is set up correctly.
bool | compositionDependent ()
| Boolean indicating whether rate has compositional dependence.
void | setCompositionDependence (bool comp_dep)
| Set rate compositional dependence.

## Protected Attributes
bool | m_negativeA_ok = false
| Permissible negative A values.
double | m_A = NAN
| Pre-exponential factor.
double | m_b = NAN
| Temperature exponent.
double | m_Ea_R = 0.
| Activation energy (in temperature units)
double | m_E4_R = 0.
| Optional 4th energy parameter (in temperature units)
double | m_logA = NAN
| Logarithm of pre-exponential factor.
double | m_order = NAN
| Reaction order.
string | m_A_str = "A"
| The string for the pre-exponential factor.
string | m_b_str = "b"
| The string for temperature exponent.
string | m_Ea_str = "Ea"
| The string for activation energy.
string | m_E4_str = ""
| The string for an optional 4th parameter.
Protected Attributes inherited from ReactionRate
AnyMap | m_input
| Input data used for specific models.
size_t | m_rate_index = npos
| Index of reaction rate within kinetics evaluator.
bool | m_valid = false
| Flag indicating whether reaction rate is set up correctly.
bool | m_composition_dependent_rate = false
| Flag indicating composition dependent rate.
Units | m_conversion_units {0.}
| Units of the leading term in the reaction rate expression.

## Additional Inherited Members

## Constructor & Destructor Documentation

## ◆ ArrheniusBase() [1/4]

ArrheniusBase | ( |  | ) |
| inline

Default constructor.

Definition at line 47 of file Arrhenius.h.

## ◆ ArrheniusBase() [2/4]

ArrheniusBase | ( | double | A,
|  | double | b,
|  | double | Ea
| ) |  |

Constructor.

Parameters

  A | Pre-exponential factor. The unit system is (kmol, m, s); actual units depend on the reaction order and the dimensionality (surface or bulk).
  b | Temperature exponent (non-dimensional)
  Ea | Activation energy in energy units [J/kmol]

Definition at line 12 of file Arrhenius.cpp.

## ◆ ArrheniusBase() [3/4]

ArrheniusBase | ( | const AnyValue & | rate,
|  | const UnitSystem & | units,
|  | const UnitStack & | rate_units
| ) |  |

Constructor based on AnyValue content.

Definition at line 23 of file Arrhenius.cpp.

## ◆ ArrheniusBase() [4/4]

ArrheniusBase | ( | const AnyMap & | node,
|  | const UnitStack & | rate_units = `{}`
| ) |  |
| explicit

Definition at line 30 of file Arrhenius.cpp.

## Member Function Documentation

## ◆ setRateParameters()

void setRateParameters | ( | const AnyValue & | rate,
|  | const UnitSystem & | units,
|  | const UnitStack & | rate_units
| ) |  |

Perform object setup based on AnyValue node information.

Used to set parameters from a child of the reaction node, which may have different names for different rate parameterizations, such as falloff rates.

Parameters

  rate | Child of the reaction node containing Arrhenius rate parameters. For example, the `rate-coefficient` node for a standard Arrhenius reaction.
  units | Unit system
  rate_units | Unit definitions specific to rate information

Definition at line 35 of file Arrhenius.cpp.

## ◆ getRateParameters()

void getRateParameters | ( | AnyMap & | node | ) | const

Get Arrhenius parameters used to populate the `rate-coefficient` or equivalent field.

Definition at line 76 of file Arrhenius.cpp.

## ◆ setParameters()

void setParameters | ( | const AnyMap & | node,
|  | const UnitStack & | units
| ) |  |
| override virtual

Set parameters.

Parameters

  node | AnyMap object containing reaction rate specification
  units | unit definitions specific to rate information

Reimplemented from ReactionRate.

Definition at line 100 of file Arrhenius.cpp.

## ◆ getParameters()

void getParameters | ( | AnyMap & | node | ) | const
| override virtual

Get parameters.

Parameters

  node | AnyMap containing rate information Store the parameters of a ReactionRate needed to reconstruct an identical object. Does not include user-defined fields available in the m_input map.

Reimplemented from ReactionRate.

Definition at line 111 of file Arrhenius.cpp.

## ◆ check()

void check | ( | const string & | equation | ) |
| override virtual

Check rate expression.

Reimplemented from ReactionRate.

Definition at line 123 of file Arrhenius.cpp.

## ◆ validate()

void validate | ( | const string & | equation,
|  | const Kinetics & | kin
| ) |  |
| override virtual

Validate the reaction rate expression.

Reimplemented from ReactionRate.

Definition at line 138 of file Arrhenius.cpp.

## ◆ preExponentialFactor()

virtual double preExponentialFactor | ( |  | ) | const
| inline virtual

Return the pre-exponential factor A (in m, kmol, s to powers depending on the reaction order)

Class specializations may provide alternate definitions that describe an effective pre-exponential factor that depends on the thermodynamic state.

Definition at line 97 of file Arrhenius.h.

## ◆ temperatureExponent()

virtual double temperatureExponent | ( |  | ) | const
| inline virtual

Return the temperature exponent b

Class specializations may provide alternate definitions that describe an effective temperature exponent that depends on the thermodynamic state.

Definition at line 106 of file Arrhenius.h.

## ◆ activationEnergy()

virtual double activationEnergy | ( |  | ) | const
| inline virtual

Return the activation energy Ea [J/kmol] The value corresponds to the constant specified by input parameters;.

Class specializations may provide alternate definitions that describe an effective activation energy that depends on the thermodynamic state.

Reimplemented in BlowersMaselRate.

Definition at line 116 of file Arrhenius.h.

## ◆ order()

double order | ( |  | ) | const
| inline

Return reaction order associated with the reaction rate.

Definition at line 121 of file Arrhenius.h.

## ◆ setRateUnits()

void setRateUnits | ( | const UnitStack & | rate_units | ) |
| inline override virtual

Set units of the reaction rate expression.

Reimplemented from ReactionRate.

Definition at line 126 of file Arrhenius.h.

## ◆ allowNegativePreExponentialFactor()

bool allowNegativePreExponentialFactor | ( |  | ) | const
| inline

Get flag indicating whether negative A values are permitted.

Definition at line 136 of file Arrhenius.h.

## ◆ setAllowNegativePreExponentialFactor()

void setAllowNegativePreExponentialFactor | ( | bool | value | ) |
| inline

Set flag indicating whether negative A values are permitted.

Definition at line 141 of file Arrhenius.h.

## Member Data Documentation

## ◆ m_negativeA_ok

bool m_negativeA_ok = false
| protected

Permissible negative A values.

Definition at line 146 of file Arrhenius.h.

## ◆ m_A

double m_A = NAN
| protected

Pre-exponential factor.

Definition at line 147 of file Arrhenius.h.

## ◆ m_b

double m_b = NAN
| protected

Temperature exponent.

Definition at line 148 of file Arrhenius.h.

## ◆ m_Ea_R

double m_Ea_R = 0.
| protected

Activation energy (in temperature units)

Definition at line 149 of file Arrhenius.h.

## ◆ m_E4_R

double m_E4_R = 0.
| protected

Optional 4th energy parameter (in temperature units)

Definition at line 150 of file Arrhenius.h.

## ◆ m_logA

double m_logA = NAN
| protected

Logarithm of pre-exponential factor.

Definition at line 151 of file Arrhenius.h.

## ◆ m_order

double m_order = NAN
| protected

Reaction order.

Definition at line 152 of file Arrhenius.h.

## ◆ m_A_str

string m_A_str = "A"
| protected

The string for the pre-exponential factor.

Definition at line 153 of file Arrhenius.h.

## ◆ m_b_str

string m_b_str = "b"
| protected

The string for temperature exponent.

Definition at line 154 of file Arrhenius.h.

## ◆ m_Ea_str

string m_Ea_str = "Ea"
| protected

The string for activation energy.

Definition at line 155 of file Arrhenius.h.

## ◆ m_E4_str

string m_E4_str = ""
| protected

The string for an optional 4th parameter.

Definition at line 156 of file Arrhenius.h.

The documentation for this class was generated from the following files:

- Arrhenius.h
- Arrhenius.cpp