Numerical solution of equations — practice questions
Practice and worked examples for 9709 Numerical solution of equations. Short previews only — attempt the full question in MarkScheme against the official scheme.
Worked example 1
Show that the equation e2x−5x−3=0 has a root between x=1 and x=2.
Show solution outline
Let f(x)=e2x−5x−3.
To show a root exists between 1 and 2, we evaluate f(1) and f(2).
For x=1:
f(1)=e2(1)−5(1)−3=e2−8≈7.389−8=−0.611
For x=2:
f(2)=e2(2)−5(2)−3=e4−10−3=e4−13≈54.598−13=41.598
We have f(1)<0 and f(2)>0.
Since the function f(x) is continuous and there is a change of sign in the interval [1,2], there must be at least one root between x=1 and x=2.
Worked example 2
The equation x3+x−5=0 has a root α.
(i) Show that α lies between 1 and 2.
(ii) Show that the equation can be rearranged into the form x=35−x.
(iii) Use the iterative formula xn+1=35−xn with x0=1.5 to find α correct to 3 decimal places.
Show solution outline
(i) Let f(x)=x3+x−5.
f(1)=13+1−5=−3f(2)=23+2−5=8+2−5=5
Since f(x) is continuous and there is a change of sign between x=1 and x=2, a root lies in the interval (1,2).
(ii) Start with the original equation:
x3+x−5=0x3=5−xx=35−x
(iii) Using the iterative formula xn+1=35−xn with x0=1.5.
x0=1.5x1=35−1.5=33.5≈1.518294x2=35−1.518294≈1.515993x3=35−1.515993≈1.516328x4=35−1.516328≈1.516281x5=35−1.516281≈1.516288
The values are converging. Both x4 and x5 round to 1.516.
To be certain, we can check the sign change around this value.
Let's check the interval [1.5155,1.5165].
f(1.5155)=(1.5155)3+1.5155−5≈−0.0051f(1.5165)=(1.5165)3+1.5165−5≈+0.0054
There is a sign change, so the root lies in this interval. Therefore, the root α=1.516 correct to 3 decimal places.