Triangle Solver

Got a photo of your Math homework?

Upload it and let AI solve it instantly.

Upload Image →
Triangle Solver Right · Area · General · Special

Result

Enter any two values. The solver finds the missing side or angle using the Pythagorean theorem.

Quick Examples

3-4-5:
From hyp:
Base & h:
Heron's:
SSS:
SAS:
30-60-90:
45-45-90:

Triangle Solver: Sides, Angles, Area, Perimeter & More

Your complete guide to solving triangle problems, from basic area and the Pythagorean theorem to the Law of Sines, Law of Cosines, Heron's formula, and special right triangles.

How to Use This Triangle Solver

Right Triangle

Enter any two values — two legs, one leg and the hypotenuse, or a leg and an angle. The solver uses the Pythagorean theorem and trigonometry to find the missing pieces.

Example: Enter legs a = 3 and b = 4, get hypotenuse c = 5, angles, area, and perimeter.

Area

Choose your method: base and height (½bh), Heron's formula for three sides, or the SAS formula (½ab sin C). All three methods give the exact same area for the same triangle.

Example: Sides 5, 6, 7 with Heron's formula gives area ≈ 14.70 square units.

General

Solve any triangle using SSS, SAS, ASA, or AAS. The solver picks the Law of Cosines or Law of Sines depending on what you enter. Great for non-right triangle problems on AP and IB exams.

Example: SSS with sides 5, 6, 7 gives all three angles.

Special

Instantly solve 30-60-90, 45-45-90, equilateral, and isosceles triangles. Enter one known value and the solver applies the exact ratio rules to find everything else.

Example: 30-60-90 with short leg = 5 gives long leg = 8.66, hypotenuse = 10.

Triangle Solver by Student Level

Middle School

Topics: Perimeter, basic area formula (½ × base × height), identifying triangle types by sides and angles, and the Pythagorean theorem.

How to use: Start with the Right Triangle tab. Enter the two legs and press Solve to find the hypotenuse. Use the Area tab with the base and height method for area questions.

Tip: The most common middle school mistake is forgetting to divide by 2 in the area formula. This solver shows that step clearly so you understand why it's there.

High School (GCSE / IB / AP)

Topics: Law of Sines, Law of Cosines, Heron's formula, special right triangles, triangle inequality theorem, and classifying triangles by angle type.

How to use: Use the General tab for SSS, SAS, ASA, and AAS problems. Use the Special tab to drill 30-60-90 and 45-45-90 ratios before an exam. Work the problem on paper first, then verify step by step here.

Tip: For GCSE and IB, write down the law name (Law of Cosines, Law of Sines) in your solution. The output labels make this easy to copy into your written work.

College Level

Topics: Oblique triangles, exact trigonometric values, vectors and triangle decomposition, polar coordinates, and triangle area in calculus contexts.

How to use: Use the General tab for full oblique triangle solutions. Use Heron's formula to quickly find area when checking integration results for triangular regions.

Tip: For vectors, a triangle with two sides as vectors uses the SAS area formula. Enter the magnitudes and the angle between them in the Area tab under the SAS method.

Using This Tool for Triangle Assignments

Homework Problems

Solve each problem by hand first, then enter your values here to verify. If your answer differs, compare your working to the solver output step by step. The most common homework errors are using the wrong formula for the given information, applying the Law of Sines where the Law of Cosines is needed, and forgetting to take the square root in the Pythagorean theorem.

Case Studies and Projects

Applied projects often use triangles in real measurements, like finding the distance across a river using two measured angles, calculating the height of a building with a surveying triangle, or analyzing a roof truss. Enter the real measurements from your project and use the step-by-step output to write up your solution with full working.

Quiz and Exam Prep

Click Random to load a random example. Solve it on paper in under 90 seconds, then check your answer here. Repeat ten times before a test. Focus especially on the General tab since SSS and SAS problems with the Law of Cosines are among the most commonly tested triangle topics at GCSE and SAT level.

Problem Sets

For multi-part problem sets, use the General tab to find all sides and angles first, then switch to the Area tab to compute area with the values you now know. Keeping consistent side labels (a opposite A, b opposite B, c opposite C) across parts of a problem avoids carry-through errors.

