Length of a Line Segment Calculator
Calculate the distance between two points using the distance formula
Calculate Line Segment Length
Coordinates of the first endpoint
Coordinates of the second endpoint
Line Segment Properties
Step-by-Step Calculation:
1. Distance formula: d = √[(x₂ - x₁)² + (y₂ - y₁)²]
2. Given points: A(0, 0), B(0, 0)
3. Calculate differences: Δx = 0 - (0) = 0, Δy = 0 - (0) = 0
4. Square the differences: Δx² = 0, Δy² = 0
5. Sum of squares: 0 + 0 = 0
6. Take square root: d = √0 = 0.000000
Example Calculations
Example 1: 2D Coordinate Plane
Problem: Find the length of line segment from (-3, 1) to (2, 5)
Given: Point A(-3, 1), Point B(2, 5)
Solution Steps
1. Use distance formula: d = √[(x₂ - x₁)² + (y₂ - y₁)²]
2. Calculate differences: Δx = 2 - (-3) = 5, Δy = 5 - 1 = 4
3. Square the differences: Δx² = 25, Δy² = 16
4. Sum of squares: 25 + 16 = 41
5. Result: d = √41 ≈ 6.403 units
Example 2: 3D Space
Problem: Distance from origin (0, 0, 0) to point (3, 4, 5)
Formula: d = √[(3-0)² + (4-0)² + (5-0)²] = √[9 + 16 + 25] = √50 ≈ 7.071
Distance Formulas
2D Distance
d = √[(x₂ - x₁)² + (y₂ - y₁)²]
3D Distance
d = √[(x₂ - x₁)² + (y₂ - y₁)² + (z₂ - z₁)²]
Midpoint (2D)
M = ((x₁ + x₂)/2, (y₁ + y₂)/2)
Slope (2D)
m = (y₂ - y₁)/(x₂ - x₁)
Quick Tips
The distance formula is derived from the Pythagorean theorem
Distance is always positive (absolute value)
Order of points doesn't matter: d(A,B) = d(B,A)
For horizontal lines: Δy = 0, for vertical lines: Δx = 0
Understanding Line Segments and Distance
What is a Line Segment?
A line segment is a part of a line that is bounded by two distinct endpoints. Unlike a line, which extends infinitely in both directions, a line segment has a definite length.
Key Properties
- •Has two endpoints with specific coordinates
- •Has a fixed, measurable length
- •Can exist in 2D, 3D, or higher dimensions
- •Forms the basis for more complex geometric shapes
The Distance Formula
The distance formula calculates the straight-line distance between two points. It's based on the Pythagorean theorem and works in any number of dimensions.
Pythagorean Connection
The distance between two points forms the hypotenuse of a right triangle
Applications
Used in physics, engineering, computer graphics, and navigation systems
Coordinate Systems
2D Cartesian System
- • Uses X and Y axes perpendicular to each other
- • Points are represented as (x, y)
- • Common in plane geometry and basic algebra
- • Distance formula: d = √[(x₂-x₁)² + (y₂-y₁)²]
3D Cartesian System
- • Adds Z axis perpendicular to the XY plane
- • Points are represented as (x, y, z)
- • Used in solid geometry and 3D modeling
- • Distance formula: d = √[(x₂-x₁)² + (y₂-y₁)² + (z₂-z₁)²]