matrix algebra and systems of equations … · matrix algebra and systems of equations 3 1.2.5....
TRANSCRIPT
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
1. SYSTEMS OF EQUATIONS AND MATRICES
1.1. Representation of a linear system. The general system of m equations in n unknowns can bewritten
a11x1 + a12x2 + · · · + a1nxn = b1
a21x1 + a22x2 + · · · + a2nxn = b2
a31x1 + a32x2 + · · · + a3nxn = b3
... +... + · · · +
... =...
am1x1 + am2x2 + · · · + amnxn = bm
(1)
In this system, the aij’s and bi’s are given real numbers; aij is the coefficient for the unknown xj
in the ith equation. We call the set of all aij’s arranged in a rectangular array the coefficient matrixof the system. Using matrix notation we can write the system as
Ax = b
a11 a12 · · · a1n
a21 a22 · · · a2n
a31 a32 · · · a3n
......
......
am1 am2 · · · amn
x1
x2
.
.xn
=
b1
b2
.
.bm
(2)
We define the augmented coefficient matrix for the system as
A =
a11 a12 · · · a1n b1
a21 a22 · · · a2n b2
a31 a32 · · · a3n b3
......
......
am1 am2 · · · amn bm
(3)
Consider the following matrix A and vector b
A =
1 2 12 5 2−3 −4 −2
, b =
38−4
(4)
We can then write
Date: September 1, 2005.1
2 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
Ax = b
1 2 12 5 2−3 −4 −2
x1
x2
x3
=
38−4
(5)
for the linear equation system
x1 + 2x2 + x3 = 3
2x1 + 5x2 + 2x3 = 8
−3x1 − 4x2 − 2x3 = −4
(6)
1.2. Row-echelon form of a matrix.
1.2.1. Leading zeroes in the row of a matrix. A row of a matrix is said to have k leading zeroes if thefirst k elements of the row are all zeroes and the (k+1)th element of the row is not zero.
1.2.2. Row echelon form of a matrix. A matrix is in row echelon form if each row has more leadingzeroes than the row preceding it.
1.2.3. Examples of row echelon matrices. The following matrices are all in row echelon form
A =
3 4 70 5 20 0 4
B =
1 0 10 0 20 0 0
(7)
C =
1 3 10 4 10 0 3
The matrix C would imply the equation system
x1 + 3x2 + x3 = b1
4x2 + x3 = b2
3x3 = b3
(8)
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 apivot. For the matrix A above the pivots are 3,5,4. For the matrix B they are 1,2 and for C they are1,4,3. For the matrix B there is no pivot in the last row.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 3
1.2.5. Reduced row echelon form. A row echelon matrix in which each pivot is a 1 and in which eachcolumn containing a pivot contains no other nonzero entries, is said to be in reduced row echelonform. This implies that columns containing pivots are columns of an identity matrix. The matricesD and E below are in reduced row echelon form.
D =
1 0 00 1 00 0 1
E =
1 0 00 1 00 0 0
(9)
The matrix F is in row echelon form but not in reduced row echelon form.
F =
0 1 5 0 30 0 0 1 10 0 0 0 10 0 0 0 0
(10)
1.2.6. Reducing a matrix to row echelon or reduced row echelon form. Any system of equations can bereduced to a system with the A portion of the augmented matrix A in echelon or reduced echelonform by performing what are called elementary row operations on the matrix A. These opera-tions are the some ones that we used when solving a linear system using the method of Gaussianelimination.
1: Changing the order in which the equations or rows are listed produces an equivalent sys-tem.
2: Multiplying both sides of a single equation of the system (or a single row of A) by a nonzeronumber (leaving the other equations unchanged) results in a system of equations that isequivalent to the original system.
3: Adding a multiple of one equation or row to another equation or row (leaving the otherequations unchanged) results in a system of equations that is equivalent to the originalsystem.
1.2.7. Rank.
Definition 1 (Rank). The number of non-zero rows in the row echelon form of an m × n matrix Aproduced 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 9 has rank 3, matrix E has rank 2, while matrix F in 10 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.
Definition 3 (Full row rank). We say that an m × n matrix A has full row rank if r = m. If r = m, allrows of A have pivots and the reduced row echelon form has no zero rows.
1.2.8. Solutions to equations (stated without proof).a: A system of linear equations with coefficient matrix A which is m × n, a right hand side
vector b which is m × 1, and augmented matrix A has a solution if and only if
rank (A) = rank (A)
4 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
b: A linear system of equations must have either no solution, one solution, or infinitely manysolutions.
c: If the rank of A = r = n < m, the linear system Ax = b has no solution or exactly one solution.In other words, if the matrix A is of full column rank and has less columns than rows, thesystem will be inconsistent, or will have exactly one solution.
d: If the rank of A = r = m < n, the linear system Ax = b will always have a solution andthere will be an infinite number of solutions. In other words, if the matrix A is of full rowrank and has more columns than rows, the system will always have an infinite number ofsolutions.
e: If the rank of A = r where r< m and r < n, the linear system Ax = b will either have nosolutions or there will be an infinite number of solutions. In other words, if the matrix Ahas neither full row nor column rank, the system will be inconsistent or will have an infinitenumber of solutions.
f: If the rank of A = r = m = n, the linear system Ax = b will exactly one solution. In otherwords, if the matrix A is square and has full rank, the system will have a unique solution.
A coefficient matrix is said to be nonsingular, that is, the corresponding linear systemhas one and only one solution for every choice of right hand side b1, b2, ... , bm, if and onlyif
number of rows of A = number of columns of A = rank (A)
1.3. Solving systems of linear equations by finding the reduced echelon form of a matrix andback substitution. To solve a system of linear equations represented by a matrix equation, we firstadd 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 untilit is in row echelon form or reduced row echelon form. If the matrix is in row echelon we can solveit by back substitution, if it is in reduced row echelon form we can read the coefficients off directlyfrom the matrix. Consider matrix equation 5 with its augmented matrix A.
Ax = b
1 2 12 5 2−3 −4 −2
x1
x2
x3
=
38−4
A =
1 2 1 32 5 2 8−3 −4 −2 −4
(11)
Step 1. Consider the first row and the first column of the matrix. Element a11 is a non-zero numberand so is appropriate for the first row of the row echelon form. If element a11 were zero, wewould 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 thesecond row have one more leading zero than the first row. We can turn the a21 element intoa zero by adding negative 2 times the first row to the second row.
−2 ×(1 2 1 3
)
⇒(−2 −4 −2 −6
)
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 5
−2 −4 −2 −62 5 2 8
−− −− −− −−0 1 0 2
This will give a new matrix on which to operate. Call it A1.
A1 =
1 2 1 30 1 0 2−3 −4 −2 −4
(12)
We can obtain A1 by premultiplying A by what is called the a21 elimination matrix de-noted by E21 where E21 is given by
E21 =
1 0 0−2 1 00 0 1
(13)
The first and third rows of E21 are just rows of the identity matrix because the first andthird rows of A and A1 are the same. The second row of A1 is a linear combination of therows of A where we add negative 2 times the first row of A to 1 times the second row of A.To convince yourself of this fact remember what it means to premultiply a matrix by a rowvector. For example
(1 0 2
)
1 22 5−3 −4
=
(−5 −6
)
For the case at hand we have
A1 =
1 0 0−2 1 00 0 1
1 2 1 32 5 2 8−3 −4 −2 −4
=
1 2 1 30 1 0 2−3 −4 −2 −4
(14)
Step 3. Use row operations to ”knock out” a31 by turning it into a zero. This would then make thethird row have one more leading zero than the first row. We can turn the a31 element into azero by adding 3 times the first row to the third row.
3×(1 2 1 3
)
⇒(3 6 3 9
)
3 6 3 9−3 −4 −2 −4−− −− −− −−0 2 1 5
This will give a new matrix on which to operate. Call it A2.
A2 =
1 2 1 30 1 0 20 2 1 5
(15)
6 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
We can obtain A2 by premultiplying A1 by what is called the a31 elimination matrixdenoted by E31 where E31 is given by
E31 =
1 0 00 1 03 0 1
(16)
The first and second rows of E31 are just rows of the identity matrix because the first andsecond rows of A1 and A2 are the same. The third row of A2 is a linear combination of therows of A1 where we add 3 times the first row of A1 to 1 times the third row of A1. For thecase at hand we have
A2 =
1 0 00 1 03 0 1
1 2 1 30 1 0 2−3 −4 −2 −4
=
1 2 1 30 1 0 20 2 1 5
(17)
Step 4. Use row operations to ”knock out” a32 by turning it into a zero. This would then make thethird row have one more leading zero than the second row. We can turn the a32 elementinto 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 −4
)
0 −2 0 −40 2 1 5
−− −− −− −−0 0 1 1
This will give a new matrix on which to operate. Call it A3.
A3 =
1 2 1 30 1 0 20 0 1 1
(18)
We can obtain A3 by premultiplying A3 by what is called the a32 elimination matrixdenoted by E32 where E32 is given by
E32 =
1 0 00 1 00 −2 1
(19)
The first and second rows of E32 are just rows of the identity matrix because the first andsecond rows of A2 and A3 are the same. The third row of A3 is a linear combination of therows of A2 where we add negative 2 times the first second of A2 to 1 times the third row ofA2. For the case at hand we have
A3 =
1 0 00 1 00 −2 1
1 2 1 30 1 0 20 2 1 5
=
1 2 1 30 1 0 20 0 1 1
(20)
We can then read off the solution for x3 because the third equation says that x3 = 1. Thesecond equation says that x2 = 2. We then solve for x1 by substituting in the first equationas follows.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 7
x1 + 2x2 + x3 = 3
⇒ x1 + 2(2) + (1) = 3
⇒ x1 + 4 + 1 = 3
⇒ x1 = − 2
(21)
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 handside vector to the coefficient matrix to form the augmented coefficient matrix. We then performelementary row and column operations on the augmented coefficient matrix until it is in reducedrow echelon form. We can read the coefficients off directly from the matrix. Consider the system ofequations in section 1.3
Ax = b
1 2 12 5 2−3 −4 −2
x1
x2
x3
=
38−4
A =
1 2 1 32 5 2 8−3 −4 −2 −4
(22)
After performing suitable row operations we obtained the matrix A3 in equation 20
A3 =
1 2 1 30 1 0 20 0 1 1
(23)
¿From this equation system we obtained the solutions by back substitution. To find the reducedrow echelon form we need to eliminate all non-zero entries in the pivot columns. We begin withcolumn 3. The a23 element is already zero, so we can proceed to the a13 element. We denote this instep 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
)
⇒(0 0 −1 −1
)
0 0 −1 −11 2 1 3
−− −− −− −−1 2 0 2
This will give a new matrix on which to operate. Call it A4.
A4 =
1 2 0 20 1 0 20 0 1 1
(24)
8 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
We can obtain A4 by premultiplying A3 by what is called the a13 elimination matrixdenoted by E13 where E13 is given by
E13 =
1 0 −10 1 00 0 1
(25)
For the case at hand we have
A4 =
1 0 −10 1 00 0 1
1 2 1 30 1 0 20 0 1 1
=
1 2 0 20 1 0 20 0 1 1
(26)
The third column of the matrix has a pivot in the third row and zeroes in the first andsecond rows.
Step 6. Use row operations to ”knock out” a12 by turning it into a zero. We can turn the a12 elementinto a zero by adding negative 2 times the second row to the first row.
−2 ×(0 1 0 2
)
⇒(0 −2 0 −4
)
0 −2 0 −41 2 0 2
−− −− −− −−1 0 0 −2
This will give a new matrix on which to operate. Call it A5.
A5 =
1 0 0 −20 1 0 20 0 1 1
(27)
We can obtain A5 by premultiplying A4 by what is called the a12 elimination matrixdenoted by E12 where E12 is given by
E12 =
1 −2 00 1 00 0 1
(28)
For the case at hand we have
A5 =
1 −2 00 1 00 0 1
1 2 0 20 1 0 20 0 1 1
=
1 0 0 −20 1 0 20 0 1 1
(29)
It is obvious that x1 = -2, x2 = 2, and x3 = 1.
1.5. Systems of linear equations and determinants.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 9
1.5.1. Solving a general 2x2 equation system using elementary row operations. Consider the followingsimple 2x2 system of linear equations where the A matrix is written in a completely general form.
a11 x1 + a12x2 = b1
a21 x1 + a22 x2 = b2
(30)
We can write this in matrix form as
Ax = b
A =[
a11 a12
a21 a22
], x =
[x1
x2
], b =
[b1
b2
].
(31)
If we append the column vector b to the matrix A, we obtain the augmented matrix for thesystem. This is written as
A =[
a11 a12 b1
a21 a22 b2
](32)
We can perform row operations on this matrix to reduce it to reduced row echelon form. We willdo this in steps. The first step is to divide each element of the first row by a11. This will make thefirst pivot a one. This will give
A1 =[
1 a12a11
b1a11
a21 a22 b2
](33)
Now multiply the first row by a21 to yield[
a21a21 a12
a11
a21 b1
a11
](34)
and subtract it from the second row
a21 a22 b2
a21a21 a12
a11
a21 b1
a11
−−− − −− − − −− −
0 a22 − a21 a12
a11b2 − a21 b1
a11
(35)
This will give a new matrix on which to operate.
A2 =
[1 a12
a11
b1a11
0 a11 a22 − a21 a12a11
a11 b2 − a21 b1a11
](36)
Now multiply the second row by a11a11 a22 − a21 a12
to obtain
A3 =
[1 a12
a11
b1a11
0 1 a11 b2 − a21 b1a11 a22 − a21 a12
](37)
Now multiply the second row by a12a11
and subtract it from the first row. First multiply the secondrow by a12
a11to yield.
[0 a12
a11
a12 (a11 b2 − a21 b1 )a11 ( a11 a22 − a21 a12 )
](38)
10 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
Now subtract the expression in equation 38 from the first row of A3 to obtain the following row.
[1 a12
a11
b1a11
]−
[0 a12
a11
a12 (a11 b2−a21 b1)a11 (a11 a22−a21 a12)
]=
[1 0 b1
a11− a12 (a11 b2−a21 b1)
a11 (a11 a22−a21 a12)
](39)
Now replace the first row in A3 with the expression in equation 39 to obtain A4
A4 =
[1 0 b1
a11− a12 (a11 b2 − a21 b1 )
a11 ( a11 a22 − a21 a12 )
0 1 a11 b2 − a21 b1a11 a22 − a21 a12
](40)
This can be simplified by putting the upper right hand term over a common denominator, andcanceling like terms as follows
A4 =
[1 0 b1 a2
11 a22 − b1 a11 a21 a12 − a12 a211 b2 + a11 a12 a21 b1
a211 ( a11 a22 − a21 a12 )
0 1 a11 b2 − a21 b1a11 a22 − a21 a12
]
=
[1 0 b1 a2
11 a22 −a12 a211 b2
a211 ( a11 a22 − a21 a12 )
0 1 a11 b2 − a21 b1a11 a22 − a21 a12
]
=
[1 0 b1 a22 −a12 b2
a11 a22 − a21 a12
0 1 a11 b2 − a21 b1a11 a22 − a21 a12
]
(41)
We can now read off the solutions for x1 and x2. They are
x1 =b1 a22 − a12 b2
a11 a22 − a21 a12
x2 =a11 b2 − a21 b1
a11 a22 − a21 a12
(42)
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 sameno matter what right hand side is chosen. That is why it is called the determinant of the matrix Aand not of the system Ax = b. The determinant of an arbitrary 2x2 matrix A is given by
det ( A ) = |A| = a11 a22 − a21 a12 (43)
The determinant of the 2x2 matrix is given by difference in the product of the elements along the
main diagonal and the reverse main diagonal. The determinant of the matrix A =[1 32 2
]is 2-6 =
-4.If we look closely at the solutions in equation 42, 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=
∣∣∣∣b1 a12
b2 a22
∣∣∣∣|A |
x2 =a11 b2 − a21 b1
a11 a22 − a21 a12=
∣∣∣∣a11 b1
a21 b2
∣∣∣∣|A |
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 11
The matrix of which we compute the determinant in the numerator of the first expression isthe matrix A, where the first column has been replaced by the b vector. The matrix of which wecompute the determinant in the numerator of the second expression is the matrix A where thesecond column has been replaced by the b vector. This procedure for solving systems of equationsis called Cramer’s rule and will be discussed in more detail later. For those interested, here is asimple example.
1.5.2. An example problem with Cramer’s rule. Consider the system of equations
3x1 + 5x2 = 11 (44)8x1 − 3x2 = 13
Using Cramer’s rule
x1 =
∣∣∣∣b1 a12
b2 a22
∣∣∣∣|A |
=
∣∣∣∣11 513 −3
∣∣∣∣∣∣∣∣3 58 −3
∣∣∣∣=
(−33) − (65)(−9) − (40)
=−98−49
= 2 (45)
x2 =
∣∣∣∣a11 b1
a21 b2
∣∣∣∣|A | =
∣∣∣∣3 118 13
∣∣∣∣∣∣∣∣3 58 −3
∣∣∣∣=
(39) − (88)(−9) − (40)
=− 49−49
= 1
2. DETERMINANTS
2.1. Introduction. Associated with every square matrix is a number called the determinant of thematrix. The determinant provides a useful summary ”measurement” of that matrix. Of particularimportance is whether the determinant of a matrix is zero. As we saw in section 1.5, elements ofthe solution of the equation Ax = b for the 2x2 case can be written in terms of the determinant ofthe matrix A. For a square matrix A, the equation Ax = 0 has a non-trivial solution (x 6= 0) if andonly 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 = ‖ aij ‖, written |A|, isdefined to be the number computed from the following sum where each element of the sum is theproduct of n elements:
|A| =∑
(±) a1i a2 j ...anr, (46)
the sum being taken over all n! permutations of the second subscripts. A term is assigned aplus 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, oneterm from each column of the matrix.
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 thesubscripts 1 and 2 of the first two terms we obtain the product a12 a21 a33 . . . ann. This product will
12 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
be assigned a minus sign. If we switch subscripts 1 and 3 of the first and third terms we obtain theproduct a13 a22 a31 . . . ann which also has a minus sign.
2.2.2. Example 1. As a first example consider the following 2x2 case
A =(
1 22 5
)(47)
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 (48)
The 2 x 2 case is easy to remember because there are just 2 rows and 2 columns. Each term in thesummation has two elements and there are two terms. The first term is the product of the diagonalelements and the second term is the product of the off-diagonal elements. The first term has a plussign because the second subscripts are 1 and 2 while the second term has a negative sign becausethe second subscripts are 2 and 1 (one permutation of 1 and 2).
2.2.3. Example 2. Now consider another 2x2 example
A =(
3 58 −3
)(49)
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 (50)
2.2.4. Example 3. Consider the following 3x3 case
A =
1 2 30 5 21 0 4
(51)
The indices are the numbers 1, 2 and 3. There are 6 (3!) permutations of (1, 2, 3). They areas 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 fromswitching one pair of indices in the natural order (1, 2, 3). The final two come from making a switchin one of the bold sets. Specifically
1: (1, 2, 3) is even (0 switches): + a11 a22 a33
2: (2, 1, 3) is odd (1 switches): - a12 a21 a33
3: (1, 3, 2) is odd (1 switches): - a11 a23 a32
4: (3, 2, 1) is odd (1 switches): - a13 a22 a31
5: (2, 3, 1) is even (2 switches): + a12 a23 a31
6: (3, 1, 2) is even (2 switches): + a13 a21 a32
Notice that the permutations are over the second subscripts, that is, every term is of the forma1 . a2 . a3 . with the second subscript varying. The determinant of A is then
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 13
|A| = + a11 a22 a33
−a12 a21 a33
−a11 a23, a32
−a13 a22 a31
+a12 a23 a31
+a13 a21 a32
= 20− 0 − 0 − 15 + 4 + 0 = 9
(52)
The first subscripts in each term do not change but the second subscripts range over all permu-tations of the numbers 1, 2, 3, ... , n. The first term is the product of the diagonal elements and has aplus sign because the second subscripts are (1, 2, 3). The last term also has a plus sign because thesecond subscripts are (3, 1, 2). This permutation come from 2 switches [(1, 2, 3) → (3,2,1) → (3,1,2)].
A simple way to remember this formula for a 3x3 matrix is to use diagram in figure 1. Theelements labeled 1j are multiplied together and receive a plus sign in the summation.
FIGURE 1. 3 x 3 Determinant – Plus Signs
The elements labeled 2j are multiplied together and receive a minus sign in the summation as infigure 2.
2.2.5. Example 4. Consider the following 3x3 case
A =
−1 2 42 1 −3−1 2 0
(53)
14 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
FIGURE 2. 3 x 3 Determinant – Minus Signs
The determinant of A is
|A| = + a11 a22 a33
+a12 a23 a31
+a13 a21 a32
−a13 a22 a31
−a12 a21 a33
−a11 a23, a32
= 0 + 6 + 16 − (−4) − 0 − 6 = 20
(54)
2.2.6. Example 5. Consider the following 4x4 case
A =
a11 a12 a13 a14
a21 a22 a23 a24
a31 a32 a33 a34
a41 a42 a43 a44
(55)
The indices are the numbers 1, 2, 3, and 4. There are 24 (4!) permutations of (1, 2, 3, 4). Theyare contained in table 1. Notice that the permutations are over the second subscripts, that is, everyterm is of the form a1 . a2 . a3 . a4 . with the second subscript varying. The general formula is ratherdifficult to remember or implement for large n and so another method based on ”cofactors” isnormally used.
2.3. Submatrices and partitions. Before discussing the computation of determinants using cofac-tors a few definitions concerning matrices and submatrices will be useful.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 15
TABLE 1. Determinant of a 4x4 Matrix
Permutation Sign element of sum Permutation Sign element of sum1234 + a11a22a33a44 3142 - a13a21a34a42
1243 - a11a22a34a43 3124 + a13a21a32a44
1324 - a11a23a32a44 3214 - a13a22a31a44
1342 + a11a23a34a42 3241 + a13a22a34a41
1432 - a11a24a33a42 3421 - a13a24a32a41
1423 + a11a24a32a43 3412 + a13a24a31a42
2134 - a12a21a33a44 4123 - a14a21a32a43
2143 + a12a21a34a43 4132 + a14a21a33a42
2341 - a12a23a34a41 4231 - a14a22a33a41
2314 + a12a23a31a44 4213 + a14a22a31a43
2413 - a12a24a31a43 4312 - a14a23a31a42
2431 + a12a24a33a41 4321 + a14a23a32a41
2.3.1. Submatrix. A submatrix is a matrix formed from a matrix A by taking a subset consisting of jrows with column elements from a set k of the columns. For example consider A({1,3},{2,3}) below
A =
3 4 72 5 21 0 4
, A({1, 3}, {2, 3}) =
(4 70 4
)(56)
The notation A({1,3},{2,3}) means that we take the first and third rows of A and include thesecond and third elements of each row.
2.3.2. Principal submatrix. A principal submatrix is a matrix formed from a square matrix A bytaking a subset consisting of n rows and column elements from the same numbered columns. Forexample consider A({1,3},{1,3}) below
A =
3 4 72 5 21 0 4
, A({1, 3}, {1, 3}) =
(3 71 4
)(57)
2.3.3. Minor. A minor is the determinant of a square submatrix of the matrix A. For example con-sider |A({2, 3}, {1,3}) |.
A =
3 4 72 5 21 0 4
, A({2, 3}, {1, 3}) =
(2 21 4
), |A ({2, 3}, {1, 3}) | = 6 (58)
2.3.4. Principal minor. A principal minor is the determinant of a principal submatrix of A. For ex-ample consider |A({1, 2}, {1,2}) |.
A =
3 4 72 5 21 0 4
, A({1, 2}, {1, 2}) =
(3 42 5
), |A({1, 2}, {1, 2}) | = 7 (59)
16 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
2.3.5. Leading principal minor. Let A =(aij) be any n × n . The leading principle minors of A are then determinants:
Dk =
a11 a12 . . . a1k
a21 a22 . . . a2k
......
. . ....
ak1 ak2 . . . akk
, k = 1, 2, . . . , n (60)
Dk is obtained by crossing out the last n-k columns and n-k rows of the matrix. Thus for k = 1,2, 3, . . . n, the leading principle minors are, respectively
a11,
∣∣∣∣a11 a12
a21 a22
∣∣∣∣ ,
∣∣∣∣∣∣
a11 a12 a13
a21 a22 a23
a31 a32 a33
∣∣∣∣∣∣, . . . ,
∣∣∣∣∣∣∣∣∣
a11 a12 . . . a1n
a21 a22 . . . a2n
......
. . ....
an1 an2 . . . ann
∣∣∣∣∣∣∣∣∣(61)
2.3.6. Cofactor. The cofactor (denoted Aij) of the element aij of any square matrix A is (-1)i+j timesthe minor of A that is obtained by including all but the ith row and the jth column, or alternativelythe minor that is obtained by deleting the ith row and the jth column. For example the cofactor ofa12 below is found as
A =
a11 a12 a13
a21 a22 a23
a31 a32 a33
=
3 4 72 5 21 0 4
A({2, 3}, {1, 3} =(
2 21 4
)
A12 =(−1)3 |A({2, 3}, {1, 3} | = (−1)3∣∣∣∣2 21 4
∣∣∣∣
= (−1)3 (6) = −6
(62)
2.4. Computing determinants using cofactors.
2.4.1. Definition of a cofactor expansion. The determinant of a square matrix A can be found induc-tively using the following formula
det A = |A | =n∑
j=1
aij Aij (63)
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 rangeover i instead of j.
2.4.2. Examples.
1: Consider as an example the following 2x2 matrix and expand using the first row
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 17
B =(
4 31 2
)
|B| = 4 ∗ (−1)2 ∗ (2) + 3 ∗ (−1)3 ∗ (1) = 8 − 3 = 5
where the cofactor of 4 is (-1)(1+1) times the submatrix that remains when we delete rowand column 1 from the matrix B while the cofactor of 3 is (-1)(1+2) times the submatrixthat remains when we delete row 1 and column 2 from the matrix B. In this case each theprinciple submatrices are just single numbers so there is no need to formally compute adeterminant.
2: Now consider a 3x3 example computed using the first row of the matrix.
B =
1 2 30 5 21 0 4
|B| = 1 ∗ (−1)2∣∣∣∣5 20 4
∣∣∣∣ + 2 ∗ (−1)3∣∣∣∣0 21 4
∣∣∣∣ + 3 ∗ (−1)4∣∣∣∣0 51 0
∣∣∣∣= (1) ∗ (20) + (−2) ∗ (−2) + 3 ∗ (−5) = 9
We can also compute it using the third row of the matrix
B =
1 2 30 5 21 0 4
|B| = 1 ∗ (−1)4∣∣∣∣2 35 2
∣∣∣∣ + 0 ∗ (−1)5∣∣∣∣1 30 2
∣∣∣∣ + 4 ∗ (−1)6∣∣∣∣1 20 5
∣∣∣∣= (1) ∗ (−11) + (0) ∗ (2) + (4) ∗ (5) = 9
or the first column
B =
1 2 30 5 21 0 4
|B| = 1 ∗ (−1)2∣∣∣∣5 20 4
∣∣∣∣ + 0 ∗ (−1)3∣∣∣∣2 30 4
∣∣∣∣ + 1 ∗ (−1)4∣∣∣∣2 35 2
∣∣∣∣= (1) ∗ (20) + (0) ∗ (−8) + (1) ∗ (−11) = 9
3: Consider the following 3x3 matrix
A =
−1 2 42 1 −3−1 2 0
(64)
The determinant of A computed using the cofactor expansion along the third row isgiven by
18 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
|A| = − 1 ∗ (−1)4∣∣∣∣2 41 −3
∣∣∣∣ + 2 ∗ (−1)5∣∣∣∣−1 42 −3
∣∣∣∣ + 0 ∗ (−1)6∣∣∣∣−1 22 1
∣∣∣∣= (−1) ∗ (−10) + (−2) ∗ (−5) + (0) ∗ (−5) = 20
2.5. Expansion by alien cofactors.
2.5.1. Definition of expansion by alien cofactors. When we expand a row of the matrix using the co-factors of a different row we call it expansion by alien cofactors.
∑
j
akj Aij = 0 k 6= i (65)
2.5.2. Some examples.
1: example 1
∣∣∣∣∣∣
4 3
1 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 1
6 2 3
1 3 1
∣∣∣∣∣∣∣∣∣∣Expand row 1 using the 2nd row cofactors. The second row cofactors are
(−1)(2+1)
∣∣∣∣3 13 1
∣∣∣∣and
(−1)(2+2)
∣∣∣∣4 11 1
∣∣∣∣and
(−1)(2+3)
∣∣∣∣4 31 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 willequal zero.
2.6. Singular and nonsingular matrices. The square matrix A is said to be singular if |A| = 0, andnonsingular if |A| 6= 0.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 19
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.
2.7. Basic rules for determinants.
1: The determinant of an n × n identity matrix is 1.
[1 00 1
]= 1,
1 0 0 . . . 00 1 0 . . . 0...
......
......
0 0 0 . . . 1
= 1
2: If two rows A are interchanged, then the determinant of A changes sign, but keeps itsabsolute value. If two columns of A are interchanged, then the determinant of A changessign, 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 first rows are added, the determinants are added.This rule applies only when other rows do not change. Consider the following examplematrices.
∣∣∣∣∣∣∣∣∣
α a11 α a12 αa13 . . . αa1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣= α
∣∣∣∣∣∣∣∣∣
a11 a12 a13 . . . a1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣
a11 + b11 a12 + b12 a13 + b13 . . . a1n + b1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣=
∣∣∣∣∣∣∣∣∣
a11 a12 a13 . . . a1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣+
∣∣∣∣∣∣∣∣∣
b11 b12 b13 . . . b1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣
Or consider the following numerical example
20 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
∣∣∣∣∣∣
1 3 50 2 70 0 4
∣∣∣∣∣∣=
∣∣∣∣∣∣
1 0 00 2 70 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
0 3 50 2 70 0 4
∣∣∣∣∣∣
=
∣∣∣∣∣∣
1 0 00 2 00 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
1 0 00 0 70 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
0 3 50 2 70 0 4
∣∣∣∣∣∣
= 2
∣∣∣∣∣∣
1 0 00 1 00 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
1 0 00 0 70 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
0 3 50 2 70 0 4
∣∣∣∣∣∣
= (2)(4)
∣∣∣∣∣∣
1 0 00 1 00 0 1
∣∣∣∣∣∣+
∣∣∣∣∣∣
1 0 00 0 70 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
0 3 50 2 70 0 4
∣∣∣∣∣∣
= 8 +
∣∣∣∣∣∣
1 0 00 0 70 0 4
∣∣∣∣∣∣+
∣∣∣∣∣∣
0 3 50 2 70 0 4
∣∣∣∣∣∣
(66)
Property 3 can be used to show that if A is an x times n matrix and α is a real numberthen |α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 thatif two rows or columns of A are proportional, then |A| = 0. If we multiply one of the rowsby the factor of proportionality and add it to the other row, we will obtain a row of zeroesand 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 66 is equal to 8 as the determinants of the two matrices on theright 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 66 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 bedefined later), then det A 6= 0.
9: If A and B are both x × 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. Some problems to solve. Provide an example for each of items 1 -11 in section 2.7.
3. THE INVERSE OF A MATRIX A
3.1. Definition of the inverse of a matrix. Given a matrix A, if there exists a matrix B such that
AB = BA = I (67)
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 B - that is, A and B are inverses of each other. Inverses
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 21
are only defined for square matrices. We usually denote the inverse of A by A−1 and write
A−1A = AA−1 = I (68)
3.2. Some examples of matrix inversion. Show that the following pairs of matrices are inverses ofeach other.
[1 −11 2
] [23
13
−13
13
]
4 3 16 2 31 3 1
13
0 − 13
17
− 17
27
−1621
37
1021
3.3. Existence of the inverse. A square matrix A has an inverse ⇔ |A| 6= 0. A square matrix is saidto be singular if |A| = 0 and nonsingular if |A| 6= 0. Thus a matrix has an inverse if and only if it isnonsingular.
3.4. Uniqueness of the inverse. The inverse of a square matrix is unique if it exists.
3.5. Some implications of inverse matrices.
AX =I ⇒ X = A−1 (69)
BA =I ⇒ B = A−1
3.6. Properties of the inverse. Let A and B be invertible n × n matrices.
1: A−1 is invertible and (A−1)−1 = A2: AB is invertible and (AB)−1 = B−1A−1
3: A′ is invertible and (A−1)′ = (A′)−1
4: (ABC)−1 = C−1B−1A−1, if A, B, and C have inverses5: (cA)−1 = c−1 A−1 whenever c is a number 6= 06: In general, (A + B)−1 6= A−1 + B−1
3.7. Orthogonal matrices. A matrix A is called orthogonal if its inverse is equal to its transpose,that is if
A−1 = A′ (70)
3.8. Finding the inverse of a 2x2 matrix. For a general 2x2 matrix A, we can find the inverse usingthe following matrix equation
A B = I (71)[a11 a12
a21 a22
] [b11 b12
b21 b22
]=
[1 00 1
]
We can divide this into two parts as follows
22 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
[a11 a12
a21 a22
] [b11
b21
]=
[10
](72)
and[
a11 a12
a21 a22
] [b12
b22
]=
[01
]
We can solve each system using Cramer’s rule. For the first system we obtain
b11 =
∣∣∣∣1 a12
0 a22
∣∣∣∣∣∣∣∣
a11 a12
a21 a22
∣∣∣∣=
a22
a11 a22 − a21 a12(73)
and
b21 =
∣∣∣∣a11 1a21 0
∣∣∣∣∣∣∣∣
a11 a12
a21 a22
∣∣∣∣=
−a21
a11 a22 − a21 a12
In a similar fashion we can show that
b12 =−a12
a11 a22 − a21 a12(74)
b22 =a11
a11 a22 − a21 a12
Combining the expressions we see that
A−1 =1
a11 a22 − a12 a21
[a22 −a12
−a21 a11
](75)
This leads to the familiar rule that to compute the determinant of a 2x2 matrix we switch thediagonal 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 ofan 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.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 23
∣∣∣∣∣∣∣∣∣
a11 a12 a13 . . . a1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣
∣∣∣∣∣∣∣∣∣
b11
b21
...bn1
∣∣∣∣∣∣∣∣∣=
∣∣∣∣∣∣∣∣∣
10...0
∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣∣
a11 a12 a13 . . . a1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣
∣∣∣∣∣∣∣∣∣
b12
b22
...bn2
∣∣∣∣∣∣∣∣∣=
∣∣∣∣∣∣∣∣∣
01...0
∣∣∣∣∣∣∣∣∣
...∣∣∣∣∣∣∣∣∣
a11 a12 a13 . . . a1n
a21 a22 a23 . . . a2n
......
......
...an1 an2 an3 . . . ann
∣∣∣∣∣∣∣∣∣
∣∣∣∣∣∣∣∣∣
b1n
b2n
...bnn
∣∣∣∣∣∣∣∣∣=
∣∣∣∣∣∣∣∣∣
00...1
∣∣∣∣∣∣∣∣∣
(76)
As discussed in section 6, this is done by performing elimination on the matrix
∣∣∣∣∣∣∣∣∣
a11 a12 a13 . . . a1n 1 0 0 . . . 0a21 a22 a23 . . . a2n 0 1 0 . . . 0
......
......
......
......
......
an1 an2 an3 . . . ann 0 0 0 . . . 1
∣∣∣∣∣∣∣∣∣(77)
4. SOLVING EQUATIONS BY MATRIX INVERSION
4.1. Procedure for solving equations using a matrix inverse. Let A be an n × n matrix. Let B bean arbitrary matrix. Then we ask whether there are matrices C and D of suitable dimension suchthat
A C = B
D A = B(78)
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 = A−1 B
D A = B ⇔ D = B A−1(79)
As an example, solve the following system of equations using theorem 2.
3 x1 + 5 x2 = 148 x1 − 2 x2 = 22
(80)
We can write the system as
24 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
A x = b
A =[
3 58 −2
], x =
[x1
x2
], b =
[1422
]
x = A−1 b = A−1
[1422
] (81)
We can compute A−1 from equation 75.
A−1 =1
(3) (−2) − (8) (5)
[−2 −5−8 3
]
=−146
[−2 −5−8 3
]
=[
246
546
846 − 3
46
](82)
We can now compute A−1 b as follows
A−1 b =[
246
546
846 − 3
46
] [1422
]=
[2846 + 110
4611246 − 66
46
]
=[
138464646
]=
[31
] (83)
4.2. Some example systems. Solve each of the following using matrix inversion
3x1 + x2 = 65x1 − x2 = 2
(84)
4x1 + x2 = 103x1 + 2 x2 = 10
(85)
4x1 + 3 x2 = 10x1 + 2 x2 = 5
(86)
4x1 + 3 x2 = 11x1 + 2 x2 = 4
(87)
5. A GENERAL FORMULA FOR THE INVERSE OF A MATRIX USING ADJOINT MATRICES
5.1. The adjoint of a matrix. The adjoint of the matrix A denoted adj (A) or A+ is the transpose ofthe matrix obtained from A by replacing each element aij by its cofactor Aij . For example considerthe matrix
A =
1 2 30 5 21 0 4
(88)
Now find the cofactor of each element. For example the cofactor of the 1 in the upper left handcorner is computed as
A11 = (−1)(1+1)
∣∣∣∣5 20 4
∣∣∣∣ = 20 (89)
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 25
Similarly the cofactor of a23 = 2 is given by
A23 = (−1)(2+3)
∣∣∣∣1 21 0
∣∣∣∣ = 2 (90)
The entire matrix of cofactors is given by
A11 A12 ... A1n
A21 A22 ... A2n
. .An1 An2 ... Ann
=
20 2 −5−8 1 2−11 −2 5
(91)
We can then compute the adjoint by taking the transpose
A+ =
A11 A12 ... A1n
A21 A22 ... A2n
. .An1 An2 ... Ann
′
=
20 2 −5−8 1 2−11 −2 5
′
=
20 −8 −112 1 −2−5 2 5
(92)
5.2. Finding an inverse matrix using adjoints. For a square nonsingular matrix A, its inverse isgiven by
A−1 =1
|A | A+ (93)
5.3. An example of finding the inverse using the adjoint. First find the cofactor matrix.
A =
1 2 30 5 21 0 4
Aij =
20 2 −5−8 1 2−11 −2 5
(94)
Now find the transpose of Aij
A+ =
20 −8 −112 1 −2−5 2 5
(95)
The determinant of A is|A| = 9
Putting it all together we obtain
A−1 =19·
20 −8 −112 1 −2−5 2 5
=
20/9 −8/9 −11/92/9 1/9 −2/9−5/9 2/9 5/9
(96)
26 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
We can check the answer as follows.
AA−1 =
1 2 30 5 21 0 4
·
20/9 −8/9 −11/92/9 1/9 −2/9−5/9 2/9 5/9
=
9/9 0 00 9/9 00 0 9/9
= I (97)
6. FINDING THE INVERSE OF A MATRIX USING ELEMENTARY ROW OPERATIONS
The most effective computational way to find the inverse of a matrix is to use elementary rowoperations. This is done by forming the augmented matrix [A : I] similar to the augmented matrixwe use when solving a system equation, except that we now add n columns of the identity matrixinstead of the right hand side vector in the equations system. In effect we are writing the system
A X = I (98)and then solving for the matrix X, which will be A−1. Consider the following matrix
A =
1 2 20 4 11 0 2
(99)
Now append an identity matrix as follows
A =
1 2 2 1 0 00 4 1 0 1 01 0 2 0 0 1
(100)
Add negative 1 times the first row to the last row to obtain
−1 −2 −2 −1 0 01 0 2 0 0 1
−− −− −− −− −− −−0 −2 0 −1 0 1
⇒ A1 =
1 2 2 1 0 00 4 1 0 1 00 −2 0 −1 0 1
(101)
Now divide the second row by 4 to obtain
A2 =
1 2 2 1 0 00 1 1/4 0 1/4 00 −2 0 −1 0 1
(102)
Now multiply the second row by 2 and add to the third row
0 2 1/2 0 1/2 00 −2 0 −1 0 1
−− −− −− −− −− −−0 0 1/2 −1 1/2 1
⇒ A3 =
1 2 2 1 0 00 1 1/4 0 1/4 00 0 1/2 −1 1/2 1
(103)
Now multiply the third row by 2
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 27
A4 =
1 2 2 1 0 00 1 1/4 0 1/4 00 0 1 −2 1 2
(104)
Now multiply the second row by negative 2 and add to the first row
1 2 2 1 0 00 −2 −1/2 0 −1/2 0
−− −− −− −− −− −−1 0 3/2 1 −1/2 0
⇒ A5 =
1 0 3/2 1 −1/2 00 1 1/4 0 1/4 00 0 1 −2 1 2
(105)
Now multiply the third row by negative 3/2 and add to the first row
1 0 3/2 1 −1/2 00 0 −3/2 3 −3/2 −3
−− −− −− −− −− −−1 0 0 4 −2 −3
⇒ A6 =
1 0 0 4 −2 −30 1 1/4 0 1/4 00 0 1 −2 1 2
(106)
Finally multiply the third row by negative 1/4 and add to the second row
0 1 1/4 0 1/4 00 0 −1/4 1/2 −1/4 −1/2
−− −− −− −− −− −−0 1 0 1/2 0 −1/2
⇒ A7 =
1 0 0 4 −2 −30 1 0 1/2 0 −1/20 0 1 −2 1 2
(107)
The inverse of A is then given by
A−1 =
4 −2 −31/2 0 −1/2−2 1 2
(108)
We can check this as follows
1 2 20 4 11 0 2
4 −2 −31/2 0 −1/2−2 1 2
=
1 0 00 1 00 0 1
(109)
28 MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS
7. THE GENERAL FORM OF CRAMER’S RULE
Consider the general equation system
A x = b (110)where A is n × n, x in nx1, and b is nx1.
Let Dj denote the determinant formed from |A| by replacing the jth column with the columnvector b. Thus
Dj =
a11 a12 ... a1 j−1 b1 a1 j+1 · · · a1n
a21 a22 ... a2 j−1 b2 a2 j+1 · · · a2n
. . . . . . . .an1 an2 ... an j−1 bn an j+1 · · · ann
(111)
Then the general system of n equations in n unknowns has unique solution if |A| 6= 0. Thesolution is
x1 =D1
|A |, x2 =
D2
|A |, · · · , xn =
Dn
|A |(112)
8. A NOTE ON HOMOGENEOUS SYSTEMS OF EQUATIONS
The homogeneous system of n equations in n unknowns
Ax = 0 (113)or
a11x1 + a12x2 + · · · + a1nxn = b1
a21x1 + a22x2 + · · · + a2nxn = b2
a31x1 + a32x2 + · · · + a3nxn = b3
... +... + · · · +
... =...
am1x1 + am2x2 + · · · + amnxn = bm
(114)
has a nontrivial solution (a trivial solution has x1 = 0, x2 = 0, ... xn = 0 if and only if |A| = 0.
MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 29
Lecture Questions1: Provide two examples of linear systems that have no solution and explain why.2: Provide two examples of linear systems that have exactly one solution and explain why.3: Provide two examples of linear systems that have exactly infinitely many solutions and
explain why. Provide at least one of these where the number of equations and unknowns isthe same.
4: Explain why if a linear system has exactly one solution, the coefficient matrix A must haveat least as many rows as columns. Give examples of why this is the case.
5: If a system of linear equations has more unknowns than equations, it must either have nosolution or infinitely many solutions. Explain why. Provide at least two examples.