MathemagiciansLibraryExplorationsDeep Dives
← Mathematics · Upper Secondary
MathematicsUpper Secondary

Drawing straight line graphs from an equation

U2 — Algebra Advancing › U2.4 — Linear and Quadratic GraphsLecture 1 of 5~2700 words

An equation with too many answers to write down

Solve . You get . One equation, one unknown, one answer. That is how equations have worked for years.

Now look at . How many answers does it have? Try : then . Try : then . Try : then . Every number you choose for gives a partner for . So the equation has infinitely many answers.

This is the disruption. You cannot list infinitely many answers. You cannot even list all the answers between and . So how can anyone "see" the solutions of this equation?

The answer is a picture. Each answer is a pair of numbers, and a pair of numbers is a point on a grid. When you mark every answer, the points join up into a line. The graph is the complete list of solutions, drawn instead of written. This lecture shows how to draw it quickly and correctly, and why this picture is always a straight line.

Method 1: a table of values

The most reliable method is the one you have just started. Choose some values of , work out for each, and plot the points. For , take from to :

Point

Show the brackets for negative values. They prevent the most common error, a sign error.

Plot the five points. Then use a ruler to draw one straight line through them, and extend it past the first and last points. The line does not stop at . The answers carry on forever in both directions, so the line does too.

x y O −4 −3 −2 −1 1 2 3 4 −2 2 4 6 8 +1 +2 +1 +2 (−2, −1) (−1, 1) (0, 3) (1, 5) (2, 7) y = 2x + 3
The five points from the table lie on one straight line. Between neighbouring points the step is always the same: 1 across and 2 up.

Why the points line up

Here is a question most textbooks skip. Why should these points lie on a straight line at all? Why not a gentle curve?

Look down the column of the table: . Each value is 2 more than the one before. This is because each step in the table adds 1 to , and the equation doubles . So each step adds exactly 2 to , wherever you are on the line.

Now picture walking from one point to the next. Every walk is 1 across, then 2 up, as the small triangles in the figure show. Because every step has the same shape, the direction never changes. A path whose direction never changes is a straight line.

That is it. That is the whole idea. Equal steps in give equal steps in , and equal steps make a straight line. The number added at each step is the gradient. For , the gradient is 2. The next lecture in this topic explores what the gradient means.

Stop and think

Make a table for with . Do equal steps in give equal steps in ? What does that tell you about its graph?

Show the answer

The values are . The steps are : they grow. So the walk from point to point gets steeper each time, and the direction keeps changing. The graph of is a curve, not a line. This is why you must never join the points of a curve with a ruler. Curves like this one are the subject of a later lecture in this topic.

This idea gives you a free check. In a table for a straight line, the steps in must all be equal. Suppose a student writes the values . The steps are . The pattern breaks at , so the error is in that row: is 5, not 6. On the graph, that point would sit just off the line. A point off the line is not a disaster. It is a message: it shows you exactly which row to check.

Two points fix a straight line, but plot at least three. With two, a mistake still gives a straight line, just the wrong one. The third point is your check.

Every point on the line, and no point off it

The graph is a promise in two directions. Every point on the line satisfies the equation. And every point that satisfies the equation is on the line. So a point that is not on the line does not satisfy it.

So you can test a point without drawing. Does lie on ? , which equals the point's , so yes. The point is 1 unit above the line, so it does not satisfy the equation.

Try this for yourself below. Move the point anywhere on the grid and see what the equation says about it.

Explore — on the line, above it or below it?

Move the point with the two sliders. Find three points that lie on the line y = 2x + 3. Then find one point above the line and one below it, and compare y with 2x + 3 each time.

To test a point, put its into and compare the result with its .

PointIts Where it is
55on the line
on the line
572 above the line
743 below the line

What did you see? On the line, and were equal. Above it, was bigger; below it, smaller. The line is the exact border between the two, an idea that returns with inequalities on graphs.

Method 2: start at the intercept, then step

The table shows two facts that make drawing faster.

