Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Matlab function, MyRegulaFalsi, that takes in a function handle f, interval lower bound a, interval upper bound b, and a tolerance tol. This function
Matlab function, MyRegulaFalsi, that takes in a function handle f, interval lower bound a, interval upper bound b, and a tolerance tol. This function should perform the regula falsi iteration until if (x)| < tol and return all iterates x, as an array x,. (a) Use your regula falsi function to find an approximate root for f (x) = (x-3) sin(x) + 3.5 with interval [1, 3] and a tolerance 105. Print a table of the iterates xi and their corresponding function values f (xi). (b) Also use your function on the interval [1,2] with the same tolerance 10-5. Print a table of the iterates xi and their corresponding function values f (x;). Do the results change significantly? Why or why not?
Step by Step Solution
★★★★★
3.46 Rating (166 Votes )
There are 3 Steps involved in it
Step: 1
Heres a MATLAB implementation of the MyRegulaFalsi function function xs MyRegulaFalsif a b tol xs if fa fb 0 errorFunction has the same sign at both interval bounds a and b end while true xn a fb b fa ...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started