Back to National 5 Mathematics

SQA National 5 Mathematics

Straight line graphs

Using y = mx + c and plotting straight lines.

Before you start

  • Know that straight lines have constant gradient.
  • Read coordinates as (x, y).
  • Remember y = mx + c.
National 5 Mathematics lesson

Explanation

A straight line graph can be described by an equation such as y = 2x + 1.

The coefficient of x is the gradient, which tells you how steep the line is. The constant term is the y-intercept.

To draw a line, plot two or more points that satisfy the equation and join them with a straight line.

Visual support

Coordinate grid and gradient

runrisey = mx + c

Key formulae and rules

  • y = mx + c
  • m = change in y / change in x

Watch out

Mixing up x and y coordinates.

Check

Use one coordinate from the graph in your equation. The left and right sides should match.

Exam tip

For graph questions, a table of values is often the simplest way to avoid plotting errors.

Calculator tip

Use brackets for fractions, powers and square roots, then round only at the final line.

Worked examples

Worked example 1

Plot a straight line

Draw y = 2x + 1 for x = −1, 0, 1, 2

  1. When x = −1, y = −1
  2. When x = 0, y = 1
  3. When x = 1, y = 3
  4. When x = 2, y = 5

Answer: Plot (-1, −1), (0, 1), (1, 3), (2, 5) and join them.

Worked example 2

Find an equation from the graph

A line crosses the y-axis at 3 and rises 2 for every 1 across.

  1. The y-intercept is c = 3.
  2. The gradient is m = 2.
  3. Substitute into y = mx + c

So: The equation is y = 2x + 3.

Worked example 3

Check if a point lies on a line

Does (4, 11) lie on y = 3x − 1?

  1. Substitute x = 4 into y = 3x − 1
  2. y = 3(4) − 1 = 11
  3. This matches the y-coordinate.

Answer: Yes, (4, 11) lies on the line.

Watch out

  • Mixing up x and y coordinates.
  • Using the intercept as the gradient.
  • Drawing a line through points that do not satisfy the equation.