Math Lessons, Calculators and Homework Help

It is time to solve your math problem

You are here:

# Calculators :: Analytic Geometry :: Distance and midpoint

This online calculator will compute and plot the distance and midpoint for two points in two dimensions. The calculator will generate a step-by-step explanation on how to obtain the results.

## Distance and midpoint calculator

This calculator will return the result representing the midpoint and distance between two points
You can enter either integers (10), decimal numbers(10.12) or FRACTIONS(10/3). Important: The form will NOT let you enter wrong characters (like *, (, ), y, p, ...)

 Distance Midpoint Show graph

## How to find distance between two points ?

To find distance between points $A(x_A, y_A)$ and $B(x_B, y_B)$, we use formula:

$${\color{blue}{ d(A,B) = \sqrt{(x_B - x_A)^2 + (y_B-y_A)^2} }}$$

Example:

Find distance between points $A(3, -4)$ and $B(-1, 3)$

Solution:

In this example we have: $x_A = 3,~~ y_A = -4,~~ x_B = -1,~~ y_B = 3$. So we have:

\begin{aligned} d(A,B) & = \sqrt{(x_B - x_A)^2 + (y_B-y_A)^2} \\ d(A,B) & = \sqrt{(-1 - 3)^2 + (3 - (-4) )^2} \\ d(A,B) & = \sqrt{(-4)^2 + (3 + 4 )^2} \\ d(A,B) & = \sqrt{16 + 49} \\ d(A,B) & = \sqrt{65} \\ d(A,B) & \approx 8.062 \end{aligned}

Note: use this calculator to find distance and draw graph.

## How to find midpoint of line segment ?

The formula for finding the midpoint $M$ of a segment, with endpoints $A(x_A, y_A)$ and $B(x_B, y_B)$, is:

$${\color{blue}{ M~\left(\frac{x_A + x_B}{2}, \frac{y_A + y_B}{2}\right) }}$$

Example:

Find midpoint of a segment with endpoints $A(3, -4)$ and $B(-1, 3)$.

Solution:

As in previous example we have: $x_A = 3,~~ y_A = -4,~~ x_B = -1,~~ y_B = 3$~. So we have:

\begin{aligned} M~\left(\frac{x_A + x_B}{2}, \frac{y_A + y_B}{2}\right) \\ M~\left(\frac{-1 + 3}{2}, \frac{3 - 4}{2}\right) \\ M~\left(\frac{2}{2}, \frac{-1}{2}\right) \\ M~\left(1, \frac{-1}{2}\right) \end{aligned}