Year 9 Mathematics | Victorian Curriculum 2.0
Linear graphs
Topic 04 | Number & Algebra | Practice

What you will learn

  • sketch linear graphs from gradient-intercept form y=mx+cy = mx + cy=mx+c,
  • convert general form ax+by=cax + by = cax+by=c to gradient-intercept form and sketch,
  • calculate the gradient between two points using m=y2−y1x2−x1m = \dfrac{y_2 - y_1}{x_2 - x_1}m=x2​−x1​y2​−y1​​,
  • find the midpoint of a line segment using M=(x1+x22,  y1+y22)M = \left(\dfrac{x_1 + x_2}{2},\;\dfrac{y_1 + y_2}{2}\right)M=(2x1​+x2​​,2y1​+y2​​),
  • calculate the distance between two points using Pythagoras,
  • identify parallel lines (equal gradients) and perpendicular lines (gradient product =−1= -1=−1).
Why do gradients matter?

The gradient of a line captures rate of change in a single number. A gradient of 333 means “for every 111 unit across, the line rises 333 units”. This idea underpins everything from speed calculations in physics to cost-per-item comparisons in business. If you can read a gradient, you can compare any two linear relationships at a glance.

Where you'll see this
  • Road signs: a gradient of 1:81:81:8 tells drivers how steeply a road rises.
  • Architecture: roof pitch is described as a gradient (rise over run).
  • Economics: a cost function like C=4n+20C = 4n + 20C=4n+20 has gradient $4 per item and a fixed cost of $20.
  • Navigation: the midpoint formula finds the halfway point between two GPS coordinates on a grid map.
Worked example 0 Real-world example: comparing phone plans

Plan A charges a $10 monthly fee plus $0.50 per GB. Plan B charges no monthly fee but $1.20 per GB. Which plan is cheaper at 202020 GB?

  1. Plan A cost: CA=0.5n+10C_A = 0.5n + 10CA​=0.5n+10. At n=20n = 20n=20: CA=0.5(20)+10=20C_A = 0.5(20) + 10 = 20CA​=0.5(20)+10=20.
  2. Plan B cost: CB=1.2nC_B = 1.2nCB​=1.2n. At n=20n = 20n=20: CB=1.2(20)=24C_B = 1.2(20) = 24CB​=1.2(20)=24.
  3. Plan A is $4 cheaper at 202020 GB. Graphing both lines would show them crossing near n≈14.3n \approx 14.3n≈14.3 GB — below that, Plan B is cheaper.

Key idea: the gradient tells you the per-GB rate; the yyy-intercept tells you the fixed cost. Comparing gradients and intercepts lets you decide which plan suits your usage.

1. Gradient-intercept form: y=mx+cy = mx + cy=mx+c

In the equation y=mx+cy = mx + cy=mx+c:

  • mmm is the gradient (slope) — how steeply the line rises or falls,
  • ccc is the yyy-intercept — where the line crosses the yyy-axis.

Formula reference

y=mx+cy = mx + cy=mx+c

mmm = gradient (rise/run), ccc = yyy-intercept.

To sketch from y=mx+cy = mx + cy=mx+c:

  1. Plot the yyy-intercept (0,c)(0, c)(0,c).
  2. From that point, use the gradient: move 111 unit right and mmm units up (or down if m<0m < 0m<0).
  3. Draw a straight line through the two points and extend in both directions.
Worked example 1 Sketching from y = mx + c

Sketch y=2x−3y = 2x - 3y=2x−3.

  1. The yyy-intercept is −3-3−3, so plot (0,−3)(0, -3)(0,−3).
  2. Gradient m=2=21m = 2 = \dfrac{2}{1}m=2=12​: from (0,−3)(0, -3)(0,−3) move 111 right and 222 up to (1,−1)(1, -1)(1,−1).
  3. Draw the line through (0,−3)(0, -3)(0,−3) and (1,−1)(1, -1)(1,−1).
  4. The xxx-intercept is found by setting y=0y = 0y=0: 0=2x−30 = 2x - 30=2x−3, so x=1.5x = 1.5x=1.5. Confirm the line passes through (1.5,0)(1.5, 0)(1.5,0).

