Two Points: Distance, Midpoint, Slope, Line
Local ProcessingDistance, midpoint, slope and line equation for two points, including 3D distance and midpoint.
How It Works & Processing Standards
Enter values above to calculate results automatically. Check each input field for guidance and units.
Tool processing runs in your browser. If you create a calculator or conversion share link, its values are included in the URL. See the privacy policy for account, analytics and advertising data.
Seven calculations you can do with two coordinates, in one tool. Choose one under "Calculation" and enter the points.
What You Can Do
- Line equation
- The line through both points as y = mx + b, or x = c for a vertical line.
- Distance, midpoint, slope
- The distance between the points, the point halfway, and Δy/Δx.
- Point-slope form
- Writes the line from one point and a slope.
- 3D distance and midpoint
- Adds z coordinates for points in space.
How to Use Two Points: Distance, Midpoint, Slope, Line
- 1Choose a calculationPick what you need. 3D calculations show extra z fields.
- 2Enter coordinatesType (x1, y1) and (x2, y2). Negatives and decimals work.
- 3Read the resultYou get an equation or coordinates.
Examples
Line through (1, 2) and (3, 6)
Input: (1, 2), (3, 6)
Result: y = 2x + 0
Distance from the origin to (3, 4)
Input: (0, 0), (3, 4)
Result: 5
Midpoint of (2, 4) and (8, 10)
Input: (2, 4), (8, 10)
Result: (5, 7)
Common Use Cases
- Checking coordinate geometry homework
- Straight-line distance between map or drawing coordinates
- The slope of a trend line
Frequently Asked Questions (FAQ)
What if x1 equals x2?
The line is vertical and has no slope. The equation is given as x = 2, for example, and the slope as "vertical".
What unit is the distance?
The same as the coordinates. Coordinates in meters give meters.
