Law of Cosines Calculator
Solve for a missing side or angle in any triangle using the Law of Cosines. Supports SAS and SSS cases.
The Law of Cosines relates the lengths of the sides of a triangle to the cosine of one of its angles. It generalizes the Pythagorean theorem to all triangles, not just right-angled ones.
Calculator Inputs
Choose what you want to calculate
Leave empty if finding a side
Angle opposite to Side c. Leave empty if finding an angle.
Results
Enter values above to see your results
How It Works
Select "Find a Side" if you know two sides and the included angle (SAS). Select "Find an Angle" if you know all three sides (SSS). Enter the values and the calculator will provide the missing value along with a step-by-step solution.
Worked Examples
Finding Side c (SAS)
a=5, b=7, C=49°= Givenc² = 5² + 7² - 2(5)(7)cos(49°)= Substitutionc² = 25 + 49 - 70(0.6561)= Simplifyc² = 74 - 45.92= 28.08c = √28.08= 5.30Tips & Best Practices
- •Ensure your calculator is in Degree mode if entering degrees (this calculator uses Degrees).
- •For the SSS case, the sum of any two sides must be greater than the third side (Triangle Inequality).
- •The included angle must be between 0 and 180 degrees.
Frequently Asked Questions
What is the Law of Cosines formula?
The standard formula is c² = a² + b² - 2ab·cos(C), where C is the angle opposite side c.
When should I use the Law of Cosines?
Use it when you have a non-right triangle and know either: two sides and the included angle (SAS) or all three sides (SSS).
Can I use it for right triangles?
Yes! Since cos(90°) = 0, the formula simplifies to c² = a² + b², which is the Pythagorean theorem.
Related Calculators
Percentage Calculator
Calculate percentages, percentage of a number, percentage increase/decrease, and more
Linear Interpolation Calculator
Find a value between two known points using linear interpolation formula.
Unit Rate Calculator
Calculate price per unit to find the best deal. Compare two products easily.
Factorial Calculator
Calculate the factorial of a number (n!). Supports large numbers.