Linear system and matrices:

advertisement
Linear system and matrices:
For the system of linear equations,
a11 x1  a12 x2    a1n xn  b1
a21 x1  a22 x2    a2 n xn  b2

am1 x1  am 2 x2    amn xn  bm
the matrix representation is
 a11 a12
a
a
Ax   21 22
 


am1 am 2
 a1n   x1   a11 x1  a12 x2    a1n xn   b1 
 a2 n   x2   a21 x1  a22 x2    a2 n xn   b2 


b
 
     

  
  
 amn   xn  am1 x1  am 2 x2    amn xn  bm 
,where
 a11
a
A   21
 

am1
a12
a22

am 2
 a1n 
 x1 
 b1 
x 
b 
 a2 n 
2
, x   , b   2 


  

 
 
 amn 
x
 n
bm 
Example:
3x1  2 x 2  5 x3  7
x1  8 x2  4 x3  9
3 2 - 5   x1   7 
 1 - 8 4   x 2    9 
.
2 6  7  x3   2
2 x1  6 x2  7 x3  2
3 2  5
 x1 
7
 Ax  b, where A  1  8 4 , x   x2 , and b   9  .
2 6  7
 x3 
 2
1
Note:
 a11 a12  a1n   x1   a11 x1  a12 x2    a1n xn 
a
a22  a2 n   x2   a21 x1  a22 x2    a2 n xn 
21

Ax 

 





   


  

a
a

a
x
a
x

a
x



a
x
mn   n 
mn n 
 m1 m 2
 m1 1 m 2 2
 a11 x1   a12 x2 
 a1n xn   a11 
 a12 
 a1n 
a x   a x 
a x  a 
a 
a 
21
1
22
2
2
n
n
21
22

  
    x    x     2n  x

     
      1    2
   n

 


  
 
 
am1 x1  am 2 x2 
amn xn  am1 
am 2 
amn 
 col1 ( A) x1  col2 ( A) x2    coln ( A) xn  b
Intuitively,
col1 ( A) x1  col 2 ( A) x2  col n ( A) xn  b
is also a linear equation with coefficient vectors col1 ( A), col 2 ( A), , col n ( A) ,
constant vector b and unknown variables x1 , x2 ,, xn .
Example:
3x1  2 x2  5 x3  7
3 2 - 5   x1  3
2
  5
7
x1  8 x2  4 x3  9  1 - 8 4   x2   1 x1   8 x2   4  x3   9 
2 6  7  x3  2
 6 
 7
 2
2 x1  6 x2  7 x3  2
2
Matrix method for solving linear system:
Motivation:
Suppose we have the following simple linear equation ax  b , where a, b are real
number and x is unknown variable. Suppose a  0 . Then,
1
side by a
ax  b multiply
both

 a 1ax  a 1b  1  x  a 1b  x  a 1b
Thus, for the linear system Ax  b , where A is a n  n square matrix, b is a
n 1 vector and x is a n 1 vector, suppose there exists a matrix A 1 such
that A 1 A  I n  n  n identity matrix. Then,
1
multiply both side by A
Ax  b 
 A1 Ax  A1b  I n  x  A1b  x  A1b
Conclusion:
For the linear system Ax  b , where A is a n  n square matrix, b is a n 1
vector and x is a n 1 vector, if there exists a matrix A 1 such that
A 1 A  I n  n  n identity matrix, then A 1b is the solution. We now introduce
the matrix A 1 .
Definition of inverse matrix:
An n  n matrix A is called nonsingular or invertible if there exists an n  n
matrix B such that
AB  BA  I n ,
where
In
is a n  n identity matrix. The matrix B is called an inverse of A.
If there exists no such matrix B, then A is called singular or noninvertible.
Important results:
1.
If A is an invertible matrix, then its inverse is unique. The inverse of A is
denoted by
A 1 .
[proof:]
Suppose B and C are inverses of A. Then,
3
BA  CA  I n  B  BI n  B( AC)  ( BA)C  I n C  C .
2.
A 
 A.
3.
 AB 1
 B 1 A1
4.
A 
5.
1
1
T
1

 A1

T
If C is an invertible matrix, then
 AC  BC  A  B.

CA  CB  A  B .
How to find A
1
:
Motivating example:B
Determine the inverse of the matrix
1
A
2

 1
1
3
3
 2
 5
.
5 

[solution:]
 x11
Suppose A   x21

 x31
1
x12
x 22
x32
x13 
x23  . Then,
x33 
 1  1  2  x11
AA1   2  3  5  x21
 1 3
