- Level: AS and A Level
- Subject: Maths
- Word count: 3206
Solving Equations Using Numerical Methods
Extracts from this document...
Introduction
Solving Equations Using Numerical Methods
Numerical methods are used for solving equations which can’t be solved with algebra. Quadratics would not need to use numerical methods as an accurate answer can be found using factorisation or by using the quadratic formula. I will be using numerical methods to solve cubic equations that have decimal answers. I will be using three methods in this coursework; ‘Decimal Search’, ‘Newton-Raphson’ and ‘Graphical Convergence’.
Decimal Search
This method solves the equation by looking for a change of sign. We know that the root of the equation that we are looking for is in between the 2 numbers that the change of sign occurs in. We then repeat the same process as before but this time to a greater level of accuracy. When I have done this process to the level of accuracy required, I will be able to tell where the root of the angle is.
I will now solve an equation using the decimal search method. The equation I will be using is y=x³-2x+0.5
I will be trying to find this root using decimal search. I will start with the integer immediately below the root (-2) and this will be the lower bound. I will find the values of f(x) for this and consecutive increments of 0.1 until a change of sign is found. Here is my table of values.
From this table, I can see that the change in sign appears in between -1.6 and -1.5. To be certain that the root is between -1.6 and -1.5, I will calculate f(x) in each case to make sure that a change of sign occurs.
F(x) = y=x³-2x+0.5
F(-1. 6) = -0.39
F(-1. 5) = 0.125
Middle
Xn
1
0
2
0.1667
3
0.1683
4
0.1683
This is the tangent that is
drawn when using this method.
It has found the 2nd root to be 0.1683
3rd Root – My first estimate will be 2.
n | Xn |
1 | 2 |
2 | 1.722 |
3 | 1.647 |
4 | 1.642 |
5 | 1.642 |
This is the tangent that is drawn when using this method. The last number inputted was the same as the last number outputted which means that this is a root.
F(x) = x3 -3x+0.5 The change of sign here confirms
F(1.6415) = -0.00144 the accuracy of the root.
F(1.6425) = 0.00365
The root is 1.6425 (to 3dp)
Although I have successfully found all three roots using the Newton-Raphson method, sometimes this method fails to find the roots. I will now show an example of the Newton-Raphson method failing and find out why it fails. I will use the equation y=3x³-9x+2.
I will try to find either the 2nd root or the 3rd root using the Newton-Raphson method. My starting value will be 1 as it is near both roots so I expect to get one of them. When I use the method, a tangent gets drawn to the curve but then the gradient is 0 and the next tangent is a horizontal line. As this is the case, it can’t find the next root as the horizontal line continues forever and an overflow is created meaning that it will never reach the x-axis so it won’t create a tangent back to the curve.
This shows that an overflow is created as a tangent can’t be drawn back to the x-axis as the previous tangent is a horizontal line and therefore will never reach the x-axis, continuing forever and causing an overflow.
Graphical Convergence
The Graphical Convergence is, like Newton-Raphson, is a ‘Fixed Point’ estimation method as you chose a single value as your estimate for the root, rather than an interval in which the root lies. The Graphical Convergence method is an iterative process as it generates a sequence of numbers by continuous repetition of the rearranged formula. The formula is found by rearranging the starting equation that you wish to solve. The rearranged formula is plotted on a graph along with the line x=y. Where the curve and the line cross is the root of the original equation. The estimate at the start of the process will be used to draw a tangent from the x=y line to the curve and then continues drawing tangents until the root is found.
I will now solve an equation using the Graphical Convergence method. The equation I will be using is y=x³-4x+0.5. (shown below)
I will now rearrange my equation so I can use it as an iterative formula. The rearrangement is . From the graph below, you can see that the roots of the original equation (shown in red) are the same as where the formula and the line x=y cross.
I will now try and find the middle root. My starting estimate will be 0.The computer draws a tangent between the line y=x and y=(x³+0.5)/4. The first tangent is between the two lines at 1 that was the starting number that I chose. It then draws a horizontal line to the y=x line and then continues to draw vertical and horizontal lines until finding the root to the required level of accuracy. I will know when a root has been found as the number outputted from the formula will be the same as the last number inputted. Here is the table of results and the graph with the tangents.
n | Xn |
1 | 0 |
2 | 0.125 |
3 | 0.1255 |
4 | 0.1255 |
Conclusion
When using a computer program, I think that the best method is Newton-Raphson. This is because you do not need to rearrange any equations yourself as the program will do it all for you. The only thing you need to do is to enter a starting value and the program will draw the tangents and give you a final root to the required accuracy. No calculations are needed so this proves a very fast method. The Graphical Convergence method is also quicker when using a computer as it also draws all your tangents and gives you the overall root. The reason that I think Newton-Raphson is better is that for Graphical Convergence you need to rearrange your own equation which can take some time if it is a difficult one. You then need to draw three equations onto a graph whereas Newton-Raphson only requires one curve on the graph. The Decimal Search method is speeded up when using a computer but it doesn’t have that much of an impact compared to the other two methods as only the calculations are done for you and these can be done with ease anyway.
Overall I think that the best method to use is Newton-Raphson as it rarely fails and this is mainly due to a poor starting value. It is very fast when using a computer and it is more reliable than Graphical convergence. Although Graphical Convergence can converge rapidly to a high degree of accuracy, it has a high failure rare and extra calculations are needed to find the error bounds. If a computer is available, you should use the Newton-Raphson method and if not the Decimal Search should be used.
This student written piece of work is one of many that can be found in our AS and A Level Core & Pure Mathematics section.
Found what you're looking for?
- Start learning 29% faster today
- 150,000+ documents available
- Just £6.99 a month