Why isn't equality in the triangle equality true when $x = y$?

209 Views Asked by At

So for the triangle inequality, I say the equality holds if and only if $x = y$.

Proof:

$|x+y| = |x|+|y|$

$|x+x| = |x|+|x|$

$|2x| = 2|x|$

$|2x| = |2x|$

Q.E.D.

Why is this incorrect, and that the equality only holds true when both the signs are the same or one of the number equals $0$ ? Thanks.

2

There are 2 best solutions below

3
On BEST ANSWER

Check $$|3+2|= |3|+|2|$$

The equality holds with $x$ and $y$ not being equal.

So it is not if and only if statement, but if $x=y$, then we have $$|x+y|= |x|+|y|$$ as you have indicated.

0
On

If these are real numbers and $|\cdot |$ is the usual absolute value, then $$\begin{aligned} & |x+y| = |x| + |y| \\ & \iff |x+y|^2 = (|x| + |y|)^2 \\ & \iff x^2 + 2xy + y^2 = x^2 + 2|xy| + y^2 \\ & \iff xy = |xy| \\ & \iff xy \geq 0 \end{aligned}$$ which holds if and only if $x$ and $y$ have the same sign or either is zero.