Skip to main content
NSWMaths Standard 2Syllabus dot point

How do you turn a linear relationship into a straight-line graph, plotting points from a table of values, recognising the line, sketching horizontal and vertical lines, and finding the intercepts?

Graph linear functions by constructing a table of values and plotting the points, recognise a linear relationship, sketch horizontal and vertical lines, and graph a line using its x- and y-intercepts

A focused answer to the HSC Maths Standard 2 dot point on graphing linear functions. Build a table of values, plot the points and rule a straight line, sketch horizontal lines and vertical lines, graph a line from its x- and y-intercepts, and read values off the graph, with worked Australian cost and distance examples.

Generated by Claude Opus 4.817 min answer

Reviewed by: AI editorial process; not yet individually human-reviewed

Have a quick question? Jump to the Q&A page

What this dot point is asking

A linear relationship is one where, every time the independent variable goes up by the same step, the dependent variable changes by the same amount. Plot it and the points fall in a perfectly straight line, which is why these are called linear functions. NESA wants you to turn such a relationship into a graph and read information back off it. Three skills are bundled here, and a question can test any of them. The first is to build a table of values and plot the points to draw the line. The second is to recognise and sketch the two special cases, horizontal lines y=ky = k and vertical lines x=kx = k. The third is to graph a line quickly from its xx- and yy-intercepts when you are given its equation.

The deeper idea worth carrying through all of it is that two points are enough to fix a straight line. A table of values gives you several points as a safety net: if one is out of line, you have made an arithmetic slip. But once you trust the relationship is linear you only ever need two well-chosen points, and the two easiest to find are almost always the intercepts. The marks come from a correctly labelled and scaled set of axes, accurately plotted points, a ruled straight line, and reading values off cleanly. Marks are lost in predictable ways: cramped or unlabelled axes, a freehand wavy line, plotting a point with the coordinates the wrong way around, and misreading a horizontal line for a vertical one.

The answer

Recognising a linear relationship

When a relationship is linear, equal steps in xx produce equal steps in yy. Look at the table for y=2x1y = 2x - 1:

xx 1-1 00 11 22 33
yy 3-3 1-1 11 33 55

Every time xx increases by 11, yy increases by 22. That constant step is the fingerprint of a straight line: it is what makes the points line up when you plot them. A relationship whose yy-steps are not constant (for example y=x2y = x^2, where the gaps grow) is not linear and its graph is a curve, which is outside this dot point. In Mathematics Standard, the linear functions you graph come in two shapes: written as y=y = \ldots in terms of xx (such as y=2x1y = 2x - 1 or y=4ny = 4n), or written as an equation like 3x+2y=123x + 2y = 12 that mixes xx and yy on one side. The method below handles both.

Graphing from a table of values

This is the bread-and-butter method, and it always works. There are three moves: build the table, draw and label the axes, then plot and rule.

  • Build the table of values. Put the independent variable (usually xx) in the top row and choose a small spread of values, commonly a few either side of 00. Substitute each one into the equation to fill in the bottom row (the dependent variable, usually yy). Three points is the minimum, but four or five is safer because a stray point reveals a mistake.
  • Draw and label the axes. Put the independent variable on the horizontal axis and the dependent variable on the vertical axis. Choose a scale that fits all your values and is evenly spaced, and label each axis with its variable and units. Good scaling is itself worth marks.
  • Plot the points and rule the line. Plot each ordered pair (x,y)(x, y), going across first, then up or down. Then join them with a single straight line drawn with a ruler, extending it a little past the end points and adding arrowheads.

The four panels below build the graph of a real Australian context, the cost CC dollars of buying nn punnets of strawberries at a market stall charging 44 dollars each, so C=4nC = 4n. The table of values is:

nn (punnets) 00 11 22 33 44 55
CC ($) 00 44 88 1212 1616 2020

Stage 1, draw and label the axes. Put the independent variable nn (the number of punnets) on the horizontal axis and the dependent variable CC (the cost in dollars) on the vertical axis. Scale the cost axis in steps of 44 so all the values from the table fit, and label each axis. An empty, well-scaled plane is the foundation; getting the scale right now saves redrawing later.

Stage 1: draw and label the axesAn empty number plane with the horizontal axis labelled n for punnets from 0 to 5 and the vertical axis labelled C for cost in dollars from 0 to 20 in steps of 4.12345481216200n (punnets)C ($)1

Stage 2, plot the points from the table. Take each pair from the table and plot it, reading the punnet value across the bottom and the cost value up the side: (0,0)(0, 0), (1,4)(1, 4), (2,8)(2, 8), (3,12)(3, 12), (4,16)(4, 16) and (5,20)(5, 20). Plot across first, then up. Already the dots look as if they line up, which is the visual check that the relationship is linear.

