Distance Between Two Points 2D Formula
Formula
Summary
Expression  Description 

The xcoordinate of the first point.  
The ycoordinate of the first point.  
The xcoordinate of the second point.  
The ycoordinate of the second point. 
Usage Notes
The distance between two points, in two dimensions, is given by solving pythagorean's theorem for the length the hypotenuse of the right triangle formed by the two points.
To calculate the length between the points (3,1) and (6,5) the distance formula below can be used:

Substitute the coordinates of the points into the formula.

Evaluate the absolute value expressions.

Evaluate exponentiation expressions.

Evaluate the addition operation.

Take the square root.

The distance is plus or minus 5 units.
To calculate the length between the points (2, 5) and (7, 3) the distance formula below can be used:

Substitute the coordinates of the points into the formula.

Evaluate absolute value expressions.

Evaluate exponentiation expressions.

Evaluate the addition operation.

The distance is the square root of 29.
The distance between the points (4, 2) and (1, 2) the formula for solving for the length of a right triangle can be applied.

Substitute the coordinates of the points into the formula.

Evaluate absolute value expressions.

Evaluate exponentiation expressions.

Evaluate the addition operation.

The distance is the square root of 41.
Derive Distance Between Two Points Formula
This example demonstrates how to derive the distance between two points formula using the properties of a right triangle and Pythagorean's Theorem.
Derivation

Start with the formula for pythagorean theorem which relates the squares of the sides of the triangle together. We start here, because we can observe that a right triangle is formed between any two points in the Cartesian Coordinate Plane.

Then rearrange the formula so that is on the left side, which represents the distance we are solving for.

Take the square root of both sides to isolate .

Use the distance between two points in onedimension to represent the length of .

Use the distance between two points in onedimension to represent the length of .

Substitute the expressions of and into the equation.

Finally replace the variable with to represent that derived formula represents the formula for the distance between two points 2d.