Distance Calculator
Calculate Euclidean, Manhattan and Chebyshev distance between two points. Essential for geometry and data science.
Point 1
Point 2
Distance
5
√((x₂-x₁)² + (y₂-y₁)²)
Euclidean: straight-line distance. Manhattan: sum of axis-aligned differences. Chebyshev: maximum of the axis differences.
Last updated: February 2026
How this calculator is verified
Checked by True Calculator automated test suite on
- Formula verified against a published worked example in the automated test suite
- Edge cases (zero, negative, boundary and unit-mismatch inputs) covered by unit tests
The full verification method is on our how we verify page. Found an error? Tell us and we will re-check it.
When to Use This Calculator
A delivery planner in Delhi compares two addresses mapped as point A at (1, 2) and point B at (4, 6). The Euclidean distance, the straight line between them, is the square root of 9 plus 16, which is 5. The Manhattan distance, which follows a grid like city streets, is 3 plus 4, or 7. The Chebyshev distance, the largest single coordinate difference, is the maximum of 3 and 4, which is 4. Each metric suits a different routing problem, so the planner compares all three before choosing one.
How to Use This Calculator
- Step 1: Enter the coordinates of the first point, such as x1 and y1.
- Step 2: Enter the coordinates of the second point.
- Step 3: Choose the distance type: Euclidean, Manhattan or Chebyshev.
- Step 4: Read the distance, and compare the modes to see how the metric changes the answer.
Worked Example
A delivery planner in Delhi compares two addresses mapped as point A at (1, 2) and point B at (4, 6). The Euclidean distance, the straight line between them, is the square root of 9 plus 16, which is 5. The Manhattan distance, which follows a grid like city streets, is 3 plus 4, or 7. The Chebyshev distance, the largest single coordinate difference, is the maximum of 3 and 4, which is 4. Each metric suits a different routing problem, so the planner compares all three before choosing one.
Tips and Common Mistakes
- •Tip 1: Euclidean distance is the straight-line or crow-flight length, so use it for direct geometry.
- •Tip 2: Manhattan distance suits grid-based problems such as city blocks where travel follows right angles.
- •Tip 3: Chebyshev distance equals the largest difference across any single coordinate, useful for maximum-step or chess-style moves.
- ✗Mistake 1: Subtracting coordinates in the wrong order within one axis, since each difference is always the same point minus the other.
- ✗Mistake 2: Using Manhattan distance for straight-line comparisons, because it always equals or exceeds the Euclidean distance.
Frequently Asked Questions
What is Euclidean distance?
It is the straight-line distance between two points, given by the square root of (x₂ − x₁)² plus (y₂ − y₁)². Between (1, 2) and (4, 6) that is √(9 + 16), or 5.
What is Manhattan distance?
It adds up the absolute differences along each axis, like travel along city blocks that only move horizontally or vertically. Between (1, 2) and (4, 6) it is |4 − 1| + |6 − 2|, or 7.
What is Chebyshev distance?
It takes the largest single coordinate difference, which is how a king moves on a chessboard — any direction, but one square at a time. Between (1, 2) and (4, 6) it is max(3, 4), or 4.
Which distance should I use for delivery or cab routes?
For grid-like city roads, Manhattan distance is closer to real travel than straight-line Euclidean distance, but even it underestimates the road distance. In cities like Delhi or Mumbai, treat the result as a planning floor, not the exact fare distance.
How do the three distance values compare?
Manhattan distance is always the largest and Chebyshev the smallest, with Euclidean straight-line distance in between. The gap between them shows exactly how much extra travel a grid route adds over a straight line.
Compare these tools
- Percentage Calculator — Calculate percentages, percentage difference and percentage change instantly
- Rounding Calculator — Round any number to the nearest value, or up and down, to any decimal places
- Standard Form Calculator — Convert numbers to and from standard form (scientific notation) with one click
You might also need
Related calculators from other categories
Date
Age Difference Calculator
Find the age difference between two dates in years, months and days, plus total days, weeks and months. See who is older at a glance.
Statistics
Correlation Coefficient Calculator
Compute the Pearson correlation coefficient between two data series. See r, r² and the direction and strength of the relationship.
Statistics
Covariance Calculator
Calculate sample or population covariance between two paired series, with the correlation coefficient. See how two variables move together.
Date
Date Difference Calculator
Count the exact days, weeks, months, years and business days between two dates, with hours and minutes too. Perfect for deadlines, leave and projects.