Stage 2: plot the points from the tableThe same number plane with the six points from the table plotted: 0 comma 0, 1 comma 4, 2 comma 8, 3 comma 12, 4 comma 16 and 5 comma 20.12345481216200n (punnets)C ($)2

Stage 3, rule a straight line through the points. Lay a ruler along the points and draw one straight line through all of them, extending it a little past the ends. If a point sits off the line, recheck that row of the table; here all six points lie exactly on the line, confirming C=4nC = 4n is linear.

Stage 3: rule a straight line through the pointsThe same plotted points now joined by a straight line ruled from 0 comma 0 up through 5 comma 20, confirming the relationship is linear.12345481216200n (punnets)C ($)3

Stage 4, read values off the finished graph. The graph now answers questions the table did not list. The line passes through the origin (0,0)(0, 0), its yy-intercept, meaning zero punnets cost nothing. To find the cost of 2.52.5 punnets-worth, read up from 2.52.5 on the bottom axis to the line, then across to the cost axis, landing on 1010 dollars (and indeed 4×2.5=104 \times 2.5 = 10).

Stage 4: read values off the finished graphThe finished line with the origin marked as the point it passes through, and dashed guide lines showing that 2 and a half punnets correspond to a cost of 10 dollars read off the graph.12345481216200n (punnets)C ($)passes through (0, 0)read off: 2.5 punnets, $104

Horizontal and vertical lines

Two special linear graphs are worth knowing on sight, because their equations look like they are missing a variable.

  • A horizontal line has equation y=ky = k for some fixed number kk. Every point on it has the same yy-coordinate, kk, no matter what xx is, so the line runs flat across the plane through kk on the yy-axis. For example y=3y = 3 passes through (3,3)(-3, 3), (0,3)(0, 3) and (2,3)(2, 3).
  • A vertical line has equation x=kx = k. Every point on it has the same xx-coordinate, kk, whatever yy is, so the line runs straight up and down through kk on the xx-axis. For example x=2x = -2 passes through (2,1)(-2, -1), (2,0)(-2, 0) and (2,2)(-2, 2).

The way to keep them straight is to ask which coordinate is pinned. In y=3y = 3 the yy-value is pinned at 33 and xx roams free, so the line is the set of all points at height 33: a horizontal line. In x=2x = -2 the xx-value is pinned and yy roams free, so the line is vertical. The pair below shows both on one plane.

Horizontal and vertical linesOne number plane showing two lines: the horizontal line y equals 3, drawn flat across at height 3, and the vertical line x equals negative 2, drawn straight up the plane through negative 2 on the x-axis.-4-3-2-11234-2-1123450xyy = 3x = −2

Graphing a line from its intercepts

When you are given an equation like 3x+2y=123x + 2y = 12, building a full table is slower than you need. Because two points fix a line, the fastest sketch comes from the two intercepts, the points where the line crosses the axes.

  • The xx-intercept is where the line crosses the xx-axis. On the xx-axis, y=0y = 0, so set y=0y = 0 and solve for xx.
  • The yy-intercept is where the line crosses the yy-axis. On the yy-axis, x=0x = 0, so set x=0x = 0 and solve for yy.

For 3x+2y=123x + 2y = 12: setting y=0y = 0 gives 3x=123x = 12, so x=4x = 4 and the xx-intercept is (4,0)(4, 0); setting x=0x = 0 gives 2y=122y = 12, so y=6y = 6 and the yy-intercept is (0,6)(0, 6). Mark those two points and rule the line through them. The diagram below shows the result, with both intercepts marked.

Graphing a line by its interceptsThe line 3x plus 2y equals 12 drawn on a number plane from its two intercepts: the y-intercept at 0 comma 6 marked on the vertical axis and the x-intercept at 4 comma 0 marked on the horizontal axis, joined by a straight line.-1123456-112345670xyy-intercept (0, 6)x-intercept (4, 0)3x + 2y = 12

The trick to remember which to zero is that you head to an axis by killing the other variable: to reach the xx-axis you make yy zero, and to reach the yy-axis you make xx zero. It feels back to front at first, which is exactly why it is a common trap.

How exam questions ask about graphing linear functions

