Does there exist a function which is continuous everywhere but not differentiable at exactly two points? Justify your answer.

Vedclass pdf generator app on play store
Vedclass iOS app on app store
(A) Consider the function $f(x) = |x| + |x - 1|$.
Since the modulus function is continuous everywhere and the sum of two continuous functions is also continuous,$f(x)$ is continuous for all $x \in \mathbb{R}$.
To check the differentiability of $f(x)$,we examine the points where the expression inside the modulus changes sign,which are $x = 0$ and $x = 1$.
At $x = 0$:
Left-hand derivative $(LHD)$ $= \lim_{x \to 0^-} \frac{f(x) - f(0)}{x - 0} = \lim_{x \to 0^-} \frac{(|x| + |x - 1|) - 1}{x} = \lim_{x \to 0^-} \frac{(-x - x + 1) - 1}{x} = \lim_{x \to 0^-} \frac{-2x}{x} = -2$.
Right-hand derivative $(RHD)$ $= \lim_{x \to 0^+} \frac{f(x) - f(0)}{x - 0} = \lim_{x \to 0^+} \frac{(|x| + |x - 1|) - 1}{x} = \lim_{x \to 0^+} \frac{(x - x + 1) - 1}{x} = \lim_{x \to 0^+} \frac{0}{x} = 0$.
Since $LHD \neq RHD$,$f(x)$ is not differentiable at $x = 0$.
At $x = 1$:
$LHD$ $= \lim_{x \to 1^-} \frac{f(x) - f(1)}{x - 1} = \lim_{x \to 1^-} \frac{(|x| + |x - 1|) - 1}{x - 1} = \lim_{x \to 1^-} \frac{(x - x + 1) - 1}{x - 1} = \lim_{x \to 1^-} \frac{0}{x - 1} = 0$.
$RHD$ $= \lim_{x \to 1^+} \frac{f(x) - f(1)}{x - 1} = \lim_{x \to 1^+} \frac{(|x| + |x - 1|) - 1}{x - 1} = \lim_{x \to 1^+} \frac{(x + x - 1) - 1}{x - 1} = \lim_{x \to 1^+} \frac{2x - 2}{x - 1} = 2$.
Since $LHD \neq RHD$,$f(x)$ is not differentiable at $x = 1$.
Thus,$f(x) = |x| + |x - 1|$ is continuous everywhere but not differentiable at exactly two points,$x = 0$ and $x = 1$.

Explore More

Similar Questions

The function $f(x) = \max \{(1 - x), (1 + x), 2\},$ $x \in ( - \infty , \infty ),$ is

If $f(x) = \begin{cases} x^2 + 3x + a, & x \leq 1 \\ bx + 2, & x > 1 \end{cases}$ is everywhere differentiable,then:

Assertion $(A)$: $f(x) = |x|$ is differentiable at $x = a \neq 0$ and continuous but not differentiable at $x = 0$.
Reason $(R)$: If a function is differentiable at a point,then it is continuous at the point. But the converse is not true.

Which of the following functions is differentiable at $x = 0$?

If $f(x) = a|\sin x| + be^{|x|} + c|x|^3$,where $a, b, c \in \mathbb{R}$,is differentiable at $x = 0$,then:

Vedclass Products

For Students

Vedclass Test Series

Mock tests in real JEE/NEET style with performance analysis. 5-day free trial.

Start Free Trial
For Teachers

Exam Paper Generator

Generate Set A/B/C/D exam papers from 7.5L+ questions in 2 minutes. 3 chapters free.

Try Free
For Institutes

Online Exam Module

Live online exams with unlimited students, 360° analytics & white-label branding.

See Demo