Skip to content
Study Hall
Lesson 5 of 6Linear and Non-Linear Relations
Unit 5 · Lesson 5 of 6

Special Lines, xy = k and Inequalities

Graph vertical and horizontal lines, lines of the form x + y = k, x − y = k and ax + by = k, the curve xy = k, and the shaded regions that show linear inequalities.

9 min read10 quick checks11 practice questionsAsk AI about this →

Key things to remember

  1. 1 is a vertical line through with undefined slope; is a horizontal line through with slope .
  2. 2 rearranges to (slope ); rearranges to (slope , -intercept ).
  3. 3For with , and not zero: -intercept (set ), -intercept (set ).
  4. 4 (with ) is non-linear: , a curve with two branches that never touches either axis.
  5. 5Inequality graphs: solid boundary for or , dashed for or ; shade the side where a test point (not on the boundary) makes the inequality true.

You have 24 dollars for a class party. Bags of chips cost 2 dollars and bottles of juice cost 3 dollars. If you buy bags and bottles, you spend dollars. Spending exactly 24 dollars gives the equation , and its graph is a line. But you are allowed to spend less, so every combination with works, and those combinations fill a whole region on one side of the line. Meanwhile, a rectangle with an area of 24 square centimetres can be 1 by 24, 2 by 12, 3 by 8 or 4 by 6: length times width is fixed, , and that graph is not a line at all. This lesson collects these special equations, shows the quickest way to graph each one, and shows how to shade the region for an inequality.

Vertical and horizontal lines: x = k and y = k

The equation says nothing about , so can be anything, but must be : the points , , all work. Together they form a vertical line crossing the -axis at . Its run between any two points is , so its slope is undefined. The equation fixes and lets vary, giving a horizontal line through with slope . Two special cases are worth remembering: is the -axis itself, and is the -axis.

Quick checkTry it before you read on
1
Which point is on the line ?
Quick checkTry it before you read on
2
Which equation describes the -axis?

Sums and differences: x + y = k and x − y = k

The points on are pairs of numbers that add to 10, like 7 right answers and 3 wrong answers on a 10-question quiz: , , . Solving for gives , so every line has slope and crosses both axes at . The points on are pairs whose difference is 3, like and . Solving for : subtract from both sides to get , then multiply by to get . So every line has slope and -intercept . Note the sign: the -intercept of is , not .

−224681012−4−22468100xy(0, 10)(3, 7)(7, 3)(10, 0)(0, −3)(3, 0)(5, 2)(8, 5)x + y = 10pairs that add to 10:(0, 10), (3, 7), (7, 3), (10, 0)y = −x + 10: slope −1,meets both axes at 10x − y = 3pairs whose difference is 3:(3, 0), (5, 2), (8, 5)y = x − 3: slope 1,x-intercept 3, y-intercept −3 (not 3)
Fig 1The line x + y = 10 through pairs that add to 10, (0, 10), (3, 7), (7, 3) and (10, 0), and the line x − y = 3 through pairs whose difference is 3, (0, −3), (3, 0), (5, 2) and (8, 5).
Quick checkTry it before you read on
1
The point is on the line . What is ?
Quick checkTry it before you read on
2
What is the slope of the line ?

ax + by = k: graphing with intercepts

An equation like is in standard form, . The fastest way to graph it uses the two intercepts. On the -axis , so and the -intercept is . On the -axis , so and the -intercept is . Plot both points and draw the line through them. If you want the slope, rearrange: , so . This shortcut needs two different intercepts. If (as in ), both intercepts are the origin, so find a second point by choosing another . If the line is horizontal, and if it is vertical.

Special lines2x + 3y = 6 and its regionxy = 6 is not a line−6−4−2246−6−4−22460xyx = −3: verticaly = 4: horizontalx + y = 2: slope −1x − y = 3: slope 1−6−4−2246−6−4−22460xy(3, 0)(0, 2)solid line: 2x + 3y = 6intercepts (3, 0) and (0, 2)shaded: 2x + 3y ≤ 6test (0, 0): 0 ≤ 6 is true−6−4−2246−6−4−22460xyxy = 6, so y = 6 ÷ x(1, 6), (2, 3), (3, 2), (6, 1)and (−1, −6), (−2, −3) …never touches either axis
Fig 2Left: the lines x = −3, y = 4, x + y = 2 and x − y = 3. Middle: 2x + 3y = 6 through its intercepts, with the region 2x + 3y ≤ 6 shaded. Right: the two branches of xy = 6
Quick checkTry it before you read on
1
What is the -intercept of ? Give the -coordinate.
Quick checkTry it before you read on
2
Why can you not graph from its two intercepts alone?
VideoSetting y = 0 and then x = 0 to find the two intercepts of a line in standard form, then joining them to graph the line.Watch on YouTube

xy = k: a curve, not a line

The points on are pairs that multiply to 6: , , , , and also and . Solving for gives . When doubles, halves, so equal steps in do not give equal changes in : for the -values have first differences and . The relation is non-linear, and its graph is a curve. The value is impossible, because , never 6, so the curve never touches the -axis; in the same way it never touches the -axis. Negative pairs such as also multiply to 6, which gives a second, separate branch. (When is negative, as in , the two branches sit in the other two quadrants.) In a context like a rectangle's length and width, only the positive branch makes sense.

