8.1 Systems of Linear Equations: Gaussian Elimination
Up until now, when we concerned ourselves with solving different types of equations there was only one equation to solve at a time. Given an equation , we could check our solutions geometrically by finding where the graphs of and intersect. The -coordinates of these intersection points correspond to the solutions to the equation , and the -coordinates were largely ignored. If we modify the problem and ask for the intersection points of the graphs of and , where both the solution to and are of interest, we have what is known as a system of equations, usually written as
The `curly bracket' notation means we are to find all pairs of points which satisfy both equations. We begin our study of systems of equations by reviewing some basic notions from Intermediate Algebra.
For reasons which will become clear later in the section, we are using subscripts in Definition to indicate different, but fixed, real numbers and those subscripts have no mathematical meaning beyond that. For example, is a linear equation in two variables with , and . We can also consider to be a linear equation in two variables1 by identifying , , and . If and are both , then depending on , we get either an equation which is always true, called an identity, or an equation which is never true, called a contradiction. (If , then we get , which is always true. If , then we'd have , which is never true.) Even though identities and contradictions have a large role to play in the upcoming sections, we do not consider them linear equations. The key to identifying linear equations is to note that the variables involved are to the first power and that the coefficients of the variables are numbers. Some examples of equations which are non-linear are , and . We leave it to the reader to explain why these do not satisfy Definition. From what we know from Sections and, the graphs of linear equations are lines. If we couple two or more linear equations together, in effect to find the points of intersection of two or more lines, we obtain a system of linear equations in two variables. Our first example reviews some of the basic techniques first learned in Intermediate Algebra.
A few remarks about Example Example 1 are in order. It is clear that some systems of equations have solutions, and some do not. Those which have solutions are called consistent, those with no solution are called inconsistent. We also distinguish the two different types of behavior among consistent systems. Those which admit free variables are called dependent; those with no free variables are called independent.4 Using this new vocabulary, we classify numbers 1, 2 and 3 in Example Example 1 as consistent independent systems, number 4 is consistent dependent, and numbers 5 and 6 are inconsistent.5 The system in 6 above is called overdetermined, since we have more equations than variables.6 Not surprisingly, a system with more variables than equations is called underdetermined. While the system in number 6 above is overdetermined and inconsistent, there exist overdetermined consistent systems (both dependent and independent) and we leave it to the reader to think about what is happening algebraically and geometrically in these cases. Likewise, there are both consistent and inconsistent underdetermined systems,7 but a consistent underdetermined system of linear equations is necessarily dependent.8
In order to move this section beyond a review of Intermediate Algebra, we now define what is meant by a linear equation in variables.
Instead of using more familiar variables like , , and even and/or in Definition, we use subscripts to distinguish the different variables. We have no idea how many variables may be involved, so we use numbers to distinguish them instead of letters. (There is an endless supply of distinct numbers.) As an example, the linear equation represents the same relationship between the variables and as the equation does between the variables and . In addition, just as we cannot combine the terms in the expression , we cannot combine the terms in the expression . Coupling more than one linear equation in variables results in a system of linear equations in n variables. When solving these systems, it becomes increasingly important to keep track of what operations are performed to which equations and to develop a strategy based on the kind of manipulations we've already employed. To this end, we first remind ourselves of the maneuvers which can be applied to a system of linear equations that result in an equivalent system.9
We have seen plenty of instances of the second and third moves in Theorem when we solved the systems in Example Example 1. The first move, while it obviously admits an equivalent system, seems silly. Our perception will change as we consider more equations and more variables in this, and later sections.
Consider the system of equations
Clearly , and we substitute this into the second equation to obtain . Finally, we substitute and into the first equation to get , so that . The reader can verify that these values of , and satisfy all three original equations. It is tempting for us to write the solution to this system by extending the usual notation to and list our solution as . The question quickly becomes what does an `ordered triple' like represent? Just as ordered pairs are used to locate points on the two-dimensional plane, ordered triples can be used to locate points in space.11 Moreover, just as equations involving the variables and describe graphs of one-dimensional lines and curves in the two-dimensional plane, equations involving variables , , and describe objects called surfaces in three-dimensional space. Each of the equations in the above system can be visualized as a plane situated in three-space. Geometrically, the system is trying to find the intersection, or common point, of all three planes. If you imagine three sheets of notebook paper each representing a portion of these planes, you will start to see the complexities involved in how three such planes can intersect. Below is a sketch of the three planes. It turns out that any two of these planes intersect in a line,12 so our intersection point is where all three of these lines meet.

