Vertex Learn

Straight-line graphs, gradient and rate of change

What this lesson covers

  • A pattern, a table, an equation and a graph can all describe the same relationship.
  • The gradient of a straight-line graph is its rate of change: how much y changes for each one unit of x.
Key idea

One relationship, four views

  • A pattern, a table, an equation and a graph.
  • All four can describe exactly the same relationship.
  • Year 10 drew the lines. Now we explain them.
ViewShowsMatchsticks
Patternthe shapessquares in a row
Tablethe numbers4, 7, 10, 13
Equationthe ruley = 3n + 1
Graphthe shapea straight line
Worked example

A matchstick pattern

  • Picture a row of squares made from matchsticks.
  • Count the sticks: 4, 7, 10, 13.
  • Up by 3 every time. A constant difference means linear.
Squares, nMatchsticksChange
14
27+3
310+3
413+3
Key idea

Try it: the matchstick rule

Worked example

Explaining the rule, not just finding it

  • Each new square shares a side, so needs only 3 new sticks.
  • Step back to zero squares: 4 − 3 = 1 stick.
  • So y = 3n + 1. Check: 3 × 4 + 1 = 13.
QuestionReasoningGives
Why the 3?each square adds 3 sticksthe 3n
Why the + 1?step back once: 4 − 3term zero is 1
Imagine the rowthe first left-hand stickstarts the row
Ruley = 3n + 1check n = 4: 13
Worked example

Running the rule backwards

  • Which pattern uses 64 sticks? Solve 3n + 1 = 64.
  • n = 21, and substituting back gives 64.
  • Fifty sticks would need a third of a square. Impossible.
QuestionWorkingAnswer
Uses 64 sticks?3n + 1 = 64, so 3n = 63n = 21
Check3 × 21 + 164, correct
Uses 50 sticks?3n + 1 = 50, so 3n = 49n = 16⅓
Reasonn must be wholeso no pattern uses 50
Worked example

From the table to the graph

  • Each row of the table becomes one point.
  • Same climb each step, so the points line up.
  • The line crosses the y-axis at 1. That is c.
From the table to the graph
Key idea

Why the difference is the gradient

  • Rise over run between any two points.
  • 12 up for 4 across is 3, the same as the table.
  • The difference is the rise for a run of exactly 1.
BetweenRise over runGradient
(1, 4) and (5, 16)(16 − 4) ÷ (5 − 1)12 ÷ 4 = 3
(2, 7) and (3, 10)3 ÷ 13
A run of 1the rise is the differencesame number
Sodifference = gradientm = 3
Key idea

Graphing calculator

Worked example

When x jumps by more than 1

  • Here x goes up in twos, and y goes up by 6.
  • That is 6 for every 2 across, so m = 3, not 6.
  • At x = 0, y = 5. So y = 3x + 5.
xyChange
05
211+6 for +2 across
417+6 for +2 across
623m = 6 ÷ 2 = 3
Worked example

A gradient with units

  • 2 km costs $10. 6 km costs $22.
  • Rise $12, run 4 km: $3 per km.
  • Units of a gradient: y units per one x unit.
A gradient with units
Worked example

What the intercept means

  • Back 2 km from $10, taking $3 each: $4.
  • The gradient: each extra km adds $3.
  • The intercept: $4 is charged before the taxi moves.
PartValueMeaning
Gradient$12 ÷ 4 km$3 per km
Its unitsy units per x unitdollars per km
Intercept10 − 2 × 3 = 4$4 before moving
EquationF = 3d + 4check d = 6: $22
Key idea

Try it: rate and starting value

Worked example

When does the line reach $25?

  • Set the rule equal to the value: 3d + 4 = 25.
  • Take off the fixed charge, then divide by the rate.
  • Seven kilometres.
StepWorkingResult
Budget $253d + 4 = 25
Take off the $43d = 21
Divide by $3 per kmd = 77 km
On the taxi graphacross from 25down to 7
Worked example

