Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Suppose f : R R and x0 is a given real number. Halley's Method of f starting at x0 is given by the sequence xn+1

Suppose f : R R and x0 is a given real number. Halley's Method of f starting at x0 is given by the sequence xn+1 = xn 1 for finding a root 2f (xn )f 0 (xn ) , n0 2f 0 (xn )2 f (xn )f 00 (xn ) f which This method is obtained by applying Newton's method to the function p |f 0 | has the same roots as f . Although this method requires evaluation of f 00 , which is a limitation, when it converges it does so at a faster rate than Newton's method. a. Implement a MATLAB function of the form function [Approx, Success] = HalleysMethod(f,x0 ,MaxIter,Tol) Here f is a function handle and x0 is an initial guess for a root of f. The method terminates when either it has performed MaxIter iterations or |f (Approx)| < Tol where Approx is the numerical approximation to a root of f computed by Halley's method. Success is a logical variable that returns 1 if |f (Approx)| < Tol and 0 otherwise. Hint. Use f to define a symbolic function F. Symbolically differentiate F to obtain a symbolic function dF. Use command double(dF(x)) to evaluate at a number. b. With Tol= 105 and MaxIter= 10 use Halley's method to approximate the roots of the following functions with given initial guesses. Also indicate if the method was successful or not 1. f (x) = x cos x, x0 = 4 2. f (x) = x3 x, x0 = 1/ 3 3. f (x) = 13 x3 12 x2 6x + 1, x0 = 3 4. f (x) = 5 6 21 x2 cos x, x0 = 3 5. f (x) = xex , x0 = 3/2 For part a your solution should consist of MATLAB code for the function HalleysMethod; for part b, submit your numerical results from running HalleysMethod in the command window. 1 See Wikipedia for more information on Halley's Method 1

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introduction to Real Analysis

Authors: Robert G. Bartle, Donald R. Sherbert

4th edition

471433314, 978-1118135853, 1118135857, 978-1118135860, 1118135865, 978-0471433316

More Books

Students also viewed these Mathematics questions