Skip to the page
Home Campus
Start free

Gradient and Intercepts of ax + by = c

Write ax+by=cax + by = c in the form y=mx+cy = mx + c to find its gradient and yy-intercept; find an unknown number in the equation; match equations to lines; find the triangle a line cuts off with the axes; and read a real setting.

Before you start

  • In lesson 2.2 you drew the graph of ax+by=cax + by = c, a straight line, from its intercepts: put y=0y = 0 for the xx-intercept and x=0x = 0 for the yy-intercept.
  • In Secondary 1 a straight line was written y=ax+by = ax + b, with gradient aa (vertical changehorizontal change).\frac{\text{vertical change}}{\text{horizontal change}}\text{).} In this chapter aa and bb are already the numbers in ax+by=cax + by = c, so that form is written y=mx+cy = mx + c: the gradient is mm and the line crosses the yy-axis at (0,c)(0, c). This cc is a different number from the cc in ax+by=cax + by = c.

The Gradient and the y-Intercept

From ax + by = c to y = mx + c

To find the gradient and the yy-intercept of a line ax+by=cax + by = c (with b≠0b \ne 0), make yy the subject and write the result in the form y=mx+cy = mx + c.

Then the gradient is mm, the number multiplying xx, and the yy-intercept is the number on its own.

The yy-intercept is not the number on the right of ax+by=cax + by = c: in 2x+3y=122x + 3y = 12 it is 44, not 1212.

Example 1: Rewriting in the form y = mx + c

Find the gradient and the yy-intercept of (a) 2x+3y=122x + 3y = 12, (b) 5x−2y=65x - 2y = 6.

Solution

(a) Subtract 2x2x: 3y=−2x+123y = -2x + 12. Divide every term by 33: y=−23x+4y = -\frac{2}{3}x + 4. So m=−23m = -\frac{2}{3}, and the yy-intercept is 44.

Check on the graph drawn in lesson 2.2, Example 2: from (0,4)(0, 4) to (6,0)(6, 0) the line goes 66 across and 44 down, so its gradient is −46=−23\frac{-4}{6} = -\frac{2}{3}.

The line 2x + 3y = 12 with a step from (0, 4): 6 across to (6, 4), then 4 down to (6, 0)xy6−4−2−112345678−2−1123456O2x + 3y = 12(0, 4)(6, 0)

(b) Subtract 5x5x: −2y=−5x+6-2y = -5x + 6. Divide every term by −2-2: y=52x−3y = \frac{5}{2}x - 3. So m=52m = \frac{5}{2}, and the yy-intercept is −3-3.

Check with two points: x=0x = 0 gives −2y=6-2y = 6, y=−3y = -3; x=2x = 2 gives 10−2y=610 - 2y = 6, y=2y = 2. From (0,−3)(0, -3) to (2,2)(2, 2): 55 up for 22 across, gradient 52\frac{5}{2}.

(a) Gradient −23-\frac{2}{3}, yy-intercept 44. (b) Gradient 52\frac{5}{2}, yy-intercept −3-3.

An unknown number in the equation can be found from one more fact about the line: a point on it (substitute its coordinates) or its gradient (write the equation in the form y=mx+cy = mx + c and compare).

Example 2: An unknown coefficient

(a) The line ax+2y=8ax + 2y = 8 passes through the point (2,1)(2, 1). Find aa, the gradient of the line, and its xx-intercept. (b) The line 4x+by=64x + by = 6 has gradient 22. Find bb.

Solution

(a) The point is on the line, so its coordinates make the equation true: a(2)+2(1)=8a(2) + 2(1) = 8, so 2a+2=82a + 2 = 8, 2a=62a = 6 and a=3a = 3.

The line is 3x+2y=83x + 2y = 8. Make yy the subject: 2y=−3x+82y = -3x + 8, so y=−32x+4y = -\frac{3}{2}x + 4. The gradient is −32-\frac{3}{2}.

xx-intercept: put y=0y = 0. 3x=83x = 8, so x=83=223x = \frac{8}{3} = 2\frac{2}{3}.

Check (2,1)(2, 1): 3(2)+2(1)=6+2=8.3(2) + 2(1) = 6 + 2 = 8\text{.}

(b) Make yy the subject: by=−4x+6by = -4x + 6, so y=−4bx+6by = -\frac{4}{b}x + \frac{6}{b}. The gradient is −4b-\frac{4}{b}, so −4b=2-\frac{4}{b} = 2.

