Section 85
The Distance Formula
The distance formula is just the
Pythagorean Theorem
in disguise.
To calculate the distance
AB
between point
A
(
x
_{
1
}
,
y
_{
1
}
) and point
B
(
x
_{
2
}
,
y
_{
2
}
), first draw a right triangle which has the segment
as its
hypotenuse
.
If the lengths of the sides are
a
and
b
, then by the Pythagorean Theorem,
(
AB
)
^{
2
}
= (
AC
)
^{
2
}
+ (
BC
)
^{
2
}
Solving for the distance
AB
, we have:
Since
AC
is a horizontal distance, it is just the difference between the
x
coordinates:

(
x
_{
1
}
–
x
_{
2
}
). Similarly,
BC
is the vertical distance

(
y
_{
1
}
–
y
_{
2
}
).
Since we're squaring these distances anyway (and squares are always nonnegative), we don't need to worry about those absolute value signs.
Example:
Find the distance between points
A
and
B
in the figure above.
In the above example, we have:
A
(
x
_{
1
}
,
y
_{
1
}
)
=
(
–
1, 0),
B
(
x
_{
2
}
,
y
_{
2
}
) = (2, 7)
so