Diagonal Calculator

Calculate the diagonal of a rectangle, square, cube, or box. Use the Pythagorean theorem and its 3D extension: d = √(l² + w² + h²) for a rectangular box.

📐 Geometry📐 d = √(l² + w²)🔢 Math
Shape
Length l (or side s)
Width w
Height h (for 3D box)
Please enter valid values.

Formula & Reference

VariableSymbolFormulaUnits
Diagonal Calculatord = √(l² + w²)units

Step-by-Step Examples

Example 1
TV Screen

Rectangle 40×30 inches.

  • d=√(1600+900)=√2500=50 inches
  • A '50-inch TV' has 50-inch diagonal
✓ d = 50 inches
Example 2
Square Room

Room 10×10 ft.

  • d=10√2≈14.14 ft
  • Diagonal of square = side×√2
✓ d ≈ 14.14 ft
Example 3
Shipping Box

Box 3×4×5 cm.

  • d=√(9+16+25)=√50≈7.07 cm
✓ d ≈ 7.07 cm

Real-World Applications

Common Mistakes to Avoid

⚠️
Screen size is diagonal

A 55-inch TV means the diagonal is 55 inches. Width and height depend on aspect ratio.

⚠️
Square diagonal uses √2

For a square with side s: d = s√2 ≈ 1.414s. This is irrational — the ancient Greeks were troubled by this.

⚠️
3D diagonal is not just 2D + h

Space diagonal d = √(l²+w²+h²). You cannot just add h to the rectangle diagonal.

Frequently Asked Questions

What is the diagonal of a rectangle?
The longest internal measurement. Using Pythagorean theorem: d=√(l²+w²). The diagonal divides the rectangle into two congruent right triangles.
Why is the square diagonal irrational?
d=s√2. Since √2 is irrational (cannot be expressed as a fraction), the diagonal of a unit square is irrational. This was a shocking discovery for the ancient Greeks.
What is a space diagonal?
The longest diagonal of a 3D box, connecting opposite corners: d=√(l²+w²+h²). Extends Pythagoras to 3D.
How is screen size standardized?
Screens are measured by their diagonal in inches. A 16:9 screen with diagonal d has width≈0.872d and height≈0.490d.
What is the relationship between polygon diagonals?
A polygon with n sides has n(n−3)/2 diagonals. Triangle: 0, Quadrilateral: 2, Pentagon: 5, Hexagon: 9.

Related Math Calculators

Formula Explorer connections

Interpretation: This relationship connects dimensions, coordinates, angles or trigonometric ratios to a geometric measurement. Assumption: Use a consistent angle mode and length unit, identify the intended shape or coordinate system, and verify that the supplied dimensions form valid geometry.

Distance Formula Calculator →Double Angle Formula Calculator →Heron's Formula Calculator →Math Formula Explorer →