Académique Documents
Professionnel Documents
Culture Documents
Lecture 1
September 19, 2011
1
Outline
Course information
Motivation
Outline of the course
What is linear algebra?
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
1.2 Vectors and Matrices
2
Course information
Instructor: Professor Gwoboa Horng
Textbook
Linear Algebra : Theory and Applications,
Ward Cheney & David Kincaid,
Jones and Bartlett 1st ed. 2009 (760 pages) / 2nd ed. 2012 (648 pages)
http://www.ma.utexas.edu/CNA/LA/index.html
3
Course information
Course web page
http://ailab.cs.nchu.edu.tw/course/LA/100/
schedule.htm
Password: ailab 4
Course information
Grading (Tentative)
Homework/Quiz 20%
(You may collaborate when solving the homework.
However, when writing up the solutions you must do
so on your own. Handwritten only.)
Midterm exam 30%
Final exam 30%
Class participation 20%
5
Outline
Course information
Motivation
Outline of the course
What is linear algebra?
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
6
Purposes of the course
To make the students become familiar with the basic
concepts of linear algebra.
Understand matrices, vector spaces, linear transformations.
To enhance the students' ability to reason
mathematically.
Understand proofs, abstract notions.
To make the students aware of the crucial
importance of linear algebra to many fields in
engineering, statistics and computer science.
Nonliear mathematics are hard.
Linearizations are good approximations.
7
Some application areas
Computer network
Network flow
Computer graphics
Transformations of the plane
Coding theory
Error-correcting codes
Cryptography
Hill cipher
More applications
http://aix1.uottawa.ca/~jkhoury/app.htm
8
Outline
Course information
Motivation
Outline of the course
What is linear algebra?
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
9
Outline of the course (1/2)
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
1.2 Vectors and Matrices
1.3 Homogeneous Linear Systems
Chapter 2. Vector Spaces and Transformations
2.1 Euclidean Vector Spaces
2.2 Line, Planes, and More
2.3 Linear Transformations
2.4 General Vector Spaces
Chapter 3. Matrix Operations
3.1 Matrices
3.2 Matrix Inverses
Chapter 4. Determinants
4.1 Determinants: Introduction
4.2 Determinants: Properties and Applications
10
Outline of the course (2/2)
Chapter 5. Vector Subspaces
5.1 Column, Row, and Null Spaces
5.2 Bases and Dimension
5.3 Coordinate Systems
Chapter 6. Eigensystems
6.1 Eigenvalues and Eigenvectors
Chapter 7. Inner Product Vector Spaces
7.1 Inner Product Spaces
7.2 Orthogonality
Chapter 8. Additional Topics
8.1 Hermitian Matrices and Spectral Theorem
8.2 Matrix Factorizations and Block Matrices
8.3 Iterative Methods
11
Outline
Course information
Motivation
Outline of the course
What is linear algebra?
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
12
Algebraic structures
An algebraic structure consists of one or
more sets, closed under one or more
operations, satisfying some axioms.
Group-like structures
Z under addition (+) is an abelian group.
Field
Each of Q, R, and C, under addition and
multiplication, is a field.
13
What is Linear & Algebra? y
cv
v
Consider a line through the origin x
cv
v
15
What is linear algebra?
A branch of mathematics that studies vectors,
matrices, vector spaces, and systems of
linear equations (p. 1)
Vectors and matrices can produce systems of
linear equations
Systems of linear equations can often model
an applied problem from the real world
16
Outline
Course information
Motivation
Outline of the course
What is linear algebra?
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
1.2 Vectors and Matrices
17
Some advise
Take notes
Read in advance
Do exercises
Make use of the web resources
18
Linear equations
Example 7x - 3y = 21
A single linear equation
ontaining two variables
The word linear
derives from the word
(0,-7)
line.
19
Linear equations
The point-slope form of a line is
y = mx + b where m is the slope and b is the
intercept on the y-axis.
Example 1: 7x - 3y = 21 y = 7/3 x 7
For two points (x0,y0) and (x1,y1), the
two-point form of the line through these
points is y - y0 = m (x-x0) where
m=(y1-y0)/(x1-x0)
20
Linear equations
Extend
a single linear equation containing two
variables
to
a system of m linear equations containing n
variables (unknowns)
21
Linear equations
A linear equation in the n variables
a1x1 + a2 x2 + ... + an xn = b
22
Linear equations
Notation:
Example: x + 3 y = sin 7, 2 variables: x, y
1 3 variables: x, y, z
y = x + 8z + 7 , n variables: x1, x2, ,xn
2
x1 9 x2 3 x3 + x4 = 34
Example:
23
Solving Systems of Linear Equations
Definition
A system of equations is consistent if it has at least one solution,
and inconsistent if it has no solution.
Every system of linear equations has either no solutions, exactly
one solution, or infinitely many solutions.
add -2 times the first equation add -2 times the first row
to the second to the second
x + y + 2z = 9 1 1 2 9
2 y 7 z = 1 7 0 2 7 17
3x + 6 y 5 z = 0 3 6 5 0
add -3 times the first quation add -3 times the first row
to the third to the third 27
Continued in the next slide.
Solving Systems of Linear Equations
x + y + 2z = 9 1 1 2 9
2 y 7 z = 17 0 2 7 17
3 y 11z = 27 0 3 11 27
multiple the second equation by 1/2 multiple the second row by 1/2
x + y + 2z = 9 1 1 2 9
0 1 7 17
y 72 z = 172 2 2
3 y 11z = 27 0 3 11 27
x + y + 2z = 9
1 1 2 9
y 7 z = 17 0 1 7 172
2 2 2
1z=3 0 0 12 32
2 2
multiple the third equation by -2 multiple the third equation by -2
x + y + 2z = 9 1 1 2 9
0 1 7 172
y 7 z = 17 2
2 2
0 0 1 3
z= 3
add -1 times the second
add -1 times the second
equation to the first
equation to the first
29
Continued in the next slide.
Solving Systems of Linear Equations
x + 11
z= 35 1 0 112 35
2
2 2
0 1 7
17
y 72 z = 172 2 2
0 0 1 3
z= 3
add -11/2 times the third add -11/2 times the third
equation to the third and equation to the third and
7/2 times the third 7/2 times the third
equation to the second equation to the second
x =1 1 0 0 1
y = 2 0 1 0 2
z= 3 0 0 1 3
solution 30
Solving Systems of Linear Equations
Matrix form of a Linear System
a11 x1 + a12 x 2 + ... + a1n x n = b1 a11x1 + a12 x2 + ... + a1n xn b1
a 21 x1 + a 22 x 2 + ... + a 2 n x n = b2 a x + a x + ... + a x b
21 1 22 2 2n n
= 2
# # # # # # # #
a m1 x1 + a m 2 x 2 + ... + a mn x n = bm
a x +
m1 1 m2 2
a x + ... + a mn n
x bm
# # # # # # # #
am1 x1 + am 2 x2 + ... + amn xn = bm am1 am 2 ... amn bm
32
Solving Systems of Linear Equations
33
Continued in the next slide.
Solving Systems of Linear Equations
34
Solving Systems of Linear Equations
35
Continued in the next slide.
Elementary Row Operations
Three types of elementary row operations:
1. (scale) Multiple a row by a nonzero factor.
2. (replacement) Add a multiple of one row to another.
3. (swap) Interchange a pair of rows.
Let ri and rj be two rows.
1. ri kri (scale k 0)
2. rj rj + kri (i j, k is a scale)
3. ri rj
Note that the third type of operation is redundant
(since it can be achieved by a sequence of operations of
the first two types).
36
Elementary Row Operations
37
Elementary Row Operations
38
Elementary Row Operations
When we transform a system by elementary
row operations, we do not introduce
spurious solutions or lose genuine solutions.
We can add equal quantities to equal quantities
to obtain further equalities, and the process can
be reverse.
39
Equivalent Linear Systems
Definition (Equivalent Linear Systems)
Two linear systems are said to be equivalent if
one can be obtained from the other by a finite
number of elementary row operations.
THEOREM
Two equivalent systems have the same set of
solutions.
40
Equivalent Linear Systems
LEMMA
Let Cx = d be the linear system obtained
from the linear system Ax = b by a single
elementary row operation. Then the linear
systems Ax = b and Cx = d have the same
set of solutions.
41
Equivalent Linear Systems
42
Solving Systems of Linear Equations
43
Solving Systems of Linear Equations
0 0 ... 1 x x x x x x
0 0 ... 0 0 0 1 x x x
...
46
Solving Systems of Linear Equations
1 4 3 7 1 1 0 0 1 2 6 0
0 1 7 5 , 0 1 0 , 0 0 1 1 3
0 0 1 5 0 0 0 0 0 0 0 1
1 0 0 0 0 1 7 0 1
0 0 1 3 , 0 0
0 1 0 , 0 0 0 0 0 0 0
0 0 1
0 0 0 0 0
1. If a row does not consist entirely of zeros then the first nonzero number in the row is a 1.
2. If there are any rows that consist entirely of zeros, then they are grouped together at the bottom of the matrix.
3. In any two successive rows that do not consist entirely of zeros, the leading 1 in the lower row occurs farther to
the right than the leading 1 in the higher row.
4. Each column that contains a leading 1 has zeros everywhere else 47
Solving Systems of Linear Equations
49
Solving Systems of Linear Equations
Gaussian Elimination
Example:
x1 + 3 x2 2 x3 + 2x 5 = 0
2 x1 + 6 x2 5 x3 2 x4 + 4 x5 3 x6 = 1
5 x3 + 10 x4 + 15 x6 = 5
2 x1 + 6 x2 + 8 x4 + 4 x5 18 x6 = 6
1 3 - 2 0 2 0 0
1 3 -2 0 2 0 0 0 0 1 2 0 3 1
2 6 - 5 - 2 4 - 3 - 1
0 0 5 10 0 15 5 0 0 0 0 0 1 13
2 6 0 8 4 - 18 6
0 0 0 0 0 0 0
Augmented Matrix row-echelon form
1 3 - 2 0 2 0 0
0 0 1 2 0 3 1
x1 + 3x2 + 4x4 + 2x 5 = 0
0 0 0 0 0 1 13 x3 + 2x4 + 3x6 = 0
0 0 0 0 0 0 0 x6 = 13
Substituting x6 = 1/3 x1 = 3 x 2 + 2 x 3 2 x 5
into the 2nd equation x3 = 1 2 x 4 3 x6
x1 = 3 x 2 + 2 x 3 2 x 5 x6 = 1
3
x3 = 2 x 4 x1, x3, x6: leading variables
x6 = 1
3
x2, x4, x5: free variables
52
Solving Systems of Linear Equations
Gaussian-Jordan Elimination
Example:
x1 + 3x2 2x3 + 2x5 = 0
2x1 + 6x2 5x3 2x4 + 4x5 3x6 = 1
5x3 +10x4 +15x6 = 5
2x1 + 6x2 + 8x4 + 4x5 18x6 = 6
1 3 0 4 2 0 0
1 3 -2 0 2 0 0 0 0 1 2 0 0 0
2 6 - 5 - 2 4 - 3 - 1
0 0 5 10 0 15 5 0 0 0 0 0 1 1
3
2 6 0 8 4 - 18 6
0 0 0 0 0 0 0
Augmented Matrix reduced row-echelon form
Continued in the next slide. 53
Solving Systems of Linear Equations
x1 + 3 x2 + 4 x4 + 2 x5 =0 x1 = 3 x 2 4 x 4 2 x 5
x3 + 2 x4 =0 x3 = 2 x 4
x6 = 13 x6 = 1
3
x1 = 3r 4 s 2t , x 2 = r , x3 = 2 s , x 4 = s , x5 = t , x6 = 1
3
54
Algorithm for the reduced row
echelon form (p. 26)
Use blackboard
55
Important Terms
Pivot position: a position of a leading entry in
an echelon form of the matrix.
Pivot: a nonzero number that either is used in a
pivot position to create 0s or is changed into a
leading 1, which in turn is used to create 0s.
Pivot column: a column that contains a pivot
position.
56
Algorithm for the reduced row echelon form
Row reduce the matrix A below to echelon form and
locate the pivot columns of A.
0 3 6 4 9
1 2 1 3 1
A=
2 3 0 3 1
1 4 5 9 7
Pivot 0 3 6 4 9
1 2 1 3 1
Position
2 3 0 3 1
1 4 5 9 7
Pivot Column
58
Continued in the next slide.
Algorithm for the reduced row echelon form
Step 2(b): Select a nonzero entry in the pivot column
as a pivot. If necessary interchange rows to move this
entry into the pivot position.
Pivot 0 3 6 4 9 R1 R4
1 2 1 3 1
Position
2 3 0 3 1
1 4 5 9 7
Pivot Column
59
Continued in the next slide.
Algorithm for the reduced row echelon form
Step 2(b): Select a nonzero entry in the pivot column
as a pivot. If necessary interchange rows to move this
entry into the pivot position.
Pivot 1 4 5 9 7
1 2 1 3 1
2 3 0 3 1
0 3 6 4 9
Pivot Column
60
Continued in the next slide.
Algorithm for the reduced row echelon form
Step 2(c): Use elementary row operations to create
zeros in all positions below the pivot.
Pivot 1 4 5 9 7
1 2 1 3 1 R2 R2 + R1
2 3 0 3 1 R3 R3 + 2 R1
0 3 6 4 9
61
Continued in the next slide.
Algorithm for the reduced row echelon form
After a few computations we get
1 4 5 9 7
0 2 4 6 6
0 5 10 15 15
0 3 6 4 9
62
Continued in the next slide.
Algorithm for the reduced row echelon form
Step 3: Cover (or ignore) the row containing the pivot
position and cover all rows, if any, above it. Apply steps
1-2 to the remaining submatrix. Repeat the process until
there are no more nonzero rows to modify.
1 4 5 9 7
0 2 4 6 6
Possible
Pivots 0 5 10 15 15 R3 R3 5 2 R2
0 3 6 4 9 R4 R 4 + 3 2 R2
63
Continued in the next slide.
Algorithm for the reduced row echelon form
1 4 5 9 7
0 2 4 6 6
0 5 10 15 15 R3 R3 5 2 R2
0 3 6 4 9 R 4 R 4 + 3 R2
2
1 4 5 9 7
0 2 4 6 6
0 0 0 0 0
0 0 0 5 0
64
Continued in the next slide.
Algorithm for the reduced row echelon form
1 4 5 9 7
0 2 4 6 6
0 0 0 0 0
R3 R4
0 0 0 5 0
1 4 5 9 7
0 2 4 6 6
0 0 0 5 0
0 0 0 0 0
Pivot Columns
65
Continued in the next slide.
Algorithm for the reduced row echelon form
Step 4: Beginning with the rightmost pivot and working
upward and to the left, create zeros above each pivot.
If a pivot is not 1, make it 1 by a scaling operation.
1 4 5 9 7
0 2 4 6 6
0 0 0 5 0 R3 1 R3
5
0 0 0 0 0
66
Continued in the next slide.
Algorithm for the reduced row echelon form
1 4 5 9 7 R1 R1 + 9 R3
0 2 4 6 6 R2 R2 + 6 R3
0 0 0 1 0
0 0 0 0 0
1 4 5 0 7
0 2 4 0 6 R2 1 2 R2
0 0 0 1 0
0 0 0 0 0
Step 5: Repeat step 4, ending with the unique
reduced row echelon form of the given matrix. 67
Continued in the next slide.
Algorithm for the reduced row echelon form
1 4 5 0 7 R1 R1 4 R2
0 1 2 0 3
0 0 0 1 0
0 0 0 0 0
1 0 3 0 5
0 1 2 0 3 Reduced Row
0 0 0 1 0 Echelon Form
0 0 0 0 0
68
More examples
TRANSFORMING MATRIX TO ROW
ECHELON FORM
example01-2.htm
TRANSFORMING MATRIX TO THE
REDUCED ROW ECHELON FORM
example01-3.htm
69
Outline
Course information
Motivation
Outline of the course
What is linear algebra?
Chapter 1. Systems of Linear Equations
1.1 Solving Linear Systems
1.2 Vectors and Matrices
70
Vectors and Matrices
y vectors
x1
x = x2 = [x1, x2, ..., xn]T = (x1, x2, ..., xn)
..
.
xn
component xi: ith entry
zero vector: 0 = (0, 0, ..., 0)
vector addition: x = (x1, x2, ..., xn), y = (y1, y2, ..., yn)
x + y = (x1+ y1, x2 + y2, ..., xn+ yn) (Figure 1.3)
scalar multiplication: ax = (ax1, ax2, ..., axn) (Figure 1.4)
n-space Rn = {(x1, x2, ..., xn) | xi R}
71
Vectors and Matrices
72
Vectors and Matrices
73
Vectors and Matrices
x = 3b1 - 7b2
y = -2b1 + 5b2
75
Vectors and Matrices
76
example02-1.htm
77
Vectors and Matrices
78
Vectors and Matrices
79
Vectors and Matrices
80
Vectors and Matrices
81
Vectors and Matrices
Definition
Let S = {v1, v2, ..., vn}. The set of all linear combinations, denoted
as span(S), of a set of vectors is called the span of S.
Example: (Example 1 and Example 2)
R2 = span({(1, 0), (0,1)}) = span({(5, 2), (7, 3)})
42 1 3 7
6 = a 2 + b 1 + c 4
76 11 4 3
85
Interpreting linear systems
(4) a matrix with vectors (5) an augmented matrix
a11 a12 ... a1n x1 b1
a a ... a x b a11 a12 ... a1n b1
a a ... a
21 22 2n 2
= 2 21 22 2n b2
# # # # # # # # #
am1 am 2 ... amn xm bm am1 am 2 ... amn bm
87
row equivalent systems
88
row equivalent systems
Example:
5 1 11 ~ 5 1 11 ~ 5 1 11 ~ 1 2 11 ~ ... ~ 1 0 3
7 3 33 2 4 22 1 2 11 5 1 11 0 1 4
5x y = 11 x=3
7x + 3y = 33 y= 3
89
Example 8
90
Example 8
91
Example 8
92
Vectors and Matrices
93
Vectors and Matrices
94
Vectors and Matrices
1 * * * 1 * * * 1 * * *
0 1 * * , 0 1 * * , 0 1 * *
0 0 1 * 0 0 1 * 0 0 0 0
0 0 0 1 0 0 0 0 0 0 0 0 95
Vectors and Matrices
96
Vectors and Matrices
97
Vectors and Matrices
A restatement of Theorem 5
98
Questions?
99