A negative rate of change

  • A tank starts with 24 litres and drains steadily.
  • 16 L at 2 minutes, 8 L at 4 minutes.
  • Minus 8 litres over 2 minutes: −4 L per minute.
A negative rate of change
Worked example

Two intercepts, two meanings

  • Vertical intercept: 24 litres at the start.
  • So V = 24 − 4t.
  • Time intercept: V = 0 when t = 6. Empty at 6 minutes.
FeatureValueMeaning
Vertical intercept24 Lfull at the start
Gradient−8 L ÷ 2 min−4 L per minute
EquationV = 24 − 4t
Time intercept24 − 4t = 0empty at 6 minutes
Key idea

Try it: read the rate

Worked example

When are there 10 litres left?

  • Solve 24 − 4t = 10. So 4t = 14.
  • t = 3.5 minutes. Substitute back to check.
  • Sense check: 10 L sits between 16 L and 8 L.
StepWorkingResult
10 L left?24 − 4t = 10
Rearrange4t = 14t = 3.5 minutes
Check24 − 4 × 3.510, correct
Sense check16 L at 2, 8 L at 410 is between
Summary

What to take away

  • Seven lines. The first two find the rule, the rest read it.
Constant differencelinear; with x up in 1s, it is m
Term zerostep back once to find c
Gradientrise over run, any two points
x steps by more than 1divide the change by the step
Units of a gradienty units per one x unit
The intercept cthe value when x is zero
Reaching a valueset the rule equal to it, solve

Common mistakes

  • Sticks go 4, 7, 10, 13, so the rule is y = 3n.
    Check n = 1: 3 × 1 = 3, not 4; step back to zero squares (4 − 3 = 1) to get y = 3n + 1.
  • x = 0, 2, 4 gives y = 5, 11, 17, so the gradient is 6.
    y rises 6 for every 2 across, so m = 6 ÷ 2 = 3 and y = 3x + 5.
  • The tank goes from 24 L to 16 L in 2 minutes, so the gradient is 4.
    The volume is falling, so the gradient is −4 L per minute, giving V = 24 − 4t; give the sign and the units.
  • In F = 3d + 4, the 4 is the cost per kilometre.
    The 4 is the intercept, $4 charged before the taxi moves; the gradient, $3 per km, is the cost of each kilometre.
Your turn

Your turn: eight questions

  • Give a reason for each step.
  • Question 2: watch how far x moves each time.
  • Question 3 needs a sign and units.
1

Tiles: 6, 11, 16, 21 for n = 1 to 4. Find the rule.

2

x = 0, 3, 6 gives y = 2, 8, 14. Write y = mx + c.

3

Steady drain, 90 L to 30 L in 12 min. Find m, with units.

4

Hall hire: C = 40h + 75. What does 75 mean? Hours for $275?

5

A plumber charges C = 85h + 60 dollars for h hours of work. Which statement is true?

6

Chairs in a pattern follow y = 4n + 2. Which pattern number n uses 58 chairs?

7

Ana finds the gradient through (2, 9) and (6, 21) as 4 ÷ 12 = 1/3. What is her mistake?

8

A candle burns steadily. It is 30 cm tall 2 hours after lighting and 18 cm after 6 hours. How many hours after lighting does it burn out?

Show answer

1. y = 5n + 1. The tiles go up by 5 each step, so m = 5, and stepping back once gives term zero 6 − 5 = 1. Check n = 4: 21. 2. y = 2x + 2. y rises 6 while x rises 3, so m = 6 ÷ 3 = 2, not 6. At x = 0, y = 2, so c = 2. 3. m = −5 litres per minute. The change is −60 L over 12 min, and the minus sign says the water is going down. 4. $75 is the fixed charge, paid before any hours. 40h + 75 = 275 gives 40h = 200, so 5 hours. Watch for students who use 60 as the rise in Q3 without the sign, or 6 as the gradient in Q2. 5. Each extra hour adds $85. The gradient 85 is the rate in dollars per hour, and the intercept 60 is the call-out fee paid before any work. 6. n = 14. Solve 4n + 2 = 58: take off the 2 to get 4n = 56, then divide by 4. Check: 4 × 14 + 2 = 58. 7. She put run over rise; m = 3. Rise over run is (21 − 9) ÷ (6 − 2) = 12 ÷ 4 = 3. 8. After 12 hours. The rate is −12 cm ÷ 4 h = −3 cm per hour, so at the start it was 30 + 2 × 3 = 36 cm, L = 36 − 3t, and 36 − 3t = 0 gives t = 12.

