Systems of Linear Equations

Systems of Linear Equations Recall that an equation of the form Ax + By = C is a linear equation in two variables. A solution of a linear equation in ...
0 downloads 3 Views 87KB Size
Systems of Linear Equations Recall that an equation of the form Ax + By = C is a linear equation in two variables. A solution of a linear equation in two variables is an ordered pair (x, y) that makes the equation a true statement. For example, (-2, 3) is a solution of the equation 2x + 3y = 5. A system of equations is two or more equations considered together. The following system of equations is a linear system of equations in two variables. 2 x + 3 y = 4  3 x − 2 y = −7 A solution of a system of equations in two variables is an ordered pair that is a solution of both equations. If you graph the above equations you will see the two lines intersect at point (-1, 2). Because this point lies on both lines, we say this is a solution of both equations and is a solution of the system of equations. You should become familiar with the basic terms used in discussing systems of linear equations: consistent, independent, and dependent. There are several methods that can be used to solve a system of linear equations. One is to graph the equations. If you have a graphing utility that allows you to graph more than one equation at the same time, this may be an option for you. However, not all intersections will be such that you can easily “read” the solution set in a graph. We need an alternative method for solving systems of equations. Fortunately, there are two additional methods for solving systems of equations. The first method we will examine is called elimination by addition. The idea is to eliminate one of the variables in the system of equation by adding (or subtracting) one equation from the other, then solving the resultant equation in a single variable. We will use the principals learned earlier in our studies. Let’s look at an example. Example 1: Solve the system of equations: 3 x + 5 y = 9  2 x − 3 y = −13 The basic idea is to manipulate the two equations (by multiplying one or both) so that one of the variables is eliminated. Looking at this system, a good candidate for elimination is the y-variable since the signs of the y-terms is positive in one equation and negative in the other. What integer do we need to multiply each equation by so that the sum of the coefficients of the y-terms will be zero? We will multiply the first equation by 3 and the second equation by 5. When I say multiply an equation, I’m implying that each term in the equation will be multiplied.

3(3 x + 5 y = 9 ) ≡ 9 x + 15 y = 27

5(2 x − 3 y = −13) ≡ 10 x − 15 y = −65

Now we will add the two equations together and solve the resulting equation in one variable. 9 x + 15 y = 27 10 x − 15 y = −65 19 x = −38 19 x − 38 = 19 19 x = −2 We now have a value for x. We will substitute this value into either of the original equations to solve for y. I’ll substitute into the first equation. 3x + 5 y = 9 3 ∗ −2 + 5 y = 9 − 6 + 5y = 9 − 6 + 5y + 6 = 9 + 6 5 y = 15 5 y 15 = 5 5 y=3 Our solution is (-2, 3). To check that this is indeed a solution for our system, I like to substitute these values in the second equation. Check: 2(-2) – 3(3) = -13 -4 – 9 = -13 -13 = -13 Notice how we’ve used the same techniques used in solving equations earlier in our studies. We haven’t added any new concepts; we are merely using those concepts in a different manner. Example 2: Solve this system of equations by the elimination method. 3 x + 4 y = 18  2 x + y = 3

We notice that all signs are positive. That tells us we will multiply one equation by a negative value. Let’s multiply the second equation by –4 in order to eliminate the yterms. (You could multiply the first equation by 2 and the second equation by –3 to eliminate the x-terms.) 1(3 x + 4 y = 18) ≡ 3 x + 4 y = 18

− 4(2 x + y = 3) ≡ −8 x − 4 y = −12

Adding the two equations results in − 5x = 6 − 5x 6 = −5 −5 6 x=− 5

Dividing by the coefficient of x

Now we can either substitute this into one of the original equations or solve for y, or we can use elimination to solve for y. Using elimination to solve for y, I must multiply the first equation by 2 and second equation by –3. 2(3 x + 4 y = 18) ≡ 6 x + 8 y = 36

− 3(2 x + y = 3) ≡ −6 x − 3 y = −9

Adding the two equations, we have 5 y = 27 5 y 27 = 5 5 27 y= 5

Dividing all terms by 5

Check:  − 6  27 2  + ?3  5  5 − 12 27 + ?3 5 5 15 =3 5 3=3 Matrices

A matrix is a rectangular array of numbers. Each number in a matrix is called an element of the matrix. The matrix below, with three rows and four columns, is called a 3× 4 , (read 3 by 4) matrix.

