System of Linear Equations - Spring - 20-21
System of Linear Equations - Spring - 20-21
Chapter-2
Linear equation:
An equation in two or more variables (unknowns) is linear if it contains no products of unknowns or
exponent of each unknowns is 1.
Example:
1. 2 x + 3 y = 8 (linear )
2. x1 + x2 + .... + xn = 1 (linear )
3. x 2 + 4 x = 8 (non − linear )
Solution:
A solution of linear equation a1 x1 + a 2 x2 + ... + a n xn = b is a sequence of 𝑛 numbers 1 , 2 ..., n such
that the equation is satisfied when we substitute x1 = 1 , x2 = 2 ,..., xn = n . The set of all such solutions
of the linear equation is called a solution set.
x + y = 2
has no solution.
x + y = 0
System of linear equations:
A group of 𝑚 linear equations of 𝑛 variables x1 , x2 ,..., xn are of the form
a11 x1 + a12 x2 + . . . + a1n xn = b1
a21 x1 + a22 x2 + . . . + a2 n xn = b2
. . . . . .
.............(1)
. . . . . .
. . . . . .
am1 x1 + am 2 x2 + . . . + amn xn = bm
1
Matrices, Vectors, Fourier Analysis Spring 2020-2021
is known as system of linear equation. Here the co-efficient a i j , i = 1,2,...m, j = 1,2,...,n of the
variable and the free term b i , i = 1,2,...,m are real numbers.
By a solution (set) of a system means such a set of real numbers that satisfies each equation in a system.
System of
Linear Equation
Inconsistent Consistent
y y y
2
Matrices, Vectors, Fourier Analysis Spring 2020-2021
x x x
Example: Following augmented matrices illustrate the consistency of the linear system.
1 2 3 2 1 2 3 2 1 2 3 2
(i) [A|B] = [0 1 4| 3], (ii) [A|B] = [0 1 4| 3], (iii) [A|B] = [0 1 4| 3].
0 0 1 2 0 0 0 2 0 0 0 0
rank(𝐴) = rank[𝐴|𝐵] = 3 rank(𝐴) = 2; rank[𝐴|𝐵] = 3 rank(𝐴) = 2;
So, this system is consistent. So, this system is inconsistent. rank[𝐴|𝐵] = 2
There is no solution for this So, this system is consistent
system. but infinitely many solutions.
~ 1 −2 3 1 2 ~ 1 −2 3 1 2
1 2
( | −4) 1 (0 1 −1 − 10|− 5)
𝑟3 → 𝑟3 − 2𝑟2 0 10 −10 −1 𝑟2 → 10 𝑟2
0 0 0 0 5 0 0 0 0 1
Now rank(𝐴) = 2, rank(𝐴|𝑏) = 3. Since rank(𝐴) ≠ rank(𝐴|𝑏) , the system is inconsistent.
7 x = 14
x = 2
Finally, substituting this value of 𝑥 into the expression for y gives y = 2(2) − 1 = 3
Therefore, the unique solution of the system is given by x = 2 and y = 3. Geometrically, the two lines
represented by the two equations that make up the system intersect at the point (2,3).
Example: A system of linear equations which are coincident has infinitely many solutions:
4
Matrices, Vectors, Fourier Analysis Spring 2020-2021
In particular, by assigning the value t to x , where t is any real number, we find that y = 2t − 1 and so
the ordered pair (t , 2t − 1) is a solution of the system. The variable t is called a parameter. For example,
setting t = 0 gives the point (0,−1) as a solution of the system, and setting t = 1 gives the point (1, 1) as
another solution. Since t represents any real number, there are infinitely many solutions of the system.
Geometrically, the two equations in the system represent the same line, and all solutions of the system
are points lying on the line (Figure). Such a system is said be dependent.
We see at once that the lines represented by these equations are parallel (each has slope 2) and
distinct since the first has y intercept −1 and the second has 𝑦 intercept −4. Systems having no
solutions such as this one are said to be inconsistent.
5
Matrices, Vectors, Fourier Analysis Spring 2020-2021
A system of linear equations is called homogeneous if all the constant terms b1, b2 ....,bn of the Non-
homogeneous system are zero such as the system has the form:
a11x1 + a12 x2 + . . . + a1n xn = 0
a21x1 + a22 x2 + . . . + a2 n xn = 0
. . . . . .
. . . . . .
. . . . . .
am1 x1 + am 2 x2 + . . . + amnxn = 0
Every homogeneous system of linear equations called consistent. Since
x1 = 0, x2 = 0,.................,xn = 0 is always a solution of the system. This solution is called the
trivial solution. If the other solution exists, they are called the non-trivial solution.
That is every solution of the system (1) is a solution of the matrix equation (2) and vice versa. Observe
that the associated homogeneous system of (1) is then equivalent to the matrix equation 𝐴𝑋 = 0.
The above matrix A is called the co-efficient matrix of the system (1) and the matrix
a11 a12 . . . a1n b1
a21 a22 . . . a2n b2
. . . . . . .
. . . . . . .
. . . . . . .
am1 an 2 . . . amn bm
is called the augmented matrix of (1). Observe that the system (1) is completely determined by its
augmented matrix.
There are three commonly used methods to solve system of linear equations:
1. Using inverse matrix,
2. Using elementary row operations (Gaussian elimination and Gauss-Jordan elimination),
3. Cramer’s rule.
6
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Example:
The co-efficient matrix and the augmented matrix of the system
2x + 3y − 4z = 7
x − 2 y − 5z = 3
are respectively the following matrices:
2 3 − 4 2 3 −4 7
and
1 − 2 − 5 − −2 −5 3
observe that the system is equivalent to the matrix equation.
x
2 3 − 4 7
y = .
1 − 2 − 5 z 3
Solution of linear equation by applying matrices:
IX = A B−1 since A A = I
IX =X
−1 1−1
X = A B (A )
A
That is,
x1 l1 m
A11 A12 . . A1n
.
1
A
x2 21 A22 . . A2 n l 2 m2
.
1 . . . . .
.
x = = m (say)
3 A . . . . . l 3 3
.
.
. . . . . . .
.
.
. An1 An 2 . . Ann .
.
x n l n mn
Then, x1 = m1 , x2 = m2 , x3 = m3 ,..............xn = mn (say) is a solution of the given system of n linear
equations.
It is to be noted that the solution of the system of equation can also be found by reducing the augmented
matrix of the given system to reduced echelon form.
When the system has 𝒎 linear equation with 𝒏 unknown and 𝒎 < 𝒏.
7
Matrices, Vectors, Fourier Analysis Spring 2020-2021
The table below is the row reduction process applied simultaneously to the system of equations, and
its associated augmented matrix. The row reduction procedure may be summarized as follows:
eliminate x from all equations below 𝑟1, and then eliminate y from all equations below 𝑟2 . This will
put the system into triangular form. Then, using back-substitution, each unknown can be solved.
8
Matrices, Vectors, Fourier Analysis Spring 2020-2021
2𝑥 + 𝑦 − 𝑧 = 8 𝑟3 → 𝑟3 − 2𝑟2 2 1 −1 8
𝑦+𝑧 =2 [ 0 1 1 | 2]
−𝑧 = 1 0 0 −1 1
The matrix is now in echelon form
2𝑥 + 𝑦 =7 𝑟1 → 𝑟1 − 𝑟3 2 1 0 7
𝑦 =3 𝑟2 → 𝑟2 + 𝑟3 [ 0 1 0 | 3]
−𝑧 = 1 0 0 −1 1
2𝑥 =4 𝑟1 → 𝑟1 − 𝑟2 2 0 0 4
𝑦 =3 [ 0 1 0 | 3]
−𝑧 = 1 0 0 −1 1
𝑥 =2 1 1 0 0 2
𝑟1 → 𝑟 [ 0 1 0| 3 ]
𝑦 =3 2 1
𝑧 = −1 𝑟2 → −𝑟2 0 0 1 −1
The solution is 𝑧 = −1, 𝑦 = 3, and 𝑥 = 2. So, there is a unique solution to the original system of
equations.
Example: Solve the following system of equations using Gaussian elimination method
2𝑥 + 𝑦 + 3𝑧 = 1 (𝑟1 )
2𝑥 + 6𝑦 + 8𝑧 = 3 (𝑟2 )
6𝑥 + 8𝑦 + 18𝑧 = 5 (𝑟3 )
𝑟2 → 𝑟2 − 𝑟1 2𝑥 + 𝑦 + 3𝑧 = 1
𝑟3 → 𝑟3 − 3𝑟1 5𝑦 + 5𝑧 = 2
5𝑦 + 9𝑧 = 2
𝑟3 → 𝑟3 − 𝑟2 2𝑥 + 𝑦 + 3𝑧 = 1
5𝑦 + 5𝑧 = 2
4𝑧 = 0
From this stage, we can get the solution by 𝑧=0
back solving 5𝑦 + 5(0) = 2
2
⇒𝑦=
5
2 3
and 2𝑥 + 5 + 3(0) = 1 ⇒ 𝑥 = 10
𝑟2 → 3𝑟2 − 2𝑟1 3𝑥 + 𝑦 − 6𝑧 = −1 0
𝑟3 → 𝑟3 − 2𝑟1 𝑦 − 3𝑧 = −4
𝑦 − 3𝑧 = −4
𝑟3 → 𝑟3 − 𝑟2 3𝑥 + 𝑦 − 6𝑧 = −1 0
𝑦 − 3𝑧 = −4
9
Matrices, Vectors, Fourier Analysis Spring 2020-2021
0=0
Thinking back to the two-variable case, getting a line like "0 = 0" (which is true, but unhelpful)
means that this is a dependent system, and the solution is going to have variables in it. The answer
above means that the solution is a line in three-dimensional space rather than a single point. To find
the solution, we have to solve the two remaining equations for 𝑥 and 𝑦 in terms of 𝑧:
𝑦 = 3𝑧 − 4
∴ 𝑥 + 3𝑧 − 4 − 6𝑧 = −10
⇒𝑥 =𝑧−2
Let, 𝑧 = 𝑡, where 𝑡 is a free variable. So the solution of the system is (𝑥, 𝑦, 𝑧) = (𝑡 − 2, 3𝑡 − 4, 𝑡)
Example: Solve the following system of equations using Gaussian elimination method
𝑥 +𝑧=1 (𝑟1 )
𝑥+𝑦+𝑧 =2 (𝑟2 )
𝑥−𝑦+𝑧 =1 (𝑟3 )
𝑟2 → 𝑟2 − 𝑟1 𝑥 +𝑧=1
𝑟3 → 𝑟3 − 𝑟1 𝑦 =1
−𝑦 =0
𝑟3 → 𝑟3 + 𝑟2 𝑥 +𝑧=1
𝑦 =1
0 =1
The third row ′0 = 1′ is nonsense. So, the system is inconsistent. That means there is no solution.
~ 1 4 −3 −2 ~ 1 4 −3 −2
𝑟2 → 𝑟2 − 𝑟3 [ 0 1 −1 ⋮ −1] 𝑟 → 𝑟 + 10𝑟 [0 1 −1 ⋮ −1]
3 3 2
0 −10 8 6 0 0 −2 −4
1 4 −3 −2 1 0 1 2 ~ 1 0 0 0
~ ~
1
𝑟3 → −2𝑟3 [ 0 1 −1 ⋮ −1 ] [
𝑟1 → 𝑟1 − 4𝑟2 0 1 −1 ⋮ −1] 𝑟1 → 𝑟1 − 𝑟3 [0 1 0 ⋮ 1]
0 0 1 2 0 0 1 2 𝑟2 → 𝑟2 + 𝑟3 0 0 1 2
Hence the solution is 𝑥 = 0, 𝑦 = 1, 𝑧 = 2.
Example: Solve the following system of equations using matrix inversion and justify your answer.
2𝑥 + 𝑦 = 1 (𝑟1 )
𝑥 − 2𝑦 = 3. (𝑟2 )
10
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Solution:
We know 𝐴𝑋 = 𝐵
If 𝐴−1 exists, then
𝐴−1 (𝐴𝑋) = 𝐴−1 𝐵
𝐼𝑋 = 𝐴−1 𝐵
𝑋 = 𝐴−1 𝐵
The given linear equations can be written in matrix form as
2 1 𝑥 1
[ ][ ] = [ ]
1 −2 𝑦 3
2 1 𝑥 1
Suppose, 𝐴 = [ ], 𝑋 = [𝑦], and 𝐵 = [ ]
1 −2 3
2 1
The determinant of the matrix A is | | = −6 ≠ 0
1 −2
So, the matrix 𝐴 is non-singular and 𝐴−1 exists.
1 −2 −1
Now 𝐴−1 = −5 [ ]
−1 2
−1
And 𝑋 = 𝐴 𝐵
1 −2 −1 1
= [ ][ ]
−5 −1 2 3
1 −5
= [ ]
−5 5
1
=[ ]
−1
𝑥 1
∴ [𝑦 ] = [ ]
−1
∴ 𝑥 = 1 and 𝑦 = −1
𝑟1 : 𝐿. 𝐻. 𝑆 = 2𝑥 + 𝑦 = 2.1 − 1 = 1 = 𝑅. 𝐻. 𝑆
𝑟1 : 𝐿. 𝐻. 𝑆 = 𝑥 − 2𝑦 = 1 − 2(−1) = 3 = 𝑅. 𝐻. 𝑆
11
Matrices, Vectors, Fourier Analysis Spring 2020-2021
𝑥1 + 2𝑥2 + 3𝑥3 = 5
2𝑥1 + 5𝑥2 + 3𝑥3 = 3 .
𝑥1 + 8𝑥3 = 17
Solution:
1 2 3
The system of equations can be written in the matrix form as 𝐴𝑋 = 𝐵 , where 𝐴 = [2 5 3],
1 0 8
𝑥1 5
𝑋 = [𝑥2 ] and 𝐵 = [ 3 ] . The solution can be written as 𝑋 = 𝐴−1 𝐵. Let us find 𝐴−1 using
𝑥3 17
elementary row operations.
1 2 3 1 0 0 ~ 1 2 3 1 0 0 ~
[𝐴 ⋮ 𝐼] = [2 5 3 ⋮ 0 1 0] 𝑟2 → 𝑟2 − 2𝑟1 [0 1 −3 ⋮ −2 1 0] 𝑟 → 𝑟 + 2𝑟
3 3 2
1 0 8 0 0 1 𝑟3 → 𝑟3 − 𝑟1 0 −2 5 −1 0 1
1 2 3 1 0 0 ~ 1 0 9 5 −2 0 ~
[0 1 −3 ⋮ −2 1 0] 𝑟1 → 𝑟1 − 2𝑟2 [0 1 −3 ⋮ −2 1 0] 𝑟 → 𝑟 + 9𝑟
1 1 3
0 0 −1 −5 2 1 0 0 −1 −5 2 1
1 0 0 −40 16 9 ~ 1 0 0 −40 16 9
[0 1 −3 ⋮ −2 1 0] 𝑟2 → 𝑟2 − 3𝑟3 [0 1 0 ⋮ 13 −5 −3]
0 0 −1 −5 2 1 𝑟3 → −𝑟3 0 0 1 5 −2 −1
−40 16 9
∴ 𝐴−1 = [ 13 −5 −3]
5 −2 −1
−40 16 9 5 1
−1
Now, 𝑋 = 𝐴 𝐵 = [ 13 −5 −3] [ 3 ] = [−1] 𝑥1 = 1, 𝑥2 = −1 and 𝑥3 = 2.
5 −2 −1 17 2
Cramer’s Rule:
Let a system of linear equations is given 𝐴𝑋 = 𝐵 and |𝐴| = 𝐷. This system is
(a) inconsistent if 𝐵 ≠ 0 but 𝐷 = 0 ;
(b) consistent and redundant if 𝐵 = 0 and 𝐷 = 0 ;
(c) consistent and unique if 𝐷 ≠ 0; and in this case the solution is given by
D
xi = i (i = 1, 2, ......., n) ,
D
𝐷𝑖 can be obtained by replacing ith column by right hand side.
Explicit formulas for small systems
𝑎 𝑥 + 𝑏1 𝑦 = 𝑐1
Consider the linear system { 1
𝑎2 𝑥 + 𝑏2 𝑦 = 𝑐2
𝑎 𝑏1 𝑥 𝑐1
which in matrix format is [ 1 ] [𝑦] = [𝑐 ]
𝑎2 𝑏2 2
Assume 𝑎1 𝑏2 − 𝑏1 𝑎2 nonzero. Then, with help of determinants 𝑥 and 𝑦 can be found with Cramer's
rule as
12
Matrices, Vectors, Fourier Analysis Spring 2020-2021
𝑐 𝑏1 𝑎1 𝑐1
| 1 | 𝑐 𝑏 −𝑏 𝑐 |𝑎
𝑐2 𝑏2 1 2 1 2 2 𝑐 | 𝑎1 𝑐 2 − 𝑐1 𝑎2
𝑥= = and 𝑦 = = .
𝑎1 𝑏1 𝑎1 𝑏2 − 𝑏1 𝑎2 𝑎 𝑏1 𝑎1 𝑏2 − 𝑏1 𝑎2
| | | 1 |
𝑎2 𝑏2 𝑎2 𝑏2
Example:
Let us demonstrate Cramer's rule with the following system:
𝑥 + 2𝑦 + 3𝑧 = 1
−𝑥 + 2𝑧 = 2
−2𝑦 + 𝑧 = −2
Step 1:
1 2 3
The coefficient matrix of this system is 𝐴 = [−1 0 2]
0 −2 1
Note that the matrix is square (it has 3 rows and 3 columns), and so we may proceed with the
next step of Cramer's rule.
Step 2:
Now find the determinant of the coefficient matrix 𝐴; use the matrix manipulator in the tools box
if you would like help in this computation. You should get |𝐴| = 12. This is not zero, so Cramer's
rule may be applied here.
Step 3:
1 2 3 |𝐴 | 20 5
𝐴𝑥 = [ 2 0 2] and its determinant is |𝐴𝑥 | = −20. Therefore 𝑥 = |𝐴|𝑥 = − 12 = − 4
−2 −2 1
Step 4:
Using the same method, the values for the remaining 2 variables, 𝑥 and 𝑦, are computed below:
13
Matrices, Vectors, Fourier Analysis Spring 2020-2021
1 1 3 |𝐴𝑦 | 13
𝐴𝑦 = [−1 2 2] and its determinant is |𝐴𝑦 | = 13. Therefore 𝑦 = |𝐴| = − 12
0 −2 1
1 2 1 |𝐴 | 2 1
𝐴𝑧 = [−1 0 2 ] and its determinant is |𝐴𝑧 | = 2. Therefore 𝑧 = |𝐴|𝑧 = 12 = 6
0 −2 −2
Example: Verify whether the following system of linear equations is consistent or not. If consistent
then solve the system using Cramer’s rule. Also check your answer.
2𝑥 − 3𝑦 − 5𝑧 = 40
17𝑥 + 14𝑦 − 22 𝑧 = 22
15𝑥 + 17𝑦 − 17𝑧 = −18 .
Solution:
2 −3 −5
D = 17 14 − 22 = 0 and ≠ 𝟎 . Therefore, this SLE is inconsistent
15 17 − 17
Example:
2𝑥 − 5𝑦 + 6𝑧 = −27
10𝑥 − 11𝑦 − 9𝑧 = 0
−3𝑥 + 2𝑧 = 16
Solution:
2 −5 6
𝐷 = 10 − 11 − 9 = – 277 and 𝐵 ≠ 0 and, therefore, this SLE has a unique solution.
−3 0 2
− 27 − 5 6 2 − 27 6 2 −5 − 27
Now D1 = 0 − 11 − 9 ; D2 = 10 0 − 9 ; D3 = 10 − 11 0 .
16 0 2 − 3 16 2 −3 0 16
= 2370 ; = 1059 ; = 1339.
2370 1059 1339
Thus 𝑥 = − ; 𝑦 =– ; 𝑧 =– .
277 277 277
Example:
3𝑥– 2𝑦 + 5𝑧– 6𝑡 = 0
– 2𝑥– 9𝑦– 𝑧 + 7𝑡 = 0
5𝑥 + 7𝑦– 4𝑧 – 6𝑡 = 0
8𝑦– 9𝑧– 2𝑡 = 0.
Solution:
3 −2 5 −6
− 2 − 9 −1 7
∆= = – 1461 and 𝐵 = 𝟎. Consequently (0,0,0,0) is the solution.
5 7 −4 −6
0 8 −9 −2
14
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Example:
Solve the following system of linear equations using Cramer’s rule
2𝑥 + 𝑦 + 𝑧 = 3
𝑥−𝑦−𝑧 =0
𝑥 + 2𝑦 + 𝑧 = 0
We have the left-hand side of the system with the variables (the "coefficient matrix") and the right-
hand side with the answer values. Let 𝐷 be the determinant of the coefficient matrix of the above
system, and let 𝐷𝑥 be the determinant formed by replacing the 𝑥-column values with the answer-
column values: Evaluating each determinant, we get:
2 1 1
𝐷 = |1 −1 −1| = 3
1 2 1
3 1 1 2 3 1 2 1 3
𝐷𝑥 = |0 −1 −1| = 3, 𝐷𝑦 = |1 0 −1| = −6, 𝐷𝑧 = |1 −1 0| = 9
0 2 1 1 0 1 1 2 0
Example:
Solve the following system of linear equations using Crammer’s rule
2𝑥 + 3𝑦 + 𝑧 = 10
𝑥−𝑦+𝑧 =4
4𝑥 − 𝑦 − 5𝑧 = −8 .
Solution: Each unknown will be the quotient of the determinant obtained by substituting the answers
in the right sides of the equations for the coefficients of the unknown divided by the determinant
formed by taking the coefficients on the left sides of the equations.
10 3 1 2 10 1 2 3 10
|4 −1 1 | |1 4 1| |1 −1 4|
−8 −1 −5 84 4 −8 −5 42 4 −1 −8 126
𝑥= 2 3 1 = = 2, 𝑦 = 2 3 1 = = 1, 𝑧 = 2 3 1 = =3
42 42 42
|1 −1 1 | |1 −1 1| |1 −1 1|
4 −1 −5 4 −1 −5 4 −1 −5
Example:
Determine the value(s) of and such that the following system of linear equations has (i) no
solution, (ii) more than one solution, and (iii) a unique solution.
x+ y+z =6
x + 2 y + 3z = 10
x + 2 y + z =
15
Matrices, Vectors, Fourier Analysis Spring 2020-2021
The above system is in echelon form. Now we consider the following three cases:
(i) If = 3 and 10 then third equation of (1) is of the form 0 = a , where a = − 10 0
which is not true. So, the system is inconsistent. Thus, the system has no solution for = 3
and 10 .
(ii) If = 3 and = 10 then third equation of (1) is vanishes and the system will be in echelon
form having two equations in three variables. So, it has 3 − 2 = 1 free variables which is
𝑧. Hence the given system has more than one solution for = 3 and = 10 .
(iii) For a unique solution, the coefficient of 𝑧 in the 3rd equation must be non-zero i.e., 3
and may have any value. Therefore, the given system has unique solution for 3 and
arbitrary values of .
Example:
Determine the values of and such that the following system of linear equations has (𝑖) no solution
(𝑖𝑖) more than one solution and (𝑖𝑖𝑖) a unique solution.
x + y − z =1
2 x + 3 y + z = 3 .
x + y + 3 z = 2
x + y − z =1
Solution: The given system of liner equations is 2 x + 3 y + z = 3
x + y + 3 z = 2
Reduce the system to echelon form by means of elementary row operations,
x + y − z =1
L/2 = L2 − 2 L1
y + ( + 2) z = 1 /
( − 1) y + 4 z = 1 L3 = L3 − L1
x + y − z =1
y + ( + 2) z = 1 L
/
3 = L3 − ( − 1) L2
4 − ( − 1)( + 2)z = 2 −
x + y − z =1
y + ( + 2) z = 1
( )
6 − − 2 z = 2 −
x + y − z =1
y + ( + 2) z = 1 (1)
( + 3)(2 − ) z = 2 −
The above system is in echelon form. Now we consider the following three cases:
(i) From third equation of (1) , we see that if + 3 = 0 or = −3 then the equation becomes
0 = 5 , which is contradiction. Therefore, the system is inconsistent if = −3 . Thus, the
system has no solution for = −3 .
(ii) We know, if the number of variables is greater than the number of equations, then the
system has more than one solution. From third equation of (1) , we see that if = 2 then it
16
Matrices, Vectors, Fourier Analysis Spring 2020-2021
becomes 0 = 0 . In this case the system has three variables with two equations. So, the
given system has more than one solution for = 2 .
(iii) We know, if the number of variables and the number of equations be equal, then the system
has unique solution. The system (1) has a unique solution
( + 3)(2 − ) 0 −3, 2.
Example:
Determine the values of and such that the following system of linear equations has (i) no
solution, (ii) more than one solution, and (iii) a unique solution.
2x + 3 y + z = 5
3 x − y + z = 2
x + 7 y − 6z =
Example:
Find the values of 𝑘 such that the following system of linear equations has non-zero solution.
𝑥 + 𝑘𝑦 + 3𝑧 = 0
4𝑥 + 3𝑦 + 𝑘𝑧 = 0.
2𝑥 + 𝑦 + 2𝑧 = 0
17
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Solution:
The augmented matrix 𝐶 = [𝐴: 𝐵]
1 𝑘 3 : 0
~ [4 3 𝑘 : 0]
2 1 2 : 0
On interchanging first row and third row, we have
2 1 2 : 0
~ [4 3 𝑘 : 0]
1 𝑘 3 : 0
Reducing the system to row echelon form by the elementary row operations …
2 1 2 : 0
𝑅2′ = 𝑅2 − 2𝑅1
~[ 0 1 𝑘 − 4 : 0] [ ′ 1 ]
0 𝑘−2
1
2 : 0 𝑅 3 = 𝑅 3 − 𝑅1
2
2 1 2 : 0
1
~ [0 1 𝑘−4 : 0] [𝑅3′ = 𝑅3 − (𝑘 − 2)𝑅2 ]
1
0 0 2 − (𝑘 − 2) (𝑘 − 4) : 0
So,
1
2 − (𝑘 − ) (𝑘 − 4) = 0
2
2
9
⟹ −𝑘 + 𝑘 = 0
2
9
⟹ 𝑘(−𝑘 + ) = 0
2
9
∴ 𝑘 = 0,
2
Example: A medicine company wishes to produce three types of medicine : type 𝑃, 𝑄 and 𝑅. To
manufacture a type 𝑃 medicine requires 2 minutes each on machine 𝐼 and 𝐼𝐼 and 3 minutes on machine
𝐼𝐼𝐼. A type of 𝑄 medicine requires 2 minutes on machine 𝐼, 3 minutes on machine 𝐼𝐼 and 4 minutes of
machine 𝐼𝐼𝐼. A type 𝑅 medicine requires 3 minutes on machine 𝐼, 4 minutes on machine 𝐼𝐼 and 3
minutes on machine 𝐼𝐼𝐼. There are 3.5 hours available on machine 1, 4.5 hours available on machine 𝐼𝐼
and 5 hours available on machine 𝐼𝐼𝐼. How many medicine of each type should company make in
order to use all the available time?
Solution:
Here, 3.5 hours = 210 minutes, 4.5 hours = 270 minutes and 5 hours = 300 minutes.
Let 𝑥, 𝑦 and 𝑧 be the number of medicines of types 𝑃, 𝑄 and 𝑅 respectively. Then we have the
2𝑥 + 2𝑦 + 3𝑧 = 210
following system of linear equations: {2𝑥 + 3𝑦 + 4𝑧 = 270
3𝑥 + 4𝑦 + 3𝑧 = 300
The augmented matrix of the above system is
2 2 3 : 210
[2 3 4 : 270]
3 4 3 : 300
Reducing the system to echelon form by the elementary row operations
18
Matrices, Vectors, Fourier Analysis Spring 2020-2021
2 2 3 : 210 𝑟 ′ = 𝑟2 − 𝑟1
~ [0 1 1 : 60 ] [ ′ 2 ]
𝑟3 = 2𝑟3 − 3𝑟 1
0 2 −3 : −30
2 2 3 : 210
~ [0 1 1 : 60 ] [𝑟3′ = 𝑟3 − 2𝑟1 ]
0 0 −5 : −150
Hence the solution of the above system is 𝑥 = 30, 𝑦 = 30, 𝑧 = 30
Thus, the number of each type of medicine is 30.
Example: Determine the polynomial 𝑝(𝑥) = 𝑎0 + 𝑎1 𝑥 + 𝑎2 𝑥 2 whose graph passes through the
points (1,4) , (2,0) and (3,12).
Solution:
Given polynomial 𝑝(𝑥) = 𝑎0 + 𝑎1 𝑥 + 𝑎2 𝑥 2
Substituting x = 1, 2 and 3 into p(x) and the corresponding y − values produces the system of linear
equations in the variables a0 , a1 and a 2 shown below:
p(1) = a0 + a1 (1) + a 2 (1) 2 = a0 + a1 + a 2 = 4
p(2) = a0 + a1 (2) + a 2 (2) = a0 + 2a1 + 4a 2 = 0
2
a0 + a1 + a 2 = 4
a1 + 3a 2 = −4
L3 = L3 − L2
/
2a = 16
2
19
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Example: Find the polynomial that fits the points (−2, 3), (−1, 5), (0, 1), (1, 4) and (2, 10).
Example:
Set up a system of linear equations to represent the network shown in the following figure and solve
the system.
20
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Solution:
Each of the network’s five junctions gives rise to a linear equation, as shown below:
𝑥1 + 𝑥2 = 20 junction 1
𝑥3 + 20 = 𝑥4 junction 2
𝑥2 + 𝑥3 = 10 + 10 junction 3
𝑥1 + 10 = 𝑥5 junction 4
𝑥5 + 10 = 𝑥4 junction 5
The augmented matrix is
1 1 0 0 0 : 20
0 0 1 − 1 0 : − 20
0 1 1 0 0 : 20
1 0 0 0 − 1 : − 10
0 0 0 − 1 1 : − 10
Reduce the system to echelon form by the elementary row operations
1 1 0 0 0 : 20
0 1 1 0 0 : 20
R R3
0 0 1 − 1 0 : − 20 2
R4 R5
0 0 0 − 1 1 : − 10
1 0 0 0 − 1 : − 10
1 1 0 0 0 : 20
0 1 1 0 0 : 20
0 0 1 −1 0 : − 20 R 5
/
= R5 − R1
0 0 0 −1 1 : − 10
0 − 1 0 0 −1 : − 30
1 1 0 0 0 : 20
0 1 1 0 0 : 20
0 0 1 −1 0 : − 20 R
5
/
= R5 + R2
0 0 0 −1 1 : − 10
0 0 1 0 −1 : − 10
21
Matrices, Vectors, Fourier Analysis Spring 2020-2021
1 1 0 0 0 : 20
0 1 1 0 0 : 20
R4 / = (−1) R4
0 0 1 −1 0
: − 20 /
R5 = R5 − R3
0 0 0 1 −1 : 10
0 0 0 1 −1 : 10
1 1 0 0 0 : 20
0 1 1 0 0 : 20
R3 / = R3 + R4
0 0 1 0 − 1 : − 10 /
R5 = R5 − R4
0 0 0 1 − 1 : 10
0 0 0 0 0 : 0
1 1 0 0 0 : 20
0 1 0 0 1 : 30
0 0 1 0 − 1 : − 10 R 2
/
= R2 − R3
0 0 0 1 − 1 : 10
0 0 0 0 0 : 0
1 0 0 0 − 1 : − 10
0 1 0 0 1 : 30
0 0 1 0 − 1 : − 10 R1
/
= R1 − R2
0 0 0 1 − 1 : 10
0 0 0 0 0 : 0
The corresponding system of equations are as follows:
x1 − x5 = − 10
x2 x5 = 30
x3 − x5 = − 10
x 4 − x5 = 10
The above system is in echelon form having 4 equations in 5 unknowns. So, it has (5 − 4) = 1 free
variable, which is x5 .
Let x5 = t , then by back substitution method, we have
x4 = t + 10, x3 = t − 10, x2 = 30 − t , x1 = t − 10, where t is a real number.
So, this system has an infinite number of solutions.
Example:
Determine the currents I1 , I 2 and I 3 for the electrical network shown in the following figure.
22
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Solution:
Applying Kirchhoff’s current law to each junction produces
I 1 + I 3 = I 2 ; Junction 1 or junction 2
and applying Kirchhoff’s second law to two paths produces
R1 I 1 + R2 I 2 = 3I 1 + 2 I 2 = 7 path 1
R2 I 2 + R3 I 3 = 2 I 2 + 4 I 3 = 8 path 2
So, we have the following system of three linear equations in
the I1 , I 2 and I 3
I1 − I2 + I3 = 0
3I 1 + 2 I 2 = 7
2I 2 + 4I 3 = 8
The augmented matrix of the above system is
1 − 1 1 : 0
3 2 0 : 7
0 2 4 : 8
Reducing the system to echelon form by the elementary row operations
1 − 1 1 : 0
0 5 − 3 : 7
R2 = R2 − 3R1
/
0 2 4 : 8
1 − 1 1 : 0
0 5 − 3 : 7
R
3
/
= 5R3 − 2 R2
0 0 26 : 26
1 − 1 1 : 0
0 5 − 3 : 7 / 1
R3 = 26 R3
0 0 1 : 1
1 − 1 0 : − 1
0 5 0 : 10 R1 / = R1 − R3
/
R2 = R2 + 3R3
0 0 1 : 1
1 − 1 0 : − 1
0 1 0 : 2 / 1
R2 = 5 R2
0 0 1 : 1
1 0 0 : 1
0 1 0 : 2
R1
/
= R1 + R2
0 0 1 : 1
So, the solution of the above system is I1 = 1A, I 2 = 2 A and I 3 = 1A.
23
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Example:
Determine the currents I 1 , I 2 , I 3 , I 4 , I 5 and I 6 for the electrical network shown in the following figure.
Solution:
Applying Kirchhoff’s current law to each junction produces
I1 + I 3 = I 2 junction 1
I1 + I 4 = I 2 junction 2
I 3 + I 6 = I 5 junction 3
I 4 + I 6 = I 5 junction 4
and applying Kirchhoff’s second law to the three paths produces
2 I 1 + 4 I 2 = 10 path 1
4I 2 + I 3 + 2I 4 + 2I 5 = 17 path 2
2 I 5 + 4 I 6 = 14 path 3
Now we have the following system of seven linear equations in the variables I 1 , I 2 , I 3 , I 4 , I 5 and I 6
I1 − I2 + I3 = 0
I − I2 + I4 = 0
1
I3 −I + I6 = 0
I4 − I5 + I6 = 0
2 I + 4 I = 10
1 2
4I 2 + I 3 + 2I 4 + 2I 5 = 17
2 I 5 + 4 I 6 = 14
Using Gauss-Jordan elimination method, we have solution of the above system is
24
Matrices, Vectors, Fourier Analysis Spring 2020-2021
I 1 = 1, I 2 = 2, I 3 = 1, I 4 = 1, I 5 = 3 and I 6 = 2
which means I1 = 1amp, I 2 = 2 amp and I 3 = 1amp. I 4 = 1amp, I 5 = 3 amp and I 6 = 2 amp.
Example:
Determine the loop currents I 1 and I 2 of the following circuit using mesh analysis.
Solution:
For loop 1: 10𝐼1 + 20𝐼1 − 20𝐼2 = 70
⇒ 30𝐼1 − 20𝐼2 = 70
⇒ 3𝐼1 − 2𝐼2 = 7
Example:
Determine the loop currents I 1 , I 2 and I 3 of the following circuit using mesh analysis.
Solution:
For loop 1: 10𝐼1 + 12𝐼1 − 10𝐼2 − 12𝐼3 = 24
⇒ 22𝐼1 − 10𝐼2 − 12𝐼3 = 24
⇒ 11𝐼1 − 5𝐼2 − 6𝐼3 = 12
25
Matrices, Vectors, Fourier Analysis Spring 2020-2021
(a) Write a general expression involving the rates of flow x1 , x2 , x3 , x4 and suggest two possible
flow patterns that will ensure no traffic congestion.
(b) Suppose the part of 4th street between 5th Avenue and 6th Avenue is to be resurfaced and that
traffic flow between the two junctions must therefore be reduced to at most 300 vehicles per
hour. Find two possible flow patterns that will result in a smooth flow of traffic.
Solution:
(a) To avoid congestion, all traffic entering an intersection must also leave that intersection.
Applying this condition to each of the four intersections in a clockwise direction beginning
with the 5th Avenue and 4th Street intersection, we obtain the following equations:
1500 = x1 + x4
1300 = x1 + x2
1800 = x2 + x3
2000 = x3 + x 4
This system of four linear equations in the four variables x1 , x2 , x3 , x4 may be written in the more
standard form
x1 + x 4 = 1500
x1 + x2 = 1300
x2 + x3 = 1800
x3 + x4 = 2000
26
Matrices, Vectors, Fourier Analysis Spring 2020-2021
1 0 0 1 1500
0
0
1
0
0 − 1 − 200
1 1 2000
R3
/
= R3 − R2
0 0 1 1 2000
1 0 0 1 1500
0
0
1
0
0 − 1 − 200
1 1 2000
R 4
/
= R4 − R3
0 0 0 0 0
The last augmented matrix is in row-reduced form and is equivalent to a system of three linear
equations in the four variables x1 , x2 , x3 , x4 . This we may express three of the variables-say,
x1 , x 2 , x3 in terms of x 4 . Setting x4 = t (t a parameter), we may write the infinitely many solutions of
the system as
x1 = 1500 − t
x2 = −200 + t
x3 = 2000 − t
x4 = t
Observe that for a meaningful solution we must have 200 t 1000 since x1 , x2 , x3 and x4 must all
be nonnegative and the maximum capacity of a street is 1000.
For example, picking t = 300 gives the flow pattern
x1 = 1200, x2 = 100, x3 = 1700 , x4 = 300
Selecting t = 500 gives the flow pattern
x1 = 1000, x2 = 300, x3 = 1500 , x4 = 500
(b) In this case, x4 must not exceed 300. Again, using results of part(𝑎), we find, upon setting
x4 = t = 300, the flow pattern x1 = 1200, x2 = 100, x3 = 1700, x4 = 300 obtained earlier.
(c) Picking t = 250 gives the flow pattern x1 = 1250, x2 = 50, x3 = 1750, x4 = 250.
27
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Linear Programming:
Problem: A company manufactures and sells two models of lamps, L1 and L2. To manufacture each
lamp, the manual work involved in model L1 is 20 minutes and for L2, 30 minutes. The mechanical
(machine) work involved for L1 is 20 minutes and for L2, 10 minutes. The manual work available per
month is 100 hours and the machine is limited to only 80 hours per month. Knowing that the profit per
unit is 15 and 10 for L1 and L2, respectively, determine the quantities of each lamp that should be
manufactured to obtain the maximum benefit.
Solution:
Let
𝑥 = number of lamps L1
𝑦 = number of lamps L2
Objective function 𝑓(𝑥, 𝑦) = 15 𝑥 + 10 𝑦
L1 L2 Time
1 1
𝑥 + 𝑦 ≤ 100
3 2
1 1
𝑥 + 𝑦 ≤ 80
3 6
1 1
· 0 + · 0 ≤ 100
3 2
28
Matrices, Vectors, Fourier Analysis Spring 2020-2021
1 1
· 0 + · 0 ≤ 80
3 6
The area of intersection of the solutions of the inequalities would be the solution to the system of
inequalities, which is the set of feasible solutions.
The optimal solution, if unique, is a vertex. These are the solutions to systems:
1 1
𝑥 + 𝑦 = 100; 𝑥 = 0 (0, 200)
3 2
1 1
𝑥 + 𝑦 = 80; 𝑦 = 0(240, 0)
3 6
1 1 1 1
𝑥 + 𝑦 = 100; 𝑥 + 𝑦 = 80(210, 60)
3 2 3 6
In the objective function, place each of the vertices that were determined in the previous step.
29
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Exercise 2
1. Test whether the systems of linear equations are consistent. If consistent find the solutions of
the system. Also check your answer by direct substitution.
a. x1 − 3 x2 = 2 b. 2 x1 − 3x2 = −2 c. − 2 x2 + 3x3 = 1
− 3 x1 + 9 x2 = 3 2 x1 + x2 = 1 3x1 + 6 x2 − 3x3 = −2
3x1 + 2 x2 = 1 6 x1 + 6 x2 + 3x3 = 5
Ans: Inconsistent
Ans: Inconsistent Ans: Inconsistent
d. 2 x1 − x2 + 3x3 = 5 e. −3x + 2y − 3z = −8 f. x1 + x2 + 2 x3 = 8
2x − y + z = 4 − x1 − 2 x2 + 3x3 = 1
− x1 + 3x2 + 5 x3 = 3
x + 2y − 4z = −2
− 4 x1 + 2 x2 − 6 x3 = 3 Ans. (2, 2, 2) 3x1 − 7 x2 + 4 x3 = 10
g. x + y + 2z = 1 h. x + 2y + 4z = −13 i. x1 − x2 + 2 x3 = 5
y + z =1 3x − y + z = 5 2 x1 + x2 − x3 = 2
x + 3y =3
−2 x + 3 y + z = 3 2 x1 − x2 − x3 = 4
Ans. (3, 0, −4)
Ans. (−1, 0, 1) Ans: (2, −1, 1)
j. 2x − y − 5 z = 4 k. 5 x + 3 y = 19 l. x1 + 2 x2 − 2 x3 = 2
x + y + z = −3 2 x − 7 y = −17 − x1 + x2 − 2 x3 = −1
− x −4y + z = 4 Ans: (2, 3) x1 − 4 x2 − 2 x3 = 8
Ans: (−1, − 1, − 1)
Ans: (2, −1, −1)
m. 2x − 3y + 4z = 8 n. 3x + y + 2z = 14 o. x+ y+z =0
3 x + 4 y − 5 z = −4 2y + 5z = 22 x− y+z =0
2x + 5y − z = −22
5x − 7 y + 6z = 9 x+ y−z =0
Ans: (2, −4 , 6)
Ans: (1, 2, 3) Ans: (0, 0, 0)
p. −x + y −z=0 q. x + 2y +3z =1 r. x + y + z = −1
3 x − y + 2 z = −2 x + 3y + 6z = 3 x − y + z = −5
2 x + 4 y + 3z = 2 2 x + 6 y + 13z = 5 2x + y − z = 5
Ans: (−2, 0, 2) Ans: (0, 2, −3)
Ans: (−6, 5, −1)
30
Matrices, Vectors, Fourier Analysis Spring 2020-2021
s. x + 2 y + 3z = 5 t. 3x + 2 y − z = −15 u. − x + 2 y + 2 z = −2
2 x + 5 y + 3z = 3 5x + 3 y + 2 z = 0 3x + 2 y − z = 9
x + 8 z = 17 3x + y + 3z = 11 x +4 y + z= 5
Ans: (1, −1, 2) −6 x − 4 y + 2 z = 30 Ans: (2, 1, −1)
Ans: (−4, 2, 7)
2. Determine the value(s) of such that the following system of linear equations has (𝑖) no
solution, (𝑖𝑖) more than one solution, and (𝑖𝑖𝑖) a unique solution.
x + y + z = 1
x + y + z = 1 .
x + y + z = 1
Ans: (𝑖) 𝜆 = −2, (𝑖𝑖) 𝜆 = 1, (𝑖𝑖𝑖) 𝜆 ≠ 1, 𝜆 ≠ −2.
3. Determine the value(s) of such that the following system of linear equations has (𝑖) no
solution, (𝑖𝑖) more than one solution, and (𝑖𝑖𝑖) a unique solution.
x − 3z = −3
2 x + y − z = −2 .
x + 2 y + z = 1
Ans: (𝑖) 𝜆 = −5, (𝑖𝑖) 𝜆 = 2, (𝑖𝑖𝑖) 𝜆 ≠ 2, 𝜆 ≠ −5.
4. Determine the value(s) of and 𝜇 such that the following system of linear equations has (i)
no solution, (ii) more than one solutions and (iii) a unique solution.
𝑥+𝑦 +𝑧 =2
𝑥 + 3𝑦 + 𝜆𝑧 = 6.
𝑥 + 2𝑦 + 3𝑧 = 𝜇
5. Determine the value(s) of such that the following system of linear equations has (𝑖) no
solution, (𝑖𝑖) more than one solution, and (𝑖𝑖𝑖) a unique solution.
x + y + z = 1
x + y + z = .
x + y + z = 2
Ans: (𝑖) 𝜆 = −2, (𝑖𝑖) 𝜆 = 1, (𝑖𝑖𝑖) 𝜆 ≠ 1, 𝜆 ≠ −2.
6. The network in the figure below shows the traffic flow (in vehicles per hour) over the
several one-way streets. Determine the general flow pattern for the network.
31
Matrices, Vectors, Fourier Analysis Spring 2020-2021
7. The network in the figure below shows the traffic flow (in vehicles per hour) over the several
one-way streets. Determine the general flow pattern for the network.
a. b.
Ans: (a) Here 𝑥3 is the free variable. The system has an infinite number of solutions. But to
remove negativity 𝑥3 must be between 0 to 500.
(b) Here 𝑥3 is the free variable. The system has an infinite number of solutions. But to
remove negativity 𝑥3 must be greater than 500.
8. The network in the figure below shows the traffic flow (in vehicles per hour) over the
several one-way streets. Determine the general flow pattern for the network.
32
Matrices, Vectors, Fourier Analysis Spring 2020-2021
Ans: Here 𝑥5 is the free variable. The system has an infinite number of solutions. But to
remove negativity 𝑥5 must start from 200.
9. A company produces three products 𝑥, 𝑦, 𝑧 every day. Their total production on a certain day
is 45 tons. It is found that the production of 𝑧 exceeds the production of 𝑥 by 8 tons while the
total production of ‘𝑥’ and ‘𝑧’ is twice the production of ‘𝑦’. Determine the production level of
the each product.
a) b)
33
Matrices, Vectors, Fourier Analysis Spring 2020-2021
11. Determine the loop currents I 1 and I 2 of the following circuit using mesh analysis.
Where 𝐸1 = 28 , 𝐸2 = 7 V, 𝑅1 = 4 Ω, 𝑅2 = 1Ω, 𝑅3 = 2Ω.
Answer: 𝐼1 = −5 𝐴, 𝐼2 = 1 𝐴.
12. A transport company has two types of trucks, Type A and Type B. Type A has a refrigerated
capacity of 20 m³ and a non-refrigerated capacity of 40 m³ while Type B has the same overall
volume with equal sections for refrigerated and non-refrigerated stock. A grocer needs to hire trucks
for the transport of 3,000 m³ of refrigerated stock and 4,000 m³ of non-refrigerated stock. The cost
per kilometer of a Type A is 30 and 40 for Type B. How many trucks of each type should the grocer
rent to achieve the minimum total cost?
Supplementary:
34
Matrices, Vectors, Fourier Analysis Spring 2020-2021
1 -1 6
35