Quasi-Newton method explained

Quasi-Newton methods are methods used to find either zeroes or local maxima and minima of functions, as an alternative to Newton's method. They can be used if the Jacobian or Hessian is unavailable or is too expensive to compute at every iteration. The "full" Newton's method requires the Jacobian in order to search for zeros, or the Hessian for finding extrema. Some iterative methods that reduce to Newton's method, such as SLSQP, may be considered quasi-Newtonian.

Search for zeros: root finding

Newton's method to find zeroes of a function

g

of multiple variables is given by

xn+1=xn-[Jg(x

-1
n)]

g(xn)

, where

[Jg(x

-1
n)]
is the left inverse of the Jacobian matrix

Jg(xn)

of

g

evaluated for

xn

.

Strictly speaking, any method that replaces the exact Jacobian

Jg(xn)

with an approximation is a quasi-Newton method.[1] For instance, the chord method (where

Jg(xn)

is replaced by

Jg(x0)

for all iterations) is a simple example. The methods given below for optimization refer to an important subclass of quasi-Newton methods, secant methods.[2]

Using methods developed to find extrema in order to find zeroes is not always a good idea, as the majority of the methods used to find extrema require that the matrix that is used is symmetrical. While this holds in the context of the search for extrema, it rarely holds when searching for zeroes. Broyden's "good" and "bad" methods are two methods commonly used to find extrema that can also be applied to find zeroes. Other methods that can be used are the column-updating method, the inverse column-updating method, the quasi-Newton least squares method and the quasi-Newton inverse least squares method.

More recently quasi-Newton methods have been applied to find the solution of multiple coupled systems of equations (e.g. fluid–structure interaction problems or interaction problems in physics). They allow the solution to be found by solving each constituent system separately (which is simpler than the global system) in a cyclic, iterative fashion until the solution of the global system is found.[2] [3]

Search for extrema: optimization

The search for a minimum or maximum of a scalar-valued function is nothing else than the search for the zeroes of the gradient of that function. Therefore, quasi-Newton methods can be readily applied to find extrema of a function. In other words, if

g

is the gradient of

f

, then searching for the zeroes of the vector-valued function

g

corresponds to the search for the extrema of the scalar-valued function

f

; the Jacobian of

g

now becomes the Hessian of

f

. The main difference is that the Hessian matrix is a symmetric matrix, unlike the Jacobian when searching for zeroes. Most quasi-Newton methods used in optimization exploit this property.

In optimization, quasi-Newton methods (a special case of variable-metric methods) are algorithms for finding local maxima and minima of functions. Quasi-Newton methods are based on Newton's method to find the stationary point of a function, where the gradient is 0. Newton's method assumes that the function can be locally approximated as a quadratic in the region around the optimum, and uses the first and second derivatives to find the stationary point. In higher dimensions, Newton's method uses the gradient and the Hessian matrix of second derivatives of the function to be minimized. In quasi-Newton methods the Hessian matrix does not need to be computed. The Hessian is updated by analyzing successive gradient vectors instead. Quasi-Newton methods are a generalization of the secant method to find the root of the first derivative for multidimensional problems. In multiple dimensions the secant equation is under-determined, and quasi-Newton methods differ in how they constrain the solution, typically by adding a simple low-rank update to the current estimate of the Hessian.

The first quasi-Newton algorithm was proposed by William C. Davidon, a physicist working at Argonne National Laboratory. He developed the first quasi-Newton algorithm in 1959: the DFP updating formula, which was later popularized by Fletcher and Powell in 1963, but is rarely used today. The most common quasi-Newton algorithms are currently the SR1 formula (for "symmetric rank-one"), the BHHH method, the widespread BFGS method (suggested independently by Broyden, Fletcher, Goldfarb, and Shanno, in 1970), and its low-memory extension L-BFGS. The Broyden's class is a linear combination of the DFP and BFGS methods.

The SR1 formula does not guarantee the update matrix to maintain positive-definiteness and can be used for indefinite problems. The Broyden's method does not require the update matrix to be symmetric and is used to find the root of a general system of equations (rather than the gradient) by updating the Jacobian (rather than the Hessian).

One of the chief advantages of quasi-Newton methods over Newton's method is that the Hessian matrix (or, in the case of quasi-Newton methods, its approximation)

B

does not need to be inverted. Newton's method, and its derivatives such as interior point methods, require the Hessian to be inverted, which is typically implemented by solving a system of linear equations and is often quite costly. In contrast, quasi-Newton methods usually generate an estimate of

B-1

directly.

As in Newton's method, one uses a second-order approximation to find the minimum of a function

f(x)

. The Taylor series of

f(x)

around an iterate is

f(xk+\Deltax)f(xk)+\nabla

T
f(x
k)

\Deltax+

1
2

\DeltaxTB\Deltax,

where (

\nablaf

) is the gradient, and

B

an approximation to the Hessian matrix.[4] The gradient of this approximation (with respect to

\Deltax

) is

\nablaf(xk+\Deltax)\nablaf(xk)+B\Deltax,

and setting this gradient to zero (which is the goal of optimization) provides the Newton step:

\Deltax=-B-1\nablaf(xk).

The Hessian approximation

B

is chosen to satisfy

\nablaf(xk+\Deltax)=\nablaf(xk)+B\Deltax,

which is called the secant equation (the Taylor series of the gradient itself). In more than one dimension

B

is underdetermined. In one dimension, solving for

B

and applying the Newton's step with the updated value is equivalent to the secant method. The various quasi-Newton methods differ in their choice of the solution to the secant equation (in one dimension, all the variants are equivalent). Most methods (but with exceptions, such as Broyden's method) seek a symmetric solution (

BT=B

); furthermore, the variants listed below can be motivated by finding an update

