c = √(a²+b²) · leg · 3D diagonal

In a right triangle: c² = a² + b² (c — the hypotenuse, a, b — the legs).
The Pythagorean theorem relates the sides of a right triangle:
where is the hypotenuse (the longest side) and are the legs. Hence , and a missing leg is found as .
In space the theorem is applied twice, giving the space diagonal of a cuboid:
The calculator handles all three cases. The classic Pythagorean triple is 3-4-5 (since 3²+4²=5²).
The longest one — the side opposite the right angle. It is always c in the formula c² = a² + b². The legs (a, b) form the right angle.
By Pythagoras twice: first the base diagonal √(a²+b²), then the diagonal of the solid √((√(a²+b²))² + c²) = √(a²+b²+c²).
Teaching? Embed this calculator on your site.
Free widget — paste it on your school site, blog or notes. It links to the full version.