Law of Cosines Calculator
Find a missing side or angle of any triangle using the law of cosines
Law of Cosines Formula
\(c^2 = a^2 + b^2 - 2ab\cos(C)\)
Use when two sides and the included angle are known.
Law of Cosines Calculator – Find Missing Side or Angle of a Triangle
The Law of Cosines Calculator helps you solve any triangle when you know two sides and the included angle or all three sides. It is one of the most important formulas in trigonometry and is widely used in geometry, engineering, navigation, and physics.
This calculator instantly computes the missing side or angle and displays the triangle graph for better visualization.
What is the Law of Cosines?
The Law of Cosines is a mathematical formula that relates the three sides of a triangle to the cosine of one of its angles. It works for all types of triangles, including acute, obtuse, and right triangles.
- a, b, c = sides of the triangle
- C = angle opposite side c
- cos = cosine trigonometric function
Law of Cosines Formula Explained
The Law of Cosines formula describes the relationship between the three sides of a triangle and the cosine of one of its angles. It allows you to calculate a missing side or angle when enough information about the triangle is known.
In this formula:
- a = length of one side of the triangle
- b = length of another side
- c = side opposite angle C
- C = the included angle between sides a and b
The formula works by subtracting the value of 2ab cos(C) from the sum of the squares of sides a and b. The result gives the square of side c. Taking the square root provides the final side length.
Alternative Forms of the Law of Cosines
The formula can also be rearranged to calculate other sides or angles of a triangle:
These variations allow the Law of Cosines to solve almost any triangle problem when sufficient side or angle information is available.
When to Use the Law of Cosines
The Law of Cosines is used when:
- ✔ Two sides and the included angle are known (SAS)
- ✔ All three sides of a triangle are known (SSS)
- ✔ The triangle is not a right triangle
Example: Using the Law of Cosines
Suppose a triangle has the following values:
- Side a = 8
- Side b = 11
- Angle C = 60°
Step 1: Write the formula
Step 2: Substitute the values
Step 3: Calculate squares
Step 4: Simplify
Step 5: Take square root
Final Result: The missing side is approximately 9.85 units.
How to Use the Law of Cosines Calculator
Method 1: Find a Missing Side
- Enter side a
- Enter side b
- Enter angle C
- Click Solve Side
Method 2: Find a Missing Angle
- Enter side a
- Enter side b
- Enter side c
- Click Solve Angle
Law of Cosines vs Pythagorean Theorem
| Feature | Law of Cosines | Pythagorean Theorem |
|---|---|---|
| Works for all triangles | Yes | No |
| Works for right triangles | Yes | Yes |
| Uses trigonometry | Yes | No |
| Formula | \(c^2 = a^2 + b^2 - 2ab\cos C\) | \(a^2 + b^2 = c^2\) |
Applications of the Law of Cosines
Navigation
Used to calculate distances between locations on maps.
Engineering
Helps determine angles and structural dimensions.
Surveying
Used in land measurement and mapping.
Physics
Used to calculate forces, vectors, and distances.
FAQ on Law of Cosines Calculator
The Law of Cosines is used to calculate the missing side or angle of a triangle when two sides and the included angle or all three sides are known.
No. The Law of Cosines works for all triangles, while the Pythagorean theorem works only for right triangles.
Yes. If all three sides are known, the Law of Cosines can be rearranged to calculate an angle using inverse cosine.