What Is a Triangle?

What is a triangle in math?

A triangle is a polygon with three sides and three angles. The three angles always add up to exactly 180 degrees. Every triangle has three vertices (corners), three sides (edges), and three interior angles. Triangles appear in geometry, trigonometry, physics, architecture, and engineering.

How do you classify triangles by sides?

Equilateral triangles have all three sides equal and all three angles equal to 60 degrees. Isosceles triangles have exactly two sides equal and two base angles equal. Scalene triangles have no sides equal and no angles equal. Use the Special tab and select Classify to identify any triangle by entering its three sides.

How do you classify triangles by angles?

Acute triangles have all three angles less than 90 degrees. Right triangles have exactly one 90-degree angle. Obtuse triangles have one angle greater than 90 degrees. A quick check: if a² + b² equals c², it is right. If a² + b² is greater than c², it is acute. If a² + b² is less than c², it is obtuse.

What is the triangle inequality theorem?

The triangle inequality theorem states that the sum of any two sides must be greater than the third side. If sides are 3, 4, and 8, no triangle exists because 3 + 4 = 7, which is less than 8. This solver checks the triangle inequality before calculating and warns you if the values you entered cannot form a real triangle.

Right Triangle Calculator

What is the Pythagorean theorem?

The Pythagorean theorem states that in a right triangle, the square of the hypotenuse (the side opposite the 90-degree angle) equals the sum of the squares of the two legs: a² + b² = c². For legs 3 and 4, the hypotenuse is √(9 + 16) = √25 = 5. This is the most fundamental formula in triangle geometry.

How do I find a missing leg of a right triangle?

Rearrange the Pythagorean theorem: if you know the hypotenuse c and one leg a, the other leg is b = √(c² − a²). For c = 13 and a = 5, b = √(169 − 25) = √144 = 12. Use the Right Triangle tab, select "Leg a and hypotenuse c," enter the values, and press Solve.

How do I use trigonometry in a right triangle?

For a right triangle with hypotenuse c and angle A: the opposite leg is a = c × sin(A), the adjacent leg is b = c × cos(A), and tan(A) = a/b. If you know one leg and one angle, the Right Triangle tab mode "Leg a and angle A" finds everything else using these trig ratios directly.

Real-world example: right triangle

A ladder of length 10 m leans against a wall at a 60-degree angle from the ground. How high up the wall does it reach? The wall height is the side opposite 60 degrees: h = 10 × sin(60°) = 10 × 0.866 = 8.66 m. Enter c = 10 and angle A = 60 in the Right Triangle tab to verify with full working.

Triangle Area Calculator

What is the basic area formula for a triangle?

The area of a triangle is A = ½ × base × height. The height must be perpendicular to the chosen base. For a triangle with base 10 and height 6, area = ½ × 10 × 6 = 30 square units. Use the Area tab with the "Base and Height" method for the quickest calculation.

What is Heron's Formula and how do I use it?

Heron's Formula finds the area when you know all three side lengths. First calculate the semi-perimeter: s = (a + b + c) / 2. Then area = √(s(s−a)(s−b)(s−c)). For sides 5, 6, 7: s = 9, area = √(9 × 4 × 3 × 2) = √216 ≈ 14.70. Enter the three sides in the Area tab under Heron's Formula to see every step.

How do I find the area with two sides and an angle?

If you know two sides a and b and the included angle C, use area = ½ × a × b × sin(C). For a = 6, b = 8, and C = 30°, area = ½ × 6 × 8 × sin(30°) = ½ × 6 × 8 × 0.5 = 12 square units. Select the SAS method in the Area tab to calculate this instantly.

Real-world example: triangle area

A triangular plot of land has sides measuring 40 m, 50 m, and 60 m. What is its area? Using Heron's formula: s = 75, area = √(75 × 35 × 25 × 15) = √984375 ≈ 992.16 m². Enter these three sides in the Heron's method to verify in one click.

General Triangle Solver (Law of Sines & Cosines)

What is the Law of Cosines?

