Salam Academy
Contents · 0% complete
  1. Learning objectives
  2. Core idea
  3. Key formulae
  4. Worked examples
  5. Explore the graph
  6. Common mistakes
  7. Exam tip
  8. Guided practice
  9. Practice questions
  10. Challenge
  11. Summary
  12. Quick quiz
  13. Same topic, different board
  14. Past paper questions
Learn9MA0Paper 1 · Pure Mathematics 1Coordinate geometryGradient, length, midpoint and equations of lines
Coordinate geometry · Subtopic 1 of 4

Gradient, Length, Midpoint and Equations of Lines

The three measurements of a line segment (gradient, length and midpoint), the three forms of the equation of a straight line, and how to find where lines cross.

Cambridge 9709 Paper 1Edexcel YMA01 WMA11Edexcel 9MA0 Paper 1Edexcel 9MA0 Paper 2AQA 7357 Paper 1AQA 7357 Paper 2≈ 35 minRevision 6 · updated 2026-10-27
Practise this topicTimed testAsk Salam Tutor
Section 1 of 14

Learning objectives

  • Find the gradient, length and midpoint of a line segment, and work backwards from them.
  • Write the equation of a line in the forms y=mx+cy=mx+c, y−y1=m(x−x1)y-y_1=m(x-x_1) and ax+by+c=0ax+by+c=0.
  • Read the gradient and intercept from any form of the equation.
  • Find where two lines intersect, check whether points are collinear, and find simple areas.
Pause and think

A line goes through (0,1)(0,1) and (2,7)(2,7). Without any formula: how much does yy go up each time xx goes up by 11?

Section 2 of 14

Core idea

Start hereDescribing a road with two numbers

A road sign says "Gradient 1 in 10": for every 1010 m you go along, you climb 11 m. A map gives the road's start and end as grid references. From just two points you can work out how steep the road is, how long it is, where its halfway café should go, and a formula for every point on it. That's coordinate geometry: turning shapes into numbers so algebra can answer geometric questions.

The big idea

From two points A(x1,y1)A(x_1,y_1) and B(x2,y2)B(x_2,y_2) you get the gradient m=y2−y1x2−x1m=\dfrac{y_2-y_1}{x_2-x_1}, the length (x2−x1)2+(y2−y1)2\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}, the midpoint (x1+x22,y1+y22)\left(\frac{x_1+x_2}2,\frac{y_1+y_2}2\right), and the line's equation y−y1=m(x−x1)y-y_1=m(x-x_1).

1. Gradient: rise over run

Gradientm=riserun=y2−y1x2−x1m=\frac{\text{rise}}{\text{run}}=\frac{y_2-y_1}{x_2-x_1}
where
(x1,y1)(x_1,y_1), (x2,y2)(x_2,y_2)
the two points; the small numbers are labels, not powers.
y2−y1y_2-y_1
the rise: how far up (negative means down).
x2−x1x_2-x_1
the run: how far across.
A(1, 2) to B(5, 10): the run and the rise
−55102468100xyy = 2xrun = 4rise = 8A(1, 2)B(5, 10)midpoint M(3, 6)
Gradient =riserun=84=2=\dfrac{\text{rise}}{\text{run}}=\dfrac84=2. Length AB=42+82=80=45AB=\sqrt{4^2+8^2}=\sqrt{80}=4\sqrt5. Midpoint =(1+52,2+102)=(3,6)=\left(\dfrac{1+5}{2},\dfrac{2+10}{2}\right)=(3,6).
Worked exampleGradients of two segments

Find the gradient of ABAB with A(1,2)A(1,2), B(5,10)B(5,10), and of PQPQ with P(−2,3)P(-2,3), Q(4,−1)Q(4,-1).

Goal
Two gradients, with correct signs.
Strategy
Subtract in the same order on top and bottom; use brackets for negatives.
  1. mAB=10−25−1=84=2m_{AB}=\frac{10-2}{5-1}=\frac84=2
    Up 2 for every 1 across.
  2. mPQ=−1−34−(−2)=−46=−23m_{PQ}=\frac{-1-3}{4-(-2)}=\frac{-4}{6}=-\frac23
    4−(−2)=64-(-2)=6; negative gradient: downhill.
