week4

73

Upload: osamahussien

Post on 18-Dec-2014

244 views

Category:

Documents


7 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Week4
Page 2: Week4
Page 3: Week4

A row of a matrix is a zero row if it consists entirely of A row of a matrix is a zero row if it consists entirely of zeros. A row which is not a zero row is a nonzero row.A leading entry of a row refers to the leftmost nonzero A leading entry of a row refers to the leftmost nonzero entry in a nonzero row

A unit column of a matrix is a column with one A unit column of a matrix is a column with one entry a 1 and all other entries 0.

0 1 1 0 3

0 0 0 0 0 0

2non-zero row

Leading entry

0 0 0 0 0 0

6 1 0 2 0

0 0 0 0

1

0 0zero row 0 0 0 0 0 0

unit columnunit column

Page 4: Week4

A matrix is in row-echelon form if and only if:A matrix is in row-echelon form if and only if:

1. All zero rows occur below all nonzero rows.

2. The leading entry of a nonzero row lies strictly to the right of the leading entry of any other preceding row.right of the leading entry of any other preceding row.

3. All entries in a column below a leading entry are zeros.3. All entries in a column below a leading entry are zeros.

3

0

6

33

0

6

3

0 2 -1 4

0

0

1

22.

3.

0

0

1

2

0 0 0 01.

Page 5: Week4

A matrix A is in or A matrix A is in or if it is in

echelon form and satisfies the following echelon form and satisfies the following additional conditions:additional conditions:1- All the leading entries are 1.

2- Every column containing a leading one is a .

Page 6: Week4

unit columnsunit columns

leading 1s

Page 7: Week4

The following matrices are in echelon The following matrices are in echelon form.

2 3 2 1 1 2 1 0

0 1 4 8

0 0 0 5 2

0 1 4 4

0 0 1 30 0 0 5 2 0 0 1 3

Page 8: Week4

And the following matrices And the following matrices

1 0 0 01 0 0 29 1 0 0 0

0 1 0 4

1 0 0 29

0 1 0 16

0 0 0 00 0 1 3

are in reduced echelon form.

Page 9: Week4

Example 3:

not a unit columnA is in row-echelon form.A fails to be in reduced row-echelon form

1 2 3A fails to be in reduced row-echelon form because the second column contains a leading 1, but is not a unit column.

0 1 7

0 0 0

A

leading 1, but is not a unit column.0 0 0

leading 1

C fails to be in row-echelon form because C fails to be in row-echelon form because the leading 1 in the second row is to the right of the leading 1 in the third row. Since 1

0

0

0

5 1 2 1

C right of the leading 1 in the third row. Since C is not in row-echelon form, it cannot be in reduced row-echelon form.

0 1 0 0

1

0

0

0C

leading 1s

Page 10: Week4

The following matrices are in echelon The following matrices are in echelon form. 0

0

0 0 0 0

0 0 0

0 0 0 00 0 0 0 0 0 0 0 0

0 0 0 0 0 0 0 0

0

0 0

where

00 0

0 0 0

0

any real number

Page 11: Week4

And the following matrices are in reduced And the following matrices are in reduced echelon form.

1 0

0 1

0 1 0 0 0 0 0

0 0 0 1 0 0 00 1

0 0 0 0 0 0 0 0 1 0 0

0 0 0 0 0 1 0

1 0 0

0 1 0

0 0 0 0 0 0 0 0 1

0 1 0

0 0 1

0 0 00 0 0

Page 12: Week4

A is one that is in echelon A is one that is in echelon form.A is one that is in reduced echelon form.in reduced echelon form.

Page 13: Week4

Each matrix is row equivalent to one and only one reduced echelon matrix.and only one reduced echelon matrix.

Page 14: Week4

The rank of the matrix is the number of nonzero rows of its row echelon formnonzero rows of its row echelon form

Page 15: Week4

Example 4 .

1 21 3 1 322 6 0 0

R RA

