Change of sign method - Finding a root by using change of sign method
Pure 2 coursework
Change of sign method
Finding a root by using change of sign method
I will divide interval into a number to apply the change of sign method by using decimal search..
The two values are the new interval's two sides on the number axis and the roots must lie between these intervals.
i am going to use the following equation to find out a root.
it is clear that we can see the first interval lies on [1, 2]. Then i will use Excel.
Value
.1
.2
.3
.4
.5
.6
.7
.8
.9
2
In this method, I take increments in size 0.1 within the interval [1 , 2]
Work out each value of and see whether the value is positive or negative. In this case, I will use Microsoft Exel to solve it.
The diagram decimal research above shows how the sign change between [1.5,1.6]. Because of this, the interval of this equation will be [1.5,1.6].
The following graph can prove whether the interval is correct. I decide to use Autograph.
This graph has been zoom in from the first graph. It is very clear to see that the result is correct
Which is between[1.5,1.6].
I use the same method to keep doing decimal research. to work out a more accurate answer. Take increments in size 0.1 within the interval [1.5,1.6]
From the above we can see that must lie between [1.52,1.53].It can be very clear if I use graph.
I will do a better research this time by using the same method to prove my result is correct.
Now I can find a more accurate result from the research which lies between [1.521,.1522].
Here is a graph to prove the interval is right.
However, I will take 4 decimal places to improve the accuracy of the interval. Also I will use the same method again.
As we can see the root is between [1.5213,1.5214]
Same again. Autograph is used to prove my solution is right.
Error bounds
This is the process which check how the accuracy of the roots are.
From those 4 decimal search I have done so far, I can say that the answer is between 1.5213 and 1.5214. These can be improved the accuracy.
Assume X=1.5213 f(x)=(1.5213)^3-1.5213-2=-0.00047
X=1.5214 f(x)=(1.5214)^3-1.5214-2=0.000121
Because the answer is -0.00047<0<0.000121.
So the answer must between 1.5213 and 1.5214.
However , these are not the exact answer so I have to estimate them.
In this case, X=1.5213.5, so the error bound is .
Because this is the middle point between the interval.
Fail example by using Exel
It is not guaranteed to use this method, because there still has some problems in it.
See the graph below:
As we can see the curve touches the x axis. The ...
This is a preview of the whole essay
Assume X=1.5213 f(x)=(1.5213)^3-1.5213-2=-0.00047
X=1.5214 f(x)=(1.5214)^3-1.5214-2=0.000121
Because the answer is -0.00047<0<0.000121.
So the answer must between 1.5213 and 1.5214.
However , these are not the exact answer so I have to estimate them.
In this case, X=1.5213.5, so the error bound is .
Because this is the middle point between the interval.
Fail example by using Exel
It is not guaranteed to use this method, because there still has some problems in it.
See the graph below:
As we can see the curve touches the x axis. The root lies between 0 and 1.
I am going to use Exel program to prove it.
There is no change of sign of this equation. So we can say that the change of sign method is failed.
Newton-Raphson method
This is another fixed point estimation method, and as for the previous method it is necessary to use an estimate of the root as a starting point.
The process can be repeated to give a sequence of points x2, x3...
I am going to use the following equation.
As we can see there are 2 roots in this function.
The first root lies close to +1.But I will estimate the first root is x1 = +2.
I will show it in graphical as +2 is a starting point.
There is a technical way to do Newton-Raphson method by using Autograph.
I will do it step by step with showing the graph.
I click the curve then right click it and chook the "Newton Raphson Iteration" option.
I have entered the value that I estimated, then press the right side button. The solutions appear automatically. The answer that I got is 1.27202.
Error bound
Because my solution is 5.bp.
So the answer will be x=1.27202
The numbers that I squared shows how close to the real answer. So we can say there are some error in it.
I am going to try another root of the equation.
I have estimated the x1 = -2. As I can see from the graph, -1.27202 is the best answer I can get. Then I will check whether the solutions are correct.
The first root: X= 1.27207 1.27197
Y= 0.000286 -0.00028
.
The second root: X= -1.27197 -1.27207
Y= -0.000286 0.000286
We can see the change of sign in these boxes, so the 2 real roots must be in this error bound
Fail example
Most problems that arise with the Newton-Raphson method fall into one or other of the following 2 categories.
Poor choice of starting point. If your initial value is close enough to a root, the method will nearly always give convergence to it. However if the initial point is not close to the root or is near a turning point of y=f(x),the iteration may diverge, or converge to another root.
This is the equation that I am going to use,
As we can see there are 3 roots lie on the graph.
I start by using Newton-Raphson method to do it.
Firstly, I estimate x=3 to see whether it can work.
It is converge to 0.
If I try another equation which is
Now I am going to investigate it by using the same method.
I take x=1.5
In this case I found that after one step the value is converging rapidly, but it converges to another root.
Rearrangement f(x)=0 in the form x=g(x)
Find a root of the equation
I am going to investigate the following equation:
let the equation then rearrange it into the form.
The first step, with an equation f(x)=0,is to rearrange it into the form x=g(x).Any value of x for which x=g(x) is clearly a root of the original equation.
Can be written in this way:
The graphs of y=x and y=g(x) in this case:
From the graph above, the red line is , the blue line is y=x.
This provides the basis for the iterative formula:
I click the red curve first and then press shift while right click the blue curve:
Click "x=g(x) Iteration".
Taking =1 as a starting point to find one of the roots in the interval [0,1],
The answers are shown below:
Therefore, my answer will be 0.5055,Then I put this value into
The gradient is 0.0544 which is less than 1 and bigger than -1.
Error bound
0.5055±0.00005
Failure example
It is always possible to rearrange an equation f(x)=0 into the form x=g(x),but this only leads to a successful iteration if:
-successive iteration converge:
-they converge to the root for which you are looking for.
I am going to use the same equation to demonstrate why this root fails.
As you can see from the graph. There are 3 points on the graph, but I just investigate two of them, point A and B.
Rearrangement method only works, when the fixed points' gradient should be in the range of.
Or it can be diverged from the solution or find a root which is not objected
If I use x=1 as a starting point to find the root of point B, it gives:
It does not work at all. So we can say it has been failed by using this method.
Comparison of methods
I am going to select an equation which I used in Rearrangement method,
By using another two methods: Change of sign method and Newton-Raphson method.
Change of sign method:
As we can see from the graph above, the root lies between 0 and 1. In this method, I take increments in size 0.1 within the interval [0 , 1] by using Exel programme.
As we can see above, the root must lie between 0.5055 and 0.5056. That is the answer that I aim.
Because it is the samw answer that I got by using Rearrangement method.
Newton-Raphson method:
Because the root lies between 0 and 1, so I take x=0 as my starting point.
As we can see from the graph below, I use the same method that I did from page6-8.
x=0.5055 is my final answer. It proves that my answer is right.
Conclusion:
All three methods are successful being applied. But those methods above, the Newton-Ranhson and Rearranging method has got the same answer: 0.5055
The Change of sign method has got the answer:, [0.5055,0.50556] which is a worse answer than the answers from the Newton-Ranhson and Rearranging methods.
-I found the Newton - Raphson method is the easiest method that I have used. It can save time and the requirement is least.
-the Change of sign mehod is a good method,it is easy to set up. However, it takes a long time to find the root.
-the rearrangement method,it takes long time to set up and requires a lot of process, such as rearranging the function ,I need be careful about the gradient to see whether the tangent of the root between , and I need to care about the x coordinate of the starting point, it needs to be smaller than the x coordinate of another fix point. But this is still a good method because if I have to iterate a lot to get a reasonable result, also its iteration is faster than the Newton-Ranhson method.
Merits of the three methods:
Change of sign method is a good method because the whole process and set up is the simplest in the three methods. Its error bounds are also very easy to find out. The failure only would happen when some several roots are close together, the curve touches the x-Axis or there is a discontinuity.
I think Newton-Raphson method is the best method of these three. It can find the root with a easy set up and fast iteration. But it is not easy to find out a very accurate error bounds.
Rearranging method is the most difficult way to solve question. With a lot of requirements. Such as we need the gradient and the starting point. However, this method is the fastest method that can converge to the root. It is good to iterate a lot to get a good solution. The failure only would happen, which the point of the tangent is not between and the
Comparison of hardware and software
It is always need to draw the graph and then check carefully because all of these three methods have possibilities to make a failure.
I have used the Microsoft Excel, Change of sign method; the Autograph, Microsoft Excel for Newton-Raphson method; Autograph for Rearranging method;Microsoft Excel for Comparison of method.
I found the Autograph is the easiest method to use. It can quickly be set up and easy to use.The graph can also be shown very clearly.