Worked example

The answers

  • y = 5n + 1.
  • y = 2x + 2.
  • m = −5 litres per minute.
  • $75 is the fixed charge. 5 hours.
Your turn

Sample question: Achieved

A straight line passes through (2, 7) and (6, 19). Find its equation in the form y = mx + c.

Hint

Find the gradient as rise over run, then put one point into y = mx + c to find c.

Answer

y = 3x + 1

Step by step
  1. A straight line is y = mx + c, so we need the gradient m and the y-intercept c.
  2. Gradient is rise over run. From (2, 7) to (6, 19), y rises by 19 − 7 = 12.
  3. x runs from 2 to 6, which is 6 − 2 = 4. Take both differences in the same order.
  4. m = 12 ÷ 4 = 3. y goes up 3 for every 1 across.
  5. So y = 3x + c. Substitute the point (2, 7): 7 = 3 × 2 + c, so 7 = 6 + c and c = 1.
  6. The equation is y = 3x + 1.
  7. Check with the other point: 3 × 6 + 1 = 19. It is on the line.
Full working
  1. m = 19 − 76 − 2 = 124 = 3rise over run
  2. 7 = 3 × 2 + c, so c = 1substitute (2, 7)
  3. check: 3 × 6 + 1 = 19
  4. y = 3x + 1
Your turn

Sample questions: Merit

1

A plumber charges a call-out fee plus an hourly rate. A 2-hour job costs $190 and a 5-hour job costs $385. Find a rule for the cost C of an h-hour job, explain what the gradient and the intercept mean, and find how long a $450 job took.

Hint

Use the two jobs as two points (h, C). The gradient is the extra cost for each extra hour.

Answer

C = 65h + 60: $65 per hour, a $60 call-out fee; a $450 job took 6 hours

Step by step
  1. Treat each job as a point (hours, cost): (2, 190) and (5, 385). A fixed fee plus a steady rate makes a straight line.
  2. Gradient: the cost rises 385 − 190 = $195 while the time rises 5 − 2 = 3 hours.
  3. m = 195 ÷ 3 = 65. The units are dollars per hour: each extra hour costs $65.
  4. So C = 65h + c. Use (2, 190): 190 = 130 + c, so c = 60.
  5. The intercept is the cost when h = 0, before any work is done. So $60 is the call-out fee.
  6. Now solve 65h + 60 = 450. Take off the fixed fee: 65h = 390.
  7. Divide by the rate: h = 390 ÷ 65 = 6 hours.
  8. Check: 65 × 6 + 60 = 390 + 60 = 450. Also 65 × 5 + 60 = 385, the second job.
Full working
  1. m = 385 − 1905 − 2 = 1953 = 65dollars per hour
  2. 190 = 65 × 2 + c, so c = 60call-out fee
  3. C = 65h + 60
  4. 65h + 60 = 450, so 65h = 390subtract the fee
  5. h = 6 hours
2

Hexagons are made from matchsticks in a row, each new hexagon sharing one side with the one before. 1, 2 and 3 hexagons use 6, 11 and 16 matches. Find a rule for the number of matches s in pattern n, and explain where each number in it comes from. Which pattern uses 101 matches? Can a pattern use exactly 150?

Hint

Find the constant difference, then step back to pattern 0. To test 150, solve the equation and see if n is a whole number.

Answer

s = 5n + 1; pattern 20 uses 101; 150 is impossible, because n = 29.8 is not a whole number