2. General form and converting between forms

The general form of a linear equation is ax+by=cax + by = cax+by=c (or ax+by+c=0ax + by + c = 0ax+by+c=0). To sketch it, rearrange to gradient-intercept form.

Worked example 2 Converting general form to y = mx + c

Rewrite 3x+2y=123x + 2y = 123x+2y=12 in gradient-intercept form and state the gradient and yyy-intercept.

  1. Subtract 3x3x3x: 2y=−3x+122y = -3x + 122y=−3x+12.
  2. Divide by 222: y=−32x+6y = -\dfrac{3}{2}x + 6y=−23​x+6.
  3. Gradient m=−32m = -\dfrac{3}{2}m=−23​, yyy-intercept c=6c = 6c=6.
Quick intercept method for general form

For ax+by=cax + by = cax+by=c, set x=0x = 0x=0 to find the yyy-intercept (0,  cb)\left(0,\;\dfrac{c}{b}\right)(0,bc​) and set y=0y = 0y=0 to find the xxx-intercept (ca,  0)\left(\dfrac{c}{a},\;0\right)(ac​,0). Plot both and draw the line.

Worked example 3 Sketching using x- and y-intercepts

Sketch 4x+3y=244x + 3y = 244x+3y=24.

  1. Set x=0x = 0x=0: 3y=243y = 243y=24, so y=8y = 8y=8. The yyy-intercept is (0,8)(0, 8)(0,8).
  2. Set y=0y = 0y=0: 4x=244x = 244x=24, so x=6x = 6x=6. The xxx-intercept is (6,0)(6, 0)(6,0).
  3. Plot both intercepts and draw the straight line.

3. Gradient from two points

xy(x₁, y₁)(x₂, y₂)run = x₂ − x₁rise = y₂ − y₁

Formula reference

m=y2−y1x2−x1=riserunm = \frac{y_2 - y_1}{x_2 - x_1} = \frac{\text{rise}}{\text{run}}m=x2​−x1​y2​−y1​​=runrise​
Worked example 4 Gradient from two points

Find the gradient of the line through (2,3)(2, 3)(2,3) and (8,15)(8, 15)(8,15).

m=15−38−2=126=2m = \frac{15 - 3}{8 - 2} = \frac{12}{6} = 2m=8−215−3​=612​=2

The line rises 222 units for every 111 unit across.

Worked example 5 Negative gradient

Find the gradient of the line through (−1,7)(-1, 7)(−1,7) and (3,−5)(3, -5)(3,−5).

m=−5−73−(−1)=−124=−3m = \frac{-5 - 7}{3 - (-1)} = \frac{-12}{4} = -3m=3−(−1)−5−7​=4−12​=−3

A negative gradient means the line falls from left to right.

4. Midpoint and distance formulas

Midpoint

The midpoint of a segment joining (x1,y1)(x_1, y_1)(x1​,y1​) and (x2,y2)(x_2, y_2)(x2​,y2​) is:

Formula reference

M=(x1+x22,  y1+y22)M = \left(\frac{x_1 + x_2}{2},\;\frac{y_1 + y_2}{2}\right)M=(2x1​+x2​​,2y1​+y2​​)
Worked example 6 Midpoint between two points

Find the midpoint of A(1,4)A(1, 4)A(1,4) and B(7,10)B(7, 10)B(7,10).

M=(1+72,  4+102)=(4,  7)M = \left(\frac{1 + 7}{2},\;\frac{4 + 10}{2}\right) = (4,\;7)M=(21+7​,24+10​)=(4,7)

Distance

The distance between two points uses Pythagoras’ theorem on the horizontal and vertical differences:

Formula reference

d=(x2−x1)2+(y2−y1)2d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}d=(x2​−x1​)2+(y2​−y1​)2​
Worked example 7 Distance between two points