Multiply both sides by bb: −4=2b-4 = 2b, so b=−2b = -2.

Check: the line is 4x−2y=64x - 2y = 6, so −2y=−4x+6-2y = -4x + 6 and y=2x−3y = 2x - 3, whose gradient is 22.

(a) a=3a = 3; the gradient is −32-\frac{3}{2} and the xx-intercept is 2232\frac{2}{3}. (b) b=−2b = -2.

Matching Equations to Graphs

To tell which line belongs to which equation, find each equation's intercepts and the sign of its gradient (up from left to right: positive; down: negative), and compare them with the drawing.

Example 3: Which line is which?

The lines AA, BB and CC are the graphs of x+2y=4x + 2y = 4, 2x−y=42x - y = 4 and 2x+y=−22x + y = -2. Match each equation to its line.

Three lines: A rises from (−0.5, −5) to (4, 4); B falls from (−4, 4) to (5, −0.5); C falls steeply from (−3, 4) to (1, −4)xy−4−3−2−112345−5−4−3−2−11234OABC

Solution

x+2y=4x + 2y = 4: intercepts 44 and 22; y=−12x+2y = -\frac{1}{2}x + 2, gradient negative.

2x−y=42x - y = 4: intercepts 22 and −4-4; y=2x−4y = 2x - 4, gradient positive.

2x+y=−22x + y = -2: intercepts −1-1 and −2-2; y=−2x−2y = -2x - 2, gradient negative.

Only AA goes up from left to right, so AA is 2x−y=42x - y = 4; it crosses the xx-axis at 22.

BB crosses the yy-axis at 22 and the xx-axis at 44: x+2y=4x + 2y = 4.

CC crosses the xx-axis at −1-1 and the yy-axis at −2-2: 2x+y=−22x + y = -2.

AA is 2x−y=42x - y = 4, BB is x+2y=4x + 2y = 4 and CC is 2x+y=−22x + y = -2.

The Triangle Cut Off by a Line

A line that crosses both axes away from the origin cuts off a right-angled triangle with the axes. Its two shorter sides lie along the axes, and their lengths are the sizes of the two intercepts.

Example 4: Area of the triangle

The line 3x+4y=243x + 4y = 24 meets the xx-axis at AA and the yy-axis at BB. Find the coordinates of AA and BB, and the area of triangle OABOAB, where OO is the origin.

Solution

AA: put y=0y = 0. 3x=243x = 24, so x=8x = 8: A(8,0)A(8, 0).

BB: put x=0x = 0. 4y=244y = 24, so y=6y = 6: B(0,6)B(0, 6).

The line 3x + 4y = 24 meeting the axes at A(8, 0) and B(0, 6); the right-angled triangle OAB is shadedxy−1123456789−11234567O3x + 4y = 24A(8, 0)B(0, 6)

The triangle has a right angle at OO. Its base OAOA is 88 units and its height OBOB is 66 units.

Area =12×8×6=24= \frac{1}{2} \times 8 \times 6 = 24 square units.

A(8,0)A(8, 0), B(0,6)B(0, 6), and the area of triangle OABOAB is 2424 square units.

A Graph from a Real Setting

In a real setting the intercepts and the gradient have meanings. An intercept is the amount of one thing when there is none of the other. The gradient says how much one amount changes as the other goes up.

Example 5: Apples and pears

Mei Ling spends exactly $2424 on xx apples at $22 each and yy pears at $33 each. (a) Write an equation connecting xx and yy. (b) Draw its graph. (c) Use the graph to list the numbers of apples and pears she can buy, with at least one of each. (d) Write the equation in the form y=mx+cy = mx + c. What do its gradient and its yy-intercept tell you?

Solution

(a) The apples cost $2x2x and the pears $3y3y: 2x+3y=242x + 3y = 24.

(b) Intercepts: y=0y = 0 gives x=12x = 12; x=0x = 0 gives y=8y = 8. Neither xx nor yy can be negative, so draw the line only from (0,8)(0, 8) to (12,0)(12, 0).

Only whole numbers of fruit make sense, so the useful points are the points of the line with whole-number coordinates. The line is drawn dashed to show that the points between them do not count.

The line 2x + 3y = 24 from (0, 8) to (12, 0), dashed, with its whole-number points (0, 8), (3, 6), (6, 4), (9, 2) and (12, 0) markedApples, xPears, y12345678910111212345678O2x + 3y = 24(0, 8)(3, 6)(6, 4)(9, 2)(12, 0)

