Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation updates #1231

Merged
merged 6 commits into from
Mar 28, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 33 additions & 5 deletions doc/sphinx/yaml/reactions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ The fields common to all ``reaction`` entries are:
- :ref:`chemically-activated <sec-yaml-chemically-activated>`
- :ref:`pressure-dependent-Arrhenius <sec-yaml-pressure-dependent-Arrhenius>`
- :ref:`Chebyshev <sec-yaml-Chebyshev>`
- :ref:`two-temperature-plasma <sec-yaml-two-temperature-plasma>`
- :ref:`Blowers-Masel <sec-yaml-Blowers-Masel>`
- :ref:`surface-Blowers-Masel <sec-yaml-surface-Blowers-Masel>`

Expand Down Expand Up @@ -286,6 +287,26 @@ Example::
type: Blowers-Masel
rate-constant: {A: 3.87e+04 cm^2/mol/s, b: 2.7, Ea0: 6260.0 cal/mol, w: 1e9 cal/mol}

.. _sec-yaml-two-temperature-plasma:

``two-temperature-plasma``
--------------------------

A reaction involving an electron as one of the reactants, where the electron temperature
may differ from the gas temperature as `described here <https://cantera.org/science/reactions.html#two-temperature-plasma-reactions>`__.

Includes the fields of an :ref:`sec-yaml-elementary` reaction, except that the
``rate-constant`` field is a mapping with the fields:

``A``
The pre-exponential factor
``b``
The temperature exponent, which is applied to the electron temperature
``Ea_T``
The activation energy term :math:`E_{a,g}` that is related to the gas temperature
``Ea_Te``
The activation energy term :math:`E_{a,e}` that is related to the electron
temperature

.. _sec-yaml-interface-reaction:

Expand All @@ -312,7 +333,7 @@ Includes the fields of an :ref:`sec-yaml-elementary` reaction plus:

``coverage-dependencies``
A mapping of species names to coverage dependence parameters, where these
parameters are contained in a mapping with the fields:
parameters are contained in either a mapping with the fields:

``a``
Coefficient for exponential dependence on the coverage
Expand All @@ -324,17 +345,24 @@ Includes the fields of an :ref:`sec-yaml-elementary` reaction plus:
Activation energy dependence on coverage, which uses the same sign convention
as the leading-order activation energy term

or a list containing the three elements above, in the given order.

Note that parameters ``a``, ``m`` and ``E`` correspond to parameters
:math:`\eta_{ki}`, :math:`\mu_{ki}` and :math:`\epsilon_{ki}` in Eq 11.113 of
[Kee, R. J., Coltrin, M. E., & Glarborg, P.(2003). Chemically reacting flow:
theory and practice. John Wiley & Sons], respectively.

Example::
Examples::

equation: 2 H(s) => H2 + 2 Pt(s)
rate-constant: {A: 3.7e21 cm^2/mol/s, b: 0, Ea: 67400 J/mol}
coverage-dependencies: {H(s): {a: 0, m: 0, E: -6000 J/mol}}
- equation: 2 H(s) => H2 + 2 Pt(s)
rate-constant: {A: 3.7e21 cm^2/mol/s, b: 0, Ea: 67400 J/mol}
coverage-dependencies: {H(s): {a: 0, m: 0, E: -6000 J/mol}}

- equation: CH4 + PT(S) + O(S) => CH3(S) + OH(S)
rate-constant: {A: 5.0e+18, b: 0.7, Ea: 4.2e+04}
coverage-dependencies:
O(S): [0, 0, 8000]
PT(S): [0, -1.0, 0]

.. _sec-yaml-electrochemical-reaction:

Expand Down
2 changes: 1 addition & 1 deletion interfaces/cython/cantera/examples/transport/dusty_gas.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
create a transport manager that implements the Dusty Gas model and use it to
compute the multicomponent diffusion coefficients and thermal conductivity.

Requires: cantera >= 2.5.0
Requires: cantera >= 2.6.0
"""

import cantera as ct
Expand Down
14 changes: 7 additions & 7 deletions interfaces/cython/cantera/reaction.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,9 @@ cdef class ArrheniusRateBase(ReactionRate):
def _cinit(self, input_data, **kwargs):
"""
Helper function called by __cinit__. The method is used as a uniform interface
for object construction. A separate method is necessary as Cython does not
support overloading of special methods such as __cinit__.
for object construction. A separate method is necessary as default argument
values to __cinit__ defined in derived classes are not available in the base
class's __cinit__ (which gets called first).
"""
if self._reaction_rate_type is None:
raise TypeError(
Expand Down Expand Up @@ -286,12 +287,11 @@ cdef class TwoTempPlasmaRate(ArrheniusRateBase):
k_f = A T_e^b \exp(-\tfrac{E_{a,g}}{RT}) \exp(\tfrac{E_{a,e}(T_e - T)}{R T T_e})

where :math:`A` is the
`pre_exponential_factor <ArrheniusTypeRate.pre_exponential_factor>`,
:math:`b` is the `temperature_exponent <ArrheniusTypeRate.temperature_exponent>`,
`pre_exponential_factor <ArrheniusRateBase.pre_exponential_factor>`,
:math:`b` is the `temperature_exponent <ArrheniusRateBase.temperature_exponent>`,
:math:`E_{a,g}` (``Ea_gas``) is the
`activation_energy <ArrheniusTypeRate.activation_energy>`, and
:math:`E_{a,e}` (``Ea_electron``) is the
`activation_electron_energy <ArrheniusTypeRate.activation_electron_energy>`.
`activation_energy <ArrheniusRateBase.activation_energy>`, and
:math:`E_{a,e}` (``Ea_electron``) is the `activation_electron_energy`.
"""
_reaction_rate_type = "two-temperature-plasma"

Expand Down
6 changes: 5 additions & 1 deletion samples/cxx/jacobian/derivative_speed.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
/*!
* @file derivative_speed.cpp
*
* Benchmark tests for derivative evaluations
* Benchmark derivative evaluations
*
* Calculate derivatives of reaction rates of progress and species production and
* destruction rates with respect to temperature, pressure, molar concentration,
* and mole fractions. Time evaluation for different chemical mechanisms.
*/

// This file is part of Cantera. See License.txt in the top-level directory or
Expand Down