# Absolute value problem $|x-y|=|y-x|$

My question is from Apostol's Vol. 1 One-variable calculus with introduction to linear algebra textbook.

Page 43. Problem 1 Prove each of the following properties of absolute values.

(c) $|x-y|=|y-x|$.

The attempt at a solution: I solved similar problem, which was this: $|x|-|y|\le|x-y|$, by manipulating triangle inequality, I guess this one might be similar but I don't see it. Please help.

So far I have proven following properties:

$|x|=0$ if and only if $x=0$.

$|-x|=|x|$.

Also, absolute value is defined in such way: If $x$ is a real number, the absolute value of $x$ is a nonnegative real number denoted by $|x|$ and defined as follows: $|x|=\begin{cases} x, & \text{if$x\ge0$,} \\ -x, & \text{if$x\le0$.} \end{cases}$.

• If you've shown that the absolute value is multiplicative, then you could say $|x-y|=|(-1)(y-x)|=|-1||y-x|=|y-x$. Oct 26 '14 at 13:31
• No, I have not done that yet, that's (f) part of problem 1. Oct 26 '14 at 13:33
• it might be helpful to include the properties you have proven, including, for example, how you're defining the absolute value (i.e. as either the square root of the square, or as a piecewise function, although these are clearly equivalent) Oct 26 '14 at 13:34
• @Hayden Yes, Sorry for not being clear, I listed all that now. Oct 26 '14 at 13:42

$$|x-y|=|x-y|$$ $$|x-y|=|1|\cdot|x-y|$$ $$|x-y|=|-1|\cdot|x-y|$$ $$|x-y|=|-1\cdot(x-y)|$$ $$|x-y|=|y-x|$$

Without $|x||y|=|xy|$

If $x>y$
Since $y-x<0$ that means $|y-x|=-(y-x)=x-y$ $$|y-x|=x-y$$ Since $x-y>0$ that means $|x-y|=x-y$ $$|x-y|=x-y$$ Equality is transitive $$|x-y|=|y-x|$$

If $y>x$
Since $x-y<0$ that means $|x-y|=-(x-y)=y-x$ $$|x-y|=y-x$$ Since $y-x>0$ that means $|y-x|=y-x$ $$|y-x|=y-x$$ Equality is transitive $$|x-y|=|y-x|$$

The case of $x=y$ is left as an exercise for the reader.

• I have not proven property $|xy|=|x||y|$ yet, so is there any other way to achieve the result? Oct 26 '14 at 13:36
• @GeorgeDirac Look at my edit Oct 26 '14 at 13:45

You say that you have proven that $|x|=|-x|$, then it immediately follows that

$$|x-y| = |-(x-y)| =|-x+y| = |y-x|.$$

• Yeah, thats true. Well I feel stupid now, that I didn't think of that, thanks for simple explanation. Oct 26 '14 at 13:54
• @GeorgeDirac You're welcome :-)
– Eff
Oct 26 '14 at 13:56