The Newton-Raphson process

The Newton-Raphson process

Spec 3.1 · Edexcel International A Level Further Maths: Revision notes

Studying this course? Keep your progress in one place.

Key facts

  • Newton-Raphson: xn+1=xn−f(xn)f′(xn)x_{n+1}=x_n-\dfrac{f(x_n)}{f'(x_n)}.
  • Each step uses the tangent at xnx_n; where it meets the xx-axis is xn+1x_{n+1}.
  • It usually converges much faster than bisection.
  • It fails if f′(xn)=0f'(x_n)=0, and can reach the wrong root from a poor start.
  • Use radians for trigonometric functions.

The idea

The tangent at the current estimate meets the xx-axis closer to the root, and that point is the next estimate.

If xnx_n is an approximation, the tangent at (xn,f(xn))(x_n,f(x_n)) has gradient f′(xn)f'(x_n) and meets the xx-axis at xn+1x_{n+1}. Gradient =f(xn)−0xn−xn+1=\frac{f(x_n)-0}{x_n-x_{n+1}}, which rearranges to the formula.

It needs ff differentiable and f′(xn)≠0f'(x_n)\neq0. In IAL FP1 the functions are polynomials, ln⁡x\ln x, exe^x and trigonometric functions in radians.

1.51.61.71.81.922.12.22.32.42.52.6−4−2246810xy(2, −1)x₁ = 2.1y = x³ − 2x − 5tangent at x = 2
For f(x) = x³ − 2x − 5 the tangent at x₀ = 2 meets the x-axis at x₁ = 2.1, much closer to the root.
  • Next estimate xn+1x_{n+1}xn−f(xn)f′(xn)x_n-\dfrac{f(x_n)}{f'(x_n)}

For f(x)=x2−4f(x)=x^2-4 and x0=3x_0=3, what is x1x_1?

Applying the formula

Differentiate, write the formula, substitute the starting value and repeat, showing ff and f′f' each time.

Take f(x)=x3−2x−5f(x)=x^3-2x-5 with x0=2x_0=2. Then f′(x)=3x2−2f'(x)=3x^2-2.

The values settle quickly: Newton-Raphson converges much faster than bisection, roughly doubling the number of correct digits each step once close to the root. Use the ANS key on a calculator to keep full accuracy.

  1. 1

    Differentiate

    find f′(x)f'(x)

  2. 2

    Write the formula

    xn+1=xn−f(xn)f′(xn)x_{n+1}=x_n-\frac{f(x_n)}{f'(x_n)}

  3. 3

    Substitute

    f(xn)f(x_n) and f′(xn)f'(x_n)

  4. 4

    Repeat

    until the digits stop changing

One Newton-Raphson iteration

Worked example

Find x1x_1 and x2x_2 for f(x)=x3−2x−5f(x)=x^3-2x-5 with x0=2x_0=2.

Close to the root, what does Newton-Raphson usually do to the number of correct digits each step?

Deriving an iteration formula

Identify ff, find f′f', and substitute into the formula. Simplify only if the question asks you to show a given form.

For f(x)=cos⁡x−xf(x)=\cos x-x (radians), f′(x)=−sin⁡x−1f'(x)=-\sin x-1, so

xn+1=xn+cos⁡xn−xn1+sin⁡xn.x_{n+1}=x_n+\frac{\cos x_n-x_n}{1+\sin x_n}.

Starting from x0=1x_0=1: x1=0.7504x_1=0.7504 and x2=0.7391x_2=0.7391.

For f(x)=x2−7f(x)=x^2-7 the formula simplifies to xn+1=xn2+72xnx_{n+1}=\frac{x_n^2+7}{2x_n}.

0.20.40.60.811.21.4−1.5−1−0.50.51xyx ≈ 0.7391y = cos x − x
y = cos x − x crosses the x-axis once, at about 0.7391, the limit of the iterations from x₀ = 1.

Worked example

Show that Newton-Raphson for f(x)=x2−7f(x)=x^2-7 gives xn+1=xn2+72xnx_{n+1}=\frac{x_n^2+7}{2x_n}.

For f(x)=ex−3f(x)=e^x-3, what is f′(x)f'(x) in the formula?

When Newton-Raphson fails

It fails if f′(xn)=0f'(x_n)=0, and can reach the wrong root if x0x_0 is far from the root or near a turning point.

Choose x0x_0 close to the root, found from a sign change or sketch, and where f′f' is not small. For f(x)=x3−3x+1f(x)=x^3-3x+1, f′(1)=0f'(1)=0, so x0=1x_0=1 fails.

For f(x)=x3−4x−2f(x)=x^3-4x-2, x0=0x_0=0 converges to −0.539-0.539, not to the largest root 2.2142.214.

−2−1.5−1−0.50.511.52−4−2246xy(1, −1)y = x³ − 3x + 1tangent at x = 1
At x = 1 the curve y = x³ − 3x + 1 has a turning point, so the tangent is horizontal and never meets the x-axis.

f′(xn)=0f'(x_n)=0

  • Tangent is horizontal
  • No xn+1x_{n+1}

Poor start

  • Far away or near a turning point
  • May reach another root

Not differentiable

  • At the root
  • or ff undefined at an iterate

Why does Newton-Raphson fail for f(x)=x3−3x+1f(x)=x^3-3x+1 with x0=1x_0=1?

Try an exam question

f(x)=x3−2x−5f(x)=x^3-2x-5. Use the Newton-Raphson method with x0=2x_0=2 to find x1x_1 and x2x_2, giving x2x_2 to 4 decimal places.

[4 marks]

That's the notes covered.

Carry on to the next subtopic.

Try a question

Find f′(x)f'(x).

1 mark, marked against the mark scheme

Revision notes