By Zencalcy Editorial TeamLast reviewed About us
The law of cosines generalizes Pythagoras to any triangle: from two sides and the angle between them (SAS), recover the third side directly.
Third side from two sides + included angle (law of cosines).
c² = a² + b² − 2ab·cos C
| Symbol | Meaning |
|---|---|
| a, b | Known sides |
| C | Included angle (degrees, 0–180) |
a = 5, b = 7, C = 60° → c² = 25 + 49 − 35 = 39, c ≈ 6.245.
Continue with the Percentage Calculator, all math calculators, or browse the full calculator directory.
At C = 90°, cos C = 0 and the formula collapses to c² = a² + b².
Click to use the Absolute Value Calculator and get instant results.
Click to use the Basic Calculator and get instant results.
Click to use the Scientific Calculator and get instant results.
Click to use the Exponent Calculator and get instant results.
Click to use the Square Root Calculator and get instant results.
Click to use the Cube Root Calculator and get instant results.
Content updated: September 2026