# What is the distance between two points

1. Jul 23, 2014

### Greg Bernhardt

Definition/Summary

In the plane with coordinate system $(O, \vec{i}, \vec{j})$ are given the points $A(x_1,y_1)$ and $B(x_2,y_2)$ (see the picture). We want to determine the distance d between the points A and B.

Equations

distance between two points $(x_1,y_1)$ and $(x_2,y_2)$:

$$d=|\vec{AB}|=\sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}$$

distance from (0,0) to point M(x,y):

$$d=|\vec{OM}|=\sqrt{x^2+y^2}$$

Extended explanation

Because of the fact that the distance is equal of the module of $\vec{AB}$,

d=|AB|

we need to find the module of the vector $\vec{AB}=(x,y)$. Because of the rectangular triangle ACB (see the picture), satisfying the Pythagorean theorem, we have:

$$|\vec{AB}|^2=|\vec{AC}|^2+|\vec{CB}|^2 \ \ \ \ (1)$$

Because of:

$$|\vec{AC}|=|\vec{A'B'}|=|x_2-x_1|$$ and $$|\vec{CB}|=|\vec{A''B''}|=|y_2-y_1|,$$

substituting in (1) we have:

$$|\vec{AB}|^2 = |x_2-x_1|^2 + |y_2 - y_1|^2 = (x_2 - x_1)^2 + (y_2 - y_1)^2$$

So, for finding the distance d between two points we have the formula:

$$d=|\vec{AB}|=\sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}$$

If the distance d, is from the point (0,0) to arbitary point M(x,y), which $d=|\vec{OM}|$, then we have:

$$d=|\vec{OM}|=\sqrt{x^2+y^2}$$

* This entry is from our old Library feature. If you know who wrote it, please let us know so we can attribute a writer. Thanks!