**Are you an EPFL student looking for a semester project?**

Work with us on data science and visualisation projects, and deploy your project as an app on top of GraphSearch.

Concept# Law of cosines

Summary

In trigonometry, the law of cosines (also known as the cosine formula or cosine rule) relates the lengths of the sides of a triangle to the cosine of one of its angles. For a triangle with sides and opposite respective angles and (see Fig. 1), the law of cosines states:
The law of cosines generalizes the Pythagorean theorem, which holds only for right triangles: if is a right angle then and the law of cosines reduces to
The law of cosines is useful for solving a triangle when all three sides or two sides and their included angle are given.
The theorem is used in solution of triangles, i.e., to find (see Figure 3):
the third side of a triangle if one knows two sides and the angle between them:
the angles of a triangle if one knows the three sides:
the third side of a triangle if one knows two sides and an angle opposite to one of them (this side can also be found by two applications of the law of sines):
These formulas produce high round-off errors in floating point calculations if the triangle is very acute, i.e., if c is small relative to a and b or γ is small compared to 1. It is even possible to obtain a result slightly greater than one for the cosine of an angle.
The third formula shown is the result of solving for a in the quadratic equation a2 − 2ab cos γ + b2 − c2 = 0. This equation can have 2, 1, or 0 positive solutions corresponding to the number of possible triangles given the data. It will have two positive solutions if b sin γ < c < b, only one positive solution if c = b sin γ, and no solution if c < b sin γ. These different cases are also explained by the side-side-angle congruence ambiguity.
Book II of Euclid's Elements, compiled c. 300 BC from material a couple of centuries older, contains a geometric theorem corresponding to the law of cosines but expressed in the contemporary language of rectangle areas; Hellenistic trigonometry developed later, and sine and cosine per se first appeared centuries afterward in India.
The cases of obtuse triangles and acute triangles (corresponding to the two cases of negative or positive cosine) are treated separately, in Propositions II.

Official source

This page is automatically generated and may contain information that is not correct, complete, up-to-date, or relevant to your search query. The same applies to every other page on this website. Please make sure to verify the information with EPFL's official sources.

Related MOOCs (11)

Related concepts (52)

Related courses (134)

Trigonometric Functions, Logarithms and Exponentials

Ce cours donne les connaissances fondamentales liées aux fonctions trigonométriques, logarithmiques et exponentielles. La présentation des concepts et des propositions est soutenue par une grande gamm

Trigonometric Functions, Logarithms and Exponentials

Ce cours donne les connaissances fondamentales liées aux fonctions trigonométriques, logarithmiques et exponentielles. La présentation des concepts et des propositions est soutenue par une grande gamm

Law of cosines

In trigonometry, the law of cosines (also known as the cosine formula or cosine rule) relates the lengths of the sides of a triangle to the cosine of one of its angles. For a triangle with sides and opposite respective angles and (see Fig. 1), the law of cosines states: The law of cosines generalizes the Pythagorean theorem, which holds only for right triangles: if is a right angle then and the law of cosines reduces to The law of cosines is useful for solving a triangle when all three sides or two sides and their included angle are given.

Pythagorean theorem

In mathematics, the Pythagorean theorem or Pythagoras' theorem is a fundamental relation in Euclidean geometry between the three sides of a right triangle. It states that the area of the square whose side is the hypotenuse (the side opposite the right angle) is equal to the sum of the areas of the squares on the other two sides. The theorem can be written as an equation relating the lengths of the sides a, b and the hypotenuse c, sometimes called the Pythagorean equation: The theorem is named for the Greek philosopher Pythagoras, born around 570 BC.

Law of tangents

In trigonometry, the law of tangents or tangent rule is a statement about the relationship between the tangents of two angles of a triangle and the lengths of the opposing sides. In Figure 1, a, b, and c are the lengths of the three sides of the triangle, and α, β, and γ are the angles opposite those three respective sides. The law of tangents states that The law of tangents, although not as commonly known as the law of sines or the law of cosines, is equivalent to the law of sines, and can be used in any case where two sides and the included angle, or two angles and a side, are known.

Le but du cours de physique générale est de donner à l'étudiant les notions de base nécessaires à la compréhension des phénomènes physiques. L'objectif est atteint lorsque l'étudiant est capable de pr

Étudier les concepts fondamentaux d'analyse et le calcul différentiel et intégral des fonctions réelles d'une variable.

Ce cours a pour but de donner les fondements de mathématiques nécessaires à l'architecte contemporain évoluant dans une école polytechnique.

Related lectures (1,000)

Black Holes: Renormalisation GroupPHYS-427: Relativity and cosmology I

Covers black holes and the renormalisation group, providing detailed information on these concepts.

Wave Equations: Vibrating StringMATH-212: Analyse numérique et optimisation

Explores the wave equation for a vibrating string and its numerical solution using finite difference formulas and the Newmark scheme in MATLAB/GNU Octave.

General Solution of Central Force MotionPHYS-101(k): General physics : mechanics

Explores the general solution of motion in a central force field, conservation of energy, Kepler's problem, and trajectory.