Systems of Linear Equations
Systems of Linear Equations
A system of linear equations is a collection of two or more linear equations, each containing one
or more variables.
The following is a system of three equations containing three variables.
x + y – z = –1
4x – 3y + 2z = 16
2x – 2y – 3z = 5
Using a matrix notation we can write this system in the simplified form
1 1 −1 −1
4 −3 2 16 .
2 −2 −3 5
This is called the augmented matrix of the system.
In writing the augmented matrix, notice that the variables, being understood, are omitted and the
equal signs are replaced by a vertical line. So that the first row of the augmented matrix is
interpreted as x + y – z = –1, the second row as 4x – 3y + 2z = 16
and the third row as 2x – 2y – 3z = 5.
Ex. Write the augmented matrix of each system.
(a) 3x – 4y = –6 (b) 2x – y + z = 0
2x – 3y = –5 x+ z–1=0
x + 2y – 8 = 0
Row operations
There are three basic row operations that can be performed on an augmented matrix in order to
solve the corresponding system of equations. These are:
1. Interchange any two rows.
2. Replace a row by a constant non-zero multiple of that row.
3. Replace a row by the sum of that row and a constant non-zero multiple of another
row.
These row operations generate equivalent systems which have the same solutions as the original
system.
Ex. Solve the system
x + 2y + 3z = 19
2x + 4y + 5z = 34
3x + 5y + 6z = 42
1 2 3 19
0 1 3 15 R2 = −R2
0 1 4
0 R3 = −R3
This final augmented matrix is said to be in row echelon form. The last row states that z = 4.
We can now determine the value of y by back-substitution with z = 4. Since row 2 represents
the equation y + 3z = 15, we get y = 3. Finally, x is determined using back-substitution again
with y = 3 and z = 4. Since row 1 represents x + 2y + 3z = 19, we get x = 1.
The solution set is {(1, 3, 4)}. That is x = 1, y = 3, z = 4, and can be easily checked in the
original equations.
1 0 0 1 R1 = R1 − 2 R2
0 1 0 3
0 0 1 4
This final augmented matrix is said to be in reduced row echelon form. Note the identity
matrix.
The solution is easily seen to be x = 1, y = 3, z = 4, as before.
The process of writing a matrix in reduced row echelon form is called Gauss-Jordan elimination.
The previous system has exactly one solution. However, there are systems that have infinitely
many solutions. These are called dependent systems. There are also systems that have no
solutions. These are said to be inconsistent.
Ex. Solve the following systems.
(a) 6x – y – z = 4 (b) x+ y+ z=6
–12x + 2y +2z = –8 2x – y – z = 3
5x + y – z = 3 x + 2y + 2z = 0
Matrix Algebra
Equality
Two matrices are defined to be equal if they are of the same order and their corresponding
elements are equal.
Consider the matrices
2 1 y 1 2 1 0
A=
, B = , C =
3 x
3
5
3
4 0
If A = B, then x = 5 and y = 2. Conversely, if x = 5 and y = 2, then A = B.
Since B and C have different sizes, there is no value of y for which B = C.
Scalar multiplication
Let A be any matrix and k some constant, or scalar. Then the product kA is the matrix obtained
by multiplying each element of A by k. The matrix kA is said to be a scalar multiple of A.
−14 6 −18
For example, if A =
,
0 −10 2
− 28 12 −36 1 7 −3 9
then 2A =
and – A =
0 .
0 − 20 4 2 5 −1
Matrix multiplication
Given two matrices A and B, we can form the product AB, provided that A is of order m × r and
B is of order r × n. A is then said to be conformable to B for multiplication and the product AB is
a matrix of order m × n.
In the product AB, A is called the first matrix, or first factor, and B the second matrix, or second
factor.
To calculate the entry in row i and column j of the product AB, single out row i from the matrix
A and column j from the matrix B. Multiply the corresponding entries from the row and the
column together and then sum the resulting products.
It is important to note that scalar multiplication is not the same as matrix multiplication.
1 4 1 2 1 0 2 4 3
Ex. Consider the matrices A =
, B = , I = and C = .
2 3
2
6
0
1
4
5 1
(a) Find the following: (i) AB, BA, BC (ii) A(BC), (AB)C (iii) A 2 (iv) AI and
IA
(b) Is it possible to find CA?
1 4 1 2 9 26
Sol. (a) (i) AB =
=
2 3
2 6
8 22
1 2 1 4 5 10
BA =
= .
2 6
2 3
14 26
Note that AB ≠ BA. That is, matrix multiplication is not commutative.
1 2 2 4 3 10 14 5
BC =
=
2 6 4 5 1 28 38 12
1 4 10 14 5 122 166 53
(ii) A(BC) =
2 3
=
28 38 12 104 142 46
9 26 2 4 3 122 166 53
(AB)C =
8 22
=
4 5 1 104 142 46
1 4 1 4 9 16
(iii) A2 =
= .
2 3
2 3
8 17
Note that to find A 2 , we multiply A by A. Do not make the common
mistake of squaring each entry in A.
1 4 1 0 1 4
(iv) AI =
= = A
2 3
0 1 2
3
1 0 1 4 1 4
IA =
= = A
0 1
2 3
2 3
Note why the matrix I is called an identity matrix.
Transpose of a matrix
If A is any m × n matrix, then the transpose of A, denoted by AT , is defined to be the n ×m
matrix that results from interchanging the rows and columns of A. The rows of A then become
the columns of AT and the columns of A become the rows of AT .
1 4 1 2
For example, if A =
, then AT =
4 3
. What is the transpose of A ?
T
2 3
2 4
2 4 3
If B =
, then B = 4 5 . What is the transpose of B T ?
T
4 5 1 3 1
a b p q
Ex. Given that A =
and B =
d
r , show that
s
( AB ) T = B T AT .
c
Determinants
The determinant of a square matrix is a real number associated with the matrix.
a b
For the 2 × 2 matrix
, the determinant is defined to be the real number ad – bc.
c d
a b
We write c d
= ad – bc.
Note carefully the difference between a determinant and a matrix: the symbol for the
determinant is a pair of vertical lines similar to the absolute value symbol, while a matrix is
enclosed in brackets.
Given a matrix A, we usually denote the determinant of A by the symbols A or det A.
1 1
Ex. Let A =
5
6
Consider the augmented matrix
1 11 0
AI =
which we now transform into
reduced row echelon form.
5 6 0 1
1 1 1 0 1 1 1 0
→ R2 = R2 − 5R1
5
6 0 1 0 1 −5 1
1 0 6 −1
→ 0 1 −5 1 R1 = R1 − R2
6 −1
Thus A −1 =
− 5 , as before.
1
1 2 3
Ex. Given that A = 2 4 5 , find A −1 using the method just described.
3 5 6
1 − 3 2
= − 3 3 − 1 .
Sol. A −1
2 − 1 0
1 2 3
1 1
Sol (a) Let A =
5 .
6 (d) Let A = 2 4 5 .
3 5 6
6 −1
From before, A −1 =
−5 .
1 From before, A −1 =
1 − 3 2
− 3 3 − 1
2 − 1 0
Now X = A −1 H Now X = A −1 H
Form Plain cake Marble cake Carrot cake Total
2 p 2m 3c 19
4 2p 4m 5c 34
6 3p 5m 6c 42
1 − 3 2
19 1
= − 3 3 − 1
6 −1 2 3
=
−5
1 =
. 34 = 3
9 −1 42 4
2 − 1 0
That is, x = 3 and y = –1. That is, x = 1, y = 3, z = 4.
Check in the original equations: Check in the original equations:
3 + (–1) = 2; 1 + 6 + 12 = 19; 2 + 12 + 20 = 34;
5(3) + 6(–1) = 9. 3 + 15 + 24 = 42.
Practical applications
1. The table below gives the number of cakes sold by three classes to raise funds for
their school.
(e) Plain cakes were sold at $20.00 each, marble cakes at $30.00 each and
carrot cakes at $40.00 each.
(ii) Determine the 3×3 matrix F such that the product FC gives the
amount of funds raised by each class. [3]
(iii) Determine the 3×3 diagonal matrix M such that the product MC
gives the amount of money generated by each type of cake. [2]