When loading reactions from a YAML file, an instance of a Kinetics
object is required so that the species associated with the reactions are
available. The required object is now constructed from the already
loaded species definitions.
Fixes#821, problem introduced in 1866e3542d
Since we set the minimum Python version in SConstruct, use that value to
fill in python_requires in setup.py.in. This ensures that when the
minimum Python version is changed in the future, setup.py will
automatically reflect the change.
Check for the minimum ruamel.yaml version, 0.15.34, at install and test
time. The check happens at install and test time because ruamel.yaml is
only required to run the Python interface, not to build it.
To run the YAML converter scripts, ruamel.yaml must be installed with a
minumum version at least 0.15.34. We aren't sure what the true minimum
version is, but 0.15.34 was released in September 2017 and is the
newest version available from the Ubuntu 18.04 repositories.
YAML documents containing null values no longer generate errors while parsing.
Modify error messages generated by null values to indicate that the error can
be caused by either a missing key or a key with no value.
The inversion of setting the mole fractions based on the chemical potentials
is not obvious for non-ideal phases, and the implementation here based on
an ideal phase leads to incorrect equilibrium solutions.
The implementation of IdealSolidSolnPhase::setToEquilState incorrectly used
the input array as the element potentials rather than the species chemical
potentials. The modified implementation corresponds to that of the
IdealGasPhase class.
The previous implementation seems to generally have resulted in an exception
being raised, which normally results in falling back to the Gibbs solver,
so this shouldn't have been producing incorrect results.
The values passed into this function are the nondimensional (species) chemical
potentials, not the element potentials. The method ChemEquil::setToEquilState
already handles calculation of the chemical potentials from the element
potentials.
The old version of the sample was using a strange definition for the
composition of air which corresponded to neither of the typical
approximations, for example "O2: 1.0, N2: 3.76" or "O2: 0.21, N2: 0.79".
The test_ignition_delay_sensitivity test needs tighter intergrator tolerances
on the sensitivity coefficients in order to give results that reliably match
the finite difference approach on all platforms.
This provides the ability to organize data files included with Cantera
and differentiate data which is useful for different purposes, e.g. sample
data which is only meant to demonstrate capabilities and may not be
physically meaningful.
See Cantera/enhancements#22.
Fixes#774
This is the same method used for profile comparisons in the Python test
suite. These comparisons are skipped (with a warning) if Numpy is not
installed.
Eliminate unnecessary variables m_mdot_in and m_mdot_out, and remove
the need to update the mass flow rates in both updateState and evalEqs
by using the current (trial) time when updating them in updateState.