Download as pdf or txt
Download as pdf or txt
You are on page 1of 32

MATH 241

LINEAR ALGEBRA I ( 1 ‫)اﻟﺟﺑر اﻟﺧطﻲ‬


DEPARTMENT OF MATHEMATICS - KAU
SECOND EDITION 2021
SECOND EDITION - 2021

The Determinant of a Matrix Eigenvalues and


Eigenvectors
Evaluation of a Determinant
using Elementary Operations
Gauss Elimination and Properties of Determinants
Gauss-Jordan elimination
Application of Determinants
Systems of linear
equations

Chapter Chapter Chapter


Two Four Six

Chapter Chapter Chapter


Vectors in ℝ!
One Three Seven
Vector Spaces
Operations with Matrices
Introduction to Linear
Properties of a Matrix Operations Subspaces of Vector Transformations
Spaces
The Inverse of a Matrix Spanning Sets and Linear The Kernel and
Independence Range
of a Linear
Basis and Dimension Transformation

Matrices for Linear


Transformations
SECOND EDITION - 2021

Textbook
SECOND EDITION - 2021
SECOND EDITION - 2021

Chapter 1: Systems of
Linear Equations

1.2 Gaussian Elimination and Gauss-Jordan


Elimination
SECOND EDITION - 2021

Definition of a Matrix

v Definition
Let 𝑚 and 𝑛 be positive integers. Then an 𝑚×𝑛 matrix is a rectangular array

Read “𝑚 by 𝑛”
𝑎## 𝑎#$ … 𝑎#% 𝑚 = the number of rows
𝑎$# 𝑎$$ … 𝑎$% 𝑛 = the number of columns
𝐴 = 𝑎!" = ⋮ ⋮ ⋮
𝑎&# 𝑎&$ 𝑎&%

in which the entry 𝑎!" is a real number located in the 𝑖-th row and the 𝑗-th column.
SECOND EDITION - 2021

Definition of a Matrix

Remark

v The matrix A is called a real matrix if each entry 𝑎!" ∈ ℝ.

v 𝑚×𝑛 is called the order of the matrix A.

v If 𝑚 = 𝑛, then the matrix is called a square matrix.

v If [𝑎!" ]% in square, then 𝑎##, 𝑎$$, … , 𝑎%% are said to be the main diagonal entries

(here 𝑖 = 𝑗).
SECOND EDITION - 2021

Example of Matrices

Example
I. [−10]#×#.
1 −5 #⁄
IV. $
1 −2 10 $×*
(
II. [−2 − π ]
) #×*

𝑒 2 7
V. 1 −17 4
0 0 log 3 −1 −5 *×*
III.
0 8 $×$
SECOND EDITION - 2021

Augmented Matrix and Coefficient Matrix

v Definition
q A matrix obtained from the coefficients and the constant terms of linear equations is

called the augmented matrix of the system.

q A matrix contains only the coefficients of the system is called the coefficient matrix.
SECOND EDITION - 2021

Augmented Matrix and Coefficient Matrix

𝑥 − 4𝑦 + 3𝑧 = 5 1 −4 3 5 1 −4 3
𝑥 + 3𝑦 − 2𝑧 = −3 1 3 −2 −3 1 3 −2
2𝑥 − 4𝑧 = 6 2 0 −4 6 2 0 −4

Augmented Coefficient
System
matrix matrix
SECOND EDITION - 2021

Elementary Row Operations

v Definition
Two matrices are said to be row-equivalent
if one can be obtained from other by a finite
Interchange two rows
sequence of elementary row operations.

Elementary row operations Multiply a row by


a non-zero constant

Add a multiple of a row


to another row
SECOND EDITION - 2021

Elementary Row Operations


Example
1 1 3 4 1 3 0 −1
I) 1 3 0 −1 𝑅! ⟷ 𝑅" 1 1 3 4
2 4 −7 0 2 4 −7 0

2 −4 8 −6 1 −2 4 −3
II) 1 4 6 2
1
𝑅
2 !
® 𝑅! 1 4 6 2
−1 0 5 1 −1 0 5 1

1 2 −4 3 1 2 −4 3
III) 1 3 −2 −1 −2𝑅" + 𝑅# ® 𝑅# 1 3 −2 −1
2 1 5 −2 0 −5 9 0
SECOND EDITION - 2021

Using Elementary Row Operations to


