Absolute Value
It is frequently desirable to measure how large a quantity is, regardless of its sign. In such cases, we use merely the absolute value of the quantity.
The absolute value (or modulus) of a real number $x$, is a nonnegative real number denoted by $|x|$, and defined as follows
$ |x|=\begin{cases} x & \text{if }x>0\\ 0 & \text{if }x=0\\ -x & \text{if }x<0 \end{cases} $- Geometrically the absolute value of a number $x$ is its distance from 0 regardless of the direction.
Find $|2|,|-2|,|0|,|3-\sqrt{3}|,|\sqrt{3}-3|$
Solution
Because $2,0,3-\sqrt{3}$ are nonnegative [$\sqrt{3}\approx1.73$, so $3-\sqrt{3}\approx1.27$], we have $ |2|=2,\ |0|=0,\ |3-\sqrt{3}|=3-\sqrt{3} $ but $-2$ and $\sqrt{3}-3$ are negative, so we have $ |-2|=-(-2)=2,\quad|\sqrt{3}-3|=-(\sqrt{3}-3)=3-\sqrt{3}. $- In computer languages and mathematical packages, the absolute value of $x$ is often denoted by
abs(x). - We have by definition:$ -|x|\leq x\leq|x| $because if $x>0$, then $|x|=x$ and we have the sign of equality on the right and the sign of inequality on the left (a positive number is larger than a negative one). If $x<0$, then $|x|=-x$, and we have the sign of equality on the left and the sign of inequality on the right.
[Note that $a\leq b$ means $a<b$ or $a=b$]
From the above definition, it follows that for every real numbers $a$ and $b$ we have:
- $|a|\geq0$
- $|a|=0$ if and only if $a=0$
- $||a||=|a|$ (because $|a|\ge0$)
- $|-a|=|a|$.
- $|ab|=|a|\ |b|$.
- $\left|\dfrac{a}{b}\right|=\dfrac{|a|}{|b|}$ (provided $b\neq0$)
- If $r>0$
Geometric Interpretation
Let $r>0$ and $ |x|\leq r. $ The above relationship implies that $x$ is nearer to 0 than $r$, and you can see from the following figure that this is possible if and only if $x$ lies between $-r$ and $r$: $ -r\leq x\leq r. $![Number line showing that |x| ≤ r means x lies between −r and r, with the interval [−r, r] highlighted and |x| marked as the distance from 0 to x.](https://adaptivebooks.org/book-images/precalculus/Ch0-AbsoluteValue-Equivalence.png)
- $|a+b|\leq|a|+|b|$ (known as triangle inequality)
- If $a$ and $b$ are either both positive, both negative, or at least one of them is zero, then $|a+b|=|a|+|b|$. Otherwise, when $a$ and $b$ have opposite signs, $|a+b|<|a|+|b|$.
Proof of the triangle inequality
We know $ -|a|\leq a\leq|a| $ and $ -|b|\leq b\leq|b|. $ Adding two inequalities we obtain $ -(|a|+|b|)\leq a+b\leq|a|+|b|. $ Let $c=|a|+|b|$ and $x=a+b$. Because $-c\leq x\leq c$, it follows from (1) that $|x|\leq c$ or $ |x|=|a+b|\leq|a|+|b|. $ This is what we were trying to prove. $\square$Show that
$ \boxed{|a| - |b| \leq |a+b| \leq |a| + |b|.} $Solution
This result follows from the triangle inequality and the fact that \( |-b| = |b| \) (Property 4). Using the triangle inequality, we have: $ |a| = |(a+b) - b| \leq |a+b| + |-b| = |a+b| + |b|. $ By subtracting \(|b|\) from both sides of the inequality, we obtain: $ |a| - |b| \leq |a+b|. $ Combining the above inequality with the standard triangle inequality \( |a+b| \leq |a| + |b| \), we conclude that: $ |a| - |b| \leq |a+b| \leq |a| + |b|. $Prove that for all real number $a$ and $b$, we have
$ |a-b|\leq|a|+|b| $Solution
This follows directly from the triangle inequality and the fact that \( |-b| = |b| \). Applying the triangle inequality to \( a + (-b) \), we get: $ |a-b| = |a + (-b)| \leq |a| + |-b| = |a| + |b|. $ Thus, \( |a-b| \leq |a| + |b| \) holds for all real numbers \(a\) and \(b\).Prove that for all real numbers \(a\) and \(b\),
$ |a| - |b| \leq |a-b|. $Solution
We start by adding and subtracting \(b\) and then applying the triangle inequality. Specifically: $ |a| = |(a-b) + b| \leq |a-b| + |b|. $ Subtracting \(|b|\) from both sides gives: $ |a| - |b| \leq |a-b|. $ Thus, the inequality \( |a| - |b| \leq |a-b| \) holds for all real numbers \(a\) and \(b\).It follows from (4) that
- $|a-b|=|b-a|$
Distance Between Points on the Real Line
Look at the following figure. The distance between $-2$ and $10$ is $12$ units. The distance can be calculated as the difference \( 10 - (-2) \), which involves subtracting the smaller value from the larger one. However, since the absolute value of \( 10 - (-2) \) equals \( |12| = 12 \), and similarly, \( |-2 - 10| = |-12| = 12 \), we can use the absolute value function to find the distance between two points without worrying about which number is larger or smaller.

If \( P \) and \( Q \) are two points located on a number line with coordinates \( a \) and \( b \), the distance between \( P \) and \( Q \), denoted by \( d(P, Q) \), is calculated as:
$ d(P, Q) = |b - a| $Since \( |b - a| \) is the same as \( |a - b| \), it follows that the distance from \( P \) to \( Q \) is equal to the distance from \( Q \) to \( P \):
$d(P,Q)=d(Q,P).$
It follows from Equation (ii) that for any real number $a$ and any positive number $r$,
$ |x-a|<r $
is equivalent to
$ -r<x-a<r $
or
$ a-r<x<a+r \tag{add $r$ to each side} $
This means that the distance of $x$ from $a$ is less than $r$ if and only if $x$ is between $a-r$ and $a+r$.

Find the set $I$, if it consists of all points whose distance from the point 2 is less than 0.6.
Solution
As discussed above $\begin{aligned} I & =\{x|\ |x-2|<0.6\} & =\{x|\ -0.6<x-2<0.6\} & =\{x|\ 2-0.6<x<2+0.6\} & =\{x|\ 1.4<x<2.6\} \end{aligned}$ This set is graphed in the following figure.
Neighborhoods
Let $I$ be the set of all points whose distance from a fixed point $a$ is less than a number $\delta>0$. Then
$ \begin{aligned} I & =\{x|\ |x-a|<\delta\}\\ & =\{x|\ -\delta<x-a<\delta\} &&(|t|<c\Leftrightarrow-c<t<c)\\ & =\{x|\ a-\delta<x<a+\delta\} &&(\text{add }a) \end{aligned} $
Such a set is called a neighborhood (or more precisely the $\delta$-neighborhood) of $a$ and $\delta$ is called the radius of the neighborhood. {The $\delta$-neighborhood of $a$ is shown in the following figure.}

Now let's consider the set of all points such that
$ 0<|x-a|<\delta $
or
$ J=\{x|\ 0<|x-a|<\delta\} $
Here we have two inequalities
$ 0<|x-a|\quad\text{and}\quad|x-a|<\delta $
Recall that the absolute value is always nonnegative (that is $0\le|t-a|$ for all $t$) , so
$ 0<|x-a| $
means
$ |x-a|\neq0 $
or equivalently
$ x\neq a $
[Recall that $|t|=0$ if and only if $t=0$]. Therefore,
$\begin{aligned} J & =\{x|\quad0<|x-a|<\delta\} & =\{x|\ |x-a|<\delta\quad\text{and}\quad x\neq a\} \end{aligned}$
That is $J$ is the $\delta$-neighborhood of $a$ with the midpoint $a$ removed. The set $J$ is called the deleted neighborhood or punctured neighborhood of $a$. The deleted $\delta$-neighborhood of $a$ is shown in the following figure.
