Upload
aileen-payne
View
217
Download
0
Tags:
Embed Size (px)
Citation preview
Pre-CalculusLesson 7-3
Solving Systems of Equations Using Gaussian Elimination
What you’ll learn about
• Triangular Forms for Linear Systems• Gaussian Elimination• Elementary Row Operations and Row Echelon Form• Reduced Row Echelon Form• Applications
… and whyMany applications in business and science are modeled by systems of linear equations in three or more variables.
What is a Dimension?
Flat: (x, y coordinate plane) 2 Dimensions x
y
x
y
zSolid: (x, y, z coordinate space) 3 Dimensions
Flat: (x, y coordinate plane) 2 Dimensions
x
y
(3, 0)(3, 0)
(0, 2)(0, 2)
1. Draw the 3 dimensional coordinate Plane below on your paper.
x
zSolid: (x, y, z coordinate space) 3 Dimensions
y
(0, 3, 0)(0, 3, 0)
(2, 0, 0)(2, 0, 0)
2. Plot the following 3 points on your graph.
(0, 0, -2)(0, 0, -2)3. Connect the dots
4. What geometric “thing” do three dots make?Plane: a simple 3-dimensional shape.
What shape does an Equation Make?
Ax + By = D
Ax + By + Cz = DAx + By + Cz = D
3x + 2y = 6 3x + 2y = 6 line (in “2” space)line (in “2” space)
plane (in “3” space)plane (in “3” space)
2x + 3y + 4z = 62x + 3y + 4z = 6
Categories of solutions in “3 space”
Exactly one point, an “ordered triple”
(x, y, z)
Along a Line: INFINITELY many solutions
(x, y, z) triples
Categories of solutions in “3 space”
Categories of solutions in “3 space”
2 parallel planes intersected by a 3rd plane
no common solution for all 3 planes
Categories of solutions in “3 space”
3 parallel planes No intersection No solution
Categories of solutions in “3 space”
Another possibility: Another possibility: No planes are parallelNo planes are parallel
NO POINT SATISFIES ALL 3 EQUATIONSNO POINT SATISFIES ALL 3 EQUATIONS
No solutionNo solution
(too hard to draw)(too hard to draw)
Categories of solutions in “3 space”
1. One ordered triple (x, y, z) one solution
3. Infinitely many ordered triples
2. No solution
Categories of Solutions in “2-space”
Ways 2 lines can be graphed:Ways 2 lines can be graphed:
Cross Cross one solution one solution
Parallel Parallel no solutionsno solutions
Same line Same line infinite infinite number of number of solutionssolutions
Solving Systems of Linear Equations
(30 April 1777 – (30 April 1777 – 23 February 1855)23 February 1855)
Charles Fredrick GaussCharles Fredrick Gauss
Gaussian EliminationGaussian Elimination
Re-writing a system of equations as a “matrix”.
11x + x + 44y = y = 22
22x + x + 55y = y = 77
1 4 21 4 2
2 5 72 5 7
Where does a “matrix” come from?
22x – x – 33yy
77x + x + 22yy
ExpressionsExpressionsNot equations since no equal sign
22x – x – 33y = y = 88
77x + x + 22y = y = 22
EquationsEquationsAre equations since there is an equal sign
Where does a “matrix” come from?
22x – x – 33yy
77x + x + 22yy
2 –32 –3
7 27 2
Matrix of Matrix of coefficientscoefficients
22x – x – 33y = y = 88
77x + x + 22y = y = 22
2 –3 82 –3 8
7 2 27 2 2
Big PictureWe will perform “row operations” to turn the left side matrix into the matrix on the right side.
3 5 33 5 3
-1 2 10-1 2 10
1 0 -41 0 -4
0 1 30 1 3
x + x + 00y = y = -4-4
00x + x + 11y = y = 3333x + x + 55y = y = 33
--x + x + 22y = y = 1010 x = x = -4-4
yy = = 33
We call this We call this reduced row eschelon form.reduced row eschelon form.
1 0 -41 0 -4
0 1 30 1 3
1’s on the main diagonal1’s on the main diagonal
0’s above/below the main diagonal0’s above/below the main diagonal
How do I do that?How do I do that?
Similar to eliminationSimilar to elimination, we add multiples of , we add multiples of one row to another row.one row to another row.
BUT, unlike eliminationBUT, unlike elimination, we only change , we only change one row at a time and we end up with the one row at a time and we end up with the same number of rows that we started same number of rows that we started with.with.
Some important principles about systems of equations.
Are the graphs of these two systems different from each other?
124
663
yx
yx
663
124
yx
yx
Principle 1: you can exchange rows of a matrix.
Some important principles about systems of equations.
Are the graphs of these two systems different from each other?
124
663
yx
yx
Principle 2: you multiply (or divide) any row by a number and it won’t change the graph (or the matrix)
124
22
yx
yx
11stst step step: we want a : we want a zerozero in the bottom left corner. in the bottom left corner.
ButBut, you will see later that this , you will see later that this will be easier if the top left will be easier if the top left number is a one or a negative number is a one or a negative one.one.
3 5 3
-1 2 10Swap rows.Swap rows.
-1 2 10
3 5 3
-1 2 10
3 5 3
11stst step step: we still want a : we still want a zerozero in the bottom left corner. in the bottom left corner.
Forget about all the numbers Forget about all the numbers but the 1but the 1stst column (for a column (for a minute).minute).
-1 2 10
3 5 3
11stst step step: we still want a : we still want a zerozero in the bottom left corner. in the bottom left corner.
Forget about all the numbers Forget about all the numbers but the 1but the 1stst column (for a column (for a minute).minute).
What multiple of the 1What multiple of the 1stst row row should we add or subtract from should we add or subtract from row 2 to turn the 3 into a row 2 to turn the 3 into a zerozero??
0)1(33
# in # in 22ndnd row row
# in # in 11stst row row
This gives us the This gives us the patternpattern of of what to do to what to do to eacheach other other number in row 2.number in row 2.
12 *3 RR
3 5 3
3 5 3
-1 2 10
3 5 3
11stst step step: we still want a : we still want a zerozero in the bottom left corner. in the bottom left corner.
New Row 2New Row 2
12 *3 RR + 3(-1 2 10)
+3(-1)
0
+3(2)
11
+3(10)
33
3 5 3
3 5 3
-1 2 10
3 5 3
11stst step step: we still want a : we still want a zerozero in the bottom left corner. in the bottom left corner.
New Row 2New Row 2
12 *3 RR + 3(-1 2 10)
+3(-1)
0
+3(2)
11
+3(10)
33
-1 2 10
0 11 33
22ndnd step step: we want a : we want a oneone in 2 in 2ndnd position of the 2 position of the 2ndnd row. row.
New Row 2New Row 2
112 R
0
11
11 33-1 2 10
0 11 33 11 11
0 1 3
New Row 2New Row 2
112 R
0
11
11 33-1 2 10
0 11 33 11 11
0 1 3-1 2 10
0 1 3
22ndnd step step: we want a : we want a oneone in 2 in 2ndnd position of the 2 position of the 2ndnd row. row.
-1 2 10
0 1 3
33rdrd step step: we want a : we want a zerozero in 2 in 2ndnd position of the 1 position of the 1stst row. row.
Forget about all the numbers Forget about all the numbers but the 2but the 2ndnd column (for a column (for a minute).minute).
-1 2 10
0 1 3
33rdrd step step: we want a : we want a zerozero in 2 in 2ndnd position of the 1 position of the 1stst row. row.
0)1(22
# in # in 11stst row row
# in # in 22ndnd row row
Forget about all the numbers Forget about all the numbers but the 2but the 2ndnd column (for a column (for a minute).minute).What multiple of the 2What multiple of the 2ndnd row row should we add or subtract from should we add or subtract from the 1the 1stst row to turn the 2 into a row to turn the 2 into a zerozero??
This gives us the This gives us the patternpattern of of what to do to what to do to eacheach other other number in row 1.number in row 1.
21 *2 RR
-1 2 10
-1 2 10
-1 2 10
0 1 3
New Row 1New Row 1
21 *2 RR -2(0 1 3)
-2(0)
-1
-2(1)
0
-2(3)
4
33rdrd step step: we want a : we want a zerozero in 2 in 2ndnd position of the 1 position of the 1stst row. row.
-1 2 10
-1 2 10
-1 2 10
0 1 3
New Row 1New Row 1
21 *2 RR -2(0 1 3)
-2(0)
-1
-2(1)
0
-2(3)
4
-1 0 4
0 1 3
33rdrd step step: we want a : we want a zerozero in 2 in 2ndnd position of the 1 position of the 1stst row. row.
44thth step step: we want a : we want a oneone in the top left corner. in the top left corner.
-1 0 4
0 1 3
New Row 2New Row 2
1*)1( R1 0 -4
-1 0 4
0 1 3
44thth step step: we want a : we want a oneone in the top left corner. in the top left corner.
1 0 -4
0 1 3
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 11 33
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 11 33
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 1 3
-1 2 10
0 11 33
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 1 3
-1 2 10
0 1 3
-1 2 10
0 11 33
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 1 3
-1 2 10
0 1 3
-1 0 4
0 1 3
-1 0 4
0 1 3
-1 2 10
0 11 33
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 1 3
-1 2 10
0 1 3
-1 0 4
0 1 3
-1 0 4
0 1 3
-1 2 10
0 11 33
Look at the circular Look at the circular patternpattern
Don’t freak outDon’t freak out: this goes faster than you think. : this goes faster than you think.
1 0 -4
0 1 3
-1 2 10
3 5 3
-1 2 10
0 11 33
-1 2 10
0 1 3
-1 2 10
0 1 3
-1 0 4
0 1 3
Systems of linear equations in Three Variables
2x + y – z = 53x – 2y + z = 164x + 3y – 5z = 3
Row Echelon Form of a MatrixA matrix is in row echelon form if the following conditions are satisfied.1. Rows consisting entirely of 0’s (if there are any)
occur at the bottom of the matrix.2. The first entry in any row with nonzero entries is
1.3. The column subscript of the leading 1 entries
increases as the row subscript increases. (this means the ones lie on a diagonal)
Row Echelon Form of a Matrix
11 -3 2 -3 -3 2 -3 0 1 7 20 1 7 20 0 1 5 0 0 1 5 z = 5z = 5
y + 7z = 2y + 7z = 2
(1) plug z = 5 into 2(1) plug z = 5 into 2ndnd equation and solve for ‘y’ equation and solve for ‘y’
x – 3y + 2z = -3x – 3y + 2z = -3
(2) plug z = 5 and the value of ‘y’ found in step 1 into 1(2) plug z = 5 and the value of ‘y’ found in step 1 into 1stst
equation and solve for ‘x’equation and solve for ‘x’
Reduced ow Echelon Form of a Matrix
11 0 0 -20 0 -20 1 0 40 1 0 40 0 1 -50 0 1 -5
We are going to perform “row operations”We are going to perform “row operations” on a matrix to change it into this form.on a matrix to change it into this form.
z = -5z = -5y = 4y = 4
x = -2x = -2
Finding the Row Echelon Form x – y + 2z = -3x – y + 2z = -32x + y – z = 02x + y – z = 0 -x + 2y – 3z = 7-x + 2y – 3z = 7
1.1. Convert to “Augmented”Convert to “Augmented” matrix form.matrix form.
1 -1 2 -31 -1 2 -3 2 1 -1 02 1 -1 0-1 2 -3 7-1 2 -3 7
2.2. The right most column are The right most column are the numbers on the right the numbers on the right side of the equal sign.side of the equal sign.
The dotted line is not The dotted line is not usually drawn in textbooks,usually drawn in textbooks, but I like to draw it, to showbut I like to draw it, to show where the equal sign is.where the equal sign is.
Row Operations -- the “big picture”We are going to rewrite the matrix numerous times. Each rewriteWe are going to rewrite the matrix numerous times. Each rewrite will change one row only. Our objective is to eliminate the will change one row only. Our objective is to eliminate the x-variables below the 1x-variables below the 1stst row like this. row like this.
1 -1 2 -31 -1 2 -3 2 1 -1 02 1 -1 0-1 2 -3 7-1 2 -3 7
1 -1 2 -31 -1 2 -3 00 3 -5 6 3 -5 6 00 2 -3 7 2 -3 7
1 5 1 5 00 -2 -2 00 3 3 00 3 3 00 00 -3 7 -3 7
1 -1 2 -31 -1 2 -3 00 3 -5 6 3 -5 6 00 00 -3 7 -3 7
Next: eliminate the y-variables below the 2Next: eliminate the y-variables below the 2ndnd row like this. row like this.
Next: eliminate the Z-variables above the 3Next: eliminate the Z-variables above the 3rdrd row like this. row like this.
1 1 00 00 -3 -3 00 3 3 00 6 6 00 00 -3 9 -3 9
Next: eliminate the y-variables above the 2Next: eliminate the y-variables above the 2ndnd row like this. row like this.
Row OperationsThen: turn the major diagonal into 1’s.Then: turn the major diagonal into 1’s.
1 1 00 00 -3 -3 00 1 1 00 2 2 00 00 1 -3 1 -3
This final matrix represents the following system of equations:This final matrix represents the following system of equations:
1 1 00 00 -3 -3 00 3 3 00 6 6 00 00 -3 9 -3 9
1x + 1x + 0y0y + + 0z0z = -3 = -3 0x0x + 1y + + 1y + 0z0z = 2 = 2 0x0x + + 0y0y + 1z = -3 + 1z = -3
x = -3x = -3 y = 2y = 2 z = -3z = -3
The The solutionsolution to the to the system of equations:system of equations:
Solve the following system using Row Operations
1 -1 2 -31 -1 2 -3 2 1 -1 02 1 -1 0-1 2 -3 7-1 2 -3 7
x - y + 2z = -3x - y + 2z = -3 2x + y - z = 02x + y - z = 0
-x + 2y - 3z = 7-x + 2y - 3z = 7
Convert to a matrixConvert to a matrix
Row Operations
The new Row #2 = (-2)Row #1 + Old Row #2The new Row #2 = (-2)Row #1 + Old Row #2
1 -1 2 -31 -1 2 -3 2 1 -1 02 1 -1 0-1 2 -3 7-1 2 -3 7
1 -1 2 -31 -1 2 -3 0 3 -5 60 3 -5 6-1 2 -3 7-1 2 -3 7
212 )2( oldnew RRR
A small explanation A small explanation below the newbelow the new matrix will help matrix will help to avoid confusion.to avoid confusion.
2 1 -1 02 1 -1 0(-2)(1 -1 2) (-3)(-2)(-2)(1 -1 2) (-3)(-2)++
0 3 -5 60 3 -5 6
(1) Eliminate the x-variable on the second row.(1) Eliminate the x-variable on the second row.
Row Operations(2) Eliminate the x-variable in the 3(2) Eliminate the x-variable in the 3rdrd row. row.
313 oldnew RRR
1 -1 2 -31 -1 2 -3 00 3 -5 6 3 -5 6-1 2 -3 7-1 2 -3 7
The new Row #3 = Row #1 + Old Row #3The new Row #3 = Row #1 + Old Row #3
1 -1 2 -31 -1 2 -3 00 3 -5 6 3 -5 6 0 1 -1 40 1 -1 4
1 -1 2 -31 -1 2 -3
++-1 2 -3 7-1 2 -3 7
0 1 -1 40 1 -1 4
Row Operations
313 oldnew RRR
1 -1 2 -31 -1 2 -3 00 3 -5 6 3 -5 6 00 1 -1 4 1 -1 4
1 -1 2 -31 -1 2 -3 00 1 -1 4 1 -1 4
(3) Eliminate the y-variable on the third row.(3) Eliminate the y-variable on the third row.
Can Can onlyonly use 2 use 2ndnd row (or you will introduce a number row (or you will introduce a number other than “0” in the x-position of the 3other than “0” in the x-position of the 3rdrd row)!!! row)!!!
For example: New row 3 = row 1 + old row 3For example: New row 3 = row 1 + old row 3
1 -1 2 -31 -1 2 -30 1 -1 40 1 -1 4++
11 0 1 1 0 1 1
11 0 1 1 0 1 1
Can Can onlyonly use rows 2 use rows 2 and 3 at this point!!!and 3 at this point!!!
Row Operations
2 32 0 0
1 -1 2 -31 -1 2 -3 0 3 -5 60 3 -5 6 0 1 -1 40 1 -1 4
1 -1 2 -31 -1 2 -3 0 1 -1 40 1 -1 4 0 3 -5 60 3 -5 6
323 )31( oldnew RRR
(3) Eliminate the y-variable on the third row.(3) Eliminate the y-variable on the third row.
Yuck: fractions!!Yuck: fractions!!
0 1 -1 40 1 -1 4((-1/3-1/3)(0 3 -5) (6)(-1/3))(0 3 -5) (6)(-1/3)
++
Wouldn’t it be nice if the 2Wouldn’t it be nice if the 2ndnd and 3 and 3rdrd rows where switched? Then we rows where switched? Then we could just multiply row two by -3 and then add to row 3.could just multiply row two by -3 and then add to row 3.
23 oldnew RR
32 oldnew RR 23R
Let’s do it!!!Let’s do it!!!
Short way of Short way of saying thissaying this
Row Operations
1 -1 2 -31 -1 2 -3 00 3 -5 6 3 -5 6 00 1 -1 4 1 -1 4
1 -1 2 -31 -1 2 -3 00 1 -1 4 1 -1 4 00 3 -5 6 3 -5 6
323 3 oldnew RRR
(3) Eliminate the y-variable on the 3(3) Eliminate the y-variable on the 3rdrd row. row.
0 3 -5 60 3 -5 6 (-3)(0 1 -1) (4)(-3)(-3)(0 1 -1) (4)(-3)
++
0 0 -2 -60 0 -2 -6
1 -1 2 -31 -1 2 -3 00 1 -1 4 1 -1 4 0 0 -2 -60 0 -2 -6
23R
Row Operations
232 21
oldnew RRR
(4) Eliminate the z-variable on the 2(4) Eliminate the z-variable on the 2ndnd row. row.
0 1 -1 40 1 -1 4 (-0.5)(0 0 -2) (-6)(-0.5)(-0.5)(0 0 -2) (-6)(-0.5)++
0 1 0 70 1 0 7
1 -1 2 -31 -1 2 -3 00 1 -1 4 1 -1 4 00 00 -2 -6-2 -6
Can Can onlyonly use 3 use 3rdrd row (or you will introduce a number row (or you will introduce a number other than “0” in the x-position of the 2other than “0” in the x-position of the 2ndnd row)!!! row)!!!
1 -1 2 -31 -1 2 -3 0 1 0 70 1 0 7 00 00 -2 -6-2 -6
Row Operations
131 oldnew RRR
(5) Eliminate the z-variable on the 1st row.(5) Eliminate the z-variable on the 1st row.
1 -1 2 -31 -1 2 -30 0 -2 -60 0 -2 -6
++
1 -1 0 -91 -1 0 -9
1 -1 2 -31 -1 2 -3 00 11 00 77 00 00 -2 -6-2 -6
1 -1 0 -91 -1 0 -9 00 11 00 77 00 00 -2 -6-2 -6
Row Operations
121 oldnew RRR
(6) Eliminate the y-variable on the 1st row.(6) Eliminate the y-variable on the 1st row.
0 1 0 70 1 0 7 1 -1 0 -91 -1 0 -9
++
1 0 0 -21 0 0 -2
1 -11 -1 00 -9-9 00 11 00 77 00 00 -2 -6-2 -6
Can Can onlyonly use 2 use 2ndnd row (or you will introduce a number row (or you will introduce a number other than “0” in the z-position of the 1other than “0” in the z-position of the 1stst row)!!! row)!!!
1 0 0 -21 0 0 -2 00 11 00 77 00 00 -2 -6-2 -6
Row Operations
33 21
oldnew RR
(7) Get all “1’s” on the main diagonal.(7) Get all “1’s” on the main diagonal.
1 1 0 00 0 -2 -2 00 11 00 77 00 00 -2 -6-2 -6
1 1 0 0 0 0 -2-2 00 11 00 77 00 00 1 31 3
1x + 1x + 0y0y + + 0z0z = -2 = -2 0x0x + 1y + + 1y + 0z0z = 7 = 7 0x0x + + 0y0y + 1z = -3 + 1z = -3
x = -2x = -2 y = 7y = 7 z = 3z = 3
The The solutionsolution to the to the system of equations:system of equations:
Classes of Solutions for 3 Equations with 3 unknowns
Gaussian Elimination results in:- a unique solution (the planes intersect at a point)- something silly like: 3 = 3 (Infinitely many solutions)- Again something silly like: 5 = -9 (there are no solutions)
Your turn:
x - y + z = 02x – 3z = -1-x - y + 2z = -1
1. Solve using Gaussian Elimination 1. Solve using Gaussian Elimination
HOMEWORKHOMEWORK
7-37-3