Download Using Inverse Matrices to Solve Systems of Equations There are

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Algebra wikipedia , lookup

Determinant wikipedia , lookup

Mathematics of radio engineering wikipedia , lookup

Transcript
Using Inverse Matrices to Solve Systems of Equations There are certain matrices that are referred to as identity matrices. They are square matrices that have ones along the diagonal and zeros everywhere else. Here are some examples of identity matrices: ⎡ 1 0 0 0 0 ⎤
⎡ 1 0 0 0 ⎤
⎢
⎥
⎡ 1 0 0 ⎤ ⎢
0 1 0 0 0 ⎥
⎥ ⎡
⎢
1 0 ⎤
⎢
⎥ ⎢ 0 1 0 0 ⎥
1
0 0 1 0 0 ⎥ 0
1
0
⎢
⎢
⎥ ⎢ 0 0 1 0 ⎥ ⎣ 0 1 ⎥⎦ [ ] ⎢
⎢
0 0 0 1 0 ⎥
⎢⎣ 0 0 1 ⎥⎦ ⎢
⎥
0
0
0
1
⎢
⎥
⎣
⎦
⎣ 0 0 0 0 1 ⎦
The reason they are called identity matrices is because multiplying them by another matrix yields the same matrix. Try the following matrix multiplication for yourself. ⎡ 7 −2 3 ⎤ ⎡ 1 0 0 ⎤
⎢
⎥⎢
⎥ = ⎢ 4 4 −1 ⎥ ⎢ 0 1 0 ⎥
⎢⎣ 8 −17 5 ⎥⎦ ⎢⎣ 0 0 1 ⎥⎦
Try it in the other order too. ⎡ 1 0 0 ⎤ ⎡ 7 −2 3 ⎤
⎢
⎥⎢
⎥ = ⎢ 0 1 0 ⎥ ⎢ 4 4 −1 ⎥
⎢⎣ 0 0 1 ⎥⎦ ⎢⎣ 8 −17 5 ⎥⎦
When dealing with real numbers, we know that the multiplicative inverse of 2 is 0.5 because 2 i 0.5 = 1 (where 1 is the multiplicative identity for real numbers). It is also possible to find the multiplicative inverse of a matrix. (By the way, it’s usually just called an inverse matrix instead of multiplicative inverse.) Show that these two matrices are inverses by multiplying them in both orders. ⎡ 7 2 1 ⎤ ⎡ −2 8 −5 ⎤
⎢
⎥⎢
⎥
⎢ 0 3 −1 ⎥ ⎢ 3 −11 7 ⎥ = ⎢⎣ −3 4 −2 ⎥⎦ ⎢⎣ 9 −34 21 ⎥⎦
⎡ −2 8 −5 ⎤ ⎡ 7 2 1 ⎤
⎢
⎥⎢
⎥ = ⎢ 3 −11 7 ⎥ ⎢ 0 3 −1 ⎥
⎢⎣ 9 −34 21 ⎥⎦ ⎢⎣ −3 4 −2 ⎥⎦
Not all matrices have multiplicative inverses. With the real numbers, the only number that doesn’t have a multiplicative inverse is 0. With matrices, there are many matrices that don’t have multiplicative inverses. We call these matrices non-­‐
invertible. Finding the inverse of a given matrix by hand is a tedious process and we won’t do it in this class. But we will use computer software (or a calculator) to find inverse matrices. Here is a description of how to use Geogebra to find the inverse of this ⎡ −3 4 2 ⎤
⎢
⎥
matrix: ⎢ 6 7 8 ⎥ . ⎢⎣ 9 −1 −5 ⎥⎦
First, create the matrix in Geogebra and name it M by typing the following into the input bar: M = {{1, 2, 3}, {0, 1, 4}, {5, 6, 0}} Now create the inverse matrix and name it Minv by typing the following into the input bar: Minv = Invert[M] You should be able to see the result in the Algebra sidebar of Geogebra. (If not, go to the View menu and check Algebra.) Write the inverse matrix here: Now check to make sure they are really inverses by finding their product. Type this in the input bar: P = M * Minv You should be able to see that P is an identity matrix. Now let’s use what you’ve learned to solve this system of equations. −2x + 8y − 5z = −1
3x − 11y + 7z = 2 9x − 34y + 21z = 6
Notice that you can rewrite these equations as a matrix equation like this: ⎡ −2x + 8y − 5z ⎤ ⎡
⎤
⎢
⎥ ⎢ −1 ⎥
⎢ 3x − 11y + 7z ⎥ = ⎢ 2 ⎥ (each side of the equation is a 3x1 matrix) ⎢ 9x − 34y + 21z ⎥ ⎢⎣ 6 ⎥⎦
⎣
⎦
And using matrix factoring you can write the equation like this: ⎡ −2 8 −5 ⎤ ⎡ x ⎤ ⎡ −1 ⎤
⎢
⎥⎢
⎥ ⎢
⎥
⎢ 3 −11 7 ⎥ ⎢ y ⎥ = ⎢ 2 ⎥ (a 3x3 matrix, a 3x1 matrix, and a 3x1 matrix) ⎣⎢ 9 −34 21 ⎦⎥ ⎢⎣ z ⎥⎦ ⎢⎣ 6 ⎥⎦
⎡ 7
If you multiply both sides of this equation by the matrix ⎢ 0
⎢
⎢⎣ −3
will get the following equation: ⎡ 7 2 1 ⎤ ⎡ −2 8 −5 ⎤ ⎡ x ⎤ ⎡ 7 2 1 ⎤ ⎡ −1
⎢
⎥⎢
⎥⎢ y ⎥ = ⎢
⎥⎢
⎥ ⎢ 0 3 −1 ⎥ ⎢ 2
⎢ 0 3 −1 ⎥ ⎢ 3 −11 7 ⎥ ⎢
⎢⎣ −3 4 −2 ⎥⎦ ⎢⎣ 9 −34 21 ⎥⎦ ⎢⎣ z ⎥⎦ ⎢⎣ −3 4 −2 ⎥⎦ ⎢⎣ 6
2 1 ⎤
⎥
3 −1 ⎥ , then you 4 −2 ⎥⎦
⎤
⎥ ⎥
⎥⎦
At this point, you might be wondering why in the world you would ever multiply both sides of the equation by that matrix. It looks very complicated. But remember from earlier in this reading that the first two matrices in the equation are inverses. So the equation reduces to ⎡ 1 0 0 ⎤ ⎡ x ⎤ ⎡ 7 2 1 ⎤ ⎡ −1 ⎤
⎥ ⎢
⎢
⎥⎢
⎥⎢
⎥
⎢ 0 1 0 ⎥ ⎢ y ⎥ = ⎢ 0 3 −1 ⎥ ⎢ 2 ⎥ ⎢⎣ 0 0 1 ⎥⎦ ⎢⎣ z ⎥⎦ ⎢⎣ −3 4 −2 ⎥⎦ ⎢⎣ 6 ⎥⎦
Since the matrix at the left is an identity matrix, multiplying by it yields the same thing, and the equation becomes even simpler. ⎡ x ⎤ ⎡ 7 2 1 ⎤ ⎡ −1 ⎤
⎢
⎥ ⎢
⎥⎢
⎥
⎢ y ⎥ = ⎢ 0 3 −1 ⎥ ⎢ 2 ⎥ ⎢⎣ z ⎥⎦ ⎢⎣ −3 4 −2 ⎥⎦ ⎢⎣ 6 ⎥⎦
The only thing left to do is to multiply the two matrices on the right side of the equation to figure out what x, y, and z equal. Finish solving the system of equations ⎡ 7 2 1 ⎤
⎡ −1 ⎤
⎢
⎥
by multiplying 0 3 −1
and ⎢ 2 ⎥ . Check the values you find for x, y, and z ⎢
⎥
⎢
⎥
⎢⎣ −3 4 −2 ⎥⎦
⎢⎣ 6 ⎥⎦
in the original equations.