Академический Документы
Профессиональный Документы
Культура Документы
a12 x2
a1n xn
b1
a21 x1
a22 x2
a2n xn
b2
a31 x1
a32 x2
a3n xn
b3
..
. =
..
.
..
. +
am1 x1
..
. +
+ am2 x2
+
+
amn xn
(1)
= bm
In this system, aij is a given real number as is bi . Specifically, aij is the coefficient for the
unknown xj in the ith equation. We call the set of all the aij arranged in a rectangular array the
coefficient matrix of the system. Using matrix notation we can write the system as
Ax = b
a11
a21
a31
..
.
am1
a12
a22
a32
..
.
..
.
am2
a1n
x1
b1
a2n
x2
b2
a3n
. = ..
.
.. ..
.
xn
bm
amn
(2)
a11
a21
A = a31
..
.
am1
a12
a22
a32
..
.
..
.
a1n
a2n
a3n
..
.
b1
b2
b3
am2
amn
bm
1
2
1
5
2 ,
A = 2
3 4 2
3
b = 8
4
(3)
(4)
Ax = b
1
2
1
x1
3
2
5
2 x2 = 8
3 4 2
x3
4
(5)
x1 + 2x2
+ x3 =
2x1 + 5x2
+ 2x3 =
3x1 4x2
2x3 =
(6)
3 4 7
A = 0 5 2
0 0 4
1
2
0
1
1
3
1 0
B = 0 0
0 0
1 3
C = 0 4
0 0
3x2 + x3
= b1
4x2 + x3
= b2
3x3
= b3
(7)
which could be easily solved for the various variable after dividing the third equation by 3.
1.2.4. Pivots. The first non-zero element in each row of a matrix in row-echelon form is called a
pivot. For the matrix A above the pivots are 3,5,4. For the matrix B they are 1,2 and for C they
are 1,4,3. For the matrix B there is no pivot in the last row.
1.2.5. Reduced row echelon form. A row echelon matrix in which each pivot is a 1 and in which each
column containing a pivot contains no other nonzero entries, is said to be in reduced row echelon
form. This implies that columns containing pivots are columns of an identity matrix. In the matrix
D in equation (8) all three columns are pivot columns. In the matrix E in equation (8) all the first
two columns are pivot columns. The matrices D and E are both in reduced row echelon form.
1 0 0
D = 0 1 0
0 0 1
(8)
1 0 0
E = 0 1 0
0 0 0
In matrix F in equation (9), columns 2, 4 and 5 are pivot columns. The matrix F is in row echelon
form but not in reduced row echelon form because of the 1 in the a25 and the 3 in the a15 elements
of the matrix. The 5 in the a13 element is irrelevant because column 3 is not a pivot column.
0 1 5 0 3
0 0 0 1 1
F =
(9)
0 0 0 0 1
0 0 0 0 0
1.2.6. Reducing a matrix to row echelon or reduced row echelon form. Any system of equations can
be reduced to a system with the A portion of the augmented matrix A in echelon or reduced echelon
These operations are
form by performing what are called elementary row operations on the matrix A.
the same ones that we used when solving a linear system using the method of Gaussian elimination.
There are three types of elementary row operations. Performing these operations does not
change the basic nature of the system or its solution.
1: Changing the order in which the equations or rows are listed produces an equivalent system.
by a nonzero
2: Multiplying both sides of a single equation of the system (or a single row of A)
number (leaving the other equations unchanged) results in a system of equations that is
equivalent to the original system.
3: Adding a multiple of one equation or row to another equation or row (leaving the other
equations unchanged) results in a system of equations that is equivalent to the original
system.
1.2.7. Rank.
Definition 1 (Rank). The number of non-zero rows in the row echelon form of an m n matrix A
produced by elementary operations on A is called the rank of A. Alternatively, the rank of an m
n matrix A is the number of pivots we obtain by reducing a matrix to row echelon form.
Matrix D in equation 8 has rank 3, matrix E has rank 2, while matrix F in 9 has rank 3.
Definition 2 (Full column rank). We say that an m n matrix A has full column rank if r = n.
If r = n, all columns of A are pivot columns.
The matrix L is of full column rank
1 0
L = 0 1
0 0
Definition 3 (Full row rank). We say that an m n matrix A has full row rank if r = m. If r =
m, all rows of A have pivots and the reduced row echelon form has no zero rows.
The matrix M is of full row rank
1 0
M = 0 1
0 0
0 10
0
4
1 7
from the matrix. Consider matrix equation 5 with its augmented matrix A.
Ax = b
1
2
1
x1
3
2
5
2 x2 = 8
3 4 2
x3
4
1
2
1
3
5
2
8
A = 2
3 4 2 4
(5)
Step 1. Consider the first row and the first column of the matrix. Element a11 is a non-zero number
and so is appropriate for the first row of the row echelon form. If element a11 were zero,
we would exchange row 1 with a row of the matrix with a non-zero element in column 1.
Step 2. Use row operations to knock out a21 by turning it into a zero. This would then make
the second row have one more leading zero than the first row. We can turn the a21 element
into a zero by adding negative 2 times the first row to the second row.
2 1 2 1 3
2 4 2 6
2 4
2
5
0
1
2 6
2
8
0
2
1
2
1
3
1
0
2
A1 = 0
(10)
3 4 2 4
We can obtain A1 by premultiplying A by what is called the a21 elimination matrix
denoted by E21 where E21 is given by
1 0 0
E21 = 2 1 0
(11)
0 0 1
The first and third rows of E21 are just rows of the identity matrix because the first and
third rows of A and A1 are the same. The second row of A1 is a linear combination of the
rows of A where we add negative 2 times the first row of A to 1 times the second row of
To convince yourself of this fact remember what it means to premultiply a matrix by a
A.
row vector. In the following example premultiplying the matrix
1
2
2
5
3 4
by the vector 1 0 2 adds one times the first row to twice the third row as follows.
1
2
1 0 2 2
5 = 5 6 .
3 4
For the case at hand we have
A1
1 0
= 2 1
0 0
0
0
1
1
2
2
5
3 4
1
3
1
2
1
3
2
8 = 0
1
0
2
2 4
3 4 2 4
(12)
Step 3. Use row operations to knock out a31 by turning it into a zero. This would then make the
third row have one more leading zero than the first row. We can turn the a31 element into
a zero by adding 3 times the first row to the third row.
3 1
1 3
3 9
3
6
3 4
0
2
3
9
2 4
1
5
1
= 0
0
3
2
5
2 1
1 0
2 1
(13)
1 0
= 0 1
3 0
0
0
1
(14)
The first and second rows of E31 are just rows of the identity matrix because the first
and second rows of A1 and A2 are the same. The third row of A2 is a linear combination
of the rows of A1 where we add 3 times the first row of A1 to 1 times the third row of A1 .
For the case at hand we have
A2
1
= 0
3
0
1
0
0
0
1
1
2
1
0
1
0
3 4 2
3
1 2
2 = 0 1
4
0 2
1
0
1
3
2
5
(15)
Step 4. Use row operations to knock out a32 by turning it into a zero. This would then make the
third row have one more leading zero than the second row. We can turn the a32 element
into a zero by adding negative 2 times the second row of A2 to the third row of A2 .
2 0 1
0 2
0 2
0
2
0
2
0
0
0 4
0
4
1
5
1
1
1
= 0
0
2 1
1 0
0 1
3
2
1
(16)
E32
1
= 0
0
0 0
1 0
2 1
1 3
1
0 2 = 0
1 5
0
(17)
The first and second rows of E32 are just rows of the identity matrix because the first
and second rows of A2 and A3 are the same. The third row of A3 is a linear combination
of the rows of A2 where we add negative 2 times the second row of A2 to 1 times the third
row of A2 . For the case at hand we have
A3
1
= 0
0
0 0
1 0
2 1
1 2
0 1
0 2
2 1
1 0
0 1
3
2
1
(18)
We can then read off the solution for x3 because the third equation says that x3 = 1.
The second equation says that x2 = 2. We then solve for x1 by substituting in the first
equation as follows.
x1 + 2x2 + x3 = 3
x1 + 2(2) + (1) = 3
x1 + 4 + 1 = 3
(19)
x1 = 2
1.4. Solving systems of linear equations by finding the reduced row echelon form of a
matrix. To solve a system of linear equations represented by a matrix equation, we first add the
right hand side vector to the coefficient matrix to form the augmented coefficient matrix. We then
perform elementary row and column operations on the augmented coefficient matrix until it is in
reduced row echelon form. We can read the coefficients off directly from the matrix. Consider the
system of equations in section 1.3
Ax = b
1
2
1
x1
3
2
5
2 x2 = 8
3 4 2
x3
4
1
2
1
3
5
2
8
A = 2
3 4 2 4
(5)
1
= 0
0
2 1
1 0
0 1
3
2
1
(20)
From this equation system we obtained the solutions by back substitution. To find the reduced
row echelon form we need to eliminate all non-zero entries in the pivot columns. We begin with
column 3. The a23 element is already zero, so we can proceed to the a13 element. We do this in step
5.
Step 5. Use row operations to knock out a13 by turning it into a zero. We can turn the a13
element into a zero by adding negative 1 times the third row to the first row.
1 0 0
1 1
1 1
0 0
0
0
1
2
1
2
1 1
1
3
0
2
1
= 0
0
A4
2
2
1
2 0
1 0
0 1
(21)
1
= 0
0
0 1
1 0
0 1
1
= 0
0
0 1
1 0
0 1
1 3
1
0 2 = 0
1 1
0
1 2
0 1
0 0
(22)
2 0
1 0
0 1
2
2
1
(23)
The third column of the matrix has a pivot in the third row and zeroes in the first and
second rows.
Step 6. Use row operations to knock out a12 by turning it into a zero. We can turn the a12
element into a zero by adding negative 2 times the second row to the first row.
2 0 1
0 2
0 2 0
0
2
1
2
1
0
4
0
4
0
2
0
2
1 0
= 0 1
0 0
0
0
1
2
2
1
(24)
E12
For the case at hand we
1 2
A5 = 0 1
0 0
1
= 0
0
have
0
1
0 0
1
0
2 0
1 0
0 1
2 0
1 0
0 1
2
1 0
2 = 0 1
1
0 0
(25)
0 2
0 2
1 1
(26)
1.5. Examples.
1.5.1. Example of a system with one solution. Consider the system of equations
x1 x2 x3 = 1
3x1 + 4x2 + 2x3 = 8
(27)
2x1 + x2 4x3 = 10
written in matrix form as
Ax = b
1 1 1
x1
1
3 4
2 x2 = 8
2
1 4
x3
10
(28)
1 1 1 1
A = 3 4
2 8
2
1 4 10
1 0 0 2
0 1 0 2
0 0 1 3
(29)
(30)
The matrix A is of rank 3 because we have 3 non-zero rows in the reduced row echelon form.
We can also see that it is of rank 3 because we have 3 pivots. The answers to the systems are
{x1 = 2, x2 = 2, x3 = 3}.
1.5.2. Example of a system with three equations and two unknowns and no solution. Consider the
system of equations
x1 x2 = 1
3x1 + 4x2 = 2
2x1 + x2 = 6
written in matrix form as
(31)
10
Ax = b
1 1
1
(32)
x
1
3 4
= 2
x2
2
1
6
The augmented matrix is of the form
1 1 1
A = 3 4 2
(33)
2 1 6
After appropriate row and column operations we obtain
1
0
6
0
(34)
1
5
0
0 11
The matrix A is of rank 2 because we have 2 non-zero rows in the reduced row echelon form. We
can also see that it is of rank 2 because we have 2 pivots. The third equation is inconsistent and so
the system has no solution.
1.5.3. Example of a system with three equations and two unknowns with exactly one solution. Consider the system of equations
x1 x2 = 1
3x1 + 4x2 = 2
(35)
2x1 + x2 = 5
written in matrix form as
Ax = b
1
1 1
3 4 x1 = 2
x2
5
2
1
The augmented matrix is of the form
1 1 1
A = 3 4 2
2 1 5
Adding 3 times the first equation to the second equation we obtain
1 1 1
0 1 1
2 1 5
Adding -2 times the first equation to the third equation we obtain
1 1 1
0 1 1
0 3 3
(36)
(37)
(38)
(39)
11
1 1 1
0 1 1
(40)
0 0 0
Adding the second equation to the first equation we obtain
!
10 2
(41)
01 1
00 0
The matrix A is of rank 2 because we have 2 non-zero rows in the reduced row echelon form. We
can also see that it is of rank 2 because we have 2 pivots. The third equation implies that 0 = 0
and the system has one solution.
We can also see this when we realize that the third row of A = {2, 1, 5} is 11 times the first row
1.5.4. Example of a system with two equations and three unknowns and infinite solutions. Consider
the system of equations
x1 x2 x3 = 1
3x1 + 4x2 + 2x3 = 8
(42)
(43)
(44)
(45)
12
The matrix A is of rank 2 because we have 2 non-zero rows in the reduced row echelon form. We
can also see that it is of rank 2 because we have 2 pivots. We can pick an arbitrary number for
x3 and then find values for x1 and x2 by solving each equation. Therefore there are infinite solutions.
For example, let x3 = 3. We then have the following system
x1
1 0 2
4
x2
=
0 1 1
5
3
We then have
x1 + (2)(3) = 4
x1 = 4 + 6 = 2
We then have
x2 + (1)(3) = 5
x2 = 5 + 3 = 2
Substituting in equation 43 we obtain
2
1
2 =
8
3
Picking a different value for x3 we would obtain different values for x1 and x2 .
1 1 1
3 4
2
1.5.5. Example of a system with three equations and three unknowns and infinite solutions. Consider
the system of equations
x1 x2 x3 = 1
3x1 + 4x2 + 2x3 = 8
(46)
2x1 + 3x2 + x3 = 7
written in matrix form as
Ax = b
1 1 1
1
x1
3 4
2 x2 = 8
2 3
1
x3
7
The augmented matrix is of the form
1 1 1 1
A = 3 4 2 8
2 3 1 7
After appropriate row and column operations we obtain
1 0 2 4
0 1 1 5
0 0 0 0
(47)
(48)
(49)
13
The matrix A is of rank 2 because we have 2 non-zero rows in the reduced row echelon form. We
can also see that it is of rank 2 because we have 2 pivots. We can pick an arbitrary number for x3
and then find values for x1 and x2 by solving each equation. Therefore there are infinite solutions.
1.5.6. Example of a system with three equations and three unknowns and no solution. Consider the
system of equations
x1 x2 + 2x3 = 5
2x1 + 3x2 x3 = 5
(50)
3x1 + 2x2 + x3 = 9
written in matrix form as
Ax = b
1 1 2
x1
5
(51)
2 3 1 x2 = 5
3 2
1
x3
9
The augmented matrix is of the form
1 1 2 5
(52)
A = 2 3 1 5
3 2 1 9
After appropriate row and column operations we obtain
1 0 1 4
0 1 1 1
(53)
0 0 0 1
The matrix A is of rank 2 because we have 2 non-zero rows in the reduced row echelon form. We
can also see that it is of rank 2 because we have 2 pivots. The third equation is inconsistent and so
the system has no solution.
(54)
14
We can perform row operations on this matrix to reduce it to reduced row echelon form. We will
do this in steps. The first step is to divide each element of the first row by a11 . This will make the
first pivot a one. This will give
A1 =
a12
a11
1
a21
a22
b1
a11
b2
(57)
a21 a12
a11
a21
a21 b1
a11
(58)
a22
b2
a21 a12
a11
a21 b1
a11
a22
a21
a21 a12
a11
(59)
a21 b1
a11
b2
A2 =
1
0
a12
a11
a11 a22 a21 a12
a11
b1
a11
a11 b2 a21 b1
a11
Now multiply the second row by the reciprocal of the element in the a22 position, i.e.
to obtain
A3 =
a12
a11
"
1
0
b1
a11
a11 b2 a21 b1
a11 a22 a21 a12
a12
a11
(60)
a11
a11 a22 a21 a12
(61)
and subtract it from the first row. First multiply the second
a12
a11
(62)
Now subtract the expression in equation 62 from the first row of A3 to obtain the following row.
h
a12
a11
b1
a11
h
0
a12
a11
h
= 1 0
b1
a11
Now replace the first row in A3 with the expression in equation 63 to obtain A4
A4 =
"
1 0
0 1
b1
a11
(63)
(64)
This can be simplified by putting the upper right hand term over a common denominator, and
canceling like terms as follows
A4 =
15
b1 a211 a22 b1 a11 a21 a12 a12 a211 b2 + a11 a12 a21 b1
a11 b2 a21 b1
a11 a22 a21 a12
a11 b2 a21 b1
a11 a22 a21 a12
b1 a22 a12 b2
a11 a22 a21 a12
a11 b2 a21 b1
a11 a22 a21 a12
(65)
We can now read off the solutions for x1 and x2 . They are
b1 a22
a11 a22
a11 b2
=
a11 a22
x1 =
x2
a12 b2
a21 a12
a21 b1
a21 a12
(66)
Each of the fractions has a common denominator. It is called the determinant of the matrix A.
Note that this part of the solution of the equation Ax=b does not depend on b; it will be the same
no matter what right hand side is chosen. That is why it is called the determinant of the matrix A
and not of the system Ax = b. The determinant of an arbitrary 2x2 matrix A is given by
det ( A ) = |A| = a11 a22 a21 a12
(67)
The determinant of the 2x2 matrix is given by difference in the product of the elements
along the
1 3
main diagonal and the reverse main diagonal. The determinant of the matrix A =
is 2-6 =
2 2
-4.
If we look closely at the solutions in equation 66, we can see that we can also write the numerator
of each expression as a determinant. In particular
x1 =
b1 a22 a12 b2
a11 a22 a21 a12
x2 =
a11 b2 a21 b1
a11 a22 a21 a12
b1 a12
b2 a22
=
|A|
a11 b1
a21 b2
=
|A|
The matrix of which we compute the determinant in the numerator of the first expression is
the matrix A, where the first column has been replaced by the b vector. The matrix of which we
compute the determinant in the numerator of the second expression is the matrix A where the second
column has been replaced by the b vector. This procedure for solving systems of equations is called
Cramers rule and will be discussed in more detail later. For those interested, here is a simple
example.
16
1.6.2. An example problem with Cramers rule. Consider the system of equations
3x1 + 5x2 = 11
(68)
8x1 3x2 = 13
Using Cramers rule
x1
b1 a12
b2 a22
=
=
|A|
x2
a11 b1
a21 b2
=
|A|
11 5
13 3
(33) (65)
98
=
=
= 2
3 5
(9)
(40)
49
8 3
3 11
8 13
(39) (88)
49
=
=
=
= 1
(9) (40)
49
3 5
8 3
(69)
2. Determinants
2.1. Introduction. Associated with every square matrix is a number called the determinant of the
matrix. The determinant provides a useful summary measurement of that matrix. Of particular
importance is whether the determinant of a matrix is zero. As we saw in section 1.6, elements of
the solution of the equation Ax = b for the 2x2 case can be written in terms of the determinant of
the matrix A. For a square matrix A, the equation Ax = 0 has a non-trivial solution (x 6= 0) if and
only if the determinant of A is zero.
2.2. Definition and analytical computation.
2.2.1. Definition of a determinant. The determinant of an n n matrix A = k aij k, written |A|,
is defined to be the number computed from the following sum where each element of the sum is the
product of n elements:
|A| =
(70)
the sum being taken over all n! permutations of the second subscripts. A term is assigned a plus
sign if (i,j, . . . ,r) is an even permutation of (1,2,. . . ,n) and a minus sign if it is an odd permutation.
An even permutation is defined as making an even number of switches of the indices in (1,2, . . . ,n),
similarly for an odd permutation. Thus each term in the summation is the product of n terms, one
term from each column of the matrix. Note that the first element of each pair does not change. We
always have a1. a2. a3. an. where it is only the second subscript that is changing.
When there are no switches in the indices from the natural order, the product will be a11 a22 a33
. . . ann or the product of the terms on the main diagonal. When the only switch is between the
subscripts 1 and 2 of the first two terms we obtain the product a12 a21 a33 . . . ann . This product
will be assigned a minus sign. If we switch subscripts 1 and 3 of the first and third terms we obtain
the product a13 a22 a31 . . . ann which also has a minus sign.
17
1 2
2 5
(71)
Here a11 = 1, a12 = 2, a21 = 2, and a22 = 5. There are two permutations of (1,2).
1: (1,2) is an even permutation with 0 switches of the indices (1,2): + a11 a22
2: (2,1) is odd permutation with 1 switch of the indices: - a12 a21
Notice that the permutations are over the second subscripts. The determinant of A is then
|A| = +a11 a22 a12 a21 = 1 5 2 2 = 1
(72)
The 2 x 2 case is easy to remember because there are just 2 rows and 2 columns. Each term
in the summation has two elements and there are two terms. The first term is the product of the
diagonal elements and the second term is the product of the off-diagonal elements. The first term
has a plus sign because the second subscripts are 1 and 2 while the second term has a negative sign
because the second subscripts are 2 and 1 (one permutation of 1 and 2).
2.2.3. Example 2. Now consider another 2x2 example
3
A=
8
5
3
(73)
Here a11 = 3, a12 = 5, a21 = 8, and a22 = -3. The determinant of A is given by
|A| = +a11 a22 a12 a21 = (3) (3) (8)(5) = 49
(74)
1
A = 0
1
2 3
5 2
0 4
(75)
The indices are the numbers 1, 2 and 3. There are 6 (3!) permutations of (1, 2, 3). They are as
follows: (1, 2, 3), (2, 1, 3), (1, 3, 2), (3, 2, 1), (2, 3, 1) and (3, 1, 2). The three in bold come
from switching one pair of indices in the natural order (1, 2, 3). The final two come from making a
switch in one of the bold sets. Specifically
1:
2:
3:
4:
5:
6:
(1,
(2,
(1,
(3,
(2,
(3,
2,
1,
3,
2,
3,
1,
3)
3)
2)
1)
1)
2)
is
is
is
is
is
is
Notice that the permutations are over the second subscripts, that is, every term is of the form
a1 . a2 . a3 . with the second subscript varying. The determinant of A is then
18
(76)
1 2 4
A = 2 1 3
1 2 0
The determinant of A is
(77)
19
(78)
a11
a21
A=
a31
a41
a12
a22
a32
a42
a13
a23
a33
a43
a14
a24
a34
a44
(79)
The indices are the numbers 1, 2, 3, and 4. There are 24 (4!) permutations of (1, 2, 3, 4).
They are contained in table 1. Notice that the permutations are over the second subscripts, that is,
every term is of the form a1 . a2 . a3 . a4 . with the second subscript varying. The general formula is
rather difficult to remember or implement for large n and so another method based on cofactors
is normally used.
2.3. Submatrices and partitions. Before discussing the computation of determinants using cofactors a few definitions concerning matrices and submatrices will be useful.
20
2.3.1. Submatrix. A submatrix is a matrix formed from a matrix A by taking a subset consisting
of j rows with column elements from a set k of the columns. For example consider A({1,3},{2,3})
below
3
A = 2
1
4 7
5 2
0 4
4 7
5 2
(80)
1 0 4
4 7
=
0 4
The notation A({1,3},{2,3}) means that we take the first and third rows of A and include the
second and third elements of each row.
2.3.2. Principal submatrix. A principal submatrix is a matrix formed from a square matrix A by
taking a subset consisting of n rows and column elements from the same numbered columns. For
example consider A({1,3},{1,3}) below
3
A = 2
1
4 7
5 2
0 4
4 7
5 2
21
(81)
1 0 4
3 7
=
1 4
2.3.3. Minor. A minor is the determinant of a square submatrix of the matrix A. For example
consider | A({2, 3}, {1, 3}) |.
3
A = 2
1
7
2
4
4 7
5 2
4
5
0
(82)
1 0 4
2 2
=
1 4
3
A = 2
1
7
2
4
4 7
5 2
4
5
0
(83)
1 0 4
3 4
=
2 5
22
3
A = 2
1
2
M22 =
7
2
4
4 7
5 2
= 3
0 4
4
5
0
a11 a12 . . .
a21 a22 . . .
Dk = .
..
..
..
.
.
(84)
7
4
a1k
a2k
.. ,
.
k = 1, 2, . . . , n
(85)
a1n
a2n
..
.
ann
(86)
2.3.7. Cofactor. The cofactor (denoted Aij ) of the element aij of any square matrix A is (-1)i+j times
the minor of A that is obtained by including all but the ith row and the jth column, or alternatively
the minor that is obtained by deleting the ith row and the jth column. For example consider the
matrix A.
3 4 7
a11 a12 a13
A = a21 a22 a23 = 2 5 2
(87)
1 0 4
a31 a32 a33
To find the cofactor of a12 we first find the submatrix that includes all rows and columns except
the first and second.
3 4 7
2 5 2 =
A({2, 3}, {1, 3}) =
1 0 4
2
1
2
4
(88)
We then multiply the determinant of this matrix by (-1)i+j . For the example element a12 , i+j =
1+2 = 3 and yields
2 2
cof actor(a12 ) = A12 = (1)3 |A({2, 3}, {1, 3}| = (1)3
1 4
(89)
= (1)3 (6) = 6
23
n
X
aij Aij
(90)
j=1
where i denotes the ith row of the matrix A. This is called an expansion of |A| by column i of A.
The result is the same for any other row. This can also be done for columns letting the sum range
over i instead of j.
2.4.2. Examples.
1: Consider as an example
4
B =
1
the following 2x2 matrix and expand using the first row
3
2
2 3
5 2
0 4
matrix, the relevant minors are
1 2 3
0 5 2
cof actor(b11 ) = B ({2, 3}, {2, 3}) =
1 0 4
1 2 3
0 5 2
cof actor(b12 ) = B ({2, 3}, {1, 3}) =
1 0 4
1 2 3
0 5 2
cof actor(b13 ) = B ({2, 3}, {1, 2}) =
1 0 4
1
B = 0
1
If we expand using the first row of the
(91)
24
2
+ 2 (1)3
4
0 2
4
1 4 + 3 (1)
0
1
5
0
1
B = 0
1
2 3
5 2
0 4
2
|B| = 1 (1)4
5
3
+ 0 (1)5
2
1 3
6
0 2 + 4 (1)
1
0
2
5
2
+ 0 (1)3
4
2 3
4
0 4 + 1 (1)
2
5
3
2
1
B = 0
1
2 3
5 2
0 4
5
|B| = 1 (1)2
0
1
A= 2
1
2 4
1 3
2 0
(92)
The determinant of A computed using the cofactor expansion along the third row is given
by
2
|A| = 1 (1)
1
4
4
+ 2 (1)5
3
1 4
6
2 3 + 0 (1)
1 2
2 1
akj Aij = 0 k 6= i
(93)
25
3
2
Expand row 1 using the 2nd row cofactors to obtain (4) (-1)(2+1) (3) + (3) (-1)(2+2 (4)
= -12 + 12 = 0.
2: example 2
4 3
6 2
1 3
1
3
1
3
3
This then gives for the cofactor expansion(4) (-1) (0) + (3) (1) (3) + (1) (-1) (9) = 0.
2.5.3. General principle. If we expand the rows of a matrix by alien cofactors, the expansion will
equal zero.
2.6. Singular and nonsingular matrices. The square matrix A is said to be singular if |A| = 0,
and nonsingular if |A| =
6 0.
2.6.1. Determinants, Minors, and Rank.
Theorem 1. The rank of an n n matrix A is k if and only if every minor in A of order k + 1
vanishes, while there is at least one minor of order k which does not vanish.
Proposition 1. Consider an n n matrix A.
1: det A= 0 if every minor of order n - 1 vanishes.
2: If every minor of order n equals zero, then the same holds for the minors of higher order.
3 (restatement of theorem): The largest among the orders of the non-zero minors generated by a matrix is the rank of the matrix.
26
1
0
0
1
= 1,
1 0
0 1
.. ..
. .
0 0
0 ...
0 ...
..
..
.
.
0 ...
0
0
.. = 1
.
1
2: If two rows A are interchanged, then the determinant of A changes sign, but keeps its
absolute value. If two columns of A are interchanged, then the determinant of A changes
sign, but keeps its absolute value.
3: The determinant is a linear function of each row separately. If the first row is multiplied
by , the determinant is multiplied by . If the first rows of two matrices are added, the
determinants are added. This rule applies only when other rows do not change. Consider
the following example matrices.
a11
a21
.
..
an1
a11 + b11
a21
..
an1
a12 + b12
a22
..
.
an2
a12
a22
..
.
an2
a13
a23
..
.
an3
a13 + b13
a23
..
.
an3
...
...
..
.
...
...
...
..
.
...
a11
a1n
a21
a2n
.. = ..
.
.
an1
ann
a11
a1n + b1n
a21
a2n
= .
..
..
an1
ann
a12
a22
..
.
an2
a12
a22
..
.
an2
a13
a23
..
.
an3
a13
a23
..
.
an3
...
...
..
.
...
...
...
..
.
...
a1n
a2n
..
.
ann
b11
a1n
a21
a2n
.. + ..
.
an1
ann
b12
a22
..
.
an2
b13
a23
..
.
an3
...
...
..
.
...
b1n
a2n
..
.
ann
0 3 5
0
7 + 0 2 7 , (First row of matrix on left is sum of two on right)
0 0 4
4
0 3 5
1 0 0
0 0
Second rows of first two matrices
2 0 + 0 0 7 + 0 2 7 ,
0 0 4 sum to second rows of matrices above
0 0 4
0 4
1 0 0
0 3 5
0 0
1 0 + 0 0 7 + 0 2 7 , (Factor 2 out of second row of first matrix above)
0 0 4
0 0 4
0 4
0 3 5
1 0 0
1 0 0
= (2)(4) 0 1 0 + 0 0 7 + 0 2 7 , (Factor 4 out of third row of first matrix above)
0 0 4
0 0 4
0 0 1
0 3 5
1 0 0
0
0
7
=8 +
+ 0 2 7
0 0 4
0 0 4
1
3 5
2 7 = 0
0
0 4
1
= 0
0
1
= 2 0
0
0
2
0
(94)
27
Property 3 can be used to show that if A is an n n matrix and is a real number then
|A| = n |A|.
4: If two rows or columns of A are equal, then |A| = 0.
5: If a scalar multiple of one row (or column) of A is added to another row (or column) of
A, then the value of the determinant does not change. This property can be used to show
that if two rows or columns of A are proportional, then |A| = 0. If we multiply one of the
rows by the factor of proportionality and add it to the other row, we will obtain a row of
zeroes and a row of zeroes implies det A = 0.
6: A matrix with a row (or column) of zeros has |A| = 0. Given this property of determinants,
the determinant in equation 94 is equal to 8 as the determinants of the two matrices on the
right are both zero.
7: If A is triangular, then det A = |A| = a11 a22 . . . ann = the product of the diagonal entries.
The product of the diagonal entries in equation 94 is equal to 8. This property, of course,
implies that the determinant of a diagonal matrix is the product of the diagonal elements.
8: If A is singular (to be defined later), then the determinant of A = 0. If A is invertible (to
be defined later), then det A 6= 0.
9: If A and B are both n n then |AB| = |A| |B|.
10: The determinant of A is equal to the determinant of A, i.e., |A| = |A |.
11: The determinant of a sum is not necessarily the sum of the determinants.
2.8. Student problem. Provide an example for each of items 1 -11 in section 2.7.
28
(95)
then we say that B is the inverse of A. Moreover, A is said to be invertible in this case. Because
BA = AB = I, the matrix A is also an inverse of Bthat is, A and B are inverses of each other.
Inverses are only defined for square matrices. We usually denote the inverse of A by A1 and write
A1 A = AA1 = I
(96)
3.2. Some examples of matrix inversion. Show that the following pairs of matrices are inverses
of each other.
4
6
1
1 1
1 2
2
3
1
3
1
3
31
1
3 1
3
2 3 17
16
3 1
21
0
71
3
7
31
2
7
10
21
(97)
BA =I B = A
3.7. Orthogonal matrices. A matrix A is called orthogonal if its inverse is equal to its transpose,
that is if
A1 = A
(98)
29
3.8. Finding the inverse of a 2x2 matrix. For a general 2x2 matrix A, we can find the inverse
using the following matrix equation
a11
a21
a12
a22
b11
b21
AB = I
b12
1
=
0
b22
(99)
0
1
a11
a21
a11
a21
1
0
and
0
b12
a12
=
1
b22
a22
a12
a22
b11
b21
We can solve each system using Cramers rule. For the first system we obtain
b11
b21
1 a12
0 a22
a22
=
=
a11 a22 a21 a12
a11 a12
a21 a22
and
a11 1
a21 0
a21
=
=
a
a
a
a
11 22 a21 a12
12
11
a21 a22
b12 =
a12
a11 a22 a21 a12
b22 =
a11
a21 a12
a11 a22
(100)
a11 a22
1
a12 a21
a22
a21
a12
a11
(101)
This leads to the familiar rule that to compute the determinant of a 2x2 matrix we switch the
diagonal elements, change the sign of the off-diagonal ones, and divide by the determinant.
3.9. Finding the inverse of a general n n matrix. The most efficient way to find the inverse
of an n n matrix is to use elementary row operations or elimination on the augmented matrix
[ A : I ]. Or in other words solve the following systems of equations for b1 , b2 , . . . , bn .
30
a11
a21
..
.
an1
a11
a21
..
.
an1
a12
a22
..
.
a13
a23
..
.
...
...
..
.
an2
an3
...
a12
a22
..
.
a13
a23
..
.
...
...
..
.
an2
an3
...
a11 a12 a13
a21 a22 a23
..
..
..
.
.
.
an1 an2 an3
As discussed in section 4, this is done by
a11 a12 a13
a21 a22 a23
..
..
..
.
.
.
an1 an2 an3
a1n
a2n
..
.
ann
a1n
a2n
..
.
ann
1
b11
0
b21
.. = ..
.
.
0
bn1
b12
0
b22
1
.. = ..
.
.
bn2
0
(102)
..
.
b1n
0
b2n
0
.. = ..
.
.
bnn
1
...
performing elimination on the matrix
. . . a1n 1 0 0 . . . 0
. . . a2n 0 1 0 . . . 0
..
..
.. .. ..
..
..
.
.
. . .
.
.
. . . ann 0 0 0 . . . 1
a1n
a2n
..
.
ann
...
...
..
.
(103)
The most effective computational way to find the inverse of a matrix is to use elementary row
operations. This is done by forming the augmented matrix [A : I] similar to the augmented matrix
we use when solving a system equation, except that we now add n columns of the identity matrix
instead of the right hand side vector in the equations system. In effect we are writing the system
AX = I
1
(104)
(105)
Ax =b
(106)
1 2
1
x1
=
2 3
0
x2
We can solve the system by appending the right hand side vector, b, to the matrix A to form the
matrix A and then use elimination to create an identity matrix in place of the A matrix. We do this
as follows.
A =
1
2
2 1
3 0
31
(107)
Add negative 2 times the first row to the second row to obtain
2 4 2
2
3
0
0
1 2
1 2
1
A1 =
0 1 2
(108)
1 2
0 1
(109)
A2 =
1
2
Now multiply the second row by -2 and add to the first row
A3
0
2 41 2 1
1
0
3
1 0 3
=
0 1 2
(110)
3
We can see that x1 = -3 and x2 = 2. So if we post multiply A by
we obtain the first
2
column of the identity matrix.
1 2
3
1
=
(111)
2 3
2
0
If we instead solve the system
0
Ax =
1
0
1 2
x1
=
1
2 3
x2
(112)
we obtain a vector that when premultiplied by the matrix A gives us the second column of the
identity matrix.
So we can find the inverse in general by solving the system.
x11
x21
A x31
..
.
xn1
x12
x22
x32
..
.
..
.
xn2
x1n
1
0
x2n
x3n
= 0
.. ..
. .
xn
0
0 0
1 0
0 1
.. ..
. .
0 0
...
...
...
..
.
...
0
0
..
.
1
(113)
32
A =
1 2
2 3
1
0
0
1
(114)
Add negative 2 times the first row to the swecond row to obtain
2 4 2
0
2
3
0
1
0
1 2
1
1 2
1 0
A1 =
0 1 2 1
(115)
1
0
2 1
1 2
0
1
(116)
Now multiply the second row by -2 and add to the first row
A3
0
2 4 21 2
1
0
3
2
1 0 3 2
=
0 1 2 1
1 0
(117)
3 2
=
2 1
(118)
2
1 0
=
3
0 1
(119)
1
A = 0
1
1 2 2
A = 0 4 1
1 0 2
2 2
4 1
0 2
1
0
0
0 0
1 0
0 1
Add negative 1 times the first row to the last row to obtain
(120)
(121)
1 2 2 1
0
0
1
0
2
0
0
1
0
2
0
1
0
1
1 2 2 1 0 0
A1 = 0 4 1 0 1 0
0 2 0 1 0 1
Now divide the second row by 4 to obtain
1 2
2
1
0 0
A2 = 0 1 1/4 0 1/4 0
0 2 0
1 0 1
Now multiply the second row by 2 and add to the third row
A3
Now multiply the third row by 2
0
2
1/2
0
1/2
0
0
2
0
1
0
1
0
0
1/2 1 1/2
1
1 2 2
1
0 0
= 0 1 1/4 0 1/4 0
0 0 1/2 1 1/2 1
1
A4 = 0
0
Now multiply the third row by negative
2 2
1
0
1 1/4 0 1/4
0 1 2 1
1/4 and add to the
0
1
1/4
0
0
1/4
0
1
0
1 2 2
1
A5 = 0 1 0 1/2
0 0 1 2
Now multiply the third row by negative 2 and add
A6
0
0
2
second row
0
1/4
0
1/2 1/4 1/2
1/2
0
1/2
0
0
0 1/2
1
2
to the first row
1
2
2
1
0
0
2
4
1
2
0
5
1 2 0 5
2
= 0 1 0 1/2 0
0 0 1 2 1
0
0
2 4
2 4
4
1/2
2
33
(122)
(123)
(124)
(125)
(126)
(127)
34
Now multiply the second row by negative 2 and add to the first row
A7
The inverse of A is then given by
1
2
0
5
0
2
0
1
1
0
0
4
1 0 0 4
2
= 0 1 0 1/2 0
0 0 1 2 1
A1
We can check this as follows
1
0
1
2
4
0
2 4
0
1
2 3
3
1/2
2
(128)
4 2 3
= 1/2 0 1/2
2 1
2
2
4 2
1 1/2 0
2
2 1
(129)
3
1 0
1/2 = 0 1
2
0 0
0
0
1
(130)
(131)
and then solving for the matrix X. Consider the following matrix
1
3
2
5
2
A = 2
4 11 7
(132)
4
b = 5
15
1
3
2
5
2
A = 2
4 11 7
(133)
as follows.
1
0
0
0 0
1 0
0 1
4
5
15
(134)
A21
2
6
2
5
0
1
1 3
= 0 1
4 11
4
2
2
0
2
2
2
2
7
A22
1
= 0
4
1
2
0
0
0
8
1
0
5
1
0
3
0 0 4
1 0 3
0 1 15
3
2
1
0
1
2 2 1
11 7
0
0
Now multiply the first row by -4 and add to the third row
A31
0 4
0 3
1 15
4
12
8 4
0
0
16
4
11
7
0
0
1
15
0
1
1 4
0
1
1
1 3 2
1
0 0 4
= 0 1 2 2 1 0 3
0 1 1 4 0 1 1
35
(135)
(136)
(137)
Now multiply the second row by -1 and add to the third row
A32
0
1
2
2
0
1
1 4
0
0
1
2
1 3 2
1
= 0 1 2 2
0 0
1 2
1
0
0
3
1
1
1
2
0 0 4
1 0 3
1 1 2
(138)
Now multiply the third row by 2 and add to the second row
A23
0
0
0
1
0
1
1 3
= 0 1
0 0
2
4
2
2 2 1
0
6
1
2
0
1
1 0
6 1
2 1
2
4
0
3
2
1
0 4
2 1
1 2
Now multiply the third row by negative 2 and add to the first row
(139)
36
A13
0
1
1
= 0
0
0
2
4
2
3
2
1
0
3
0
5
2
0
1
1
= 0
0
3
0
18
3
6
3
3
0
5
2 2
0
0
0
13
1
4
3
0 0 13 1 4 3
1 0 6 1 2 1
0 1 2 1 1 2
3 0
1 0
0 1
2 4
0
4
2
0
5 2 2 0
6 1
2 1
2 1
1 2
(140)
Now multiply the second row by 3 and add to the first row
A12
A1
The solution to the equation is given by
13 1
= 6 1
2 1
4
2
1
3
x = 1
2
(142)
(143)
(141)
1
3
2
3
4
2
5
2 1 = 5
4 11 7
2
15
(144)
x =A1 b
3
13 1
1 = 6 1
2
2 1
4
2
1
4
5
15
(145)
37
AC = B
(146)
DA = B
In the first case the matrix B must have n rows, while in the second B must have n columns.
Then we have the following theorem.
Theorem 2. If |A| =
6 0, then:
A C = B C = A1 B
(147)
D A = B D = B A1
As an example, solve the following system of equations using theorem 2.
3 x1 + 5 x2 = 14
(148)
8 x1 2 x2 = 22
We can write the system as
Ax = b
3 5
14
x1
A =
, b =
, x =
8 2
22
x2
14
x = A1 b = A1
22
(149)
1
=
(3) (2) (8) (5)
1 2 5
=
46 8 3
2
5
46
46
= 8
3
46
46
5
46
3
46
14
22
46
138
3
46
=
=
46
1
46
2 5
8 3
(150)
28
46
112
46
+ 110
46
66
46
(151)
6.2. Some example systems. Solve each of the following using matrix inversion
3x1 + x2 = 6
5x1 x2 = 2
4x1 + x2 = 10
3x1 + 2 x2 = 10
(152)
(153)
38
4x1 + 3 x2 = 10
x1 + 2 x2 = 5
(154)
4x1 + 3 x2 = 11
x1 + 2 x2 = 4
(155)
1 2 3
A = 0 5 2
(156)
1 0 4
Now find the cofactor of each element. For example the cofactor of the 1 in the upper left hand
corner is computed as
5 2
= 20
(157)
A11 = (1)(1+1)
0 4
Similarly the cofactor of a23 = 2 is given by
(2+3)
A23 = (1)
The entire matrix of cofactors
A11
A21
.
An1
is given by
A12
A22
An2
1 2
1 0 = 2
A1n
20
2 5
A2n
= 8
1
2
.
11 2 5
... Ann
...
...
(158)
(159)
A+
A11
A21
=
.
An1
A12
A22
...
...
An2
...
A1n
20
2 5
A2n
= 8
1
2
.
11 2 5
Ann
(160)
20 8 11
1
2
= 2
5 2
5
7.2. Finding an inverse matrix using adjoints. For a square nonsingular matrix A, its inverse
is given by
1
A+
(161)
A1 =
|A |
1 2
A = 0 5
1 0
20
Aij = 8
11
Now find the transpose of Aij
A+
The determinant of A is
39
3
2
4
(162)
2 5
1
2
2 5
20 8 11
1
2
= 2
5 2
5
(163)
|A| = 9
Putting it all together we obtain
A1
20
1
2
=
9
5
8 11
20/9 8/9 11/9
1
2 = 2/9
1/9
2/9
2
5
5/9 2/9
5/9
(164)
AA1
1 2
= 0 5
1 0
3
20/9 8/9 11/9
9/9 0
0
2 2/9
1/9
2/9 = 0 9/9 0 = I
4
5/9 2/9
5/9
0
0 9/9
(165)
(166)
a11
a21
Dj =
.
an1
formed from |A| by replacing the jth column with the column
a12
a22
.
an2
... a1 j1
... a2 j1
.
.
... an j1
b1
b2
.
bn
a1 j+1
a2 j+1
.
an j+1
a1n
a2n
.
ann
(167)
Then the general system of n equations in n unknowns has unique solution if |A| =
6 0. The solution
is
x1 =
D2
Dn
D1
, x2 =
, , xn =
|A|
|A|
|A|
(168)
40
(169)
or
a11 x1
a12 x2
a1n xn
b1
a21 x1
a22 x2
a2n xn
b2
a31 x1
a32 x2
a3n xn
b3
..
. =
..
.
..
. +
..
. +
(170)