Free · Triangles
Triangle Side from Perimeter, Angles and Known Sides
Find a missing triangle side from its perimeter, a selected angle and two sides, or a side with two angles.
- Formula & worked example
- Private in your browser
- No signup
Calculator inputs
Loading calculator…
How to use this calculator
- Enter the known values in the units shown. Results update as you type.
- Where results are editable, change one to solve backwards. Lock a value to hold it fixed.
- Use the worked example to check the method. Reset restores the starting fields.
Private by default
Inputs and results stay in this browser tab. Bookify does not upload or store the values you enter.
Formula and method
Sides 5 cm and 7 cm with an 18 cm perimeter leave a 6 cm third side.
P=a+b+c; a²=b²+c²−2bc cos(α); a/sin(α)=b/sin(β)=c/sin(γ).
Worked example
Enter these known values and leave the other values blank.
- Calculation method
- 2 sides and perimeter
- Side a
- 5 cm
- Side b
- 7 cm
- Perimeter
- 18 cm
- Side c
- 6 cm
Assumptions and limitations
- Choose the retained perimeter, angle-and-two-sides, ASA or AAS method. In angle-and-two-sides mode the angle selector preserves all three labelled choices.
- Every side is positive and smaller than the other two combined; every interior angle lies strictly between 0° and 180°. Supplied angle pairs must sum to less than 180°.
- An SSA inverse can have two, one or no geometric solutions. The captured positive-square-root branch is retained; this calculator does not enumerate every ambiguous triangle. A branch that is zero, negative, non-real or inconsistent is not a valid triangle.
- Angle-sum residuals at most 1e-60 radian are accepted as computational equality at 64-digit working precision. Extreme near-degeneracy may remain numerically unresolved. In an SSA inverse with the opposite side no longer than the adjacent known side, angles within 1e-50 radian below a right angle are also numerically unresolved; right or obtuse angles require a strictly longer opposite side.
- The three worked examples load locally, reset earlier entries and set their own units. Original numerical example conditions and step-by-step explanations are retained with new wording.
- Very small finite values may use scientific notation when ordinary fixed-decimal formatting cannot show them without losing the nonzero result.
Common questions
When can I subtract known sides from a perimeter?
When the perimeter and two sides are known: the missing side is P minus those two sides. The resulting positive lengths must also satisfy the triangle inequalities.
Why can a supplied angle and two sides be ambiguous?
If the angle is not between the two known sides, more than one triangle may fit. The retained inverse chooses one algebraic branch and does not promise all solutions.
References
Use four-factor Heron/atan2 for angles, half-angle cosine-law forward sides, and rationalized positive-square-root inverses when the projection is negative. These algebraic equivalents retain every captured target/input set and avoid subtracting nearly equal positive lengths. Negative SSA radicands are clamped only inside a separately enforced relative 1e-60 boundary, retaining a zero repeated-root solution at working precision. Evaluate SSA differences before products, sort sides with exact-sign comparisons for Kahan-style Heron factors, and factor angle dot differences to retain thin positive triangles. Use the same stable half-angle SAS identity in source consistency presentations as in the numeric forward rules. The SSA radicand uses the reviewed source-specific sector-dependent cosine/sine decomposition; algebraic targets and the chosen positive-square-root branch remain unchanged. Use exact-sign positive side/angle and triangle inequalities, enforce both supplied angle sums, and replace unsupported approximate equal predicates with an explicit 1e-60-radian angle-sum resolution boundary. Retain all source modes and the positive-square-root branch in side-angle inverses. Triangle inequalities subtract the larger adjacent side first, preserving small positive differences without changing the strict geometric domain. Reject nonpositive SSA branches at right/obtuse known angles. When opposite<=adjacent, require the known angle to be more than1e-60 radian belowpi/2; this explicit numerical-domain exclusion prevents unit-conversion roundoff from inventing a positive side at exactly90degrees. Evaluate SSA radicands using a nonnegative cosine decomposition whenever opposite>=adjacent, and also in the acute near-right sector; retain sine factors below45degrees when opposite<adjacent to avoid small-opposite cancellation. Scale the negative-roundoff boundary to magnitudes of the actual evaluated terms, so resolved non-real near-right inputs cannot be hidden by a much larger opposite-side square. Tighten the explicitly unresolved near-right acute exclusion for opposite<=adjacent to1e-50radian, retaining guard precision above display accuracy.