The wording tells you which method to reach for:

  • "Complete the table of values" or "draw the graph of y=y = \ldots by first constructing a table of values" means substitute the listed xx values, plot the pairs, and rule the line.
  • "Plot the following points and join them to form a straight line" gives you the table already; just plot accurately and rule.
  • "Sketch the graph of x=4x = 4" (or y=1y = -1) is testing the special lines: decide horizontal or vertical by which coordinate is pinned, then draw it.
  • "Find the xx-intercept and the yy-intercept", or "sketch the line ax+by=cax + by = c", means use the intercept method: zero yy for the xx-intercept, zero xx for the yy-intercept.
  • "Use your graph to find ..." is a read-off: go up (or across) from the given value to the line, then across (or down) to the other axis, and state the value with units.
  • "Show that the point ()(\ldots) lies on the line" means substitute the coordinates into the equation and check both sides are equal.

Why two points (the intercepts) are enough

It is worth seeing why the intercept shortcut is valid, because it is the reasoning behind nearly every quick sketch. A straight line has no bends, so once you know any two distinct points on it there is exactly one line you can rule through them: two points determine a line. A table of values gives you more than two points, but only as insurance against an arithmetic slip; the line itself is already pinned down by any two of them. The intercepts are simply the two easiest points to compute, because setting a variable to zero removes a whole term from the equation.

The method does have one edge case. A line through the origin, like C=4nC = 4n or d=80td = 80t, has both intercepts at the same point (0,0)(0, 0), so the two intercepts coincide. Here you need a second point elsewhere to fix the direction, found by substituting any convenient value, say n=5n = 5. Lines of the form y=ky = k and x=kx = k are the other edge case. A horizontal line y=ky = k (with k0k \neq 0) never crosses the xx-axis, and a vertical line x=kx = k (with k0k \neq 0) never crosses the yy-axis, so the intercept method does not apply and you read them straight off as flat or upright.

Exam-style practice questions

Practice questions written in the style of NESA exam questions on this dot point, with worked answer explainers. The year tag is the paper they imitate, not the source.

2021 HSC-style3 marksA mobile phone plan charges a fixed monthly fee plus a rate per minute of calls. The cost $CC for a month with mm minutes of calls is C=20+0.10mC = 20 + 0.10m. (a) Construct a table of values for m=0,50,100,150m = 0, 50, 100, 150. (b) State the CC-intercept and explain what it represents.
Show worked answer →

Part (a): substitute each mm into C=20+0.10mC = 20 + 0.10m. Work along the row, multiplying the minutes by 0.100.10 and adding 2020:

m=0: C=20+0.10×0=20m = 0:\ C = 20 + 0.10 \times 0 = 20, then m=50: C=20+5=25m = 50:\ C = 20 + 5 = 25, then m=100: C=20+10=30m = 100:\ C = 20 + 10 = 30, then m=150: C=20+15=35m = 150:\ C = 20 + 15 = 35.

mm (minutes) 00 5050 100100 150150
CC ($) 2020 2525 3030 3535

Part (b): read off the intercept. The line cuts the vertical axis where m=0m = 0, giving C=20C = 20, so the CC-intercept is (0,20)(0, 20). It represents the fixed monthly fee of $2020 that is charged even when no calls are made.

Markers reward four correct table values and an interpretation of the intercept as the fixed fee, not just the bare number.

2023 HSC-style4 marksA line has equation 5x+2y=405x + 2y = 40. (a) Find the xx-intercept and the yy-intercept. (b) Show that the point (4,10)(4, 10) lies on the line. (c) Describe how to sketch the line using your answers from part (a).
Show worked answer →

Part (a): find each intercept. For the xx-intercept set y=0y = 0, because the line meets the xx-axis where yy is zero:

5x+2(0)=40,5x=40,x=405=8,5x + 2(0) = 40, \qquad 5x = 40, \qquad x = \frac{40}{5} = 8,

giving the xx-intercept (8,0)(8, 0). For the yy-intercept set x=0x = 0:

5(0)+2y=40,2y=40,y=402=20,5(0) + 2y = 40, \qquad 2y = 40, \qquad y = \frac{40}{2} = 20,

giving the yy-intercept (0,20)(0, 20).

Part (b): check the point. Substitute x=4x = 4 and y=10y = 10 into the left-hand side: 5(4)+2(10)=20+20=405(4) + 2(10) = 20 + 20 = 40. This equals the right-hand side, so (4,10)(4, 10) satisfies the equation and lies on the line.

Part (c): sketch. Mark (8,0)(8, 0) on the xx-axis and (0,20)(0, 20) on the yy-axis, then rule a single straight line through them, extended a little past both points. Two points fix a straight line, so the intercepts alone give the whole graph.

Markers reward both intercepts found by zeroing the correct variable, a clear both-sides check for the point, and a method that joins the two intercepts.

