Академический Документы
Профессиональный Документы
Культура Документы
LABORATORY MANUAL
ACTIVITY NO. 1
ITERATIVE METHODS FOR SOLVING ROOTS OF FUNCTIONS I
ACTIVITY OBJECTIVE:
At the end of this experiment, the student should be able to develop programs for determining the
roots of functions using Half-Interval Method and Regula-Falsi Method.
EQUIPMENT NEEDED:
PC with Scilab
LABORATORY ACTIVITIES:
A. Half-Interval Method
Problem:
0.5x
Given the function f(x)=e -x-4, determine the root xr in the interval -10≤x≤0 using Half-Interval
Method.
(a) Write a Scilab program to implement the Half-Interval method algorithm.
(b) Tabulate the first 5 iterations (tabulate values accurate to 6 decimal places)
-12
(c) The minimum number of iterations, n, to determine a root such that |f(xr)|<10 .
-12
(d) The root, xr (accurate to 6 decimal places), that satisfies |f(xr)|<10 .
Results:
(a) Tabulate answers in the given table.
Iteration xl Xu xr
1 -10 0 ________________
B. Regula-Falsi Method
Problem:
LABORATORY MANUAL
0.5x
Given the function f(x)=e -x-4, determine the root xr in the interval 0≤x≤10 using Regula-Falsi
Method.
(a) Write a Scilab program to implement the Regula-Falsi Method algorithm.
(b) Tabulate the first 5 iterations (tabulate values accurate to 6 decimal places)
-12
(c) The minimum number of iterations, n, to determine a root such that |f(xr)|<10 .
-12
(d) The root, xr (accurate to 6 decimal places), that satisfies |f(xr)|<10 .
Results:
(a) Tabulate answers in the given table.
Iteration xl Xu xr
1 0 10 ________________