Pythagorean Theorem Calculator
Use the Pythagorean theorem to solve for a missing side of a right triangle. Enter two known sides and calculate side a, side b, or hypotenuse c.
Enter two known sides
Choose which side you want to solve for, then enter the two known measurements. The calculator uses a² + b² = c².
a² + b² = c²
c = √(a² + b²)
a = √(c² − b²)
b = √(c² − a²)
Whether you are building a staircase, designing a roof pitch, working through a geometry exam, or troubleshooting a surveying problem, the Pythagorean Theorem is one of the most powerful and widely applied formulas in all of mathematics. This free Pythagorean Theorem calculator lets you solve for any unknown side of a right triangle instantly — just enter two known values and the tool handles the rest. Below, you will find a comprehensive guide covering the theorem's formula, history, step-by-step worked examples, real-world use cases, common mistakes, and advanced applications so you understand not just the answer, but why it works.
This calculator is part of the free math calculator collection available on WalDev, where you can find dozens of tools designed to make complex calculations fast, accurate, and completely free.
Table of Contents
Jump to any section of this guide using the links below.
What Is the Pythagorean Theorem?
The Pythagorean Theorem is a fundamental principle in Euclidean geometry that describes a fixed mathematical relationship between the three sides of any right triangle. A right triangle is defined as a triangle in which exactly one of the three interior angles measures exactly 90 degrees. The theorem states that the square of the longest side — called the hypotenuse — is always equal to the sum of the squares of the other two sides, which are called legs.
This deceptively simple rule turns out to be extraordinarily useful. It provides a way to calculate an unknown side length whenever the other two are known. It also works in reverse: if three side lengths satisfy the equation, you can confirm that the triangle must contain a right angle without ever measuring it directly. This dual power — both to calculate and to verify — is what makes the theorem so valuable across so many disciplines.
The theorem is taught in virtually every middle school and high school mathematics curriculum worldwide, but its applications extend far beyond the classroom. Engineers, architects, carpenters, navigators, physicists, game developers, and data scientists all rely on the same foundational relationship Pythagoras made famous more than two thousand years ago.
The Two Legs (a and b)
The two shorter sides of a right triangle that form the 90-degree angle are called legs. In the standard formula they are labeled a and b. Either leg can be placed in the a or b position — the formula is symmetrical, so the result is the same either way.
The Hypotenuse (c)
The hypotenuse is the longest side of the right triangle and is always positioned directly opposite the 90-degree angle. It is labeled c in the formula. The hypotenuse is always longer than either individual leg but shorter than the sum of the two legs.
The Formula: a² + b² = c²
The Pythagorean Theorem is expressed in its classic form as a single, elegant equation. Every calculation you will ever perform with this theorem flows directly from this one relationship.
a² + b² = c²
Where a and b are the two legs and c is the hypotenuse (the side opposite the right angle).
From this single equation, three practical rearrangements can be derived depending on which side is unknown:
Solve for c (Hypotenuse)
c = √(a² + b²)
Use this when both legs are known and you need the length of the longest side.
Solve for a (Leg)
a = √(c² − b²)
Use this when the hypotenuse and one leg are known. Subtract, then take the square root.
Solve for b (Leg)
b = √(c² − a²)
Identical in structure to solving for a — subtract the known leg's square from the hypotenuse squared.
Key insight: The formula is always symmetric with respect to a and b. There is no mathematical distinction between which leg you call "a" and which you call "b" — swapping them produces exactly the same hypotenuse.
How to Use This Pythagorean Theorem Calculator
The calculator at the top of this page is designed to be as straightforward as possible. You only need two of the three values — the tool will solve for the third. Here is exactly how to use it:
Decide whether you need to find the hypotenuse (c) or one of the two legs (a or b). This determines which input field you leave blank.
Type the two values you already know into the appropriate fields. Side lengths can be whole numbers, decimals, or fractions. Make sure all values use the same unit of measurement — do not mix inches and centimeters, for example.
The calculator automatically detects which field is missing and applies the correct rearrangement of the formula. Simply leave that field blank or set it to zero.
The calculator returns the missing side length. If the result is a decimal, it is already rounded appropriately. You can verify the result by plugging all three values back into a² + b² = c² to confirm they balance.
Remember that the result carries the same unit as the values you entered. If your inputs were in meters, the output is in meters. If in feet, the output is in feet.
Important: This calculator only works for right triangles. If your triangle does not contain a 90-degree angle, the Pythagorean Theorem does not apply. For oblique triangles, you would need the Law of Cosines or the Law of Sines instead. You can also use the right triangle calculator on WalDev if you need to solve for angles as well as sides.
Finding the Hypotenuse — Step-by-Step Worked Examples
Finding the hypotenuse is the most common use of the Pythagorean Theorem. You are given both legs and need to determine the length of the longest side. The process always follows three steps: square both legs, add the results, take the square root.
Example 1: The Classic 3-4-5 Triangle
This is the most well-known Pythagorean triple. Suppose one leg measures 3 units and the other measures 4 units. What is the hypotenuse?
✓ Worked Example
Given: a = 3, b = 4, find c
Step 1 — Square each leg: 3² = 9, and 4² = 16
Step 2 — Add the squares: 9 + 16 = 25
Step 3 — Take the square root: √25 = 5
Result: The hypotenuse c = 5 units
Example 2: A Decimal Result
Not every calculation produces a clean whole number. Suppose one leg is 6 cm and the other is 8 cm. Wait — actually, let us try legs of 5 cm and 7 cm, which will not produce a perfect square.
✓ Worked Example
Given: a = 5 cm, b = 7 cm, find c
Step 1 — Square each leg: 5² = 25, and 7² = 49
Step 2 — Add the squares: 25 + 49 = 74
Step 3 — Take the square root: √74 ≈ 8.602 cm
Result: The hypotenuse c ≈ 8.602 cm (an irrational number, rounded to 3 decimal places)
Example 3: A Real-World Ladder Problem
A ladder leans against a wall. The bottom of the ladder is placed 4 feet from the base of the wall, and the top of the ladder rests 10 feet up the wall. How long is the ladder?
✓ Worked Example
Given: horizontal distance a = 4 ft, vertical height b = 10 ft, find c (ladder length)
Step 1: 4² = 16, and 10² = 100
Step 2: 16 + 100 = 116
Step 3: √116 ≈ 10.77 ft
Result: The ladder must be approximately 10.77 feet long
Finding a Missing Leg — When You Know the Hypotenuse
Sometimes you know the hypotenuse and one leg but need to find the second leg. This situation arises frequently in construction (when you know the diagonal and one dimension of a rectangle) and in navigation (when you know the total path distance and one directional component). The key difference is that instead of adding the squares, you subtract them.
b = √(c² − a²)
Subtract the square of the known leg from the square of the hypotenuse, then take the square root.
Example 1: Finding the Second Leg
✓ Worked Example
Given: hypotenuse c = 13, one leg a = 5, find b
Step 1 — Square both known sides: 13² = 169, and 5² = 25
Step 2 — Subtract: 169 − 25 = 144
Step 3 — Take the square root: √144 = 12
Result: The missing leg b = 12 units. This is the famous 5-12-13 Pythagorean triple.
Example 2: A Room Diagonal Problem
You are laying flooring in a rectangular room. The diagonal of the room (from corner to corner) is 25 feet. One wall measures 15 feet. What is the length of the adjacent wall?
✓ Worked Example
Given: c = 25 ft, a = 15 ft, find b
Step 1: 25² = 625, and 15² = 225
Step 2: 625 − 225 = 400
Step 3: √400 = 20
Result: The adjacent wall is exactly 20 feet long. This is the 15-20-25 triple, which is the 3-4-5 triple scaled by a factor of 5.
Example 3: A Non-Integer Result
✓ Worked Example
Given: c = 10 m, a = 4 m, find b
Step 1: 10² = 100, and 4² = 16
Step 2: 100 − 16 = 84
Step 3: √84 ≈ 9.165 m
Result: The missing leg b ≈ 9.165 meters
Once you have all three sides, you can calculate all three angles of the right triangle. The right triangle calculator on WalDev handles both sides and angles in one tool.
Pythagorean Triples — When All Three Sides Are Whole Numbers
A Pythagorean triple is a set of three positive integers (a, b, c) that satisfy a² + b² = c² exactly. These are particularly useful in practical work because they produce right triangles with no irrational numbers, making them easy to measure and construct physically. The most famous is (3, 4, 5), but there are infinitely many others, and any multiple of a known triple is also a valid triple.
| Leg a | Leg b | Hypotenuse c | Verification (a² + b² = c²) | Common Use |
|---|---|---|---|---|
| 3 | 4 | 5 | 9 + 16 = 25 ✓ | The most common; used in construction to check square corners |
| 5 | 12 | 13 | 25 + 144 = 169 ✓ | Roofing, structural engineering |
| 8 | 15 | 17 | 64 + 225 = 289 ✓ | Surveying, carpentry |
| 7 | 24 | 25 | 49 + 576 = 625 ✓ | Navigation and mapping |
| 6 | 8 | 10 | 36 + 64 = 100 ✓ | Scaled version of 3-4-5; very common in building |
| 9 | 40 | 41 | 81 + 1600 = 1681 ✓ | Larger structural calculations |
| 20 | 21 | 29 | 400 + 441 = 841 ✓ | Civil engineering |
| 28 | 45 | 53 | 784 + 2025 = 2809 ✓ | Advanced geometry problems |
How to Generate New Pythagorean Triples
Any known triple can be scaled into a new triple by multiplying all three values by the same positive integer. For example, multiplying (3, 4, 5) by 2 gives (6, 8, 10); multiplying by 3 gives (9, 12, 15); and so on. All of these scaled versions are valid right triangles.
There is also a general formula for generating primitive triples (ones where a, b, and c share no common factor): choose any two positive integers m and n where m is greater than n. Then a = m² − n², b = 2mn, and c = m² + n². For m = 2, n = 1: a = 3, b = 4, c = 5 — the classic triple.
Practical tip for construction: The 3-4-5 method is used on job sites worldwide to confirm that a corner is perfectly square. Measure 3 units along one wall and 4 units along the adjacent wall, then check that the diagonal between those two points measures exactly 5 units. If it does, the corner is square.
Real-World Applications of the Pythagorean Theorem
The Pythagorean Theorem is not merely an academic exercise. It appears constantly in professional practice across a remarkable range of fields. Understanding where it applies helps you recognize when to reach for it in your own work.
🏛 Construction and Architecture
Builders use the theorem every day. When framing a wall, calculating a rafter length for a roof, checking that a foundation is square, or determining the diagonal of a concrete slab, the Pythagorean Theorem provides the necessary answer. Rafter length calculations are essentially hypotenuse problems where the horizontal run and vertical rise of the roof are the two legs.
⛹ Navigation and GPS
Air and sea navigators calculate straight-line distances between two points using coordinate geometry that is directly derived from the Pythagorean Theorem. GPS systems perform these calculations thousands of times per second. When a ship knows its north-south displacement and east-west displacement, the direct-line distance is the hypotenuse of the triangle formed by those two components.
💻 Computer Graphics and Game Development
Every time a game engine calculates the distance between two objects on screen — to detect a collision, to render a shadow, or to determine line-of-sight — it is using the Pythagorean Theorem. The distance formula d = √((x₂−x₁)² + (y₂−y₁)²) is the theorem applied to coordinate geometry. In 3D games, it extends to three dimensions: d = √(x² + y² + z²).
🛠 Engineering and Manufacturing
Mechanical engineers calculate diagonal bracing lengths in structural frames, electrical engineers calculate signal path lengths in circuit board layouts, and manufacturing engineers verify part dimensions on the shop floor. Anytime a diagonal distance in a rectangular or right-angle context needs to be determined, the theorem provides it.
🏭 Surveying and Land Measurement
Surveyors establish property boundaries and elevation changes by measuring triangles across terrain. When a surveyor cannot measure a distance directly because of an obstacle, they measure the two sides of a right triangle around the obstacle and calculate the hypotenuse. This is one of the oldest practical uses of the theorem, dating back to ancient Egyptian land surveying after the annual Nile floods.
📈 Physics and Science
In physics, vector components are frequently combined using the Pythagorean Theorem. If an object moves 30 m/s east and 40 m/s north, its actual speed is √(30² + 40²) = 50 m/s. Similarly, the resultant of two perpendicular forces is the hypotenuse of a force triangle. These calculations appear in mechanics, electromagnetism, fluid dynamics, and optics.
Specific Scenario: Calculating Stair Dimensions
When a carpenter designs a staircase, the diagonal length of a stringer — the angled board that supports the steps — is a classic Pythagorean problem. Suppose a staircase must rise 8 feet vertically and travel 10 feet horizontally. The length of the stringer is √(8² + 10²) = √(64 + 100) = √164 ≈ 12.81 feet. Without this calculation, ordering the right amount of lumber would be guesswork.
Specific Scenario: Screen and Display Sizing
Television and monitor sizes are traditionally measured diagonally. A display described as "55 inches" has a 55-inch diagonal. If you know the screen is 16:9 aspect ratio, you can use the Pythagorean Theorem to determine the exact width and height. For a 55-inch 16:9 display: if the width is 16x and the height is 9x, then (16x)² + (9x)² = 55², giving 256x² + 81x² = 3025, so 337x² = 3025, x ≈ 2.996, meaning the screen is approximately 47.94 inches wide and 26.97 inches tall.
The volume calculator on WalDev can help you work out the capacity of boxes, cylinders, and other 3D shapes — a common companion task to right-triangle geometry in construction projects.
History and Origins of the Pythagorean Theorem
The theorem bears the name of Pythagoras of Samos, a Greek mathematician and philosopher who lived approximately from 570 to 495 BCE. However, the relationship between the sides of a right triangle was known and used by several ancient civilizations long before Pythagoras is thought to have formalized a proof.
Babylonian Mathematics
Archaeological evidence shows that Babylonian mathematicians understood the principle at least 1,200 years before Pythagoras. The clay tablet known as Plimpton 322, dated to roughly 1800 BCE, contains a table of Pythagorean triples written in base-60 cuneiform numerals. Babylonian scribes clearly knew how to work with these number relationships, likely for practical surveying and construction purposes, even if they did not articulate a formal general theorem.
You can read more about the mathematical history of this theorem through resources like the Encyclopaedia Britannica's entry on the Pythagorean Theorem, which provides a thorough historical overview.
Indian Mathematics
The Sulba Sutras, ancient Indian texts dating from approximately 800 to 200 BCE, contain geometric principles that include the Pythagorean relationship. Indian mathematician Baudhayana explicitly described the theorem in these texts: "The diagonal of a square produces double the area of the original square." While phrased geometrically, the concept directly encodes a² + b² = c².
Chinese Mathematics
The Chinese mathematical text Zhoubi Suanjing, believed to date from around 1000 BCE to 200 CE, contains a demonstration of the theorem using a visual proof based on area rearrangement. The Chinese referred to the theorem as the Gougu theorem (勾股定理), names derived from the names for the two legs of a right triangle.
Pythagoras and the Greeks
What distinguishes Pythagoras's contribution is not the discovery of the numerical relationship but rather the development of a rigorous deductive proof — a cornerstone of the Greek mathematical tradition. Pythagoras and his followers, the Pythagoreans, valued mathematical proofs as philosophical achievements, not just practical tools. The theorem's association with his name reflects both the Greek emphasis on proof and the enormous influence of Euclid's Elements, which included the proof and spread it throughout the Western world.
Over 370 Known Proofs
The Pythagorean Theorem is one of the most proved theorems in all of mathematics. More than 370 distinct proofs are known, ranging from geometric area arguments to algebraic manipulations to trigonometric derivations. Even former U.S. President James A. Garfield published an original proof in 1876, using a trapezoid area argument.
The Converse of the Pythagorean Theorem
The converse of the Pythagorean Theorem is just as important as the theorem itself. While the theorem tells you that if a triangle has a right angle, then a² + b² = c² must hold, the converse flips this logic: if a² + b² = c² holds for three side lengths, then the triangle must have a right angle.
This makes the converse a practical test for right angles. Rather than measuring an angle directly — which requires a protractor or angle gauge — you can measure three side lengths, plug them into the equation, and know definitively whether the corner is square.
Using the Converse in Practice
Construction quality control: After pouring a concrete foundation, workers measure the two walls and the diagonal. If the diagonal matches the calculated hypotenuse of a 3-4-5 triangle (or any valid triple at the correct scale), the corner is confirmed square. This is faster and more reliable than an angle gauge on a large structure.
Checking furniture assembly: When assembling flat-pack furniture, measuring the diagonal of a rectangular frame and comparing it to the expected hypotenuse confirms whether the frame is sitting at 90 degrees before the joints are tightened.
Verifying right-angle cuts: A carpenter making a miter cut can verify the cut angle by measuring all three sides of the triangle formed by the cut piece and checking the equation.
Classifying triangles: Beyond right triangles, you can use the converse to determine whether a triangle is acute or obtuse. If a² + b² is greater than c², the triangle is acute. If a² + b² is less than c², the triangle is obtuse.
The Pythagorean Theorem and the Distance Formula
One of the most important applications of the Pythagorean Theorem in modern mathematics is the distance formula used in coordinate geometry. When you place two points on a coordinate plane and want to find the straight-line distance between them, you are effectively finding the hypotenuse of a right triangle whose legs are the horizontal and vertical distances between the two points.
d = √((x₂ − x₁)² + (y₂ − y₁)²)
The horizontal difference (x₂ − x₁) is leg a. The vertical difference (y₂ − y₁) is leg b. The distance d is the hypotenuse c.
Worked Example: Distance Between Two Points
✓ Worked Example
Points: A = (1, 2) and B = (5, 5)
Horizontal difference: 5 − 1 = 4 (this is leg a)
Vertical difference: 5 − 2 = 3 (this is leg b)
Distance: √(4² + 3²) = √(16 + 9) = √25 = 5
Result: The straight-line distance between A and B is 5 units — and we have secretly just solved a 3-4-5 triangle in coordinate form.
Why This Matters for Data Science and Analytics
Machine learning algorithms frequently use Euclidean distance — which is simply the multi-dimensional generalization of the distance formula — to measure how similar two data points are. Algorithms like k-nearest neighbors (kNN) and k-means clustering calculate distances between data points in spaces with dozens or hundreds of dimensions, all using the same fundamental relationship that Pythagoras described for a simple flat triangle.
For anyone working with percentages and ratios in their data analysis, WalDev's percent difference calculator and percent error calculator can be useful companions when evaluating the accuracy of calculated measurements against expected values.
Extending the Pythagorean Theorem to Three Dimensions
The Pythagorean Theorem does not stop at two dimensions. In three-dimensional space, you can find the diagonal distance through a rectangular box using an extended version of the formula. This is sometimes called the "space diagonal" problem and is directly derived by applying the theorem twice.
d = √(l² + w² + h²)
Where l = length, w = width, and h = height of the rectangular box, and d is the diagonal distance from one corner to the opposite corner through the interior.
How the 3D Formula Is Derived
The derivation is elegant: first, find the diagonal of the rectangular base using the standard theorem: d_base = √(l² + w²). This base diagonal and the height h now form another right triangle, where the base diagonal is one leg, the height is the other, and the full 3D diagonal is the hypotenuse. Applying the theorem again: d = √(d_base² + h²) = √(l² + w² + h²).
✓ Worked Example — Box Diagonal
Given: A storage box is 4 m long, 3 m wide, and 2 m tall. What is the longest item that could fit inside the box diagonally?
Apply: d = √(4² + 3² + 2²) = √(16 + 9 + 4) = √29 ≈ 5.385 m
Result: Any item shorter than approximately 5.385 m could theoretically fit diagonally through the interior of the box.
Applications of the 3D Extension
This three-dimensional form is used in shipping logistics (to determine maximum diagonal dimension for irregular cargo), interior design (to determine whether a long piece of furniture can fit through a hallway), physics (to calculate resultant velocity vectors in 3D), and computer graphics (to calculate distances between objects in 3D space). The standard deviation calculator and other statistical tools on WalDev are often used alongside geometry tools when analyzing measurement data from physical experiments in these fields.
Common Mistakes to Avoid When Using the Pythagorean Theorem
Despite its simplicity, the Pythagorean Theorem is the source of a surprising number of calculation errors, especially under exam conditions or when applied in the field. Knowing the most common mistakes in advance helps you avoid them.
Mistake 1 — Forgetting to take the square root at the end. After computing a² + b², many students write that answer as c rather than c². The final answer requires a square root. The formula gives c² = a² + b², so c = √(a² + b²). Always apply the square root as the last step.
Mistake 2 — Adding the sides instead of their squares. The theorem squares the side lengths before adding them. A common error is writing a + b = c rather than a² + b² = c². For the 3-4-5 triangle: 3 + 4 = 7, which is not the hypotenuse. The correct process: 3² + 4² = 9 + 16 = 25, and √25 = 5.
Mistake 3 — Misidentifying the hypotenuse. The hypotenuse is always the side opposite the right angle. If you label the wrong side as c and apply the formula, your result will be wrong. Always confirm which angle is 90 degrees before assigning variable names to the sides.
Mistake 4 — Using the theorem on non-right triangles. The Pythagorean Theorem is exclusively for right triangles. Applying it to an equilateral, isosceles, or scalene triangle without a right angle will produce an incorrect answer. Use the Law of Cosines for other triangle types.
Mistake 5 — Mixed units. All three side lengths must be measured in the same unit. If one leg is measured in feet and the other in inches, you must convert before applying the formula. The result will be in the same unit as the inputs.
Mistake 6 — Subtracting wrong when finding a leg. When solving for a missing leg, you subtract: b = √(c² − a²). A common error is adding instead: √(c² + a²). If your computed leg is longer than the hypotenuse, this is the likely cause — check your operation sign.
Mistake 7 — Assigning a leg value larger than the hypotenuse. If you are given a hypotenuse of 5 and one leg of 6, the formula will try to compute √(5² − 6²) = √(25 − 36) = √(−11), which has no real solution. A leg can never be longer than the hypotenuse. If your inputs produce a negative number under the square root, one of your values is wrong.
For students: The most common exam error is forgetting the square root. Before writing your final answer, double-check: did you compute c², or did you compute c? The exponent and the radical must always be matched. Writing c² = 25 and answering "c = 25" is a classic and preventable mistake.
Classic Proofs of the Pythagorean Theorem
Understanding at least one proof of the theorem gives you genuine insight into why the relationship must be true, not just confidence that a formula works. Here are three of the most accessible and elegant proofs among the hundreds that exist.
Proof 1: The Geometric Area Proof (Bhaskara's Proof)
One of the most visually intuitive proofs arranges four identical right triangles inside a large square. Place four copies of a right triangle (with legs a and b and hypotenuse c) around the interior of a large square of side length (a + b). The four triangles fit neatly inside, leaving a smaller square in the center with side length c. The area of the large square is (a + b)², and the area of the four triangles is 4 × (½ × a × b) = 2ab. So the area of the inner square is (a + b)² − 2ab = a² + 2ab + b² − 2ab = a² + b². Since that inner square has side c, its area is also c². Therefore a² + b² = c².
Proof 2: Euclid's Proof from Elements (Book I, Proposition 47)
Euclid's proof is longer but entirely rigorous. It constructs squares on each of the three sides of the right triangle and then uses congruence arguments to show that the areas of the two smaller squares sum to the area of the largest. This proof is the one taught in traditional classical geometry courses and is the version most often attributed to Pythagoras himself.
Proof 3: The Similar Triangles Proof
Draw an altitude from the right angle of the triangle to the hypotenuse, creating two smaller triangles. Both smaller triangles are similar to the original and to each other. From the proportional relationships in similar triangles, it follows directly that a² + b² = c². This proof is particularly elegant because it requires no area calculations — only the properties of similar triangles.
Proof 4: The Algebraic Proof
Consider a large square with side (a + b). Place four right triangles inside it so that their hypotenuses form an inner tilted square of side c. Area of outer square = (a + b)² = a² + 2ab + b². Area of four triangles = 4 × ½ab = 2ab. Area of inner square = (a + b)² − 2ab = a² + b². But the inner square has side c, so its area = c². Therefore c² = a² + b².
The chain rule calculator and double integral calculator on WalDev are useful tools when the Pythagorean relationship appears inside more advanced mathematical contexts.
Special Right Triangles and the Pythagorean Theorem
Two special right triangles appear so frequently in geometry and trigonometry that their side ratios are worth memorizing. Both are derived directly from the Pythagorean Theorem.
The 45-45-90 Triangle (Isosceles Right Triangle)
A 45-45-90 triangle is a right triangle where both acute angles measure 45 degrees. Because the two acute angles are equal, the two legs must also be equal. If both legs measure 1, then by the Pythagorean Theorem: c = √(1² + 1²) = √2. The side ratio for a 45-45-90 triangle is always 1 : 1 : √2.
This means if you know one leg, you can immediately find the hypotenuse by multiplying by √2 (approximately 1.414). And if you know the hypotenuse, divide by √2 to find each leg. This triangle appears constantly in geometry problems, particularly when working with squares — the diagonal of any square forms a 45-45-90 triangle with two of its sides.
✓ Quick Reference — 45-45-90
Leg = 6 → Hypotenuse = 6√2 ≈ 8.485
Hypotenuse = 10 → Each leg = 10/√2 = 5√2 ≈ 7.071
The 30-60-90 Triangle
A 30-60-90 triangle has angles of 30, 60, and 90 degrees. Its side ratios are 1 : √3 : 2. The shortest side (opposite the 30° angle) is half the hypotenuse. The longer leg (opposite the 60° angle) is the shortest side multiplied by √3. You can verify this with the Pythagorean Theorem: 1² + (√3)² = 1 + 3 = 4 = 2².
This triangle appears in equilateral triangle problems (where dropping an altitude bisects it into two 30-60-90 triangles), in trigonometry (where the sine and cosine of 30° and 60° are derived from it), and in many engineering and physics applications.
✓ Quick Reference — 30-60-90
Short leg = 5 → Long leg = 5√3 ≈ 8.660, Hypotenuse = 10
Hypotenuse = 8 → Short leg = 4, Long leg = 4√3 ≈ 6.928
| Triangle Type | Angles | Side Ratio | When to Use |
|---|---|---|---|
| 45-45-90 | 45° · 45° · 90° | 1 : 1 : √2 | Diagonals of squares, isosceles right triangles |
| 30-60-90 | 30° · 60° · 90° | 1 : √3 : 2 | Equilateral triangle altitudes, ramp and pitch problems |
| 3-4-5 family | ≈ 36.87° · 53.13° · 90° | 3 : 4 : 5 | Construction squaring, practical field use |
Interpreting Your Results — What the Numbers Mean
Once the calculator gives you a result, knowing how to interpret and apply it correctly is just as important as the calculation itself. Here are the key things to keep in mind when reading the output.
Units Are Preserved
The Pythagorean Theorem is unit-agnostic. If your inputs are in centimeters, the result is in centimeters. If your inputs are in feet, the result is in feet. The formula does not care about units — it only cares about the ratio and relative sizes of the numbers. Never mix units within a single calculation.
When the Result Is Irrational
Many Pythagorean calculations produce irrational numbers — values like √2, √3, or √74 that cannot be expressed as simple fractions. When this happens, the calculator will return a decimal approximation. In academic settings, leaving the answer in exact form (e.g., "√74 cm") is often preferred. In practical settings, rounding to two or three decimal places is appropriate for most measurements.
Rounding and Precision
In construction and engineering, the required precision depends on the context. A rough carpentry task might only need the result rounded to the nearest inch or centimeter. Fine woodworking or CNC machining might require precision to three or four decimal places. Always match your rounding to the precision requirements of your actual project, not just the precision of the calculator output.
Sanity Checks for Your Result
Before accepting any result, apply these quick sanity checks: Is the hypotenuse longer than both individual legs? Is the hypotenuse shorter than the sum of the two legs? Does the result make physical sense in the context of your problem? A ladder cannot be shorter than the wall it leans against; a roof rafter cannot be shorter than either the run or the rise. If the result fails any of these checks, re-examine your input values.
Frequently Asked Questions About the Pythagorean Theorem
Click any question to expand the detailed answer.
What exactly is the Pythagorean Theorem and what does it state?
The Pythagorean Theorem is a mathematical law that applies to all right triangles. It states that the square of the length of the hypotenuse — the side opposite the 90-degree angle — is equal to the sum of the squares of the lengths of the other two sides, called legs. Written as an equation: a² + b² = c². This relationship holds true for every right triangle, regardless of the size of the triangle or the specific angle measures of the acute angles, as long as one angle is exactly 90 degrees.
How do I find the hypotenuse if I know both legs?
To find the hypotenuse, use c = √(a² + b²). Square the first leg, square the second leg, add those two squared values together, and then take the square root of the sum. For example, if leg a = 6 and leg b = 8, then c = √(36 + 64) = √100 = 10. If you enter both legs into the Pythagorean Theorem calculator above and leave the hypotenuse field blank, the tool handles all three steps automatically.
How do I find a missing leg when I know the hypotenuse and one leg?
Rearrange the formula to isolate the missing leg: b = √(c² − a²). Square the hypotenuse, subtract the square of the known leg, and take the square root of the result. For example, if c = 13 and a = 5, then b = √(169 − 25) = √144 = 12. The critical distinction from finding the hypotenuse is the minus sign — when solving for a leg you subtract, and when solving for the hypotenuse you add.
Can the Pythagorean Theorem be used on non-right triangles?
No. The Pythagorean Theorem applies exclusively to right triangles — triangles with exactly one 90-degree angle. For triangles with no right angle (acute triangles where all angles are less than 90°, or obtuse triangles where one angle exceeds 90°), the appropriate tools are the Law of Cosines and the Law of Sines. If you apply the Pythagorean Theorem to a non-right triangle, the result will be incorrect. Always confirm the presence of a right angle before using this formula.
What is a Pythagorean triple and why is it useful?
A Pythagorean triple is a set of three positive whole numbers that satisfy a² + b² = c² exactly. The most common examples are (3, 4, 5), (5, 12, 13), (8, 15, 17), and (7, 24, 25). Multiples of these triples are also valid — for instance, (6, 8, 10) and (9, 12, 15) are both multiples of the (3, 4, 5) triple. Pythagorean triples are useful in construction and surveying because they produce right triangles with side lengths that are whole numbers, making them easy to measure and verify without any approximation or rounding.
What is the hypotenuse of a right triangle?
The hypotenuse is the longest side of a right triangle and is positioned directly opposite the right angle (the 90-degree angle). It is labeled c in the Pythagorean formula a² + b² = c². The hypotenuse is always longer than either of the two legs (the other two sides), but shorter than their sum. If you are unsure which side is the hypotenuse in a triangle, identify the right angle first, and the hypotenuse is the side that does not touch that angle.
Why does the Pythagorean Theorem only work in Euclidean (flat) geometry?
The Pythagorean Theorem is a theorem of Euclidean geometry, which describes the geometry of flat surfaces. On curved surfaces — such as the surface of a sphere — the rules of geometry change. For example, a right triangle drawn on the surface of the Earth does not satisfy a² + b² = c² using spherical distances. Curved-surface geometry (such as spherical trigonometry or hyperbolic geometry) requires different formulas. For all practical purposes on flat surfaces, however — which is the overwhelming majority of everyday and professional calculations — the Pythagorean Theorem applies perfectly.
What is the converse of the Pythagorean Theorem and how is it used?
The converse states: if three side lengths a, b, and c of any triangle satisfy a² + b² = c², then that triangle must contain a right angle. This is used as a test for right angles without measuring any angles directly. In construction, the 3-4-5 method exploits the converse: if you measure 3 units along one wall, 4 units along an adjacent wall, and the diagonal between those two points measures exactly 5 units, the corner must be square. You can also use the converse to classify triangles: if a² + b² > c², the triangle is acute; if a² + b² < c², the triangle is obtuse.
How does the Pythagorean Theorem relate to the distance formula in coordinate geometry?
The distance formula d = √((x₂−x₁)² + (y₂−y₁)²) is a direct application of the Pythagorean Theorem to coordinate geometry. The horizontal difference (x₂−x₁) is one leg, the vertical difference (y₂−y₁) is the other leg, and the straight-line distance d between the two points is the hypotenuse. Every time you use the distance formula on a coordinate grid, you are solving a Pythagorean problem. This connection extends into machine learning, physics simulations, and computer graphics, where Euclidean distance in multiple dimensions is calculated using the same underlying principle.
How do I apply the Pythagorean Theorem in three-dimensional space?
In three dimensions, the theorem extends to d = √(x² + y² + z²), where x, y, and z are the differences in each spatial coordinate between two points, and d is the straight-line (Euclidean) distance between them. For a rectangular box, the interior diagonal equals √(l² + w² + h²) where l, w, and h are the length, width, and height. This formula is derived by applying the standard Pythagorean Theorem twice: first to the base of the box to find the diagonal of the rectangular floor, and then again to that base diagonal and the height to find the full 3D diagonal.
Who discovered the Pythagorean Theorem?
The theorem is named after Pythagoras of Samos (approximately 570–495 BCE), a Greek mathematician and philosopher. However, the underlying relationship between the sides of a right triangle was known to Babylonian, Indian, and Chinese mathematicians centuries before Pythagoras. The Babylonian clay tablet Plimpton 322 (approximately 1800 BCE) contains lists of Pythagorean triples, and ancient Indian texts (the Sulba Sutras) and Chinese texts (the Zhoubi Suanjing) also describe the relationship. The enduring association with Pythagoras reflects the Greek tradition of formal proof and the enormous influence of Euclid's Elements, which spread Greek mathematics throughout the world.
What does the Pythagorean Theorem look like for a 45-45-90 triangle?
A 45-45-90 triangle has two equal legs. If each leg has length 1, the Pythagorean Theorem gives c = √(1² + 1²) = √2. This means the hypotenuse of a 45-45-90 triangle is always √2 times the length of each leg. If the legs are length s, the hypotenuse is s√2. Conversely, if you know the hypotenuse is h, each leg measures h/√2 = h√2/2. This triangle appears whenever you cut a square diagonally, making it extremely common in geometry and construction.
Can a leg value ever equal the hypotenuse?
No. A leg can never equal the hypotenuse in a valid right triangle. If leg a were equal to hypotenuse c, then the formula a² + b² = c² would require b² = 0, meaning b = 0, which is not a triangle but a line segment. The hypotenuse must always be strictly longer than either individual leg. If a calculation returns a result where a claimed leg equals or exceeds the hypotenuse, at least one of the input values is incorrect.
How many proofs of the Pythagorean Theorem exist?
Over 370 distinct proofs of the Pythagorean Theorem are known, making it one of the most proved theorems in all of mathematics. The proofs use a wide range of techniques: geometric area rearrangements, similar triangle arguments, algebraic manipulation, trigonometric derivations, and even calculus-based approaches. Notably, former U.S. President James A. Garfield published an original proof in 1876 using a trapezoid area argument, and Leonardo da Vinci is also credited with at least one geometric proof.
Is the Pythagorean Theorem used in trigonometry?
Yes, deeply. The Pythagorean Theorem is the foundation of the most fundamental identity in trigonometry: sin²(θ) + cos²(θ) = 1. This identity is derived directly from the theorem by placing a right triangle inside a unit circle (a circle with radius 1). The hypotenuse becomes the radius (1), the horizontal leg becomes cos(θ), and the vertical leg becomes sin(θ). Applying the theorem: cos²(θ) + sin²(θ) = 1² = 1. This identity is then used to derive dozens of other trigonometric identities and formulas.
What happens if I calculate a negative number under the square root?
If you are solving for a leg (using b = √(c² − a²)) and the result under the square root is negative, this means the values you entered cannot form a valid right triangle. The most common cause is entering a leg value that is larger than the hypotenuse, which is geometrically impossible. Check your inputs: make sure the value you labeled as the hypotenuse is actually the longest of the three sides, and that the leg you entered is genuinely shorter than the hypotenuse. If both conditions are met and you still get a negative result, one of the input values may contain a typo.
How is the Pythagorean Theorem used in everyday life outside of school?
The theorem appears constantly in everyday and professional life. Builders use it to ensure walls are square and to calculate rafter lengths. TV size is specified as a diagonal measurement calculated using the theorem from screen width and height. GPS navigation systems calculate straight-line distances using coordinate geometry built on the Pythagorean relationship. Satellite technicians use it to aim dishes. Carpenters use it to cut diagonal bracing. Landscapers use it to run irrigation lines across irregular plots. Video game developers use it to detect object collisions in real-time. Virtually anyone working with physical space at some point relies on this fundamental geometric relationship.
Summary: Everything You Need to Know About the Pythagorean Theorem
The Pythagorean Theorem — a² + b² = c² — is one of the oldest, most verified, and most practically useful formulas in all of mathematics. It applies to every right triangle in flat (Euclidean) geometry, allowing you to find any missing side when the other two are known. Its three rearrangements cover every possible missing-side scenario: solve for the hypotenuse by adding the squared legs and taking the root; solve for a leg by subtracting the squared known leg from the squared hypotenuse and taking the root.
Beyond basic triangle calculation, the theorem is the foundation of the coordinate distance formula, the trigonometric Pythagorean identity, Euclidean distance in three and more dimensions, and hundreds of practical applications in construction, engineering, navigation, computer science, and physics. Pythagorean triples provide clean, whole-number solutions useful for field measurement. Special triangles — the 45-45-90 and 30-60-90 — encode the theorem in memorable side ratios. And the converse of the theorem gives you a way to verify right angles through side measurement alone.
Use the free calculator at the top of this page whenever you need a fast, reliable answer. And explore the full collection of free tools at WalDev to find the right calculator for every step of your mathematical or professional workflow.
The Formula
a² + b² = c² — applies to every right triangle in flat geometry.
Pythagorean Triples
3-4-5, 5-12-13, 8-15-17 — whole-number solutions perfect for field use.
Real-World Use
Construction, navigation, GPS, gaming, engineering, and physics all depend on this theorem.
