Answered step by step
Verified Expert Solution
Question
1 Approved Answer
MATLAB The root of an equation, y-f(x), is a value of x for which y has a value of zero and it is often the
MATLAB
The "root" of an equation, y-f(x), is a value of x for which y has a value of zero and it is often "the answer" for a practical engineering problem. The Bisection method is one of the simplest and most robust numerical methods for computing an approximate value for a root of a function. An explanation of the Bisection method is presented on the following page Craft a UDF that: Accepts as an input argument a 4-element vector containing the lower bound for the search interval -the upper bound for the search interval a value of f(x) close enough to zero to accept x as an approximate value for a root the maximum number of iterations before termination of execution Calls another UDF, myFunction, saved in a different m-file, to compute a value of the dependent variable from a value of the independent variable. For example, myFunction accepts a value for x, computes a value of y from yex2, and returns the value of y. No credit will be earned for this assignment if you do not use the specified function name Generates a plot of the function over the specified range of values to provide an idea of how many roots exist on that interval . . .Executes the bisection algorithm to search for a root of the function on the specified interval and reports to the CW one of the two possible outcomes. a) If a root is found, the approximate value of the root and the corresponding value of the function, b) That an approximate value for a root has not been found after iterations where the hyphens are the number of iterations conducted The file you submit to the dropbox should have only the UDF that performs the bisection. NOTE: Although this method is considered slow compared to other numerical methods for finding the root of a function, after only 20 iterations the length of the search interval will be less than 1 millionth of its starting length Step by Step Solution
There are 3 Steps involved in it
Step: 1
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