Law of Cosines
The law of cosines, c² = a² + b² − 2ab·cos C, generalises the Pythagorean theorem to any triangle. Given two sides and the angle between them, this solver finds the third side, then uses the law of cosines again to find the remaining angles.
Frequently asked questions
What is the SAS case?
SAS means Side-Angle-Side: you know two sides and the angle included between them. The law of cosines solves it directly.
How is it related to the Pythagorean theorem?
When the included angle is 90°, cos C = 0 and the formula reduces to c² = a² + b².
Can the included angle be obtuse?
Yes. Any angle strictly between 0° and 180° is valid; an obtuse angle simply gives a longer third side.