Upload
others
View
3
Download
0
Embed Size (px)
Citation preview
Matrices and Matrix AlgebraDeterminants I
Linear Algebra. Session 3
Dr. Marco A Roque Sol
01/27/2020
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Inverting diagonal matrices
Theorem 3.1A diagonal matrix D = diag(d1, d2, · · · .dn) is invertible if and onlyif all diagonal entries are nonzero; di 6= 0 for 1 ≤ i < n
If D is invertible then D−1 = diag(d−11 , d−12 , · · · .d−1n )
d1 0 · · · 00 d2 · · · 0...
.... . .
...0 0 · · · dn
−1
=
d−11 0 · · · 0
0 d−12 · · · 0...
.... . .
...0 0 · · · d−1n
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
proof
If all di 6= 0, then clearly,
diag(d1, d2, · · · .dn)diag(d−11 , d−12 , · · · .d−1n ) =
diag(1, 1, · · · .1) = In
diag(d−11 , d−12 , · · · , d−1n )diag(d1, d2, · · · .dn) =
diag(1, 1, · · · .1) = In
Now suppose that di = 0, for some i . Then for any n × n matrixB, the ith row of the matrix DB is zero. Hence DB 6= In. �
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Inverting 2× 2 matrices
The determinant of a 2× 2 matrix
A =
(a bc d
)is denoted by det(A) and defined by det(A) = ad − bc
Theorem 3.2
A matrix
A =
(a bc d
)is invertible if and only if det(A) 6= 0 . If det(A) 6= 0, then
A−1 =
(a bc d
)−1=
1
ad − bc
(d −b−c a
)Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
proof
Let B the matrix
B =
(d −b−c a
)then
AB = BA =
(ad − bc 0
0 ad − bc
)In the case det(A) = ad − bc 6= 0 we have A−1 = [det(A)]−1B
In the case det(A) = ad − bc = 0 the matrix A is non invertible asotherwise⇒ AB = 0 ⇒ A−1(AB) = A−10 = 0⇒ (A−1A)B = 0 ⇒ I2B = 0 ⇒ B = 0⇒ A = 0, but the zero matrix is singular !!!!! �
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
System of n linear equations in n variables:a11x1 + a12x2 + · · ·+ a1nxn = b1a21x1 + a22x2 + · · ·+ a2nxn = b2
...an1x1 + an2x2 + · · ·+ annxn = bn
⇔ Ax = b
where
A =
a11 a12 · · · a1na21 a22 · · · a2n
...an1 an2 · · · ann
x =
x1x2...xn
b =
b1b2...bn
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Theorem 3.3
If the matrix A above, is invertible then the system has a uniquesolution, which is x = A−1b
General results on inverse matrices
Theorem 3.4
Given an n × n matrix A, the following conditions are equivalent:
(i) A is invertible.
(ii) x = 0 is the only solution of the matrix equation Ax = 0.
(iii) The matrix equation Ax = b has a unique solution for anyn-dimensional column vector b.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
(iv) The row echelon form of A has no zero rows.
(v) The reduced row echelon form of A, is the identity matrix.
Theorem 3.5
Suppose that a sequence of elementary row operations converts amatrix A into the identity matrix. Then the same sequence ofoperations converts the identity matrix into the inverse matrix A−1
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
� ∗ ∗ ∗ ∗ ∗ ∗� ∗ ∗ ∗ ∗ ∗
� ∗ ∗ ∗ ∗� ∗ ∗ ∗
� ∗ ∗� ∗
�
� ∗ ∗ ∗ ∗ ∗ ∗� ∗ ∗ ∗ ∗ ∗
� � ∗ ∗ ∗� ∗ ∗
� �
Invertible case Noninvertible case
For any Invertible square matrix in row echelon form, the numberof columns with leading entries equals the number of rows withleading entries. For a Noninvertible square matrix, the number ofcolumns without leading entries (i.e., the number of free variablesin a related system of linear equations) equals the number of rowswithout leading entries (i.e., zero rows).
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
� ∗ ∗ ∗ ∗ ∗ ∗� ∗ ∗ ∗ ∗ ∗
� ∗ ∗ ∗ ∗� ∗ ∗ ∗
� ∗ ∗� ∗
�
� ∗ ∗ ∗ ∗ ∗ ∗� ∗ ∗ ∗ ∗ ∗
� � ∗ ∗ ∗� ∗ ∗
� �
Invertible case Noninvertible case
Hence the row echelon form of a square matrix A is either stricttriangular or else it has a zero row. In the former case, theequation Ax = b always has a unique solution. Also, in the formercase the reduced row echelon form of A is I .
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Example 3.2
Check whether the matrix A, given by 3 −2 01 0 1−2 3 0
is invertible.
Solution
We convert it to row echelon form. Interchange the 1st row withthe 2nd row: 1 0 1
3 −2 0−2 3 0
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Add −3 times the 1st row to the 2nd row: 1 0 10 −2 −3−2 3 0
Add 2 times the 1st row to the 3rd row : 1 0 1
0 −2 −30 3 2
Multiply the 2nd row by −1/2 : 1 0 1
0 1 3/20 3 2
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Add −3 times the 2nd row to the 3rd row: 1 0 10 1 3/20 0 −5/2
Multiply the 3rd row by −2/5 : 1 0 1
0 1 3/20 0 1
We already know that the matrix A is invertible. Let’s proceedtowards reduced row echelon form .
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Add −3/2 times the 3rd row to the 2nd row: 1 0 10 1 00 0 1
Add −1 times the 3rd row to the 1st row: 1 0 0
0 1 00 0 1
To obtain A−1, in this case, we need to apply the followingsequence of elementary row operations ( same applied to A before)to the identity matrix:
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
1) Interchange the 1st row with the 2nd row.
2) Add −3 times the 1st row to the 2nd row.
3) Add 2 times the 1st row to the 3rd row.
4) Multiply the 2nd row by −1/2 :
5) Add −3 times the 2nd row to the 3rd row.
6) Multiply the 3rd row by −2/5
7) Add −3/2 times the 3rd row to the 2nd row.
8) Add −1 times the 3rd row to the 1st row.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
A convenient way to compute the inverse matrix A−1 is to writethe matrices A and I into one 3× 6 matrix (A|I ) (called TheAugmented Matrix), and apply elementary row operations to thisnew matrix, until A is transformed into I and the identity matrix Iwill be automatically transformed into A−1
A =
3 −2 01 0 1−2 3 0
I =
1 0 00 1 00 0 1
(A|I ) =
3 −2 0 1 0 01 0 1 0 1 0−2 3 0 0 0 1
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
3 −2 0 1 0 01 0 1 0 1 0−2 3 0 0 0 1
Interchange the 1st row with the 2nd row: 1 0 1 0 1 0
3 −2 0 1 0 0−2 3 0 0 0 1
Add −3 times the 1st row to the 2nd row: 1 0 1 0 1 0
0 −2 −3 1 −3 0−2 3 0 0 0 1
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
1 0 1 0 1 00 −2 −3 1 −3 0−2 3 0 0 0 1
Add 2 times the 1st row to the 3rd row. 1 0 1 0 1 0
0 −2 −3 1 −3 00 3 2 0 2 1
Multiply the 2nd row by −1/2 : 1 0 1 0 1 0
0 1 3/2 −1/2 3/2 00 3 2 0 2 1
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
1 0 1 0 1 00 1 3/2 −1/2 3/2 00 3 2 0 2 1
Add −3 times the 2nd row to the 3rd row. 1 0 1 0 1 0
0 1 3/2 −1/2 3/2 00 0 5/2 −3/5 1 0
Multiply the 3rd row by −2/5 1 0 1 0 1 0
0 1 3/2 −1/2 3/2 00 0 1 −3/5 1 −2/5
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
1 0 1 0 1 00 1 3/2 −1/2 3/2 00 0 1 −3/5 1 −2/5
Add −3/2 times the 3rd row to the 2nd row. 1 0 1 0 1 0
0 1 0 2/5 0 3/50 0 1 −3/5 1 −2/5
Add −1 times the 3rd row to the 1st row. 1 0 0 3/5 0 2/5
0 1 0 2/5 0 3/50 0 1 −3/5 1 −2/5
= (I |A−1)
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Thus
3 −2 01 0 1−2 3 0
3/5 0 2/52/5 0 3/5−3/5 1 −2/5
=1
5
3 0 22 0 3−3 5 −2
That is 3 −2 0
1 0 1−2 3 0
1
5
3 0 22 0 3−3 5 −2
=
1 0 00 1 00 0 1
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
We already saw ( Theorem 3.5) that a convenient way to computethe inverse matrix A−1 is to merge the matrices A and I into onematrix (A|I ) and apply elementary row operations to this newmatrix.
Question: Why does it work?
Proposition
Any elementary row operation can be simulated as leftmultiplication by a certain ( elementary ) matrix
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Elementary matrices
1)
E =
1 0. . .
1r
1
0. . .
1
row i
The matrix EA can be obtained from A, multiplying the ith row byr . (The matrix AE can be obtained from A, multiplying the ithcolumn by r)
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Elementary matrices
2)
E =
1 0...
. . .... · · · 1...
.... . .
0 · · · r · · · 1...
......
. . .
0 · · · 0 · · · 0 · · · 1
row i
row j
The matrix EA can be obtained from A, adding r times the ith rowto the jth row. (The matrix AE can be obtained from A, adding rtimes the jth column to the ith column)
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Elementary matrices
3)
E =
1 0. . .
0 · · · 1...
. . ....
1 · · · 0. . .
0 1
row i
row j
The matrix EA can be obtained from A, interchanging the ith rowwith the jth row. (The matrix AE can be obtained from A,interchanging the ith column with the jth column)
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Thus, assume that a square matrix A can be converted to theidentity matrix by a sequence of elementary row operations. ThenEkEk−1 · · ·E2E1A = I , where E1,E2, · · · ,Ek−1,Ek are elementarymatrices s imulating those operations.
Applying the same sequence of operations to the identity matrix,we obtain the matrix
B = EkEk−1 · · ·E2E1I = EkEk−1 · · ·E2E1
Thus, BA = I . Moreover, B is invertible since elementary matricesare invertible. It follows that B−1(BA) = (B−1B)A = A, thenBA = AB, then A = B−1, so B = A−1.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Transpose of a matrix
Given a matrix A the transpose of A, denoted by AT , is thematrix whose rows are columns of A (and whose columns are rowsof A ) That is, if A = (aij), then AT = (bij) where bij = aji . Thus,for instance (
1 2 34 5 6
)T
=
1 42 53 6
1
45
T
=(
1 4 5)
(1 22 0
)T
=
(1 22 0
)
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Properties of transposes
(AT )T = A
(A + B)T = AT + BT
(rA)T = rAT
(AB)T = BTAT
(A1A2 · · ·Ak)T = ATk A
Tk−1 · · ·AT
2 AT1
(AT )−1 = (A−1)T
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Matrices, matrix algebra
Definition
A square matrix A is said to be symmetric if A = AT
For example, any diagonal matrix is symmetric.
Proposition
For any square matrix A the matrices B = AAT and C = A + AT ,are symmetric.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
The general definition of the determinant is quite complicated asthere is no simple explicit formula
Approach 1 (Axiomatic): We formulate properties that thedeterminant should have.
Approach 2 (Inductive): The determinant of an n × n matrix isdefined in terms of determinants of certain (n − 1)× (n − 1)matrices.
Approach 3 (Original): An explicit (but very complicated)formula is provided.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Approach 1 (Axiomatic)
Mn×n(R): The set of n × n matrices with real entries.
AXIOMS
There exists a unique function det :Mn×n(R) −→ R (called thedeterminant) with the following properties
A1 If a row of a matrix is multiplied by a scalar r , the determinantis also multiplied by r
A2 If we add a row of a matrix multiplied by a scalar to anotherrow, the determinant remains the same
A3 If we interchange two rows of a matrix, the determinantchanges its sign;
A4: det(I ) = 1
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Theorem 3.6
Suppose A is a square matrix and B is obtained from A applyingelementary row operations. Then det(A) = 0 if and only ifdet(B) = 0.
Theorem 3.7
det(B) = 0 whenever the matrix B has a zero row
Theorem 3.8
det(A) = 0 if and only if the matrix is not invertible.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Idea of the proof of 3.8: Let B be the reduced row echelon form ofA. If A is invertible then B = I ; otherwise B has a zero row .
Remark. The same argument proves that properties (A1)-(A4) areenough to evaluate any determinant.
Theorem 3.9
If a matrix A has two proportional rows then det(A) = 0
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Row echelon form of a square matrix
� ∗ ∗ ∗ ∗ ∗ ∗� ∗ ∗ ∗ ∗ ∗
� ∗ ∗ ∗ ∗� ∗ ∗ ∗
� ∗ ∗� ∗
�
� ∗ ∗ ∗ ∗ ∗ ∗� ∗ ∗ ∗ ∗ ∗
� � ∗ ∗ ∗� ∗ ∗
� �
det(A) 6= 0 det(A) = 0
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
As an example, we have the matrix
A =
3 −2 01 0 1−2 3 0
Earlier we have transformed the matrix A into the identity matrixusing elementary row operations.
These included two row multiplications, by −0.5 and by −0.4, andone row exchange.
It follows that
det(A)(−0.5)(−0.4)(−1) = (−0.2)det(A) = det(I ) = 1
Hence det(A) = −5det(I ) = −5
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Approach 2 (Inductive)
Let’s start by considering a 2× 2 system{ax + by = ecx + dy = f
whose solution is given by
x =ed − bf
ad − bcy =
af − ce
ad − bc
where we can notice that the amount ad − bc playing an importantrole in the solution is a combination of the elements of the matrix(
a bc d
)Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
In a similar way, if we consider a 3× 3 systema11x + a12y + a13 = b1a21x + a22y + a23 = b2a31x + a32y + a33 = b3
we find, the solutions for the variables have in the denominator thequantity
a11(a22a33 − a23a32)− a12(a21a33 − a23a31)+
a13(a21a32 − a22a31)
which also plays an important role in the solution set. Thus, thiscould be a practical starting point of the concept of determinant.
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Before introducing the concept of determinant, let’s start with acouple of definitions
Submatrices
Definition Given a matrix A, a k × k submatrix of A is a matrixobtained by specifying k columns and k rows of A and deleting theother columns and rows.
1 2 3 410 20 30 403 5 7 9
⇒ ∗ 2 ∗ 4∗ ∗ ∗ ∗∗ 5 ∗ 9
⇒ (2 45 9
)
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Minors
Given an n× n matrix A = (aij), let Mij , denote the determinant ofthe (n − 1)× (n − 1) submatrix obtained by deleting the ith rowand the jth column of A. That number obtained in this way iscalled the ij-minor of A
Definition
Associated to every n × n matrix A there is a real number calledthe determinant of A denoted by |A| or det(A) and definedinductivly as follows
n = 1 A = a11 |A| = a11
n = 2 A =
(a11 a12a21 a22
)|A| =
∣∣∣∣a11 a12a21 a22
∣∣∣∣ = a11a22 − a12a21
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
n = 3 A =
a11 a12 a13a21 a22 a23a31 a32 a33
|A| =
∣∣∣∣∣∣a11 a12 a13a21 a22 a23a31 a32 a33
∣∣∣∣∣∣ =
a11
∣∣∣∣a22 a23a32 a33
∣∣∣∣− a12
∣∣∣∣a21 a23a31 a33
∣∣∣∣+ a13
∣∣∣∣a11 a12a31 a32
∣∣∣∣ = a11a22a33+
a12a23a31 + a13a21a32 − a31a22a13 − a32a23a11 − a33a21a12 =
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
a11a22a33 + a12a23a31+a13a21a32 − a31a22a13−a32a23a11 − a33a21a12
=
∣∣∣∣∣∣∣∣a11 a12 a13 a11 a12a21 a22 a23 a21 a22a31 a32 a33 a31 a32
− − − + + +
∣∣∣∣∣∣∣∣Now, for n ≥ 4, if let M1j be the corresponding minors to the firstrow, then we have
|A| =n∑
j=1
(−1)1+ja1jM1j
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Theorem 3.10
For any 1 ≤ k ,m ≤ n we have that
det(A) =n∑
j=1
(−1)k+jakjMkj =n∑
j=1
akj(−1)k+jMkj =n∑
j=1
akjCkj
( Cofactor Ckj expansion, by the k − th row, )
det(A) =n∑
i=1
(−1)i+maimMim =n∑
j=1
aim(−1)i+mMim =n∑
j=1
aimCim
(Cofactor Cim expansion, by the m − th column, )
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Theorem 3.11
Given an n × n matrix A, if B is an n × n matrix obtained from Aby
1) Additive law for rows
Suppose that matrices X ,Y ,Z are identical except for the ith row.The the ith row of Z is the sum of the ith rows of X and Y then
det(Z ) = det(X ) + det(Y )
∣∣∣∣∣∣a1 + a′1 a2 + a′2 a3 + a′3
b1 b2 b3c1 c2 c3
∣∣∣∣∣∣ =
∣∣∣∣∣∣a1 a2 a3b1 b2 b3c1 c2 c3
∣∣∣∣∣∣+
∣∣∣∣∣∣a′1 a′2 a′3b1 b2 b3c1 c2 c3
∣∣∣∣∣∣Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
2) Adding a multiple of the ith row to the jth row then |B| = |A|∣∣∣∣∣∣a1 + rb1 a2 + rb2 a3 + rb3
b1 b2 b3c1 c2 c3
∣∣∣∣∣∣ =
∣∣∣∣∣∣a1 a2 a3b1 b2 b3c1 c2 c3
∣∣∣∣∣∣+
∣∣∣∣∣∣rb1 rb2 rb3b1 b2 b3c1 c2 c3
∣∣∣∣∣∣ =
∣∣∣∣∣∣a1 a2 a3b1 b2 b3c1 c2 c3
∣∣∣∣∣∣2) Interchanging two rows, then |B| = −|A|
3) Multiplying a row by a nonzero scalar α then |B| = α|A|
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
Theorem 3.12
1) |AT | = |A|
( As a consequence, for every property of determinants involvingrows of a matrix there is an analogous property involving columnsof a matrix. )
2) |AB| = |A||B|
3) If A has a row (column) of zeros, then |A| = 0
4) If A has a two identical rows (columns), then |A| = 0
Dr. Marco A Roque Sol Linear Algebra. Session 3
Matrices and Matrix AlgebraDeterminants I
Determinants I
5) If two rows (columns) of A are proportional, then |A| = 0
6) If A is an upper (lower) triangular matrix, then|A| = a11a22a33 · · · ann
7) If A is an invertible matrix, then |A−1| = |A|−1
8) If A is an n × n matrix and r ∈ R, then |rA| = rn|A|
Dr. Marco A Roque Sol Linear Algebra. Session 3