Skip to content

Inconsistency in ReactionRateCoeff units calculation #1071

@ischoegl

Description

@ischoegl

Problem description

Since the introduction of YAML, reaction constructors ensure that units are provided in a consistent manner. Units are, however, not consistently handled when constructing reactions from scratch, i.e.

ElementaryReaction3(const Composition& reactants, const Composition& products, const ArrheniusRate& rate);

or

ElementaryReaction2(const Composition& reactants_, const Composition products_, const Arrhenius& rate_);

as well as all other corresponding constructor instances.

While it is (at least for the newer framework) possible to associate units with ReactionRate objects, there never is a call to Reaction::calculateRateCoeffUnits that would otherwise handle units.

Per @speth's comments ...

the units for the rate constant are a combination of the reacting phase standard concentration units and the concentration units for the reactants, as in Reaction::calculateRateCoeffUnits.

Steps to reproduce

N/A ... although these C++ constructors are widely used in the C++ test suite.

Behavior

Units are never calculated (no call to Reaction::calculateRateCoeffUnits).

System information

  • Cantera version: current development version
  • OS: all
  • Python/MATLAB/other software versions: N/A (it is part of the C++ core)

Additional context

This issue surfaced when discussing PR #1061

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions