Education

Distance Formula Calculator

Calculate the straight-line distance between two points using the coordinate distance formula. The result includes decimal distance, distance squared, coordinate changes, and formula steps.

distance-formula
Distance
Δx
Δy
Distance squared
Formula substitution

Distance formula for two points

The distance formula gives the straight-line distance between two points in the coordinate plane. It comes from the Pythagorean theorem: the horizontal change and vertical change form the legs of a right triangle, and the segment between the points is the hypotenuse. OpenStax explains this connection in its distance and midpoint formulas section.

Distance = √((x₂ - x₁)² + (y₂ - y₁)²)

Worked example

Find the distance between (-3, 2) and (5, 8) Δx = 5 - (-3) = 8 Δy = 8 - 2 = 6 Distance = √(8² + 6²) Distance = √(64 + 36) = √100 = 10

The calculator also shows distance squared, which is useful when comparing lengths without taking a square root.

Distance formula vs. slope vs. midpoint

These three coordinate geometry tools answer different questions. Distance gives the length of a segment, slope gives steepness and direction, and midpoint gives the halfway coordinate. A strong coordinate geometry page should show all three because many homework problems combine them.

Common questions

  • The distance formula is √((x2-x1)^2 + (y2-y1)^2). It finds the straight-line distance between two points.
  • No. Reversing the two points changes the signs of Δx and Δy, but squaring them gives the same distance.
  • No. Distance is a length, so it is always zero or positive.
  • Distance squared is (x2-x1)^2 + (y2-y1)^2 before taking the square root.
  • It is an application of the Pythagorean theorem on a coordinate plane.
  • The distance is 0 because there is no separation between the points.
  • Yes, but the 3D version adds a z-coordinate: √((x2-x1)^2+(y2-y1)^2+(z2-z1)^2).
  • Squaring removes negative signs and measures the horizontal and vertical changes as positive lengths.