Bk+1

that is as close as possible to

Bk

in some norm; that is,

Bk+1=\operatorname{argmin}B\|B-Bk\|V

, where

V

is some positive-definite matrix that defines the norm. An approximate initial value

B0=\betaI

is often sufficient to achieve rapid convergence, although there is no general strategy to choose

\beta

.[5] Note that

B0

should be positive-definite. The unknown

xk

is updated applying the Newton's step calculated using the current approximate Hessian matrix

Bk

:

\Deltaxk=-\alphak

-1
B
k

\nablaf(xk)

, with

\alpha

chosen to satisfy the Wolfe conditions;

xk+1=xk+\Deltaxk

;

\nablaf(xk+1)

, and

yk=\nablaf(xk+1)-\nablaf(xk)

is used to update the approximate Hessian

Bk+1

, or directly its inverse

Hk+1=

-1
B
k+1
using the Sherman–Morrison formula.

Bk

is positive-definite, and

\alphak

is chosen to satisfy the Wolfe conditions, then

Bk+1

is also positive-definite.

The most popular update formulas are:

Method

\displaystyleBk+1=

Hk+1

-1
=B
k+1

=

BFGS

Bk+

y
T
y
k
k
T
y\Deltaxk
k

-

B\Deltaxk(Bk\Delta
T
x
k)
k
\Delta
T
x
k
Bk\Deltaxk

\left(I-

\Deltaxk
T
y
k
T
y\Deltaxk
k

\right)Hk\left(I-

y\Delta
T
x
k
k
T
y\Deltaxk
k

\right)+

\Deltaxk\Delta
T
x
k
T
y\Deltaxk
k
Broyden

Bk+

yk-Bk\Deltaxk
\Delta
T
x
k
\Deltaxk

\Delta

T
x
k

Hk+

(\Deltaxk-Hkyk)\Delta
T
x
k
Hk
\Delta
T
x
k
Hkyk
Broyden family

(1-\varphik)

BFGS
B
k+1

+\varphik

DFP,
B
k+1

\varphi\in[0,1]

DFP

\left(I-

y\Delta
T
x
k
k
T
y\Deltaxk
k

\right)Bk\left(I-

\Deltaxk
T
y
k
T
y\Deltaxk
k

\right)+

y
T
y
k
k
T
y\Deltaxk
k

Hk+

\Deltaxk\Delta
T
x
k
\Delta
T
x
k
yk

-

Hyk
T
y
k
Hk
k
T
yHkyk
k
SR1

Bk+

(y-Bk\Deltaxk)(yk-Bk\Delta
T
x
k)
k
(y-Bk\Delta
T
x
k)
\Deltaxk
k

Hk+

(\Deltaxk-Hkyk)(\Deltaxk-Hk
T
y
k)
(\Deltaxk-Hk
T
y
k)
yk

Other methods are Pearson's method, McCormick's method, the Powell symmetric Broyden (PSB) method and Greenstadt's method.

Relationship to matrix inversion

When

f

is a convex quadratic function with positive-definite Hessian

B

, one would expect the matrices

Hk

generated by a quasi-Newton method to converge to the inverse Hessian

H=B-1

. This is indeed the case for the class of quasi-Newton methods based on least-change updates.[6]

Notable implementations

Implementations of quasi-Newton methods are available in many programming languages.

Notable open source implementations include:

Notable proprietary implementations include:

See also

Further reading

Notes and References

  1. Book: Broyden, C. G. . Quasi-Newton Methods . Numerical Methods for Unconstrained Optimization . W. . Murray . London . Academic Press . 1972 . 87–106 . 0-12-512250-0 .
  2. Web site: Haelterman . Rob . Analytical study of the Least Squares Quasi-Newton method for interaction problems . 2009 . PhD Thesis, Ghent University . 2014-08-14 .
  3. Rob Haelterman . Dirk Van Eester . Daan Verleyen . Accelerating the solution of a physics model inside a tokamak using the (Inverse) Column Updating Method . Journal of Computational and Applied Mathematics . 279 . 2015 . 133–144 . 10.1016/j.cam.2014.11.005 . free.
  4. Web site: Introduction to Taylor's theorem for multivariable functions - Math Insight. mathinsight.org. November 11, 2021.
  5. Book: Nocedal . Jorge . Wright . Stephen J. . 2006 . 142 . Numerical Optimization . limited . New York . Springer . 0-387-98793-2 .
  6. Robert Mansel Gower . Peter Richtarik . Randomized Quasi-Newton Updates are Linearly Convergent Matrix Inversion Algorithms . 2015 . 1602.01768. math.NA .
  7. Web site: optim function - RDocumentation. 2022-02-21. www.rdocumentation.org. en.
  8. Web site: Scipy.optimize.minimize — SciPy v1.7.1 Manual.
  9. Web site: Unconstrained Optimization: Methods for Local Minimization—Wolfram Language Documentation. 2022-02-21. reference.wolfram.com.
  10. Web site: The Numerical Algorithms Group . Keyword Index: Quasi-Newton . NAG Library Manual, Mark 23 . 2012-02-09 .
  11. Web site: The Numerical Algorithms Group . E04 – Minimizing or Maximizing a Function . NAG Library Manual, Mark 23 . 2012-02-09 .
  12. Web site: Find minimum of unconstrained multivariable function - MATLAB fminunc.
  13. Web site: Constrained Nonlinear Optimization Algorithms - MATLAB & Simulink. 2022-02-21. www.mathworks.com.