The Law of Cosines is c² = a² + b² − 2ab × cos(C). It generalizes the Pythagorean theorem to any triangle. Use it when you have SSS (all three sides, to find angles) or SAS (two sides and the included angle, to find the third side). For a = 5, b = 7, C = 60°: c² = 25 + 49 − 70 × 0.5 = 39, so c ≈ 6.24.

What is the Law of Sines?

The Law of Sines states that a / sin(A) = b / sin(B) = c / sin(C). Use it when you have ASA (two angles and the included side) or AAS (two angles and a non-included side). Once two angles are known, the third is simply 180° minus the sum of the other two. The solver handles all four cases and shows which formula applies.

How do I solve a triangle with SSS?

With three known sides, use the Law of Cosines to find each angle. Start with the largest side to find the largest angle: cos(C) = (a² + b² − c²) / (2ab). Then use the Law of Sines to find a second angle, and subtract both from 180° to get the third. Enter all three sides in the General tab under SSS to see each step.

How do I solve a triangle with SAS?

With two sides and the included angle, use the Law of Cosines to find the third side, then the Law of Sines to find a second angle, then subtract to get the third. For a = 8, b = 6, C = 45°: c² = 64 + 36 − 96 × cos(45°) = 100 − 67.88 = 32.12, so c ≈ 5.67. Enter this in the General tab under SAS to get the full solution.

Special Right Triangles Calculator

How do you solve a 30-60-90 triangle?

In a 30-60-90 triangle, the sides follow the ratio 1 : √3 : 2. If the short leg (opposite 30°) is x, the long leg (opposite 60°) is x√3 and the hypotenuse is 2x. For short leg = 5: long leg = 5√3 ≈ 8.66, hypotenuse = 10. Enter 5 in the Special tab under 30-60-90 to see the full calculation with exact and decimal values.

How do you solve a 45-45-90 triangle?

In a 45-45-90 triangle, both legs are equal. If each leg is x, the hypotenuse is x√2. For legs = 6: hypotenuse = 6√2 ≈ 8.49. The area is ½ × 6 × 6 = 18 square units. These triangles appear constantly in geometry, trigonometry, and standardized tests. Use the Special tab with 45-45-90 selected to solve them in one click.

How do you solve an equilateral triangle?

An equilateral triangle has all three sides equal (let each side = a) and all three angles equal to 60 degrees. The height is h = (a√3) / 2. The area is A = (a²√3) / 4. For a = 6: height = 5.196, area = 15.59 square units. Enter the side length in the Special tab under Equilateral to get all measurements instantly.

How do you solve an isosceles triangle?

An isosceles triangle has two equal sides (let each equal leg = a) and a base (b). The height from the apex to the base bisects it: h = √(a² − (b/2)²). The two base angles are equal, and the apex angle = 180° minus twice the base angle. Enter the equal leg and base in the Special tab under Isosceles.

What are Pythagorean triples?

Pythagorean triples are sets of three whole numbers that satisfy a² + b² = c². The most famous is 3, 4, 5. Other common triples are 5, 12, 13; 8, 15, 17; and 7, 24, 25. Any multiple of a triple is also a triple, so 6, 8, 10 and 9, 12, 15 work too. Recognizing these on an exam saves a lot of calculation time.

Real World Uses of Triangle Calculations

Where are triangles used in real life?

Triangles are the most structurally stable shape, so they appear everywhere in engineering and construction. Bridge trusses, roof frames, and crane supports all use triangular frames. Architects use the Pythagorean theorem to check that walls meet at right angles. Surveyors use the Law of Sines and Cosines to measure distances that cannot be measured directly.

How do pilots and sailors use triangle calculations?

Navigation uses triangulation to find a position from known reference points. A ship traveling at a known speed and direction forms a velocity triangle that can be solved with the Law of Cosines. Aircraft use the same method to correct for crosswind, treating the wind speed, aircraft speed, and ground speed as the three sides of a triangle.

How are triangles used in physics?

Vector problems in physics are fundamentally triangle problems. Adding two forces with different directions creates a triangle where the resultant is the third side, solvable with the Law of Cosines. Inclined plane problems decompose gravity into components along a triangle's legs. Projectile motion uses right triangle trigonometry to find horizontal and vertical components.

