Вы находитесь на странице: 1из 13

Compilation of Numerical Methods Laboratory Experiments

Author: Luigi Carlo M. De Jesus BSECE Student

Module 7 L.U. Decomposition

A. Objective:

To find the approximate roots of the given system of linear equations using Crouts/Choleskys Method.

B. Data and Analysis:


Given the matrices:

The lower and upper triangular matrices and value of variables are as follows:

Formula used: *Please refer to the figure below

J9 = D9

C. Discussion:
I. First write the variables and constant in matrix form separately.

II.

Create two matrices and name them lower and upper diagonal matrix.

III.

To get the values of the lower and upper diagonal matrices, I applied the Crouts Method to decompose matrix A.

I applied the steps/formulas as follows: i. Lower Diagonal Matrix Put zeros on the upper triangle of the Lower Diagonal Matrix. Copy the first column of Matrix A to the first column of the Lower Diagonal Matrix. Please refer to the figure.

ii.

Upper Diagonal Matrix First, put ones on the diagonal of the Upper Diagonal Matrix Then, put zeros on the lower triangle of the Upper Diagonal Matrix. To get the first row of the Upper Diagonal Matrix, the elements of the first row of the matrix A must be divided to the first row first column of the matrix A. Please refer to the figure.

iii.

Apply the pattern below to get the proceeding values of the matrices: See the color coding of the formula. For Lower Diagonal Matrix

For Upper Diagonal Matrix

IV. Create another 4 x 1 matrix and name it Y. Please refer to the figure.

To get the values of Y, apply matrix multiplication between the Lower Diagonal Matrix and the Constant. ((4x4 matrix) cross multiply(4 x 1 matrix) = Y). Please study the matrix multiplication on internet or books, its really easy. VI. VII. Create another 4 x 1 matrix and name it Unknowns. To get the values of Unknowns, apply matrix multiplication between the Lower Diagonal Matrix and the Constant. ((4x4 matrix) cross multiply (4 x 1 matrix) = Unknowns).

V.

See next page for the finished product

Voila! Now you got the values of the unknowns a, b, c and d respectively.

Module 8 Gauss-Seidel and Jacobi Method

Module 9 Regression

Вам также может понравиться