# Triangle Inequality

**Triangle inequality** has its name on a geometrical fact that **the length of one side of a triangle can never be greater than the sum of the lengths of other two sides of the triangle**. If $ a$ , $ b$ and $ c$ be the three sides of a triangle, then neither $ a$ can be greater than $ b+c$ , nor$ b$ can be greater than $ c+a$ and so $ c$ can not be greater than $ a+b$ .

Consider the triangle in the image, side $ a$ shall be equal to the sum of other two sides $ b$ and $ c$ , only if the triangle behaves like a straight line. Thinking practically, one can say that one side is formed by joining the end points of two other sides.

In modulus form, $ |x+y|$ represents the side $ a$ if $ |x|$ represents side $ b$ and $ |y|$ represents side $ c$ . A modulus is nothing, but the distance of a point on the number line from point zero.

For example, the distance of $ 5$ and $ -5$ from $ 0$ on the initial line is $ 5$ . So we may write that $ |5|=|-5|=5$ .

Triangle inequalities are not only valid for real numbers but also for complex numbers, vectors and in Euclidean spaces. In this article, I shall discuss them separately.

## Triangle Inequality for Real Numbers

For arbitrary real numbers $ x$ and $ y$ , we have

$ |x+y| \le |x|+|y|$ .

This expression is same as the length of any side of a triangle is less than or equal to (i.e., not greater than) the sum of the lengths of the other two sides. The proof of this inequality is very easy and requires only the understandings of difference between ‘the values’ and ‘the lengths’. Values (like $ 4.318, 3, -7, x$ ) can be either negative or positive but the lengths are always positive. Before we proceed for the proof of this inequality, we will prove a lemma.

**Lemma:** If $ a\ge 0$ , then $ |x|\le a$ if and only if $ -a\le x\le a$ .$

Proof: ‘if and only if’ means that there are two things to proven: first if $ |x|\le a$ then $ -a\le x\le a$ , and conversely if $ -a\le x\le a$ then $ |x|\le a$

**Proof:** Suppose $ |x|\le a$ . Then $ -|x|\ge -a$ . But since, $ |x|$ can only be either $ x$ or $ -x$ , hence $ -|x|\le x \le |x|$ . This implies that, $ -a\le -|x|\le x\le |x|\le a$ .

Or, $ -a\le x\le a$ . (Proved!)

And conversely, assume $ -a\le x\le a$ . Then if $ x \ge 0$ , we have $ |x| =x$ and from assumption, $ x \le a$ . Or $ |x| \le a$ . And also, if $ x\le 0$ , $ |x|=-x \le a$ . In either cases we have $ |x| \le a$ . (Proved!)

This is the proof of given lemma.

Now as we know $ -|x|\le x\le |x|$ and $ -|y|\le y\le |y|$ . Then on adding them we get

$ -(|x|+|y|)\le x+y \le |x|+|y|$ .

Hence by the lemma, $ |x+y| \le |x|+|y|$ .** (Proved!)**

Generalization of triangle inequality for real numbers can be done be increasing the number of real-variables.

As, $ |x_1+x_2+ \ldots +x_n| \le |x_1|+|x_2|+ \ldots +|x_n|$

or, in sigma summation:

$ |\sum_{k=1}^n {x_k}| \le \sum_{k=1}^n {|x_k|}$ .

## Triangle Inequality for Vectors

**Theorem**: If $ A$ and $ B$ are vectors in $ V_n$ (vector space in n-tuples or simply n-space), we have

$ ||A+B|| \le ||A||+||B||$ .

Notations used in this theorem are such that $ ||A||$ represents the length (or norm) of vector $ A$ in a vector space.

See: Real Analysis

The length of a vector is defined as the square-root of scalar product of the vector to itself. i.e., $ ||A||= \sqrt{A\cdot A}$ .

Now, we can write

$ ||A+B|| =\sqrt{(A+B) \cdot (A+B)}$

or, $ ||A+B|| =\sqrt{A \cdot A +2 A \cdot B +B\cdot B} =\sqrt{||A||^2+2 A \cdot B + ||B||^2} \ldots (1)$

($ A\cdot A= ||A||$ and so for $ ||B||$ )

Similarly,

$ ||A||+||B|| = \sqrt{{(||A||+||B||)}^2} =\sqrt{||A||^2+2||A|| ||B|| +||B||^2} \ldots (2)$ .

