Question: MATLAB help please 1. Implement fixed-point iteration. Your signature should be function p fp(g, po, maxits) where g is a function handle and po, maxits,

 MATLAB help please 1. Implement fixed-point iteration. Your signature should be

MATLAB help please

1. Implement fixed-point iteration. Your signature should be function p fp(g, po, maxits) where g is a function handle and po, maxits, and p are numbers. The return value p is the result of maxits applications of g, i.e. p g(g g(po Test your code on the following four functions. (a) g: (x+2/x)/2 (This is the Babylonian method' for computing v2- 1.414) i. Confirm visually that the fixed-point problem "Solve g()s equivalent to the root-finding problem i. Experient with the parameters po and maxits. How can you pick pO to control which of the two ii. Try po 1.5 and compare with the bisection method (Worksheet 3) with a 1, b 2, and tol eps. *Solve f(x) = 0, with f: z r2-2. That is, make a plot showing that y-f(r) intersects y = 0 at the same z-values which y = g(x) intersects y = z. fixed points (2 the method converges to? Plot the error (abs (sqrt (2) p)) of the two methods as a function of iteration number. (You will have to modify your fp and bisection codes to return all of the iterates, not just the last.) Use a semilogy plot

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!