4

I came across a very basic absolute value question

$|x+2| + |x-3| =5.$

Initially, I thought the answer was $x=-2$ and $x=3$ because I let each absolute values be either positive and negative and that's what you get.

But the correct answer was an inequality; $-2\le x \le 3.$ Now, If you try subbing values in or solve it graphically, this inequality is correct.

But how am I supposed to know if the solution is to be an inequality or equality? Is there anyway to tell by looking at the expression?

Thanks,

Charlie
  • 43
  • Intuitively, in that range increasing x will add stuff to one term and remove stuff from the other. – djechlin Aug 30 '14 at 02:09
  • Note if 5 were slightly different, this wouldn't happen at all. The problem is set up so there are infinitely many solutions instead of finitely many. – djechlin Aug 30 '14 at 02:10
  • Rather similar question: http://math.stackexchange.com/questions/153818/solving-x-2-x-5-3 – Martin Sleziak Aug 30 '14 at 08:50
  • I voted to close as a duplicate, since both questions are about equations of the form $|x-a|+|x-b|=b-a$ where $a$, $b$ are some real numbers so they are basically the same. See also discussion in chat. – Martin Sleziak Aug 30 '14 at 11:51

5 Answers5

5

Methodology/ Algorithm:

You start by checking when the expressions within the absolute value signs are positive or negative. This is because according to the definition of $|f(x)| = f(x)$ when $f(x) \ge 0$ and $|f(x)| = - f(x)$ when $f(x) \lt 0$. So first differentiate when the expressions will change signs.

Then you will arrive at a number of points where the expressions change signs. Here since you have two expressions inside absolute value signs you will have two such points. Divide the real line at these points and solve the resulting equations subject to the inequality which arises from restricting $x$ to a portion of the real line.

For an example, here the line will be split at $x = -2$ and $x = 3$. So suppose, $-2 \le x \lt3 $ then, the resulting equation , due to the inequality is,

$$ x + 2 - (x - 3) = 5 \iff 5 = 5 $$

This means the equality is satisfied for every $x$ in the given interval. Now check the other regions, namely $x \ge 3$ and $x \lt -2$ and solve the equation within this regions and you will find the equality is not satisfied for any $x$ in the stipulated conditions.

Ishfaaq
  • 10,034
  • 2
  • 30
  • 57
  • So you are saying that the only way to know if it is an inequality or not is by trial and error? i.e. testing the points within and outside the 2 values? – Charlie Aug 30 '14 at 02:40
  • 1
    Never said it was the only way. For example, some equations can be squared and solved. But this is not a trial and error method. Try drawing the graph of the function $f(x) = |x + 2| + |x + 3| - 5$ you will see that its like three distinct straight lines in the given regions. What we've done is solve those straight lines separately. – Ishfaaq Aug 30 '14 at 02:44
3

For a more intuitive approach, plotting a graph of $|x+2|$ and $|x-3|$ would help. These are two V-shaped graphs of $\pm45^o $ gradient, touching the x-axis at $-2$ and $3$ respectively.

Then you can clearly see that for $-2\leq x\leq3$, the graphs are $$\begin{align} &y_1&&=\ \ \ x+2\\ &y_2=-(x-3)&&=-x+3\end{align}$$

giving $y_1+y_2=5$.

Thus the solution to $|x+2|+|x-3|=5$ is $-2\leq x\leq3$.

2

The triangle inequality states that for $x,y,z \in \mathbb{R}$, we have $|x-y|+|x-z| \le |y-z|$ with equality occurring if and only if $x$ is in between $y$ and $z$ inclusive. Apply that here for $y = -2$ and $z = 3$.

JimmyK4542
  • 54,331
2

A useful fact in absolute value equations: $|a| + |b| = |a -b| \implies ab \le 0$.

If we apply the above result here, then we are left with $(x+2)(x-3)\le 0$, the solution set to which is $x \in \left[-2,3\right]$.

P.K.
  • 7,742
0

just consider all the following 5 cases:

1) $ x+2>0 $ and $ x-3>0$

2) $ x+2>0 $ and $ x-3<0$

3) $ x+2<0 $ and $ x-3>0$

4) $ x+2<0 $ and $ x-3<0$

5) $ x+2=0 $ and $ x-3=0$