introduction this chapter gives you several methods which can be used to solve complicated equations...
TRANSCRIPT
Numerical solutions of equations
Introduction
β’ This chapter gives you several methods which can be used to solve complicated equations to given levels of accuracy
β’ These are similar to methods which computers and calculators will use, and hence can be used in computer programming
Teachings for Exercise 2A
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using interval
bisection
Interval bisection is a variation on Trial and Improvement which you will have
seen at GCSE level
Interval Bisection is an iterative process which allows us to find a root to whatever degree of accuracy we wish (usually 1-2 decimal places!)
An iterative process is one which is a short set of instructions which are then
repeated as many times as needed
As a result such processes can be used in computers and calculators so
they can solve equations
2A
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using interval
bisection
Use Interval Bisection to find β11 to 1 decimal place
Set this up as an equation:
2A
π₯=β11π₯2=11
π₯2β11=0
Square both sides
Subtract 11
π (π₯ )=π₯2β11
π (3 )=(3)2β11
ΒΏβ2
π (4 )=(4)2β11
ΒΏ5
Sub in integers until we find a change of sign
So an solution lies between 3 and 4
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using interval bisection
Use Interval Bisection to find β11 to 1 decimal place
So a solution lies between 3 and 4.
Now we set up a table, subbing these 2 values into f(x), as well as
the midpoint of these
When you have found the midpoint and substituted it in, choose the positive and negative answers
closest to 0
The answer will be between these. Now repeat the process for these 2
numbers
2A
π (π₯ )=π₯2β11
π (π+ππ )π+π
ππ ππ (π) π (π)
3 4 3.5β2 5 1.25
π (π₯ )=π₯2β11
3 3.5 1.25β2 3.25 β0.438
3.25 β0.438 3.5 1.25 3.375 0.391
3.25 β0.438 3.375 0.3913.3125β0.027
3.3125β0.027 3.375 0.3913.343750.181
Our answer must be between 3.3125 and 3.34375
To one decimal place, the answer therefore must be 3.3!
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using interval
bisection
Show that a root of the equation:
lies between 0 and 1
Use interval bisection 4 times to find an approximation for this root
2A
π₯3β5 π₯+3=0
π (π₯ )=π₯3β5 π₯+3
π (0 )=(0)3β5(0)+3
ΒΏ3
π (1 )=(1)3β5(1)+3
ΒΏβ1
Sub in 0 and 1 to show the sign of
the answer changes
As the sign has changed, a solution must lie between 0 and 1β¦
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using interval
bisection
Show that a root of the equation:
lies between 0 and 1
Use interval bisection 4 times to find an approximation for this root
2A
π₯3β5 π₯+3=0
π (π+ππ )π+π
ππ ππ (π) π (π)
0 1 0.53 β1 0.625
π (π₯ )=π₯3β5 π₯+3
0.5 0.625 1 β1 0.75β0.328
0.75β0.3280.5 0.625 0.6250.119
0.6250.1190.75β0.3280.6875β0.113
Our approximation is the final bisection
0.6875 (or round if necessary)
Teachings for Exercise 2B
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
In linear interpolation, you first draw a sketch of the function between 2
intervals
Then, you draw a straight line between the interval coordinates (this will be a rough approximation to the
curve
You can then use similar triangles to find the place the straight line crosses
the x-axis (the βrootβ as it were)
You then update the interval and repeat the processβ¦
2B
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
π (π₯ )=π₯3+4 π₯β9
π (1 )=(1)3+4 (1 )β9
ΒΏβ4
π (2 )=(2)3+4 (2 )β9
ΒΏ7
Sub in 1 and 2 to show the sign of
the answer changes
As the sign has changed, a solution must lie between 1 and 2β¦
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
π (π₯ )=π₯3+4 π₯β9
π (1 )=β4π (2 )=7
Now sketch the graph between x = 1 and x = 2 (the limits you were given)
It does not have to be really accurate!
(1,-4)
(2,7)
After sketching the graph between the limits, draw a straight line between them
The place this crosses the x-axis is an approximation for the root
You can call it x and then use similar triangles to find its value
xx
y
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
(1,-4)
(2,7)
xx
y
4
7
x-1 2-x
Imagine creating triangles using the x-axis and the coordinates marked
Label the sides, using x as the place the straight line crosses the x-axis
These two triangles are similar β ie) They have the same angles (both have a right angle and two other pairs that are the same β you can see this from the vertically opposite angles at the centre and the βalternateβ angles ta the top and bottom!)
In similar triangles, a long side divided by a shorter side will give the same answer (provided that equivalent sides are used!)
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
(1,-4)
(2,7)
xx
y
4
7
x-1 2-x
π₯β14
=2β π₯7
7π₯β728
=8β4 π₯28
7 π₯β7=8β4 π₯
11π₯=15
π₯=1511
(1.3636β¦)
Short side Γ· longer side in each triangle gives the same answerβ¦
Multiply the whole left by 7 and the whole right by 4
Multiply by 28 to leave the
numeratorsAdd 4x, Add 7
Divide by 11
So the value of x is 15/11 or 1.3636β¦
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
(1,-4)
(2,7)
xx
y
4
7
x-1 2-x
So the value of x is 15/11 or 1.3636β¦
15/11
π (π₯ )=π₯3+4 π₯β9
π ( 1511 )=( 1511 )3
+4 ( 1511 )β9π ( 1511 )=β1.009767β¦β¦
Sub in 15/11 to find the value on the curve at this
point
Calculate
(15/11,-1.009β¦.)
We now repeat the process from this new pointβ¦
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
(2,7)
x
y
(15/11,-1.009β¦.)
As you can see, the new estimate for the root is closer than the first approximation
Repeat the process using these new values (strictly speaking the original estimate was x1, and this one is x2 β use this notation when you solve these problems!)
x
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using linear
interpolation
A solution of the equation:
lies in the interval [1,2]. Use linear interpolation to find this root, correct
to one decimal place.
2B
π₯3+4 π₯β9=0
(2,7)
x
y
(15/11,-1.009β¦.)
x
7
1.009β¦
x-15/11 2-x
π₯β1511
1.009β¦=2β π₯7
7 (π₯β 1511 )=1.009 (2βπ₯ )
7 π₯β10511
=2.018β1.009 π₯
8.009 π₯=11.563β¦
π₯=1.4438
Cross-multiply
Expand brackets
Rearrange
Solve
Repeat this process several times until your answer is accurate to the requested
degree Try to be as accurate as possible at
each stage, avoiding rounding too much
Draw a new sketch at each stage Use x1, x2, x3 to represent each
approximation!
Teachings for Exercise 2C
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
The Newton-Raphson formula is as follows:
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
Our current approximation for
the root
Our next approximation for
the root
The function we are solving, with our current
approximation substituted in
The derivative of the function we are solving,
with our current approximation substituted
in
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
Use the Newton-Raphson process to find the root of the equation:
Use x0 = 3 and give your answer to 2 decimal places.
Find the function and its derivative firstβ¦
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯4+π₯2=80
π₯4+π₯2=80
π₯4+π₯2β80=0
π (π₯ )=π₯4+π₯2β80
π β² (π₯ )=4 π₯3+2π₯
Rearrange
Differentiate
π (π₯ )=π₯4+π₯2β80
π β² (π₯ )=4 π₯3+2π₯π₯0=3
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
Use the Newton-Raphson process to find the root of the equation:
Use x0 = 3 and give your answer to 2 decimal places.
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯4+π₯2=80
π (π₯ )=π₯4+π₯2β80
π β² (π₯ )=4 π₯3+2π₯π₯0=3
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯1=π₯0β(π₯0 )4+(π₯0 )2β80 4 (π₯0 )3+2 (π₯0 )
π₯1=3β(3 )4+(3 )2β80 4 (3 )3+2 (3 )
π₯1=2.912
π₯1=2.912
Our current approximation is x0, replace the fraction with equivalent expressions
Sub in x0 = 3
Calculate
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
Use the Newton-Raphson process to find the root of the equation:
Use x0 = 3 and give your answer to 2 decimal places.
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯4+π₯2=80
π (π₯ )=π₯4+π₯2β80
π β² (π₯ )=4 π₯3+2π₯π₯0=3
π₯2=π₯1β(π₯1 )4+(π₯1 )2β80 4 (π₯1 )3+2 (π₯1 )
π₯2=2.912β(2.912 )4+ (2.912 )2β80 4 (2.912 )3+2 (2.912 )
π₯2=2.908β¦
π₯1=2.912
Sub in x1 = 2.912
Calculate
Repeat the process, but now we use the value of x1 to find x2
π₯2=2.908β¦
As both x1 and x2 round to 2.91, then this is the solution to 2 decimal
places!
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
Use the Newton-Raphson process twice to find approximate a root of
the equation:
Use x0 = 2 as your first approximation and give your answer to 3 decimal places.
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯3+2π₯2β5π₯β4=0
π (π₯ )=π₯3+2π₯2β5 π₯β4
π β² (π₯ )=3 π₯2+4 π₯β5Differentiate
π (π₯ )=π₯3+2π₯2β5 π₯β4
π β² (π₯ )=3 π₯2+4 π₯β5π₯0=2
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
Use the Newton-Raphson process twice to find approximate a root of
the equation:
Use x0 = 2 as your first approximation and give your answer to 3 decimal places.
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯3+2π₯2β5π₯β4=0
π (π₯ )=π₯3+2π₯2β5 π₯β4
π β² (π₯ )=3 π₯2+4 π₯β5π₯0=2
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯1=π₯0β(π₯0)
3+2 (π₯0 )2β5 (π₯0 )β4 3 (π₯0 )2+4 (π₯0 )β5
π₯1=2β(2)3+2 (2 )2β5 (2 )β4 3 (2 )2+4 (2 )β5
π₯1=1.866β¦
π₯1=1.866β¦
Sub in x0 as our first
approximation and replace
the parts of the fraction
Sub in x0 = 2
Calculate
Numerical solutions of equations
You can solve equations of the form f(x) = 0 using the
Newton-Raphson process
Use the Newton-Raphson process twice to find approximate a root of
the equation:
Use x0 = 2 as your first approximation and give your answer to 3 decimal places.
2C
π₯π+1=π₯πβπ (π₯π )π β² (π₯π)
π₯3+2π₯2β5π₯β4=0
π (π₯ )=π₯3+2π₯2β5 π₯β4
π β² (π₯ )=3 π₯2+4 π₯β5π₯0=2
π₯2=π₯1β(π₯1)
3+2 (π₯1 )2β5 (π₯1 )β4 3 (π₯1 )2+4 (π₯1 )β5
π₯2=1.866β(1.866)3+2 (1.866 )2β5 (1.866 )β4
3 (1.866 )2+4 (1.866 )β5
π₯2=1.8558 . .
π₯1=1.866β¦
Sub in x1 =
1.866
Calculate
π₯2=1.856 (3ππ)
It is important to note that the Newton-Raphson method will not always work, sometimes tending
away from a root rather than towards it
Usually, choosing a different first approximation will correct this!
Summary
β’ You have learnt several iterative methods for solving equations
β’ Although these may seem cumbersome, the ideas involved in these are used in computers and calculators
β’ They will also work when other methods fail to find answers!
2C