Solve a System
Example
Linear system Augmented matrix
𝑥 − 2𝑦 + 3𝑧 = 9 1 −2 3 9
−𝑥 + 3𝑦 = −4 −1 3 0 −4
2𝑥 − 5𝑦 + 5𝑧 = 17 2 −5 5 17

𝐸! + 𝐸" ® 𝐸" 𝑅! + 𝑅" ® 𝑅"

𝑥 − 2𝑦 + 3𝑧 = 9 1 −2 3 9
𝑦 + 3𝑧 = 5 0 1 3 5
2𝑥 − 5𝑦 + 5𝑧 = 17 2 −5 5 17
SECOND EDITION - 2021

Using Elementary Row Operations to


Solve a System
−2𝐸! + 𝐸# ® 𝐸# −2𝑅! + 𝑅# ® 𝑅#

𝑥 − 2𝑦 + 3𝑧 = 9 1 −2 3 9
0 1 3 5
𝑦 + 3𝑧 = 5
0 −1 −1 −1
−𝑦 − 𝑧 = −1

𝐸" + 𝐸# ® 𝐸# 𝑅" + 𝑅# ® 𝑅#

𝑥 − 2𝑦 + 3𝑧 = 9 1 −2 3 9
𝑦 + 3𝑧 = 5 0 1 3 5
2𝑧 = 4 0 0 2 4
SECOND EDITION - 2021

Using Elementary Row Operations to Solve a System

! !
𝐸
" #
® 𝐸# 𝑅 ® 𝑅#
" #

𝑥 − 2𝑦 + 3𝑧 = 9 1 −2 3 9
𝑦 + 3𝑧 = 5 0 1 3 5
𝑧 =2 0 0 1 2

By using back-substitution, we obtain By using back-substitution, we obtain


𝑧 = 2,
𝑦 = 5 − 3𝑧 𝑥 = 9 + 2𝑦 − 3𝑧 𝑧 = 2, 𝑦 = −1, 𝑥=1
=5−6 =9−2−6
= 1.
= −1
SECOND EDITION - 2021

Row-Echelon Form of a Matrix

v Definition
A matrix in row-echelon form has the following properties:

1) All rows consisting of zeros (if exists) only appear in the bottom of the
matrix.

2) For each non-zero row the first non-zero entry is 1 (such an entry is called
a leading 1 or pivot).

3) For two consecutive non-zero rows, the leading 1 in the higher row is
further to the left than the leading 1 in the lower row.
SECOND EDITION - 2021

Reduced Row-Echelon Form of a Matrix

v Definition
A matrix in row echelon form is called a reduced row-echelon form if every column
has a leading 1 has zero in every position above and below it’s leading 1.

Example The following matrices are in row-echelon form.


1 −5 2 −1 3 1 0 0 2
1 2 1 4 0 1 0 5 0 1 0 −4
C)
0 0 1 −4 2 D)
A) 0 1 0 3 B) 0 0 1 3
0 0 0 1 0 0 0 1 3
0 0 1 −3 0 0 0 0 0 0 0 0 1 0 0 0 0

The matrices in (B) and (D) are in reduced row-echelon form


SECOND EDITION - 2021

Examples of Non Row-Echelon Form of a Matrix

The following matrices are not in row-echelon form.

1 2 −1 3 1 2 −1 3
e) 0 4 7 −2 f) 0 0 0 0
0 0 1 1 0 −1 2 4
0 0 0 0

Later, we will show that every matrix is a row-equivalent to a matrix in row-echelon form.
SECOND EDITION - 2021
...

...

...

...
Gaussian Elimination with Back-Substitution

1) Write the augmented matrix of the system of linear equations.

2) Use elementary row operations to write the augmented matrix

in row echelon form.


The process named
3) Write the system of linear equations corresponding to the after
Card Friedrich Gauss
matrix in row-echelon form and use Back-substitution to find (German mathematician)
1777-1855
the solution.
SECOND EDITION - 2021

Example Use Gaussian with back-substitution to solve linear equations


