Horizontal, vertical and diagonal straight line graphs

By Martin McBride, 2022-05-25
Tags: straight line graphs horizontal vertical diagonal
Categories: gcse graphs
Level:


In this section, we will look at some simple straight-line graphs and their equations.

Here is a video on this topic:

Horizontal lines

This graph shows a horizontal straight line:

Graph of line y = 3

We have marked a few example points that are on the line:

  • (-2, 3)
  • (1, 3)
  • (3, 3)

Each of these points has the same y value of 3, and if you look at the line it is clear that any point on the line will have a y value of 3. So the line has the equation:

Straight line graph formula

The formula of a graph defines all the points that are on the line. In this case, any points that have y equal to 3 are on the line and all other points are not on the line.

This line goes through 3 on the y-axis.

A line that goes through a on the y-axis has the equation:

Straight line graph formula

The position of the line depends on the value of a:

  • When a is greater than 0, the horizontal line is above the x-axis.
  • When a is 0, the horizontal line is on the x-axis.
  • When a is less than 0, the horizontal line is below the x-axis.

For example:

Graph of lines y = a

Vertical lines

This graph shows a vertical straight line:

Graph of line x = 2

These are points marked on the line:

  • (2, -3)
  • (2, 1)
  • (2, 3)

Each of these points has the same x value of 2, and any point on the line will have an x value of 2. The line has the equation:

Straight line graph formula

This line goes through 2 on the x-axis. A line that goes through a on the x-axis has the equation:

Straight line graph formula

The position of the line depends on the value of a:

  • When a is greater than 0, the vertical line is to the right of the y-axis.
  • When a is 0, the vertical line is on the y-axis.
  • When a is less than 0, the vertical line is to the left of the x-axis.

For example:

Graph of lines y = a

Remember that y = a defines all the points with the same y value, so is a horizontal line. x = a defines all the points with the same x value, so is a vertical line.

Main diagonal lines

Here is the main positive-going diagonal line:

Graph of line y = x

This line goes through the origin, in an upwards direction. Here are some of the points the line goes through:

  • (-3, -3)
  • (1, 1)
  • (2, 2)

Every point the line goes through has a y value that is equal to the x value, so the equation is:

Straight line graph formula

Here is the main negative-going diagonal line:

Graph of line y = -x

This line also goes through the origin, this time in a downward direction. Here are some of the points the line goes through:

  • (-2, 2)
  • (2, -2)
  • (3, -3)

In this graph, every point has a y value that is equal to the negative of the x value, so the equation is:

Straight line graph formula

These resources are designed to support GCSE Maths students. They cover a range of useful mathematical topics but are not intended to provide a complete GCSE course or follow any particular exam board's specification. More...

Related articles