First, look at the row . There, is 0, so . The point is where the line crosses the -axis. This is called the -intercept. In , it is simply the number added at the end.

Second, each 1 across gives 2 up, and 2 is the number multiplying . This is the gradient. (Some books call it the slope.)

Drawing a line in the form y = mx + c

When an equation is written as , the number is the -intercept: the line passes through . The number is the gradient: for every 1 unit across to the right, changes by .

To draw it: plot . From there, go 1 across and up (or down, if is negative). Repeat to get a third point. Join with a ruler.

For : plot , then step to and . These are the table's points, found in seconds.

When the gradient is a fraction, take a bigger step so that you land on whole numbers. A gradient of means up for every 1 across. Three steps of 1 across give up. So "3 across, 2 up" describes the same gradient, and it lands on grid points. Worked Example 3 uses this.

Method 3: cover-up, for equations like 3x + 4y = 12

Many equations do not arrive as . The equation is a straight line too. You could rearrange it, but there is a faster way to find two points.

Every point on the -axis has . So cover up the term: , giving . Every point on the -axis has . So cover up the term: , giving . Join the two intercepts, and check with a third point: at , , so , and does lie on the line through and .

Lines that are not y = mx + c

The equation has no in it at all. That means is 3 whatever is: , , . These points form a horizontal line. It fits with .

The equation is different. It says is whatever is: , , . These points form a vertical line. And this line cannot be written as . For one value of , there are infinitely many values of , so no formula "y = something with x" can describe it. Every straight line can be written as . Every straight line except a vertical one can also be written as .

x y O −4 −3 −2 −1 1 2 3 4 −2 −1 1 2 3 4 5 (−2, 3) y = 3 x = −2
is horizontal: every point on it has . is vertical: every point on it has . They cross at , the one point that satisfies both.

Which equations, then, give straight lines? Sort the cards below, and look for the rule.

Sort — straight line or not?

Put each equation in the box where it belongs. Make a quick table in your head if you are not sure: do equal steps in x give equal steps in y?

Straight lines: , , , , . Not straight lines: , , √. A straight line needs and each to the power 1: never multiplied together, under a root, or in the bottom of a fraction.

Equations whose graphs are lines are called linear equations. You can recognise one from how and appear in it, without drawing anything.

Which method, when? If a question asks for a table, give a table. For with a simple gradient, start at the intercept and step. For with numbers that divide neatly, use cover-up. Otherwise rearrange first. When in doubt, use a table: it is slower, but it never fails.

Worked examples

Worked Example 1 — A line that goes down

Draw the graph of for from to .

A range is given, so make a table across that range. Keep the brackets for the negative value: at , .

01234
543210

Each step of 1 in changes by , so the table is consistent and the gradient is : the line slopes down from left to right. It crosses the axes at and . Plot the six points and join them with a ruler.

Worked Example 2 — The same line in disguise

Draw the graph of .

Rearrange. Add to both sides: . Divide every term by 2: . This is the line from the start of the lecture. Two equations that look different describe the same set of points.

Draw. Plot , step 1 across and 2 up to , and again to . Join them.

Check a different way. Cover-up on the original equation: gives , so ✓. And gives , so . Is on ? ✓. Two methods, one line.

Worked Example 3 — A fractional gradient

Draw the graph of .

The intercept is , so plot . The gradient is . Stepping 1 across would land at , which is hard to plot. So step 3 across and 2 up, which is the same gradient: from to , then to . Stepping backwards, 3 left and 2 down, gives .

Check. At : ✓. At : ✓.

Worked Example 4 — Two lines, one meeting point

On the same axes, draw and . Find where they cross.

For : plot and step 1 across, 3 up to . For : plot and step 1 across, 2 down to . Both lines pass through , so that is where they cross.

Now think about what that point means. It is on the first line, so it satisfies the first equation. It is on the second line, so it satisfies the second. It is the one pair that satisfies both: the solution of the simultaneous equations, which the earlier topic found by algebra. Check by substitution: gives , so and ✓.

