#Sales Offer!| Get upto 25% Off:

1.A nonlinear algebraic equation f (x) = 0 may be solved in many different ways, and we have met some of these in this chapter. Another, very useful, solution approach is to first re-write the equation into x = φ(x) (this re-write is not unique), and then formulate the iteration xn+1 = φ(xn), n = 0, 1,… , with some starting value x0. If φ(x) is continuous, and if φ(xn) approaches α as xn approaches α (i.e., we get α = φ(α) as n → ∞), the iteration is called a fixed point iteration and α is referred to as a fixed point of the mapping x → φ(x). Clearly, if a fixed point α is found, α will also be a solution to the original equation f (x) = 0. In this exercise, we will briefly explore the fixed point iteration method by solving x3 + 2x = e−x, x ∈ [−2, 2] . For comparison, however, you will first be asked to solve the equation by Newton’s method (which, in fact, can be seen as fixed point iteration8).

a) Write a program that solves this equation by Newton’s method. Use x = 1 as your starting value. To better judge the printed answer found by Newton’s method, let the code also plot the relevant function on the given interval.

b) The given equation may be rewritten as x = e−x−x3 2 . Extend your program with a function fixed_point_iteration, which takes appropriate parameters, and uses fixed point iteration to find and return a solution (if found), as well as the number of iterations required. Use x = 1 as starting value.When the program is executed, the original equation should be solved both with Newton’s method and via fixed point iterations (as just described). Compare the output from the two methods.

Found something interesting ?

• On-time delivery guarantee
• PhD-level professional writers
• Free Plagiarism Report

• 100% money-back guarantee
• Absolute Privacy & Confidentiality
• High Quality custom-written papers

Related Model Questions

Feel free to peruse our college and university model questions. If any our our assignment tasks interests you, click to place your order. Every paper is written by our professional essay writers from scratch to avoid plagiarism. We guarantee highest quality of work besides delivering your paper on time.

Grab your Discount!

25% Coupon Code: SAVE25
get 25% !!