Question: One way to evaluate Squareroot a is to use the Newton Raphson method to find the zeros of the function f (x) = x^2 -

One way to evaluate Squareroot a is to use the Newton Raphson method to find the zeros of the function f (x) = x^2 - a, starting at x_0 = a. Use this approach to find Squareroot 472 Write MATLAB code to show how you would use the NR method to find the roots of f starting at x_0 - 472. Show how the solution proceeds by plotting of your estimate for Squareroot a as a function of iteration number. Does the process work if you start at x_0 = -472? Modify your code and using the output make a plot of the estimate of Squareroot a as a function of iteration number for this starting point. Why does the process fail if you start at x = 0? Make a plot of the of the NR iteration function as a function of x over the range [-30, 30]. g(x_n) = x_n - f(x_n)/f (x_n) Apart from x = 0, what would be bad choices of starting point for the Newton Raphson method? Why? Remember to include any codes you wrote in jour answer to question 1. Consider setting a maximum number of iterations in your code to avoid the chance that your code may get into an infinite loop. Also consider the need to test how close you are to f(x) - 0 to determine when you can stop
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
