2
$\begingroup$

I'm not sure how to express this function in piecewise form without using absolute values:

$$ f(x) = 3|x-2| - |x+1|$$

I know how to do it when there is just one absolute value, such as:

$$g(x) = 3+|2x-5|$$

$$ g(x)= \begin{cases} 2x-2& \text{; }x\ge\frac52\\ 8-2x&\text{; }x<\frac52 \end{cases} $$

To express $g(x)$ in piecewise form, I made 2 cases. Case 1 positive and Case 2 negative.

But I can't exactly do that for this problem [$f(x)$]... Could someone tell me how to proceed?

EDIT: Thank you for all the help!

$\endgroup$
1
  • $\begingroup$ I would first find where the function is $0$ $\endgroup$ Commented Aug 21, 2014 at 0:16

2 Answers 2

5
$\begingroup$

The only places where we need to break the function into "pieces" are those points where the expression inside each absolute value becomes zero. This occurs at $x = -1$ and $x = 2$.

Accordingly, we consider what the function looks like on each of the intervals $(-\infty,-1)$, $(-1,2)$, and $(2,\infty)$.

For $x < -1$, we have $x + 1 < 0$ and so $|x+1| = -(x+1)$. Similarly, $x - 2 < x + 1 < 0$ and so $|x-2| = -(x-2)$. So on the interval $(-\infty,-1)$ the function can be simplified as $f(x) = -3(x-2) +(x+1) = -2x+7$.

Thus far, we have established

$$f(x) = \begin{cases} -2x + 7 & \text{if }x < -1 \\ ??? & \text{if }-1 \leq x \leq 2 \\ ??? & \text{if }x > 2 \\ \end{cases}$$

You can handle the other intervals in exactly the same way.

$\endgroup$
7
  • $\begingroup$ Fixed my sign error, sorry about that. $\endgroup$ Commented Aug 21, 2014 at 0:19
  • 1
    $\begingroup$ Ah, I get it, thanks! So would the answer be this? $$ f(x)= \begin{cases} -2x+5& \text{if }x<-1\\ -4x+5&\text{if }-1\le x\le2\\2x-7&\text{if }x>2 \end{cases} $$ $\endgroup$ Commented Aug 21, 2014 at 0:31
  • $\begingroup$ Actually, it seems that there is a miscalculation... Wouldn't the first piece be $-2x+7$ instead of $-2x+5$ ? Or am I wrong? $\endgroup$ Commented Aug 21, 2014 at 0:42
  • $\begingroup$ @precalculusANON: Looks good to me! One more thing I will mention: note that it doesn't matter where we put the $\leq$ since the $f$ is continuous (because it is the sum of two continuous functions). So we could equally well make the intervals $x \leq -1$, $-1 < x < 2$, and $x \geq 2$ if we were so inclined. $\endgroup$ Commented Aug 21, 2014 at 0:42
  • 1
    $\begingroup$ @HananN. In this case, it doesn't make a difference. You could make the first interval $x \leq 1$ and the second interval $1 < x \leq 2$ if you prefer. The reason this is OK is because $f$ is a continuous function, so when you express it piecewise, the first and second formulas must have the same value at $x=-1$, and similarly, the second and third formulas must have the same value at $x=2$. $\endgroup$ Commented Feb 12, 2016 at 19:46
1
$\begingroup$

Try expressing each of the parts - $3|x-2|$ and $|x+1|$ in piecewise form first. This tells you where the behaviour of the function is going to change: at $x=-1$ and $x=2$. So you have three intervals to look at: $\{x < -1\}$, $\{-1 \le x \lt 2\}$ and $\{x \ge 2\}$. Then all you have to do is see how the two functions combine in each of those regions.

$\endgroup$
2
  • $\begingroup$ How do you know when the interval include $\leq or \geq$ sign? in other words why in the first interval its $x < -1$ and in the second is $-1 \leq x \leq 2$ ? $\endgroup$ Commented Feb 12, 2016 at 10:59
  • $\begingroup$ Since |0| = |-0| = 0, you can include that point on either interval. I chose to use intervals that are closed on the left, but you could do it the other way (or mix them up, although I like having a consistent, if arbitrary, choice). $\endgroup$ Commented Feb 14, 2016 at 23:57

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.