Professional Documents
Culture Documents
2.0
U nle a shing Possibilit ie s
I. OBJECTIVES
1. To be able to create .m file to solve Linear Equations using Gauss elimination and
LU Decomposition
2. To execute m file and get the correct value of the unknowns at the command
window
II. DISCUSSION
A system of linear equations can also be solved by using an iterative approach.
The process is same as in the fixed-point iteration method used for solving nonlinear
equation. In an iterative process for solving a system of equations, the equations are
written in an explicit form in which each unknown is written in terms of the other
unknown.
The solution process starts by assuming initial values for the unknowns (first
estimated solution). In the 1st iteration, the first assumed solution is substituted on the
right-hand side of the equations, and the new values that are calculated for the
unknowns are the 2nd estimated solution. In the 2nd iteration, the second solution is
substituted back in the equations to give new values for the unknowns, which are the
3rd estimated solution. The solutions that are obtained as successive iterations
converge toward the actual solution.
The iterations can be stopped when the absolute value of the estimated relative
error of all the unknowns is smaller than some predetermined value or the absolute
value of approximate error εa must be less than the acceptance error εs.
IV. METHODOLOGY
CI TE
2.0
U nle a shing Possibilit ie s
2.0
U nle a shing Possibilit ie s
V. OUTPUT
Problem 1
CI TE
2.0
U nle a shing Possibilit ie s
1. Editor Window
CI TE
2.0
U nle a shing Possibilit ie s
2. Command Window
CI TE
2.0
U nle a shing Possibilit ie s
Problem 2
(a)
1. Editor Window
CI TE
2.0
U nle a shing Possibilit ie s
2. Command Window
CI TE
2.0
U nle a shing Possibilit ie s
CI TE
2.0
U nle a shing Possibilit ie s
CI TE
2.0
U nle a shing Possibilit ie s
(b)
1. Editor Window
2. Command Window
CI TE
2.0
U nle a shing Possibilit ie s
CI TE
2.0
U nle a shing Possibilit ie s
CI TE
2.0
U nle a shing Possibilit ie s
CI TE
2.0
U nle a shing Possibilit ie s
VI. QUESTIONS
1. Using the created program, differentiate the methods used under Direct Method
of solving Linear Equations?
The methods used under Direct Method of Solving Linear Equations are the
Gauss Elimination and the LU Decomposition Method. The Gauss
Elimination Method utilizes a sequence of operations performed on the
corresponding matrix of coefficients. This method can also be used to find
the rank of a matrix, to calculate the determinant of a matrix, and to calculate
the inverse of an invertible square matrix.
VII. CONCLUSIONS:
Upon conducting the experiment, we were able to implement both LU Decomposition
and Gauss Elimination Method; which yielded different results. An iterative approach
was used by writing the equations in an explicit form. Upon doing so, the group
evaluated the correct values of the unknowns and computed the approximate error
which determined that LU Decomposition method is a more efficient method of solving
Linear Equations. Hence, the group can conclude that the objectives of the experiment
were met. The group was able to create a .m file which can solve Linear Equations
using Gauss elimination and LU Decomposition. The group was also able to execute
the said .m file and got the correct value of the unknowns at the command window.
Lastly, the group was able to compute the approximate error using Gauss elimination
and LU Decomposition and compare which method is more efficient.
CI TE
2.0
U nle a shing Possibilit ie s