Answer22 and −23-\frac23.
✓ CheckReversing the order: 3−(−1)−2−4=4−6=−23\frac{3-(-1)}{-2-4}=\frac4{-6}=-\frac23 ✓ (order doesn't matter if consistent).
  • m>0m>0: uphill (left to right); m<0m<0: downhill.
  • m=0m=0: horizontal line y=ky=k.
  • Vertical line x=kx=k: the run is 00, so the gradient is undefined.
Common misconceptionMixed order y2−y1x1−x2\frac{y_2-y_1}{x_1-x_2} gives the wrong sign. Same point first on top and bottom.

2. Length: Pythagoras on the grid

The distance formula
  1. run=x2−x1,rise=y2−y1\text{run}=x_2-x_1,\qquad\text{rise}=y_2-y_1
    The two shorter sides of a right-angled triangle with hypotenuse ABAB.
  2. AB2=(x2−x1)2+(y2−y1)2AB^2=(x_2-x_1)^2+(y_2-y_1)^2
    Pythagoras: hypotenuse² = sum of the other two squared.
  3. AB=(x2−x1)2+(y2−y1)2AB=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}
    Square root (length is positive).
For A(1,2)A(1,2), B(5,10)B(5,10): 16+64=80=45≈8.94\sqrt{16+64}=\sqrt{80}=4\sqrt5\approx8.94.

3. Midpoint: the average

Halfway along, you've done half the run and half the rise: x=x1+12(x2−x1)=x1+x22x=x_1+\frac12(x_2-x_1)=\frac{x_1+x_2}2, and similarly for yy. So the midpoint's coordinates are the averages.

Worked exampleWorking backwards from a midpoint

M(4,1)M(4,1) is the midpoint of A(1,−3)A(1,-3) and BB. Find BB.

Goal
Coordinates of B(x,y)B(x,y).
Strategy
Write the midpoint formula with unknowns and solve each coordinate.
  1. 1+x2=4⇒1+x=8⇒x=7\frac{1+x}2=4\Rightarrow1+x=8\Rightarrow x=7
    xx-coordinates.
  2. −3+y2=1⇒−3+y=2⇒y=5\frac{-3+y}2=1\Rightarrow-3+y=2\Rightarrow y=5
    yy-coordinates.
AnswerB(7,5)B(7,5).
✓ CheckMidpoint of (1,−3)(1,-3) and (7,5)(7,5) is (4,1)(4,1) ✓.

4. The equation of a line

Point–gradient form y−y1=m(x−x1)y-y_1=m(x-x_1)
  1. Let (x,y) be any other point on the line.\text{Let }(x,y)\text{ be any other point on the line.}
    We want a rule every point obeys.
  2. y−y1x−x1=m\frac{y-y_1}{x-x_1}=m
    The gradient from (x1,y1)(x_1,y_1) to (x,y)(x,y) must equal mm (a straight line has constant gradient).
  3. y−y1=m(x−x1)y-y_1=m(x-x_1)
    Multiply both sides by (x−x1)(x-x_1).
Expanding gives y=mx+cy=mx+c, where c=y1−mx1c=y_1-mx_1 is the yy-intercept.
y = mx + 1 as the gradient m changes
−4−3−2−11234−4−22460xyy-intercept (0, 1)
The gradient is how much yy goes up when xx goes up by 11.
Worked exampleLine through (3,−1)(3,-1) with gradient −23-\tfrac23

Find the equation in the form ax+by+c=0ax+by+c=0 with integers.

Goal
Integer coefficients.
Strategy
Point–gradient form, clear the fraction, collect.
  1. y+1=−23(x−3)y+1=-\tfrac23(x-3)
    y−(−1)=y+1y-(-1)=y+1.
  2. 3y+3=−2(x−3)3y+3=-2(x-3)
    Multiply both sides by 33.
  3. 3y+3=−2x+63y+3=-2x+6
    Expand.
  4. 2x+3y−3=02x+3y-3=0
    Add 2x2x, subtract 66.
Answer2x+3y−3=02x+3y-3=0.
✓ Check(3,−1)(3,-1): 6−3−3=06-3-3=0 ✓. Gradient: y=−23x+1y=-\frac23x+1 ✓.
Worked exampleWhere two lines meet

Find where y=2xy=2x meets x+y=9x+y=9.

Goal
The intersection point.
Strategy
The point satisfies both equations: solve simultaneously.
  1. x+2x=9⇒x=3x+2x=9\Rightarrow x=3
    Substitute y=2xy=2x.
  2. y=6y=6
    Back into y=2xy=2x.
Answer(3,6)(3,6).
✓ Check3+6=93+6=9 ✓.
Pause and think

Where does 3x+4y=243x+4y=24 cross each axis, and how far apart are those points?

Summary

  • Gradient = rise/run.
  • Length by Pythagoras; midpoint by averages.
  • y−y1=m(x−x1)y-y_1=m(x-x_1); y=mx+cy=mx+c.
  • Intersections: solve simultaneously.
