The bisection method for finding roots involves starting with 2 values of a func
ID: 3784902 • Letter: T
Question
The bisection method for finding roots involves starting with 2 values of a function, f(x), that have opposite sign. Since the function is continuous, there must be at least 1 root on the interval. This root can be found by sequentially calculating the function at the midpoint of the interval until a sufficiently precise root value is obtained. Please 1) write an algorithm for this method and 2) create a computation program to input any continuous function, f(x), and 3) for the function below, use your program to find the 3 roots to a precision/error level of 0.0001. Note the number of steps/computations needed to obtain solutions. f(x) = -2 - 0.01x + 1.5 x^2 - 0.2x^3Explanation / Answer
Given a function f (x) continuous on an interval [a,b] and f (a) * f (b) < 0
Do
c = (a+b)/2
if f (a) * f (c) < 0 then b = c
else a = c
while (none of the convergence criteria C1, C2 or C3 is satisfied)
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.