Frequently Asked Questions

1. How do you find a missing side of a triangle?
It depends on what you know. For a right triangle with two sides, use a² + b² = c². For any triangle with two sides and the included angle (SAS), use the Law of Cosines: c² = a² + b² − 2ab × cos(C). For two angles and a side (AAS or ASA), use the Law of Sines: a/sin(A) = b/sin(B). The General tab in this triangle solver automatically picks the right formula.
2. How do you calculate the area of a triangle without the height?
Use Heron's Formula. If you know all three sides a, b, c, first find the semi-perimeter s = (a + b + c) / 2. Then area = √(s(s−a)(s−b)(s−c)). No height is needed. Alternatively, if you know two sides and the included angle, use area = ½ × a × b × sin(C). The Area tab covers both methods with full step-by-step output.
3. How do I solve a right triangle step by step?
Step 1: Identify what you know (two sides, or one side and one angle). Step 2: If you know both legs, apply c = √(a² + b²) for the hypotenuse. Step 3: Find angle A using tan(A) = a/b, then angle B = 90° − A. Step 4: Calculate area = ½ × a × b and perimeter = a + b + c. Enter your known values in the Right Triangle tab to see each step calculated automatically.
4. What is the difference between Law of Sines and Law of Cosines?
The Law of Sines (a/sin A = b/sin B = c/sin C) is used when you have two angles and any side (ASA or AAS), or two sides and a non-included angle (SSA). The Law of Cosines (c² = a² + b² − 2ab cos C) is used when you have three sides (SSS) or two sides and the included angle (SAS). Both laws handle any triangle, not just right triangles.
5. How do you solve a 30-60-90 triangle?
The sides of a 30-60-90 triangle always follow the ratio x : x√3 : 2x, where x is the shortest leg (opposite 30°). Multiply x by √3 (approximately 1.732) to get the long leg, and multiply x by 2 to get the hypotenuse. If you are given the hypotenuse instead, divide by 2 to get x first. Enter any starting value in the Special tab under 30-60-90 and this triangle solver calculates everything instantly.
6. What is Heron's Formula and when do I use it?
Heron's Formula calculates the area of any triangle when you only know the three side lengths, with no height needed. Find the semi-perimeter s = (a + b + c) / 2, then area = √(s(s−a)(s−b)(s−c)). Use it for SSS problems where the height is not given. For example, a triangle with sides 7, 8, 9 has s = 12, and area = √(12 × 5 × 4 × 3) = √720 ≈ 26.83 square units.
7. How do I find all angles of a triangle if I know all three sides?
Use the Law of Cosines three times. For angle C: cos(C) = (a² + b² − c²) / (2ab), then C = arccos of that value. Repeat for angle A and angle B. As a shortcut, once you have two angles, the third is simply 180° minus the other two. Enter the three sides in the General tab under SSS to get all three angles with working shown.
8. What is the triangle inequality theorem?
The triangle inequality theorem states that the sum of any two sides of a triangle must be strictly greater than the third side. This applies to all three combinations: a + b > c, a + c > b, and b + c > a. If any of these conditions fails, the given lengths cannot form a triangle. For example, sides 2, 3, 6 fail because 2 + 3 = 5 which is less than 6. This solver checks the inequality automatically before calculating.
9. Is this triangle solver useful for GCSE and IB exams?
Yes. This tool covers every triangle formula and method tested in GCSE Maths (Foundation and Higher), IB SL and HL, and AP Precalculus. The General tab handles all four triangle cases (SSS, SAS, ASA, AAS). The Special tab drills the 30-60-90 and 45-45-90 ratios that appear on nearly every standardized test. Use Random to generate practice problems and solve them before checking here.
10. How do I find the perimeter and height of a triangle?
The perimeter is simply a + b + c. The height (altitude) relative to a specific base depends on which base you choose. For base b, height h = 2 × Area / b. Once you have the area from any method (Heron's, base-height, or SAS), divide twice the area by the base of your choice to get the corresponding altitude. Every solver tab in this tool shows perimeter and height alongside area in its output.