Key words
Gradient
Rise per unit run; steepness.
Intercept
Where a line crosses an axis.
HistoryWhy they are called Cartesian coordinates. In 1637 the French philosopher René Descartes published La Géométrie, showing how to describe curves with equations. Pierre de Fermat had the same idea at about the same time. Coordinates are named "Cartesian" after Descartes, whose Latin name was Renatus Cartesius.
Fun factThe fly on the ceiling (probably a legend). A popular story says Descartes invented coordinates while lying in bed watching a fly crawl across the ceiling, realising he could describe its position by its distances from two walls. There is no evidence it is true, but it is a perfect picture of what (x,y)(x,y) means.
Section 3 of 14

Key formulae

For A(x₁, y₁) and B(x₂, y₂)m=y2−y1x2−x1AB=(x2−x1)2+(y2−y1)2midpoint M=(x1+x22, y1+y22)\begin{gathered}m=\frac{y_2-y_1}{x_2-x_1}\qquad AB=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2} \\[4pt] \text{midpoint }M=\left(\frac{x_1+x_2}2,\ \frac{y_1+y_2}2\right)\end{gathered}
Three forms of a straight liney=mx+cy−y1=m(x−x1)ax+by+c=0from ax+by+c=0:  m=−ab\begin{gathered}y=mx+c\qquad y-y_1=m(x-x_1)\qquad ax+by+c=0 \\[3pt] \text{from }ax+by+c=0:\ \ m=-\frac ab\end{gathered}
NoteWhich form to give? Use y−y1=m(x−x1)y-y_1=m(x-x_1) to find the line: it needs no rearranging. Then give the answer in the form the question asks for. "ax+by+c=0ax+by+c=0 where aa, bb and cc are integers" means clear all fractions first.
Section 4 of 14

Worked examples

