This causes problems to be caught early, where they can at least sometimes be
handled as recoverable intergrator errors, rather than letting NaN values
propagate through the solution.
For binary (or higher order) reactions, multiple negative (but small, i.e. with
respect to integration tolerances) species concentrations should not produce
positive reaction rates that would drive those concentrations to even more
negative values.
Throwing an exception when a state variable is being set to NaN transforms some
reactor network integration errors from unrecoverable errors into recoverable
errors.
The constructor with the signature (inputFile, [id]) just calls initThermoFile.
The constructor with the signature (phase XML node, [id]) just calls importPhase
(note that the id argument is unused, since the correct XML node must already be
given).
If any of the reaction orders differ from the corresponding stoichiometric
coefficients, the reaction needs to be handled as the general case, instead of
just when the orders are non-integral.
The check introduced in f6f868fe28 takes place too late, as the pointer to
ReactorBase.m_thermo has already been dereferenced at this point. Most compilers
let this pass, but it is techincally incorrect.
The downstream and upstream Reactors, the "master" flow controller, and the
coefficient arrays were being read without checking that they had been
initialized.
Fixes#278.
They have the names setState_RP, setState_RPX, and setState_RPY. These
base class functions mirror the TP, TPX, TPY set, except that RP is not
implemented, because it depends on the EOS of the system. We cannot use
the normal setPressure because it sets the state by calculating the
density, but RP will specify the density.
The value of this argument has almost no effect on the integrator, and
frequently confuses users since the ReactorNet can end up at a time either
greater or less than the specified time. By removing this argument, the
distinction betwen step() and advance(t) becomes much more clear.
The first argument should be the function name from which the exception was
thrown. Leaving this blank makes it difficult to track down the location of the
exception.