Lower Triangular Matrices

Lower Triangular Matrices Dylan Levi Renaud March 2016 1 Products of n x n Triangular Matrices 1.1 2 x 2, 3 x 3, and 4 x 4 Random Triangular Matri...
Author: Ruth Allison
9 downloads 0 Views 155KB Size
Lower Triangular Matrices Dylan Levi Renaud March 2016

1

Products of n x n Triangular Matrices

1.1

2 x 2, 3 x 3, and 4 x 4 Random Triangular Matrices

The commands L1 = tril(rand(n)), L2 = tril(rand(n)), L1*L2, L2*L1 Where n = 2, 3, 4 and 5 yielded two n x n random lower triangular matrices whose products had the same diagonals and upper triangles whose elements were zero. This is to say the product L1*L2 and L2*L1 resulted in matrices of the form:   L 0 0 ... 0 R L 0 . . . 0    R R L . . . 0     .. . .. . . ..  R

...

L

Where L represents a common element to both L1*L2 and L2*L1 and R represents a value not common to both matrix products. n=2 ans = 0.1660 0.2635

0 0.0243

0.1660 0.2912

0 0.0243

ans =

n=3 ans = 0.2454 0.4839 0.2806

0 0.4380 0.2706

0 0 0.3049

0.2454 0.3783 0.5127

0 0.4380 0.4357

0 0 0.3049

ans =

n=4

1

ans = 0.3768 0.2924 0.5593 1.3543

0 0.0335 0.1106 0.4471

0 0 0.1362 0.7596

0 0 0 0.2944

0.3768 0.2230 1.3099 1.7129

0 0.0335 0.3616 0.5315

0 0 0.1362 0.2151

0 0 0 0.2944

ans =

n=5 ans = 0.1001 0.4467 0.5189 0.1456 0.5903

0 0.1512 0.7015 0.1105 0.7878

0 0 0.2507 0.0453 0.3454

0 0 0 0.0342 0.4868

0 0 0 0 0.5136

0.1001 0.8146 0.9270 0.5583 1.8159

0 0.1512 0.3646 0.2767 0.5344

0 0 0.2507 0.3045 0.4352

0 0 0 0.0342 0.1864

0 0 0 0 0.5136

ans =

1.2

2 x 2, 3 x 3, and 4 x 4 Random Non-triangular Matrices

For non-triangular random matrices the results shown in section 1.1 do not hold. The matrices calculated had no identical elements. The matrix products were computed simply by removing the tril command when creating matrices. The following code was then implemented for n = 2. Below is an example L1 = (rand(2)), L2 = (rand(2)), L1*L2, L2*L1 ans = 0.3694 0.2889

0.2479 0.2125

0.4920 0.1415

0.2642 0.0900

ans =

1.3

Proof : The Product of Any Two n x n Lower Triangular Matrices is Lower Triangular

Given any two lower triangular n x n  a11 0  a21 a22  L1 =  .  .. an1

...

matrices L1 and L2   ... 0 b11  b21 ... 0    and L2 =  . ..  ..   .. . . ann bn1

0 b22 ...

... ... .. .

0 0 .. .

    

bnn

We may easily prove that the matrix products L1*L2 and L2*L1 yield n x n lower triangular matrices.

2

Consider L1*L2. If we compute any element Lij of the matrix product such that j > i we will find that the element is equal to zero. Lij = aij ∗ bij + ai(j+1) ∗ b(i+1)j + ...ain ∗ bnj (1) Here we see that if i > j the element Lij is zero. Consider L12 . Then equation (1) becomes: L12 = a11 ∗ b12 + a12 ∗ b22 + ...ain ∗ bnj = a11 ∗ 0 + 0 ∗ b22 + ...0 ∗ bnj = 0 Taking into account that b12 , a12 , . . . , a1n are zero (all elements of L1 and L2 with j > i are zero) we can see that this sum is zero. This holds for the case L2*L1 as well. To show that the diagonals of L1*L2 and L2*L1 are the same consider the computation of any element Lij where i = j. These elements make up the diagonal of the matrix product. Returning to equation (1), if i = j we are left with a sum of the products of zero and a non-zero number and the products of the diagonal values. Therefore, after simplification we are left with aij ∗ bij for i = j which is equal to bij ∗ aij . This shows why the diagonals are the same for both matrix products.

2

Products of n x n Unit Triangular Matrices

2.1

2 x 2, 3 x 3, and 4 x 4 random triangular matrices

The commands L1 = tril(rand(n),-1)+eye(n),L2 = tril(rand(n),-1)+eye(n),L1*L2,L2*L1 Where n = 2, 3, 4 and 5 yielded n x n unit lower triangular matrices. The products L1*L2 and L2*L1 had the same diagonals whose elements were 1 and upper triangles whose elements were zero. n=2 ans = 1.0000 1.0033

