Chapter 1: Limits
Section 1.7: Intermediate Value Theorem
|
Example 1.7.1
|
|
Use bisection to approximate the zeros of .
|
|
|
|
Solution
|
|
•
|
From the graph of in Figure 1.7.1(a), it would appear that there are three zeros located one each in the following three intervals: .
|
•
|
Note how the vertical asymptote at is avoided as an endpoint of an interval that "traps" a zero.
|
•
|
The three zeros are, in fact, , , and , as found by Maple's floating-point solver. These values certainly fall within the three intervals obtained from Figure 1.7.1(a).
|
•
|
Below, the bisection algorithm is detailed, and its connection to the Intermediate Value theorem explained.
|
|
>
|
Student:-Precalculus:-RationalFunctionPlot((x^5-4*x^2+2)/(x-1),view=[-2..2,-20..20],caption="",verticalasymptoteoptions=[color=green,linestyle=dot],tickmarks=[10,5]);
|
|
Figure 1.7.1(a) Graph of
|
|
|
|
Define the function
|
•
|
Control-drag (or type)
Context Panel: Assign Function
|
|
|
Verify that has different signs at the endpoints of each interval
|
|
=
=
|
|
=
=
|
|
=
=
|
Alternate verification
|
•
|
If the product , then and differ in sign.
If the product is zero, then one of or is a zero!
|
|
= = =
|
•
|
If the sign of a continuous function changes at the endpoints of an interval , then, by the Intermediate Value theorem, the function must take the value zero somewhere between and . This is the essence of the idea behind the bisection method.
|
•
|
In Maple's implementation of the method, the function is evaluated at the midpoint , and the half-interval in across which there continues to be a sign change is retained. This process is repeated until the zero is "trapped" in a sufficiently small interval. The midpoint of this last interval is then taken as the approximation to the zero.
|
•
|
Tables 1.7.1(a-c) display the output of Maple's Bisection command used to approximate each of the three zeros of the given function .
|
|
|
|
>
|
interface(rtablesize=100):
|
>
|
Student:-NumericalAnalysis:-Bisection(f(x),[-1,-.5],output=information,maxiterations=50,stoppingcriterion=function_value,tolerance=1e-6);
|
|
Table 1.7.1(a) Bisection approximates leftmost zero as , at which point
|
|
|
The endpoints of the retained half-interval are given as and . The midpoint of the retained half-interval is given as . The next-to-last column list the values and the last column lists , the stopping criterion used for this, and the following two tables. The help page for the Bisection command details alternate stopping criteria; the full syntax of the commands used generate Tables 1.7.1(a-c) are hidden behind the table cells.
>
|
interface(rtablesize=100):
|
>
|
Student:-NumericalAnalysis:-Bisection(f(x),[0.5,0.9],output=information,maxiterations=50,stoppingcriterion=function_value,tolerance=1e-7);
|
|
Table 1.7.1(b) Bisection approximates middle zero as , at which point
|
|
|
Bisection is a slowly converging method for root-finding. The smaller the initial interval, the fewer the iterations needed to approximate a zero to the desired accuracy.
>
|
interface(rtablesize=100):
|
>
|
Student:-NumericalAnalysis:-Bisection(f(x),[1.1,1.5],output=information,maxiterations=50,stoppingcriterion=function_value,tolerance=1e-7);
|
|
Table 1.7.1(c) Bisection approximates rightmost zero as , at which point
|
|
|
|
|
<< Previous Section Section 1.7
Next Example >>
© Maplesoft, a division of Waterloo Maple Inc., 2024. All rights reserved. This product is protected by copyright and distributed under licenses restricting its use, copying, distribution, and decompilation.
For more information on Maplesoft products and services, visit www.maplesoft.com
|