DoAssignment.ca
G7 · Develop and use the distance formula for line segments
Learn to develop and use the distance formula for line segments through clear examples and targeted practice.
Ontario Grade 10 Mathematics
Analytic Geometry
Develop and use the distance formula for line segments
A map uses coordinates to show where places are. If two places are marked by points, their straight-line distance is the length of the line segment joining them. This lesson develops a way to find that length from the points' coordinates. You will first review how to count horizontal and vertical changes, then connect those changes to a right triangle.
What you will learn
- Recall how horizontal and vertical changes are found from coordinates.
- Explain how the Pythagorean theorem connects those changes to the length of a line segment.
- Use the distance formula to find the length of a segment between two points.
- Check that a distance is reasonable and report it with suitable units when units are given.
1. Grade 9 bridge: coordinate changes
A point on a coordinate grid is named by an ordered pair, such as . The first number tells the horizontal position, and the second tells the vertical position. The horizontal axis is the left-to-right number line. The vertical axis is the up-and-down number line.
To find how far apart two points are horizontally, compare their first coordinates. To find their vertical separation, compare their second coordinates. For instance, points and have a horizontal change of and a vertical change of .
A change can be negative if it points left or down. For distance, however, we need the size of each change. Squaring a number makes its square positive whether the original change was positive or negative.
- The first coordinate gives horizontal position; the second gives vertical position.
- Subtract matching coordinates to find the changes.
- A distance is a length, so it cannot be negative.
2. From a right triangle to a distance formula
Imagine drawing a horizontal segment and a vertical segment from the endpoints of a slanted segment. These three segments make a right triangle. The slanted segment is the triangle's hypotenuse. The hypotenuse is the side opposite the right angle and is the longest side of a right triangle.
The Pythagorean theorem says that, in a right triangle, the square of the hypotenuse equals the sum of the squares of the other two sides. Here, the horizontal and vertical changes are the two shorter sides. Their lengths are and . The absolute value bars mean the positive size of a number.
If the endpoints are and , the distance between them follows from the Pythagorean theorem. The squares remove the need to worry about whether a coordinate change was negative. The square root gives the segment's length rather than its squared length.
The order of the points does not change the distance. Reversing the subtraction changes the signs of both coordinate differences, but their squares stay the same.
- The coordinate differences form the legs of a right triangle.
- Use the Pythagorean theorem to combine the two changes.
- The distance formula works for horizontal, vertical, and slanted segments.
3. Guided example: calculate and check
Find the length of the line segment joining and . The labels and simply name the two points. Match the first coordinates with each other and the second coordinates with each other.
The horizontal change is . The vertical change is . These values are the two legs of the right triangle. Substitute them into the distance formula, square each change, add, and take the square root.
The result is . This is reasonable: the horizontal and vertical changes are and , so the slanted length should be greater than either change. If the coordinates represented metres, the segment would be metres long.
- Keep each point's coordinates together when substituting.
- Subtract first, then square the differences.
- Check that the answer is at least as large as either individual change.
4. Use the formula carefully
For any pair of endpoints, choose one point to be and the other to be . Write the values into the formula in matching positions. You may swap the endpoint labels, but do not mix the first coordinate of one point with the second coordinate of the other.
If two points share the same first coordinate, the segment is vertical. Its length is the size of the difference between the second coordinates. If they share the same second coordinate, the segment is horizontal, and its length is the size of the difference between the first coordinates. The distance formula gives the same result in either case.
Keep the square root until the end of the calculation. If the number inside is a perfect square, the distance is a whole number. Otherwise, a decimal approximation may be useful. Follow the instructions of the question about rounding. Include units if the problem provides them.
Now try these independently. Find the distance between and . Then find the distance between and . For each one, identify the horizontal and vertical changes before calculating. Check your answers by considering whether the segment is horizontal, vertical, or slanted.
- Use the same coordinate order for both endpoints.
- A shared coordinate makes one of the changes zero.
- Do not round before the final answer.
Coordinate changes for the guided example
| Direction | Coordinate subtraction | Change |
|---|---|---|
| Horizontal | ||
| Vertical | ||
| Segment length |
Worked example
Distance between two slanted-segment endpoints
Find the distance between and .
- Find the coordinate changesSubtract the first coordinates to get the horizontal change. Subtract the second coordinates to get the vertical change. These changes are the legs of the right triangle formed by the segment.
- Substitute into the distance formulaThe formula combines the squares of the two leg lengths. This is the Pythagorean theorem applied to the triangle between the points.
- Calculate the lengthSquare each change, add the results, and take the square root. The distance is the positive length of the segment.
Answer: The distance between and is units.
Check: The answer is greater than both the horizontal change, , and the vertical change, , as expected for a slanted segment.
Common mistakes and how to avoid them
Adding the coordinates instead of finding the changes.
Correction: Subtract matching coordinates to find the horizontal and vertical changes. Then square those changes.
Leaving a negative distance because one coordinate change is negative.
Correction: The changes are squared in the formula, so their signs do not make the distance negative.
Forgetting the square root and reporting the sum of the squared changes.
Correction: The sum gives the square of the distance. Take its square root to find the length.
Mixing the coordinates of the two endpoints.
Correction: Subtract first coordinates from first coordinates, and second coordinates from second coordinates.
Lesson summary
- Find the horizontal and vertical changes by subtracting matching coordinates.
- Use the Pythagorean theorem to combine the changes into the segment length.
- Take the square root after adding the squared changes.
- Check that the answer is non-negative and makes sense compared with the coordinate changes.
Check your understanding
Question 1
What is the distance between and ?
Show answer and explanation
The first coordinates are the same, so the segment is vertical. Its length is the difference between the second coordinates: .
Question 2
What is the distance between and ?
Show answer and explanation
The changes are and . The distance is .
Question 3
Why does the distance formula square each coordinate change?
- To use the two changes as the sides of a right triangle and remove any negative signs
- To make the horizontal change twice as large
- To avoid taking a square root
- To show that every segment is vertical
Show answer and explanation
To use the two changes as the sides of a right triangle and remove any negative signs
The changes are the legs of a right triangle, so their squares are added by the Pythagorean theorem. Squaring also makes each contribution non-negative.
Key terms
- Coordinate
- A number that tells a point's position along one axis of a grid.
- Line segment
- A straight part of a line with two endpoints.
- Hypotenuse
- The side opposite the right angle in a right triangle.
- Distance formula
- A rule that uses the coordinates of two points to calculate the length of the segment between them.
Continue through MPM2D
View the complete MPM2D Ontario Grade 10 Mathematics curriculum and lessons
- G1 · Find slope from two points and write a line equation
- G2 · Use slopes of parallel and perpendicular lines
- G3 · Translate among common forms of a line equation
- G4 · Solve two-variable linear systems by substitution or elimination
- G5 · Model and solve real situations with linear systems
- G6 · Develop and use the midpoint formula
About this lesson
Published by DoAssignment. This AI-assisted lesson follows Ontario Grade 10 Mathematics (MPM2D), study topic G7. It is a study resource, not an official curriculum publication.