0 1.0000

1.0000 1.0033

0 1.0000

ans =

n=3 ans = 1.0000 0.6576 1.5804

0 1.0000 0.6088

0 0 1.0000

1.0000 0.6576 1.4906

0 1.0000 0.6088

0 0 1.0000

ans =

n=4 ans = 1.0000 0.5738 1.2597 0.8925

0 1.0000 1.2426 1.8807

0 0 1.0000 0.5433

3

0 0 0 1.0000

ans = 1.0000 0.5738 1.0266 0.9069

0 1.0000 1.2426 2.0448

0 0 1.0000 0.5433

0 0 0 1.0000

n=5 ans = 1.0000 0.5923 1.7796 1.3902 1.7817

0 1.0000 0.4740 0.7893 1.7349

0 0 1.0000 0.7884 1.1601

0 0 0 1.0000 0.8937

0 0 0 0 1.0000

1.0000 0.5923 1.5272 1.0371 1.9589

0 1.0000 0.4740 0.9088 1.5317

0 0 1.0000 0.7884 1.0426

0 0 0 1.0000 0.8937

0 0 0 0 1.0000

ans =

2.2

Proof : The Product of Any Two n x n Unit Lower Triangular Matrices is Unit Lower Triangular

Given any two unit lower triangular n x n matrices L1 and L2    1 1 0 ... 0  b21  a21  1 . . . 0    and L2 =  . L1 =  . ..  ..  ..  ..  . . bn1 an1 . . . 1

0 1 ...

... ... .. .

 0 0  ..  . 1

We may easily prove that the matrix products L1*L2 and L2*L1 yield n x n unit lower triangular matrices in a manner similar to the proof found in section 1.2. As in section 1.2, if we compute any element Lij of the matrix product such that j > i we will find that the element is equal to zero. Lij = aij ∗ bij + ai(j+1) ∗ b(i+1)j + . . . ain ∗ bnj = 0 ∗ 0 + 0 ∗ b(i+1)j + · · · + 0 ∗ bnj = 0 Similarly, if i = j we are left with a sum of the products of zero and a non-zero number and the products of the diagonal values which are 1. An examples is shown below for the case of i = j = 1. L11 = a11 ∗ b11 + a12 ∗ b21 + . . . ain ∗ bnj = 1 ∗ 1 + 0 ∗ b21 + · · · + 0 ∗ bnj = 1 Because aij ∗ bij = bij ∗ aij for the case of i = j the diagonals of L1*L2 and L2*L1 will be the same. This proves that the product of any two n x n unit lower triangular matrices is unit lower triangular.

3

Extra Credit

Consider an n x n lower triangular matrix with each diagonal entry non-zero. Call this matrix L. If we augment L with the n x n identity matrix I we obtain the following augmented matrix A.   a11 0 ... 0 1 0 ... 0  a21 a22 . . . 0 0 1 . . . 0   A= . . .. ..  . .. .. ..  .. . . . an1

...

ann 4

0

...

1

Now, by a series of elementary row operations we can the form  1 0 . . . 0 b11 0 1 . . . 0 b21  A = . .. . ..  .. . .. . 0 ... 1 bn1

show that the reduced echelon form of A must be of  0 ... 0 b22 . . . 0     ..  = I K ..  . . ...

bnn

Recall that for a matrix to be in reduced echelon form the leading entries (first non-zero element) of each row must be 1, must have zeroes below and above in the column corresponding to the leading entry, and must be to the right of the leading entry in the row above it. To obtain L in reduced echelon form we must perform n-1 pivot operations such that we are left with   1 0 ... 0 a11 0 . . . 0  0 a22 . . . − aa21 1 . . . 0 0 11   A= . .. .. ..  .. ..  .. . . . . . a21 an2 an1 1 0 ... ann − a11 + a22 a11 + . . . . . . Now if we perform n scale operations so that all the leading entries in L are 1, we are left with the following augmented matrix.  1 0  A = .  .. 0

0 1

... ... .. .

...

a21 an1 1 where a111 , − (a11 a22 ) , a22 , − a11 ann + see that

0 0 .. . 1

1 a11 a21 − a11 a22

0 1 a22

.. .

− a11an1 ann +

a21 an2 1 ann a22 a11 , ann

a21 an2 ann a22 a11

+ ...

... ... .. .

...

0 0 .. .

    

1 ann

etc. are equal to b11 , b21 , b22 , bn1 , bnn etc. respectively, we

 A= I

K



Where I is the n x n identity matrix and K is an n x n lower triangular matrix.

5

Suggest Documents