Quick checkTry it before you read on
1
Which point is on the curve ?
Quick checkTry it before you read on
2
On the curve , what is when ? Give a decimal.

Inequalities: shading a region

An inequality such as is true for a whole region of points, not just a line. To graph it: (1) graph the boundary, the line you get by replacing the inequality sign with ; (2) draw it solid if the sign is or (points on the line count) and dashed if it is or (they do not); (3) pick a test point that is not on the line, often , and substitute it; (4) if the test point makes the inequality true, shade its side of the line; if false, shade the other side. For , the test gives , which is true, so you shade the side containing the origin.

InequalityBoundaryTest point resultShade
Solid vertical line x = 2(0, 0): 0 ≥ 2 is falseRight of the line
Dashed horizontal line y = −1(0, 0): 0 < −1 is falseBelow the line
Solid line through (5, 0) and (0, 5)(0, 0): 0 ≤ 5 is trueThe side containing the origin
Dashed line through (2, 0) and (0, −2)(0, 0): 0 > 2 is falseThe side away from the origin
Solid line through (3, 0) and (0, 2)(0, 0): 0 ≥ 6 is falseThe side away from the origin
Graphing five inequalities with a boundary and a test point
x + y ≤ 5x − y > 2−6−4−2246−6−3360xytest (0, 0)−6−4−2246−6−3360xytest (0, 0)solid boundary x + y = 5: ≤ includes the linetest (0, 0): 0 + 0 = 0 ≤ 5 is trueso shade the side that contains (0, 0)dashed boundary x − y = 2: > leaves the line outtest (0, 0): 0 − 0 = 0 > 2 is falseso shade the side away from (0, 0)
Fig 3Left: x + y ≤ 5 has a solid boundary through (5, 0) and (0, 5), and the test point (0, 0) is true, so the origin side is shaded. Right: x − y > 2 has a dashed boundary through (2, 0) and (0, −2), and (0, 0) is false, so the other side is shaded.
When the origin is on the boundary
If the boundary passes through , as does, the origin cannot tell you which side to shade, because it is on the line. Pick a test point clearly off the line instead, such as : for , is false, so shade the side that does not contain .
The test point works for curves too
For positive and , the inequality describes rectangles with area of at least 6. Test : is true, so the region is on and above the positive branch of , the side away from the axes. Test : is false, so the region between the curve and the axes is not included.
Quick checkTry it before you read on
1
How should you draw the boundary line for ?
Quick checkTry it before you read on
2
When graphing , why is a poor test point?
VideoAn Ontario teacher graphs linear inequalities step by step: draw the boundary line, test a point, and shade the side that makes the inequality true.Watch on YouTube

Worked examples

Reveal one step at a time and try to beat it to the next line.

Example 1
Graph using its intercepts, and find its slope.
Example 2
Write in the form , then give its slope, -intercept and -intercept.
Example 3
Chips cost 2 dollars a bag and juice costs 3 dollars a bottle, and you can spend at most 24 dollars. Write the inequality, find the intercepts of its boundary, and decide whether 6 bags and 4 bottles, and 7 bags and 4 bottles, are affordable.
Example 4
A rectangle has an area of 24 cm², so its length and width satisfy . Make a table for , decide whether the relation is linear, and find the width when the length is 5 cm.

Where marks get lost

  • Mixing up and . Remember that is the set of points whose -coordinate is 3, which form a vertical line.
  • Giving the -intercept of as . Rearranged, it is , so the -intercept is .
  • Drawing a solid boundary for or . Points on the line do not satisfy a strict inequality, so the line must be dashed.
  • Using as the test point when the boundary passes through the origin, as does. Pick a point clearly off the line.
  • Joining the points of with a straight line, or connecting its two branches through the origin. It is a curve, and no point has .

Flashcards 8

x = k
y = k
x + y = k
x − y = k
+ 4 more

Practice

1
What does the graph of look like?
2
What is the -intercept of ? Give the -coordinate.
3
What is the -intercept of ? Give the -coordinate.
4
What is the -intercept of ? Give the -coordinate.
5
Which equation's graph is NOT a straight line?
6
How do you graph ?
7
Is a solution of ? Answer yes or no.
8
On the curve , what is when ? Give an exact decimal.
9
Match each equation to its graph.
x = 4
y = 4
x + y = 4
x − y = 4
xy = 4
10
Put these steps in order to graph 2x + y > 4.
  1. 1Draw the boundary through them as a dashed line, because the sign is >
  2. 2Shade the side of the line that does not contain (0, 0)
  3. 3Test (0, 0): 0 > 4 is false
  4. 4Find the boundary's intercepts: (2, 0) and (0, 4)
11
Chips cost 2 dollars a bag and juice 3 dollars a bottle, and you can spend at most 24 dollars. Which purchase is NOT possible?

Spot a mistake on this page? Let us know