NOTACAL logo

Pythagorean Theorem Calculator

Pythagorean Theorem Calculator

Enter values

Introduction

The Pythagorean Theorem Calculator is an essential tool for anyone working with right triangles. This fundamental principle of geometry, discovered by the ancient Greek mathematician Pythagoras around 500 BCE, describes the relationship between the three sides of a right triangle. The theorem states that the square of the hypotenuse equals the sum of the squares of the other two sides. This simple yet powerful relationship has been used for thousands of years in architecture, engineering, navigation, and countless other applications.

The importance of the Pythagorean theorem extends far beyond simple geometry problems. It forms the foundation of trigonometry and is essential for understanding concepts in physics, engineering, computer graphics, and surveying. Whether you are a student learning geometry, a construction worker calculating roof pitches, or a game developer programming 3D graphics, the Pythagorean theorem is an indispensable tool. It is one of the most widely taught and applied mathematical concepts in history, appearing in curricula around the world.

The theorem remains relevant in the modern world due to its practical applications in technology. Global Positioning System technology uses the theorem to calculate positions. Computer graphics use it for distance calculations between pixels. Architects use it to ensure structures are level and properly proportioned. Even simple tasks like determining if furniture will fit through a doorway can be solved using this ancient mathematical principle.

For more information, see the Right Triangle Calculator.

How to Use

Using the Pythagorean Theorem Calculator is straightforward. The key is knowing which sides you have and which side you need to find.

Finding the Hypotenuse

If you know the lengths of both legs, you can find the hypotenuse. Enter the length of leg a and leg b, then select calculate. The calculator will compute the hypotenuse using the formula c equals the square root of a squared plus b squared. This is the most common use of the Pythagorean theorem.

Finding a Missing Leg

If you know the hypotenuse and one leg, you can find the other leg. Enter the hypotenuse length and the known leg, then calculate. The calculator uses the formula a equals the square root of c squared minus b squared. This is useful when you know the diagonal distance and one side length.

Understanding the Results

The calculator displays not only the numerical answer but also the step-by-step calculation. This helps students understand the mathematical process and verify that their manual calculations are correct. The result is typically displayed to two decimal places for precision, though exact values are provided where applicable.

Formulas and Calculations

Basic Pythagorean Theorem

The fundamental formula relating the three sides of a right triangle is:

a2+b2=c2a^2 + b^2 = c^2

Where a and b are the legs and c is the hypotenuse.

Solving for the Hypotenuse

When both legs are known:

c=a2+b2c = \sqrt{a^2 + b^2}

Example: For a triangle with legs 3 and 4, the hypotenuse equals the square root of 3 squared plus 4 squared, which equals the square root of 9 plus 16, which equals the square root of 25, which equals 5.

Solving for a Missing Leg

When the hypotenuse and one leg are known:

a=c2b2a = \sqrt{c^2 - b^2}

Example: For a triangle with hypotenuse 10 and one leg 6, the other leg equals the square root of 10 squared minus 6 squared, which equals the square root of 100 minus 36, which equals the square root of 64, which equals 8.

Law of Cosines (Extension)

The Pythagorean theorem is a special case of the Law of Cosines:

c2=a2+b22abcos(C)c^2 = a^2 + b^2 - 2ab \cdot \cos(C)

When angle C equals 90 degrees, the cosine term becomes zero, reducing the formula to the Pythagorean theorem.

Reference Table: Common Pythagorean Triples

A Pythagorean triple consists of three positive integers that satisfy the Pythagorean theorem.

TripleabcCommon Use
3-4-5345Most common
5-12-1351213Surveying
8-15-1781517Engineering
7-24-2572425Navigation
9-40-4194041Ancient structures
6-8-106810Scaled 3-4-5

Real-World Examples

Example 1: Construction

A contractor needs to check if a corner is square. They measure 3 feet along one wall and 4 feet along the other wall. The diagonal should measure exactly 5 feet for a perfect right angle. This is a traditional method used in carpentry and masonry to ensure structures are properly aligned.

Example 2: Ladder Safety

A 15-foot ladder is placed with its base 9 feet from a wall. How high does the ladder reach on the wall? Using the Pythagorean theorem: height equals the square root of 15 squared minus 9 squared, which equals the square root of 225 minus 81, which equals the square root of 144, which equals 12 feet. This helps ensure safe ladder placement.

Example 3: Screen Size Measurement

Television and monitor sizes are measured diagonally. If a monitor is 24 inches wide and 14 inches tall, what is its diagonal size? Diagonal equals the square root of 24 squared plus 14 squared, which equals the square root of 576 plus 196, which equals the square root of 772, which approximately equals 27.8 inches.

Example 4: Navigation

A hiker walks 4 miles due north, then 3 miles due east. How far are they from the starting point? Distance equals the square root of 4 squared plus 3 squared, which equals 5 miles. This is the direct distance as the crow flies, useful for navigation and estimating travel time.

