0% found this document useful (0 votes)
153 views11 pages

1 Intro BisectionMethod PDF

The document discusses numerical methods for finding roots of equations. It focuses on the bisection method and false position method. The bisection method uses brackets to bound the root and narrows the interval at each step. The false position method is an improvement that chooses the next point based on the graphical relationship between the x-axis and function value. Examples are provided to demonstrate applying both methods to find roots of different functions within a specified tolerance in a few iterations.

Uploaded by

amir nabil
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
153 views11 pages

1 Intro BisectionMethod PDF

The document discusses numerical methods for finding roots of equations. It focuses on the bisection method and false position method. The bisection method uses brackets to bound the root and narrows the interval at each step. The false position method is an improvement that chooses the next point based on the graphical relationship between the x-axis and function value. Examples are provided to demonstrate applying both methods to find roots of different functions within a specified tolerance in a few iterations.

Uploaded by

amir nabil
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

Numerical Analysis

(1)

1
Many problems in Science and Engineering are expressed as:

These problems are called: Root Finding Problems


A number r that satisfies an equation is called a
Root of the equation.

2
Bisection Method
1. Bisection method is the simplest bracketing method.
The lower value, 𝑥𝑙 and the upper value, 𝑥𝑢 which bracket the
root(s) are required.
2. The procedure starts by finding the interval [𝑥𝑙, 𝑥𝑢] where the
solution exists.
3. As shown below at least one root exist in the interval

[𝑥𝑙, 𝑥𝑢] if
4. It is also called: Interval Halving method.

Intermediate value theorem:

if a function is continuous and f(a) and f(b) have different signs


then the function has at least one zero in the interval [a , b]

3
Step 4: Calculate the approximate percent relative error:

Step 5: Compare with. If 𝜀𝑎 < 𝜀𝑠, then stop the computation. Otherwise
go to Step 2 and repeat the process by using the new interval.

Note:
‫… التشابه‬. a
‫… االختالف‬. b

4
𝜀𝑎: Relative approximate error
𝜀𝑠: True percent relative error "acceptance error".

Example: Can you use Bisection method to find a zero of :

Solution

F(x) is continuous on [0 , 2] and f(0) * f(2) = (1) (3) = 3 > 0

Assumptions are not satisfied So Bisection method cannot be used


,

Solution

F(x) is continuous on [0 , 1] and f(0) * f(1) = (1) (-1) = -1 < 0

Assumptions are satisfied So Bisection method can be used


,

5
Best Estimate and Error Level: Bisection method obtains an
interval that is guaranteed to contain a zero of the function.

Stopping Criteria:

1. Stop after a fixed number of iterations (n).


2. Stop when the absolute error is less than a specified value.

Convergence Analysis:

To know How many iterations are needed.

Example:

F(x) = - 0.4 x 2 + 2.2 x + 4.7

Find solution by using bisection method using a = 5, b =10 and

𝜀𝑠 = 5%
6
Solution

C = (a + b) / 2 = (5+10) / 2 = 7.5

C = (a + b) / 2 = (5+7.5) / 2 = 6.25

C = (a + b) / 2 = (6.25 + 7.5) / 2 = 6.875

C = (a + b) / 2 = (6.875 + 7.5) / 2 = 7.1875

n a b c F(a) F(b) F(c) Update 𝜀a


1 5 10 7.5 5.7 -13.3 -1.3 b=c -----

2 5 7.5 6.25 5.7 -1.3 2.82 c=a 20 %

3 6.25 7.5 6.875 2.82 -1.3 0.918 a=c 9.09 %

4 6.875 7.5 7.1875 0.918 -1.3 -0.15 b=c 4.347 %

𝜀 < 𝜀𝑠 , Then root of the function =


Since : 𝑎 7.1875

7
Example:

F(x) = x3 + 4x – 2 , in the interval [0, 1] , when n= 3

Solution

C = (a + b) / 2 = (0+1) / 2 = 0.5

C = (a + b) / 2 = (0+ 0.5) / 2 = 0.25

C = (a + b) / 2 = (0.25 + 0.5) / 2 = 0.375

n a b c F(a) F(b) F(c) Update 𝜀a


1 0 1 0.5 -2 3 0.125 b=c -----

2 0 0.5 0.25 -2 0.125 -0.98 a=c 100 %

3 0.25 0.5 0.375 -0.98 0.125 -0.44 a=c 33.3 %

Then root = 0.375

8
Example:

F(x) = 3x e x – 1 , in the interval [0, 1] , when n= 3

Solution

Note: e = 2.718

C = (a + b) / 2 = (0+1) / 2 = 0.5

C = (a + b) / 2 = (0+ 0.5) / 2 = 0.25

C = (a + b) / 2 = (0.25 + 0.5) / 2 = 0.375

n a b c F(a) F(b) F(c) Update 𝜀a


1 0 1 0.5 -1 7.15 1.47 b=c -----

2 0 0.5 0.25 -1 1.47 -0.0.36 a=c 100 %

3 0.25 0.5 0.375 -0.03 1.47 0.6368 b=c 33.3 %

9
The False-Position Method

• It is an improvement of the Bisection method.

• The bisection method converges slowly due to its behavior in

redefined the size of interval that containing the root.

• Although bisection is a perfectly valid technique for

determining roots, it's rate is relatively slow and inefficient.

• False position is an alternative based on graphical knowledge.

10
Example:

F(x) = x sin x - 1 , in the interval [0, 2] , when n= 3

Solution

C = b – ( [f(b) * (a - b)] / [ f(a) – f(b) ] )

C = 2 – ( [ 0.81859 * ( 0 – 2 )] / [-1 - 0.81859] ) = 1.09975

. .. ….

n a b c F(a) F(b) F(c) Update

1 0 2 1.09975 -1 0.81859 -0.02001 a=c

2 1.09975 2 1.12126 -0.02001 0.81859 0.00981 b=c

3 1.09975 1.12123 1.11416 -0.02001 0.00981 0.6368 b=c

11

You might also like