Distance Between Points - Maple Programming Help

Home : Support : Online Help : Math Apps : Graphing : Basic : MathApps/DistanceBetweenPoints

Distance Between Points

The Distance Formula

The distance d between two points $\left({x}_{1},{y}_{1}\right)$ and $\left({x}_{2},{y}_{2}\right)$ is given by:

$d=\sqrt{{\left({x}_{2}-{x}_{1}\right)}^{2}+{\left({y}_{2}-{y}_{1}\right)}^{2}}$

More Details

By using the Pythagorean theorem, we can work out the length of the hypotenuse of a right-angled triangle if we know the length of the other two sides. To find the distance between two points $\left({x}_{1},{y}_{1}\right)$ and $\left({x}_{2},{y}_{2}\right)$, we first locate the points on the Cartesian plane.

Next, we can construct a right triangle by drawing a horizontal line through $\left({x}_{1},{y}_{1}\right)$ and a vertical line through $\left({x}_{2},{y}_{2}\right)$.

From the Pythagorean Theorem we know that $c=\sqrt{{a}^{2}+{b}^{2}}$.

Now, we need to determine the lengths a and b.

$a=\left|{x}_{2}-{x}_{1}\right|$        $b=\left|{y}_{2}-{y}_{1}\right|$

Then square each side to get closer to the form  $\sqrt{{a}^{2}+{b}^{2}}$.

${b}^{2}={\left|{y}_{2}-{y}_{1}\right|}^{2}={\left({y}_{2}-{y}_{1}\right)}^{2}$

Then

$c=\sqrt{{a}^{2}+{b}^{2}}=\sqrt{{\left({x}_{2}-{x}_{1}\right)}^{2}+{\left({y}_{2}-{y}_{1}\right)}^{2}}$

Click or drag two points on the graph, and the distance between them will be computed, along with the two components of the distance.

Check Only use integer coordinates if you want to allow only lattice points to be selected (for example, not ).

 More MathApps