Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Motivation

Despite its numerous advantages, Newton’s method suffers from two disadvantages:

Solution: We replace the Hessian matrix with an approximation Bk≈∇2f0(x(k))B_k \approx \nabla^2 f_0(x^{(k)}), leading to so-called quasi-Newton methods.

Principle of Quasi-Newton Methods

The crucial step lies in defining matrices BkB_k (or HkH_k) such that

Bk≈∇2f0(x(k))orHk≈[∇2f0(x(k))]−1B_k \approx \nabla^2 f_0(x^{(k)}) \quad \text{or} \quad H_k \approx \left[\nabla^2 f_0(x^{(k)})\right]^{-1}

often by a recursive relation (i.e., it is built on the fly, from values at previous iterations). For a given update rule, one gets a specific quasi-Newton method. Some examples are:

Many of such algorithms are implemented in standard Python libraries, such as in scipy. Check for instance the documentation of scipy.optimize.minimize function.

Example: BFGS algorithm

For details about the derivation of BFGS updates, properties of the algorithm and implementation details, one can consult Section 6.1, Nocedal & Wright, 2006.

Comparison on a non-quadratic example

To compare the BFGS algorithm with gradient descent (fixed step-size) and Newton’s method, we come back to the non-quadratic example introduced when studying step-size strategies for gradient descent

minimize⁡f0(x):=ex1+3x2−0.1+ex1−3x2−0.1+e−x1−0.1subject to⁡x∈R2\begin{array}{ll} \minimize &\quad f_0(x):=e^{x_1+3x_2 - 0.1} + e^{x_1 -3x_2 - 0.1} + e^{-x_1 - 0.1}\\ \st & \quad x \in \mathbb{R}^2 \end{array}

Let us look at how fixed step-size gradient descent and Newton’s method perform on this problem.

Source
<Figure size 800x600 with 2 Axes>

Below is a possible, non-optimized, BFGS implementation.

Let us compare how BFGS performs, starting from the same initial point and using H0=[∇2f(x(0))]−1H_0 = [\nabla^2 f(x^{(0)})]^{-1}.

Source
<Figure size 800x600 with 2 Axes>
<Figure size 800x600 with 1 Axes>

In this example, we see that BFGS does converges almost as fast as Newton’s method -- and much faster than fixed step-size gradient descent. However, unlike Newton’s method, it does not require the evaluation of the Hessian at each iteration.

References
  1. Nocedal, J., & Wright, S. J. (2006). Numerical optimization (Second Edition). Springer.