𝑥" + 𝑥# − 2𝑥$ = −3 1 2 −1 0 2
𝑥! + 2𝑥" − 𝑥# =2 0 1 1 −2 −3
(−2𝑅! + 𝑅# ® 𝑅# )
0 0 3 −3 −6
2𝑥! + 4𝑥" + 𝑥# − 3𝑥$ = −2
1 −4 −7 −1 −19
𝑥! − 4𝑥" − 7𝑥# − 𝑥$ = −19
1 2 −1 0 2
The augmented matrix is 0 1 1 −2 −3
(− 𝑅! + 𝑅$ ® 𝑅$ )
0 0 3 −3 −6
0 1 1 −2 −3 0 −6 −6 −1 −21
1 2 −1 0 2
2 4 1 −3 −2 1 2 −1 0 2
1 −4 −7 −1 −19 0 1 1 −2 −3
(6𝑅" + 𝑅$ ® 𝑅$ )
0 0 3 −3 −6
0 0 0 −13 −39
1 2 −1 0 2
0 1 1 −2 −3 1 2 −1 0 2
( 𝑅! ↔ 𝑅" )
2 4 1 −3 −2 !
( 𝑅# ® 𝑅# ) 0 1 1 −2 −3
1 −4 −7 −1 −19 #
0 0 1 −1 −2
0 0 0 −13 −39
SECOND EDITION - 2021

Solving A System Using Gaussian Elimination

1 2 −1 0 2 𝑥$ = 3,
(− !# 𝑅$ ® 𝑅$ ) 0 1 1 −2 −3
!

0 0 1 −1 −2 𝑥# = −2 + 𝑥$
0 0 0 1 3 = −2 + 3
= 1,

The corresponding linear system: 𝑥" = −3 − 𝑥# + 2𝑥$

𝑥! + 2𝑥" − 𝑥# =2 = −3 − 1 + 6
= 2,
𝑥" + 𝑥# − 2𝑥$ = −3
𝑥! = 2 − 2𝑥" + 𝑥#
𝑥# − 𝑥$ = −2
=2−4+1
𝑥$ = 3 = −1.
SECOND EDITION - 2021 1 −1 2 4
Example Solve
(−2𝑅! + 𝑅# ® 𝑅# )
0 1 −1 2
0 −1 1 −4
𝑥# − 𝑥$ + 2𝑥* =4 3 2 −1 1
𝑥# + 𝑥* =6
1 −1 2 4
2𝑥# − 3𝑥$ + 5𝑥* =4 0 1 −1 2
(−3𝑅! + 𝑅$ ® 𝑅$ )
3𝑥# + 2𝑥$ − 𝑥* =1 0 −1 1 −4
0 5 −7 −11
The augmented matrix is 1 −1 2 4
0 1 −1 2
(𝑅" + 𝑅# ® 𝑅# )
0 0 0 −2
1 −1 2 4
0 5 −7 11
1 0 1 6
2 −3 5 4 The corresponding linear system
3 2 −1 1
𝑥# − 𝑥$ + 2𝑥* = 4
𝑥$ − 𝑥* = 2
1 −1 2 4
0 = −2
( −𝑅! + 𝑅" ® 𝑅" ) 0 1 −1 2
2 −3 5 4 5𝑥$ − 7𝑥* = −11
3 2 −1 1
The system has no solution.
SECOND EDITION - 2021

Rank of Matrices
So far, we solved two systems of linear equations using Gaussian Elimination, the first system
has a unique solution while the second one has no solution. We will illustrate an example of
a system with infinite number of solutions after the following definition:

v Definition
The rank of a matrix is the number of nonzero rows in its row echelon form.

Note that it is not necessary to find the reduced echelon form to compute the rank of a matrix, row echelon form
is indeed sufficient.
SECOND EDITION - 2021

Number of Free Variables in Solving a System

The assertion below tells us how many free variables (parameters) before we
find the explicit solution of a system.

v Theorem
Let 𝐴 be the coefficient matrix of a system of linear equations with 𝑛 variables.
If the system is consistent, then
Number of free variables = 𝑛 − 𝑟𝑎𝑛𝑘(𝐴)
SECOND EDITION - 2021

Example Solve
−𝑅" ® 𝑅"
1 2 −1 0
2𝑥# + 4𝑥$ − 2𝑥* = 0 0 1 −3 −1
3𝑥# + 5𝑥$ =1
The rank of the above matrix is 2; but we have 3 variables. Hence,
using the above theorem, the number of free variables is 1.
The augmented matrix is
The corresponding system is
2 4 −2 0
𝑥! + 2𝑥" − 𝑥# = 0
3 5 0 1 𝑥" −3𝑥# = −1

Let 𝑡 ∈ ℝ,
1 1 2 −1 0
𝑅 ® 𝑅!
2 ! 3 5 0 1 𝑥* = 𝑡
𝑥$ = −1 + 3𝑡,
1 2 −1 0 𝑥# = 2 − 5𝑡.
−3𝑅! + 𝑅" ® 𝑅"
0 −1 3 1
SECOND EDITION - 2021

Gauss-Jordan Elimination

1) Write the augmented matrix of the system of linear equations.

2) Use elementary row operations to write the augmented matrix in


row echelon form.
3) Continue the reduction process to obtain a reduce row-echelon
The process published
form. in 1988
Wihelm Jordan
4) Write the system of linear equations corresponding to the matrix
(German mathematician)
in reduced row-echelon form and use Back-substitution to find 1842-1899
the solution.
SECOND EDITION - 2021

Example Use Gauss-Jordan elimination to solve the system


1 −2 3 9
𝑥 − 2𝑦 + 3𝑧 = 9 (−2𝑅! + 𝑅# ® 𝑅# ) 0 1 3 5
−𝑥 + 3𝑦 = −4 0 −1 −1 −1
2𝑥 − 5𝑦 + 5𝑧 = 17
1 −2 3 9
The augmented matrix is ( 𝑅" + 𝑅# ® 𝑅# ) 0 1 3 5
1 −2 3 9 0 0 2 4
−1 3 0 −4
2 −5 5 17

!
1 −2 3 9
( 𝑅
" #
® 𝑅# ) 0 1 3 5
1 −2 3 9 0 0 1 2
(𝑅! + 𝑅" ® 𝑅" ) 0 1 3 5
2 −5 5 17
SECOND EDITION - 2021

1 −2 3 9
−3𝑅# + 𝑅" ® 𝑅" 0 1 0 −1
0 0 1 2

1 −2 0 3
−3𝑅# +𝑅! ® 𝑅! 0 1 0 −1
0 0 1 2

1 0 0 1
2𝑅" +𝑅! ® 𝑅! 0 1 0 −1
0 0 1 2

Thus 𝑥 = 1, 𝑦 = −1, 𝑧 = 2.
SECOND EDITION - 2021

Homogeneous system of linear equations

v A Homogeneous system has the form

𝑎##𝑥# + 𝑎#$𝑥$ + ⋯ + 𝑎#% 𝑥% = 0


𝑎$#𝑥# + 𝑎$$𝑥$ + ⋯ + 𝑎$% 𝑥% = 0
𝑎*#𝑥# + 𝑎*$𝑥$ + ⋯ + 𝑎*% 𝑥% = 0

⋮ ⋮ ⋮ ⋮

𝑎&#𝑥# + 𝑎&$𝑥$ + ⋯ + 𝑎&% 𝑥% = 0

The Homogeneous system has at least one solution which is zero (the trivial solution).
SECOND EDITION - 2021

Example Solve the homogeneous system (𝑅" + 𝑅! ® 𝑅! )


1 0 2 0
0 1 −1 0
𝑥# − 𝑥$ + 3𝑥* = 0
2𝑥# + 𝑥$ + 3𝑥* = 0 The corresponding system:

Applying Gauss-Jordan elimination 𝑥# +2𝑥*= 0


yields the augmented matrix below 𝑥$ − 𝑥* = 0

1 −1 3 0 Let 𝑥* = 𝑡, 𝑡 ∈ ℝ. Then
2 1 3 0
𝑥$ = 𝑡
𝑥# = −2𝑡,
(−2𝑅! +𝑅" ® 𝑅" )
1 −1 3 0
0 3 −3 0
The system has an infinite number of solutions.
1 1 −1 3 0
𝑅 ® 𝑅"
3 " 0 1 −1 0
SECOND EDITION - 2021

The Number of Solutions of a Homogeneous system


v Theorem
1) Every homogeneous system of a linear equations is consistent.
2) If a homogeneous system has fewer equations than variables, then it must have an
infinite number of solutions.

Notice that the second part of the above theorem does not necessarily hold for an
inhomogeneous system with fewer equations than variables.

Ex. The system 𝑥! +𝑥" + 𝑥# = 1


𝑥! +𝑥" + 𝑥# = 2
is inhomogeneous and has fewer equations than variables; yet it has no solution (Why?!)
SECOND EDITION - 2021

Homework 1.2
Page Number Exercise Number
26 1, 2, 9, 11, 17, 31, 36

27 49, 51

28 59, 60

Elementary Linear Algebra Sixth Edition By


Larson | Edwards | Falvo

You might also like