including third-body and pressure dependent derivatives, and derivative of the
temperature term. The complete Jacobian is more robust than the incomplete and
partially approximate form used previously and improves the efficiency of the
stiff ODE solvers which rely on the Jacobian.
Reaction rate evaluation moved from the chemistryModel to specie library to
simplfy support for alternative reaction rate expressions and associated
Jacobian terms.
Temperature clipping included in the Reaction class. This is inactive by default
but for most cases it is advised to provide temperature limits (high and
low). These are provided in the foamChemistryFile with the keywords Thigh and
Tlow. When using chemkinToFoam these values are set to the limits of the Janaf
thermodynamic data. With the new Jacobian this temperature clipping has proved
very beneficial for stability and for some cases essential.
Improvement of the TDAC MRU list better integrated in add and grow functions.
To get the most out of this significant development it is important to re-tune
the ODE integration tolerances, in particular the absTol in the odeCoeffs
sub-dictionary of the chemistryProperties dictionary:
odeCoeffs
{
solver seulex;
absTol 1e-12;
relTol 0.01;
}
Typically absTol can now be set to 1e-8 and relTol to 0.1 except for ignition
time problems, and with theses settings the integration is still robust but for
many cases a lot faster than previously.
Code development and integration undertaken by
Francesco Contino
Henry G. Weller, CFD Direct
twoPhaseMixtureThermo writes the temperatures during construction only
for them to be read again immediately after by construction of the
individual phases' thermo models. When running with collated file
handling this behaviour is not thread safe. This change deactivates
threading for the duration of this behaviour.
Patch contributed by Mattijs Janssens
The reference height is now defined in the direction of -g, whether as
previously it was defined in the direction cmptMag(g). This change makes
the behaviour consistent when the case is transformed. For a "typical"
case with g along one of the negative axes, this should make no
difference. None of the tutorials are affected.
Resolves bug report https://bugs.openfoam.org/view.php?id=2980
This is faster than the library functionality that it replaces, as it
allows the compiler to do inlining. It also does not utilise any static
state so generators do not interfere with each other. It is also faster
than the the array lookup in cachedRandom. The cachedRandom class
therefore offers no advantage over Random and has been removed.
Tree bound boxes are expanded asymmetrically to reduce the liklihood of
octree faces aliging with mesh faces and edges. The asymmetry is now
generated using hard-coded irrational numbers, rather than using a
random generator.
The asymmetry was effectively already hard coded. The random numbers are
only pseudo random, so the same numbers were being applied to the bound
boxes every time. This change simply removes the overhead of creating
the generator, and also gets rid of some duplicated code.
Sometimes decomposition can remove a cyclic patch entirely, converting
it into a processor cyclic. If this patch is being used to specify the
transform for a cyclicRepeatAMI patch then the calculation will fail.
This change adds a check for this situation, and errors with the
suggestion that the transform patch be preserved during decomposition.
The use of random numbers for positioning within the cone injection
models has been made consistent across all cores. Some calls have been
synchronised by means of the globalSample methods, whilst others have
been replaced by non-randomised algorithms.
This resolves bug report https://bugs.openfoam.org/view.php?id=2956
The functions findMin and findMax return the index of the minimum or
maximum component, consistently with the functions in ListOps.H. The
perpendicular function returns an arbitrary vector perpendicular to the
supplied vector, with the same magnitude.
MultiInteraction appeared to have been written for combining the usual
patch interaction models with a model called
CoincidentBaffleInteraction, which was never released. None of the
remaining patch interaction models make sense operating in combination,
so the MultiInteraction model has been removed. All documentation
references to CoincidentBaffleInteraction have also been deleted.
Resolves bug report https://bugs.openfoam.org/view.php?id=2939
This prevents infinite loops occurring during correction steps as a
result of a fixed correction velocity repeatedly pushing the particle
towards a rebound patch.
Resolves bug report https://bugs.openfoam.org/view.php?id=2935