Right Triangle

Pythagorean Theorem Calculator

Enter any two sides of a right triangle and solve the third side. The calculator also shows the formula used, perimeter, area, and the two acute angles.

Triangle Sides

Leave one side blank. Side c is the hypotenuse.

Solved side

c = 13

5, 12, and 13 form a right triangle

Using c = sqrt(a^2 + b^2), c = sqrt(5^2 + 12^2) = 13.

Right triangle diagram with sides a, b, and c b = 12 a = 5 c = 13
Perimeter30
Area30
Angle A22.619865 deg
Angle B67.380135 deg

Calculation Details

The missing side is solved from a^2 + b^2 = c^2.

  • Formula: c = sqrt(a^2 + b^2)
  • Substitution: c = sqrt(5^2 + 12^2)
  • Check: 5^2 + 12^2 = 13^2
  • Hypotenuse: 13

What this Pythagorean theorem calculator is designed to solve

This calculator is built for one of the most common geometry workflows on the web: solving a missing side of a right triangle from the other two sides. That sounds simple until users need to know which formula branch applies, whether the supplied hypotenuse is valid, how the triangle diagram should look, and whether the result produces a real geometric figure rather than just a symbolic square-root expression.

The tool remains the main action surface above the fold. The long-form content below exists as a technical manual for the result so users can understand why the theorem works, how the solver chooses the right branch, and what hidden checks matter when validating a triangle rather than merely producing a number.

This matters for search intent because users are often not just plugging values into a formula. They are checking homework, validating construction measurements, comparing triangle triples, or confirming whether a drawing is actually consistent with a right angle.

Core Pythagorean formulas

Readable main formula: a squared + b squared = c squared.

Readable hypotenuse formula: c = square root of (a squared + b squared).

Readable leg formulas: a = square root of (c squared - b squared) and b = square root of (c squared - a squared).

Variable key: a and b are the two legs that meet at the right angle, and c is the hypotenuse opposite the 90 degree angle.

These formulas are deterministic as long as the triangle is a real right triangle. The most common user error is not algebra. It is misidentifying which side is supposed to be the hypotenuse or entering a hypotenuse that is too short.

Why the theorem only applies to right triangles

The Pythagorean theorem is not a generic triangle identity. It depends on the presence of a right angle. Without that 90 degree structure, the relation between side lengths changes and must be handled by other geometry tools such as the law of cosines.

This is one of the most important high-signal points on the page because weak calculator content often states the theorem correctly but does not emphasize its domain. Users then try to force it onto triangles that only look approximately right in a sketch.

A good theorem page should therefore function as a validity check as well as a solver. If the triangle is not right, the user needs a different mathematical model, not just a different numeric input.

How the calculator chooses the correct branch

When both legs are known, the page solves for the hypotenuse by adding the leg squares and taking the square root. When the hypotenuse and one leg are known, the page subtracts the known leg square from the hypotenuse square and then takes the square root to recover the missing leg.

That branching matters because the same three symbols do not all play the same role. Solving for c is an additive path. Solving for a or b is a subtractive path. Mixing them up can still produce a tidy expression that answers the wrong geometric question.

This is why the page labels side c as the hypotenuse directly in the interface. The user should not have to infer the role of the longest side silently while also trying to reason about the formula.

Why the hypotenuse must be the longest side

In every real right triangle, the hypotenuse is longer than either leg. That is not a convention. It falls directly out of the theorem, since c squared equals the sum of two positive leg squares and must therefore exceed either individual leg square.

This is the hidden variable behind most failed leg calculations. If a user enters side c shorter than or equal to a known leg, the subtraction under the square root becomes zero or negative and the triangle stops being geometrically valid.

A strong calculator page should explain this explicitly because it turns an error message into geometric understanding. The failure is not arbitrary. It is proof that the supplied side labels do not describe a real right triangle.

Area, perimeter, and angle interpretation

Once all three sides of a valid right triangle are known, the page can derive more than the missing length. The area comes from one half of leg a times leg b, the perimeter is the sum of all three sides, and the two acute angles can be recovered from inverse trigonometric relationships.

This additional output is useful because many users do not stop at the missing-side calculation. A builder may need perimeter, a student may need angles for a full diagram, and a geometry learner may want to connect side lengths to trig ratios immediately.

That makes the tool more than a single-formula widget. It becomes a compact right-triangle analysis surface.

The theorem as a geometric validation test

The Pythagorean theorem can be used in reverse as a check: if three side lengths satisfy a squared + b squared = c squared exactly, then the triangle is right. If they do not, then the triangle is not a perfect right triangle under exact arithmetic.

This is valuable in measurement workflows where users are checking layouts, drawings, or recorded values. A triangle can look square to the eye while failing the theorem numerically, especially when field measurements include rounding or drift.

For search users, this validation use case is often as important as the missing-side use case. The page should support both interpretations clearly.

