Matrices Students have been working with matrices since Grade 9 and have been performing various operations with number arrays. However, a review of the terminology involved with matrices would be beneficial for the students. A matrix is a rectangular array of numbers enclosed by parenthesis. Matrices are usually named using upper case letters. Some examples of matrices are: A 4 3 6 9 5 2 B 3 7 4 1 6 C 2 7 4 0 1 3 The individual numbers in a matrix are called the elements. A horizontal arrangement of the numbers in a matrix is called a row. A vertical arrangement of the numbers in a matrix is called a column. The number of rows and the number of columns in a matrix is called the dimensions of a matrix. Any matrix that has the same number of rows as it has columns is called a square matrix. 5 2 the elements are 5, -2, 3, -7. The elements in row one are In the following matrix B 3 7 5 and -2 and those in row two are 3 and -7. The elements in column one are 5 and 3 and those in column two are -2 and -7.The dimensions of B are 2 rows by 2 columns. The dimensions are written as 2 2 and read as “two by two”. Since the number of rows and the number of columns are the same, this is also a square matrix. The operations of addition, subtraction, scalar multiplication and multiplication can be performed using matrices. Addition and subtraction can only be done if the matrices being used are of the same dimensions. These operations are done with the corresponding elements of the matrices involved. Scalar multiplication can be done on any matrix since it is simply applying the distributive property – multiply each element of the matrix by the number before the matrix. Multiplication can only be performed if the number of columns of the first matrix equals the number of rows of the second matrix. Then the process is carried out by doing row by column multiplication. Here are some examples of these operations done with matrices. Examples: Perform the indicated operations: 1. A B Given: A B 5 6 2 B 3 7 4 4 4 5 3 6 6 2 1 3 A B A B 8 3 5 7 9 4 5 12 13 Solution: 2. 4 3 6 A 8 5 9 Given: 6 7 A 4 5 3 2 Solution: 6 8 7 3 A B 4 3 5 1 3 2 2 8 4 3 3. 5 6 2 20 15 Solution: 30 10 4. AB Given: 8 3 B 3 1 2 8 6 2 3 A 4 2 5 14 10 A B 7 6 5 10 2 3 B 4 5 1 6 6 2 2 4 3 1 6 3 2 5 3 6 7 26 Solution: AB 4 2 2 4 5 1 4 3 2 5 5 6 5 28 This review of operations with matrices should be sufficient to enable the students to recall this prior knowledge. Associated with every square matrix is a value called the determinant. This value for a 2 2 matrix is the number that results from the difference between the products of the numbers a b represents any 2 2 matrix, then the determinant in each diagonal of the matrix. If A c d is the result of ad – bc. The determinant of A can be represented as detA or as A . Notation: det A a b ad bc c d Examples: Find the determinant of each of the following matrices: 5 3 1. 7 2 6 4 2. 2 3 4 2 3. 3 5 3 8 4. 2 4 52 73 6 3 2 4 45 3 2 3 4 28 10 21 18 8 10 20 6 12 16 28 11 26 a b represents any The inverse of a 2 2 matrix can also be determined. If A c d b d then the inverse of A, written as A-1, is found by: A 1 det A det A a c det A det A 1 When a 2 2 matrix is multiplied by its inverse, the result is the identity matrix 0 2 2 matrix, 0 . 1 Examples: Find the inverse of each of the following matrices: 3 2 1. A 5 4 Solution: The first step is to find the determinant of (A). A 12 10 A 2 4 A 2 5 2 4 A 1 2 5 2 1 2 2 3 2 2 2 2 or 5 3 2 2 1 3 2 Do not leave a negative sign in the denominator of any fraction. Apply the rule for division of integers and place the resulting sign in the numerator of the fraction. When using the inverse matrix to solve a system of linear equations, it is best to leave all the elements in fraction form. To confirm that the answer is correct, multiply the matrix by its inverse. 10 6 3 6 5 3 3 1 0 1 6 2 2 3 Check: 10 10 5 6 0 1 20 12 5 2 10 2 2 1 product of A A is the identity matrix. Therefore the inverse matrix is correct. 3 2 2 5 5 4 2 The 2 6 2. A 1 3 Solution: The first step is to find the determinant of (A). A 6 6 A 12 6 1 1 3 1 1 4 2 12 12 A orA 1 1 1 2 12 12 12 6 When using the inverse matrix to solve a system of linear equations, it is best to leave all of the elements in fraction form with the same common denominator as shown in the first inverse rather than as reduced fractions as shown in the second inverse. Check: 6 6 6 12 12 12 0 3 2 6 12 12 12 12 12 12 12 12 1 0 1 3 1 2 3 3 6 6 0 12 0 1 12 12 12 12 12 12 12 12 The product of A A is the identity matrix. Therefore the inverse matrix is correct. 1 The multiplication above was done using A-1 in which all the elements had the common denominator 12. Therefore, the resulting products could be manipulated in order to produce the identity matrix. 10 4 3. A 5 2 Solution: The first step is to find the determinant of (A). A 20 20 A 40 2 A 1 40 5 40 2 A 1 40 5 40 Check: 2 10 4 40 5 2 5 40 4 40 10 40 4 1 1 40 orA 1 20 10 10 1 1 40 4 8 4 20 20 40 40 40 10 10 10 40 40 40 40 40 40 40 40 40 20 20 0 40 40 40 0 40 1 0 40 0 1 40 The product of A A is the identity matrix. Therefore the inverse matrix is correct. 1 6 3 4. A 5 2 Solution: The first step is to find the determinant of (A). A 12 15 A 3 2 A 1 3 5 3 Check: 2 6 3 3 5 2 5 3 3 3 6 3 2 1 orA 1 3 5 2 3 3 12 15 18 18 3 3 3 3 3 3 3 6 10 10 15 12 0 3 3 3 3 3 3 0 3 1 0 3 0 1 3 The product of A A is the identity matrix. Therefore the inverse matrix is correct. 1 Exercises: 1. Find the determinant of each of the following matrices: 3 2 3 7 5 2 8 5 a) 4 10 b) c) d) 4 2 3 2 4 3 2. Find the inverse of each of the following 2 2 matrices. Check your solution by 1 performing the operation of A A . 3 4 a) A 1 2 6 3 b) A 7 4 5 0 c) A 4 2 9 3 d) A 5 2 Answers: Finding the determinant 3 2 1. a) 4 10 det = -20- + 12 det = -32 3 7 b) 4 2 det = -14- -12 det = -2 5 2 c) 3 2 8 5 d) 4 3 det = 10- + 6 det = 4 det -24- - 20 det = -4 Finding the inverse matrix 3 4 1. a) A 1 2 A 8 3 A 5 2 3 A 1 5 5 4 1 5 5 3 2 5 A 1 5 1 4 5 5 6 3 b) A 7 4 A 24 21 A 3 4 3 A 1 3 3 7 6 3 3 4 3 A 1 3 3 7 6 3 3 1 1 A 1 7 2 3 5 0 c) A 4 2 A 10 0 A 3 A 10 2 A 1 10 4 10 1 A 1 5 2 5 9 3 d) A 5 2 A 18 15 0 10 5 10 0 1 2 2 3 3 A 1 3 5 9 3 3 2 1 A 1 3 5 3 3 Solving a 2 2 system of linear equations by using the inverse matrix method A system of linear equations can be solved by using our knowledge of inverse matrices. The steps to follow are: Express the linear system of equations as a matrix equation. Determine the inverse of the coefficient matrix. Multiply both sides of the matrix equation by the inverse matrix. In order to multiply the matrices on the right side of the equation, the inverse matrix must appear in front of the answer matrix.(the number of columns in the first matrix must equal the number of rows in the second matrix). Complete the multiplication. The solution will appear as: 1 0 x c1 where c1 and c2 are the solutions. 0 1 y c2 Examples: Solve the following system of linear equations by using the inverse matrix method: 2 x 9 y 1 1. 4 x y 15 Solution: If 2 9 x 1 4 1 y 15 2 9 A 4 1 1 A 1 34 4 34 then This is the matrix equation that represents the system. A 2 36 A 34 9 34 2 34 1 A 1 34 4 34 9 34 2 34 This is the determinant and the inverse of the coefficient matrix. 1 34 4 34 9 1 2 9 x 34 34 2 4 1 y 4 34 34 9 34 1 2 15 34 2 36 34 34 8 8 34 34 34 34 0 34 9 9 1 135 x 34 34 34 34 36 2 y 4 30 34 34 34 34 0 136 x 34 34 34 y 34 34 34 1 0 x 4 0 1 y 1 The common point or solution is (4, -1). This is the result of multiplying the matrix equation by the inverse of the coefficient matrix. 3x 6 y 45 2. 9 x 5 y 8 3 6 x 45 Solution: 9 5 y 8 A 15 54 3 6 then If A A 39 9 5 5 A 1 39 9 39 5 39 9 39 6 39 3 39 6 5 3 6 x 39 39 3 9 5 y 9 39 39 15 54 39 39 27 27 39 39 6 39 45 3 8 39 30 30 225 48 x 39 39 39 39 54 15 y 405 24 39 39 39 39 39 39 0 39 0 273 x 39 39 39 y 429 39 39 1 0 x 7 0 1 y 11 The common point or solution is (-7, -11). In the next example, the products will be written over the common denominator instead of being written as two separate fractions. 4 x y 13 3. 6 x 5 y 37 1 x 13 4 Solution: 6 5 y 37 5 A 1 14 6 14 5 14 6 14 1 14 4 14 1 5 4 1 x 14 14 4 6 5 y 6 14 14 20 6 14 24 24 14 1 4 If A 6 5 then 5 A 1 14 6 14 1 14 4 14 1 14 13 4 37 14 5 5 65 37 x 14 14 6 20 y 78 148 14 14 14 0 28 x 14 14 14 0 14 y 70 14 14 14 A 20 6 A 14 1 0 x 2 0 1 y 5 The common point or solution is (-2, -5). 3x y 11 4. x 2 y 8 Solution: 3 1 x 11 1 2 y 8 3 1 If A 1 2 then A 6 1 A 7 2 1 A 1 7 7 1 3 7 7 2 1 2 1 3 1 x 11 7 7 7 7 1 3 1 2 y 1 3 8 7 7 7 7 6 1 7 33 7 7 7 0 7 2 2 22 8 x 7 7 1 6 y 11 24 7 7 0 14 x 1 0 x 2 7 7 7 y 35 0 1 y 5 7 7 solution is (-2, 5) The common point or Exercises: Solve the following systems of linear equations by using the inverse matrix method: 5 x 3 y 21 1. 2 x 7 y 21 2 x 3 y 48 2. 3x 2 y 42 2 x 6 y 3 3. 4 x 3 y 5 x y 1 4. 4 x 2 y 8 Answers: Solving systems of linear equations using the inverse matrix method 5 x 3 y 21 1. 2 x 7 y 21 If 5 3 A 2 7 then A 35 6 A 29 7 A 1 29 2 29 3 7 29 A 1 29 5 2 29 29 3 29 5 29 5 3 x 21 2 7 y 21 7 29 2 29 3 7 5 3 x 29 29 5 2 7 y 2 29 29 35 6 29 10 10 29 29 29 0 29 3 29 21 5 21 29 21 21 147 63 x 29 29 6 35 y 42 105 29 29 0 210 x 29 29 29 y 147 29 29 1 0 x 7.24 0 1 y 5.07 2 x 3 y 48 2. 3x 2 y 42 2 3 then A 4 9 If A 3 2 A 5 2 A 1 5 3 5 3 2 5 A 1 5 2 3 5 5 3 5 2 5 2 3 x 48 3 2 y 42 2 3 2 3 2 3 x 48 5 5 5 5 3 2 3 2 y 3 2 42 5 5 5 5 49 66 96 126 x 5 5 5 6 6 9 4 y 144 84 5 5 5 5 5 0 5 0 30 x 5 5 5 y 60 5 5 1 0 x 6 0 1 y 12 2 x 6 y 3 3. 4 x 3 y 5 3 6 1 18 18 A 4 2 18 18 2 6 x 3 4 3 y 5 2 6 then A 6 24 If A 4 3 A 18 3 6 3 6 2 6 x 3 18 18 18 18 4 2 4 3 y 4 2 5 18 18 18 18 6 24 18 18 9 30 x 18 18 18 24 6 y 12 10 88 18 18 18 18 0 21 x 18 18 18 0 18 y 2 18 18 18 1 0 x 1.16 0 1 y .1 1 x y 1 4. 4 x 2 y 8 2 A 1 2 4 2 1 1 then A 2 4 If A 4 2 A 2 1 2 1 2 1 1 x 1 4 2 y 8 2 2 4 2 1 2 1 1 x 2 2 1 4 2 y 4 2 2 1 2 1 1 8 2 24 2 4 4 2 2 2 0 2 2 2 2 8 x 2 2 4 2 y 4 8 2 2 0 6 x 2 2 2 y 4 2 2 1 0 x 3 0 1 y 2