Example 5: Baseball Field

The distance from home plate to second base in baseball is the diagonal of a square. If the distance from home to first base is 90 feet, the distance to second base equals 90 times the square root of 2, which equals approximately 127.3 feet. This calculation is essential for field design and player positioning.

Common Pythagorean Triples Multiples

When working with scaled versions of the basic triples, the multiplier applies to all three sides. The 3-4-5 triangle is particularly versatile:

MultiplierSidesExample Use
13, 4, 5Small scale models
26, 8, 10Medium construction
39, 12, 15Larger projects
412, 16, 20Engineering
515, 20, 25Surveying
1030, 40, 50Large distances

This property allows the theorem to be applied at any scale, from microscopic measurements to astronomical distances.

Proving the Pythagorean Theorem

Over the years, many different proofs of the Pythagorean theorem have been discovered. Here are three famous approaches:

Visual Proof (Rearrangement)

Consider a square with side a + b containing four right triangles and a central square of side c. The area can also be expressed as the sum of the four triangles plus the inner square. By equating these two expressions and simplifying, we derive a squared plus b squared equals c squared.

Algebraic Proof

Using similar triangles, one can show that the ratios of sides in right triangles follow specific relationships. This leads directly to the Pythagorean relationship through algebraic manipulation of proportions.

Euclidean Proof

Euclid's Elements contains a proof using geometry that does not rely on algebra. This proof demonstrates that the area of the square on the hypotenuse equals the sum of the areas of the squares on the two legs.

Applications in Technology

GPS and Location Technology

The Global Positioning System uses trilateration, which relies on distance calculations between satellites and receivers. The Pythagorean theorem enables accurate position determination on Earth.

Computer Graphics

Video games and computer simulations use the Pythagorean theorem constantly. It calculates distances between objects, determines lighting angles, and helps animate movement. The theorem enables realistic physics simulations and collision detection.

Surveying and Mapping

Surveyors use the Pythagorean theorem to calculate distances that cannot be measured directly. By measuring horizontal distances and height differences, they can compute straight-line distances.

Architecture and Engineering

Structural engineers use the theorem to ensure buildings are properly supported. It helps calculate roof pitches, foundation dimensions, and load-bearing capacities.

Limitations

Only for Right Triangles

The Pythagorean theorem applies specifically to right triangles where one angle equals exactly 90 degrees. For other triangle types, the Law of Cosines must be used instead.

Requires Accurate Measurements

The accuracy of calculations depends entirely on the accuracy of input measurements. Small measurement errors can lead to significant discrepancies in calculated distances, especially over large scales.

Integer Results Are Rare

While common textbook problems often yield integer results, real-world measurements usually produce decimal values. The calculator provides decimal approximations rather than exact values in most cases.

Cannot Verify Right Angles Alone

The theorem can calculate side lengths but cannot determine if a triangle is actually a right triangle. The presence of a 90-degree angle must be verified independently.

Special Right Triangles

45-45-90 Triangle

When the two legs are equal, the triangle is isosceles. The relationship is simple: if each leg equals L, then the hypotenuse equals L times the square root of 2. This appears frequently in diagonal measurements of squares.

30-60-90 Triangle

This special triangle has sides in the ratio 1 to the square root of 3 to 2. The shortest leg is half the hypotenuse, and the longer leg is the short leg times the square root of 3. This appears in hexagons and equilateral triangles cut in half.

Practical Tips

Estimation

For quick mental calculations, remember that 3-4-5 is the simplest triple. Any multiple works: 6-8-10, 9-12-15, and so on. For approximate calculations, 5-12-13 and 7-24-25 are also useful.

Verification

After calculating, verify your answer by checking if the sides make sense. The hypotenuse must be longer than either leg, and the sum of the squares of the legs should equal the square of the hypotenuse.

Units

Always ensure all measurements use the same units before calculating. Convert inches to feet or meters to centimeters as needed before applying the formula.

Common Mistakes

A frequent error is confusing which side is the hypotenuse. Remember: the hypotenuse is always the longest side and is opposite the right angle. Another mistake is forgetting to take the square root at the end.

Frequently Asked Questions

What is the Pythagorean theorem?
In a right triangle: a^2 + b^2 = c^2, where c is the hypotenuse (longest side).
How do I use this calculator?
Enter any two side lengths. The calculator solves for the missing side automatically.
Can I solve for legs if I only know the hypotenuse?
No. You need one more value — either a leg length or an angle.
What if my values do not form a right triangle?
If a^2 + b^2 does not equal c^2, the calculator warns the input does not satisfy the theorem.
Does the order of sides a and b matter?
No. Only the hypotenuse c must be the longest side.

References

Last updated: May 28, 2026