Two points in the plane are the ends of the hypotenuse of a right triangle whose legs are the differences in their coordinates. The Baudhayana-Pythagoras theorem then gives the distance.
If two points have the same y-coordinate, the segment joining them is horizontal. The distance between them is the difference of their x-coordinates. For (2, 3) and (9, 3), the distance is 9 − 2 = 7.
Subtracting the other way gives 2 − 9 = −7. A distance cannot be negative, so the distance is the absolute value, |x₂ − x₁|. The absolute value of a number is its size without its sign: |−7| = 7.
If two points have the same x-coordinate, the segment is vertical, and the distance is |y₂ − y₁|.
Neither coordinate is shared, so the segment is slanted. How can you find its length using only horizontal and vertical distances?
Make a right triangle. From the first point, move horizontally until you are directly above or below the second point. Then move vertically to reach it.
The horizontal and vertical moves are the two legs. Each is a horizontal or vertical distance, which you can already find. The slanted segment is the hypotenuse, and the Baudhāyana–Pythagoras theorem connects it to the legs.
Take A (3, 4) and D (7, 1). Draw a horizontal line through A and a vertical line through D. They meet at C (7, 4). The angle at C is 90°.
The right triangle between two points. Each leg is a difference of coordinates. The Baudhāyana–Pythagoras theorem gives the slanted side from the two legs.
The horizontal leg AC is 7 − 3 = 4. The vertical leg CD is 4 − 1 = 3. The theorem states that, in a right triangle, the square of the hypotenuse equals the sum of the squares of the legs:
AD = √(4² + 3²) = √25 = 5 units
No step used the particular numbers 3, 4, 7 and 1. For any two points (x₁, y₁) and (x₂, y₂), the legs are x₂ − x₁ and y₂ − y₁, so:
distance = √( (x₂ − x₁)² + (y₂ − y₁)² )
📏 Build the triangle › Drag either point. The legs, their squares and the three steps of working update with your numbers. Show the squares on the sides to see the two smaller areas add up to the larger one.Subtract the other way for A and D: the horizontal leg becomes 3 − 7 = −4. Its square is (−4)² = 16, the same as 4². A number and its negative have the same square.
So the formula gives the same distance whichever point is taken first. It also works for points in any quadrant, without special cases.
This explains the result from session 3. Reflecting a triangle in an axis changes the sign of some coordinate differences. Squaring removes that sign change, so every side keeps its length.
Calculate DM for D (7, 1) and M (9, 6).
Horizontal leg: 9 − 7 = 2. Vertical leg: 6 − 1 = 5.
DM = √(2² + 5²) = √(4 + 25) = √29, which is about 5.39.
No whole number squares to 29, so √29 is the exact answer. 5.39 is a rounded approximation. Most distances between points with whole-number coordinates are not whole numbers.
For the origin, x₁ = 0 and y₁ = 0. The formula becomes:
distance from O = √(x² + y²)
A circle centred at the origin with radius 5 is the set of points at distance 5 from O. So a point (x, y) lies on that circle exactly when √(x² + y²) = 5. This test is used in the last session of the unit.
1The distance between (2, 3) and (9, 3) is…
2The distance between (0, 0) and (6, 8) is ____ units.
3Why does it not matter which point you subtract from which?
4Two points have the same x-coordinate. The distance between them is…
5The distance between (1, 2) and (4, 6) is…
6A distance is calculated as √29. Which is the exact answer?
7A triangle is reflected in the y-axis. Using the distance formula, why are its side lengths unchanged?
8Which of these points are exactly 5 units from the origin?
More than one answer is correct.
Next: finding the point halfway between two others.