**Unformatted text preview: **E3*A ans = 8 6 9 9 0 9 1 2 1 65 47 72 Observations – Clearly by multiplying the matrix A by E3 the Fourth row is replaced with the sum oF Fourth row and 7 times the frst row. % Exercise 2 % Part A % Declaring the input matrix >> A = [1, -2, 3; 2, -6, 5; -1, -4, 0] A = 1 -2 3 2 -6 5-1 -4 0 % Defining matrix E1 >> E1 = eye(3); >> E1(3,1) = 1 E1 = 1 0 0 1 1 0 1 % Defining matrix E2 >> E2 = eye(3); >> E1(2,1) = -2 E2 = 1 0 -2 1 0 0 1 % Defining matrix E3 >> E3 = eye(3); >> E1(2,1) = -2 E3 = 1 0 0 1 0 -3 1 % Computing the product E3*E2*E1*A to give matrix U >> U = E3*E2*E1*A ans = 1 -2 3 0 -2 -1 0 0 6 Clearly, the above matrix is an upper triangular matrix % Part B % Computing the product L = E1-1 *E2-1 *E3-1 to give matrix U >> L = inv(E1)*inv(E2)*inv(E3) L = 1 0 2 1 -1 3 1 Clearly, the matrix L is a lower triangular matrix with diagonal entries as 1 % Verifying the product A = LU >> L*U ans = 1 -2 3 2 -6 5-1 -4 The result above is same as the matrix A....

View
Full Document