HOME

TheInfoList



OR:

In
mathematics Mathematics is a field of study that discovers and organizes methods, Mathematical theory, theories and theorems that are developed and Mathematical proof, proved for the needs of empirical sciences and mathematics itself. There are many ar ...
, the triangle inequality states that for any
triangle A triangle is a polygon with three corners and three sides, one of the basic shapes in geometry. The corners, also called ''vertices'', are zero-dimensional points while the sides connecting them, also called ''edges'', are one-dimension ...
, the sum of the lengths of any two sides must be greater than or equal to the length of the remaining side. This statement permits the inclusion of degenerate triangles, but some authors, especially those writing about elementary geometry, will exclude this possibility, thus leaving out the possibility of equality. If , , and are the lengths of the sides of a triangle then the triangle inequality states that :c \leq a + b , with equality only in the degenerate case of a triangle with zero area. In
Euclidean geometry Euclidean geometry is a mathematical system attributed to ancient Greek mathematics, Greek mathematician Euclid, which he described in his textbook on geometry, ''Euclid's Elements, Elements''. Euclid's approach consists in assuming a small set ...
and some other geometries, the triangle inequality is a theorem about vectors and vector lengths ( norms): :\, \mathbf u + \mathbf v\, \leq \, \mathbf u\, + \, \mathbf v\, , where the length of the third side has been replaced by the length of the vector sum . When and are
real number In mathematics, a real number is a number that can be used to measure a continuous one- dimensional quantity such as a duration or temperature. Here, ''continuous'' means that pairs of values can have arbitrarily small differences. Every re ...
s, they can be viewed as vectors in \R^1, and the triangle inequality expresses a relationship between
absolute value In mathematics, the absolute value or modulus of a real number x, is the non-negative value without regard to its sign. Namely, , x, =x if x is a positive number, and , x, =-x if x is negative (in which case negating x makes -x positive), ...
s. In Euclidean geometry, for
right triangle A right triangle or right-angled triangle, sometimes called an orthogonal triangle or rectangular triangle, is a triangle in which two sides are perpendicular, forming a right angle ( turn or 90 degrees). The side opposite to the right angle i ...
s the triangle inequality is a consequence of the
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 t ...
, and for general triangles, a consequence of the
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 ...
, although it may be proved without these theorems. The inequality can be viewed intuitively in either \R^2 or \R^3. The figure at the right shows three examples beginning with clear inequality (top) and approaching equality (bottom). In the Euclidean case, equality occurs only if the triangle has a angle and two angles, making the three vertices
collinear In geometry, collinearity of a set of Point (geometry), points is the property of their lying on a single Line (geometry), line. A set of points with this property is said to be collinear (sometimes spelled as colinear). In greater generality, t ...
, as shown in the bottom example. Thus, in Euclidean geometry, the shortest distance between two points is a straight line. In
spherical geometry 300px, A sphere with a spherical triangle on it. Spherical geometry or spherics () is the geometry of the two-dimensional surface of a sphere or the -dimensional surface of higher dimensional spheres. Long studied for its practical applicati ...
, the shortest distance between two points is an arc of a
great circle In mathematics, a great circle or orthodrome is the circular intersection of a sphere and a plane passing through the sphere's center point. Discussion Any arc of a great circle is a geodesic of the sphere, so that great circles in spher ...
, but the triangle inequality holds provided the restriction is made that the distance between two points on a sphere is the length of a minor spherical line segment (that is, one with central angle in ) with those endpoints. The triangle inequality is a ''defining property'' of norms and measures of
distance Distance is a numerical or occasionally qualitative measurement of how far apart objects, points, people, or ideas are. In physics or everyday usage, distance may refer to a physical length or an estimation based on other criteria (e.g. "two co ...
. This property must be established as a theorem for any function proposed for such purposes for each particular space: for example, spaces such as the
real number In mathematics, a real number is a number that can be used to measure a continuous one- dimensional quantity such as a duration or temperature. Here, ''continuous'' means that pairs of values can have arbitrarily small differences. Every re ...
s,
Euclidean space Euclidean space is the fundamental space of geometry, intended to represent physical space. Originally, in Euclid's ''Elements'', it was the three-dimensional space of Euclidean geometry, but in modern mathematics there are ''Euclidean spaces ...
s, the Lp spaces (), and
inner product space In mathematics, an inner product space (or, rarely, a Hausdorff pre-Hilbert space) is a real vector space or a complex vector space with an operation called an inner product. The inner product of two vectors in the space is a scalar, ofte ...
s.


Euclidean geometry

The triangle inequality theorem is stated in
Euclid's Elements The ''Elements'' ( ) is a mathematics, mathematical treatise written 300 BC by the Ancient Greek mathematics, Ancient Greek mathematician Euclid. ''Elements'' is the oldest extant large-scale deductive treatment of mathematics. Drawing on the w ...
, Book I, Proposition 20: '' ��in the triangle ABC the sum of any two sides is greater than the remaining one, that is, the sum of BA and AC is greater than BC, the sum of AB and BC is greater than AC, and the sum of BC and CA is greater than AB.'' Euclid proved the triangle inequality for distances in
plane geometry Euclidean geometry is a mathematical system attributed to ancient Greek mathematics, Greek mathematician Euclid, which he described in his textbook on geometry, ''Euclid's Elements, Elements''. Euclid's approach consists in assuming a small set ...
using the construction in the figure. Beginning with triangle , an isosceles triangle is constructed with one side taken as and the other equal leg along the extension of side . It then is argued that angle has larger measure than angle , so side is longer than side . However: :\overline = \overline + \overline = \overline + \overline, so the sum of the lengths of sides and is larger than the length of . This proof appears in
Euclid's Elements The ''Elements'' ( ) is a mathematics, mathematical treatise written 300 BC by the Ancient Greek mathematics, Ancient Greek mathematician Euclid. ''Elements'' is the oldest extant large-scale deductive treatment of mathematics. Drawing on the w ...
, Book I, Proposition 20.


Mathematical expression of the constraint on the sides of a triangle

For a proper triangle, the triangle inequality, as stated in words, literally translates into three inequalities (given that a proper triangle has side lengths that are all positive and excludes the degenerate case of zero area): :a + b > c ,\quad b + c > a ,\quad c + a > b . A more succinct form of this inequality system can be shown to be :, a - b, < c < a + b . Another way to state it is :\max(a, b, c) < a + b + c - \max(a, b, c) implying :2 \max(a, b, c) < a + b + c and thus that the longest side length is less than the semiperimeter. A mathematically equivalent formulation is that the area of a triangle with sides must be a real number greater than zero. Heron's formula for the area is : \begin 4\cdot \text & =\sqrt \\ & = \sqrt. \end In terms of either area expression, the triangle inequality imposed on all sides is equivalent to the condition that the expression under the square root sign be real and greater than zero (so the area expression is real and greater than zero). The triangle inequality provides two more interesting constraints for triangles whose sides are , where and \phi is the
golden ratio In mathematics, two quantities are in the golden ratio if their ratio is the same as the ratio of their summation, sum to the larger of the two quantities. Expressed algebraically, for quantities and with , is in a golden ratio to if \fr ...
, as :1<\frac<3 :1\le\min\left(\frac, \frac\right)<\phi.


Right triangle

In the case of right triangles, the triangle inequality specializes to the statement that the hypotenuse is greater than either of the two sides and less than their sum. The second part of this theorem is already established above for any side of any triangle. The first part is established using the lower figure. In the figure, consider the right triangle . An isosceles triangle is constructed with equal sides . From the triangle postulate, the angles in the right triangle satisfy: : \alpha + \gamma = \pi /2 \ . Likewise, in the isosceles triangle , the angles satisfy: :2\beta + \gamma = \pi \ . Therefore, : \alpha = \pi/2 - \gamma ,\ \mathrm \ \beta= \pi/2 - \gamma /2 \ , and so, in particular, :\alpha < \beta \ . That means side , which is opposite to angle , is shorter than side , which is opposite to the larger angle . But . Hence: :\overline > \overline \ . A similar construction shows , establishing the theorem. An alternative proof (also based upon the triangle postulate) proceeds by considering three positions for point : (i) as depicted (which is to be proved), or (ii) coincident with (which would mean the isosceles triangle had two right angles as base angles plus the vertex angle , which would violate the triangle postulate), or lastly, (iii) interior to the right triangle between points and (in which case angle is an exterior angle of a right triangle and therefore larger than , meaning the other base angle of the isosceles triangle also is greater than and their sum exceeds in violation of the triangle postulate). This theorem establishing inequalities is sharpened by
Pythagoras' 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 ...
to the equality that the square of the length of the hypotenuse equals the sum of the squares of the other two sides.


Examples of use

Consider a triangle whose sides are in an
arithmetic progression An arithmetic progression or arithmetic sequence is a sequence of numbers such that the difference from any succeeding term to its preceding term remains constant throughout the sequence. The constant difference is called common difference of that ...
and let the sides be . Then the triangle inequality requires that :\begin 0 &<& a &<& 2a+3d, \\ 0 &<& a+d &<& 2a+2d, \\ 0 &<& a+2d &<& 2a+d. \end To satisfy all these inequalities requires : a>0 \text -\frac When is chosen such that , it generates a right triangle that is always similar to the
Pythagorean triple A Pythagorean triple consists of three positive integers , , and , such that . Such a triple is commonly written , a well-known example is . If is a Pythagorean triple, then so is for any positive integer . A triangle whose side lengths are a Py ...
with sides , , . Now consider a triangle whose sides are in a geometric progression and let the sides be . Then the triangle inequality requires that :\begin 0 &<& a &<& ar+ar^2, \\ 0 &<& ar &<& a+ar^2, \\ 0 &<& \! ar^2 &<& a+ar. \end The first inequality requires ; consequently it can be divided through and eliminated. With , the middle inequality only requires . This now leaves the first and third inequalities needing to satisfy : \begin r^2+r-1 & >0 \\ r^2-r-1 & <0. \end The first of these quadratic inequalities requires to range in the region beyond the value of the positive root of the quadratic equation , i.e. where is the
golden ratio In mathematics, two quantities are in the golden ratio if their ratio is the same as the ratio of their summation, sum to the larger of the two quantities. Expressed algebraically, for quantities and with , is in a golden ratio to if \fr ...
. The second quadratic inequality requires to range between 0 and the positive root of the quadratic equation , i.e. . The combined requirements result in being confined to the range :\varphi - 1 < r <\varphi\, \text a >0. When the common ratio is chosen such that it generates a right triangle that is always similar to the Kepler triangle.


Generalization to any polygon

The triangle inequality can be extended by
mathematical induction Mathematical induction is a method for mathematical proof, proving that a statement P(n) is true for every natural number n, that is, that the infinitely many cases P(0), P(1), P(2), P(3), \dots  all hold. This is done by first proving a ...
to arbitrary polygonal paths, showing that the total length of such a path is no less than the length of the straight line between its endpoints. Consequently, the length of any polygon side is always less than the sum of the other polygon side lengths.


Example of the generalized polygon inequality for a quadrilateral

Consider a quadrilateral whose sides are in a geometric progression and let the sides be . Then the generalized polygon inequality requires that :\begin 0 &<& a &<& ar+ar^2+ar^3 \\ 0 &<& ar &<& a+ar^2+ar^3 \\ 0 &<& ar^2 &<& a+ar+ar^3 \\ 0 &<& ar^3 &<& a+ar+ar^2. \end These inequalities for reduce to the following : r^3+r^2+r-1>0 : r^3-r^2-r-1<0. The left-hand side polynomials of these two inequalities have roots that are the tribonacci constant and its reciprocal. Consequently, is limited to the range where is the tribonacci constant.


Relationship with shortest paths

This generalization can be used to prove that the shortest curve between two points in Euclidean geometry is a straight line. No polygonal path between two points is shorter than the line between them. This implies that no curve can have an
arc length Arc length is the distance between two points along a section of a curve. Development of a formulation of arc length suitable for applications to mathematics and the sciences is a problem in vector calculus and in differential geometry. In the ...
less than the distance between its endpoints. By definition, the arc length of a curve is the least upper bound of the lengths of all polygonal approximations of the curve. The result for polygonal paths shows that the straight line between the endpoints is the shortest of all the polygonal approximations. Because the arc length of the curve is greater than or equal to the length of every polygonal approximation, the curve itself cannot be shorter than the straight line path.


Converse

The converse of the triangle inequality theorem is also true: if three real numbers are such that each is less than the sum of the others, then there exists a triangle with these numbers as its side lengths and with positive area; and if one number equals the sum of the other two, there exists a degenerate triangle (that is, with zero area) with these numbers as its side lengths. In either case, if the side lengths are , , we can attempt to place a triangle in the
Euclidean plane In mathematics, a Euclidean plane is a Euclidean space of Two-dimensional space, dimension two, denoted \textbf^2 or \mathbb^2. It is a geometric space in which two real numbers are required to determine the position (geometry), position of eac ...
as shown in the diagram. We need to prove that there exists a real number consistent with the values , , and , in which case this triangle exists. By the
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 t ...
we have and according to the figure at the right. Subtracting these yields . This equation allows us to express in terms of the sides of the triangle: :d=\frac. For the height of the triangle we have that . By replacing with the formula given above, we have :h^2 = b^2-\left(\frac\right)^2. For a real number to satisfy this, must be non-negative: :\begin 0 &\le b^2-\left(\frac\right)^2 \\ pt 0 &\le \left(b- \frac\right) \left(b + \frac\right) \\ pt 0 &\le \left(a^2-(b-c)^2)((b+c)^2-a^2 \right) \\ pt 0 &\le (a+b-c)(a-b+c)(b+c+a)(b+c-a) \\ pt 0 &\le (a+b-c)(a+c-b)(b+c-a) \end which holds if the triangle inequality is satisfied for all sides. Therefore, there does exist a real number h consistent with the sides a, b, c, and the triangle exists. If each triangle inequality holds
strictly In mathematical writing, the term strict refers to the property of excluding equality and equivalence and often occurs in the context of inequality and monotonic functions. It is often attached to a technical term to indicate that the exclusiv ...
, h > 0 and the triangle is non-degenerate (has positive area); but if one of the inequalities holds with equality, so h = 0, the triangle is degenerate.


Generalization to higher dimensions

The area of a triangular face of a
tetrahedron In geometry, a tetrahedron (: tetrahedra or tetrahedrons), also known as a triangular pyramid, is a polyhedron composed of four triangular Face (geometry), faces, six straight Edge (geometry), edges, and four vertex (geometry), vertices. The tet ...
is less than or equal to the sum of the areas of the other three triangular faces. More generally, in Euclidean space the hypervolume of an -
facet Facets () are flat faces on geometric shapes. The organization of naturally occurring facets was key to early developments in crystallography, since they reflect the underlying symmetry of the crystal structure. Gemstones commonly have facets cu ...
of an - simplex is less than or equal to the sum of the hypervolumes of the other facets. Much as the triangle inequality generalizes to a polygon inequality, the inequality for a simplex of any dimension generalizes to a
polytope In elementary geometry, a polytope is a geometric object with flat sides ('' faces''). Polytopes are the generalization of three-dimensional polyhedra to any number of dimensions. Polytopes may exist in any general number of dimensions as an ...
of any dimension: the hypervolume of any facet of a polytope is less than or equal to the sum of the hypervolumes of the remaining facets. In some cases the tetrahedral inequality is stronger than several applications of the triangle inequality. For example, the triangle inequality appears to allow the possibility of four points , , , and in Euclidean space such that distances : and :. However, points with such distances cannot exist: the area of the equilateral triangle is 169\sqrt 3, which is larger than three times 39\sqrt 3, the area of a isosceles triangle (all by Heron's formula), and so the arrangement is forbidden by the tetrahedral inequality.


Normed vector space

In a
normed vector space The Ateliers et Chantiers de France (ACF, Workshops and Shipyards of France) was a major shipyard that was established in Dunkirk, France, in 1898. The shipyard boomed in the period before World War I (1914–18), but struggled in the inter-war ...
, one of the defining properties of the norm is the triangle inequality: : \, \mathbf u + \mathbf v\, \leq \, \mathbf u\, + \, \mathbf v\, \quad \forall \, \mathbf u, \mathbf v \in V That is, the norm of the sum of two vectors is at most as large as the sum of the norms of the two vectors. This is also referred to as subadditivity. For any proposed function to behave as a norm, it must satisfy this requirement. If the normed space is Euclidean, or, more generally, strictly convex, then \, \mathbf u+\mathbf v\, =\, \mathbf u\, +\, \mathbf v\, if and only if the triangle formed by , , and , is degenerate, that is, and are on the same ray, i.e., or , or for some . This property characterizes strictly convex normed spaces such as the spaces with . However, there are normed spaces in which this is not true. For instance, consider the plane with the norm (the
Manhattan distance Taxicab geometry or Manhattan geometry is geometry where the familiar Euclidean distance is ignored, and the distance between two point (geometry), points is instead defined to be the sum of the absolute differences of their respective Cartesian ...
) and denote and . Then the triangle formed by , , and , is non-degenerate but :\, \mathbf u+\mathbf v\, =\, (1,1)\, =, 1, +, 1, =2=\, \mathbf u\, +\, \mathbf v\, .


Example norms

The ''
absolute value In mathematics, the absolute value or modulus of a real number x, is the non-negative value without regard to its sign. Namely, , x, =x if x is a positive number, and , x, =-x if x is negative (in which case negating x makes -x positive), ...
'' is a norm for the
real line A number line is a graphical representation of a straight line that serves as spatial representation of numbers, usually graduated like a ruler with a particular origin (geometry), origin point representing the number zero and evenly spaced mark ...
; as required, the absolute value satisfies the triangle inequality for any real numbers and . If and have the same sign or either of them is zero, then , u + v, = , u, +, v, . If and have opposite signs, then without loss of generality assume , u, > , v, . Then , u + v, \leq , u, +, v, . The triangle inequality is useful in
mathematical analysis Analysis is the branch of mathematics dealing with continuous functions, limit (mathematics), limits, and related theories, such as Derivative, differentiation, Integral, integration, measure (mathematics), measure, infinite sequences, series ( ...
for determining the best upper estimate on the size of the sum of two numbers, in terms of the sizes of the individual numbers. There is also a lower estimate, which can be found using the ''reverse triangle inequality'' which states that for any real numbers and , , u-v, \geq \bigl, , u, -, v, \bigr, . The '' taxicab norm'' or 1-norm is one generalization absolute value to higher dimensions. To find the norm of a vector v = (v_1, v_2, \ldots v_n ), just add the absolute value of each component separately, \, v\, _1 = , v_1, + , v_2, + \dotsb + , v_n, . The ''Euclidean norm'' or 2-norm defines the length of translation vectors in an -dimensional
Euclidean space Euclidean space is the fundamental space of geometry, intended to represent physical space. Originally, in Euclid's ''Elements'', it was the three-dimensional space of Euclidean geometry, but in modern mathematics there are ''Euclidean spaces ...
in terms of a
Cartesian coordinate system In geometry, a Cartesian coordinate system (, ) in a plane (geometry), plane is a coordinate system that specifies each point (geometry), point uniquely by a pair of real numbers called ''coordinates'', which are the positive and negative number ...
. For a vector v = (v_1, v_2, \ldots v_n ), its length is defined using the -dimensional
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 t ...
: \, v\, _2 = \sqrt. The ''inner product'' is norm in any
inner product space In mathematics, an inner product space (or, rarely, a Hausdorff pre-Hilbert space) is a real vector space or a complex vector space with an operation called an inner product. The inner product of two vectors in the space is a scalar, ofte ...
, a generalization of Euclidean vector spaces including infinite-dimensional examples. The triangle inequality follows from the
Cauchy–Schwarz inequality The Cauchy–Schwarz inequality (also called Cauchy–Bunyakovsky–Schwarz inequality) is an upper bound on the absolute value of the inner product between two vectors in an inner product space in terms of the product of the vector norms. It is ...
as follows: Given vectors u and v, and denoting the inner product as \langle u , v\rangle : : The Cauchy–Schwarz inequality turns into an equality if and only if and are linearly dependent. The inequality \langle u, v \rangle + \langle v, u \rangle \le 2\left, \left\langle u, v \right\rangle\ turns into an equality for linearly dependent u and v if and only if one of the vectors or is a ''nonnegative'' scalar of the other. Taking the square root of the final result gives the triangle inequality. The -norm is a generalization of taxicab and Euclidean norms, using an arbitrary positive integer exponent, \, v\, _p = \bigl(, v_1, ^p + , v_2, ^p + \dotsb + , v_n, ^p\bigr)^, where the are the components of vector . Except for the case , the -norm is ''not'' an inner product norm, because it does not satisfy the
parallelogram law In mathematics, the simplest form of the parallelogram law (also called the parallelogram identity) belongs to elementary geometry. It states that the sum of the squares of the lengths of the four sides of a parallelogram equals the sum of the s ...
. The triangle inequality for general values of is called Minkowski's inequality. It takes the form:\, u+v\, _p \le \, u\, _p + \, v\, _p \ .


Metric space

In a
metric space In mathematics, a metric space is a Set (mathematics), set together with a notion of ''distance'' between its Element (mathematics), elements, usually called point (geometry), points. The distance is measured by a function (mathematics), functi ...
with metric , the triangle inequality is a requirement upon
distance Distance is a numerical or occasionally qualitative measurement of how far apart objects, points, people, or ideas are. In physics or everyday usage, distance may refer to a physical length or an estimation based on other criteria (e.g. "two co ...
: :d(A,\ C) \le d(A,\ B) + d(B,\ C) \ , for all points , , and in . That is, the distance from to is at most as large as the sum of the distance from to and the distance from to . The triangle inequality is responsible for most of the interesting structure on a metric space, namely, convergence. This is because the remaining requirements for a metric are rather simplistic in comparison. For example, the fact that any
convergent sequence As the positive integer n becomes larger and larger, the value n\times \sin\left(\tfrac1\right) becomes arbitrarily close to 1. We say that "the limit of the sequence n \times \sin\left(\tfrac1\right) equals 1." In mathematics, the li ...
in a metric space is a
Cauchy sequence In mathematics, a Cauchy sequence is a sequence whose elements become arbitrarily close to each other as the sequence progresses. More precisely, given any small positive distance, all excluding a finite number of elements of the sequence are le ...
is a direct consequence of the triangle inequality, because if we choose any and such that and , where is given and arbitrary (as in the definition of a limit in a metric space), then by the triangle inequality, , so that the sequence is a Cauchy sequence, by definition. This version of the triangle inequality reduces to the one stated above in case of normed vector spaces where a metric is induced via , with being the vector pointing from point to .


Reverse triangle inequality

The reverse triangle inequality is an equivalent alternative formulation of the triangle inequality that gives lower bounds instead of upper bounds. For plane geometry, the statement is: :''Any side of a triangle is greater than or equal to the difference between the other two sides''. In the case of a normed vector space, the statement is: : \big, \, u\, -\, v\, \big, \leq \, u-v\, , or for metric spaces, , d(A, C) - d(B, C), \leq d(A, B). This implies that the norm \, \cdot\, as well as the distance-from-z function d(z ,\cdot) are
Lipschitz continuous In mathematical analysis, Lipschitz continuity, named after Germany, German mathematician Rudolf Lipschitz, is a strong form of uniform continuity for function (mathematics), functions. Intuitively, a Lipschitz continuous function is limited in h ...
with Lipschitz constant , and therefore are in particular uniformly continuous. The proof of the reverse triangle inequality from the usual one uses \, v-u\, = \, 1(u-v)\, = , 1, \cdot\, u-v\, = \, u-v\, to find: : \, u\, = \, (u-v) + v\, \leq \, u-v\, + \, v\, \Rightarrow \, u\, - \, v\, \leq \, u-v\, , : \, v\, = \, (v-u) + u\, \leq \, v-u\, + \, u\, \Rightarrow \, u\, - \, v\, \geq -\, u-v\, , Combining these two statements gives: : -\, u-v\, \leq \, u\, -\, v\, \leq \, u-v\, \Rightarrow \big, \, u\, -\, v\, \big, \leq \, u-v\, . In the converse, the proof of the triangle inequality from the reverse triangle inequality works in two cases: If \, u +v\, - \, u\, \geq 0, then by the reverse triangle inequality, \, u +v\, - \, u\, = \, u + v\, -\, u\, \leq \, (u + v) - u\, = \, v\, \Rightarrow \, u + v\, \leq \, u\, + \, v\, , and if \, u +v\, - \, u\, < 0, then trivially \, u\, +\, v\, \geq \, u\, > \, u + v\, by the nonnegativity of the norm. Thus, in both cases, we find that \, u\, + \, v\, \geq \, u + v\, . For metric spaces, the proof of the reverse triangle inequality is found similarly by: d(A, B) + d(B, C) \geq d(A, C) \Rightarrow d(A, B) \geq d(A, C) - d(B, C) d(C, A) + d(A, B) \geq d(C, B) \Rightarrow d(A, B) \geq d(B, C) - d(A, C) Putting these equations together we find: d(A, B) \geq , d(A, C) - d(B, C), And in the converse, beginning from the reverse triangle inequality, we can again use two cases: If d(A, C) - d(B, C) \geq 0, then d(A, B) \geq , d(A, C) - d(B, C), = d(A, C) - d(B, C) \Rightarrow d(A, B) + d(B, C) \geq d(A, C), and if d(A, C) - d(B, C) < 0, then d(A, B) + d(B, C) \geq d(B, C) > d(A, C) again by the nonnegativity of the metric. Thus, in both cases, we find that d(A, B) + d(B, C) \geq d(A, C).


Triangle inequality for cosine similarity

By applying the cosine function to the triangle inequality and reverse triangle inequality for arc lengths and employing the angle addition and subtraction formulas for cosines, it follows immediately that \operatorname(u,w) \geq \operatorname(u,v) \cdot \operatorname(v,w) - \sqrt and \operatorname(u,w) \leq \operatorname(u,v) \cdot \operatorname(v,w) + \sqrt\,. With these formulas, one needs to compute a
square root In mathematics, a square root of a number is a number such that y^2 = x; in other words, a number whose ''square'' (the result of multiplying the number by itself, or y \cdot y) is . For example, 4 and −4 are square roots of 16 because 4 ...
for each triple of vectors that is examined rather than for each pair of vectors examined, and could be a performance improvement when the number of triples examined is less than the number of pairs examined.


Reversal in Minkowski space

The
Minkowski space In physics, Minkowski space (or Minkowski spacetime) () is the main mathematical description of spacetime in the absence of gravitation. It combines inertial space and time manifolds into a four-dimensional model. The model helps show how a ...
metric \eta_ is not positive-definite, which means that \, u\, ^2 = \eta_ u^\mu u^\nu can have either sign or vanish, even if the vector is non-zero. Moreover, if and are both timelike vectors lying in the future light cone, the triangle inequality is reversed: : \, u+v\, \geq \, u\, + \, v\, . A physical example of this inequality is the
twin paradox In physics, the twin paradox is a thought experiment in special relativity involving twins, one of whom takes a space voyage at relativistic speeds and returns home to find that the twin who remained on Earth has aged more. This result appear ...
in
special relativity In physics, the special theory of relativity, or special relativity for short, is a scientific theory of the relationship between Spacetime, space and time. In Albert Einstein's 1905 paper, Annus Mirabilis papers#Special relativity, "On the Ele ...
. The same reversed form of the inequality holds if both vectors lie in the past light cone, and if one or both are null vectors. The result holds in n + 1 dimensions for any n \geq 1. If the plane defined by u and v is space-like (and therefore a Euclidean subspace) then the usual triangle inequality holds.


See also

* Subadditivity * Minkowski inequality * Ptolemy's inequality


Notes


References

* * {{DEFAULTSORT:Triangle Inequality Geometric inequalities Linear algebra Metric geometry Articles containing proofs Theorems in geometry