EEE 231 Lecture
EEE 231 Lecture
On
Given a function f(x), it required to find the root of the equation using numerical
methods.seveeral Numerical methods can be used to solve these equations which includes:
1. Bisection method
3. Newton’s method
1. Bisection method
Given f(x) = 0 and values of x 1and x 2 such that f (x ¿¿ 1)¿ and f (x ¿¿ 2)¿ are of opposite sign
Set of Rules
1
|x −x | ≥ tolenrance value
2 1 2
( x 1 + x 2)
Set x 3 =
2
Example 1: find the roots of the equation between 3 and 4, if f(x) = x 2−3.7 x=0 using
x 1=3 , x2 =4 ,
No of
x1 x2 x3 f (x ¿¿ 1)¿ f (x ¿¿ 2)¿ f (x ¿¿ 3)¿
iteration
1 3 4 3.5 -2.100 1.200 -0.700
Solution
No of
x1 x2 x3 f (x ¿¿ 1)¿ f (x ¿¿ 2)¿ f (x ¿¿ 3)¿
iteration
1 1 3 2 -2.3513 4.0372 1.7183
Given f(x) = 0 and values of x 1and x 2 such that f (x ¿¿ 1)¿ and f (x ¿¿ 2)¿ are of opposite sign
Set of Rules
Solution
X= 0.360433.
3. NEWTON’S METHOD.
Given a function f(x) = 0 and a value of x vary close to the root, a specific no of iteration or a
tolerance value.
Steps
Set of rules
f ( x1)
( x 2 )=x 1−
f ' ( x1 )
x 1=x 2
Example 4: find the solution of the equation f ( x )=2 x 3−7 x 2−x +12=0 which as a root near
x= 1.5
Solution
3 2
f ( x n ) =2 x −7 x −x +12
2
f ' ( x n ) =6 x −14 x−1
Iteration
number
1.6764705
1 0.07327498 -7.60726644
9
1.6861028
2 0.00028558 -7.54778314
2
1.6861406
3 4.462E-09 -7.54754728
6
1.6861406
4 0 -7.54754728
6
Example 5: find the solution of the equation f ( x )=x 3 +5 x 2−3 x−4=0 which as a root near
x= 0.5
Solution
3 2
f ( x n ) =x +5 x −3 x−4
'( xn )
f =2 x 2 +10 x−3
Iteration
number
-
2 1.36820208 2.65044486
8.92296753
-
3 1.66523834 0.1591048
7.67522441
-
4 1.685968 0.00130329
7.54862344
Example 6: find the solution of the equation f ( x )=e x + x−2=0 which as a root near
x= 0.4
Solution
x
f ( x )=e + x−2=0
'( xn )
f =e x +1
Iteration
number
10.354650
1 0.44341208 -6.02808352
3
-
2 2.16114712 2.6675241 -3.2327184
7
2.9391256
3 1.33598271 -8.99465913
2
0.1782515
4 1.66274614 -7.69009763
4
INTEGRAL FUNCTIONS
Some functions are mostly convieniet defined in the form of as integrals and we shall look
into different appraoch which include Gamma and Beta functions in this module.
r(x) = ∫ t
x−1 −t
e dt and is convergent for x > 0 (1)
0
∞ ∞
0 0
i.e ∫ t e dt
x −t
recall: ∫ t e dt = uv - ∫ vdu
x x
du x−1
let u = t x ; =x t
dx
−t
du −t dv e
; integrate both sides ∫
dt ∫
−t
du = e dt −t
; =e = e ;v=
dt −1
∞
r(x+1) = ∫ t e dt
x −t
= uv - ∫ vdu
[ ]
∞ −t
e−t e
) - ∫(
x x−1
= t ( )x t dt
−1 0 −1
= x ∫ t e dt
x−1 −t
Recall, r(x) = ∫ t
x−1 −t
e dt
= [0-0] + xr(x)
Γ(1) = ∫ t e dt = ∫ t e dt = ∫ t e dt
x−1 −t 1−1 −t 0 −t
0 0 0
∞
= [−e−t ]0 = 0+1 = 1
Γ(1) = 1
Or using recurrence relation in reverse, given that Γ(11) = 3628800 we can determine Γ(10)
by;
1
Now let us consider when x =
2
()
∞
1
= ∫ t e dt
x−1 −t
Γ
2 0
= ∫t
1/ 2−1 −t
e dt
0
= ∫t
−1 /2 −t
e dt
0
dt
let t= U 2 ; =2 U ; dt = 2Udu; −1
U =t
−1
du
()
∞ −1
1 ( )
= ∫ U 2 e 2 Udu
2
2 −u
Γ
2 0
∞
= 2∫ U
2
−1 −u
e Udu
0
= 2 ∫t e
2
−1 −u
t du ; t-1 /t = 1
0
= 2 ∫e
2
−u
du ……………………………………………………………..(3)
0
Hence, ∫ e
2
−u
du can not be easily resolve by normal means. So we can say that:
0
To Evaluate ∫ e
2
−x
dx
0
∞ ∞
Let I = ∫ e dx and I = ∫ e
2 2
−x −y
dy
0 0
( )( )
∞ ∞
∫e − x2
∫ e− y dy
2
I2 = dx
0 0
∞ ∞
= ∫ ∫ e− x + y dxdy
( 2 2
)
0 0
δa = δxδy represents an element of area in the x—y plane and the integration with the stated
limits covers the whole of the first quadrant.
Also, x2 + y2 = r2
from δa = r δθδr.
п /2 ∞
I = ∫ ∫e
−¿ ¿
2
¿¿
0 0
[ ]
п /2 2
e−r ∞
I =∫
2
dθ
0 2 0
п /2
1
I2 = ∫ dθ
0 2
= []
θ п /2
2 0
= п /4
I2 = п /4
∞
√п = 2
∫ e−u du( in expression (3) above)
2
I=
2 0
Γ (3.5)
Example 1: Evaluate
Γ ( 4.5)
Solution
Γ (3.5) = Γ (1+ 2.5) ; Γ (2.5) = Γ (1+1.5) ; Γ (1.5) = Γ (1+ 0.5) = 0.5 Γ (0.5)
7 15
2 8 √
Γ (4.5) = Γ (1+ 3.5) = 3.5 Γ (3.5) = X ( п ¿ = 105/16√ п
Γ (3.5) Γ (3.5) 15/8 √ п ¿ ¿ 15 16
= =
8 105 √
To evaluate we can now say that X ( п¿ =
Γ ( 4.5) Γ ( 4.5) 105 /16 √п
2
7√
п
Γ (1/2)
Γ (−1/2) = Γ ¿ ¿ = = -2 √ п
Γ (−1/2)
Γ (5.5)
1)
Γ (7.5)
Γ (−2.5 )
2)
Γ ( 4.5 )
Γ (−1.5 )
3)
Γ (−3.5 )
Γ (−7.5 )
4)
Γ (−4.5 )
Example 2: Evaluate I = ∫ x
2
1 /2 −x
e dx .
0
Solution
Let y = x2 ; dy = 2xdx
When x = 0, y = 0; x = ∞, y = ∞.
0 0 4
∞ −1
1
= ∫y 4 −y
e dy
20
∞
1
= ∫ y e dy
v−1 − y
20
3
Where v =
4
1
Hence I = Г ( 3/4 ) = 0.613 recall that Г ( 3/ 4 ) =1.2254
2
∞
Example 3: Evaluate∫ x e dx .
7 −x
∞ ∞
0 0
Since v – 1 = 7 ; v = 8
i.e. ∫ x e dx = Г ( 8 ) =7 !=5040.
7 −x
B (m, n) =∫ x
m−1 n−1
(1− x) dx which converges for m > 0 and n > 0
0
B (n, m) = ∫ (1−u)
m−1 n−1
u du
1
B (n, m) = B (m, n)
B (m, n) =∫ x
m−1 n−1
(1− x) dx
0
If we put x = sin2 θ,
π
2
B (m, n) =2∫ sin2m−1 θ cos 2n−1 θ❑ dθ
0
π
When x=0, θ =0 ; x=1, θ = , 1- x = 1- sin2 θ=cos2 θ
2
π
2
B (m, n) =2∫ sin2m−2 θ cos 2n−2 θ❑ sin θ cos θ d θ
0
π
2
B (m, n) =2∫ sin2m−1 θ cos 2n−1 θ❑ d θ.
0
π
m−1 ( 2 m−1 )−1 2
B (m, n) = X ∫ sin 2m−3 θ cos 2n−3 θ❑ d θ.
m+ n−1 ( 2m−3 ) +(2 n−1)
0
m−1 ( n−1 )
B (m, n) = ¿ X B(m−1 , n−1)
m+ n−1 m+ n−2 ¿
4−1 ( 3−1 )
B (m, n) = X B(4−1 , 3−1)
4+ 3−1 (4+3−2)
To determine B(2 , 1)
π
[ ]
2 4 π
B(2 , 1) = 2∫ sin 3 θcosθdθ=2 sin θ 2 = 1
0 4 2
0
(3)(2)(2)(1)
Hence B(4 , 3) = B(2 , 1)
(6)(5)(4)(3)
b . B(6 , 2),
c . B(5 , 7).
Solution
m−1 ( n−1 )
B (m, n) = ¿ X B(m−1 , n−1)
m+ n−1 m+ n−2 ¿
¿ ( 4 ) ( 2 )( 3 )( 1 )
B(5 , 3) = B (5 ,3 ) = (4)(2)¿ ( 7 ) ( 6 ) B ( 4 ,2 ) = B ( 3 , 1)
( 7) ( 6) ( 5) ( 4 )
To determine B(3 , 1)
π π
[ ]
2 2 6 π
B(3 , 1) = 2∫ sin 5 θcosθdθ=∫ sin5 θ(sinθ)=¿ 2 sin θ 2 = 1 ¿
0 0 6 3
0
( 4 ) ( 2 )( 3 )( 1 ) ( 4 ) ( 2 ) (3 )( 1 ) 1 ( 2 ) ( 4 !)(2 !)
B (5 ,3 ) = B ( 3 , 1) = =¿
( 7) ( 6) ( 5) ( 4 ) ( 7) ( 6) ( 5) ( 4 ) 3 (2) (7 !)
Hence determine
B(6 , 2),
B(5 , 7).
The use of gamma and beta functions in the evaluation of definite integral depends largely on
the ability to change the variables to express the integral in the basic form of the beta
function.
1
0
1
Then m-1 =5 ; m = 6. n -1 = 4 ; n = 5
(5 !)( 4 !) 1
I = B(6, 5) = = .
(10!) 1260
π
2
Example 6: Evaluate I = ∫ sin 5 θcos 4 θdθ.
0
π
2
Compare this with B (m, n) = 2∫ sin2m−1 θ cos 2n−1 θ❑ dθ
0
1 1 Г ( 4 ) Г ( 5 /2 ) 1 2 ! ( 3 √ π ) / 4 8
I = B(3, 5/2) = = x = .
2 2 Г ( 11/2 ) 2 ( 945 √ π ) /32 315