Download as pdf or txt
Download as pdf or txt
You are on page 1of 23

MATH 2220 LINEAR ALGEBRA FOR

ENGINEERING
Diagonal, Triangular, and Symmetric Matrices

Section 1. 7

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Definition
A square matrix in which all the entries off the main diagonal are zero
is called a diagonal matrix. Here are some examples:
 
  6 0 0 0
  1 0 0  0 −4 0 0 
 
2 0 0 0
, 0 1 0 ,  ,
0 −5  0 0 0 0  0 0
0 0 1
0 0 0 8

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


A general n × n diagonal matrix D can be written as
 
d1 0 · · · 0
 0 d2 · · · 0 
D= .
 
. .. .. 
 . . . 
0 0 · · · dn

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


A diagonal matrix is invertible if and only if all of its diagonal entries are
nonzero; in this case
 
1/d1 0 ··· 0
−1
 0 1/d2 · · · 0 
D = .
 
. .. .. 
 . . . 
0 0 · · · 1/dn

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Powers of diagonal matrices are easy to compute; we leave it for you
to verify that if D is the diagonal matrix and k is a positive integer, then
 k 
d1 0 · · · 0
 0 dk · · · 0 
k 2
D = .
 
. .. .. 
 . . . 
0 0 · · · dnk

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Inverses and Powers of Diagonal Matrices

Example
If  
1 0 0
A =  0 −3 0 
0 0 2

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Example
   
1 0 0 1 0 0
A−1 =  0 − 13 0  , A5 =  0 −243 0 
0 0 12 0 0 32

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Example
 
1 0 0
A−5 1
= 0 − 243
 0 
1
0 0 32

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Matrix products that involve diagonal factors are especially easy to
compute. For example
   
d1 0 0 a11 a12 a13 a14 d1 a11 d1 a12 d1 a13 d1 a1
 0 d2 0   a21 a22 a23 a24  =  d2 a21 d2 a22 d2 a23 d2 a2
0 0 d3 a31 a32 a33 a34 d3 a31 d3 a32 d3 a33 d3 a3

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


   
a11 a12 a13   d1 a11 d2 a12 d3 a13
 a21 d 1 0 0
 a22 a23   d1 a21
  0 d2 0  =  d2 a22 d3 a23 

 a31 a32 a33   d1 a31 d2 a32 d3 a33 
0 0 d3
a41 a42 a43 d1 a41 d2 a42 d3 a43

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


A square matrix in which all the entries above the main diagonal
are zero is called lower triangular, and a square matrix in which
all the entries below the main diagonal are zero is called upper
triangular. A matrix that is either upper triangular or lower trian-
gular is called triangular.

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Upper and Lower Triangular Matrices

Example
   
a11 a12 a13 a14 a11 0 0 0
 0 a22 a23 a24   a21 a22 0 0 
   
 0 0 a33 a34   a31 a32 a33 0 
0 0 0 a44 a41 a42 a43 a44

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Theorem
(a) The transpose of a lower triangular matrix is upper triangular, and
the transpose of an upper triangular matrix is lower triangular.
(b) The product of lower triangular matrices is lower triangular, and the
product of upper triangular matrices is upper triangular.
(c) A triangular matrix is invertible if and only if its diagonal entries are
all nonzero.
(d) The inverse of an invertible lower triangular matrix is lower
triangular, and the inverse of an invertible upper triangular matrix is
upper triangular:

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Computations with Triangular Matrices

Example
Consider the upper triangular matrices
   
1 3 −1 3 −2 2
A= 0 2 4 , B =  0 0 −1 
0 0 5 0 0 1

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Example
It follows that the matrix A is invertible but the matrix B is not.
Moreover, the theorem also tells us that A−1 , AB, and BA must be
upper triangular. We leave it for you to confirm these three statements
by showing that

1 − 23 7 
  
5 3 −2 −2
A−1 =  0 1
2 −5
2 
, AB =  0 0 2 
1 0 0 5
0 0 5

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Example
 
3 5 −1
BA =  0 0 −5 
0 0 5

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Definition
A square matrix A is said to be symmetric if A = AT

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Symmetric Matrices

Example
The following matrices are symmetric, since each is equal to its own
transpose (verify).
 
  d1 0 0 0
  1 4 5
7 −3  0 d2 0 0 
,  4 −3 0  ,  
−3 5  0 0 d3 0 
5 0 7
0 0 0 d4

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Theorem
If A and B are symmetric matrices with the same size, and if k is any
scalar, then:
(a) AT is symmetric.
(b) A + B and A − B are symmetric.
(c) kA is symmetric.

Theorem
The product of two symmetric matrices is symmetric if and only if the
matrices commute.

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Products of Symmetric Matrices

Example
The first of the following equations shows a product of symmetric
matrices that is not symmetric, and the second shows a product of
symmetric matrices that is symmetric. We conclude that the factors in
the first equation do not commute, but those in the second equation
do. We leave it for you to verify that this is so.
    
1 2 −4 1 −2 1
=
 2 3   1 0  −5 2 
1 2 −4 3 2 1
=
2 3 3 −1 1 3

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Theorem
If A is an invertible symmetric matrix, then A−1 is symmetric.

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


The Product of a Matrix and Its Transpose Is
Symmetric

Example
Let A be the 2 × 3 matrix
 
1 −2 4
A=
3 0 −5

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T


Example
Then
   
1 3   10 −2 −11
1 −2 4
AT A =  −2 0  =  −2 4 −8 
3 0 −5
4 −5   −11 −8 41
  1 3  
1 −2 4  21 −17
AAT = −2 0 =
3 0 −5 −17 34
4 −5

Observe that AT A and AAT are symmetric as expected.

MATH 2220 LINEAR ALGEBRA FOR ENGINEERING Diagonal, T

You might also like