# Absolute Difference

An Absolute Difference between two numbers is the Absolute Value of the subtraction between the two, i.e. [math]|A-B|[/math] .

**Example(s):**- [math]|3-5|= |-5|=5[/math]

**Counter-Example(s):**

**See:** Absolute Value, Number, Mean Deviation.

## References

### 2016

- (Wikipedia, 2016) ⇒ http://www.wikiwand.com/en/Absolute_difference Retrieved 2016-07-10
- The
**absolute difference**of two real numbers*x*,*y*is given by |*x*−*y*|, the absolute value of their difference. It describes the distance on the real line between the points corresponding to*x*and*y*. It is a special case of the L^{p}distance for all 1 ≤*p*≤ ∞ and is the standard metric used for both the set of rational numbers**Q**and their completion, the set of real numbers**R**.As with any metric, the metric properties hold:

- The

- |
*x*−*y*| ≥ 0, since absolute value is always non-negative. - |
*x*−*y*| = 0 if and only if*x*=*y*. - |
*x*−*y*| = |*y*−*x*| (*symmetry*or*commutativity*). - |
*x*−*z*| ≤ |*x*−*y*| + |*y*−*z*| (*triangle inequality*); in the case of the absolute ::difference, equality holds if and only if*x*≤*y*≤*z*.

- |
- By contrast, simple subtraction is not non-negative or commutative, but it does obey the second and fourth properties above, since
*x*−*y*= 0 if and only if*x*=*y*, and*x*−*z*= (*x*−*y*) + (*y*−*z*). - The absolute difference is used to define other quantities including the relative difference, the L
^{1}norm used in taxicab geometry, and graceful labelings in graph theory.When it is desirable to avoid the absolute value function – for example because it is expensive to compute, or because its derivative is not continuous – it can sometimes be eliminated by the identity

- |
*x*−*y*| < |*z*−*w*| if and only if (*x*−*y*)^{2}< (*z*−*w*)^{2}. - This follows since |
*x*−*y*|^{2}= (*x*−*y*)^{2}and squaring is monotonic on the nonnegative reals.

- (Eric W. Weisstein, 2016) ⇒ Weisstein, Eric W. "Absolute Difference." From MathWorld--A Wolfram Web Resource. http://mathworld.wolfram.com/AbsoluteDifference.html Retrieved 2016-07-10
- The absolute difference of two numbers [math]n_1[/math] and [math]n_2[/math] is [math]|n_1-n_2|[/math], where the minus sign denotes subtraction and |x| denotes the absolute value.

### 2008

- (Upton & Cook, 2008) ⇒ Graham Upton, and Ian Cook. (2008). “A Dictionary of Statistics, 2nd edition revised." Oxford University Press. ISBN:0199541450