Coordinate GeometryDistance Formula
Aman lives in town A. His nani lives in town B, which is 36 km east and 15 km north of A. The bus follows the roads — 36 km east, then 15 km north, 51 km in all. Now the state wants to build a straight highway from A to B, across fields and over a river. How long will it be? Nobody is going to walk across with a measuring tape.
Let's warm up on a smaller map first. Town A sits at the origin and every square is 1 km.
Most spots for B give a highway with an awkward length like 2.24 km. A few give a whole number.
Drag town B and find three spots where the highway is exactly 5 km, 10 km and 13 km long — with B on neither axis.
The east road and the north road are the bus route; the highway cuts straight across.
Back to Aman's Highway
Every whole-number highway you found was the longest side of a right
The real towns work in the same way. In Fig. 7.1, the 36 km road east and the 15 km road north meet at a right angle, and the highway AB is the hypotenuse:
So
Points on the Axes
Start with the easiest case: two points on the same axis. Take A(4, 0) and B(6, 0) on the x-axis in Fig. 7.2. You can read off OA = 4 units and OB = 6 units, so the distance from A to B is AB = OB − OA = 6 − 4 =
The y-axis works the same way. For C(0, 3) and D(0, 8), CD = 8 − 3 =
Now a harder one: how far is A from C? They sit on different axes, so OA, OC and AC form a right triangle with its right angle at O. With OA = 4 and OC = 3,
Each distance you get right is drawn into the figure.
Building the Triangle Yourself
What if neither point lies on an axis? We can still use the
In Fig. 7.3, P(4, 6) and Q(6, 8) both lie in the first
So the upright side QT = 8 − 6 =
Now Pythagoras in the right triangle PTQ:
So the slanting side PQ = units.
Across the Quadrants
What about two points in different quadrants? Take P(6, 4) and Q(−5, −3), as in Fig. 7.4. Draw QS perpendicular to the x-axis, and draw PT from P perpendicular to QS extended; on its way, PT crosses the y-axis at R.
Then PT =
Why? Across, P is 6 units to the right of the y-axis and Q is 5 units to the left of it, so PT = 6 + 5. Up, P is 4 units above the x-axis and Q is 3 units below it, so QT = 4 + 3.
Pythagoras in the right triangle PTQ gives
PQ =
The Formula for Any Two Points
Now let's find the distance between any two points, and . Fig. 7.5 below is live. Wherever you put the points, the horizontal gap and the vertical gap make a right triangle, with PQ as its hypotenuse.
Drag P and Q (a press grabs whichever point is nearer) and complete all three missions.
Here is the same reasoning with letters instead of numbers. Draw PR and QS perpendicular to the x-axis, and PT perpendicular to QS. Then
, so
, so
Applying the Pythagoras theorem in ,
A distance can never be negative, so we keep only the positive square root. The distance between and is
which is called the
Why it works
There is nothing new to memorise here — the distance formula is the Pythagoras theorem in disguise. The horizontal gap and the vertical gap between two points are the two legs of a right triangle, and the straight-line distance is its hypotenuse. Square the two gaps, add, take the square root: that is just .
Two quick consequences are worth remembering.
Note
- The distance of a point P(x, y) from the
origin O(0, 0) is . - We can also write . (Why?)
Try the first one: the point (−6, 8) is
And the answer to "Why?": is just the negative of , and a number and its negative have
Example 1 : Do the points (3, 2), (–2, –3) and (2, 3) form a triangle? If so, name the type of triangle formed.
Solution : Call the points P(3, 2), Q(–2, –3) and R(2, 3), and find all three distances with the distance formula:
Any two of these distances add up to more than the third, so P, Q and R form a
Also , so by the converse of the Pythagoras theorem, . Therefore PQR is a
Example 2 : Show that the points (1, 7), (4, 2), (–1, –1) and (– 4, 4) are the
Solution : Let A(1, 7), B(4, 2), C(–1, –1) and D(– 4, 4) be the given points. A quadrilateral is a square when all four sides are equal and both
So AB = BC = CD = DA and AC = BD: all four sides of the
Alternative Solution : Find the four sides and just one diagonal, say AC, as above. Here , so by the converse of the Pythagoras theorem, . A quadrilateral with four equal sides and one right angle is a square, so ABCD is a
Example 3 : Fig. 7.6 shows the arrangement of desks in a classroom. Ashima, Bharti and Camella are seated at A(3, 1), B(6, 4) and C(8, 6) respectively. Do you think they are seated in a line? Give reasons for your answer.
Solution : Using the distance formula,
Since , the points A, B and C are
Example 4 : Find a relation between x and y such that the point (x , y) is
Riya lives at A(7, 1) and Aman at B(3, 5) on the town map. They want to meet at a chai stall that is exactly as far from Riya's house as from Aman's. Where could the stall be? Fig. 7.7 below is live.
Drag the purple point P and find three grid points that are equally far from A and B.
Your three points lie on one straight line, the purple line in Fig. 7.7. Let us find its equation.
Solution : Let P(x, y) be equidistant from A(7, 1) and B(3, 5). Then AP = BP, and so :
The and terms cancel, leaving , i.e. , i.e.
which is the required relation.
Note
The graph of is a
Example 5 : Find a point on the y-axis which is equidistant from the points A(6, 5) and B(– 4, 3).
Solution : Every point on the y-axis looks like (0, y), so let P(0, y) be equally far from A and B. Then :
i.e.,
i.e.,
i.e.,
So the required point is (0, 9).
Let's check the answer:
Note
Using the remark in Example 4, (0, 9) is the point where the
Speed Round: How Far Apart?
No figure this time. Find the two gaps, square them, add, and take the square root — all in your head.
Get five right to move on.