If $f(x) = |x|+|x-5|$, then which of the following statements are TRUE?
(A) f is a continuous function every where
(B) f is a continuous function except x = 5 and x = 0
(C) f is a continuous function except x = 0 but not differentiable at x = 5
(D) f is a continuous function everywhere but not differentiable at x = 0 and x = 5
Choose the correct answer from the options given below:
Answer & explanation
Correct answer: option 3
The correct answer is Option (3) → (A) and (D) only
$\text{Given } f(x)=|x|+|x-5|$
$\text{Piecewise form: } f(x)=\begin{cases} 5-2x,& x<0\\ 5,& 0\le x<5\\ 2x-5,& x\ge 5 \end{cases}$
$\textbf{Continuity check}$
$\forall x\ne 0,5$: each branch is a polynomial $\Rightarrow$ continuous.
$x=0$: \ \ $f(0)=5$; \ $ \lim\limits_{x\to 0^-}f(x)=5-2(0)=5$; \ $ \lim\limits_{x\to 0^+}f(x)=5$ $\Rightarrow$ limits equal $=f(0)$ $\Rightarrow$ continuous at $0$.
$x=5$: \ \ $f(5)=2\cdot 5-5=5$; \ $ \lim\limits_{x\to 5^-}f(x)=5$; \ $ \lim\limits_{x\to 5^+}f(x)=2\cdot 5-5=5$ $\Rightarrow$ continuous at $5$.
$\Rightarrow f$ is continuous everywhere $\mathbb{R}$.
$\textbf{Differentiability check}$
$x<0:\ f'(x)=\frac{d}{dx}(5-2x)=-2$
$0
$x>5:\ f'(x)=\frac{d}{dx}(2x-5)=2$
$x=0:\ f'_{-}(0)=-2,\ \ f'_{+}(0)=0\ \Rightarrow\ f'\ \text{does not exist at }0$
$x=5:\ f'_{-}(5)=0,\ \ f'_{+}(5)=2\ \Rightarrow\ f'\ \text{does not exist at }5$
$\textbf{Conclusions about options}$
(A) True: $f$ continuous everywhere.
(B) False: contradicts continuity at $0$ and $5$.
(C) False: $f$ is continuous at $0$ and $5$, but not differentiable at both.
(D) True: continuous everywhere, not differentiable at $x=0$ and $x=5$.
Correct statements: (A) and (D)