[Math] Prove the following function is differentiable

analysisderivativesfunctionsmultivariable-calculusreal-analysis

I have to prove if this function is differentiable.

$$f(x,y)= \begin{cases} (x^2+y^2) \sin\frac 1{(x^2+y^2)} \iff (x,y) \neq (0,0) \\0 \iff (x,y)=(0,0) \end{cases}$$

I tried proving that all of its partial derivatives are continuous in (0,0). However,

$$f_x(x,y)= \begin{cases} \frac {-2x}{(x^2+y^2)} \cos\frac 1{(x^2+y^2)}+2x\sin\frac 1{(x^2+y^2)} \iff (x,y) \neq (0,0) \\0 \iff (x,y)=(0,0) \end{cases}$$

Which is, I think, actually not continuous in (0,0), so this approach didn't work. What would you suggest for proving $f$ is differentiable?

I've tried using the definition of differentiability. Is it enough to say that $\nabla(0,0)=(0,0)$ since

$$
\lim_{\mathbf{h\to 0}} \frac{\mathbf{f(0+h)-f(0)-(0,0)h}}{||\mathbf{h}||} =\lim_{\mathbf{h\to 0}} \frac{\mathbf{f(h)}}{||\mathbf{h}||} =\mathbf{0}
$$

What do you think?

Best Answer

The continuity of the partial derivatives $f_x$, $f_y$ at $(x_0,y_0)$is a sufficient, but not a necessary condition for differentiability of $f$ at $(x_0,y_0)$.

In your example both $f_x$ and $f_y$ are continuous on the open set $\dot{\mathbb R}^2:={\mathbb R}^2\setminus\{(0,0)\}$; whence $f$ is differentiable at all points of $\dot{\mathbb R}^2$.

It remains to test the point ${\bf 0}:=(0,0)$. According to the definition of $f$ we have $$f({\bf 0}+{\bf h})-f({\bf 0})=|{\bf h}|^2\sin{1\over |{\bf h}|^2}\qquad({\bf h}\ne{\bf 0})$$ and therefore $${f({\bf 0}+{\bf h})-f({\bf 0})-{\bf 0}\cdot{\bf h}\over|{\bf h}|}=|{\bf h}|\sin{1\over |{\bf h}|^2}\to{\bf 0}\qquad({\bf h}\to{\bf 0})\ .\tag{1}$$

Here $\cdot$ denotes the scalar product in ${\mathbb R}^2$. The last formula proves $df({\bf 0})=0$, and a fortiori $\nabla f({\bf 0})={\bf 0}$. It follows that $f$ is differentiable on all of ${\mathbb R}^2$.

Note that computing $f_x(0,0)=f_y(0,0)=0$ does not suffice. We need a formula of type $(1)$ to assure differentiability at ${\bf 0}$.

Related Question