Triangle Solver
Calculate triangle sides and angles (SSS, SAS, ASA). Solves triangles given at least 3 known values using law of cosines, law of sines, and Heron's formula.…
Solves triangles given at least 3 known values using law of cosines, law of sines, and Heron's formula. Enter any combination of sides (a,b,c) and angles (A,B,C).
How Are Triangles Solved Using Trigonometry?
Triangle solving determines unknown sides and angles from known values using three fundamental laws. The Law of Cosines (c² = a² + b² − 2ab·cos(C)) handles SSS (three sides) and SAS (two sides and included angle) cases. The Law of Sines (a/sin(A) = b/sin(B) = c/sin(C)) handles ASA and AAS cases.
In metalworking and fabrication, triangle solving is essential for layout work, calculating bevel angles, determining compound angles for miter cuts, computing distances between holes, and verifying geometric relationships on machined parts. Inspection departments use triangle calculations to verify angular features from coordinate measurements.
Heron's formula calculates area from three sides: A = √(s(s−a)(s−b)(s−c)) where s = (a+b+c)/2. This is useful when verifying material area for weight calculation or checking triangular gusset plate dimensions. The perimeter and area together can verify that a calculated triangle matches the physical part.
Formula: Law of Cosines: c² = a² + b² − 2ab·cos(C) Law of Sines: a/sin(A) = b/sin(B) = c/sin(C) Heron's Area: A = √(s(s−a)(s−b)(s−c)), s=(a+b+c)/2 Angle Sum: A + B + C = 180°
Example Calculation
Given triangle with a = 50 mm, b = 70 mm, C = 60°. Law of Cosines: c² = 50² + 70² − 2×50×70×cos(60°) = 2500 + 4900 − 3500 = 3900, c = 62.45 mm. Law of Sines: sin(A) = 50×sin(60°)/62.45 = 0.693, A = 43.9°. B = 180° − 60° − 43.9° = 76.1°. Area = 0.5×50×70×sin(60°) = 1515.5 mm².
When to Use This Calculator
- Calculating compound angles for miter cuts in fabrication — welded joints at non-standard angles require precise triangle geometry
- Determining the true distance between two hole positions from angular and partial-dimension information on a drawing
- Verifying geometric relationships from CMM coordinate data — converting X/Y deviations into angular error values
- Laying out triangular gusset plates or brackets where only some dimensions are specified on the drawing
Common Mistakes to Avoid
- Not checking for the ambiguous case (SSA) — two sides and a non-included angle can produce zero, one, or two valid solutions; failing to check leads to using the wrong triangle
- Using degrees when the calculator expects radians (or vice versa) — this produces completely nonsensical results
- Assuming all three angles sum to 180° as a check without accounting for rounding — floating-point rounding can make valid triangles appear to fail this check
- Providing an invalid combination of inputs (e.g., three angles without any side) — this defines a shape family, not a unique triangle; at least one side length is required
How to Interpret Results
- Sanity-check every solution: the three angles must sum to 180° and the longest side must sit opposite the largest angle — a violation means an input was mistyped
- In the ambiguous SSA case (two sides and a non-included angle), the solver returns the acute-angle solution — check whether the obtuse supplement (180° − angle) also fits your physical geometry before cutting material
- An 'invalid triangle' result means the inputs violate the triangle inequality or the given angle cannot close the shape — re-measure rather than forcing values
- Area (Heron's formula) supports material and weight estimates for gussets and brackets; perimeter gives cut length — both serve as independent checks against CAD
- Results are rounded to 4 decimal places — sufficient for shop layout, but carry CAD-level precision through chained calculations to avoid accumulating rounding error
Related Standards & References
- Machinery's Handbook — Solution of Triangles section: the canonical shop reference for law of sines/cosines layout calculations
- ISO 80000-2 — Quantities and units — Part 2: Mathematics (angle units and notation conventions in technical documentation)
- ASME Y14.5 — Dimensioning and tolerancing (how angular dimensions and basic angles are specified on engineering drawings)
- CRC Standard Mathematical Tables and Formulas — reference for trigonometric identities and triangle solution formulas
Frequently Asked Questions
When does the ambiguous case (SSA) occur and how do I handle it?
The ambiguous case arises when given two sides and a non-included angle (SSA). There may be zero, one, or two valid triangles. If a < b·sin(A), no triangle exists. If a = b·sin(A), one right triangle exists. If b·sin(A) < a < b, two triangles exist (supplement angle solution). If a ≥ b, one triangle exists. Always check for the ambiguous case when using the Law of Sines with SSA input.
How is triangle solving used in machining and fabrication?
Common applications: calculating hole positions from angular specifications, determining miter and bevel angles for welded joints, computing compound angles for 5-axis machining setups, verifying part geometry from CMM coordinate data, laying out triangular gusset plates and brackets, and calculating the true length of pipe offsets in piping layout. Inspection uses triangle solving to convert X/Y coordinate deviations into angular errors.