1.1: The Bisection Method September 2019: MA385/530 - Numerical Analysis
1.1: The Bisection Method September 2019: MA385/530 - Numerical Analysis
3
2
f(x)= x −2
2 x−axis
0
x[0]=a x[2]=1 x[3]=1.5 x[1]=b
−1
−2
−0.5 0 0.5 1 1.5 2 2.5
§1 Solving nonlinear equations Intro (2/58)
and are easy to solve. Some nonlinear problems are also easy to
solve, e.g.,
Similarly, there are formulae for all cubic and quartic polynomial
equations. But most equations do not have simple formulae for
their solutions, so numerical methods are needed.
§1 Solving nonlinear equations Intro (3/58)
References
Chap. 1 of Süli and Mayers (Introduction to Numerical
Analysis). We’ll follow this pretty closely in lectures, though
we will do the sections in reverse order!
Stewart (Afternotes ...), Lectures 1–5. A well-presented
introduction, with lots of diagrams to give an intuitive
introduction.
Chapter 4 of Moler’s “Numerical Computing with MATLAB”.
Gives a brief introduction to the methods we study, and
description of MATLAB functions for solving these problems.
The proof of the convergence of Newton’s Method is based on
the presentation in Thm 3.2 of Epperson.
§1 Solving nonlinear equations Intro (4/58)
There are some subtleties here, particularly with part (2). What we
would like to say is that at each step the error is getting smaller.
That is
But we can’t. Usually all we can say is that the bounds on the
error is getting smaller. That is: let εk be a bound on the error
at step k
|τ − xk | < εk ,
then εk+1 < µεk for some number µ ∈ (0, 1). It is easiest to
explain this in terms of an example, so we’ll study the simplest
method: Bisection.
Bisection (8/58)
3
f(x)= x2 −2
2 x−axis
0
x[0]=a x[2]=1 x[3]=1.5 x[1]=b
−1
−2
−0.5 0 0.5 1 1.5 2 2.5
Bisection (11/58)
√
Find an estimate for 2 that is correct to 6 decimal places.
Solution: Use bisection to solve f (x ) := x 2 − 2 = 0 on the
interval [0, 2].
1 k−1
|τ − xk | ≤ |b − a|, for k = 2, 3, 4, ...
2
Improving upon bisection (13/58)
Exercise 1.2
Suppose we want to find τ ∈ [a, b] such that f (τ ) = 0 for some
given f , a and b. Write down an estimate for the number of
iterations K required by the bisection method to ensure that, for a
given ε, we know |xk − τ | ≤ ε for all k ≥ K . In particular, how
does this estimate depend on f , a and b?
Exercises (15/58)
Exercise 1.3
How many (decimal) digits of accuracy are gained at each step of
the bisection method? (If you prefer, how many steps are needed
to gain a single (decimal) digit of accuracy?)
Exercise 1.4
Let f (x ) = e x − 2x − 2. Show that there is a solution to the
problem: find τ ∈ [0, 2] such that f (τ ) = 0.
Taking x0 = 0 and x1 = 2, use 6 steps of the bisection method to
estimate τ . You may use a computer program to do this, but
please note that in your solution.
Give an upper bound for the error |τ − x6 |.
Exercises (16/58)
Exercise 1.5
√
We wish to estimate τ = 3 4 numerically by solving f (x ) = 0 in
[a, b] for some suitably chosen f , a and b.
(i) Suggest suitable choices of f , a, and b for this problem.
(ii) Show that f has a zero in [a, b].
√
(iii) Use 6 steps of the bisection method to estimate 3 4. You
may use a computer program to do this, but please note that
in your solution.
(iv) Use Theorem 1.3 to give an upper bound for the error
|τ − x6 |.