01 / 20

Find Distance Using the
Pythagorean Theorem

Learn how to calculate the exact distance between any two points on a coordinate plane using a right triangle and the formula \( d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2} \).

8th Grade Math

What Is Distance on a Graph?

Distance is the length of the straight line connecting two points. On a coordinate plane, you can't just count grid squares diagonally: you need a formula that accounts for both the horizontal and vertical separation.

\( d = ? \)
\( A(2, 2) \)
\( B(7, 5) \)

The Big Idea: A Hidden Right Triangle

Between any two points on the coordinate plane, you can always draw a right triangle. The horizontal leg is the difference in \( x \)-values, the vertical leg is the difference in \( y \)-values, and the hypotenuse is the distance you want.

\( (1, 1) \)
\( (5, 4) \)
horizontal: \( 4 \)
vertical: \( 3 \)
\( d = ? \)

Quick Recap: Pythagorean Theorem

For any right triangle with legs \( a \) and \( b \) and hypotenuse \( c \):

\( a \)
\( b \)
\( c \)
A B C

We'll use this theorem on the hidden right triangle to find the distance between two points.

The Distance Formula

Substitute the coordinate differences into \( a^2 + b^2 = c^2 \) and solve for \( c \):

\( (x_2 - x_1)^2 \)
Horizontal leg squared: the change in \( x \)
\( (y_2 - y_1)^2 \)
Vertical leg squared: the change in \( y \)
\( \sqrt{\phantom{x}} \)
Square root gives the hypotenuse: the actual distance

Same Formula, Different Look

The distance formula is the Pythagorean Theorem: just applied to coordinates. Here's the side-by-side comparison:

Pythagorean Theorem Distance Formula
Equation \( a^2 + b^2 = c^2 \) \( d^2 = (\Delta x)^2 + (\Delta y)^2 \)
Horizontal Leg \( a \) \( x_2 - x_1 \)
Vertical Leg \( b \) \( y_2 - y_1 \)
Result Hypotenuse \( c \) Distance \( d \)

How to Apply the Formula

1
Label your points. Call them \( (x_1, y_1) \) and \( (x_2, y_2) \).
2
Find the differences. Compute \( x_2 - x_1 \) and \( y_2 - y_1 \).
3
Square each difference. Calculate \( (x_2 - x_1)^2 \) and \( (y_2 - y_1)^2 \).
4
Add the squares. Sum them together.
5
Take the square root. The result is the distance \( d \).

Example 1: Points (1, 2) and (4, 6)

1 2 3 4 5 1 2 3 4 5 6
\( (1, 2) \)
\( (4, 6) \)
\( 3 \)
\( 4 \)
\( d = 5 \)

Example 2: Points (−2, 3) and (4, −1)

-1 -2 1 2 3 4 1 2 3 -1 -2
\( (-2, 3) \)
\( (4, -1) \)
\( 6 \)
\( 4 \)

Example 3: Simplifying the Radical

Find the distance between \( (-3, 5) \) and \( (1, -1) \).

1
Differences: \( x_2 - x_1 = 1 - (-3) = 4 \), \( y_2 - y_1 = -1 - 5 = -6 \)
2
Square them: \( 4^2 = 16 \), \( (-6)^2 = 36 \)
3
Add: \( 16 + 36 = 52 \)
4
Simplify: \( \sqrt{52} = \sqrt{4 \cdot 13} = 2\sqrt{13} \approx 7.21 \)

Recognizing Pythagorean Triples

Sometimes the distance comes out to a whole number. This happens when the legs form a Pythagorean triple: a set of three integers that satisfy \( a^2 + b^2 = c^2 \).

3, 4, 5
\( 9 + 16 = 25 \)
5, 12, 13
\( 25 + 144 = 169 \)
8, 15, 17
\( 64 + 225 = 289 \)

Special Cases: Horizontal & Vertical

When two points share the same \( x \)- or \( y \)-value, the distance simplifies: one of the squared differences is zero.

Horizontal
Same \( y \): \( d = |x_2 - x_1| \). Example: (2, 3) to (7, 3) gives \( d = 5 \).
Vertical
Same \( x \): \( d = |y_2 - y_1| \). Example: (4, 1) to (4, 9) gives \( d = 8 \).

Why Does This Matter?

The distance formula appears everywhere: GPS navigation, video game design, physics, and architecture. Anytime you need the "as-the-crow-flies" distance between two locations plotted on a grid, this is the tool.

Maps
Calculate the straight-line distance between two cities on a coordinate grid.
Games
Check if a character is within attack range of an enemy.
Building
Measure a diagonal brace length from corner to corner.

Common Mistakes to Avoid

✕ Forgetting to Square
Writing \( \sqrt{(x_2-x_1) + (y_2-y_1)} \) instead of squaring each difference first.
✕ Subtracting Wrong Pair
Mixing coordinates: using \( x_2 - y_1 \) instead of \( x_2 - x_1 \). Keep \( x \)'s with \( x \)'s.
✕ Forgetting the Root
Stopping at \( d^2 = 52 \) and reporting 52. Always take the square root at the end!

Summary: Key Formulas

Scenario Formula Example
General distance \( d = \sqrt{(\Delta x)^2 + (\Delta y)^2} \) \( (1,2) \) to \( (4,6) \to 5 \)
Horizontal only \( d = |x_2 - x_1| \) \( (2,3) \) to \( (7,3) \to 5 \)
Vertical only \( d = |y_2 - y_1| \) \( (4,1) \) to \( (4,9) \to 8 \)
With negatives Same formula: signs vanish after squaring \( (-2,3) \) to \( (4,-1) \to 2\sqrt{13} \)

Question 1 of 5

What is the distance between the points (0, 0) and (3, 4)?

Question 2 of 5

Find the distance between (-1, 2) and (5, 10).

Question 3 of 5

What is the distance between (2, -3) and (-1, 1)?

Question 4 of 5

A student claims the distance between (0, 0) and (5, 12) is \( \sqrt{17} \). What did they do wrong?

Question 5 of 5

Find the exact distance between (-4, -2) and (2, 4) in simplified radical form.