2 5 -2 5 -3 6 4 0 1 3 7 2 A matrix can be created from a system of linear equations using only the coefficients and the constants in the equations. For example, the system of equations  2 x + 5 y = −1  3 x − 2 y = 8 will be represented in matrix form as a coefficient matrix and a constant matrix: 2 5  − 1 3 − 2 and 8      We combine these into an augmented matrix: − 1 2 5 3 − 2 8    Using this augmented matrix we can solve the system of equations by manipulating the rows of the augmented matrix until we have an augmented matrix of the form: 1 0 x  0 1 y    The changes allowed to the rows of an augmented matrix are: 1. Any two rows may be interchanged. 2. Multiply all the elements in a row by the same nonzero number. 3. Replace a row by the sum of that row and a nonzero multiple of any other row. The first operation allows us to arrange the equations as best suits our solution strategy. How we arrange the equations doesn’t alter the system. The second operation allows us to write an equation in a different form. We did this when we solved a system using elimination.

The third operation allows us to combine equations in order to eliminate one of the variables; that is, one of the coefficients will become zero. Let’s use these operations to solve this system of equations. You may find it helpful it you note beside the matrix what you are doing. A word of caution, don’t try to use too many operations in one step. Invariably you will make a mistake. Keep in mind our goal is to have a 1 0 in the first row and 0 1 in the second row. Let’s start by getting that 1 in the first position of row 1. If we multiply row 1 by –1, then add row 2 to row 1 and store the result in row 1, we’ll have our 1 in the proper position. That will be denoted by -1R1 -> R1 or –1 times row 1 will be stored in row 1. − 1 2 5 3 − 2 8  -1R1 -> R1   − 2 − 5 1  R1 + R2 ->R1 (Add row 2 to row 1 and store in row 1) 3 − 2 8  1 − 7 9 3 − 2 8    Now we want to get the first zero in row 2. We can do this by multiplying row 1 by –3 , then adding that to row 2, storing the result in row 2. We will do this in one step, since we don’t want to change row1. 1 − 7 9 3 − 2 8  -3R1 + R2 -> R2   1 − 7 9  0 19 −19   Now we want a one in the second position of row 2 and we can do that by dividing all of row 2 by 19. 1 − 7 9  0 19 −19 R2/19 -> R2   1 − 7 9  0 1 −1  Now we want a zero in the second position of row 1. If we multiply row 2 by 7 and add to row 1, that will put a zero in position 2 of row 1.

1 − 7 9  7R2 + R1 -> R1 0 1 −1  1 0 2  0 1 −1   Now that we have our matrix in the desired form we can state our solution for the system of equations is (2, -1). Yes, this seems to be much more work than using elimination, but it isn’t. In fact, this is the same work you would perform if using elimination to solve this system. Because you are writing each step and copying the matrix, it appears to be more work than it actually is. The process is similar for any system of equations, but the order in which you apply operations may vary. Just remember your goal is to have a one in position x of row x and zeroes in all other positions of row x. That means you want a 1 in position 1 of row 1, a 1 in position 2 of row 2, etc. Example 3: Use augmented matrices to solve this system of equations:

3x1 + 4 x 2 = −1  3x1 + 5 x 2 = 1 First we write our augmented matrix. 3 4 − 1 3 5 1    Let’s get our 0 in position 1 of row 2 as our first step, by multiplying row 1 by –1 and adding to row 2. Note this is the same thing as subtracting row 1 from row 2. 3 4 − 1 3 5 1  -1R1 + R2 -> R2   3 4 − 1 0 1 2    Now let’s multiply row 2 by –4 and add to row 1 to get a zero in position 2 of row 1. 3 4 − 1 0 1 2  -4R2 + R1 -> R1  

3 0 − 9 0 1 2    Now we need to transform row 1 so the first value is a 1. We can do this by dividing row 1 by 3. 3 0 − 9 0 1 2  R1/3 -> R1   1 0 − 3 0 1 2    From our augmented matrix we have x1 = -3 and x2 = 2. We can check to be certain these are correct. Check: 3(-3) + 4(2) ? –1 -9 + 8 = -1 -1 = -1

3(-3) + 5(2) ? 1 -9 + 10 = 1 1=1

Our solution checks in both the original equations. Please note that this is one area where it is easy to make mistakes. Until you are comfortable with this process, always check your solutions in the original equations.