Lbfgs

class Lbfgs : public minim::NewMinimiser<Lbfgs>

LBFGS minimisation algorithm.

Limited-memory Broyden-Fletcher-Goldfarb-Shanno. A quasi-Newton method that uses the last m iterations of position and gradient changes to approximate the inverse Hessian, giving Newton-like convergence without computing second derivatives.

Converged when the RMS gradient falls below the state’s convergence criterion.

Public Functions

Lbfgs &setM(int m)

Set the number of stored iterations m used to approximate the inverse Hessian (default: 5).

virtual Lbfgs &setMaxIter(int maxIter)

Set the maximum number of iterations.

Lbfgs &setMaxStep(double maxStep)

Set the maximum allowed step size (0: no limit).

Lbfgs &setInitStep(double initStep)

Set the initial step size used in the first iteration, when no curvature information is yet available (default: 1).

virtual void init(State &state)

Initialise the minimiser before the first iteration.

virtual void iteration(State &state)

Perform a single minimisation iteration.

virtual bool checkConvergence(const State &state) override

Check whether the minimisation is converged.