Graphing Systems of Linear Inequalities
Determine whether an ordered pair is a solution of a system of linear inequalities
The definition of a system of linear inequalities is very similar to the definition of a system of linear equations.
A system of linear inequalities looks like a system of linear equations, but it has inequalities instead of equations. A system of two linear inequalities is shown here:
To solve a system of linear inequalities, we will find values of the variables that are solutions to both inequalities. We solve the system by using the graphs of each inequality and show the solution as a graph. We will find the region on the plane that contains all ordered pairs that make both inequalities true.
To determine if an ordered pair is a solution to a system of two inequalities, we substitute the values of the variables into each inequality. If the ordered pair makes both inequalities true, it is a solution to the system.
Example. Determine whether the ordered pair is a solution to the system : (a) (b) .
(a) Is the ordered pair a solution? We substitute and into both inequalities.
made both inequalities true. Therefore is a solution to this system.
(b) Is the ordered pair a solution? We substitute and into both inequalities.
made one inequality true, but the other one false. Therefore is not a solution to this system.
For the system , determine whether each ordered pair is a solution.
Is the ordered pair a solution to the system ?
Substitute and into both inequalities and check that both come out true.Is the ordered pair a solution to the system ?
Substitute and into first — if it comes out false, the pair is not a solution.Solve a system of linear inequalities by graphing
The solution to a single linear inequality is the region on one side of the boundary line that contains all the points that make the inequality true. The solution to a system of two linear inequalities is a region that contains the solutions to both inequalities. To find this region, we will graph each inequality separately and then locate the region where they are both true. The solution is always shown as a graph.
Example. How to solve a system of linear inequalities by graphing. Solve the system by graphing: .
Step 1. Graph the first inequality. We graph the boundary line . It is a solid line because the inequality sign is . We choose as a test point. Since is true, is a solution, so we shade in the side of the boundary line that contains .
Step 2. On the same grid, graph the second inequality. We graph the boundary line . It is a dashed line because the inequality sign is . Testing again: since is true, we shade in the side of this boundary line that also contains .
Step 3. The solution is the region where the shading overlaps. The point where the boundary lines intersect, , is not included in the solution, since it is not a solution to . The solution is the region shaded twice, which appears as the darkest region in the graph.
Step 4. Check by choosing a test point. We’ll use .
Check the point in the system : substitute it into and simplify the right side.
, so is trueSubstitute into : .Solve a system of linear inequalities by graphing.
- Graph the first inequality.
- Graph the boundary line.
- Shade in the side of the boundary line where the inequality is true.
- On the same grid, graph the second inequality.
- Graph the boundary line.
- Shade in the side of that boundary line where the inequality is true.
- The solution is the region where the shading overlaps.
- Check by choosing a test point.
Example. Solve the system by graphing: .
Graph by graphing and testing a point. The intercepts are and , and the boundary line will be dashed. We test , which makes the inequality false, so we shade the side that does not contain .
Graph by graphing using the slope and -intercept . The boundary line will be dashed. We test , which makes the inequality true, so we shade the side that contains .
The point where the two lines intersect is not included in the solution, since both boundary lines are dashed. The solution is the area shaded twice — which appears as the darkest shaded region.
Example. Solve the system by graphing: .
Graph by graphing and testing a point. The intercepts are and , and the boundary line will be dashed. We test , which makes the inequality true, so we shade the side that contains .
Graph by graphing and recognizing that it is a horizontal line through . The boundary line will be dashed. We test , which makes the inequality true, so we shade the side that contains .
The point is in the solution, as we already found it to be a solution of each inequality. The point of intersection of the two lines is not included, since both boundary lines are dashed. The solution is the area shaded twice — which appears as the darkest shaded region.
Systems of linear inequalities where the boundary lines are parallel might have no solution. We’ll see this in the next example.
Example. Solve the system by graphing: .
Graph by graphing and testing a point. The intercepts are and , and the boundary line will be solid. We test , which makes the inequality false, so we shade the side that does not contain .
Graph by graphing using the slope and -intercept . The boundary line will be dashed. We test , which makes the inequality true, so we shade the side that contains .
There is no point in both shaded regions, so this system has no solution.
Does the system have a solution?
The boundary lines are parallel, with the same slope ; the shaded regions face away from each other and never overlap.Some systems of linear inequalities where the boundary lines are parallel will have a solution. We’ll see this in the next example.
Example. Solve the system by graphing: .
Graph by graphing using the slope and the intercept . The boundary line will be dashed. We test , which makes the inequality true, so we shade the side that contains .
Graph by graphing and testing a point. The intercepts are and , and the boundary line will be dashed. We choose a test point in the solution and verify that it is a solution to both inequalities. We test , which makes the inequality false, so we shade the side that does not contain .
No point on the boundary lines is included in the solution, since both lines are dashed. The solution is the region that is shaded twice, which is also the solution to alone.
For the system , what is the -intercept of the boundary line ?
Substitute into and solve for .Solve applications of systems of inequalities
The first thing we’ll need to do to solve applications of systems of inequalities is to translate each condition into an inequality. Then we graph the system, as we did above, to see the region that contains all the solutions. Many situations will be realistic only if both variables are positive, so we add inequalities to the system as additional requirements.
Example. Christy sells photographs at a booth at a street fair. At the start of the day, she wants to display at least 25 photos. Each small photo she displays costs her $4 and each large photo costs her $10, and she doesn’t want to spend more than $200 on photos to display.
(a) Write a system of inequalities to model this situation.
Let the number of small photos and the number of large photos. She wants to have at least 25 photos, so the number of small plus the number of large should be at least 25: . Each small photo costs $4 and each large photo costs $10, and the total must be no more than $200: . The number of small and the number of large photos must each be greater than or equal to zero: , . We have the system of inequalities:
(b) Graph the system. Since and , all solutions will be in the first quadrant, so our graph shows only Quadrant I. To graph , graph as a solid line; testing makes the inequality false, so we shade the side that does not contain . To graph , graph as a solid line; testing makes the inequality true, so we shade the side that contains .
The solution of the system is the region of the graph that is shaded the darkest. The boundary line sections that border the darkly shaded section are included in the solution, as are the points on the -axis from to .
(c) Could she display 10 small and 20 large photos? We look at the graph to see whether the point is in the solution region. It is not, so Christy would not display 10 small and 20 large photos.
(d) Could she display 20 small and 10 large photos? We look at the graph to see whether the point is in the solution region. It is, so Christy could choose to display 20 small and 10 large photos.
When we use variables other than and to define an unknown quantity, we must change the names of the axes of the graph as well.
Example. Omar needs to eat at least 800 calories before going to his team practice. All he wants is hamburgers and cookies, and he doesn’t want to spend more than $5. At the hamburger restaurant near his college, each hamburger has 240 calories and costs $1.40. Each cookie has 160 calories and costs $0.50.
(a) Write a system of inequalities to model this situation.
Let the number of hamburgers and the number of cookies. The calories from the hamburgers, at 240 calories each, plus the calories from the cookies, at 160 calories each, must be more than 800: . The amount spent on hamburgers, at $1.40 each, plus the amount spent on cookies, at $0.50 each, must be no more than $5.00: . The number of hamburgers and the number of cookies must each be greater than or equal to zero: , . We have the system of inequalities:
(b) Graph the system. Since and , our graph shows only Quadrant I. To graph , graph as a solid line; testing makes the inequality false, so we shade the side that does not contain . To graph , graph as a solid line; testing makes the inequality true, so we shade the side that contains .
The solution of the system is the region of the graph that is shaded the darkest.
(c) Could he eat 3 hamburgers and 1 cookie? We look at the graph to see whether the point , three hamburgers and two cookies, is in the solution region. It is, so Omar might choose to eat 3 hamburgers and 1 cookie.
(d) Could he eat 2 hamburgers and 4 cookies? We look at the graph to see whether the point is in the solution region. It is, so Omar might choose to eat 2 hamburgers and 4 cookies.
Tenison needs to eat at least an extra 1,000 calories a day to prepare for running a marathon. He has only $25 to spend on the extra food he needs and will spend it on $0.75 donuts, which have 360 calories each, and $2 energy drinks, which have 110 calories each.
Let be the number of donuts and be the number of energy drinks Tenison buys. Write an inequality that models needing at least 1,000 extra calories, given each donut has 360 calories and each energy drink has 110 calories.
Multiply calories per item by the number of items, add the two, and use 'at least' to choose the inequality symbol.Tenison's system is , where is the number of donuts and is the number of energy drinks. Can he buy 8 donuts and 4 energy drinks and satisfy both his caloric needs and his budget?
Check both inequalities: , and .Key terms
system of linear inequalities — two or more linear inequalities grouped together. solutions of a system of linear inequalities — the values of the variables that make all the inequalities in the system true, shown as a shaded region in the coordinate system that includes all the points whose ordered pairs make the inequalities true.
This section is adapted from Intermediate Algebra 2e, Section 4.7: Graphing Systems of Linear Inequalities by Lynn Marecek, MaryAnne Anthony-Smith, and Andrea Honeycutt Mathis, © OpenStax, licensed under CC BY-NC-SA 4.0. Access the original for free at openstax.org. Changes: recreated the coordinate-plane figures as accessible interactive graphs; omitted the Be Prepared quiz, Media links, Self Check, and Section Exercises; and converted the source Try Its into interactive exercises with instant feedback.