2 6

) 1

0

(

0

Thus

r A ) 1(r A

1 21 3 1 322 5 0 1

R RB 2

1 3R 2 11 030 1

R R2 5 0 1

B 2

0 1 0 1

Thus,Thus,

r(B) = 2

Page 16: Week4

Step 1: Begin with the leftmost nonzero column say C . If a =0

and a 0

column say Cr . If a1r =0

and asr 0

interchange R1 by a row Rs.interchange R1 by a row Rs.Step 2: Use elementary row operations to create zeros in all positions below acreate zeros in all positions below a1r

-(asr /a1r) R1+Rs s= 2,3, ,msr 1r 1 s

Page 17: Week4

Step 3: go to the next leftmost nonzero column and repeat steps 1and 2

to the column and repeat steps 1and 2

to the remaining submatrix. Repeat the process remaining submatrix. Repeat the process until there are no more nonzero rows to modify.modify.

Page 18: Week4

Row reduce the matrix below to echelon Row reduce the matrix below to echelon form and find the rank of .

0 3 6 4 90 3 6 4 9

1 2 1 3 1

2 3 0 3 1A

2 3 0 3 1

1 4 5 9 7

Page 19: Week4

Step 1:R R1 4R R

1 4 5 9 71 4 5 9 7

1 2 1 3 11 2 1 3 1

2 3 0 3 1

0 3 6 4 90 3 6 4 9

Page 20: Week4

1 2R R1 2

2 R R

R R

1 32 R R

1 4 5 9 7

0 2 4 6 6

0 5 10 15 15

0 3 6 4 9

Page 21: Week4

5R R 235

2R R

3R R 243

2R R

1 4 5 9 7

0 2 4 6 60 2 4 6 6

0 0 0 0 0

0 0 0 5 0

Page 22: Week4

433

1 4 5 9 7

0 2 4 6 60 2 4 6 6

0 0 0 5 0

0 0 0 0 00 0 0 0 0

r(A) = 3r(A) = 3

Page 23: Week4

Row reduce the matrix below to echelon Row reduce the matrix below to echelon form and find the rank of .

0 3 6 6 4 50 3 6 6 4 5

3 7 8 5 8 9

3 9 12 9 6 15

Page 24: Week4

R R3 9 12 9 6 15

1 3R R3 9 12 9 6 15

3 7 8 5 8 9

0 3 6 6 4 50 3 6 6 4 5

1 23

R R 3 9 12 9 6 15

0 2 4 4 2 61 23

R R0 2 4 4 2 6

0 3 6 6 4 5

Page 25: Week4

3 9 12 9 6 153

3 9 12 9 6 15

0 2 4 4 2 6

0 0 0 0 1 432

3

2R R

0 0 0 0 1 42

Row Echelon FormRow Echelon Form

r(A) = 3r(A) = 3

Page 26: Week4
Page 27: Week4

Assume that A is an invertible matrix of Assume that A is an invertible matrix of order nStep 1: Construct the augmented matrixStep 1: Construct the augmented matrix

B = [ A In]B = [ A In]

Step 2: Reduce B to its (unique) reduced Step 2: Reduce B to its (unique) reduced echelon formThe resulting equivalent matrix isThe resulting equivalent matrix is

n-1

n

Page 28: Week4

Use the Gauss-Jordon elimination to find the inverse ofinverse of

2

Page 29: Week4

5 11

2 21 0

12R

12 2

1 0

1 3 0 1

5 12 2

1 01 2R R 2 2

1 12 2

1 0

0 - 12 2

0 - 1

Page 30: Week4

22 R5 12 2

1 0

22 R 2 21 1

0 - 2

2 1

5

2R R

0 3

1 1

1 -5

0 - 22 12R R

1 1

0 - 2

1 3 5

1 2A

1 2

Page 31: Week4

Use the Gauss-Jordon elimination to find the inverse ofinverse of

012

121

012

A

210

Page 32: Week4

001012

100

010

001

210

121

012

IA

100210

1 1

1

1 11 - 0 0 0

2 21 2 1 0 1 0

1

2

R 1

0 1 2 0 0 12

Page 33: Week4

1- 0 0 0

2

11

2

1 2

31 1

10

20 0

021 2 0 1

R R

0 01 2 0 1

1 11 - 0 0 0

2 2

2

2 1 21

3 3 3

1 - 0 0 02 2

0 02

3

R3 3 3

0 1 2 0 0 13

Page 34: Week4

1 2 11 00

1 2 11 0

3 3 32 1 2

0 01

0

1

R R2 1 0 03 3 3

0 1 2 0 0 12

1

R R

1 21 0

10

2 3

1 21 0

3 32 1

0 0

10

32

1

R R2 3 0 03 3

4 1

132

03

0 13 3

R R

33 3

Page 35: Week4

1 21 0

3 3

10

3

3

1 03 32 1

0 03 3

3

4

032

13

R 3 3 341 1 1

14 2

30 0

4 2

2 11 0

3 2

2 11 0

1 0 3 33

1 20 1 1

2 30

2

3

R R3 2 0 1 12 3

0 01 1

14

0

2

31

R R

4 2

Page 36: Week4

3

4

13

121 00 4

13 1

3

2

2

12 3

1

3

1 000 1

0 0 1

0R R

114

12

0 0 1

3 1 13

4

1

21

1

321 1

121 1

2

3

A

1 1

4 21

Page 37: Week4
Page 38: Week4

7

Solve

x x1 2

1 2

7

2 3 6

x x

x x1 22 3 6x x

Solution

1 23 4, x xSolution

Page 39: Week4

Solve

1 2 3 53 2 2 0x x x x

Solve

1 2 3 5

1 2 3 4 5 62 6 5 2 4 3 1

5 10 15 5

x x x x x x

x x x3 4 6

1 2 4 5 6

5 10 15 5

2 6 8 4 18 6

x x x

x x x x x1 2 4 5 6

SolutionSolution

1 2 3 4 5 6? ? ? ? ? ?, , , , , x x x x x x1 2 3 4 5 6? ? ? ? ? ?, , , , , x x x x x x

Page 40: Week4

1 2, , , nn x x x

A in variables is defined to

be in the form

linear equation

1 1 2 2 n na x a x a x b

be in the form

1 2, , , , .na a a b Rwhere

The variables in a linear equation are called the .unknowns

Page 41: Week4

Linear

N ot linear

Linear

N ot linear

3 7x y 23 7x y

1 2 3 42 3 7x x x x 3 2 4x z x z

12 3 1y x z sin 0y x

1 2 1nx x x1 2 32 1x x x

Page 42: Week4

, , ,x x xA finite set of linear equations in the variables is called1 2, , , nx x xA finite set of linear equations in the variables is called

a .system of linear equations

11 1 12 2 1 1n na x a x a x b

a x a x a x b

21 1 22 2 2 2n na x a x a x b

1 1 2 2m m mn n ma x a x a x b

1 2

1 1 2 2

, , ,

, , ,

A sequence of numbers is called a of the

system if is a solution of equation

in the system.

n

n n

s s s

x s x s x s

solution

every

in the system.

Page 43: Week4

Matrix form of a system of linear equations:equations:

11 1 12 2 1 1

21 1 22 2 2 2

n n

n n

a x a x a x b

a x a x a x b equationslinear

m21 1 22 2 2 2

1 1 2 2

n n

m m mn n ma x a x a x b

equationslinear

m

11 12 1 1 1na a a x bequationmatrix

Single

A x b

11 12 1 1 1

21 22 2 2 2

n

n

a a a x b

a a a x b

A x b

1m n n 1m

1 2m m mn n ma a a x b

A x b

Page 44: Week4

A system of equations that has no solution is said to be

inconsistent;inconsistent;inconsistent;inconsistent;if there is at least one solution of the system, it is said to be consistent.consistent.

4x y

The system consistent.consistent.

2 2 6x y

has no solutions since the equivalent system

4

3

x y

x y

has contradictory equations.has contradictory equations.

Page 45: Week4

Every system of linear equations has either Every system of linear equations has either solutions, exactly solution, or

solutions.solutions.

Page 46: Week4

If m < n, the system has more than one of solutions.solutions.

If m > n, the system can be reduced to equivalent system where m n, or it is equivalent system where m n, or it is inconsistant.

If m = n , the system has either no solution or one solution.or one solution.

Page 47: Week4

Solution possibilities for two lines Consider the solutions to the general system of two linear equations

( , )

Consider the solutions to the general system of two linear equations

in the two unknowns and :

not both zero

x y

a x b y c a b1 1 1 1 1

2 2 2 2 2

( , )

( ,

not both zero

not

a x b y c a b

a x b y c a b )both zero

1 2The graphs of these equations are lines; call them and .l l

Then the solutions of the system correspond to the intersections

of the lines.

Page 48: Week4

We will study the solution of linear systems under the following assumptions:the following assumptions:m = n (#of equations = # of unknowns)m = n (#of equations = # of unknowns)b is a nonb is a non--zero matrixzero matrixb is a nonb is a non--zero matrixzero matrixThe system is consistent .The system is consistent .

Under these assumptions the system has Under these assumptions the system has either no solution or one solution.either no solution or one solution.either no solution or one solution.either no solution or one solution.

Page 49: Week4

For the linear system AX=b , if A is invertible then the system is consistent and it has one solutionand it has one solutionX = A-1 bX = A b

Page 50: Week4

Solving a systemSolving a system

11--GAUSS ELIMINATIONGAUSS ELIMINATION

Reduce the augmented matrix to the Reduce the augmented matrix to the echelon echelon form and use form and use back substitutionback substitution..form and use form and use back substitutionback substitution..

22--GAUSSGAUSS--JORDON ELIMINATIONJORDON ELIMINATIONReduce the augmented matrix to the Reduce the augmented matrix to the reducedreducedReduce the augmented matrix to the Reduce the augmented matrix to the reducedreduced

[A [A b] b] [I[Inn X]X]

Page 51: Week4

To find the solution and the inverse of the matrix at the same time reduce the the matrix at the same time reduce the matrixmatrix[A In b] to the reduced echelon formto get [I A-1 X]to get [I A-1 X]

nn--11

nn--11

Page 52: Week4

2 9

2 4 3 1

x y z

x y z2 4 3 1

3 6 5 0

x y z

x y z

1 1 2 9 1 1 2 912 2

1 1 2 9 1 1 2 9

2 4 3 1 0 2

3 6 5 0 3 6 0

7 1 7

5

R R

3 6 5 0 3 6 05

Page 53: Week4

1 3 23 0.51 2 9 1 1 2 9

2 7

17

1

0 0 1 3.5 8.5R R R

2 7

17

3 11 27 0 3 11 27

0

0

0 1 3.5 8.5

2 331 2 9

1

0 1 3.5

8.5R R

0 1 3.5

8.5

0 0.5 1.50

321 2 91

R32

0 3.5 8.5

00 1 3

1R

00 1 3

Page 54: Week4

You may stop at this step and use back substitution.substitution.z=3z=3

y-3.5 z=-8.5 y=-8.5+10.5=2

x+y+2z=9 x=9-2-6=1

Page 55: Week4

Or we may continue to find the reduced echelon form and the solutionechelon form and the solution

Page 56: Week4

3 22 1 3.51 0 5.5 17.5 1 0 5.5 17.5

0 1 3.5

8.5

0 1 0

2R RR R

0 1 3.5

8.5

0 1 0

2

0 0 1 3 0 0 1 3

1 1 0 13 15.5

1 1 0 1

0 1 0 2

0 0 1 3

R R

0 0 1 3

Page 57: Week4

x y z2 4 12x y z

x y z

x y z

2 4 12

2 5 18

3 3 8x y z3 3 8

1851212421

41106330

12421

2)R1(R28331

18512 4110R1R3

2)R1(R2

211012421 1 2 4 1 2

0 1 1 2

R23

141102110 0 1 1 2

0 0 2 6R3 ( )R21

1 2 4 12

0 1 1 2

0 0 1 3R3

1

x y z

y z

2 4 12

2 solution .

x

y

z

2

1

30 0 1 3R3

2 z 3 z 3

Page 58: Week4

x y z4 8 12 44

Solve the system

x y z

x y z

x y

4 8 12 44

3 6 8 32

2 7

x y2 7

32863

441284

32863

11321

1100

11321

R12R3

3)R1(R2R1

17012 7012 15630

11321

R12R3

11321

R14

1100

5210R2

3

1R3R21100

15630

The solution is , , .x y z2 3 1The solution is , , .x y z2 3 1

Page 59: Week4

9333 xxx

Solve, if possible, the system of equations7537429333

321

321

321

xxxxxxxxx

753 321 xxx

715374123111

715374129333

R131

242012103111

3)R1(R3

2)R1(R2

71537153 3 24203)R1(R3

R 3 R 22

1 1 1 3

0 1 2 1x x x x x x1 2 3 1 2 34 4

R 3 R 22 0 1 2 1

0 0 0 0 x x x x1 2 3 1 2 3

2 3 2 32 1 2 1

The general solution to the system isThe general solution to the system is

12

43

2

1

rx

rx

.parameter) a (callednumber real is where, 3

2

rrx

Page 60: Week4

Example 6

2 x1 + x2 + x3 =71 2 3

3 x1 +2 x2 +x3 =-3x + x =5x2 + x3 =5

Page 61: Week4

2 1 1 7 1 0 .5 0 .5 3 .5

1

2 1 1 7 1 0 .5 0 .5 3 .51

3 2 1 -3 3 2 1 -32

0 1 1 5 0 1 1 5

R

0 1 1 5 0 1 1 5

0 .5 0 .5 3 .51

1 2

0 .5 0 .5 3 .5

3 0 .5 -0 .5 -1 3 .5

1

0R R

1 1 50

Page 62: Week4

1

0

0 . 5 0 . 5 3 . 5

2 1 - 1

- 2 7R 2 0

0

2 1 - 1

- 2 7

1 1 5

R

1 0

0

1 1 7

0 . 5 1 - 1

- 2 7R R2 1 0

0

0 . 5 1 - 1

- 2 7

1 1 5

R R

1 1 7

1 - 1

-

1 0

2 70R R2 3 1 - 1

- 2 70

20 3 20

R R

Page 63: Week4

1 1 71 0

3

1 1 7

0 .5 1 -1 - 2 7

1 0

0R 3

1 1 60 0

3 1 6x

2 3 22 7 2 7 1 6 1 1x x x2 3 22 7 2 7 1 6 1 1

1 7 1 7 1 6 1

x x x

x x x1 3 11 7 1 7 1 6 1x x x

Page 64: Week4
Page 65: Week4
Page 66: Week4

6

77

Page 67: Week4
Page 68: Week4
Page 69: Week4
Page 70: Week4
Page 71: Week4

1212-- SOLVE THE FOLLOWING SYSTEMS OF LINEAR SOLVE THE FOLLOWING SYSTEMS OF LINEAR EQUATIONSEQUATIONSEQUATIONSEQUATIONS

Page 72: Week4

1313-- SOLVE THE FOLLOWING SYSTEMS OF SOLVE THE FOLLOWING SYSTEMS OF 1313-- SOLVE THE FOLLOWING SYSTEMS OF SOLVE THE FOLLOWING SYSTEMS OF LINEAR EQUATIONSLINEAR EQUATIONS

Page 73: Week4