# Triangle Inequality/Real Numbers

## Theorem

Let $x, y \in \R$ be real numbers.

Let $\size x$ denote the absolute value of $x$.

Then:

$\size {x + y} \le \size x + \size y$

## Proof 1

 $\displaystyle \size {x + y}^2$ $=$ $\displaystyle \paren {x + y}^2$ $\displaystyle$ $=$ $\displaystyle x^2 + 2 x y + y^2$ $\displaystyle$ $=$ $\displaystyle \size x^2 + 2 x y + \size y^2$ $\displaystyle$ $\le$ $\displaystyle \size x^2 + 2 \size {x y} + \size y^2$ Negative of Absolute Value‎ $\displaystyle$ $=$ $\displaystyle \size x^2 + 2 \size x \cdot \size y + \size y^2$ Absolute Value Function is Completely Multiplicative $\displaystyle$ $=$ $\displaystyle \paren {\size x + \size y}^2$
$\size {x + y} \le \size x + y$

$\blacksquare$

## Proof 2

This can be seen to be a special case of Minkowski's Inequality, with $n = 1$.

$\blacksquare$

## Proof 3

We have that Real Numbers form Ordered Integral Domain.

Therefore Sum of Absolute Values on Ordered Integral Domain applies directly.

$\blacksquare$

## Proof 4

We do a case analysis.

### $(1): \quad x \ge 0, y \ge 0$

 $\displaystyle x$ $\ge$ $\displaystyle 0$ $\displaystyle y$ $\ge$ $\displaystyle 0$ $\displaystyle \leadsto \ \$ $\displaystyle \size {x + y}$ $=$ $\displaystyle x + y$ $\displaystyle$ $=$ $\displaystyle \size x + \size y$

$\Box$

### $(2): \quad x \le 0, y \le 0$

 $\displaystyle x$ $\le$ $\displaystyle 0$ $\displaystyle y$ $\le$ $\displaystyle 0$ $\displaystyle \leadsto \ \$ $\displaystyle \size {x + y}$ $=$ $\displaystyle -x - y$ $\displaystyle$ $=$ $\displaystyle \size x + \size y$

$\Box$

### $(3): \quad x \ge 0, y \le 0$

We have that $\size x = x$ and $\size y = -y$.

In this case we show:

$\size {x + y} \le \max \set {\size x, \size y}$

Let $\size x \le \size y$.

Then:

 $\displaystyle x$ $\le$ $\displaystyle -y$ $\displaystyle \leadsto \ \$ $\displaystyle y$ $\le$ $\displaystyle y + x$ as $x \ge 0$ $\displaystyle$ $\le$ $\displaystyle 0$ $\displaystyle \leadsto \ \$ $\displaystyle \size {x + y}$ $=$ $\displaystyle -\paren {x + y}$ $\displaystyle$ $\le$ $\displaystyle -y$ $\displaystyle$ $=$ $\displaystyle \size y$

Let $\size x \ge \size y$.

Then:

 $\displaystyle x$ $\ge$ $\displaystyle -y$ $\displaystyle \leadsto \ \$ $\displaystyle x$ $\ge$ $\displaystyle x + y$ as $y \le 0$ $\displaystyle$ $\ge$ $\displaystyle 0$ $\displaystyle \leadsto \ \$ $\displaystyle \size {x + y} =$ $=$ $\displaystyle x + y$ $\displaystyle$ $\le$ $\displaystyle x$ $\displaystyle$ $=$ $\displaystyle \size x$

We have $\max \set {a, b} \le a + b$ for positive real numbers $a$ and $b$.

The result follows by taking $a = \size x$ and $b = \size y$.

$\Box$

### $(4): \quad x \le 0, y \ge 0$

Follows by symmetry from the case $(3)$.

$\blacksquare$

## Examples

### Example: $\size {-1 + 3}$

$2 = \size {-1 + 3} \le \size {-1} + \size 3 = 1 + 3 = 4$