Survey
* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project
6.3 Notes O’Brien F15 CA 6th ed HLR 6.3 Solution of Linear Systems by Row Transformations I. Introduction In this section we will solve systems of first degree equations which have two or more variables. We will use matrices and three row operations to rewrite the system into reduced row-echelon form. 2 1 0 0 2 3 5 18 Example: 2x – 3y + 5z = 18 4x + z= 9 0 1 9 0 1 0 3 4 x + 5y + 2z = –11 0 0 1 1 1 5 2 11 II. Terminology A. Matrix A matrix is a rectangular array of numbers. The plural of matrix is matrices. 0 7 2 3 Example: 0 6 5 9 5 1 4 2 A horizontal line of numbers is called a row. A vertical line of numbers is called a column. B. Entry Each number or element in a matrix is called an entry. Each entry in a matrix can be designated by a letter with two subscripts which indicate the row and column it is in. Example: a 1,2 is the entry in the first row, second column. In the matrix above, a 1,2 = –3. C. Order A matrix which has m rows and n columns is said to be of order m x n (read “m by n”). When giving the order of a matrix, the number of rows always comes first, followed by the number of columns. Example: The matrix shown above has 3 rows and 4 columns, so it is a 3 x 4 matrix. D. Main Diagonal Entries a 1,1 , a 2,2 , ..., a n,n form the main diagonal of the matrix. Example: E. In the matrix above, the main diagonal contains entries a 1,1 = 2, a 2,2 = 6, and a 3,3 = –4 Reduced Row-echelon Form of a Matrix A matrix in reduced row-echelon form (RREF) has the following properties: 1 0 0 1 0 1 0 5 0 0 1 2 1. All rows consisting entirely of zeros occur at the bottom of the matrix. 2. For each row that does not consist entirely of zeros, the first non-zero entry is 1 (the leading 1). 3. For two successive non-zero rows, the leading 1 in the lower row is farther right than the leading 1 in the higher row. 4. Each column that contains a leading 1 has zeros above and below the leading 1. 1 6.3 Notes O’Brien F15 CA 6th ed HLR F. Augmented Matrix An augmented matrix is written using the coefficients and constants of a system of linear equations. We use a vertical bar to separate the coefficients from the constants. If a term is missing from an equation, we insert zero as a placeholder in the matrix. 2x – 4y + 3z = 9 1x – 2z = 13 –5x + 6y + 4z = 17 III. 3 9 2 4 0 2 13 1 5 6 4 1 7 Row Operations To rewrite a system of equations into reduced row-echelon form, we can use three basic row operations to produce equivalent systems (systems which have exactly the same solution as the original). 1. Interchange two rows [Swap rows] Example of notation: R1 R 2 This operation is used to get a 1 in a pivot position. 2. Multiply each entry in a row by a nonzero constant [Multiply] 3. Add a multiple of one row to another [Pivot] 1 R3 4 This operation is also used to get a 1 in a pivot position, usually by multiplying the row by the reciprocal of the leading coefficient. Example of notation: Example of notation: 3R 1 R 2 This operation is used to get a 0 above or below a one in a pivot position. Typically we take (the opposite of the leading coefficient x the pivot row) + the row we are changing. Caution: When we add a multiple of a row to another row, only the row we add to changes. The row we multiply does not change. It is called the pivot row. IV. The Sequence of Operations in Gauss-Jordan Elimination Our goal is to rewrite the given system of equations into reduced row-echelon form. To do this, we work from left to right, transforming one column at a time. First we get a one in the pivot position and then we get zeros above and below the one. Starting with the first column: 1. Get a 1 in the pivot position using Rowop 1 (Swap) or Rowop 2 (Multiply). 1 Be sure you record your row operation in proper form. (Example: R2 ). 3 2. Get 0s above and below the pivot by using Rowop 3 (Pivot). Be sure you record your row operations in proper form. (Example: 4R 2 R 3 ). Repeat steps 1 and 2 for each column, working from left to right. Always get the 1 in the pivot position and then 0s above and below it before you move to the next column. Once you have reduced row-echelon form (1s along main diagonal and 0s above and below), write your solution as an ordered pair or ordered triple (i.e., as a point). You can check your solution by plugging it into each equation in the original system of equations or by using SOLVSYS or SOLVSYS3. Hint: The first pivot is in row 1, column 1. The second pivot is in row 2, column 2. The third pivot is in row 3, column 3. The nth pivot is in row n, column n. Thus the pivot moves along the main diagonal. 2 6.3 Notes O’Brien F15 CA 6th ed HLR V. ROWOPS Program 1. Before you enter the program, you must enter your matrix as Matrix A. Go to the MATRIX menu. Right arrow two times to EDIT. Select [A]. Enter # of rows followed by the # of columns. Enter matrix, row by row, from left to right. Hit enter after each entry. Before you leave this screen, check your matrix for errors by using the arrow keys to move from column to column, row to row. 2. Turn the program ROWOPS on. Start on a blank line on the home screen. Hit the Program key. Select the number of the program called ROWOPS. You should see prgmROWOPS. Hit enter. You should see the matrix you just entered. Record the initial matrix on your paper. Hit enter again to advance the program. 3. Performing Row Operations A. To get a one in a pivot position by swapping rows: Select 1 TO SWAP ROWS. Enter the number of the first row you want to swap. Hit enter. Enter the number of the other row you want to swap. Hit enter. Record the row operation in proper form (Ex: R1 R3). Record the resulting matrix. B. To get a one in a pivot position by multiplying a row: Select 2 TO MULTIPLY. Enter the number of the row you want to multiply. Hit enter. Enter the number you want to multiply by (usually the reciprocal of the leading coefficient). Hit enter. Record the row operation in proper form (Ex: ¼R1). Record the resulting matrix. C. To get a zero above or below a one in a pivot position: Select 3 TO PIVOT. Enter the row number where the pivot is located. Hit enter. Enter the column number where the pivot is located. Hit enter. Record the row operation in proper form (Ex: 2R2 + R1). Record the resulting matrix. D. To exit the ROWOPS program: Select 4 TO STOP. Hit enter. Hit clear. 4. Hints You will not use Rowop 1 (Swap) very often. In fact, you can do all Gauss-Jordan Elimination problems using just Rowop 2 (Multiply) and Rowop 3 (Pivot). When you use Rowop 3 (Pivot), the program will get zeros in every position in the column except where the pivot is located. Be sure you write down the appropriate row operation to get each zero. You must record every matrix and every row operation. It is o.k. to record more than one pivoting operation on a single matrix, but do not record the operations to get zeros on the same matrix where you record the operation to get a one. Pivot R1 C1 is not the proper form for recording an operation to get zeros. You must be specific about what you multiplied the pivot row by and what row you added that to. 3 6.3 Notes O’Brien F15 CA 6th ed HLR VI. The Number of Solutions of a Linear System In a three dimensional coordinate system, the graph of a linear equation in three variables is a plane. 1. A consistent, independent system would mean the three planes were intersecting in one point, like the corner of a room. A solution to this type of system is an ordered triple such as (1, –7, 4). 1 1 0 0 0 1 0 7 0 0 1 4 2. A consistent, dependent system would mean that the three planes were intersecting in a line or that all three were the same plane. A solution to this type of system would look like (z – 3, 2z + 5, z) where two of the variables (usually x & y) are expressed in terms of the third (usually z). Note the all zero row. 1 0 0 1 0 0 An inconsistent system would mean that the three planes have no points of intersection common to all three. The solution to this type of system will be the empty set. Note the row with three zeros and a non-zero constant. 1 0 0 0 1 0 0 0 0 3. VII. 1 3 5 0 2 0 2 3 6 Sample Problems Example 1 Solve the following system of equations using Gauss-Jordan Elimination with Matrices. –2x + 3y = –5 5x – 7y = 13 3 5 2 5 7 13 3R 2 2 R1 (like 31 – 36 on p. 441) 1 3 5 2 2 5 7 13 1R 2 1 1 0 4 0 1 1 5R 1 R 2 1 3 2 1 0 2 5 2 1 2 2R 2 1 3 2 1 0 5 2 1 Solution: (4, 1) Example 2 Solve the following system of equations using Gauss-Jordan Elimination with Matrices. –3x – 2y + z = –1 x + 4y – 7z = –23 6x + y + z = 14 (like 41 – 48 on p. 441) 1 1 3 2 4 7 23 1 6 1 1 14 4 7 23 1 10 20 70 0 0 23 43 152 1 5 1 0 0 1 2 7 0 0 3 9 R1 R 2 1 R 10 2 31 R 3 4 7 23 1 1 1 3 2 6 1 1 14 4 1 1 0 0 23 7 23 2 7 43 152 1 5 1 0 0 1 2 7 0 0 1 3 3R1 R 2 6R1 R 3 4R 2 R 1 23R 2 R 3 1R 3 R 1 2R 3 R 2 1 0 0 0 1 0 0 0 1 2 1 3 Solution: (2, –1, 3) 4 6.3 Notes O’Brien F15 CA 6th ed HLR Example 3 Solve the following system of equations using Gauss-Jordan Elimination with Matrices. 4x + 2y = –6 –8x – 4y = 17 (like 38 on p. 441) 2 6 4 8 4 17 1 3 1 2 2 8 4 17 1R 4 1 8R 1 R 2 1 1 3 2 2 5 0 0 No Solution Example 4 Solve the following system of equations using Gauss-Jordan Elimination with Matrices. –x – 2y + 3z = –1 x + 5y – 8z = –23 6x + 12y – 18z = 6 (like 59 – 62 on p. 442) 3 1 1 2 5 8 23 1 6 12 18 6 5 8 23 1 3 5 24 0 0 18 30 144 x 31 z 17 y 53 z 8 R1 R 2 1R 3 2 1 1 6 5 8 2 3 12 18 5 8 23 1 1 53 8 0 0 18 30 144 x 31 z 17 y 53 z 8 Solution: zz zz 1 3 23 1 6 1R 1 R 2 6R 1 R 3 5R 2 R1 18R 2 R 3 z 17, 53 z 8, z 1 1 0 17 3 0 1 53 8 0 0 0 0 Example 5 Solve the following application problem by using Gauss-Jordan Elimination with Matrices. Pat Summers wins $200,000 in the Louisiana state lottery. He invests part of the money in real estate with an annual return of 3% and another part in a money market account at 2.5% interest. He invests the rest, which amounts to $80,000 less than the sum of the other two parts, in certificates of deposit that pay 1.5%. If the total annual interest on the money is $4900, how much was invested at each rate? (like 69 – 72 on p. 443) x = money invested in real estate at 3% y = money invested in money market account at 2.5% z = money invested in CDs at 1.5% total invested was $200,000 total interest income was $4,900 x + y + z = 200,000 .03x + .025y + .015z = $80,000 less than the sum of the other two parts, in certificates of deposit 4,900 z = x + y – 80,000 x + y – z = 80,000 x + y+ z = 200,000 .03x + .025y + .015z = x + y– 4,900 z = 80,000 5 6.3 Notes O’Brien F15 CA 6th ed HLR x + y+ z = 200,000 .03x + .025y + .015z = x + y– 4,900 z = 80,000 1 1 200000 1 4900 .03 .025 .015 1 1 1 80000 1 200000 1 1 3 220000 0 1 0 0 2 120000 2R 3 R1 3R 3 R 2 Solution: .03R 1 R 2 1R 1 R 3 1R 2 R1 1 1 1 0 200 0 0 1 3 200 2 1 0 2 20000 3 220000 0 1 0 0 2 120000 200000 1100 120000 1 R3 2 –200R2 1 0 2 3 0 1 0 0 1 20000 220000 60000 1 0 0 100000 0 1 0 40000 0 0 1 60000 $100,000 is invested in real estate at 3% $40,000 is invested in money market account at 2.5% $60,000 is invested in CDs at 1.5% 6