Assignment EKC 245 PDF
Assignment EKC 245 PDF
Assignment EKC 245 PDF
Group 17
First iteration :
= 1.8541
X1 = Xl + d
= -2 + 1.8541
= -0.1459
X2 = Xu - d
= 1- 1.8541
= -0.8541
Error %
xu xl
Ɛa = a (1 R ) | | 100%
xopt
5 1 1 ( 2)
[1 ]| | 100%
2 0.1459
= 785.4 %
Xu new = 1-1.1459
= -0.1459
Error %
xu xl
a (1 R) | | 100%
xopt
5 1 1 (0.8541)
= [1 ]| | 100%
2 0.1459
= 485. 4 %
a) Golden Section Search
X optimum =
-0.3468
b) Using Parabolic Interpolation (𝑥0 =− 2 ,𝑥1 =− 1 ,𝑥2 = 1, iteration = 10)
𝑓 𝑥 =− 𝑥4 − 2𝑥3 − 8𝑥2 − 5𝑥
Use initial guess
𝑥0 =− 2
4 3 2
𝑓 𝑥 = 𝑓 − 2 =− − 2 −2 −2 −8 −2 − 5( − 2) =− 22
𝑥1 =− 1
4 3 2
𝑓 𝑥 = 𝑓 − 1 =− − 1 −2 −1 −8 −1 − 5( − 1) =− 2
𝑥2 = 1
4 3 2
𝑓 𝑥 = 𝑓 1 =− 1 −2 1 −8 1 − 5(1) =− 16
𝑓 𝑥3 = 𝑓 − 0.3889
4 3 2
=− − 0.3889 − 2 − 0.3889 − 8 − 0.3889 − 5( − 0.3889)
= 0.8293
Error %
𝑥1 −𝑥0
𝜀𝑎 = × 100%
𝑥1
Xoptimum = -0.3473
c) Using Newton’s Method (𝑥0 =− 1 , 𝜀𝑎 = 1%)
𝑓'(𝑥𝑖 )
𝑥𝑖+1 = 𝑥𝑖 −
𝑓"(𝑥𝑖 )
𝑓 𝑥 =− 𝑥4 − 2𝑥3 − 8𝑥2 − 5𝑥
𝑓' 𝑥 =− 4𝑥3 − 6𝑥2 − 16𝑥 − 5
𝑓'' 𝑥 =− 12𝑥2 − 12𝑥 − 16
𝑓'(𝑥0 )
𝑥1 = 𝑥0 −
𝑓"(𝑥0 )
9
=− 1 −
− 16
=− 0.4375
Error %
𝑥1 −𝑥0
𝜀𝑎 = × 100%
𝑥1
− 0.4375 − − 1
= × 100%
− 0.4375
= 128.57%
𝑓 𝑥1 = 𝑓 − 0.4375
4 3 2
=− − 0.4375 − 2 − 0.4375 − 8 − 0.4375 − 5 − 0.4375
= 0.7871
𝑓' 𝑥1 = 1.1865
𝑓"(𝑥1 ) =− 13.0468
C) Newton’s Method
f ( x) x 4 2 x 3 8 x 2 5 x
f ' ( x ) 4 x 3 6 x 2 16 x 5
f ' ' ( x ) 12 x 2 12 x 16
Xopt = -0.3473