5   x31
x12
x22
x32
x13  1 0 0
x23   0 1 0  I 3 .
x33  0 0 1
Thus,
 x11   1  1  2  x11  1
 x12   1  1  2  x12  0








A x21    2  3  5  x21   0 , A x 22    2  3  5  x 22   1 ,
 x31   1 3
 x32   1 3
5   x31  0
5   x32  0
4
and
 x13   1  1  2  x13  0
A x 23    2  3  5  x 23   0 .
 x33   1 3
5   x33  1
We need solve for 3 linear systems with common coefficient matrix A and the
1 0
0




constant vectors 0 , 1 , and 0 . The associated augmented matrices for the 3
   
 
0 0
1
linear systems are
 1  1  2 1
  2  3  5 0 ,


  1 3
5 0
 1  1  2 0
 2  3  5 1 ,


  1 3
5 0
 1  1  2 0
  2  3  5 0 .


  1 3
5 1
We need to transform the 3 augmented matrices in reduced row echelon forms.
Adding the first row to the third row is the first step. The resulting matrices are
( 3)  ( 3)  (1)
 
 1  1  2 1
  2  3  5 0 ,


 0
2
3 1
 1  1  2 0
 2  3  5 1 ,


 0
2
3 0
 1  1  2 0
  2  3  5 0 .


 0
2
3 1
the same
Observe that the first 3 columns which correspond to coefficient matrix in the above
matrices are the same. The only difference is the last column in the augmented
matrices. Therefore, we can solve the 3 linear systems by using a new augmented
matrix
 1  1  2  1 0 0
 2  3  5  0 1 0


 1 3
5  0 0 1
A
( 3)  ( 3)  (1)
 
1  1  2  1 0 0
 2  3  5  0 1 0 .


0 2
3  1 0 1
I3
The first 3 and the fourth columns are corresponding to the original first
5
augmented matrix, the first 3 and the fifth columns to the original second
augmented matrix and the first 3 and the sixth columns to the original third
augmented matrix.
The procedure for computing the inverse of a n  n matrix A:
1. Form the n  2n augmented matrix
 a11 a12
a
a
A  I n    21 22
 


a n1 a n 2
 a1n  1
 a2n  0
   
 a nn  0
0  0
1  0
  

0  1
and transform the augmented matrix to the matrix
C
2.
D

in reduced row echelon form via elementary row operations.
If
(a) C  I n , then A1  D .
(b) C  I n , then A is singular and A 1 does not exist.
Motivating example (continue):
1
 1
To find the inverse of A   2


 1
 2
, we can employ the procedure
 5

5 

3
3
introduced above.
1.
1
2

 1
(3)(3)(1)
( 2)( 2)2*(1)

1
0

0
1
2  1
0
3
3
5 
5 
1
0
1
2 
1
2
1
3


6
0
0
1
0
2
1
1
0
0
0 .
1
0
0
1
( 2 )1*( 2 )

(1)(1)( 2)
(3)(3)2*( 2)

1  2 
1
1
2
1
3


2
1
1
0

0
0
1 
1
0

0
(1)(1)(3)
( 2)( 2)(3)

2.
1
0

0
1
0
1
1
0
 1 0
0 1
0
 1 0
 1 0
2 1
3


2
3
0
0 
0
1
1
0
0 
1 
5
3
3
2
1
 1
1 
The inverse of A is
 0
 5


 3
1
3
2
1 
 1
.
1 

Important result:
If A is an n  n matrix. Then A is nonsingular (has an unique inverse) if and
only if
Ax  b
has a unique solution
x  A 1b .
[proof:]
 : A is nonsingular, then there exists an unique A 1 . Thus
A 1 Ax  A 1b  I n x  A 1b  x  A 1b .
 : Suppose Ax  b has a unique solution d. Therefore, the augmented matrix
A b can be transformed to the matrix in reduced row echelon form I n d 
via elementary row operations. Thus, we can employ the same row operations to
the augmented matrix A  I n  and the resulting matrix is I n  D. D is
the inverse of A.
Motivating example (continue):
7
 1
Solve for the linear system Ax   2


 1
1
3
3
 2  x1 
 1 



.
 5  x2   
 3 

5 

 x3 

  2

[solution:]
0 1 1
 1   0 1 1  1   1 
A 1   5  3  1  x  A 1  3    5  3  1  3    2 .
 3 2 1 
 2  3 2 1   2  1 
Note:
When we want to solve the linear system
be more efficient to find
A 1
Ax  b
for x as we vary b., it would
and the corresponding solution x  A 1b than
using Gauss-Jordan reduction for different linear systems.
8
Download