Professional Documents
Culture Documents
1. (50 points) Consider finding the root of the function f (x) = e2x − 1 − 2x.
f (xi )
(a) Using the initial guess x0 = 1, apply Newtons method given by xi+1 = xi − to find the
f 0 (xi )
root within six correct places. (Note: You can use the code provided as a part of the course or
write your own code). Include your MATLAB code and print out all intermediate steps in the
iterations as the output.
(b) Starting with an initial value x0 = 1, implement the modified Newtons method given by xi+1 =
f (xi )
xi − 2 0 to find the root within six correct places. (Note: You can modify the code provided
f (xi )
as a part of the course or write your own code). Include your MATLAB code and print out all
intermediate steps in the iterations as the output.
(c) Explain clearly your observation on the convergence of each method used respectively in parts
(a) and (b). Which one converges faster and why? Explain your reasoning with mathematical
details.
2. (60 points) Consider the following iterative method to find the root of the equation f (x) = 0 starting
with an initial guesses x0 and x1 :
f (xk )
xk+1 = xk −
h(xk , xk−1 ) + g(xk , xk−1 )
where,
f 0 (xk ) f (xk−1 ) f (xk )
h(xk , xk−1 ) = g(xk , xk−1 ) =
f (xk−1 ) − f (xk ) xk − xk−1
(a) Write a MATLAB code to implement the iterative method. Test the code for f (x) = x3 + x − 1
with an initial guess x0 = 100 and x1 = 90 with a tolerance of 1 × 10−8 for stopping criteria.
f (xk )
(b) Compare your results in part (a) with Newton’s method: xk+1 = xk − 0 for x0 = 100 with
f (xk )
a tolerance of 1 × 10−8 for stopping criteria. (Note: You can use the code provided as a part of
the course or write your own code).
(c) Explain clearly your observation on the convergence of each method used respectively in parts (a)
and (b).