Full Guide
Triangle Calculator Guide
Enter three sides, two sides with their included angle, one side with two angles, or right-triangle data to solve sides, angles, area, perimeter, heights, medians, and radii.
Full Guide
What This Calculator Does
The Triangle Calculator helps when you know part of a triangle and want the rest filled in without switching between several geometry formulas. Enter three sides (SSS), two sides with their included angle (SAS), one side with two angles (ASA/AAS), or supported right-triangle data. The page detects the entered combination and fills in missing sides and angles when the information is sufficient.
The output is more than one missing value. For a solvable triangle, it also reports area, perimeter, semiperimeter, all three heights, all three medians, inradius, circumradius, angle values in radians, a type label, and a visual triangle diagram. It is useful for geometry homework, dimension checks, layout estimates, and understanding how Heron's formula, the law of sines, and the law of cosines fit together.
If you only need a right-triangle hypotenuse or leg, use the Pythagorean Theorem Calculator. For a general equation or numeric expression, use the Equation Solver or Mathematical Expression Calculator.
When to Use It
- You know three sides and want angles, area, perimeter, and a triangle classification.
- You know two sides and the angle between them and want the third side and remaining angles.
- You know one side and two interior angles and want both missing side lengths.
- You know a right angle and enough side data to check the hypotenuse, angles, area, and radii.
- You want heights, medians, inradius, and circumradius in the same result set.
This is not an SSA ambiguous-case solver, and three angles alone do not determine a triangle's scale. A side is still required to determine absolute lengths.
Inputs Explained
Sides a, b, and c
Side values must be positive; leave unknown sides blank. When all three sides are supplied, the page uses the law of cosines for the interior angles and Heron's formula for the area. The three sides must also satisfy the triangle inequality: every pair must add to more than the remaining side.
There is no unit selector. You may use centimeters, meters, inches, or another consistent unit, but do not mix 3 cm, 4 m, and 5 in in one calculation. Perimeter, semiperimeter, heights, and radii follow the side unit, while area uses square units.
Angles A, B, and C
Enter angles in degrees, not radians. A right angle is 90, and a 30-degree angle is 30. A valid interior angle is greater than 0 and less than 180 degrees. When two angles are entered, their sum must be below 180 degrees and the page fills the third with 180° - A - B; when all three are entered, their sum must be 180 degrees.
The result also reports each angle in radians for comparison with trigonometric formulas. In the inputs, zero means unknown or blank; it is not a valid measured side or interior angle.
How the page detects a case
There is no separate mode selector. The page detects the non-empty fields and tries one of these patterns:
- SSS (three sides): enter a, b, and c;
- SAS (two sides and their included angle): for example a, b, and C;
- ASA/AAS (one side and two angles): enter one side and two interior angles;
- Right triangle: enter a 90-degree angle and enough corresponding side data.
Two sides alone, angles alone, or contradictory values do not produce the supported complete result. Results recalculate as inputs change; after a valid field loses focus, the current values are written to the URL so a copied link can restore them.
How the Calculation Works
The page first resolves the three sides and three angles, then derives the other measurements from the same solved triangle. The main relationships are:
Three sides and Heron's formula
The semiperimeter is:
s = (a + b + c) / 2
The area is calculated with Heron's formula:
Area = √[s(s-a)(s-b)(s-c)]
Two sides and an included angle
For known a, b, and included angle C, the law of cosines gives c:
c = √(a² + b² - 2ab cos C)
The remaining angles and derived values are then calculated. The angle must be between the two known sides; an arbitrary angle with two sides is an SSA situation and may not have a unique answer.
One side and two angles
The missing angle comes from the triangle angle sum, then the law of sines supplies the missing sides:
a / sin A = b / sin B = c / sin C
Derived measurements
If the area is K, the three altitudes are:
ha = 2K/a, hb = 2K/b, hc = 2K/c
One median formula is:
ma = 1/2 × √(2b² + 2c² - a²)
The inradius and circumradius are:
r = K/s
R = abc/(4K)
The page calculates and formats numeric values; it does not expand a full symbolic derivation or preserve exact radicals.
Example
Example 1: sides 3, 4, and 5
Enter a=3, b=4, and c=5. The page recognizes a right triangle:
perimeter = 3 + 4 + 5 = 12
s = 6
area = √(6×3×2×1) = 6
ha = 4, hb = 3, hc = 2.4
inradius r = 1
circumradius R = 2.5
The angles are about A=36.8699°, B=53.1301°, and C=90°, with the matching radian values shown as well.
Example 2: SAS
Enter a=7, b=10, and included angle C=30°. The law of cosines gives:
c ≈ 5.26844
A ≈ 41.63121°
B ≈ 108.36879°
The page then uses the completed sides to calculate area, perimeter, heights, medians, and both circle radii.
Example 3: one side and two angles
Enter a=5, A=40°, and B=60°. The missing angle is C=80°; the law of sines then gives b≈6.73648 and c≈7.66044. This also shows why two angles alone are not enough: at least one side is needed to set the scale.
How to Understand the Result
Sides and angles
Check the solved sides and angles against your worksheet or drawing first. The angles should add to approximately 180 degrees, and the largest side should face the largest angle. If those relationships fail, revisit the input mapping before reading the area or radii.
Area, perimeter, and semiperimeter
Perimeter is the sum of the three sides, and semiperimeter is half of that value. Area uses the square of the side unit; do not interpret the area number as a length.
Heights and medians
An altitude is the perpendicular distance from a vertex to the opposite side or its extension. A median joins a vertex to the midpoint of the opposite side. The page reports all three of each.
Inradius and circumradius
The incircle touches all three sides, with radius r=K/s. The circumcircle passes through all three vertices, with radius R=abc/(4K). Both values use the same length unit as the sides.
Triangle type and diagram
The page can label an equilateral, isosceles, right, acute, or obtuse triangle and draws a diagram scaled from the solved sides. The diagram is for visual understanding, not a dimensionally certified engineering drawing.
Common Mistakes
- Entering only two sides and expecting the page to guess a unique triangle.
- Treating two sides plus a non-included angle as SAS; this is an SSA case that can have multiple solutions, which the current page does not display.
- Entering radians or an exterior/supplementary angle instead of an interior degree value.
- Mixing centimeters, meters, inches, or other length units.
- Ignoring the triangle inequality for three side inputs.
- Entering three angles without a side, so the scale remains unknown.
- Treating the visual diagram as a scale drawing for formal construction.
FAQ
Why do three angles produce no result?
Three angles determine a shape up to scale, not the absolute side lengths. The page needs at least one side and enough total information to match SSS, SAS, ASA/AAS, or a supported right-triangle case.
What is the difference between SAS and SSA?
SAS gives two sides and the angle between them and normally determines one triangle. SSA gives two sides and a non-included angle and can produce zero, one, or two solutions. This page implements SAS-style combinations and does not present SSA alternatives.
Why is the area not labeled with a unit?
The page cannot know whether your side numbers are meters, centimeters, or inches, so it does not invent a unit. Interpret the result using the square of your side unit.
Why do values have decimals or add to slightly more or less than 180 degrees?
Trigonometric functions and Heron's formula use JavaScript floating-point arithmetic, and the UI formats results to about five decimal places. Boundary triangles can show small rounding differences and deserve an extra check.
Can I use this for construction or safety sign-off?
It is suitable for learning, planning, and preliminary dimension checks. For tolerances, safety, load-bearing work, or contractual drawings, use professional measurement and review rather than relying on a web result alone.
Notes
- The page accepts numeric side and angle values; it does not parse units in text, coordinates, area-back-solving, base-height mode, or symbolic expressions.
- The supported patterns are SSS, SAS, ASA/AAS, and selected right-triangle combinations. It does not promise a solution for every three-field selection or display SSA multiple solutions.
- Results use floating-point arithmetic and usually show about five decimal places; nearly degenerate triangles, very large values, or tiny angles can be more sensitive to rounding.
- Valid values are written to URL parameters after the field loses focus. This restores the current inputs but is not a history list or cloud storage.
- Use the results and diagram for quick learning, estimates, and checks, not as a replacement for formal proof, surveying, or engineering review.
Frequently Asked Questions
What is the minimum input?
You need at least three valid numeric values and at least one side; the page supports three sides, two sides with their included angle, one side with two angles, and supported right-triangle combinations.
Can I enter any two sides and one angle?
No. The current page treats two sides plus their included angle as SAS and is not an SSA ambiguous-case solver.
Should angles be entered in degrees or radians?
Enter angles in degrees, such as 30, 45, or 90; the result also reports the corresponding radian values.
Why do three sides fail validation?
All sides must be positive and the sum of any two sides must be greater than the third; equality describes a degenerate line, not a valid triangle.
What units are used for area and radii?
The page has no unit selector. Perimeter, heights, and radii follow the side unit, while area uses the squared side unit.