Step by step
  1. The numbers go 6, 11, 16: up 5 each time. A constant difference means the rule is linear, s = 5n + c.
  2. Why 5? Each new hexagon shares one side with the last one, so it needs only 6 − 1 = 5 new matches.
  3. Step back one pattern to n = 0: 6 − 5 = 1. So c = 1, and s = 5n + 1.
  4. So think of one starting match, then 5 more for every hexagon. That is what 5n + 1 says.
  5. Check: n = 3 gives 5 × 3 + 1 = 16. Correct.
  6. 101 matches: solve 5n + 1 = 101. Subtract 1: 5n = 100. Divide by 5: n = 20.
  7. 150 matches: solve 5n + 1 = 150. 5n = 149, so n = 29.8.
  8. A pattern number must be a whole number of hexagons, so no pattern uses exactly 150 matches. Pattern 29 uses 146 and pattern 30 uses 151.
Full working
  1. differences 5, 5linear, m = 5
  2. 6 − 5 = 1, so c = 1step back to n = 0
  3. s = 5n + 1
  4. 5n + 1 = 101, so n = 20
  5. 5n + 1 = 150, so n = 29.8not a whole number
  6. s = 5n + 1; pattern 20; 150 is impossible
Your turn

Sample questions: Excellence

1

At the same moment, tank A starts draining from 500 litres at 12 litres per minute, and tank B starts filling from 80 litres at 9 litres per minute. (a) Write a rule for each tank. (b) When do they hold the same amount, and how much is that? (c) For what times does A hold more than B? (d) Is the rule for A sensible at t = 50 minutes? Explain.

Hint

A draining rate is a negative gradient. Set the two rules equal for (b), use an inequation for (c), and think about when A runs out for (d).

Answer

(a) A = 500 − 12t, B = 80 + 9t (b) after 20 minutes, 260 litres each (c) 0 ≤ t < 20 (d) no: A is empty at 1253 minutes (about 41.7), and the rule gives −100 litres

Step by step
  1. Each tank starts with a fixed amount and changes at a steady rate, so each rule is a straight line.
  2. A starts at 500 and loses 12 each minute: A = 500 − 12t. The gradient −12 is negative because it drains.
  3. B starts at 80 and gains 9 each minute: B = 80 + 9t.
  4. (b) Same amount means A = B: 500 − 12t = 80 + 9t.
  5. Add 12t to both sides and subtract 80: 420 = 21t, so t = 20 minutes.
  6. Amount: 500 − 12 × 20 = 260 litres, and 80 + 9 × 20 = 260 litres. Both agree.
  7. (c) A more than B: 500 − 12t > 80 + 9t, so 420 > 21t and t < 20. Time starts at 0, so 0 ≤ t < 20.
  8. That makes sense: A starts higher and the gap closes by 12 + 9 = 21 litres every minute. 420 ÷ 21 = 20.
  9. (d) At t = 50 the rule gives 500 − 600 = −100 litres. A tank cannot hold a negative amount.
  10. A is empty when 500 − 12t = 0, so t = 50012 = 1253 minutes (about 41.7). After that the rule no longer fits.
  11. So the rule for A only works for 0 ≤ t ≤ 1253. This is a limitation of the model.
Full working
  1. A = 500 − 12t, B = 80 + 9tstart plus rate × time
  2. 500 − 12t = 80 + 9t, so 21t = 420set equal
  3. t = 20, 260 L each
  4. 500 − 12t > 80 + 9t gives t < 20so 0 ≤ t < 20
  5. 500 − 12t = 0 gives t = 1253A is empty
  6. t = 50 gives −100 Limpossible, rule only for 0 ≤ t ≤ 1253
  7. 20 min, 260 L; A more for 0 ≤ t < 20; rule fails after 41.7 min
2

Kiwi Cabs charges a fixed fee plus a rate per km. A 4 km trip costs $14 and a 10 km trip costs $29. A rival charges $2 per km plus a fixed fee of F dollars. Find the values of F for which the rival is cheaper for every trip of 6 km or more. Explain your reasoning.