Since the geometry for equations involving more than two variables is complicated, we will focus our efforts on the algebra. Returning to the system
we note the reason it was so easy to solve is that the third equation is solved for , the second equation involves only and , and since the coefficient of is , it makes it easy to solve for using our known value for . Lastly, the coefficient of in the first equation is making it easy to substitute the known values of and and then solve for . We formalize this pattern below for the most general systems of linear equations. Again, we use subscripted variables to describe the general case. The variable with the smallest subscript in a given equation is typically called the leading variable of that equation.
In our previous system, if we make the obvious choices , , and , we see that the system is in triangular form.14 An example of a more complicated system in triangular form is
Our goal henceforth will be to transform a given system of linear equations into triangular form using the moves in Theorem.
Like all algorithms, Gaussian Elimination has the advantage of always producing what we need, but it can also be inefficient at times. For example, when solving 2 above, it is clear after we eliminated the 's in the second step to get the system
that equations and when taken together form a contradiction since we have identical left hand sides and different right hand sides. The algorithm takes two more steps to reach this contradiction. We also note that substitution in Gaussian Elimination is delayed until all the elimination is done, thus it gets called back-substitution. This may also be inefficient in many cases. Rest assured, the technique of substitution as you may have learned it in Intermediate Algebra will once again take center stage in Section. Lastly, we note that the system in 3 above is underdetermined, and as it is consistent, we have free variables in our answer. We close this section with a standard `mixture' type application of systems of linear equations.
Exercises
(Review Exercises) In Exercises -, take a trip down memory lane and solve the given system using substitution and/or elimination. Classify each system as consistent independent, consistent dependent, or inconsistent. Check your answers both algebraically and graphically.
- Find two other forms of the parametric solution to Exercise above by reorganizing the equations so that or can be the free variable.
- A local buffet charges per person for the basic buffet and for the deluxe buffet (which includes crab legs.) If 27 diners went out to eat and the total bill was before taxes, how many chose the basic buffet and how many chose the deluxe buffet?
- At The Old Home Fill'er Up and Keep on a-Truckin' Cafe, Mavis mixes two different types of coffee beans to produce a house blend. The first type costs $3 per pound and the second costs $8 per pound. How much of each type does Mavis use to make 50 pounds of a blend which costs $6 per pound?
- Skippy has a total of 10,000 to split between two investments. One account offers simple interest, and the other account offers simple interest. For tax reasons, he can only earn in interest the entire year. How much money should Skippy invest in each account to earn in interest for the year?
- A salt solution is to be mixed with pure water to produce 75 gallons of a salt solution. How much of each are needed?
- At The Crispy Critter's Head Shop and Patchouli Emporium along with their dried up weeds, sunflower seeds and astrological postcards they sell an herbal tea blend. By weight, Type I herbal tea is 30% peppermint, 40% rose hips and 30% chamomile, Type II has percents 40%, 20% and 40%, respectively, and Type III has percents 35%, 30% and 35%, respectively. How much of each Type of tea is needed to make 2 pounds of a new blend of tea that is equal parts peppermint, rose hips and chamomile?
- Discuss with your classmates how you would approach Exercise above if they needed to use up a pound of Type I tea to make room on the shelf for a new canister.
- If you were to try to make 100 mL of a acid solution using stock solutions at and , respectively, what would the triangular form of the resulting system look like? Explain.
In Exercises -, put each system of linear equations into triangular form and solve the system if possible. Classify each system as consistent independent, consistent dependent, or inconsistent.
Answers
- Consistent independent Solution
- Consistent independent Solution
- Consistent independent Solution
- Consistent independent Solution
- Consistent dependent Solution for all real numbers
- Consistent dependent Solution for all real numbers
- Inconsistent No solution
- Inconsistent No solution
- If is the free variable then the solution is and if is the free variable then the solution is .
- chose the basic buffet and chose the deluxe buffet.
- Mavis needs 20 pounds of $3 per pound coffee and 30 pounds of $8 per pound coffee.
- Skippy needs to invest 6000 in the account and 4000 in the account.
- gallons of the solution and gallons of pure water.
- pounds of Type I, pounds of Type II and pounds of Type III where .
Because triangular form is not unique, we give only one possible answer to that part of the question. Yours may be different and still be correct.
Adapted from Precalculus, 3rd corrected edition, by Carl Stitz and Jeff Zeager (stitz-zeager.com), licensed under CC BY-NC-SA 3.0. Changes were made: reformatted as an accessible XYZ web edition. License: CC-BY-NC-SA-3.0.