Triangle Calculator: Free Sides, Angles and Area Tool
Solve any triangle by entering three known sides or angles to find the remaining values, plus area and perimeter, with clear step-by-step results.
Enter Known Values
Enter any three values (at least one side).
Sides
Angles
About this calculator
Triangle Calculator
Comprehensive Guide
The triangle is the foundational polygonal polygon of Euclidean geometry and the fundamental structural building block of planar engineering, geodesy, computer graphics rendering, and navigation. In Euclidean space, any polygon with $n$ vertices can be decomposed through triangulation into exactly $n - 2$ non-overlapping triangles. Because a triangle is the only geometric polygon whose shape is completely rigid and unyielding when its side lengths are fixed (a principle known in structural engineering as triangular rigidity), triangles form the essential lattice of bridges, construction cranes, geodesic domes, and architectural trusses.
Solving a triangle means determining all six fundamental geometric elements—three side lengths ($a, b, c$) and three interior angles ($A, B, C$)—from a minimum subset of three known parameters, of which at least one must be a side length. Triangle solving problems are universally classified into five classic geometric cases:
- SSS (Side-Side-Side): All three side lengths are known. Solved uniquely via the Law of Cosines, provided the Triangle Inequality Theorem is satisfied ($a + b > c$).
- SAS (Side-Angle-Side): Two sides and their included interior angle are known. Solved uniquely by using the Law of Cosines to find the third side, followed by the Law of Sines for remaining angles.
- ASA (Angle-Side-Angle): Two angles and the included side are known. Solved uniquely using the angle sum theorem ($A + B + C = 180^\circ$) followed by the Law of Sines.
- AAS (Angle-Angle-Side): Two angles and a non-included side are known. Solved uniquely like ASA via the Law of Sines.
- SSA (Side-Side-Angle): Two sides and a non-included angle are known. Known historically as the Ambiguous Case, this scenario can yield zero, exactly one, or two distinct valid triangles depending on the altitude $h = b \sin(A)$.
Beyond side lengths and angles, complete triangle analysis calculates the perimeter, semi-perimeter ($s$), surface area (via base-height, trigonometric SAS, or Heron's formula), inradius ($r$, radius of the inscribed circle), circumradius ($R$, radius of the circumscribed circle), medians, and coordinates of the four classical triangle centers (centroid, incenter, circumcenter, and orthocenter).
This calculator solves right, acute, and obtuse triangles across all five input configurations with complete step-by-step mathematical proofs.
How to Use the Triangle Calculator
- Select Input Configuration Mode: Choose the combination of known parameters:
- SSS: Enter side lengths $a, b, c$.
- SAS: Enter two sides and the included angle (e.g., sides $a, b$ and angle $C$).
- ASA / AAS: Enter two interior angles and any side length.
- SSA (Ambiguous Case): Enter two sides and a non-included angle (e.g., sides $a, b$ and angle $A$).
- Right Triangle: Enter any two parameters (hypotenuse and leg, or leg and acute angle).
- Set Angular Units: Select Degrees (°) (standard in civil surveying, aviation, and navigation) or Radians (rad) (standard in physics and calculus).
- Enter Numerical Values: Input your measurements into the corresponding fields.
- Evaluate Results: Click Calculate. The tool validates the Triangle Inequality Theorem, checks for SSA ambiguity, and generates:
- All three side lengths ($a, b, c$) and interior angles ($A, B, C$)
- Total Perimeter ($P$) and Semi-perimeter ($s$)
- Exact Area ($Area$) computed via multiple analytical methods
- Inradius ($r$) and Circumradius ($R$)
- Triangle classification (Equilateral, Isosceles, Scalene; Acute, Right, Obtuse).
The Calculator Formulas
The analytical engine leverages the core trigonometric and algebraic laws of Euclidean geometry:
Interior Angle Sum Theorem:
A + B + C = 180° = pi radians
Triangle Inequality Theorem (Existence Condition):
a + b > c AND a + c > b AND b + c > a
Pythagorean Theorem (Right Triangles, C = 90°):
c^2 = a^2 + b^2
c = sqrt(a^2 + b^2)
Law of Cosines (Solving SSS and SAS):
c^2 = a^2 + b^2 - 2 * a * b * cos(C)
cos(C) = (a^2 + b^2 - c^2) / (2 * a * b)
cos(A) = (b^2 + c^2 - a^2) / (2 * b * c)
cos(B) = (a^2 + c^2 - b^2) / (2 * a * c)
Law of Sines (Solving ASA, AAS, and SSA):
a / sin(A) = b / sin(B) = c / sin(C) = 2 * R
where R is the circumradius
Area Formulas:
Standard Base-Height:
Area = (1 / 2) * b * h
Trigonometric SAS Area:
Area = (1 / 2) * a * b * sin(C) = (1 / 2) * b * c * sin(A) = (1 / 2) * a * c * sin(B)
Heron's Formula (SSS Area):
Semi-perimeter: s = (a + b + c) / 2
Area = sqrt( s * (s - a) * (s - b) * (s - c) )
Inradius (r) and Circumradius (R):
Inradius: r = Area / s
Circumradius: R = (a * b * c) / (4 * Area)
Practical Examples
Example 1: Solving an SSS Boundary Parcel via Law of Cosines
Problem Statement: A land surveyor measures the three boundary fences of a triangular property parcel: $a = 120.0\text{ m}$, $b = 150.0\text{ m}$, and $c = 90.0\text{ m}$. Calculate all three interior angles, the land area, and the inradius.
Step-by-Step Evaluation:
- Check Triangle Inequality:
- $120 + 90 = 210 > 150$ (Valid)
- Compute angle $C$ opposite side $c$ using Law of Cosines:
cos(C) = (a^2 + b^2 - c^2) / (2 * a * b) cos(C) = (120^2 + 150^2 - 90^2) / (2 * 120 * 150) cos(C) = (14400 + 22500 - 8100) / 36000 = 28800 / 36000 = 0.8000 C = arccos(0.8000) ≈ 36.870° - Compute angle $A$ opposite side $a$:
cos(A) = (b^2 + c^2 - a^2) / (2 * b * c) cos(A) = (150^2 + 90^2 - 120^2) / (2 * 150 * 90) cos(A) = (22500 + 8100 - 14400) / 27000 = 16200 / 27000 = 0.6000 A = arccos(0.6000) ≈ 53.130° - Compute angle $B$:
(Note: $90^2 + 120^2 = 8100 + 14400 = 22500 = 150^2$, confirming a right triangle).B = 180° - (A + C) = 180° - (53.130° + 36.870°) = 90.000° - Compute land area:
Area = (1 / 2) * a * c = (1 / 2) * 120.0 * 90.0 = 5400.0 m^2 - Compute semi-perimeter and inradius:
s = (120 + 150 + 90) / 2 = 180.0 m r = Area / s = 5400.0 / 180.0 = 30.0 m
Example 2: Civil Engineering Roof Truss (ASA Case)
Problem Statement: A roof truss has a horizontal base beam $c = 10.0\text{ m}$. The two roof pitch angles at the base are $A = 35.0^\circ$ and $B = 45.0^\circ$. Determine the lengths of rafters $a$ and $b$, and the roof peak height.
Step-by-Step Evaluation:
- Compute the apex angle $C$:
C = 180° - (35.0° + 45.0°) = 180° - 80.0° = 100.0° - Compute rafter $a$ via Law of Sines:
a / sin(A) = c / sin(C) a = c * (sin(35.0°) / sin(100.0°)) = 10.0 * (0.573576 / 0.984808) ≈ 5.824 m - Compute rafter $b$ via Law of Sines:
b = c * (sin(45.0°) / sin(100.0°)) = 10.0 * (0.707107 / 0.984808) ≈ 7.180 m - Compute the vertical peak height $h$:
h = b * sin(A) = 7.180 * sin(35.0°) ≈ 7.180 * 0.573576 ≈ 4.118 m
Key Concepts & Essential Terminology
Rigorous geometric problem solving requires understanding triangle classification taxonomies, solvability conditions, and the geometry of classical centers.
Triangle Solvability & Congruence Reference Matrix
The following matrix categorizes all input configurations, governing laws, and unique solvability constraints:
| Input Case | Known Parameters | Primary Trigonometric Law | Number of Valid Solutions | Critical Solvability Constraint |
|---|---|---|---|---|
| SSS | 3 Side lengths ($a, b, c$) | Law of Cosines | 1 Unique Solution | Triangle Inequality: $a + b > c$ |
| SAS | 2 Sides, Included Angle ($a, b, C$) | Law of Cosines | 1 Unique Solution | Angle must satisfy $0^\circ < C < 180^\circ$ |
| ASA | 2 Angles, Included Side ($A, B, c$) | Law of Sines | 1 Unique Solution | Angles must sum to $< 180^\circ$ ($A + B < 180^\circ$) |
| AAS | 2 Angles, Non-Included Side ($A, B, a$) | Law of Sines | 1 Unique Solution | Angles must sum to $< 180^\circ$ |
| SSA (Case 1) | 2 Sides, Non-Included Angle ($a < h$) | Law of Sines | 0 Solutions (Impossible) | Side $a$ cannot reach base ($a < b\sin(A)$) |
| SSA (Case 2) | 2 Sides, Non-Included Angle ($a = h$) | Law of Sines | 1 Unique Right Triangle | Side $a$ exactly equals altitude ($a = b\sin(A)$) |
| SSA (Case 3) | 2 Sides, Non-Included Angle ($h < a < b$) | Law of Sines | 2 Distinct Triangles | Ambiguous case: one acute, one obtuse |
| SSA (Case 4) | 2 Sides, Non-Included Angle ($a \ge b$) | Law of Sines | 1 Unique Solution | Obtuse branch lies outside geometric bounds |
| AAA | 3 Angles ($A, B, C$) | Cannot Solve | Infinitely Many | Fixes shape (similarity), not absolute size |
Figure: Anatomical decomposition of an oblique triangle detailing the Law of Sines, Law of Cosines, altitude, and Heron's area formula.
The Classical Triangle Centers & Euler Line Properties
Every triangle possesses four remarkable classical centers that encapsulate distinct physical and geometric optimization equilibria:
| Triangle Center | Defining Intersection of Lines | Coordinates Formula (Barycentric) | Center Characteristic & Optimization Property | Physical / Engineering Application |
|---|---|---|---|---|
| Centroid ($G$) | Intersection of 3 Medians | $(1/3, 1/3, 1/3)$ | Center of mass / gravity of uniform plate | Structural balance, aeronautical center of lift |
| Incenter ($I$) | Intersection of 3 Angle Bisectors | $(a : b : c)$ | Center of inscribed circle tangent to all 3 sides | Internal clearance routing, machine tool radius |
| Circumcenter ($O$) | Intersection of Perpendicular Bisectors | $(sin(2A) : sin(2B) : sin(2C))$ | Center of circumscribed circle passing through vertices | Cell tower / hospital equidistant tri-coverage |
| Orthocenter ($H$) | Intersection of 3 Altitudes | $( an(A) : an(B) : an(C))$ | Altitude intersection point (inside if acute, outside if obtuse) | Reflection acoustic focusing in concert halls |
Empirical Statistics & Geometric Benchmarks
- The Euler Line Theorem: In any non-equilateral triangle, the Centroid ($G$), Circumcenter ($O$), and Orthocenter ($H$) are collinear, lying on a single line where the centroid divides the distance between $H$ and $O$ in an exact $2:1$ ratio ($HG = 2 \cdot GO$).
- Fermat-Torricelli Point: The unique point within a triangle whose sum of distances to all three vertices is minimized. If all angles are $< 120^\circ$, lines connecting the Fermat point to each vertex meet at exact $120^\circ$ angles—a principle utilized in optical fiber network path minimization.
How Triangle Solving Works
The underlying mechanics of triangle calculation rely on coordinate geometry and vector cross products.
When solving an SSS triangle, the algorithm sets side $c$ along the $x$-axis from origin $(0, 0)$ to $(c, 0)$. Vertex $C$ is placed at coordinates $(x, y)$. Using the Law of Cosines, the coordinates of $C$ are evaluated as:
x = b * cos(A) = (b^2 + c^2 - a^2) / (2 * c)
y = b * sin(A) = sqrt(b^2 - x^2) = (2 * Area) / c
In the ambiguous SSA case where angle $A$ and sides $a$ and $b$ are given, the algorithm evaluates the altitude $h = b \sin(A)$. If $a < h$, the side is too short to close the polygon, producing a domain error $\sin(B) > 1$. If $a = h$, $\sin(B) = 1$ yielding $B = 90^\circ$. If $h < a < b$, $\sin(B) = (b \sin(A)) / a < 1$ produces two valid supplementary angles: $B_1 = \arcsin(\dots)$ and $B_2 = 180^\circ - B_1$. The calculator branches into two parallel solution states, outputting both acute and obtuse triangle profiles.
For area evaluation, Heron's formula is computed using numerical stabilization. In standard floating-point arithmetic, evaluating $\sqrt{s(s-a)(s-b)(s-c)}$ for needle-like triangles (where $a + b \approx c$) suffers catastrophic cancellation. Stabilized implementations sort sides such that $a \ge b \ge c$ and evaluate:
Area = (1 / 4) * sqrt( (a + (b + c)) * (c - (a - b)) * (c + (a - b)) * (a + (b - c)) )
Common Triangle Calculator Mistakes to Avoid
- Violating the Triangle Inequality Theorem: Entering side lengths such as $5, 10, 20$ will fail because $5 + 10 = 15 < 20$. In Euclidean space, the sum of any two sides must strictly exceed the third side length.
- Ignoring the Ambiguous SSA Second Triangle: When given two sides and a non-included acute angle where $a < b$, there are almost always two valid geometric solutions (one where angle $B$ is acute, and one where $B$ is obtuse). Failing to check for the second solution can cause catastrophic structural misalignment in framing.
- Using Right Triangle Formulas on Oblique Triangles: Applying basic mnemonic ratios like $\sin(\theta) = \text{opposite} / \text{hypotenuse}$ or the Pythagorean theorem ($a^2 + b^2 = c^2$) to non-right triangles produces invalid results. You must use the Law of Sines and Law of Cosines for oblique triangles.
- Angular Mode Discrepancies (Degrees vs. Radians): Entering an angle of $45$ while the engine is set to Radians evaluates an angle of $45\text{ radians} \approx 2,578^\circ$, producing immediate calculation failure. Verify your angular unit mode.
- Attempting to Solve with Three Angles (AAA): Providing three angles ($A, B, C$) confirms triangle shape and similarity, but establishes zero scale. An infinite family of similar triangles share identical angles. At least one linear side length is required to solve absolute dimensions.
Frequently Asked Questions
What is the ambiguous SSA case in trigonometry?
The SSA (Side-Side-Angle) case occurs when you know two sides and an angle that is NOT between them. If the given angle is acute and the opposite side is shorter than the adjacent side but longer than the altitude (h < a < b), two completely different valid triangles can be formed: one acute triangle and one obtuse triangle. A rigorous triangle calculator must identify and solve both configurations.
How does Heron's formula calculate triangle area without knowing height?
Heron's formula calculates the exact area of any triangle using only its three side lengths (a, b, c). It first determines the semi-perimeter s = (a + b + c) / 2, and then evaluates Area = √[s(s - a)(s - b)(s - c)]. This eliminates the need to calculate altitudes or interior angles.
How do I know if three side lengths can form a valid triangle?
Under the Triangle Inequality Theorem, three side lengths can form a valid triangle if and only if the sum of any two sides is strictly greater than the third side: a + b > c, a + c > b, and b + c > a. If the sum of the two shorter sides equals or is less than the longest side, the lines cannot close to form a triangle.
What is the difference between the inradius and the circumradius?
The inradius (r = Area / s) is the radius of the largest circle that fits completely inside the triangle, touching all three sides tangentially. The circumradius (R = abc / (4 × Area)) is the radius of the circle that passes through all three exterior vertices of the triangle.
Can a triangle have more than one right angle or obtuse angle?
No. In Euclidean plane geometry, the sum of all three interior angles in any triangle must equal exactly 180°. If a triangle had two right angles (90° + 90° = 180°), the third angle would have to be 0°, meaning the lines would be parallel and never intersect. Similarly, two obtuse angles (>90°) would exceed 180°.
Why can't I solve a triangle with only three angles (AAA)?
Knowing three angles defines the shape and proportional ratios of the triangle (geometric similarity), but conveys zero information regarding absolute physical scale. A triangle with angles 30°-60°-90° could have sides measuring 1-√3-2 inches or 100-173-200 miles. At least one side length is mandatory to establish absolute scale.
Conclusion
The triangle is the bedrock of spatial mathematics, uniting classical geometry with modern analytical trigonometry. By leveraging the Law of Sines, Law of Cosines, and Heron's formula across the five fundamental solvability configurations, engineers, architects, surveyors, and students can resolve complex geometric structures with speed and fidelity. Mastering triangle properties ensures structural rigidity, navigational accuracy, and mathematical insight across all technical disciplines.
Related Calculators
- Pythagorean Theorem Calculator – Solve right triangle hypotenuses and spatial distances.
- Surface Area Calculator – Calculate 3D surface areas of prisms, pyramids, cones, and spheres.
- Scientific Calculator – Compute advanced trigonometric and inverse circular functions.
- Proportion Calculator – Solve geometric similarity ratios and scale factor equations.
Sources & References
- Euclid. (~300 BCE). Elements (Book I & Book IV). Translated by Sir Thomas L. Heath (1908). Cambridge University Press.
- Heath, T. L. (1921). A History of Greek Mathematics: From Thales to Euclid. Clarendon Press.
- Casey, J. (1888). A Treatise on Spherical Trigonometry, and Its Application to Geodesy and Astronomy. Hodges, Figgis, & Co.
- Weisstein, E. W. (2022). Triangle. From MathWorld—A Wolfram Web Resource.
Technical & General Calculation Disclaimer
This calculation tool applies standard mathematical, scientific, or engineering formulas. While designed for precision, output values are estimates and should be independently verified for commercial, structural, or safety-critical applications.
Comments
Loading comments…
Related Math Calculators
Explore more tools to continue your analysis
Pythagorean Theorem Calculator
Solve for the hypotenuse of a right triangle.
Area Calculator
Calculate area of various 2D shapes.
Slope Calculator
Calculate slope, distance, and angle of a line.
Circle Calculator
Calculate circle area, circumference, radius.
Distance Formula Calculator
Calculate 2D and 3D Euclidean distance.
Surface Area Calculator
Surface area of sphere, cube, cylinder, cone.
Volume Calculator
Calculate the volume of common shapes.
Scientific Calculator
Advanced math operations.