Numerical Computing I, Spring 2018 Homework 1. Due on Jan. 28 In this homework, we study the convergence of Interval Bisection Method, Newton’s method, and the globally convergent Newton’s Method for...

I need help with newton's method, bisection method, and fixed point. my assignment is attached


Numerical Computing I, Spring 2018 Homework 1. Due on Jan. 28 In this homework, we study the convergence of Interval Bisection Method, Newton’s method, and the globally convergent Newton’s Method for solving a nonlinear equation of one variable. 1. First use the MATLAB built-in function fzero to find the solution of the nonlinear equation e2 sin(x) − x = 0. (1) Plot the function y = e2 sin(x) − x on the interval x ∈ [−10, 10]. Write a MATLAB function which returns the function value f(x) = e2 sin(x) − x and its derivative (if needed; see nargout in MATLAB) for a given input x. 2. Write a MATLAB function which implements the Interval Bisection method to solve (1). In the implementation, you can choose the initial interval as, for example, [−8, 8]. The iteration can be stopped when |f(xk)| ≤ 10−12, at iterate xk. To evaluate the function value f(x), call the function written in Question 1. Does the interval Bisection Method find the same root as obtained from fzero? 3. Write a MATLAB function to implement the Fixed Point Method to solve (1). Remember that the method finds a value in which x = f(x). The stopping criterion is also |f(xk)| ≤ 10−12. 4. Write a MATLAB function to implement Newton’s Method to solve (1). The stopping criterion is also |f(xk)| ≤ 10−12. In the algorithm, both the function value and its derivative are needed, which can be obtained by using the function written in Question 1. Experiment different initial guesses in Newton’s Method, e.g., x0 = −6,−4,−2, 0, 2, 4, 6, and discuss how the convergence depends on the initial guess. 5. Write a MATLAB function to implement the globally convergent Newton’s Method to solve (1). In this algorithm, Newton’s Method needs to be combined with the Interval Bisection Method, as discussed in the lecture. In the implementation, an initial interval, e.g., [−8, 8], needs be provided. The initial guess x0 can be taken either as the left or the right end point of the initial interval. Does this algorithm improve the convergence significantly compared with the original Newton’s Method in Question 3, for certain initial guesses used there? 6. Adjust the above functions such that for each of the four methods, you save the errors |ek| for all the iterates into a vector. Draw the four error vectors for the four algorithms, respectively, in the same graph. Generate such graphs corresponding to different initial guesses used in the Newton’s method, e.g., x0 = −6,−4,−2, 0, 2, 4, 6, as done in Question 3, respectively. From those graphs, what can you say about the performances of the three algorithms? Which algorithm is both robust and fast? 1
Jan 23, 2021
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here