Return to my Mathematics pages
Go to my home page
© Copyright 2001, Jim Loy
Systems of Equations:
Let me reproduce this section, from Intro to Matrices. A system of equations is a collection of equations that are all true simultaneously. For example:
y=3x-1
y=2x+3
This is a system of equations with two variables. By the way, they are linear equations (they don't have squares and cubes in them), which are the easiest and most common equations. Both of these equations must hold simultaneously. y=3x-1 has infinitely many solutions, but the system of these two equations has one and only one solution. There are several ways to solve a system of equations. Here is one way (solving for x in one equation and then substituting that into the second):
y=3x-1
3x=y+1
x=(y+1)/3
y=2(y+1)/3+3 [substituting x=(y+1)/3 for x in the second equation of our system]
y=2y/3 + 3+2/3
y=2y/3 + 9/3 + 2/3
3y=2y+11
3y-2y=11
y=11
x=12/3=4
You may not show all of those steps. We can also subtract equations:
2y=6x-2 [multiplying the first equation by 2]
3y=6x+9 [multiplying the second equation by 3]
y=11 [subtracting the first equation from the second]
Once we have found y, we can go back and find x. Notice that subtracting -2 is the same as adding 2. We can also solve a system with two variables by graphing the two equations. We can normally tell exactly where the two lines intersect.
Solving a system of three or more equations is just as easy, but takes more steps. Here is a system of three equations:
x-2y+ z=-1
2x+ y-3z=3
3x+3y-2z=10
We could subtract equations. First we might get rid of the x's by subtracting multiples of the first equation from the other two equations. This would give us two equations with two unknowns (y and z), which we could then solve by subtracting equations again.
Determinants defined:
A determinant is a special kind of matrix, one that has a numerical value. The value of a matrix may be 3, for example. We write a determinant with vertical lines around it:
| 2 1 |
| -3 4 | = 8-(-3) = 11
Here you see four vertical lines, because I am limited in my choice of symbols here. Normally, draw just one longer line on each side of the determinant. The above 2x2 determinant equals 11. This is how you evaluate a 2x2 determinant:
| a b |
| c d | = ad-bc
Let's solve our first system of equations (in two variables), rewriting it as:
3x-y=1
2x-y=-3
This gives us three determinants, and these two equations
| 1 -1 | | 3 1 |
|-3 -1 | | 2 -3 |
x= __________ y= __________
| 3 -1 | | 3 -1 |
| 2 -1 | | 2 -1 |
Remember that determinants are numbers. The above equations are just numbers divided by numbers. The denominators are determinants derived from the left side of our two equations (the four coefficients). If the denominator=0, then the system has no solution. You already knew that you can't divide by zero. The two numerators are made up of the denominator determinant, with the two numbers from the right side of our equations inserted into it. We can evaluate these three determinants, and we get x=(-1-3)/(-3+2)=4 and y=(-9-2)/(-3+2)=11. That is the answer that we got above.
3x3 determinants:
Determinants may seem like a waste of time with two equations and two unknowns. But you can get good at using them. Besides, determinants work well when programmed into a computer. 3x3 determinants work much the same way, and are not much more difficult. We begin to see how useful determinants can be, when trying to solve three or more equations. Let's solve our system of three equations:
x-2y+ z=-1
2x+ y-3z=3
3x+3y-2z=10
We construct our determinants in the same way:
|-1 -2 1 | | 1 -1 1 | | 1 -2 1 |
| 3 1 -3 | | 2 3 -3 | | 2 1 3 |
|10 3 -2 | | 3 10 -2 | | 3 3 10 |
x= _____________ y= _____________ z= _____________
| 1 -2 1 | | 1 -2 1 | | 1 -2 1 |
| 2 1 -3 | | 2 1 -3 | | 2 1 -3 |
| 3 3 -2 | | 3 3 -2 | | 3 3 -2 |
There are two ways to evaluate a 3x3 determinant. I will show you both ways. Here is a general 3x3 determinant:
| a b c |
| d e f | = aei+bfg+cdh-afh-bdi-ceg
| g h i |
Do you see the pattern there? We go along diagonals, the last three being negative. This method can be easily extended to 4x4 and larger determinants. And it can be programmed into a computer. This is the method that I learned. But the following method seems to be more common:
| a b c | | e f | | d f | | d e |
| d e f | = a | h i | - b | g i | + c | g h |
| g h i |
or
| a b c | | e f | | b c | | b c |
| d e f | = a | h i | - d | h i | + g | e f |
| g h i |
We just make our 3x3 determinant into the sum of three 2x2 determinants. Again there is an easy pattern here. We have a times the 2x2 determinant made up of numbers not from the same rows and colums of a. We can choose any row or column to form our three determinants. If we had chosen the second column, instead of the first, the signs would have been -+- instead of +-+. This method can also be programmed into a computer.
Let's solve our three equations:
|-1 -2 1 | | 1 -1 1 | | 1 -2 -1 |
| 3 1 -3 | | 2 3 -3 | | 2 1 3 |
|10 3 -2 | | 3 10 -2 | | 3 3 10 |
x= _____________ y= _____________ z= _____________
| 1 -2 1 | | 1 -2 1 | | 1 -2 1 |
| 2 1 -3 | | 2 1 -3 | | 2 1 -3 |
| 3 3 -2 | | 3 3 -2 | | 3 3 -2 |
x=(2+60+9-9-12-10)/(-2+18+6+9-8-3)=40/20=2 and y=(-6+9+20+30-4-9)/20=40/20=2 and z=(10-18-6-9+40+3)/20=20/20=1. I will substitute those numbers back in to the three equations (we have to do this, as you should always check for mistakes) to see if x=2, y=2, z=1 is the solution. It worked. That is the solution.
This may all seem difficult. But, by systematizing the process, it actually makes solving systems of equations easy.
Incidentally, here is a formula for the area of a triangle, given the rectangular coordinates of the vertices:
| x1 y1 1 |
A = 1/2 | x2 y2 1 |
| x3 y3 1 |
A more complicated formula, involving three determinants, gives the area of a triangle, given the rectangular coordinates of the vertices in three-space.