x y O −2 −1 1 2 3 4 −4 −2 2 4 6 8 (1, 2) (0, −1) (0, 4) y = 3x − 1 y = −2x + 4
The two lines of Worked Example 4 cross at : the only point that satisfies both equations.

The graph shows the meeting point at once, and the algebra gives it exactly. When lines cross between grid lines, a hand-drawn graph gives only an estimate, which is why questions often say "use your graph to estimate".

Three classic mistakes

Trap 1 — Reading m and c before rearranging

In , the gradient is , not 4: the gradient is the number multiplying , wherever it is written. In , the intercept is 3, not 6: and can be read only when the equation starts with alone. Rearrange first, every time.

Trap 2 — Turning the gradient upside down

A gradient of means 3 across and 2 up. Many students step 2 across and 3 up, which draws a gradient of , a steeper line. Say it as a sentence: "for every 3 across, 2 up". And for a negative gradient, the step goes down as you move right.

Trap 3 — Mixing up x = 3 and y = 3

is a vertical line, because every point on it has -coordinate 3. is a horizontal line. If you are unsure, list three points that fit the equation, such as , , , and see which way they line up.

Try it yourself

Work each one on paper first. Open a hint only when you are stuck.

  1. Make a table of values for for from to . Then decide, without drawing, which of these points lie on the line: , , .

    Hint 1

    Work out for each . Check that the values go down in equal steps.

    Hint 2

    To test a point, put its into and compare the result with its .

    Full answer

    For : . Each step is , so the table is consistent. Testing: at , , so is on the line. At , , but the point has , so is not on the line: it is 1 below it. At , , so is on the line. It is where the line crosses the -axis.

  2. Draw in two ways: by cover-up, and by rearranging into . Show that the two methods give the same line.

    Hint 1

    Cover-up: put , then put . Watch the minus sign in front of .

    Hint 2

    To rearrange, move to the other side first: . Then divide every term by .

    Full answer

    Cover-up. : , so , giving . : , so , giving . Rearranging. , so , which is . The intercept is , the same point . The gradient 1.5 is : 2 across and 3 up. From that gives , then , the cover-up point ✓. Check in the original: ✓.

  3. The point lies on the line . Find . Then decide whether lies on the same line.

    Hint 1

    A point on the line satisfies the equation. So put and into it.

    Hint 2

    . Solve this ordinary equation for .

    Full answer

    , so and . Check: ✓. For : , which equals the point's . So yes, lies on the line. Notice what happened in the first part: knowing one coordinate of a point on a line, the equation gave the other.

  4. Temperatures in degrees Fahrenheit (F) and Celsius (C) are linked by . Make a table for and draw the graph, with across and up. On the same axes, draw the line . At what temperature do the two scales show the same number? Find it from your graph, then exactly by algebra.

    Hint 1

    The two lines cross where and are equal. You will need negative values on both axes, and the same scale on both axes helps.

    Hint 2

    For the algebra, put into the formula: .

    Full answer

    The table: gives . These points lie on a straight line with gradient 1.8 and intercept 32. The line passes through , and . The two lines cross at about . Algebra: gives , so , and then ✓. So degrees is the same temperature on both scales. The graph also shows why there is only one such temperature: two straight lines with different gradients cross exactly once.

The bigger idea

In this lecture you turned an equation into a shape, and a point on a grid back into a question about the equation. The line and the equation carry exactly the same information.

This link between algebra and geometry was set out in the 1630s, by two French mathematicians working separately. Pierre de Fermat described it in a short paper written around 1636. René Descartes published it in 1637, in his book La Géométrie. Earlier mathematicians had linked numbers and shapes, but Fermat and Descartes made it a general method: an equation can be studied as a curve, and a curve can be described by an equation. The – grid is called "Cartesian" after Descartes.

Much of what comes later depends on this link. Two lines crossing is a pair of simultaneous equations. A supply line crossing a demand line is a market price. Drawing a straight line from its equation is the simplest case, and it is where all of that begins.

Key concepts in this lesson