πŸ“˜ CodingMarble Learn

Solving Equations and Inequalities Graphically

The graph of an equation is the set of all its solutions. To solve f(x) = g(x), draw y = f(x) and y = g(x): the x-coordinates where they cross are the solutions. f(x) > g(x) is true for the x-values where the graph of f is above the graph of g. A linear inequality in two variables, like y > 2x + 1, is solved by a half-plane: draw the boundary line (dashed for < or >, solid for ≀ or β‰₯) and shade the side that a test point says is true. A system of inequalities is solved by the overlap of the shaded half-planes.

🎬 Step-by-step story

  1. Every point on the line y = 2x βˆ’ 1 is a solution of that equation. Points rain down and all land on the line. The graph is the set of all solutions.
  2. To solve 2x βˆ’ 1 = βˆ’x + 2, draw both lines. They cross at x = 1. That x is the answer.
  3. Where is 2x βˆ’ 1 > βˆ’x + 2? Where the blue line is above the green line: for x > 1. The yellow strip on the x-axis shows it.
  4. In two variables, y > x + 1 is a whole region. Draw the boundary dashed (strict >), test (0, 0): 0 > 1 is false, so shade the other side.
  5. A system: y > x + 1 and y ≀ βˆ’x + 3. Shade each half-plane. The answer is where both shadings overlap.
  6. Try it: change the slope, intercept and sign, then move a test point and see if it is a solution.

Tip: drag the 3D scene to turn it. Use two fingers to zoom.

πŸ€” Common doubts, cleared

Why is a whole line the answer to one equation?

An equation in x and y has many solution pairs. Every pair is a point, and together they form the line.

Why do we read only x at the crossing point?

f(x) = g(x) asks which x makes both sides equal. At the crossing both have the same y, and the x there is the answer.

How do I know which side of the crossing is the answer for f > g?

Look at which graph is on top. The yellow strip marks the x-values where f is above g.

Why dashed for > but solid for β‰₯?

Points on the line make both sides equal. For strict > they do not count, so the line is drawn dashed.

Why not test any point I like?

Any point not on the line works. (0, 0) is easiest, unless the line passes through it.

What is the answer when two shadings overlap?

Only the overlap region satisfies both inequalities. The orange area in the 3D is the answer.

The graph is the solution set

Every point (x, y) on the graph of an equation in two variables makes the equation true. Every point off the graph makes it false. So the graph is a picture of all the solutions.

Example: (2, 3) is on y = 2x βˆ’ 1 because 2 Γ— 2 βˆ’ 1 = 3. (2, 4) is not, because 3 β‰  4.

Solving f(x) = g(x) with intersections

To solve an equation like f(x) = g(x):

  1. Draw y = f(x) and y = g(x) on the same axes.
  2. Find where the graphs intersect (cross).
  3. The x-coordinate of each intersection is a solution.

This works for any kinds of functions β€” linear, quadratic, exponential, absolute value β€” even when algebra is hard. With a graphing tool or a table of values you can find the answer to any accuracy (successive approximation).

Special case: to solve f(x) = 0, look where y = f(x) crosses the x-axis (y = 0).

Number of solutions = number of crossing points. Parallel lines never cross: no solution.

Solving f(x) > g(x) graphically

f(x) > g(x) is true wherever the graph of f is above the graph of g. f(x) < g(x) is true where f is below.

Example: 2x βˆ’ 1 > βˆ’x + 2. The lines meet at x = 1. To the right, the line y = 2x βˆ’ 1 is higher, so the answer is x > 1. Check with algebra: 3x > 3, so x > 1. βœ”

Linear inequalities in two variables: half-planes

An inequality like y > 2x + 1 or 3x + 2y ≀ 12 is true for a whole region called a half-plane.

  1. Boundary: draw the line you get with '='. Use a dashed line for < or > (points on it are not solutions) and a solid line for ≀ or β‰₯.
  2. Test point: pick a point not on the line, usually (0, 0). Put it in the inequality.
  3. If it is true, shade the side with the test point. If false, shade the other side.

Shortcut when the inequality is written as y > mx + c: shade above the line; for y < mx + c, shade below.

Systems of linear inequalities

A system has two or more inequalities that must all be true together. Shade each one; the overlap is the solution set (also called the feasible region).