Hint

Find Kiwi Cabs' rule first. Then think about which trip of 6 km or more is the hardest one for the rival to win.

Answer

Kiwi Cabs: C = 2.5d + 4. The rival is cheaper for every trip of 6 km or more when 0 ≤ F < 7

Step by step
  1. Kiwi Cabs is a straight-line rule C = md + c. Use the points (4, 14) and (10, 29).
  2. m = (29 − 14) ÷ (10 − 4) = 15 ÷ 6 = 2.5, so $2.50 per km.
  3. c: 14 = 2.5 × 4 + c = 10 + c, so the fixed fee is $4. C = 2.5d + 4.
  4. The rival costs F + 2d. Its rate, $2 per km, is lower than 2.5, so the longer the trip, the more the rival saves.
  5. Each extra km, the rival saves another $0.50. So the hardest trip for the rival to win is the shortest one allowed: 6 km.
  6. At 6 km Kiwi Cabs costs 2.5 × 6 + 4 = $19. The rival costs F + 12.
  7. Rival cheaper at 6 km: F + 12 < 19, so F < 7.
  8. If F < 7, the rival is cheaper at 6 km, and its lead only grows after that. So it is cheaper for every trip of 6 km or more.
  9. If F is 7 or more, the 6 km trip is not cheaper, so the condition fails.
  10. Check F = 6: at 6 km, 18 < 19; at 20 km, 46 < 54. Check F = 7: at 6 km both cost 19, so not cheaper.
Full working
  1. m = 29 − 1410 − 4 = 2.5dollars per km
  2. 14 = 2.5 × 4 + c, so c = 4C = 2.5d + 4
  3. rival F + 2d: saves 0.5 per kmgap grows with d
  4. hardest case d = 6: F + 12 < 19Kiwi Cabs costs 19
  5. 0 ≤ F < 7a fee cannot be negative
Try it

Graphing Slope-Intercept

Full screen · PhET Interactive Simulations, University of Colorado Boulder, CC BY 4.0

Challenge

1

A straight line has gradient 4 and passes through the points (1, k) and (k, 21). Find k and the equation of the line, and say whether the point (−3, −11) is on it.

Hint

Gradient is rise over run. Write the rise and the run between the two points using k, set the gradient equal to 4, and solve.

Answer

k = 5; y = 4x + 1; yes, (−3, −11) is on the line

Step by step
  1. Rise from the first point to the second is 21 − k. Run is k − 1.
  2. Gradient is rise over run, so 21 − kk − 1 = 4.
  3. Multiply both sides by k − 1: 21 − k = 4k − 4. So 25 = 5k and k = 5.
  4. The points are (1, 5) and (5, 21). From (1, 5), step back 1 in x and 4 in y: the intercept is 1. So y = 4x + 1.
  5. At x = −3: 4 × (−3) + 1 = −11. That matches, so the point is on the line.
  6. Check the gradient: (21 − 5) ÷ (5 − 1) = 16 ÷ 4 = 4.
Full working
  1. 21 − kk − 1 = 4rise over run
  2. 21 − k = 4k − 4multiply by k − 1
  3. 25 = 5k, k = 5collect
  4. c = 5 − 4 × 1 = 1, so y = 4x + 1step back to x = 0
  5. 4 × (−3) + 1 = −11substitute x = −3
  6. k = 5, y = 4x + 1, and (−3, −11) is on the line
2

Matchsticks make a grid of squares 3 squares high and n squares long. Find a rule for the number of matches s, explaining where each number in the rule comes from. Kahu has 250 matches. What is the longest grid she can make, and how many matches are left over?

Hint

Count the horizontal matches and the vertical matches separately. How many horizontal rows of matches are there, and how many vertical columns of matches?

Answer

s = 7n + 3; the longest grid is 35 squares long, using 248 matches, with 2 left over