Pythagorean triples and why they are useful

Pythagorean triples are whole-number side sets that satisfy the theorem exactly. Familiar examples include 3-4-5, 5-12-13, and 8-15-17. They are useful because they give clean right-triangle examples without decimal noise.

In teaching and quick checking, triples help users recognize when a result is likely correct before any calculator is involved. They also appear in construction and layout contexts where integer ratios are easier to communicate and verify.

That is why the page surfaces common triples rather than leaving them implicit. They are not trivia. They are one of the most practical ways to sanity-check right-triangle work.

Units, scaling, and interpretation

The theorem works with any consistent linear unit: meters, feet, centimeters, inches, or any other unit where all three sides are measured on the same scale. The key requirement is consistency, not a specific system.

If one side is in meters and another is in centimeters, the arithmetic can still run but the geometric meaning collapses. A high-quality page should remind users that the theorem assumes the side lengths belong to one coherent measurement system.

Scaling is also predictable: if every side of a right triangle is doubled, the theorem still holds, area scales by the square factor, and the acute angles remain unchanged.

Why a negative square-root result signals a setup problem

When solving for a leg, the expression under the square root must stay positive for a nonzero real triangle side to exist. If it goes negative, the issue is not a calculator glitch. The side configuration itself is impossible for a right triangle.

This is one of the most useful interpretive checks on the page because it teaches users how to diagnose bad input. A negative inside the radical is geometry telling you the designated hypotenuse is too short or the wrong side was marked as c.

Users often benefit more from that explanation than from a generic invalid-input message, because it ties the arithmetic failure back to the triangle structure.

How this relates to trigonometry

The Pythagorean theorem is tightly connected to trigonometry because sine, cosine, and tangent all live inside right-triangle relationships. Once the three sides are known, trig ratios and acute angles become straightforward to compute.

This is why the page includes angle outputs and why the related tools below point to trig calculators. In practice, many users solve a triangle side first and then move immediately into sine, cosine, tangent, or inverse-trig interpretation.

The theorem is therefore not isolated geometry. It is part of the broader right-triangle toolkit.

Why the theorem still matters in real work

The Pythagorean theorem remains one of the most used geometry relationships in construction, layout, surveying, drafting, CAD, navigation, and education because it turns perpendicular structure into a direct numeric check.

Even when a professional tool hides the formula under a visual interface, the logic underneath is often still the same. If two perpendicular components are known, the third side and the consistency of the right angle can usually be checked through this relationship.

That practical value is why a strong page should go beyond a one-line formula. Users need enough context to know when the theorem is the right tool and when it is not.

Use cases where this page adds real value

The obvious use case is solving the missing side of a right triangle. The higher-value use cases are usually narrower: checking whether measured sides really form a right triangle, generating a clean worked example, moving from side lengths into angle interpretation, or confirming that a proposed hypotenuse is geometrically possible.

A thin theorem page that only prints the formula misses that intent. Users often want a worked substitution, a visual triangle, a theorem check, and adjacent geometric outputs before the result becomes fully usable.

That is why the page pairs the solver with the diagram, the detail block, the FAQ, and the related trig tools. The goal is not just to produce one side length, but to make the triangle understandable.

Common Right Triangle Triples

3, 4, 5 5, 12, 13 7, 24, 25 8, 15, 17 9, 40, 41 20, 21, 29

Pythagorean Theorem FAQ

What is the Pythagorean theorem?

For a right triangle with legs a and b and hypotenuse c, the theorem states that a squared plus b squared equals c squared.

Which side is the hypotenuse?

The hypotenuse is the longest side of a right triangle and sits opposite the 90 degree angle. In this calculator it is side c.

Can I solve for a leg instead of the hypotenuse?

Yes. Enter c and one leg. The calculator uses a = sqrt(c^2 - b^2) or b = sqrt(c^2 - a^2).

Why does the hypotenuse need to be longer?

For a real right triangle, c must be greater than each leg. If c is not longer than the known leg, c^2 - leg^2 is zero or negative and no valid right-triangle side is produced.

Can I use this theorem on any triangle?

No. The Pythagorean theorem applies only to right triangles. If the triangle does not contain a 90 degree angle, the relationship a squared plus b squared equals c squared does not hold in that direct form.

Why does the calculator show angles as well as side lengths?

Once the three sides of a valid right triangle are known, the two acute angles can be derived with inverse trigonometric relationships. That gives extra geometric context beyond the missing-side calculation alone.

What are Pythagorean triples?

Pythagorean triples are whole-number side sets that satisfy the theorem exactly, such as 3-4-5 or 5-12-13. They are useful for quick checking and for building examples with clean integer results.

Why might a triangle side calculation fail?

The most common failure is trying to solve a leg when the supplied hypotenuse is not actually the longest side. In that case the square-root step would require the square root of a negative number, which does not produce a real triangle side.