Lecture 2
Lecture 2
Roots of Equations
In this chapter we shall discuss one of the oldest approximation problems
which
consists of finding the roots of an equation.
It is also one of the most commonly
occurring problems in applied mathematics.
The root-finding problem consists
of the following: given a continuous function f,
find the values of x that satisfy the equation
f(x) = 0 (3.1)
The solutions of this equation are called the zeros of f or the roots of the
equation.
In general, Eqn. (3.1) is impossible to solve exactly. Therefore, one must
rely on
some numerical methods for an approximate solution.
Bisection Method
Objectives:
(2)The procedure is carried out by first defining the midpoint of [a, b], c = (a + b)/2
and then computing the product f(c)f(b).
(3)If the product is negative, then the root is in the interval [c,b].
(4)If the product is positive, then the root is in the interval [a, c]. Thus, a new
interval containing α is obtained.
(5)The process of halving the new interval continues until the root is located as
accurately as desired.
where an and bn are the endpoints of the nth interval [an, bn]
and is a specified
tolerance value.
Some other stopping criteria that one can use, other than
(3.5), are given by
Proof :
>> Bis
enter the value of a: 1
enter the value of b: 2
enter the tolerance level: 0.000001
enter the number of iteration: 20
0 1.500000000000000
1 1.250000000000000
2 1.375000000000000
3 1.437500000000000
4 1.406250000000000
5 1.390625000000000
6 1.382812500000000
7 1.386718750000000
“An introduction to numerical methods, A matlab approach“ , Third edition Slide 1 - 15
8 1.388671875000000
9 1.387695312500000
10 1.388183593750000
11 1.387939453125000
12 1.388061523437500
13 1.388122558593750
14 1.388153076171875
15 1.388137817382813
16 1.388130187988281
17 1.388126373291016
18 1.388124465942383
19 1.388125419616699