2024 HSC-style4 marksA water tank is draining at a steady rate. The volume VV litres remaining after tt minutes is V=60040tV = 600 - 40t. (a) Construct a table of values for t=0,5,10,15t = 0, 5, 10, 15. (b) Use the relationship to find the volume after 1212 minutes. (c) Find how long the tank takes to empty completely.
Show worked answer →

Part (a): substitute each tt into V=60040tV = 600 - 40t. Multiply the time by 4040 and subtract from 600600:

t=0: V=6000=600t = 0:\ V = 600 - 0 = 600, then t=5: V=600200=400t = 5:\ V = 600 - 200 = 400, then t=10: V=600400=200t = 10:\ V = 600 - 400 = 200, then t=15: V=600600=0t = 15:\ V = 600 - 600 = 0.

tt (minutes) 00 55 1010 1515
VV (litres) 600600 400400 200200 00

Part (b): volume after 1212 minutes. Reading up from t=12t = 12 to the line and across to the VV-axis matches the calculation V=60040×12=600480=120V = 600 - 40 \times 12 = 600 - 480 = 120 litres.

Part (c): time to empty. The tank is empty when V=0V = 0. Reading across from V=0V = 0 to the line and down to the tt-axis gives t=15t = 15, matching 0=60040t0 = 600 - 40t, so 40t=60040t = 600 and t=60040=15t = \dfrac{600}{40} = 15 minutes.

Markers reward four correct table values (note the line falls because the gradient is negative), a read-off or calculation for the volume, and solving V=0V = 0 for the empty time.

Practice questions

Original practice questions graded from foundation to exam level, each with a full worked solution. Try them before revealing the solution.

foundation2 marksComplete a table of values for the line y=x+2y = x + 2 using x=2,1,0,1,2x = -2, -1, 0, 1, 2, then state the coordinates of the five points you would plot.
Show worked solution →

Substitute each xx value into y=x+2y = x + 2. Work along the row, adding 22 to each xx:

x=2:;y=2+2=0,x=1:;y=1+2=1,x=0:;y=0+2=2,x = -2:; y = -2 + 2 = 0, \qquad x = -1:; y = -1 + 2 = 1, \qquad x = 0:; y = 0 + 2 = 2,

x=1:;y=1+2=3,x=2:;y=2+2=4.x = 1:; y = 1 + 2 = 3, \qquad x = 2:; y = 2 + 2 = 4.

Write out the table. The completed table of values is:

xx 2-2 1-1 00 11 22
yy 00 11 22 33 44

State the points. The five points to plot are (2,0)(-2, 0), (1,1)(-1, 1), (0,2)(0, 2), (1,3)(1, 3) and (2,4)(2, 4). They rise one unit for every unit you move right, which is the sign of a straight line.

foundation2 marksOn a number plane, describe how you would draw the graph of (a) the line y=1y = -1 and (b) the line x=4x = 4.
Show worked solution →
Part (a), the line y=1y = -1
Every point on this line has a yy-coordinate of 1-1, no matter what xx is. So it is a horizontal line. Draw a flat line straight across the plane through 1-1 on the yy-axis, for example through (2,1)(-2, -1), (0,1)(0, -1) and (3,1)(3, -1).
Part (b), the line x=4x = 4
Every point on this line has an xx-coordinate of 44, whatever yy is. So it is a vertical line. Draw a line straight up and down through 44 on the xx-axis, for example through (4,1)(4, -1), (4,0)(4, 0) and (4,2)(4, 2).
State the rule
An equation of the form y=ky = k is always horizontal and an equation of the form x=kx = k is always vertical; the missing variable is free to be anything.
core3 marksA line has equation 4x+5y=204x + 5y = 20. (a) Find the xx-intercept and the yy-intercept. (b) Hence describe how to sketch the line.
Show worked solution →

Part (a), find the xx-intercept. The xx-intercept is where the line crosses the xx-axis, so y=0y = 0. Substitute y=0y = 0:

4x+5(0)=20,4x=20,x=204=5.4x + 5(0) = 20, \qquad 4x = 20, \qquad x = \frac{20}{4} = 5.

The xx-intercept is the point (5,0)(5, 0).

Find the yy-intercept. The yy-intercept is where the line crosses the yy-axis, so x=0x = 0. Substitute x=0x = 0:

4(0)+5y=20,5y=20,y=205=4.4(0) + 5y = 20, \qquad 5y = 20, \qquad y = \frac{20}{5} = 4.

The yy-intercept is the point (0,4)(0, 4).

Part (b), sketch the line. Mark the two intercepts, (5,0)(5, 0) on the xx-axis and (0,4)(0, 4) on the yy-axis, then rule a straight line through them and extend it past both points. Two points are enough to fix a straight line, so the intercepts alone give the whole graph.

