Straight-Line Graphs
Straight-Line Graphs
Coordinates
To fix a point in two dimensions (2D), its position is given in relation
to a point called the origin. Through the origin, axes are drawn
perpendicular to each other. The horizontal axis is known as the x-axis,
and the vertical axis is known as the y-axis.
y
5
3
A
2
0
1 2 3 4 5 x
The x-axis is numbered from left to right. The y-axis is numbered from
bottom to top.
The position of point A is given by two coordinates: the x-coordinate
first, followed by the y-coordinate. So the coordinates of point A are
(3, 2).
A number line can extend in both directions by extending the x- and
y-axes below zero, as shown in the grid below:
y
4
D
3
–4 –3 –2 –1 0 1 2 3 4 x
–1
–2
C B
–3
–4
258
Reading scales
Exercise 21.1 1 Draw a pair of axes with both x and y from −8 to +8.
Mark each of the following points on your grid:
a A = (5, 2) b B = (7, 3) c C = (2, 4)
d D = (−8, 5) e E = (−5, −8) f F = (3, −7)
g G = (7, −3) h H = (6, −6)
2 A = (3, 2) B = (3, −4) C = (−2, −4) D = (−2, 2)
Draw a separate grid for each of Questions 2−4 with x- and y-axes from
−6 to +6. Plot and join the points in order to name each shape drawn.
3 E = (1, 3) F = (4, −5) G = (−2, −5)
4 H = (−6, 4) I = (0, −4) J = (4, −2) K = (−2, 6)
Exercise 21.2 Draw a pair of axes with both x and y from −10 to +10.
1 Plot the points P = (−6, 4), Q = (6, 4) and R = (8, −2).
Plot point S such that PQRS when drawn is a parallelogram.
a Draw diagonals PR and QS. What are the coordinates of their
point of intersection?
b What is the area of PQRS?
2 On the same axes, plot point M at (−8, 4) and point N at (4, 4).
a Join points MNRS. What shape is formed?
b What is the area of MNRS?
c Explain your answer to Question 2b.
3 On the same axes, plot point J where point J has y-coordinate +10 and
JRS, when joined, forms an isosceles triangle. What is the x-coordinate
of all points on the line of symmetry of triangle JRS?
Exercise 21.3 1 a On a grid with axes numbered from −10 to +10 draw a hexagon
ABCDEF with centre (0, 0), points A(0, 8) and B(7, 4) and two lines
of symmetry.
b Write down the coordinates of points C, D, E and F.
2 a On a similar grid to Question 1, draw an octagon PQRSTUVW
which has point P(2, −8), point Q(−6, −8) and point R(−7, −5).
PQ = RS = TU = VW and QR = ST = UV = WP.
b List the coordinates of points S, T, U, V and W.
c What are the coordinates of the centre of rotational symmetry of
the octagon?
Reading scales
Exercise 21.4 1 The points A, B, C and D are not at whole number points on the
number line. Point A is at 0.7.
What are the positions of points B, C and D?
A B C D
0 1 2 3 4 5 6
2 On this number line, point E is at 0.4.
What are the positions of points F, G and H?
E F G H
0 1 2
259
21 STRAIGHT-LINE GRAPHS
4 5 6 7
4 Point P is at position 0.4 and point W is at position 9.8.
What are the positions of points Q, R, S, T, U and V?
P Q R S T U V W
0 1 2 3 4 5 6 7 8 9 10
–2 –1 0 1 2 x –4 –3 –2 –1 0 1 2 3 4 x
–1
–1 G –2
–3 F
C B
–2 –4
0 x
–10 –9 –8 –7 –6 –5 –4 –3 –2 –1 1 2 3 4 5 6 7 8 9 10
–1
–2
–3
–4
260
The gradient of a straight line
The lines have some properties in common (e.g. they are straight),
but also have differences. One of their differences is that they have
different slopes. The slope of a line is called its gradient.
The gradient of a straight line is constant, i.e. it does not change.
The gradient of a straight line can be calculated by considering the
coordinates of any two points on the line.
On the line below, two points A and B have been chosen.
y
4
A
3
0 x
–4 –3 –2 –1 1 2 3 4
–1
–2
B
–3
–4
The coordinates of the points are A(2, 3) and B(−1, −3). The gradient is
calculated using the following formula:
vertical distance between two points
Gradient =
horizontal distance between two points
1
Vertical distance
0 x
–4 –3 –2 –1 1 2 3 4
–1
–2
B
–3
Horizontal distance
–4
261
21 STRAIGHT-LINE GRAPHS
Worked example
Calculate the gradient of the line shown below.
y
4
0 x
–7 –6 –5 –4 –3 –2 –1 1 2 3 4 5 6 7 8 9 10
–1
–2
–3
–4
Choose two points on the line, e.g. (−4, 3) and (8, −3).
y
4
(–4, 3)
3
0 x
–7 –6 –5 –4 –3 –2 –1 1 2 3 4 5 6 7 8 9 10
–1
–2
(8, –3)
–3
–4
Note: The gradient is not affected by which point is chosen as point 1 and which
is chosen as point 2. In the example above, if point 1 was (8, −3) and point 2
(−4, 3), the gradient would be calculated as:
y2 − y1 3 − ( −3)
Gradient = =
x 2 − x1 −4 − 8
= 6 = −1
−12 2
262
The gradient of a straight line
To check if the sign of the gradient is correct, the following guideline is useful.
A line sloping this way will A line sloping this way will
have a positive gradient have a negative gradient
A large value for the gradient implies that the line is steep. The line on the
right below will have a greater value for the gradient than the line on the left
as it is steeper.
Exercise 21.6 1 For each of the following lines, select two points on the line and then
calculate its gradient.
a y
4
0 x
–5 –4 –3 –2 –1 1 2 3 4
–1
–2
–3
–4
b y
4
0 x
–3 –2 –1 1 2 3 4
–1
–2
–3
–4
263
21 STRAIGHT-LINE GRAPHS
Exercise 21.6 c y
(cont) 4
0 x
–5 –4 –3 –2 –1 1 2 3
–1
–2
–3
–4
d y
4
0 x
–6 –5 –4 –3 –2 –1 1 2 3 4 5 6
–1
–2
–3
–4
e y
4
0 x
–4 –3 –2 –1 1 2 3 4
–1
–2
–3
–4
264
The equation of a straight line
f y
4
0 x
–4 –3 –2 –1 1 2 3 4
–1
–2
–3
–4
2 From your answers to Question 1e, what conclusion can you make
about the gradient of any horizontal line?
3 From your answers to Question 1f, what conclusion can you make
about the gradient of any vertical line?
4 The graph below shows six straight lines labelled A−F.
y
C
D A E
0 x
Six gradients are given below. Deduce which line has which gradient.
1
Gradient = 2 Gradient is undefined Gradient = 2
265
21 STRAIGHT-LINE GRAPHS
Worked examples
a By looking at the coordinates of some of the points on the line below,
establish the equation of the straight line.
y
x y
5
1 4
4
2 4
3
2
3 4
1 4 4
5 4
0
1 2 3 4 5 6 7 8 x 6 4
Some of the points on the line have been identified and their coordinates
entered in a table above. By looking at the table it can be seen that the only
rule all the points have in common is that y = 4.
Hence the equation of the straight line is y = 4.
b By looking at the coordinates of some of the points on the line, establish
the equation of the straight line.
y x y
8
1 2
7
6 2 4
5 3 6
4 4 8
3
2
1
0 x
1 2 3 4 5 6 7 8
Once again, by looking at the table it can be seen that the relationship
between the x- and y-coordinates is that each y-coordinate is twice the
corresponding x-coordinate.
Hence the equation of the straight line is y = 2x.
Exercise 21.7 1 In each of the following, identify the coordinates of some of the points
on the line and use these to find the equation of the straight line.
a y b y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1 1
0 0
266 1 2 3 4 5 6 7 8 x 1 2 3 4 5 6 7 8 x
The equation of a straight line
c y d y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1 1
0 x 0
1 2 3 4 5 6 7 8 1 2 3 4 5 6 7 8 x
e y f y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1 1
0 0
1 2 3 4 5 6 7 8 x 1 2 3 4 5 6 7 8 x
g y h y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1 1
–4 –3 –2 –1 0 1 2 3 4 5
x –4 –3 –2 –1 0 1 2 3 4 5
x
267
21 STRAIGHT-LINE GRAPHS
Exercise 21.8 1 In each of the following, identify the coordinates of some of the points
on the line and use these to find the equation of the straight line.
a y b y
6 6
5 5
4 4
3 3
2 2
1 1
–4 –3 –2 –1 0 1 2 3 x –4 –3 –2 –1 0 1 2 3 x
–1 –1
–2 –2
–3 –3
c y d y
6 8
5 7
4 6
3 5
2 4
1 3
2
–4 –3 –2 –1 0 1 2 3 x
–1 1
–2
–4 –3 –2 –1 0 1 2 3 x
–3 –1
–2
–3
e y f y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1 1
–4 –3 –2 –1 0 1 2 3 x –4 –3 –2 –1 0 1 2 3 x
–1 –1
–2 –2
–3 –3
268
The equation of a straight line
–4 –3 –2 –1 0 1 2 3 x –4 –3 –2 –1 0 1 2 3 x
–1 –1
–2 –2
–3 –3
c y d y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1 1
–4 –3 –2 –1 0 1 2 3 x –4 –3 –2 –1 0 1 2 3 x
–1 –1
–2 –2
–3 –3
e y f y
8 8
7 7
6 6
5 5
4 4
3 3
2 2
1
1
–4 –3 –2 –1 0 1 2 3 x
–4 –3 –2 –1 0 1 2 3 x –1
–1
–2
–2
–3
–3
269
21 STRAIGHT-LINE GRAPHS
Exercise 21.8 3 a For each of the graphs in Questions 1 and 2, calculate the gradient
of the straight line.
(cont) b What do you notice about the gradient of each line and its equation?
c What do you notice about the equation of the straight line and
where the line intersects the y-axis?
4 Copy the diagrams in Question 1. Draw two lines on each diagram
parallel to the given line.
a Write the equation of these new lines in the form y = mx + c.
b What do you notice about the equations of these new parallel lines?
5 In Question 2, you have an equation for these lines in the form y = mx + c.
Change the value of the intercept c and then draw the new line.
What do you notice about this new line and the first line?
Gradient ‘ m ’
0 x
By looking at the equation of a straight line written in the form
y = mx + c, it is therefore possible to deduce the line’s gradient and
intercept with the y-axis without having to draw it.
Worked examples
a Calculate the gradient and y-intercept of the following straight lines:
i y = 3x − 2 gradient = 3
y-intercept = −2
ii y = −2x + 6 gradient = −2
y-intercept = 6
b Calculate the gradient and y-intercept of the following straight lines:
i 2y = 4x + 2
This needs to be rearranged into gradient-intercept form (i.e. y = mx + c).
y = 2x + 1 gradient = 2
y-intercept = 1
270
Equation of a straight line in the form ax + by + c = 0
ii y − 2x = −4
Rearranging into gradient-intercept form, we have:
y = 2x − 4 gradient = 2
y-intercept = −4
iii −4y + 2x = 4
Rearranging into gradient-intercept form, we have:
y = 1x−1 gradient = 12
2
y-intercept = −1
y+3
iv = −x + 2
4
Rearranging into gradient-intercept form, we have:
y + 3 = –4 x + 8
y = − 4x + 5 gradient = −4
y-intercept = 5
Worked examples
a The equation of a straight line is given as y = 1 x + 3 . Write this in the form
2
ax + by + c = 0, where a, b and c are integers.
Rearranging the equation so that all the terms are on one side produces
1
x − y + 3 = 0.
2
However, there is still a fraction in the equation and the question stated
that a, b and c are integers.
To eliminate the fraction, both sides of the equation are multiplied by two.
This gives: x − 2 y + 6 = 0
2 1
b The equation of a straight line is given as y = x − . Write this in the form
5 3
ax + by + c = 0 , where a, b and c are integers.
Rearranging the equation so that all the terms are on the same side gives:
2
x− y− 1 = 0
5 3
To eliminate the fractions, multiply both sides by 15 to give 6 x − 15 y − 5 = 0.
271
21 STRAIGHT-LINE GRAPHS
Exercise 21.9 For the following linear equations, calculate both the gradient and
y-intercept in each case.
1 a y = 2x + 1 b y = 3x + 5 c y=x−2
d y = 12 x + 4 e y = −3x + 6 f y = − 23 x + 1
g y = −x h y = −x − 2 i y = −(2x − 2)
2 a y − 3x = 1 b y + 12 x − 2 = 0 c y + 3 = −2x
d y + 2x + 4 = 0 e y − 14 x − 6 = 0 f −3x + y = 2
g 2+y=x h 8x − 6 + y = 0 i −(3x + 1) + y = 0
3 a 2y = 4x − 6 b 2y = x + 8 c 12 y = x − 2
d 14 y = −2x + 3 e 3y − 6x = 0 f 13 y + x = 1
g 6y − 6 = 12x h 4y − 8 + 2x = 0 i 2y − (4x − 1) = 0
4 a 2x − y = 4 b x−y+6=0 c −2y = 6x + 2
d 12 − 3y = 3x e 5x − 12 y = 1 f − 23 y + 1 = 2x
g 9x − 2 = −y h −3x + 7 = − 12 y i −(4x − 3) = −2y
y+2
5 a = 1x b
y−3
=2 c
y–x
=0
4 2 x 8
1
2 y – 3x 3y – 2 y–1
d =6 e = –3 f 2 = –2
2 x x
3x – y 6 – 2y –( x + 2 y)
g =6 h =2 i =1
2 3 5x
3x – y −x + 2y y−x
6 a =2 b 4
= y+1 c x+y =2
y
–(6 x + y) 2x – 3y + 4
d 1y = 1x e 2
= y+1 f 4
=4
7 a
y + 1 3y – 2
+ = –1 b
x
+ 1 =3
x 2x y + 1 2y + 2
–(– y + 3 x) –( x – 2 y) – (– x – 2 y)
c =1 d = –2
–(6 x – 2 y) 4+x–y
− ( 2 x + 3 y) 2 3 ( x − 2 y) 2x x
d 3x
=3 e −4=0 f 5 y + − y = −1
x
272
Parallel lines and their equations
Worked examples
a traight line has equation y = 2 x + 4.
A straight 4 . Another
A straight line has equation
y = −2 x + 4.
4. E
Explain,
xplain, giving reasons, whether the two lines are parallel to
each other or not.
ey are not parallel as one has a gradient of 2, the other has a gradient of –2.
They
b raight line has equation 4 x – 2 y + 1 = 0.
A straight
other straight line has equation 2 x – 4 = 1.
Another
y
Explain,
plain, giving reasons, whether the two lines are parallel to each other or not.
Rearranging the equations into gradient-intercept form gives:
2x – 4
4x – 2y + 1 = 0 =1
y
2y = 4x + 1 y = 2x − 4
y = 2x + 1
2
With both equations written in gradient-intercept form, it is possible to see
that
hat both lines have a gradient of 2 and are therefore parallel.
c A straight
raight line A has equation y = −3x
3x + 6. A second line B is parallel to
line A and passes through the point with coordinates (−4,
( 10).
Calculate the equation of line B.
As line B is a straight line it must take the form y = mx + c.
As it is parallel to line A, its gradient must be −3.
Because line B passes through the point (−4, 10), these values can be
substituted into the general equation of the straight line to give:
10 = −3 × (−4) + c
Rearranging to find c gives: c = −2
The equation of line B is therefore y = −3x − 2.
Exercise 21.10 1 A straight line has equation y = x + 43 . Write down the equation of
another straight line parallel to it.
2 A straight line has equation y = −x + 6. Which of the following lines
is/are parallel to it?
a y=−x−2 b y=8−x
c y=x−6 d y=−x
3 A straight line has equation 3y − 3x = 4. Write down the equation of
another straight line parallel to it.
4 A straight line has equation y = −x + 6. Which of the following lines
is/are parallel to it?
a 2(y + x) = −5 b −3x − 3y + 7 = 0
1
c 2y = −x + 12 d y + x = 10
273
21 STRAIGHT-LINE GRAPHS
Exercise 21.10 5 Find the equation of the line parallel to y = 4x − 1 that passes through
(0, 0).
(cont)
6 Find the equations of lines parallel to y = −3x + 1 that pass through
each of the following points:
a (0, 4) b (−2, 4) c − 5, 4 ( 2 )
7 Find the equations of lines parallel to x − 2y = 6 that pass through each
of the following points:
a (−4, 1) ( ) b 1, 0
2
Worked examples
a Plot the line y = x + 3. y
8
To identify two points, simply choose y=x+3
two values of x. Substitute these 7
into the equation and calculate their 6
corresponding y values. 5
When x = 0, y=3 4
3
When x = 4, y = 7
2
Therefore two of the points on the line
1
are (0, 3) and (4, 7).
0 x
The straight line y = x + 3 is plotted below. 1 2 3 4 5 6 7 8
–4 –3 –2 –1 0 1 2 3 x
–1
–2
y = –2x + 4
–3
274
Graphical solution of simultaneous equations
Worked example
a By plotting both of the following equations on the same axes, find a
common solution.
x+y=4 (1)
x−y=2 (2)
y
4
x y=4
x y=2
0 1 2 3 4 x
When both lines are plotted, the point at which they cross gives the
common solution as it is the only point which lies on both lines.
Therefore the common solution is the point (3, 1).
275
21 STRAIGHT-LINE GRAPHS
Worked example
The coordinates of two points are (1, 3) and y
(5, 6). Draw a pair of axes, plot the given 8
points and calculate the distance between 7
them. (5, 6)
6
By dropping a vertical line from the point 5
(5, 6) and drawing a horizontal line from a 3
4
(1, 3), a right-angled triangle is formed. The
3
length of the hypotenuse of the triangle is (1, 3) 4
the length we wish to find. 2
1
Using Pythagoras’ theorem, we have:
a 2 = 32 + 42 = 25 0
1 2 3 4 5 6 7 8 x
a = 25 = 5
The length of the line segment is 5 units.
276
The midpoint of a line segment
To find the distance between two points directly from their coordinates, use
the following formula:
d= ( x1 − x2 )2 + ( y1 − y2 )2
Worked example
Without plotting the points, calculate the distance between the points (1, 3)
and (5, 6).
d = (1 − 5 ) 2 + ( 3 − 6 ) 2
= ( −4 ) 2 + ( −3) 2
= 25 = 5
The distance between the two points is 5 units.
Worked examples
a Find the coordinates of the midpoint of the line segment AB where A is
(1, 3) and B is (5, 6).
The x-coordinate of the midpoint will be 1 + 5 = 3
2
The y-coordinate of the midpoint will be 2 6 = 4.5
3 +
277
21 STRAIGHT-LINE GRAPHS
Worked example
Calculate the equation of the straight line passing through the points (−3, 3)
and (5, 5).
The equation of any straight line can be written in the general form y = mx + c.
Here we have:
gradient = 5 – 3 = 2
5 – (–3) 8
gradient = 1
4
The equation of the line now takes the form y = 14 x + c.
Since the line passes through the two given points, their coordinates must
satisfy the equation. So to calculate the value of ‘c’ the x and y coordinates of
one of the points are substituted into the equation. Substituting (5, 5) into the
equation gives:
5 = 1 ×5+c
4
5= 5+c
4
Therefore c = 5 − 1 14 = 3 43
The equation of the straight line passing through (−3, 3) and (5, 5) is:
y= 1x+3 3
4 4
Exercise 21.14 Find the equation of the straight line which passes through each of the
following pairs of points:
1 a (1, 1) (4, 7) b (1, 4) (3, 10) c (1, 5) (2, 7)
d (0, −4) (3, −1) e (1, 6) (2, 10) f (0, 4) (1, 3)
g (3, −4) (10, −18) h (0, −1) (1, −4) i (0, 0) (10, 5)
278
Perpendicular lines
Perpendicular lines
The two lines shown below are perpendicular to each other.
y
4
3
A
2
B
1
–9 –8 –7 –6 –5 –4 –3 –2 –1 0 1 2 3 4 5 6 7 8 x
–1
–2
–3
–4
3
D C
2
–7 –6 –5 –4 –3 –2 –1 0 1 2 3 4 5 6 7 x
–1
–2
–3
–4
279
21 STRAIGHT-LINE GRAPHS
This is in fact the case for the gradients of any two perpendicular lines.
If two lines L1 and L2 are perpendicular to each other, the product of
their gradients m1 and m 2 is −1.
i.e. m1m 2 = −1
Therefore the gradient of one line is the negative reciprocal of the
other line.
i.e. m1 = − m1
2
Worked examples
a i Calculate the gradient of the line joining the two points (3, 6) and (1, −6).
6 – (–6)
12
Gradient = 3 – 1 = 2 = 6
ii Calculate the gradient of a line perpendicular to the one in part i above.
m1 = − m12 , therefore the gradient of the perpendicular line is − 16 .
iii The perpendicular line also passes through the point (−1, 6). Calculate
the equation of the perpendicular line.
The equation of the perpendicular line will take the form y = mx + c.
As its gradient is − 16 and it passes through the point (−1, 6), this can be
substituted into the equation to give:
6 = − 16 × (−1) + c
Therefore c = 35 .
6
The equation of the perpendicular line is y = − 16 x + 35
6
.
280
Perpendicular lines
C
D
B(10, 5)
A(4, 3)
0 x
Calculate:
a the gradient of the line AB
b the equation of the line passing through A and B
c the gradient of the line AD
d the equation of the line passing through A and D
e the equation of the line passing through B and C
f the coordinates of C
g the coordinates of D
h the equation of the line passing through C and D
i the length of the sides of the square to 1 d.p.
j the coordinates of the midpoint of the line segment AC.
4 The diagram below shows a right-angled isosceles triangle ABC,
where AB = AC.
The coordinates of A and B are given.
y
C
B(9, 2)
0 x
A(–1, –2)
281
21 STRAIGHT-LINE GRAPHS
Student assessment 1
1 For each of the following lines, select two points on the line and
then calculate its gradient.
a a) y
9
8
7
6
5
4
3
2
1
–5 –4 –3 –2 –1 0 1 2 3 4 x
–1
–2
–3
–4
b y
9
8
7
6
5
4
3
2
1
–5 –4 –3 –2 –1 0 1 2 3 4 x
–1
–2
–3
–4
282
Perpendicular lines
2 Find
a)the equation of the straight line for each of the following:
a y
9
8
7
6
5
4
3
2
1
–5 –4 –3 –2 –1 0 1 2 3 4 x
–1
–2
–3
–4
b)
b y
9
8
7
6
5
4
3
2
1
–5 –4 –3 –2 –1 0 1 2 3 4 x
–1
–2
–3
–4
283
21 STRAIGHT-LINE GRAPHS
C
D(0, 6)
A(4, 3) B(9, 3)
0 x
a Calculate:
i the coordinate of the point C
ii the equation of the line passing through A and C
iii the equation of the line passing through B and D.
b Are the diagonals of the rhombus perpendicular to each other?
Justify your answer.
284