Step by step
  1. Horizontal matches: a grid 3 squares high has 4 rows of matches (top, bottom and 2 in between), each n long. That is 4n.
  2. Vertical matches: there are n + 1 columns of matches, each 3 long. That is 3(n + 1) = 3n + 3.
  3. Total: s = 4n + 3n + 3 = 7n + 3. The 7 is the matches each new column of squares adds (4 across, 3 up). The 3 is the left-hand edge that starts the grid.
  4. Check: n = 1 is a column of 3 squares: 4 across and 6 up is 10, and 7 + 3 = 10.
  5. With 250 matches: 7n + 3 ≤ 250 gives 7n ≤ 247, n ≤ 35.28...
  6. n must be whole, so n = 35. That uses 7 × 35 + 3 = 248 matches, leaving 2.
Full working
  1. across: 4 rows × n = 4n3 squares high has 4 lines
  2. up: (n + 1) columns × 3 = 3n + 3one more column than squares
  3. s = 7n + 3collect
  4. 7n + 3 ≤ 250, so n ≤ 35.28...at most 250 matches
  5. 7 × 35 + 3 = 248, 250 − 248 = 2n = 35, whole
  6. s = 7n + 3; 35 squares long, 2 matches left over
3

Cambridge and Hamilton are 24 km apart on a straight cycle path. Tama leaves Cambridge at 7:00 am cycling to Hamilton at 18 km per hour. Mere leaves Hamilton at 7:30 am cycling to Cambridge at 12 km per hour. Let t be hours after 7:00 am and d the distance from Cambridge. Write a rule for each rider, and explain what the 30 in Mere's rule would mean and why her rule only holds from t = 0.5. When do they meet, and at what two times are they exactly 6 km apart?

Hint

Tama: d = 18t. Mere is at 24 km when t = 0.5 and her d falls by 12 each hour, so work back to t = 0. Before 7:30 only Tama is moving.

Answer

Tama d = 18t, Mere d = 30 − 12t (for t ≥ 0.5); they meet at 8:00 am, 18 km from Cambridge; they are 6 km apart at 7:48 am and 8:12 am

Step by step
  1. Tama starts at d = 0 and gains 18 km each hour: d = 18t.
  2. Mere's distance falls by 12 km each hour, a gradient of −12. At t = 0.5, d = 24. Stepping back half an hour adds 6, so the intercept is 30: d = 30 − 12t.
  3. The 30 is where Mere would have been at 7:00 am if she had been riding all along: 30 km from Cambridge, 6 km beyond Hamilton. She was really waiting in Hamilton, so the rule only holds from t = 0.5.
  4. They meet when 18t = 30 − 12t, so 30t = 30 and t = 1. That is 8:00 am, at 18 km from Cambridge.
  5. Before 7:30 the gap is 24 − 18t, which is still 15 km at 7:30. After that the gap is (30 − 12t) − 18t = 30 − 30t until they meet. 30 − 30t = 6 gives t = 0.8, which is 7:48 am.
  6. After they pass, the gap is 18t − (30 − 12t) = 30t − 30. 30t − 30 = 6 gives t = 1.2, which is 8:12 am. Tama is at 21.6 km and Mere at 15.6 km.
Full working
  1. Tama: d = 18tstarts at 0, 18 km per hour
  2. Mere: d = 24 − 12(t − 0.5) = 30 − 12tat 24 km when t = 0.5, falling 12 per hour
  3. 18t = 30 − 12t, t = 1, d = 18they meet
  4. 30 − 30t = 6, t = 0.8gap closing: 7:48 am
  5. 30t − 30 = 6, t = 1.2gap opening: 8:12 am
  6. meet at 8:00 am, 18 km from Cambridge; 6 km apart at 7:48 am and 8:12 am

More challenge problems

Science

Where science uses this

Practice

Practise this

Worksheet with answersWithout answersDownload PDF
2026 practice paper with worked answersOpen the paper
Report a mistake

More in AS 91947

Is your child on track?

Take the free placement test