ArticleslgStudy

computer science

Nonlinear conjugate gradient method

Nonlinear conjugate gradient method is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Nonlinear conjugate gradient method rather than just read about it. In short: In numerical optimization, the nonlinear conjugate gradient method generalizes the conjugate gradient method to nonlinear optimization. For a quadratic function f(x) f(x)=‖Ax−b‖2, the minimum of f is obtained when the gradient is 0: ∇xf=2AT(Ax−b)=0.

Key takeaways

  • Nonlinear conjugate gradient method belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Nonlinear conjugate gradient method to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Nonlinear conjugate gradient method from memory before moving on to harder problems.

Reference excerpt

In numerical optimization, the nonlinear conjugate gradient method generalizes the conjugate gradient method to nonlinear optimization. For a quadratic function f(x)

f(x)=‖Ax−b‖2, the minimum of f is obtained when the gradient is 0:

∇xf=2AT(Ax−b)=0. Whereas linear conjugate gradient seeks a solution to the linear equation ATAx=ATb, the nonlinear conjugate gradient method is generally used to find the local minimum of a nonlinear function using its gradient ∇xf alone. It works when the function is approximately quadratic near the minimum, which is the case when the function is twice differentiable at the minimum and the second derivative is non-singular there. Given a function f(x) of N variables to minimize, its gradient ∇xf indicates the direction of maximum increase. One simply starts in the opposite (steepest descent) direction:

Δx0=−∇xf(x0) with an adjustable step length α and performs a line search in this direction until it reaches the minimum of f:

α0:=arg⁡minαf(x0+αΔx0), x1=x0+α0Δx0 After this first iteration in the steepest direction Δx0, the following steps constitute one iteration of moving along a subsequent conjugate direction sn, where s0=Δx0:

Calculate the steepest direction: Δxn=−∇xf(xn), Compute βn according to one of the formulas below, Update the conjugate direction: sn=Δxn+βnsn−1 Perform a line search: optimize αn=arg⁡minαf(xn+αsn), Update the position: xn+1=xn+αnsn, With a pure quadratic function the minimum is reached within N iterations (excepting roundoff error), but a non-quadratic function will make slower progress. Subsequent search directions lose conjugacy requiring the search direction to be reset to the steepest descent direction at least every N iterations, or sooner if progress stops. However, resetting every iteration turns the method into steepest descent. The algorithm stops when it finds the minimum, determined when no progress is made after a direction reset (i.e. in the steepest descent direction), or when some tolerance criterion is reached. Within a linear approximation, the parameters α and β are the same as in the linear conjugate gradient method but have been obtained with line searches. The conjugate gradient method can follow narrow (ill-conditioned) valleys, where the steepest descent method slows down and follows a criss-cross pattern. Four of the best known formulas for βn are named after their developers:

Fletcher–Reeves: βnFR=ΔxnTΔxnΔxn−1TΔxn−1. Polak–Ribière: βnPR=ΔxnT(Δxn−Δxn−1)Δxn−1TΔxn−1. Hestenes–Stiefel: βnHS=ΔxnT(Δxn−Δxn−1)−sn−1T(Δxn−Δxn−1). Dai–Yuan: βnDY=ΔxnTΔxn−sn−1T(Δxn−Δxn−1).. These formulas are equivalent for a quadratic function, but for nonlinear optimization the preferred formula is a matter of heuristics or taste. A popular choice is β=max⁡{0,βPR}, which provides a direction reset automatically. Algorithms based on Newton's method potentially converge much faster. There, both step direction and length are computed from the gradient as the solution of a linear system of equations, with the coefficient matrix being the exact Hessian matrix (for Newton's method proper) or an estimate thereof (in the quasi-Newton methods, where the observed change in the gradient during the iterations is used to update the Hessian estimate). For high-dimensional problems, the exact computation of the Hessian is usually prohibitively expensive, and even its storage can be problematic, requiring O(N2) memory (but see the limited-memory L-BFGS quasi-Newton method). The conjugate gradient method can also be derived using optimal control theory. In this accelerated optimization theory, the conjugate gradient method falls out as a nonlinear optimal feedback controller, u=k(x,x˙):=−γa∇xf(x)−γbx˙ for the double integrator system, x¨=u The quantities γa>0 and γb>0 are variable feedback gains.

See also Gradient descent Broyden–Fletcher–Goldfarb–Shanno algorithm Conjugate gradient method L-BFGS (limited memory BFGS) Nelder–Mead method Wolfe conditions

References

Worked examples

Example 1 — a first encounter with Nonlinear conjugate gradient method

Start with the simplest possible case. Write down what Nonlinear conjugate gradient method claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Nonlinear conjugate gradient method before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Nonlinear conjugate gradient method ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Nonlinear conjugate gradient method

In research
Nonlinear conjugate gradient method appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Nonlinear conjugate gradient method in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Nonlinear conjugate gradient method is common in secondary-school and first-year university syllabi. It links to neighbouring topics Gradient methods, Optimization algorithms and methods, so understanding it makes those chapters shorter.
In everyday life
Look for Nonlinear conjugate gradient method outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Nonlinear conjugate gradient method” →

How to study Nonlinear conjugate gradient method in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Nonlinear conjugate gradient method means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Nonlinear conjugate gradient method out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Nonlinear conjugate gradient method in simple terms?

In numerical optimization, the nonlinear conjugate gradient method generalizes the conjugate gradient method to nonlinear optimization. For a quadratic function f(x) f(x)=‖Ax−b‖2, the minimum of f is obtained when the gradient is 0: ∇xf=2AT(Ax−b)=0.

Why does Nonlinear conjugate gradient method matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Nonlinear conjugate gradient method?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Nonlinear conjugate gradient method.

Tags

  • Gradient methods
  • Optimization algorithms and methods

Keep exploring