(c) The line passes exactly through grid points at x=0,3,6,9,12x = 0, 3, 6, 9, 12. With at least one of each fruit, (0,8)(0, 8) and (12,0)(12, 0) are left out.

Check (9,2)(9, 2): 2(9)+3(2)=18+6=24.2(9) + 3(2) = 18 + 6 = 24\text{.}

(d) 3y=−2x+243y = -2x + 24, so y=−23x+8y = -\frac{2}{3}x + 8. The yy-intercept 88 is the number of pears she can buy with no apples: 8 pears cost $2424.

The gradient −23-\frac{2}{3} says that for every 33 more apples she buys 22 fewer pears: 3 apples cost $66, the same as 2 pears. On the graph, each whole-number point is 33 across and 22 down from the one before.

(a) 2x+3y=242x + 3y = 24. (c) 3 apples and 6 pears, 6 apples and 4 pears, or 9 apples and 2 pears. (d) y=−23x+8y = -\frac{2}{3}x + 8: with no apples she buys 8 pears, and every 3 more apples means 2 fewer pears.

Common Mistakes

  • Reading the yy-intercept off ax+by=cax + by = c. In 2x+3y=122x + 3y = 12 the yy-intercept is 44, not 1212. Make yy the subject first.
  • Losing a sign when rearranging. From 5x−2y=65x - 2y = 6: −2y=−5x+6-2y = -5x + 6, and dividing every term by −2-2 gives y=52x−3y = \frac{5}{2}x - 3.
  • Taking the sign of the gradient from the signs in ax+by=cax + by = c. In 2x+3y=122x + 3y = 12 both numbers are positive, but the gradient is −23-\frac{2}{3}: the line goes down from left to right.
  • A negative length. An intercept may be negative, but a side of a triangle never is: for B(0,−6)B(0, -6), OB=6OB = 6 units.

Practice Questions

Work each question on paper before you open its solution. The questions get harder as you go.

Question 1

Find the gradient and the yy-intercept of (a) 4x+2y=104x + 2y = 10, (b) 3x−5y=153x - 5y = 15, (c) x+3y=2x + 3y = 2.

ShowHide solution

(a) 2y=−4x+102y = -4x + 10, so y=−2x+5y = -2x + 5: gradient −2-2, yy-intercept 55.

(b) −5y=−3x+15-5y = -3x + 15. Divide every term by −5-5: y=35x−3y = \frac{3}{5}x - 3: gradient 35\frac{3}{5}, yy-intercept −3-3.

(c) 3y=−x+23y = -x + 2, so y=−13x+23y = -\frac{1}{3}x + \frac{2}{3}: gradient −13-\frac{1}{3}, yy-intercept 23\frac{2}{3}.

(a) −2-2 and 55 (b) 35\frac{3}{5} and −3-3 (c) −13-\frac{1}{3} and 23\frac{2}{3}

Question 2

Find the gradient of the line 4x−3y=124x - 3y = 12 (a) by writing the equation in the form y=mx+cy = mx + c, (b) by drawing the line through its intercepts and counting the step from one intercept to the other.

ShowHide solution

(a) −3y=−4x+12-3y = -4x + 12. Divide every term by −3-3: y=43x−4y = \frac{4}{3}x - 4. The gradient is 43\frac{4}{3}.

(b) y=0y = 0 gives 4x=124x = 12, x=3x = 3: the point (3,0)(3, 0). x=0x = 0 gives −3y=12-3y = 12, y=−4y = -4: the point (0,−4)(0, -4).

The line 4x − 3y = 12 through (0, −4) and (3, 0), with a step from (0, −4): 3 across to (3, −4), then 4 up to (3, 0)xy34−2−1123456−6−5−4−3−2−11234O4x − 3y = 12(0, −4)(3, 0)

From (0,−4)(0, -4) to (3,0)(3, 0) the line goes 33 across and 44 up, so its gradient is 43\frac{4}{3}. The two ways agree.

The gradient is 43\frac{4}{3}.

Question 3

The line 5x+by=115x + by = 11 passes through (3,−2)(3, -2). Find bb and the gradient of the line.

ShowHide solution

5(3)+b(−2)=115(3) + b(-2) = 11, so 15−2b=1115 - 2b = 11, −2b=−4-2b = -4 and b=2b = 2.