Corner points of the region are found by solving pairs of boundary equations. If the shadings never overlap, the system has no solution. This idea is the base of linear programming, where we find the best point inside the region.

Try it: graph paper check

On graph paper draw y = x + 1 (dashed) and y = βˆ’x + 3 (solid). Mark five points: (0, 0), (0, 2), (1, 2), (βˆ’1, 3), (2, 0). Before testing, predict which lie in the region y > x + 1 and y ≀ βˆ’x + 3. Then test each by substituting. Use the 3D sliders in the last step to check.

Key formulas and definitions

Worked examples

1. Is (3, 5) a solution of y = 2x βˆ’ 1? Is (1, 2)?

For (3, 5): 2 Γ— 3 βˆ’ 1 = 5 βœ”, so it lies on the graph and is a solution. For (1, 2): 2 Γ— 1 βˆ’ 1 = 1 β‰  2, so it is not on the graph.

2. Solve 2x βˆ’ 1 = βˆ’x + 2 graphically and check.

Draw y = 2x βˆ’ 1 (through (0, βˆ’1) and (1, 1)) and y = βˆ’x + 2 (through (0, 2) and (2, 0)). They cross at (1, 1), so x = 1. Check: 2(1) βˆ’ 1 = 1 and βˆ’1 + 2 = 1 βœ”.

3. Using the same graphs, solve 2x βˆ’ 1 ≀ βˆ’x + 2.

We need where the blue line y = 2x βˆ’ 1 is on or below y = βˆ’x + 2. Left of the crossing at x = 1 it is lower, and at x = 1 they are equal. Answer: x ≀ 1.

4. Shade y β‰₯ βˆ’2x + 4. Is (1, 1) a solution?

Boundary y = βˆ’2x + 4 is solid (β‰₯) through (0, 4) and (2, 0). Test (0, 0): 0 β‰₯ 4 is false, so shade the side away from the origin (above the line). For (1, 1): 1 β‰₯ βˆ’2 + 4 = 2? False, so (1, 1) is not a solution.

5. Graph 3x + 2y < 12 and say which side to shade.

Boundary 3x + 2y = 12 meets the axes at (4, 0) and (0, 6); draw it dashed (<). Test (0, 0): 0 < 12 true, so shade the side containing the origin (below the line).

6. Find the corner of the region y > x + 1 and y ≀ βˆ’x + 3, and give one point inside it.

Corner: x + 1 = βˆ’x + 3 β†’ 2x = 2 β†’ x = 1, y = 2. The corner (1, 2) is on the dashed line, so it is not included. Try (0, 2): 2 > 1 βœ” and 2 ≀ 3 βœ”, so (0, 2) is inside.

7. Solve |x| = 0.5x + 3 graphically.

Draw the V-shape y = |x| and the line y = 0.5x + 3. Right branch: x = 0.5x + 3 β†’ x = 6 (point (6, 6)). Left branch: βˆ’x = 0.5x + 3 β†’ x = βˆ’2 (point (βˆ’2, 2)). Two crossings, so x = βˆ’2 or x = 6.

Common mistakes

Practice quiz

1. To solve f(x) = g(x) from graphs, you read…
2. The boundary of y < 3x βˆ’ 2 is drawn…
3. For y β‰₯ x + 2, the test point (0, 0) gives 0 β‰₯ 2, which is false. So you shade…
4. The solution of a system of inequalities is…
5. Two parallel lines y = 2x + 1 and y = 2x βˆ’ 3 show that 2x + 1 = 2x βˆ’ 3 has…

Practice: answer these yourself

Type or choose your answer, then press Check. Use a hint if you are stuck; the full solution appears after you answer.

Frequently asked questions

How do you solve an equation graphically?

Draw both sides as separate graphs on the same axes. The x-coordinates of the points where they intersect are the solutions.

How do you know which side to shade for an inequality?

Pick a test point not on the boundary, like (0, 0). If it makes the inequality true, shade its side; if false, shade the other side.

When is the boundary line dashed?

When the sign is < or >, because points on the line are not solutions. Use a solid line for ≀ or β‰₯.

Where this is taught

USA (Common Core, NGSS, AP)Grade 11Polynomial, rational and radical relationships

Learn first

Learn next

Related lessons

All Maths lessons