Guide
Midpoint and distance between two points
The distance between two points is the hypotenuse of a right-angled triangle, so the distance formula is just Pythagoras. The midpoint is a kind of average of the coordinates. Both, worked through step by step.
When we have two points in a coordinate system, we can use the distance formula to find the distance between them. We mark the distance between two points and with two vertical bars, , which means the length of the line segment between and . And with the midpoint formula we can find the point that sits exactly halfway between them.
When do I use this?
Whenever a problem is set on coordinate axes and asks how long something is, or where the middle of it is: the length of a side of a triangle drawn on a grid, the centre of a rectangle, or the radius of a circle when you know the centre and a point on it. Both formulas belong to coordinate geometry, where figures are described with coordinates and equations.
The distance formula
The formula looks like this:
The points here are and . So the formula says: take the square root of the difference between the points' x-coordinates squared, plus the difference between the points' y-coordinates squared.
Let's try an example. We have the two points and and want the distance between them. We put the points into the formula and work it out:
So the distance between the two points is about .
That was a small example of the distance formula, but where does it come from? Let's look at that now.
Why does the distance formula look like that?
You may already have noticed that the distance formula reminds you a lot of Pythagoras' theorem, and that's because it comes from there. Let's see how we use Pythagoras to find the distance between two points.
We start by drawing the two points and joining them with a line segment, which we call . That's the distance we want a formula for.
Now we draw in a right-angled triangle where the hypotenuse is the distance we want, . We call one of the shorter sides and the other one . That means we can write Pythagoras as
On our figure we can describe both and in another way.
Here the coordinates of and are drawn in, and . We can see that is actually the difference between the two points' x-coordinates. At the same time, is actually the difference between the two points' y-coordinates. So:
We can now swap those into Pythagoras' theorem:
We don't want our length squared, so we get rid of the square by taking the square root on both sides:
And now we've arrived at our formula, which really is just Pythagoras' theorem.
The midpoint formula
The midpoint formula is a formula we use to find the middle between two points. You can see it as finding the middle of the distance between the two points.
We find the midpoint with this formula:
The formula tells us how to find the midpoint, which we call , with coordinates . We find the x-coordinate first, by taking the x-coordinates of the two points, adding them together and then dividing by . We find the y-coordinate of the midpoint the same way: add the y-coordinates of the points together and divide by . It's actually a kind of average of the x-values and of the y-values.
Let's take an example. Say we had the two points and . To find the midpoint between them we put the points into the formula:
Then we just work it out:
So the midpoint is . If you look at the figure, it sits exactly halfway along the segment from to .
Common mistakes
- Stopping at . Pythagoras gives you the distance squared. The last step is always the square root, otherwise you have instead of .
- Mixing up which difference is which. is the difference between the x-coordinates and is the difference between the y-coordinates. Keep the x's together and the y's together inside the formula.
- Averaging only one of the coordinates for the midpoint. The midpoint needs both: the average of the x-coordinates and the average of the y-coordinates.
Related
- Coordinate geometry: lines, distances and circles
- The equation of a circle, where the same Pythagoras triangle turns up inside a circle
- Pythagoras' theorem
Frequently asked questions
Read next
Want to get good at maths?
Mathara explains every topic step by step with videos, exercises and personal feedback.
๐ Get started for free