68 void operator=(
const LBFGS&) =
delete;
138 virtual ~LBFGS() =
default;
151 virtual void write();
void allocateMatrices()
Allocate matrices in the first optimisation cycle.
TypeName("LBFGS")
Runtime type information.
void update()
Update design variables.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
void readFromDict()
Read old info from dict.
Abstract base class for optimisation methods.
virtual void write()
Write old info to dict.
void steepestDescentUpdate()
Update based on steepest descent.
scalar etaHessian_
Step for the Newton method.
labelList activeDesignVars_
Map to active design variables.
virtual void updateOldCorrection(const scalarField &oldCorrection)
Update old correction. Useful for quasi-Newton methods coupled with line search.
void pivotFields(PtrList< scalarField > &list, const scalarField &f)
Move pointers in PtrList to the left and replace last element with given field.
PtrList< scalarField > s_
The previous correction. Holds nPrevSteps_ fields.
scalarField derivativesOld_
The previous derivatives.
label nPrevSteps_
Number of old corrections and grad differences kept.
label counter_
Optimisation cycle counter.
void LBFGSUpdate()
Update based on LBFGS.
void computeCorrection()
Compute design variables correction.
label nSteepestDescent_
Number of first steepest descent steps.
scalarField correctionOld_
The previous correction.
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers...
Mesh data needed to do the Finite Volume discretisation.
PtrList< scalarField > y_
The previous differences of derivatives. Holds nPrevSteps_ fields.
The quasi-Newton Limited-memory BFGS formula. Keeps nPrevSteps_ of the y and s vectors and approximat...
void updateVectors()
Update y and s vectors.
virtual ~LBFGS()=default
Destructor.