core3 marksA car travels at a constant speed. Its distance from home, dd km, after tt hours is given by d=60td = 60t. (a) Construct a table of values for t=0,1,2,3t = 0, 1, 2, 3. (b) Use the graph idea to find the distance after 2.52.5 hours, and (c) the time taken to travel 9090 km.
Show worked solution →

Part (a), build the table. Substitute each tt into d=60td = 60t:

t=0:;d=60×0=0,t=1:;d=60,t=2:;d=120,t=3:;d=180.t = 0:; d = 60 \times 0 = 0, \quad t = 1:; d = 60, \quad t = 2:; d = 120, \quad t = 3:; d = 180.

tt (hours) 00 11 22 33
dd (km) 00 6060 120120 180180
Part (b), distance after 2.52.5 hours
Read up from t=2.5t = 2.5 to the line, then across to the dd-axis. By calculation, d=60×2.5=150d = 60 \times 2.5 = 150 km.
Part (c), time to travel 9090 km
Read across from d=90d = 90 to the line, then down to the tt-axis. By calculation, 90=60t90 = 60t, so t=9060=1.5t = \dfrac{90}{60} = 1.5 hours.
Interpret
The line passes through the origin because at t=0t = 0 the car is at home; its steady climb of 6060 km each hour is the constant speed.
exam5 marksA market stall sells punnets of strawberries for 4dollarseach.Thecost4 dollars each. The cost Cdollarsofbuying dollars of buying npunnetsis punnets is C = 4n.(a)Constructatableofvaluesfor. (a) Construct a table of values for n = 0, 1, 2, 3, 4, 5.(b)Graphtheline.(c)Statethe. (b) Graph the line. (c) State the yinterceptandexplainwhatitmeans.(d)Usethegraphtofindthecostof-intercept and explain what it means. (d) Use the graph to find the cost of 2.5$ punnets-worth (for example, half-punnet trays).
Show worked solution →

Part (a), build the table. Substitute each nn into C=4nC = 4n:

n=0:;C=0,n=1:;C=4,n=2:;C=8,n=3:;C=12,n=4:;C=16,n=5:;C=20.n = 0:; C = 0, \quad n = 1:; C = 4, \quad n = 2:; C = 8, \quad n = 3:; C = 12, \quad n = 4:; C = 16, \quad n = 5:; C = 20.

nn (punnets) 00 11 22 33 44 55
CC ($) 00 44 88 1212 1616 2020
Part (b), graph the line
Put nn on the horizontal axis and CC on the vertical axis, plot the six points and rule a straight line through them. The points line up, so the relationship is linear.
Part (c), the yy-intercept
The line cuts the vertical axis at (0,0)(0, 0), so the yy-intercept is 00. It means that buying 00 punnets costs 00 dollars, which makes sense for a stall that charges only per punnet with no fixed fee.
Part (d), read off 2.52.5 punnets
Read up from n=2.5n = 2.5 to the line, then across to the CC-axis. By calculation, C=4×2.5=10C = 4 \times 2.5 = 10 dollars. So two and a half punnets-worth cost 1010 dollars.
exam5 marksA line has equation 3x+4y=243x + 4y = 24. (a) Find its xx- and yy-intercepts. (b) Show that the point (4,3)(4, 3) lies on the line. (c) Sketch the line and use it to find yy when x=0x = 0, confirming your intercept.
Show worked solution →

Part (a), find the intercepts. For the xx-intercept set y=0y = 0:

3x+4(0)=24,3x=24,x=243=8,3x + 4(0) = 24, \qquad 3x = 24, \qquad x = \frac{24}{3} = 8,

giving (8,0)(8, 0). For the yy-intercept set x=0x = 0:

3(0)+4y=24,4y=24,y=244=6,3(0) + 4y = 24, \qquad 4y = 24, \qquad y = \frac{24}{4} = 6,

giving (0,6)(0, 6).

Part (b), check the point (4,3)(4, 3). Substitute x=4x = 4 and y=3y = 3 into the left-hand side:

3(4)+4(3)=12+12=24.3(4) + 4(3) = 12 + 12 = 24.

This equals the right-hand side, 2424, so (4,3)(4, 3) satisfies the equation and lies on the line.

Part (c), sketch and confirm. Mark (8,0)(8, 0) and (0,6)(0, 6), rule the line through them, and check it passes through (4,3)(4, 3) as a third point. Reading off at x=0x = 0 gives y=6y = 6, which matches the yy-intercept found by calculation, so the sketch is correct.

Related dot points