# 2. Distance Formula

In this lesson, we’ll establish the formula to find out the distance between two points whose coordinates are given. This formula is commonly known as the Distance Formula.

## Distance Formula

Consider two points P and Q, whose coordinates are given, say (x1, y1) and (x2, y2). We have to find the length of PQ, i.e. distance between the points P and Q.

Fig. 1: Distance between two points

To compute the distance, we do some constructions as follows:

Fig. 2: Some constructions

QB & PA parallel to the Y axis, and QD & PC parallel to the X axis. CP is extended to meet QB at R.

Here’s the idea – if we’re able to find the lengths QR and PR, then we can apply Pythagoras theorem in triangle PQR to find PQ. That is PQ=$$\sqrt{PR^2 + QR^2}$$

Observe that QR = QB – RB and QB is the distance of Q from the X axis which is y2 (its ordinate)

PA is the distance of the point P from the X axis, which is (by definition) equal to its ordinate y1. And, PA = RB, as PR is parallel to the X axis.  Therefore RB = y1

Hence, QR = QB – RB = y– y1 and similarly, PR = x– x1

The following figure makes it clear

Fig. 3: The details

And.. we’re done ! Having obtained PR and QR, we can finally obtain the distance PQ as $$\sqrt{PR^2 + QR^2}$$ or $$\sqrt{( x_2 – x_1)^2 + (y_2 – y_1)^2}$$

## Lesson Summary

1. The distance between two points whose coordinates are (x1, y1) and (x2, y2) is given by $$\sqrt{( x_2 – x_1)^2 + (y_2 – y_1)^2}$$

As an exercise, try to find out the coordinates of  R, A, B, C and D. The next lesson will cover some examples and applications.