EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the...

12

Transcript of EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the...

Page 1: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need
Page 2: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Solve the system of linear equations using Gaussian elimination.

4x+ 8y − 4z = 4

3x+ 8y + 5z = −11

−2x+ y + 12z = −17

Solution: We first write the augmented matrix of the system, and then use elementary row operations toput it in row-echelon form.

We now have an equivalent matrix in row-echelon form, and the corresponding system of equations is

x+ 2y − z = 1

y + 4z = −7

z = −2

We use back-substitution to solve the system.

So the solution of the system is (−3, 1,−2).

2

Page 3: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

Gauss-Jordan Elimination

If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need toback-substitute to solve the system. To put a matrix in reduced row-echelon form, we use the followingsteps.

• Use the elementary row operations to put the matrix in row-echelon form.• Obtain zeros above each leading entry by adding multiples of the row containing that entry to therows above it. Begin with the last leading entry and work up.

The following matrices are in reduced row-echelon form.

Using the reduced row-echelon form to solve a system is called Gauss-Jordan elimination. We illustratethis process in the next example.

EXAMPLE: Solve the system of linear equations, using Gauss-Jordan elimination.

4x+ 8y − 4z = 4

3x+ 8y + 5z = −11

−2x+ y + 12z = −17

Solution: In the previous Example we used Gaussian elimination on the augmented matrix of this systemto arrive at an equivalent matrix in row-echelon form. We continue using elementary row operations onthe last matrix in that Example to arrive at an equivalent matrix in reduced row-echelon form.

We now have an equivalent matrix in reduced row-echelon form, and the corresponding system of equations

is

x = −3

y = 1

z = −2

. Hence we immediately arrive at the solution (−3, 1,−2).

3

Page 4: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

Inconsistent and Dependent Systems

The matrices below, all in row-echelon form, illustrate the three cases described in the box.

EXAMPLE: Solve the system.

x− 3y + 2z = 12

2x− 5y + 5z = 14

x− 2y + 3z = 20

Solution: We transform the system into row-echelon form.

This last matrix is in row-echelon form, so we can stop the Gaussian elimination process. Now if wetranslate the last row back into equation form, we get 0x + 0y + 0z = 1, or 0 = 1, which is false. Nomatter what values we pick for x, y, and z, the last equation will never be a true statement. This meansthe system has no solution.

4

Page 5: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Find the complete solution of the system.

−3x− 5y + 36z = 10

−x+ 7z = 5

x+ y − 10z = −4

Solution: We transform the system into reduced row-echelon form.

The third row corresponds to the equation 0 = 0. This equation is always true, no matter what valuesare used for x, y, and z. Since the equation adds no new information about the variables, we can drop itfrom the system. So the last matrix corresponds to the system

Now we solve for the leading variables x and y in terms of the non-leading variable z:

To obtain the complete solution, we let t represent any real number, and we express x, y, and z in termsof t:

x = 7t− 5

y = 3t+ 1

z = t

We can also write the solution as the ordered triple (7t− 5, 3t+ 1, t), where t is any real number.

EXAMPLE: Find the complete solution of the system.

x+ 2y − 3z − 4w = 10

x+ 3y − 3z − 4w = 15

2x+ 2y − 6z − 8w = 10

5

Page 6: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Find the complete solution of the system.

x+ 2y − 3z − 4w = 10

x+ 3y − 3z − 4w = 15

2x+ 2y − 6z − 8w = 10

Solution: We transform the system into reduced row-echelon form.

This is in reduced row-echelon form. Since the last row represents the equation 0 = 0, we may discard it.So the last matrix corresponds to the system

To obtain the complete solution, we solve for the leading variables x and y in terms of the non-leadingvariables z and w, and we let z and w be any real numbers. Thus, the complete solution is

x = 3s+ 4t

y = 5

z = s

w = t

where s and t are any real numbers. We can also express the answer as the ordered quadruple (3s+4t, 5, s, t).

6

Page 7: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

Appendix

EXAMPLE: Solve the system of linear equations.

Solution: To put this in triangular form, we begin by eliminating the x-terms from the second equationand the third equation.

Now we eliminate the y-term from the third equation.

The new third equation is true, but it gives us no new information, so we can drop it from the system.Only two equations are left. We can use them to solve for x and y in terms of z, but z can take on anyvalue, so there are infinitely many solutions.

To find the complete solution of the system we begin by solving for y in terms of z, using the new secondequation.

Then we solve for x in terms of z, using the first equation.

To describe the complete solution, we let t represent any real number. The solution is

x = −3t

y = 2t+ 2

z = t

We can also write this as the ordered triple (−3t, 2t+ 2, t).

7

Page 8: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Solve the system.{

3x1 + 4x2 = 1

x1 − 2x2 = 7

Solution: We start by writing the augmented matrix corresponding to system:[

3 4 1

1 –2 7

]

To get a 1 in the upper left corner, we interchange R1 and R2:

To get a 0 in the lower left corner, we multiply R1 by −3 and add to R2 — this changes R2 but not R1.Some people find it useful to write (−3R1 outside the matrix to help reduce errors in arithmetic, as shown:

To get a 1 in the second row, second column, we multiply R2 by1

10:

To get a 0 in the first row, second column, we multiply R2 by 2 and add the result to R1 — this changesR1 but not R2:

We have accomplished our objective. The last matrix is the augmented matrix for the system{

x1 = 3

x2 = 5

The preceding process may be written more compactly as follows:

8

Page 9: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Solve by Gauss-Jordan elimination:

2x1 − 2x2 + x3 = 3

3x1 + x2 − x3 = 7

x1 − 3x2 + 2x3 = 0

Solution: Write the augmented matrix and follow the steps indicated at the right.

The solution to this system is x1 = 2, x2 = 0, x3 = −1.

9

Page 10: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Solve the system.{

2x1 + 6x2 = −3

x1 + 3x2 = 2

Solution:

This is the augmented matrix of the system{

x1 + 3x2 = 2

0 = −7

The second equation is not satisfied by any ordered pair of real numbers. Therefore the original system isinconsistent and has no solution.

EXAMPLE: Solve by Gauss-Jordan elimination:

2x1 − 4x2 + x3 = −4

4x1 − 8x2 + 7x3 = 2

−2x1 + 4x2 − 3x3 = 5

Solution:

The system has no solution.

10

Page 11: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Solve by Gauss-Jordan elimination:

3x1 + 6x2 − 9x3 = 15

2x1 + 4x2 − 6x3 = 10

−2x1 − 3x2 + 4x3 = −6

Solution:

Note that the leftmost variable in each equation appears in one and only one equation. We solve for theleftmost variables x1 and x2 in terms of the remaining variable, x3:

{

x1 = −x3 − 3

x2 = 2x3 + 4

If we let x3 = t, then for any real number t,

x1 = −t− 3

x2 = 2t+ 4

x+ 3 = t

One can check that (−t− 3, 2t+ 4, t) is a solution of the original system for any real number t.

11

Page 12: EXAMPLE: Solve the system of linear equations using ... · Gauss-JordanElimination If we put the augmented matrix of a linear system in reduced row-echelon form, then we don’t need

EXAMPLE: Find the complete solution of the system.

y + z − 2w = −3

x+ 2y − z = 2

2x+ 4y + z − 3w = −2

x− 4y − 7z − w = −19

Solution:

The matrix is now in row-echelon form, and the corresponding system is

x+ 2y − z = 2

y + z − 2w = −3

z − w = −2

w = 3

Using back-substitution, you can determine that the solution is x = −1, y = 2, z = 1, and w = 3.

12