Example 1 · All three measurements0 / 3 steps
AA is (−3,4)(-3,4) and BB is (5,−2)(5,-2). Find the gradient, the length and the midpoint of ABAB.
    Example 2 · Equation from two points0 / 3 steps
    Find the equation of the line through (1,2)(1,2) and (4,11)(4,11) in the form ax+by+c=0ax+by+c=0.
      Example 3 · Working backwards from a midpoint0 / 2 steps
      M(3,5)M(3,5) is the midpoint of ABAB, where AA is (1,2)(1,2). Find BB.
        Example 4 · Where two lines cross0 / 2 steps
        Find the point of intersection of 2x+y=72x+y=7 and x−y=2x-y=2.
          Section 5 of 14

          Explore the graph

          Two points, three measurements
          Loading the interactive graph…
          Try this
          1. The two value rows show the gradient and the length of the segment. Check they match Example 1: −34-\tfrac34 and 1010.
          2. Make b=db=d. What is the gradient of a horizontal line?
          3. Make a=ca=c. Why does the gradient row show an error? (A vertical line has an undefined gradient, and its equation is x=ax=a.)

          The middle point is the midpoint. Try to predict where it will be before you move a slider.

          TrickThe step trick for midpoints and ends. Find the step from one point to the midpoint (for example, right 22, up 33), then take the same step again to get the other end. It is quicker than solving two equations and much harder to get wrong.
          In the real worldScreens count downwards. On a computer screen, pixel coordinates start at the top-left corner and yy increases downwards. Game designers flip the sign of every gradient, which is why a "rising" line on screen has a negative gradient in their code.
          Section 6 of 14

          Common mistakes

          IncorrectGradient =x2−x1y2−y1=\dfrac{x_2-x_1}{y_2-y_1}
          Correcty2−y1x2−x1\dfrac{y_2-y_1}{x_2-x_1}
          Gradient is "up over across": change in yy on top.
          Incorrect3x+4y=123x+4y=12 has gradient 33
          Correct−34-\tfrac34
          Rearrange to y=−34x+3y=-\tfrac34x+3 before reading the gradient.
          Incorrect(5−(−3))2+(−2−4)2=22+62\sqrt{(5-(-3))^2+(-2-4)^2}=\sqrt{2^2+6^2}
          Correct82+62\sqrt{8^2+6^2}
          5−(−3)=85-(-3)=8: subtracting a negative adds.
          Incorrecty−2=3(x−1)⇒y=3x−3−2y-2=3(x-1)\Rightarrow y=3x-3-2
          Correcty=3x−3+2=3x−1y=3x-3+2=3x-1
          Move the −2-2 across by adding 22.
          1. Gradient is run over rise

          2. Gradient is rise over run

          3. Gradient is y2−y1x2−x1\dfrac{y_2-y_1}{x_2-x_1} and I keep the order the same on top and bottom

          Section 7 of 14

          Exam tip

          Exam tipKeep fractions exact. If a gradient is −34-\tfrac34, keep it as a fraction. Decimals like −0.75-0.75 are fine, but 13\tfrac13 as 0.3330.333 loses accuracy marks in the next step. Answers such as 52\sqrt{52} should be simplified to 2132\sqrt{13} when asked for exact form.
          Section 8 of 14

          Guided practice

          SA-9709-P1-CG-G014 marksL1 FoundationCalculatorEquations
          AA is (1, 2)(1,\,2) and BB is (5, 10)(5,\,10). Find the gradient of ABAB, the midpoint of ABAB, and the length of ABAB in exact form.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          Section 9 of 14

          Practice questions

          SA-9709-P1-CG1-0012 marksL1 FoundationCalculatorGradient & midpoint
          Find the gradient of the line through (−3,4)(-3,4) and (5,−2)(5,-2).

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG1-0032 marksL2 StandardCalculatorGradient & midpoint
          M(3,5)M(3,5) is the midpoint of ABAB, where AA is (1,2)(1,2). Find the coordinates of BB.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG-0012 marksL1 FoundationCalculatorEquations
          Find the equation of the line with gradient 33 passing through (2, −1)(2,\,-1), in the form y=mx+cy=mx+c.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG-0032 marksL1 FoundationCalculatorEquations
          The line LL has equation 3x+4y=123x+4y=12. State the gradient of LL and the yy-coordinate where LL crosses the yy-axis.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG1-0062 marksL2 StandardCalculatorEquations
          The line y=23x−4y=\tfrac23x-4 can be written as 2x+by+c=02x+by+c=0, where bb and cc are integers. Find bb and cc.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG-0043 marksL2 StandardCalculatorEquations
          Find the point of intersection of the lines y=2x−1y=2x-1 and x+3y=11x+3y=11.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG1-0073 marksL2 StandardCalculatorIntersections
          The points (1,3)(1,3), (3,7)(3,7) and (6,k)(6,k) lie on a straight line. Find kk.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          SA-9709-P1-CG-0143 marksL2 StandardCalculatorEquations
          The distance between P(k, 3)P(k,\,3) and Q(4, −1)Q(4,\,-1) is 55. Find the possible values of kk.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme

          More questions on every skill in this subtopic are in the question bank under Practise.

          Section 10 of 14

          Challenge

          SA-9709-P1-CG1-0105 marksL5 ExtensionCalculatorGradient & midpoint
          AA is (0,2)(0,2) and BB is (6,5)(6,5). The point CC lies on the xx-axis and is the same distance from AA as from BB. Find the xx-coordinate of CC.

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          Section 11 of 14

          Summary

          • Gradient: change in yy over change in xx. Length: Pythagoras. Midpoint: average the coordinates.
          • Find the line with y−y1=m(x−x1)y-y_1=m(x-x_1), then rearrange to the form asked for.
          • For ax+by+c=0ax+by+c=0, the gradient is −ab-\tfrac ab.
          • Intersections: solve the two equations simultaneously.
          Section 12 of 14

          Quick quiz

          Q1 · SA-9709-P1-CG1-Q011 markL1 FoundationCalculatorEquations
          The gradient of the line y=5−3xy=5-3x is
          Choose one option

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          Q2 · SA-9709-P1-CG1-Q021 markL1 FoundationCalculatorEquations
          The line through (2,−4)(2,-4) parallel to the xx-axis has equation
          Choose one option

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          Q3 · SA-9709-P1-CG1-Q031 markL1 FoundationCalculatorGradient & midpoint
          The midpoint of (x1,y1)(x_1,y_1) and (x2,y2)(x_2,y_2) is
          Choose one option

          Sign in or create a free account to check answers, get hints and track your progress.

          Salam Academy Original Practice · Proposed mark scheme
          Section 13 of 14

          Same topic, different board

          Specification
          IAL Mathematics
          Where
          WMA11 (Pure 1) · Coordinate geometry in the (x, y) plane
          Expected
          Equation of a straight line in the forms y − y₁ = m(x − x₁) and ax + by + c = 0, with gradient, length, midpoint and intersections (WMA11).
          Calculator
          WMA11 (straight lines) is non-calculator; WMA12 (circles) allows a calculator.
          Typical style
          Short structured parts, often with a sketch given to label.
          Open in
          YMA01 · WMA119MA0 · Paper 19MA0 · Paper 2
          Section 14 of 14

          Past paper questions

          3 questions (22 marks) from real exams test this subtopic. Try each one under timed conditions, then mark it with the official mark scheme.

          1. WMA11/01 · June 2025Question 57 marks

            A perpendicular line, where two lines meet, and a distance to the origin.

          2. WMA11/01 · June 2024Question 99 marks

            Line through two points, a point at a given distance and a triangle area.

          3. WMA11/01 · June 2023Question 76 marks

            A region bounded by lines, described with inequalities.

          All YMA01 past paper questions by topic

          Salam Academy original content · Content status: reviewed and published. Syllabus mapping: Pearson Edexcel 9MA0, First teaching 2017 (official specification).