Comparing (1) and (2), we get that

$ ||A+B|| \le ||A||+||B||$

Since, $ A\cdot B \le ||A|| ||B||$ .

## Triangle Inequality for complex numbers

**Theorem**: If $ z_1$ and $ z_2$ be two complex numbers, $ |z|$ represents the absolute value of a complex number $ z$ , then

$ |z_1+z_2| \le |z_1|+|z_2|$ .

The proof is similar to that for vectors, because complex numbers behave like vector quantities with respect to elementary operations. You need only to replace $ A$ and $ B$ by $ z_1$ and $ z_2$ respectively.

## Triangle Inequality in Euclidean Space

Before introducing the inequality, I will define the set of n-tuples of real numbers $ \mathbb{R}^n$ , distance in $ \mathbb{R}^n$ and the Euclidean space $\mathbb{R}^n$ .

## 1. The Set $ \mathbb{R}^n$

The set of all ordered n-tuples or real numbers is denoted by the symbol $ \mathbb{R}^n$ .

Thus the n-tuples

$ (x_1, x_2, \ldots x_n)$

where $ x_1, x_2, \ldots x_n$ are real numbers and are members of $ \mathbb{R}^n$ . Each of the members $ x_1, x_2 \ldots x_n$ is called a Co-ordinate or Component of the n-tuple.

We shall denote the elements of $ \mathbb{R}^n$ by lowercase symbols $ \mathbf{x}^n$ , $ \mathbf{y}^n$ , $ \mathbf{z}^n$ etc. or simply $ \mathbf{x}$ , $ \mathbf{y}$ , $ \mathbf{z}$ ; so that each stands for an ordered n-tuple of real numbers.

i.e., $ \mathbf{x} =(x_1, x_2, \ldots x_n)$

$ \mathbf{y} =(y_1, y_2, \ldots y_n)$ etc.

We define,

$ \mathbf{x+y} =(x_1+y_1, \ldots x_n+y_n)$

and $ c \mathbf{x} =(cx_1, cx_2, \ldots cx_n)$ for any real number $ c$ .

Also we write

$ \mathbf{0} =(0, 0, \ldots 0)$

and $ \mathbf{-x} =(-x_1, -x_2, \ldots -x_n)$ .

## 2. Distance in $ \mathbb{R}^n$

If $ \mathbf{x} =(x_1, x_2, \ldots x_n)$

and $ \mathbf{y} =(y_1, y_2, \ldots y_n)$ .

We define a quantity

$ d(\mathbf{x}, \mathbf{y})$ as

$ d(\mathbf{x}, \mathbf{y})=\sqrt{\left({{(x_1-y_1)}^2+{(x_2-y_2)}^2+ \ldots {(x_n-y_n)}^2}\right)}$

or, that is

$ d(\mathbf{x}, \mathbf{y})=\sqrt{\left({\displaystyle{\sum_{i=1}^n}{(x_i-y_i)}^2}\right)}$

and we describe $ d(\mathbf{x}, \mathbf{y})$ as the distance between the points $ \mathbf{x}$ and $ \mathbf{y}$ .

## 3. Norm

If $ \mathbf{x}=(x_1, x_2, \ldots x_n) \ \in \mathbb{R}^n$ , we write

$ ||\mathbf{x}||=\sqrt{\left({\displaystyle{\sum_{i=1}^n} {x_i}^2}\right)}$

so that $ ||x||$ is a non-negative real number. The number $ ||x||$ which denotes the distance between point $ \mathbf{x}$ and origin $ \mathbf{0}$ is called the Norm of $ \mathbf{x}$ . The norm is just like the absolute value of a real number.

And also,

$ d(\mathbf{x}, \mathbf{y}) =||\mathbf{x}-\mathbf{y}||$ .

## 4. The Euclidean Space $ \mathbb{R}^n$

The set $ \mathbb{R}^n$ equipped with all the properties mentioned above is called the Euclidean space of dimension $ n$ .

Some major properties of the Euclidean Space are:

A. $ d(\mathbf{x}, \mathbf{y}) \ge 0, \ \forall \mathbf{x}, \mathbf{y} \in \mathbb{R}^n$ .