Find the distance between P(2,1)P(2, 1)P(2,1) and Q(6,4)Q(6, 4)Q(6,4).

d=(6−2)2+(4−1)2=16+9=25=5d = \sqrt{(6-2)^2 + (4-1)^2} = \sqrt{16 + 9} = \sqrt{25} = 5d=(6−2)2+(4−1)2​=16+9​=25​=5

5. Parallel and perpendicular lines

Parallel lines have the same gradient: m1=m2m_1 = m_2m1​=m2​.

Perpendicular lines have gradients whose product is −1-1−1: m1×m2=−1m_1 \times m_2 = -1m1​×m2​=−1.

Equivalently, if one line has gradient mmm, a perpendicular line has gradient −1m-\dfrac{1}{m}−m1​.

Worked example 8 Testing parallel or perpendicular

Line AAA: y=3x+1y = 3x + 1y=3x+1. Line BBB: y=−13x+5y = -\dfrac{1}{3}x + 5y=−31​x+5.

  1. Gradient of AAA: mA=3m_A = 3mA​=3.
  2. Gradient of BBB: mB=−13m_B = -\dfrac{1}{3}mB​=−31​.
  3. Product: 3×(−13)=−13 \times \left(-\dfrac{1}{3}\right) = -13×(−31​)=−1.
  4. Since the product is −1-1−1, the lines are perpendicular.
Worked example 9 Finding a parallel line through a given point

Find the equation of the line parallel to y=4x−7y = 4x - 7y=4x−7 that passes through (2,5)(2, 5)(2,5).

  1. A parallel line has the same gradient: m=4m = 4m=4.
  2. Substitute into y=mx+cy = mx + cy=mx+c: 5=4(2)+c5 = 4(2) + c5=4(2)+c, so c=−3c = -3c=−3.
  3. Equation: y=4x−3y = 4x - 3y=4x−3.

Practice

Fluency

Tier 1: gradient, intercept and sketching

    1. State the gradient and yyy-intercept of y=5x−2y = 5x - 2y=5x−2.
    2. State the gradient and yyy-intercept of y=−3x+7y = -3x + 7y=−3x+7.
    3. Rewrite 2x+y=102x + y = 102x+y=10 in the form y=mx+cy = mx + cy=mx+c.
    4. Rewrite 6x−3y=96x - 3y = 96x−3y=9 in gradient-intercept form.
    5. Find the xxx- and yyy-intercepts of 5x+2y=205x + 2y = 205x+2y=20.
    6. Find the gradient of the line through (1,2)(1, 2)(1,2) and (4,11)(4, 11)(4,11).
    7. Find the gradient of the line through (−3,5)(-3, 5)(−3,5) and (1,−7)(1, -7)(1,−7).
    8. Find the midpoint of (2,6)(2, 6)(2,6) and (10,14)(10, 14)(10,14).
    9. Find the distance between (0,0)(0, 0)(0,0) and (5,12)(5, 12)(5,12).
    10. Find the distance between (−1,3)(-1, 3)(−1,3) and (2,7)(2, 7)(2,7).
Reasoning

Tier 2: mixed practice

    1. A line passes through (0,−4)(0, -4)(0,−4) with gradient 23\dfrac{2}{3}32​. Write its equation.
    2. Find the equation of the line through (1,5)(1, 5)(1,5) and (3,11)(3, 11)(3,11).
    3. Determine whether the lines y=2x+3y = 2x + 3y=2x+3 and 4x−2y=74x - 2y = 74x−2y=7 are parallel, perpendicular, or neither.
    4. Find the midpoint and length of the segment joining A(−2,3)A(-2, 3)A(−2,3) and B(6,−1)B(6, -1)B(6,−1).
    5. A line has equation 3x+4y=243x + 4y = 243x+4y=24. Find its gradient, xxx-intercept and yyy-intercept.
    6. Find the equation of the line perpendicular to y=−2x+1y = -2x + 1y=−2x+1 that passes through (4,3)(4, 3)(4,3).
    7. Show that the triangle with vertices A(0,0)A(0, 0)A(0,0), B(4,0)B(4, 0)B(4,0) and C(4,3)C(4, 3)C(4,3) is right-angled by calculating all three side lengths.
    8. The midpoint of P(a,3)P(a, 3)P(a,3) and Q(5,9)Q(5, 9)Q(5,9) is (4,6)(4, 6)(4,6). Find the value of aaa.