The line is 5x+2y=115x + 2y = 11: 2y=−5x+112y = -5x + 11, y=−52x+112.y = -\frac{5}{2}x + \frac{11}{2}\text{.} The gradient is −52-\frac{5}{2}.

Check: 5(3)+2(−2)=15−4=11.5(3) + 2(-2) = 15 - 4 = 11\text{.}

b=2b = 2; the gradient is −52-\frac{5}{2}.

Question 4

The line 2x+3y=k2x + 3y = k passes through (−3,4)(-3, 4). Find kk and the xx-intercept of the line.

ShowHide solution

k=2(−3)+3(4)=−6+12=6.k = 2(-3) + 3(4) = -6 + 12 = 6\text{.} The line is 2x+3y=62x + 3y = 6.

xx-intercept: y=0y = 0 gives 2x=62x = 6, so x=3x = 3.

k=6k = 6; the xx-intercept is 33.

Question 5

The line ax+3y=12ax + 3y = 12 has gradient −2-2. Find aa and the xx-intercept of the line.

ShowHide solution

3y=−ax+123y = -ax + 12, so y=−a3x+4y = -\frac{a}{3}x + 4. The gradient is −a3-\frac{a}{3}, so −a3=−2-\frac{a}{3} = -2 and a=6a = 6.

The line is 6x+3y=126x + 3y = 12. xx-intercept: y=0y = 0 gives 6x=126x = 12, so x=2x = 2.

Check: 3y=−6x+123y = -6x + 12 gives y=−2x+4y = -2x + 4, whose gradient is −2-2.

a=6a = 6; the xx-intercept is 22.

Question 6

The lines PP, QQ and RR are the graphs of x+y=3x + y = 3, x−y=3x - y = 3 and x+y=−3x + y = -3. Match each equation to its line.

Three lines: P rises from (−2, −5) to (5, 2); Q falls from (−2, 5) to (5, −2); R falls from (−5, 2) to (2, −5)xy−5−4−3−2−112345−5−4−3−2−112345OPQR
ShowHide solution

x−y=3x - y = 3 is y=x−3y = x - 3: gradient 11, positive. Only PP rises, so PP is x−y=3x - y = 3 (it crosses the xx-axis at 33 and the yy-axis at −3-3).

x+y=3x + y = 3: intercepts 33 and 33. QQ crosses both axes at 33.

x+y=−3x + y = -3: intercepts −3-3 and −3-3. RR crosses both axes at −3-3.

PP is x−y=3x - y = 3, QQ is x+y=3x + y = 3 and RR is x+y=−3x + y = -3.

Question 7

The line 2x−y=62x - y = 6 meets the xx-axis at AA and the yy-axis at BB. Find the area of triangle OABOAB.

ShowHide solution

AA: y=0y = 0 gives 2x=62x = 6, x=3x = 3: A(3,0)A(3, 0). BB: x=0x = 0 gives −y=6-y = 6, y=−6y = -6: B(0,−6)B(0, -6).

The line 2x − y = 6 meeting the axes at A(3, 0) and B(0, −6); triangle OAB, below the x-axis, is shadedxy−112345−7−6−5−4−3−2−112O2x − y = 6A(3, 0)B(0, −6)

The lengths are OA=3OA = 3 units and OB=6OB = 6 units: a length is never negative, although BB is below the xx-axis.

Area =12×3×6=9= \frac{1}{2} \times 3 \times 6 = 9 square units.

The area of triangle OABOAB is 99 square units.

Question 8

The line 2x+y=k2x + y = k, where k>0k > 0, cuts off a triangle of area 1616 square units with the axes. Find kk.

ShowHide solution

y=0y = 0 gives 2x=k2x = k, so the xx-intercept is k2\frac{k}{2}. x=0x = 0 gives y=ky = k, so the yy-intercept is kk.

Since k>0k > 0, both intercepts are positive, and they are the lengths of the two shorter sides of the triangle. Area =12×k2×k=k24.= \frac{1}{2} \times \frac{k}{2} \times k = \frac{k^{2}}{4}\text{.}

k24=16\frac{k^{2}}{4} = 16, so k2=64k^{2} = 64. Since k>0k > 0, k=8k = 8.

Check: 2x+y=82x + y = 8 meets the axes at (4,0)(4, 0) and (0,8)(0, 8), and 12×4×8=16\frac{1}{2} \times 4 \times 8 = 16.