B. $ d(\mathbf{x}, \mathbf{y}) =0 \iff \mathbf{x}=\mathbf{y}$ .

C. $ d(\mathbf{x}, \mathbf{y})=d(\mathbf{y}, \mathbf{x}) \ \forall \mathbf{x}, \mathbf{y} \in \mathbf{R}^n$ .

D. $ d(\mathbf{x}, \mathbf{y}) \le d(\mathbf{x}, \mathbf{z}) +d(\mathbf{z}, \mathbf{y}), \ \forall \mathbf{x}, \mathbf{y}, \mathbf{z} \in \mathbb{R}^n$ .

**Properties A, B and C are immediate consequences of the definition of $ d(\mathbf{x}, \mathbf{y}$ ). We shall now prove, property D, which is actually Triangle inequality.**

**Theorem:**Prove that $ d(\mathbf{x}, \mathbf{y}) \le d(\mathbf{x}, \mathbf{z}) +d(\mathbf{z}, \mathbf{y}), \ \forall \mathbf{x}, \mathbf{y}, \mathbf{z} \in \mathbf{R}^n$ .

From the definition of norm,

$ {||\mathbf{x}+\mathbf{y}||}^2= \displaystyle{\sum_{i=1}^n} {(x_i+y_i)}^2$

$ =\displaystyle{\sum_{i=1}^n} {x_i}^2+\displaystyle{\sum_{i=1}^n} {y_i}^2 +2 \displaystyle{\sum_{i=1}^n} {x_iy_i}$

$ \le \displaystyle{\sum_{i=1}^n} {x_i}^2+\displaystyle{\sum_{i=1}^n} {y_i}^2 +2 \sqrt{\displaystyle{\sum_{i=1}^n} {x_i}^2} \sqrt{\displaystyle{\sum_{i=1}^n} {y_i}^2}$ .

(Since $ \displaystyle{\sum_{i=1}^n} {x_iy_i} \le \sqrt{\displaystyle{\sum_{i=1}^n} {x_i}^2} \sqrt{\displaystyle{\sum_{i=1}^n} {y_i}^2}$ from Cauchy Schwartz Inequality).

We have

$ {||\mathbf{x}+\mathbf{y}||}^2 \le {\left(\sqrt{\displaystyle{\sum_{i=1}^n} {x_i}^2}+\sqrt{\displaystyle{\sum_{i=1}^n} {y_i}^2}\right)}^2$

or,

$ {||\mathbf{x}+\mathbf{y}||}^2 \le {\left({||\mathbf{x}||+||\mathbf{y}||}\right)}^2$ .

Or,

$ ||\mathbf{x}+\mathbf{y}||\le ||\mathbf{x}||+||\mathbf{y}||$ …(1)

Since equation (1) is true for all $x, y$, it should also be true for all $x-z$ and $z-y$ too.

Replacing $ \mathbf{x}$ and $ \mathbf{y}$ by $ \mathbf{x}-\mathbf{z}$ and $ \mathbf{z}-\mathbf{y}$ respectively, we obtain:

$ ||\mathbf{x}-\mathbf{y}||\le ||\mathbf{x}-\mathbf{z}||+||\mathbf{z}-\mathbf{y}||$

$ \iff d(\mathbf{x}, \mathbf{y}) \le d(\mathbf{x}, \mathbf{z}) +d(\mathbf{z}, \mathbf{y}), \ \forall \mathbf{x}, \mathbf{y}, \mathbf{z} \in \mathbb{R}^n$ (from the definition of norm).

Hi Gaurav. Nice post, I will include this in the next Math and Multimedia Carnival. By the way, if you can lower the level of your posts to high school level, I can invite to as a guest blogger.

Thanks Guillermo for the compliment! I usually write on basic topics in mathematics —however this is not the one. :)

Hi Gaurav. Nice post, I will include this in the next Math and Multimedia Carnival. By the way, if you can lower the level of your posts to high school level, I can invite to as a guest blogger.

Thanks Guillermo for the compliment! I usually write on basic topics in mathematics —however this is not the one. :)

I am greatly surprised, that how could you do this? Great post. I could only get that the longest side of a triangle is always less than the sum of other two sides

I am greatly surprised, that how could you do this? Great post. I could only get that the longest side of a triangle is always less than the sum of other two sides

very interesting post.

very interesting post.