- previously always called dlclose on opened libraries when destroying
the dlLibraryTable. However, by force closing the libraries the
situation can arise that the library is missing its own code that it
needs on unload (#1524). This is also sometimes evident when closing
VTK libraries for runTimePostProcessing (#354, #1585).
- The new default is to not forcibly dlclose any libraries, unless
the dlcloseOnTerminate OptimisationSwitch specifies otherwise.
- The dlLibraryTable::close() method can be used to explicitly close
all libraries and clear the list.
- The dlLibraryTable::clear() method now only clears the entries,
without a dlclose.
Failures shown in interFoam cases were found to be a result of stale ldu
addressing in fvMesh. Potentially delete lduPtr_ alone, but likely safer to
clear all addressing:
// deleteDemandDrivenData(lduPtr_);
clearAddressing(true);
The FO BilgerMixtureFraction needs access to specieComposition which is
stored in ReactingMixture. A virtual mechanism was added to
basicSpecieMixture to access specieComposition form rho and psi
reationThermos.
ptr was changed to autoPtr to avoid memory leaks (Kutalmis Bercin)
Multiplies a given list of (at least two or more) fields and outputs the
result into a new field.
fieldResult = field1 * field2 * ... * fieldN
Minimal example by using \c system/controlDict.functions:
multiply1
{
// Mandatory entries (unmodifiable)
type multiply;
libs (fieldFunctionObjects);
// Mandatory (inherited) entry (runtime modifiable)
fields (<field1> <field2> ... <fieldN>);
...
}
- now also tracks the previous output time, which aids on restarts
since it allows the FEA side the possibility of determining
the effective deltaT between the output of forces
COMP: fix SP/DP inconsistency in fvGeometryScheme
STYLE: rename polyMesh::updateGeom to polyMesh::updateGeomPoints
- avoids compiler complaints and potential masking of
primitiveMesh::updateGeom / fvMesh::updateGeom
- mark argument as movable, since that is what is happening inside.
GIT: remove merge cruft
TUT: better clean on MPPICInterFoam
The SPL can now be weighted according to the new 'SPLweighting' entry
that can be set to:
- none: no weighting
- dBA : dB(A)
- dBB : dB(B)
- dBC : dB(C)
- dBD : dB(D)
This commit also includes code refactoring of the noiseModel class to
remove the dependency on noiseFFT/declutter.
Affected only the first optimisation cycle, if line search was enabled
If eta was not set explicitly, it was computed after evaluating the
directional derivative of the merit function, which was computed
wrongly, leading to an erroneous value of the extrapolated merit
function value.
fvOptionsAdjoint was needlessly duplicating a lot of the functionality
of fvOptions in order to add an interface for computing sensitivity
contributions emerging from fvOptions. To reduce this code duplication:
- fvOptionsAdjoint was removed
- the corresponding sensitivity contributions have moved to fvOptions through
virtual functions (returning a zero contribution in the base so
backwards compatibility is retained)
- all sensitivity classes that were using fvOptionsAdjoint have been
modified appropriately
- all adjoint solvers are now grabbing a reference to an fvOptionList
from the database instead of constructing an fvOptionsAdjointList
Hence, all fvOptions contributions to the adjoint equations
or the sensitivity derivatives can be given through system/fvOptions,
removing the need for separate sub-dictionaries within optimisationDict.
- Expanded the write function in the base class so that it can manage
input coming from the derived ones. This reduces a lot of code
duplication in the latter but keeps the functionality.
- Added a default width for all entries in the objective files.
- If a normalisation factor or a target is set, they are written on the
header of the objective file.
- Cosmetic/code consistency changes in various files.
- Added preLoop, loop and postLoop functions
- Added preIter, mainIter and postIter functions for each SIMPLE
iteration
- Added addMomentumSource and addPressureSource virtual functions, to
allow for additions by derived classes
fvOptions are no longer a member of incompressiblePrimalSolver but are
looked up from the registry in each iteration of each primal solver.
This means that the main system/fvOptions dictionary is read by ALL
instances of the primal solvers and the latter no longer have their
own fvOptions dict in optimisationDict. This is safe since each fvOption
is applied to a specific field and in case of many primal solvers, the
primal fields are named differently for each of them.
In addition, simple is now split in preLoop, loop and postLoop phase.
Furthermore, each SIMPLE iteration is broken down to
a preIter, mainIter and postIter phase, to allow for different behaviour
by derived classes.
Part of the (E)SI shape sensitivities depends of grad(Ua) & nf computed
on the boundary. Up to now, the code was only computing the normal part
of grad(Ua), to avoid the potentially spurious tangential component
which is computed on the cell center and extrapolated to the boundary
faces. However, for some objectives that are strongly related to the
stresses (e.g. moment, stresses), including also the tangential part of
grad(Ua) is necessary for E-SI to replicate the outcome of FI.
Extensive testing on a number of objectives/cases showed
- No regression when including the tangential part
- Improved behaviour in some rare cases (moment, stresses)
Hence, the tangential part is now included by default. The previous code
behaviour can be replicated by setting the useSnGradInTranposeStresses
flag to true.
- controlPointsDefinition is now controled by a class with
runTimeSelection.
- Added a new controlPointsDefinition option that translates, rotates
and scales a given box. The required entries have the same meaning as
in the Paraview 'Transform' filter, facilitating the transition between the
visual placement of control boxes (e.g. in Paraview) and their setup
in the code.
- Improved performance during the parameterization, sensitivity
computation and grid displacement phases by re-using already computed
basis functions.