k=8k = 8

Question 9

A class spends exactly $4848 on xx plates of chicken rice at $44 each and yy bowls of noodles at $33 each. (a) Write an equation in xx and yy and draw its graph. (b) If they buy 6 plates of chicken rice, how many bowls of noodles do they buy? (c) List every possible order with at least one of each.

ShowHide solution

(a) 4x+3y=484x + 3y = 48. Intercepts: y=0y = 0 gives x=12x = 12; x=0x = 0 gives y=16y = 16. Draw from (0,16)(0, 16) to (12,0)(12, 0), dashed, since only whole numbers count.

The line 4x + 3y = 48 from (0, 16) to (12, 0), dashed, with its whole-number points (0, 16), (3, 12), (6, 8), (9, 4) and (12, 0), and a guide line from x = 6 up to (6, 8)Chicken rice, xNoodles, y12345678910111212345678910111213141516O4x + 3y = 48(3, 12)(6, 8)(9, 4)

(b) Up from x=6x = 6 to the line, then across: y=8y = 8. Check: 4(6)+3(8)=24+24=48.4(6) + 3(8) = 24 + 24 = 48\text{.}

(c) y=48−4x3y = \frac{48 - 4x}{3} is a whole number when xx is a multiple of 33. With xx and yy at least 11: x=3,6,9x = 3, 6, 9.

(a) 4x+3y=484x + 3y = 48 (b) 8 bowls of noodles (c) 3 plates and 12 bowls, 6 plates and 8 bowls, or 9 plates and 4 bowls.

Question 10

A hall is set up for exactly 240240 guests, with xx long tables that seat 88 each and yy round tables that seat 1010 each. (a) Show that 4x+5y=1204x + 5y = 120. (b) Write the equation in the form y=mx+cy = mx + c. (c) What does the yy-intercept tell you? (d) What does the gradient tell you? (e) If 1515 long tables are used, how many round tables are needed?

ShowHide solution

(a) The long tables seat 8x8x guests and the round tables 10y10y, so 8x+10y=2408x + 10y = 240. Divide every term by 22: 4x+5y=1204x + 5y = 120.

(b) 5y=−4x+1205y = -4x + 120. Divide every term by 55: y=−45x+24y = -\frac{4}{5}x + 24.

(c) The yy-intercept is 2424: with no long tables, 2424 round tables are needed (24×10=24024 \times 10 = 240).

(d) The gradient is −45-\frac{4}{5}: for every 55 more long tables, 44 fewer round tables are needed. Five long tables seat 4040 guests, the same as four round tables.

(e) x=15x = 15: y=−45(15)+24=−12+24=12.y = -\frac{4}{5}(15) + 24 = -12 + 24 = 12\text{.} Check: 8(15)+10(12)=120+120=240.8(15) + 10(12) = 120 + 120 = 240\text{.}

(b) y=−45x+24y = -\frac{4}{5}x + 24 (c) With no long tables, 24 round tables are needed. (d) Every 5 more long tables means 4 fewer round tables. (e) 12 round tables

Key Points

  • To find the gradient and the yy-intercept of ax+by=cax + by = c (with b≠0b \ne 0), make yy the subject and write it as y=mx+cy = mx + c: the gradient is mm and the yy-intercept is the number on its own.
  • The yy-intercept is not the number on the right of ax+by=cax + by = c: in 2x+3y=122x + 3y = 12 it is 44, not 1212.
  • An unknown number in the equation: if a point is on the line, substitute its coordinates; if the gradient is given, write y=mx+cy = mx + c and compare.
  • To match equations to lines, compare the intercepts and the sign of the gradient (up from left to right: positive; down: negative).
  • A line crossing both axes away from the origin cuts off a right-angled triangle; its area is 12×\frac{1}{2} \times (size of xx-intercept) ×\times (size of yy-intercept).
  • In a real setting, an intercept is the amount of one thing when there is none of the other, and the gradient says how much one amount changes as the other goes up.

‹ 2.2 Graphs of Linear Equations in Two Variables 2.4 Horizontal and Vertical Lines ›

All Secondary 2 (Grade 8) lessons

Home Campus has lessons, practice questions with worked solutions and worksheets for Primary 3 to Secondary 1. Register free to practise and keep track of progress.

This lesson follows the Singapore Secondary 2 syllabus and was checked question by question before it was published. Spotted a mistake? Tell us.