Formula sheet

Distance between two points

This formula is printed on the exam formula sheet, so you do not have to memorise it. What you must know is when to reach for it, any time a question asks for the length of a line segment or the distance between two coordinate points, and how to substitute the coordinates in the correct order.

Distance between two points
Distance = √(x2−x1)2 + (y2−y1)2
Given in the exam

What the symbols mean

  1. x₁, y₁ the x- and y-coordinates of the first point (x₁, y₁)
  2. x₂, y₂ the x- and y-coordinates of the second point (x₂, y₂)
  3. Distance the straight-line length between the two points, in the same units as the axes

Given in the exam, or memorise?

This formula is printed on the exam formula sheet, so you do not have to memorise it. What you must know is when to reach for it, any time a question asks for the length of a line segment or the distance between two coordinate points, and how to substitute the coordinates in the correct order.

Why it works

It is simply Pythagoras' theorem applied to the right-angled triangle formed by the horizontal and vertical gaps between the two points.

  1. Plot the two points; the horizontal gap is (x₂ − x₁) and the vertical gap is (y₂ − y₁).
  2. These two gaps are the legs of a right-angled triangle, and the line joining the points is the hypotenuse.
  3. By Pythagoras, hypotenuse² = (x₂ − x₁)² + (y₂ − y₁)², so the distance is the square root of that.

Worked example 1

Find the distance between the points A(1, 2) and B(4, 6).

  1. Take (x₁, y₁) = (1, 2) and (x₂, y₂) = (4, 6).
  2. Distance = √((4 − 1)² + (6 − 2)²)
  3. = √(3² + 4²) = √(9 + 16)
  4. = √25 = 5

Worked example 2

Find the distance between P(0, 1) and Q(6, 4), leaving your answer in surd form.

  1. Take (x₁, y₁) = (0, 1) and (x₂, y₂) = (6, 4).
  2. Distance = √((6 − 0)² + (4 − 1)²)
  3. = √(6² + 3²) = √(36 + 9)
  4. = √45 = √(9 × 5) = 3√5

Where students go wrong

  1. Forgetting to square the differences, writing √((x₂ − x₁) + (y₂ − y₁)) instead of squaring each gap first.
  2. Splitting the root wrongly: √(9 + 16) is NOT √9 + √16 = 7. Add inside the root first, then take one square root: √25 = 5.
  3. Treating a squared negative as negative: (−4)² = 16, not −16, so a downward or leftward gap still adds a positive value.
  4. Leaving the answer as √45 when the question asks for surd form, simplify it to 3√5.

Use it with

Source:SPM: Format Pentaksiran mulai 2021, Matematik (1449)

Book a Trial ClassOne-hour paid trial · Same-day reply · from RM50/hr

Frequently asked questions

Does it matter which point I call point 1 and which point 2?

No. Because each difference is squared, (x₂ − x₁)² gives the same value as (x₁ − x₂)².

So you can label either point as the first one and still get the same distance. Just be consistent within a single calculation and square each gap before adding them together.

How do I know when to use the distance formula instead of the midpoint formula?

Use the distance formula when a question asks for a length, how far apart two points are, the length of a side, or the perimeter of a shape. Use the midpoint formula when it asks for the point exactly halfway between two points.

The words 'length' or 'distance' are your signal.

Should I leave the answer as a surd or a decimal?

Follow the question. If it says 'in surd form', simplify to something like 3√5.

If it asks for the length correct to a number of decimal places, use your calculator to get a decimal such as 6.71. When it does not specify, giving both the exact surd and its decimal value is a safe choice.

Book a Trial Class

Book a Trial Class
One-hour paid trial · Same-day replyfrom RM50/hr
Book a Trial Class