ZARQA UNIVERSITY
Numerical Analyses
Report: Secant Method
Students:
Haytham Harb Salah Abdallah || 20220836
Supervisor: Eng. Mohamad Musleh
1|Page
Lab Work
Practical Work
1. Use the MATLAB implementation of the Secant method to find a root of the function
ƒ(𝑥) = 𝑥3 − 2𝑥2 − 6𝑥 + 4 using the initial guesses x−1=−3∧x 0=−4
Iteration 𝗑i 𝑓(𝗑i) 𝑓(𝗑i−1) 𝗌𝑎,i(%)
-4 58 33 Inf
0
-1.68 9.1872 58 138.1
1
-1.2433 3.6111 9.1872 35.119
2
-0.96057 0.61032 3.6111 29.439
3
-0.90305 0.058715 0.61032 6.3689
4
-0.89693 0.0011687 0.058715 0.68255
5
The approximate root is: -0.89693
2. Repeat step 2 using the initial guesses x−1=3∧x 0=2
Iteration 𝗑i 𝑓(𝗑i) 𝑓(𝗑i−1) 𝗌𝑎,i(%)
0 2 -2 9 Inf
2.1818 -0.44628 -2 8.3333
1
2 2.234 0.036668 -0.44628 2.3377
3 2.2301 -0.00057407 0.036668 0.1778
2.2301 -7.1585e-07 -0.00057407 0.0027407
4
5 2.2301 1.4012e-11 -7.1585e-07 3.4218e-06
The approximate root is: 2.2301
2|Page
3. Use the MATLAB implementation of the Secant method to find a root of the function
ƒ(𝑥) = sin(x) + cos (1+x) -1 :
a- Using the initial guesses x−1=1∧x0 =3 , the approximate root is :
The approximate root is: 2.5599
b- Using the initial guesses x−1=−5∧x 0=0 , the approximate root is :
The approximate root is: -151.3644
c- Using the initial guesses x−1=1.5∧x 0=8.5 , the approximate root is :
The approximate root is: 4.0901
3|Page