Triangle Calculator
Solve any triangle using SSS, SAS, or ASA input modes. Computes all sides, angles, area, and perimeter with dynamic SVG visualization.
Triangle Solver
Results update instantly as you type
Enter Values
Embed Code
Copy and paste this HTML snippet into any web page to embed this calculator directly.
<iframe src="http://127.0.0.1:54963/embed/math/triangle-calculator?ref=embed" title="Triangle Calculator" width="100%" style="max-width:600px; border:none; height:500px;" loading="lazy"></iframe>
Direct Link
Share this link to let others open the calculator in their browser.
The Formula
The law of cosines relates the sides of a triangle to the cosine of one angle: a² = b² + c² − 2bc·cos(A). It is a generalization of the Pythagorean theorem that works for any triangle, not just right triangles. The law of sines relates side lengths to the sines of their opposite angles: a/sin(A) = b/sin(B) = c/sin(C). Together, these two laws provide everything needed to solve any triangle when given three independent measurements (SSS, SAS, or ASA). The third angle is always found by subtracting the other two from 180° since all interior angles of any triangle sum to 180°.
Variable Definitions
Side Lengths
The three sides of the triangle. Side a is opposite angle A, side b is opposite angle B, and side c is opposite angle C.
Interior Angles
The three interior angles of the triangle, always summing to exactly 180° in Euclidean geometry.
Area
Computed via Heron's formula: √(s(s−a)(s−b)(s−c)) where s = (a+b+c)/2 is the semi-perimeter.
How to Use This Calculator
- 1
Select the input mode that matches the information you have: SSS (three side lengths), SAS (two sides plus the angle between them), or ASA (two angles plus the side between them).
- 2
Enter the known measurements in the labeled fields.
- 3
The calculator computes all missing sides, angles, area, and perimeter automatically.
- 4
The SVG visualization draws the triangle to scale with labeled sides, angles, and dimensions.
Triangle with labeled vertices, sides, angles, and height for area calculation
Understanding the Concept
Triangles are the building blocks of geometry. Any polygon can be decomposed into triangles, making triangle-solving a fundamental skill in geometry, surveying, engineering, and computer graphics. Given any three independent measurements (but not only three angles), the triangle is uniquely determined up to congruence — this is the SSS, SAS, ASA, and AAS congruence rules taught in geometry. The law of cosines is a generalization of the Pythagorean theorem: when angle C = 90°, c² = a² + b² − 2ab·cos(90°) = a² + b² (the familiar Pythagorean theorem). For SSS input, the law of cosines finds the first angle, then the law of sines finds the second, and the third is 180° minus the other two. For ASA, the third angle is found first (180° minus the two known angles), then the law of sines finds the unknown sides. This systematic approach ensures accuracy across all input modes.
Frequently Asked Questions
Sources & References
Related Calculators
Reviews
No reviews yet. Be the first to share your experience with Triangle Calculator.
Write a Review
