Question: Write a program to implement the fixed point iteration scheme xn + 1 = g ( xn ) for general g . Provide for termination
Write a program to implement the fixed point iteration scheme
xn gxn
for general g Provide for termination of the process as soon as xn xn or when n Nmax,
whichever occurs first. Your fixed point function should return the iterates xn and should print out on
the screen the values of n and xn for each n so that you can watch the progress of the iteration.
a Show by hand calculation that using gx x hF x with hF F
k for some constant
k you are solving equation
b Run your program with k x and Nmax
i Plot Analysis: Plot y gx and y x on the same graph. Identify the fixed point as the
intersection of y gx and y x On this plot:
Mark each iterate xn gxn up to the first three iterates to visualize the sequences
progression in relation to the fixed point.
Draw dashed vertical lines from each point xn xn to xn gxn
Draw dashed horizontal lines from each point xn gxn to gxn gxn
ii Convergence Assessment:
Observe the behavior of the iterates over these first three steps. Do they appear to
approach or move away from the fixed point?
Based on your observations and understanding of fixedpoint iteration, explain why con
vergence might or might not occur in this case.
c Determine the values of k for which convergence is guaranteed if xn remains in the range
d Choose, giving reasons, a value of k for which monotonic convergence should occur near the
root, and also a value for which oscillatory convergence should occur near the root. Look my
supplemental notes rootfinding part page Verify that these two values of k give the
expected behavior, by running the program with Nmax and xplease
choose values that help to illustrate the behavior clearly! Mark the iterates and draw vertical
and horizontal dashed lines like in b Adjust your viewing window so the behavior is shown
clearly
e Also run the case k and and x This should converge slowly, so set
Nmax Discuss whether the termination criterion xn xn ensures that the absolute
error, xn is less than in this case? Use formula in rootfinding part page
that gives a good approximation of the actual error, read also the corresponding slides to
understand the idea around it and how the iteration can be speed up using Aitkens extrapolation
f Discuss whether your previous convergence results for are consistent with firstorder conver
gence.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
