Function with absolute value and parameters?

82 Views Asked by At

I need help with this exercise

Consider

$f(x)=||x|-a|$

$1)$Determine as $a\in \mathbb{R}$ varies the intervals in which $f(x)$ is continuous and the intervals in which $f(x)$ is differentiable

$2)$Determine the values of $a\in \mathbb{R}$ for which $f(x)$ has a local max and for which it has a local min. In both cases determine $f(x_{max})$ and $f(x_{min})$

What's the right way to solve this kind of exercises? I tried to split the situation in all the cases but there are many different possibilities and I get wrong results. Is there an easier way to do it?

Thanks a lot

1

There are 1 best solutions below

0
On BEST ANSWER

1) As $|x|\geq0$, if $a\leq0$ then $|x|-a$ would be $\geq 0$ and $a$ wouldn't make any effect. Therefore $a > 0$.

2) If $a > 0$, then local minima and maxima would happen when $|x|-a=0$. If you draw the graph, you'll find that $x_{max}=0$ and $x_{min}=\pm a$, $f(x_{max})=a$ and $f(x_{min})=0$.