Reasoning

Tier 3: explain and apply

    1. Explain why a vertical line cannot be written in the form y=mx+cy = mx + cy=mx+c. What happens to the gradient formula when x1=x2x_1 = x_2x1​=x2​?
    2. Two hikers start at point A(1,2)A(1, 2)A(1,2) on a grid map (km units). Hiker 1 walks to B(7,10)B(7, 10)B(7,10). Hiker 2 walks to C(9,5)C(9, 5)C(9,5). Who walks further, and by how much?
    3. A quadrilateral has vertices P(0,0)P(0, 0)P(0,0), Q(6,0)Q(6, 0)Q(6,0), R(8,4)R(8, 4)R(8,4), S(2,4)S(2, 4)S(2,4). By calculating gradients, show that PQRSPQRSPQRS is a parallelogram.
    4. The line y=kx+2y = kx + 2y=kx+2 is perpendicular to y=4x−1y = 4x - 1y=4x−1. Find kkk.
    5. Point M(3,5)M(3, 5)M(3,5) is the midpoint of A(1,2)A(1, 2)A(1,2) and BBB. Find the coordinates of BBB.

Challenge

Reasoning

Harder reasoning

    1. Prove that the diagonals of the rectangle with vertices A(0,0)A(0, 0)A(0,0), B(8,0)B(8, 0)B(8,0), C(8,6)C(8, 6)C(8,6), D(0,6)D(0, 6)D(0,6) bisect each other by finding both midpoints.
    2. A line passes through (2,−1)(2, -1)(2,−1) and is perpendicular to the line 3x−5y=103x - 5y = 103x−5y=10. Find its equation in general form ax+by=cax + by = cax+by=c.
    3. Three points are A(1,1)A(1, 1)A(1,1), B(5,3)B(5, 3)B(5,3), C(3,5)C(3, 5)C(3,5). Find the perimeter of triangle ABCABCABC, giving your answer in exact (surd) form.
    4. The vertices of a triangle are P(−1,4)P(-1, 4)P(−1,4), Q(5,0)Q(5, 0)Q(5,0) and R(3,8)R(3, 8)R(3,8). Find the length of the median from PPP to the midpoint of QRQRQR.

Interactive

Try it yourself: build three lines

Work through 3 examples on one graph. Drag, check, then move to the next.

Example 1 (easy). Make your line pass through the red target at (2, 4). Many m and c work — any will do.

Point A
(0, 0)
Point B
(2, 2)
Slope m
1
Intercept c
0

Example 1: Example 1 (easy). Make your line pass through the red target at (2, 4). Many m and c work — any will do.

(2, 4)
Worked solution: Any line through (2, 4) satisfies 4 = 2m + c, i.e. c = 4 - 2m. Try m = 1, c = 2 (y = x + 2); or m = 2, c = 0 (y = 2x); or m = 0, c = 4 (horizontal y = 4).

Example 2: Example 2 (medium). Make a line with slope m = -2 that passes through (0, 3). One right answer.

(0, 3)
Worked solution: Slope -2 and y-intercept 3 gives y = -2x + 3. Check: at x = 0, y = 3. ✓

Example 3: Example 3 (hard). Make a line parallel to y = 2x (shown dashed) that passes through (-1, 0).

(-1, 0)
Worked solution: Parallel means same slope, so m = 2. Then 0 = 2(-1) + c gives c = 2. The line is y = 2x + 2.

Printed view: static snapshots of each example. Drag and check in the browser.

Year 9 Mathematics study companion | Practice