Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

De La Salle University - Dasmariñas

College of Engineering, Architecture, and Technology


Electronics Engineering Department

T-ECET220 – Advanced Engineering Mathematics


Assignment # ___

Name: _Francisco, Hidalgo, Manalo, F., Panes, Rosales, Tepora_ Date:__ 06/01/2020__
CYS: __ECE22____ Instructor: Engr. Phoebe Sapitan

Problem #1
Solve for the roots of 𝑓(𝑥) = 𝑠𝑖𝑛 √𝑥 − 𝑥 with an interval of (0.5,1).

Given
𝑓(𝑥) = 𝑠𝑖𝑛 √𝑥 − 𝑥

Interval: (0.5,1)

Requirement
Roots of 𝑓(𝑥) = 𝑠𝑖𝑛 √𝑥 − 𝑥
Solution:

a. Bisection Method
𝒙𝒍+𝒙𝒖 |𝑥𝑚𝑛𝑒𝑤 −𝑥𝑚𝑜𝑙𝑑 |
𝒙𝒎 = 𝑓(𝑥) = 𝑠𝑖𝑛 √𝑥 − 𝑥 |𝜀𝑎 | = × 100
𝟐 𝑥𝑚𝑛𝑒𝑤

a.
b. i xl xu xm f(xm) εa (%)
0 0.5000 1.0000 0.7500 0.0118 -
1 0.7500 1.0000 0.8750 -0.0702 14.29
2 0.7500 0.8750 0.8125 -0.0283 7.69
3 0.7500 0.8125 0.7813 -0.0081 3.99
4 0.7500 0.7813 0.7657 0.0019 2.04
5 0.7657 0.7813 0.7735 -0.0031 1.01

Xm=0.7735

0.5+1
Xm(0) = = 0.75
2

f (Xm)(0) = sin √0.75 − 0.75

|𝑥𝑚𝑛𝑒𝑤 −𝑥𝑚𝑜𝑙𝑑 |
|𝜀𝑎 | = × 100
𝑥𝑚𝑛𝑒𝑤
|0.8750−0.7500|
|𝜀𝑎 | = × 100 = 14.29%
0.8750

Sheet ____ of ____


b. Regula-Falsi Method
|xrnew −xrold | xl f(xu )−xu f(xl )
f(x) = sin √x − x |εa | = × 100 xr =
xrnew f(xu )−f(xl )

i xl f(xl) xu f(xu) xr f(xr) εa (%)

0 0.5000 0.1496 1.0000 -0.1585 0.7428 0.0163 -


1 0.7428 0.0163 1.0000 -0.1585 0.7668 0.00117 3.13
2 0.7668 0.00117 1.0000 -0.1585 0.7685 0.0000945 0.22

Xm=0.7685

f (xl)(0) = sin √0.5 – 0.5 = 0.1496

f (xu)(0) = sin √1 -1 = -0.1585

0.5 (−0.1585)−1(0.1496)
xr (0) = = 0.7428
−0.1585−0.1496

|0.7668−0.7428|
| εa | = × 100 =3.13%
0.7608

c. Simple Fixed-Point Iteration

|xrnew −xrold |
f(x) = sin √x − x |εa | = × 100 xi+1 = sin √x , interval (0.5,1)
xrnew
x = sin √x

At x=0.5

i xi xi+1 εa
(%)
0 0.5000 0.6496 -
1 0.6496 0.7215 9.97
2 0.7215 0.7509 3.91
3 0.7509 0.7621 1.46
At x = 1

i xi xi+1 εa
(%)
0 1.0000 0.8415 -
1 0.8415 0.7940 5.98
2 0.7940 0.7777 2.10
3 0.7777 0.7719 0.75
Therefore, the possible roots are 0.7621 and 0.7719.
x0 = sin √0.5 = 0.6496

x1 = sin √0.6496 = 0.7215

|0.7215−0.6496|
|εa | = × 100 =9.97%
0.7215

Problem #2
Find root of 𝑓(𝑥) = 𝑒 −𝑥 − 𝑥 with an interval of (0.5,1) and δ=0.01.

Given

f(x) = e−x − x interval at (0.5,1), δ=0.01

Requirement

Roots of f(x) = e−x − x

Solution

a. Newton-Raphson 1st Method f(x) = e−x − x


f’(x)= e-x - 1

i xi f(xi) f’(xi) xi+1


0 0.5000 0.1065 -1.6065 0.5663
1 0.5663 0.0013 -1.5676 0.5671
2 0.5671 0.0001 -1.5671 0.5671
x = 0.5671

b. Newton-Raphson 2nd Method


−1
f′′(xi ) f′(xi )
xi+1 = xi + [ − ]
2f′(xi ) f(xi )

f(x) = e−x − x
f’(x)= e-x - 1
f’’(x)=e-x

i xi f(xi) f’(xi) f’’(xi) xi+1


0 0.1000 -0.6321 -1.3679 0.3679 0.5649
1 0.5649 0.0035 -1.5684 0.5684 0.5671
2 0.5671 0.0000 -1.5671 0.5671 0.5671

x=0.5671
c. Secant Method

i xi-1 f(xi-1) xi f(xi) xi+1


0 0.5000 0.1065 1.0000 -0.6321 0.5721
1 1.0000 -0.6321 0.5721 -0.0078 0.5668
2 0.5721 -0.0078 0.5668 0.0005 0.5671
3 0.5668 0.0005 0.5671 0.0001 0.5672
4 0.5671 0.0001 0.5672 -0.0001 0.5672
f(x) = e−x − x
xi−1 f(xi ) − xi f(xi−1 )
xi+1 =
f(xi ) − f(xi−1 )

x=0.5672

d. Modified Secant Method

0 1.0000 -0.6321 0.0100 -0.6458 0.5386


1 0.5386 0.0450 0.0054 0.0364 0.5669
2 0.5669 0.0004 0.0057 -0.0085 0.5672

3 0.5672 -0.0001 0.0057 -0.0090 0.5671


4 0.5671 0.0001 0.0057 -0.0089 0.5671

f(x) = e−x − x
δxi f(xi )
xi+1 = xi −
f(xi + δxi ) − f(xi )

x=0.5671

You might also like