What is the gradient of a straight line, what do its sign and size tell you, and how do you find the gradient from a graph or from two points and read the y-intercept?
Find the gradient of a straight line as rise over run, interpret the sign of the gradient and what steepness means, read the y-intercept from a graph, and calculate the gradient between two points
A focused answer to the HSC Maths Standard 2 dot point on gradient and intercept. Gradient as rise over run, what positive, negative, zero and undefined gradients mean and what steepness tells you, reading the y-intercept off a graph, and the gradient formula between two points, with worked ramp, hourly-pay and phone-plan examples.
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
The gradient of a straight line measures how steeply it slopes, and it is the single most important number a line carries. NESA wants you to find it two ways, read its meaning, and pair it with the line's starting value. Four skills are bundled here, and a question can test any of them: find a gradient from a graph by counting the rise over the run; find the gradient between two given points using the formula; read the sign of a gradient (positive, negative, zero or undefined) and say what its size tells you about steepness; and read the -intercept straight off a graph. In a real context the gradient is always a rate (dollars per hour, dollars per kilometre, metres climbed per metre across) and the -intercept is always the starting value (a fixed fee, a flagfall, a height at the start). So interpreting them in words is part of the dot point too.
The deeper idea worth carrying through all of it is that the gradient is a rate of change: it says how much moves for each one-unit step in . That is why a steeper line means a faster change, a negative gradient means is falling as grows, and a flat line (zero gradient) means never changes. The marks come from a correctly drawn rise/run triangle, subtracting the coordinates in a consistent order, dividing rise by run the right way up, and stating the sign and units. Marks are lost in predictable ways. The usual slips are dividing run by rise, subtracting the two points in opposite orders top and bottom, reading a falling line as positive, and confusing the -intercept with the -intercept.
The answer
Gradient as rise over run
The gradient of a line, usually called , is the vertical rise divided by the horizontal run between any two points on it:
To find it from a graph, pick two points where the line passes cleanly through grid corners, then build a right-angled triangle: go across from the first point to under the second (that horizontal distance is the run), then up or down to the second point (that vertical distance is the rise). Divide the rise by the run. Because a straight line has the same steepness everywhere, it does not matter which two points you choose or how big you make the triangle: the ratio is always the same, which is exactly what makes the gradient a single number for the whole line.
The line below passes through and . Going across from to is a run of , and going up from to is a rise of , so the gradient is . A bigger triangle, say from all the way across, would give the same ratio.
So . The order matters less than the consistency: as long as you go across and up in the same direction, the signs look after themselves.
The sign of the gradient: positive, negative, zero and undefined
The sign of the gradient tells you which way the line tilts, before you even look at how steep it is. Read every line left to right (the direction of increasing ) and ask what is doing.
- A positive gradient () means the line goes up to the right: as increases, increases. The rise and the run have the same sign.
- A negative gradient () means the line goes down to the right: as increases, decreases. A positive run pairs with a negative rise.
- A zero gradient () means a horizontal line: there is no rise, so and never changes. These are the lines .
- An undefined gradient means a vertical line: there is no run, so asks you to divide by zero, which is not allowed. These are the lines . We say the gradient is undefined, not zero or infinite.
The three panels below show the first three cases on identical axes, so you can compare the tilt at a glance.
A vertical line is the fourth case and does not fit a panel like these, because it would be a single upright stroke with no run; remember it separately as the undefined gradient, the line .
What steepness means: the size of the gradient
While the sign tells you the direction, the size of the gradient (its value ignoring any minus sign) tells you the steepness. A larger size is a steeper line, because changes more for each step across. A gradient of climbs three times as fast as a gradient of ; a gradient of is gentle, rising only half a unit per unit across. To compare steepness, compare the absolute values: a line of gradient is steeper than a line of gradient , because is bigger than , even though one falls and one rises. This is why a wheelchair ramp built to the Australian standard of at most in (a gradient of about ) looks almost flat, while a steep driveway at in (a gradient of ) is noticeably harder to climb: the bigger the number, the steeper the slope.
Reading the y-intercept from a graph
The -intercept is the value of where the line crosses the vertical axis, the point . You read it straight off a graph by finding where the line cuts the -axis: no calculation needed. The letter is the usual name for it. In a real context the -intercept is the starting value of the relationship, what equals when is zero: a fixed monthly fee before you use any data, a taxi flagfall before the car moves, a tank's level before you start draining it.
Reading it correctly means looking at the vertical axis. A frequent slip is to read the -intercept (where the line crosses the horizontal axis) by mistake; the -intercept is always the crossing on the up-and-down axis. The diagram below shows a phone-plan cost line: it cuts the vertical axis at , so the -intercept is x = 10x = 302025 dollars to 10 dollars, giving , that is, $0.50 per GB.
Finding the gradient between two points
When you are given two points rather than a graph, you do not need to plot anything: the gradient formula computes the rise over run straight from the coordinates. For points and ,
The top is the rise (the difference in the -values) and the bottom is the run (the difference in the -values). The one rule that prevents almost every error is to subtract in the same order top and bottom: if you start with the second point's on top, start with the second point's on the bottom. Take and for a worker's pay against hours:
The gradient is , which in context is the pay rate of \tfrac{56 - 140}{2 - 5} = \tfrac{-84}{-3} = 28\tfrac{140 - 56}{2 - 5} = \tfrac{84}{-3} = -28$, which gives the wrong sign.
How exam questions ask about gradient and intercept
The wording tells you which skill to reach for:
- "Find the gradient of the line" with a graph means draw a rise/run triangle between two grid points and divide rise by run.
- "Find the gradient of the line through and " means use the formula , keeping the subtraction order consistent.
- "State whether the gradient is positive or negative" (or "is the line increasing or decreasing?") is testing the sign: up to the right is positive and increasing, down to the right is negative and decreasing.
- "Which line is steeper?" is testing the size: compare the gradients ignoring their signs.
- "Write down the -intercept" or "where does the line cut the -axis?" means read the value off the vertical axis at .
- "What does the gradient represent?" or "interpret the -intercept in this context" wants words: the gradient is the rate (with units like dollars per hour) and the intercept is the starting value (a fixed fee or initial amount).
Why the order of subtraction does not change the gradient
It is worth seeing why subtracting the two points in either order gives the same gradient. This is the reasoning that stops the most common formula error from worrying you. The gradient is a ratio of two differences, and if you swap which point comes first, both the top and the bottom change sign:
In the second version the top is the negative of the first top and the bottom is the negative of the first bottom, so the two minus signs cancel and the value is identical. What you must not do is take on top but on the bottom: then only one sign flips, and the gradient comes out with the wrong sign, turning an increasing line into a decreasing one. The safe habit is to write the second point's coordinates first in both the top and the bottom, every time. There is one edge case the formula handles automatically and one it cannot. A horizontal line has , so the top is and as expected. A vertical line has , so the bottom is , and dividing by zero is undefined, which is exactly why a vertical line has no gradient.
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.
2022 HSC-style2 marksA rainwater tank is being drained. Its volume in litres is shown by a straight line on a volume-versus-time graph that passes through and , where is the time in hours. Find the gradient of the line and state what it represents.Show worked answer →
Apply the gradient formula. Subtract in the same order, on top and on the bottom, using the points and :
State what it represents. The gradient is . In context it is the rate at which the tank empties: the volume falls by litres each hour, so L per hour. The negative sign shows the volume is decreasing.
Markers reward the substituted formula with a consistent subtraction order, the value , and an interpretation as a draining rate (with the negative sign explained) in litres per hour.
2024 HSC-style4 marksTwo e-scooter hire apps each charge an unlock fee plus a rate per minute, shown as straight lines on a cost-versus-time graph (cost in dollars, in minutes). App A passes through and . App B passes through and . (a) Find the gradient of each line and say what it represents. (b) State which app charges the steeper per-minute rate. (c) Find the cost of a minute ride with App A.Show worked answer →
Part (a), gradient of App A. Use and :
So App A charges $0.40 per minute. Gradient of App B, using and :
So App B charges $0.30 per minute. Each gradient is the rate per minute of riding.
Part (b), which is steeper. Steepness is the size of the gradient. Since , App A has the steeper per-minute rate.
Part (c), a minute ride with App A. App A meets the vertical axis at , so the $3 unlock fee is its -intercept. Add the rate times the minutes:
The ride costs dollars.
Markers reward both gradients with units, the steeper rate identified by comparing sizes, the unlock fee read as the intercept, and the final cost of $13 for App A.
Practice questions
Original practice questions graded from foundation to exam level, each with a full worked solution. Try them before revealing the solution.
foundation2 marksA straight line passes through the points and . Find its gradient as rise over run.Show worked solution →
Find the rise. The rise is the change in the vertical () values from the first point to the second:
Find the run. The run is the matching change in the horizontal () values, taken in the same order:
Divide rise by run. The gradient is
State the answer. The gradient is . It is positive, so the line slopes up to the right, rising units for every units across.
foundation2 marksFor each line, state whether the gradient is positive, negative, zero or undefined: (a) a line sloping up to the right; (b) a horizontal line; (c) a line sloping down to the right; (d) a vertical line.Show worked solution →
- Part (a), up to the right
- A line going up as you move right has a positive gradient, because the rise and the run have the same sign.
- Part (b), horizontal
- A flat line has no rise, so . The gradient is zero.
- Part (c), down to the right
- A line going down as you move right has a negative gradient, because a positive run goes with a negative rise.
- Part (d), vertical
- A vertical line has no run, so , and you cannot divide by zero. The gradient is undefined.
core2 marksA part-time worker is paid the same rate for every hour. After hours she has earned 5140 dollars. Find the gradient of the pay line and state what it represents.Show worked solution →
Set up the two points. Put hours across and pay up, giving the points and .
Apply the gradient formula. Subtract in the same order, top and bottom:
State the answer. The gradient is . In this context it is the pay rate: the worker earns $28 dollars for each extra hour worked, that is, $28 per hour.
Quick check. At hours, ; at hours, . The rate is the same, confirming a constant gradient.
core3 marksA taxi fare is shown by a straight line on a cost-versus-distance graph. The line crosses the vertical axis at (2, 8)(5, 14)xy$-intercept and what it means. (b) Find the gradient and what it means.Show worked solution →
Part (a), the -intercept. The line cuts the vertical axis at , so the -intercept is . It is the cost when the distance is km, that is, the flagfall of $4 dollars charged just for getting in.
Part (b), find the gradient. Use the two given points and :
Interpret the gradient. The gradient is , the rate per kilometre: the fare rises $2 dollars for each extra km travelled, so $2 per km.
Tie it together. The fare starts at the $4 flagfall (the intercept) and climbs at $2 per km (the gradient), so for example km costs dollars, matching the point .
exam4 marksA straight line passes through the points and . (a) Find the gradient. (b) State whether the line is increasing or decreasing, and explain how the gradient tells you. (c) Find the gradient of a second line through and , and state which of the two lines is steeper.Show worked solution →
Part (a), gradient of the first line. Subtract the coordinates in the same order:
Part (b), increasing or decreasing. The gradient is , which is negative, so the line is decreasing: it slopes down to the right, falling units for every unit across. A negative rise with a positive run gives the negative sign.
Part (c), the second line and which is steeper. For the line through and :
Steepness is measured by the size of the gradient, ignoring the sign. Comparing with , the first line is steeper because .
exam5 marksA mobile phone plan charges a fixed monthly fee plus a set rate for each extra gigabyte (GB) of data. The monthly cost dollars for extra GB is shown by a straight line through and . (a) Find the gradient and say what it means. (b) The line meets the vertical axis at ; state the -intercept and what it means. (c) Use your results to find the cost for extra GB in a month.Show worked solution →
Part (a), find the gradient. Use the two points and :
In context the gradient is the rate per gigabyte: each extra GB adds $0.50 dollars to the bill, that is, $0.50 per GB.
Part (b), the -intercept. The line meets the vertical axis at , so the -intercept is . It is the cost when extra GB, that is, the fixed monthly fee of $20 dollars you pay before any extra data.
Part (c), cost for extra GB. The cost is the fixed fee plus the rate times the GB:
State the answer. For extra GB the monthly cost is 200.5$) sets how fast it climbs.
Related dot points
- 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.
- Use the gradient-intercept form y = mx + b: read the gradient m and the y-intercept b directly from the equation (rearranging first if needed), write the equation of a line from its graph, and sketch a line from m and b
A focused answer to the HSC Maths Standard 2 dot point on the gradient-intercept formula. How to read the gradient m and y-intercept b straight from y = mx + b, rearrange an equation into that form first, write the equation of a drawn line, sketch a line from m and b, and build a real cost model, with worked Australian examples.
- Construct a linear model y = mx + b for a practical situation made of a fixed amount plus a constant rate, interpret the gradient as the rate and the y-intercept as the fixed starting amount in context, and use the model to predict an output and to find the input that gives a required output
A focused answer to the HSC Maths Standard 2 dot point on linear models. How to build y = mx + b from a fixed amount plus a rate, interpret the gradient and y-intercept in words with units, predict a value and read the model backwards, with worked plumber, taxi, mobile-plan and tank-filling examples.
- Recognise and model direct variation y = kx, where one quantity is a constant multiple of another, find the constant of variation k from a data pair, write and use the equation, identify direct variation from a constant ratio in a table or a straight-line graph through the origin, and contrast it with simple inverse variation y = k/x
A focused answer to the HSC Maths Standard 2 dot point on direct variation. How y = kx works, finding the constant of variation k from a data pair, why the graph is a straight line through the origin, recognising direct variation from a table or graph, and a brief contrast with inverse variation y = k/x, with worked pay, cost and speed examples.
- Use the relationship between distance, speed and time to solve problems, rearranging the formula to find any of the three quantities and converting between km/h and m/s
A focused answer to the HSC Maths Standard 2 dot point on distance, speed and time. The triangle and how to rearrange it for distance, speed or time, average speed over a whole journey, keeping units consistent, converting between km/h and m/s with the factor 3.6, and reading a distance-time graph, with worked Australian examples.