Theorem – The triangle inequality

Contents
1. Theorem
2. Proof
3. Extension to a series of real numbers

Theorem

Let a,b\in{\mathbb{R}}. Then,

|a+b| \leq |a|+|b|

Proof

The following proof may seem a little ‘plucked out of thin air’, however it is actually a rather simple comparison of the two sides of the theorem above, but in reverse. This will be pointed out at the end of the proof.

Consider the statement, for any two real numbers a,b,

ab\leq |a||b|

Now, we have two cases. Firstly, either a>0, b>0 or a <0, b<0. In this case, we have equality, ie ab =|a||b|. The next case is that a>0, b<0. Then, we have ab<|a||b|. Since we have covered all possible cases, we have proven that ab\leq |a||b| is always true.

So, now,

\begin{aligned} ab\leq |a||b| &\Rightarrow 2ab\leq 2|a||b| \\ &\Rightarrow a^2 + b^2 + 2ab \leq a^2 +b^2 +2|a||b| \\ &\Rightarrow a^2 + b^2 + 2ab \leq |a|^2 +|b|^2 +2|a||b| \\ &\Rightarrow (a+b)^2 \leq (|a|+|b|)^2 \\ &\Rightarrow (|a+b|)^2 \leq (|a|+|b|)^2  \\ &\Rightarrow |a+b| \leq |a|+|b| \end{aligned}

Where in the last step we are only considering the positive square roots. Since we have proven that ab\leq |a||b| \Rightarrow |a+b| \leq |a|+|b| and that e positive square roots. Since we have proven that ab\leq |a||b| is always true, it must be the case that the consequent of the implication is also true.

The reason for us beginning by proving the statement ab\leq |a||b| should be clear by reading the proof in reverse. If you prove that |a+b| \leq |a|+|b|  \Rightarrow ab\leq |a||b|, then in order to prove the theorem, you would hope to show ab\leq |a||b| is always true. Then, proving the converse implication proves the theorem.

Extension to any finite subset of real numbers

Not only does the triangle inequality hold for just two elements of the reals, but also for any subset of the real numbers. More specifically, we have that

|x_1 + x_2 + ... + x_n| \leq |x_1| + |x_2| + ... + |x_n|

Where n is a natural number (and hence finite).

This follows by induction. For the base case, ie for two numbers, we have (the proven result),

|a+b| \leq |a|+|b|

Now, to prove the inductive step, assume the statement is true for some k\in\mathbb{R};

|x_1 + x_2 + ... + x_k| \leq |x_1| + |x_2| + ... + |x_k| .

We have that,

\begin{aligned} |x_1 + x_2 + ... + x_k| &\leq |x_1| + |x_2| + ... + |x_k| \\ \Rightarrow  |x_1 + x_2 + ... + x_k| + |x_{k+1}| &\leq |x_1| + |x_2| + ... + |x_k| + |x_{k+1}|\end{aligned}

Note that x_1 + x_2 + ... + x_k \in\mathbb{R} , which means that we may apply the base case to the the LHS of |x_1 + x_2 + ... + x_k| + |x_{k+1}| \leq |x_1| + |x_2| + ... + |x_k| + |x_{k+1}| , obtaining

\begin{aligned} |x_1 + x_2 + ... + x_k + x_{k+1}| &\leq |x_1 + x_2 + ... + x_k| + |x_{k+1}| \\ &\leq  |x_1| + |x_2| + ... + |x_k| + |x_{k+1}| ~\square\end{aligned}