# Partial derivative isn't continuous

I would like verification on a calculation that shows $f$ below is differentiable at $(0,0)$ but $f_x$ is not continuous at $(0,0)$.

$$f(x,y)=(x^2+y^2)\sin(\frac{1}{x^2+y^2})$$

when $(x,y)\neq (0,0)$ and $f(0,0)=0$.

So assuming for the moment that the function is differentiable at $(0,0)$ (it is), this shows that $f_x(0,0)$ exists. In fact, it is easy to see $f_x(0,0)=0$ by applying the definition of the derivative and using the squeeze theorem. Then by standard computation we get that away from the origin $$f_x(x,y)=2x\left(\sin\left(\frac{1}{x^2+y^2}\right)-\frac{\cos\left(\frac{1}{x^2+y^2}\right)}{x^2+y^2}\right)$$

Here is where I'm a little fuzzy.... I found that $\lim_{(x,0)\to (0,0)} f_x=0$ and so this isn't helpful. I need to find a path that makes the limit not equal to zero, right? What if I find a path where the limit doesn't exist? Is this enough? I have a result that says

$$\lim_{(x,y)\to(0,0)}g(x,y)=\lim_{r\to 0^+} g(r\cos\theta,r\sin\theta)$$

I guess I prefer working in these coordinates because then I don't have to worry about the path. I computed the following

$$\lim_{r\to 0^+} f_x(r,\theta)=2r\cos\theta\left(\sin(r^{-2})-r^{-2}\cos(r^{-2})\right)$$

Where $2r\cos\theta\sin(\frac{1}{r^2})\to0$ by the squeeze theorem and the second term's limit does not exist (right?) So I have two questions:

1) Does this prove that $f_x$ is not continuous since this limit does not exist? Or should I work in Cartesian coordinates and find a path that shows the limit depends on the path.

2) Can I always do this switch to polar coordinates (where the above centred equation holds true)? Does there need to be polar symmetry? I don't believe this function has polar symmetry.

• Actually...... it now seems that $\lim_{(x,0)\to (0,0)} f_x$ DNE but that is beside the point. I don't really see a need to edit the question. Dec 18, 2016 at 7:15
• The continuity of first partial derivatives isn't required for a function to be differentiable: it is enough all but one of them is continuous to get differentiability, though. Anyway, if you choose a way in some kind of coordinates where the function's defined and you get the limit you want doesn't exist this is enough to deduce the limit doesn't exist and thus the function isn't continuous there and yes: you can always switch to polar coord., observing the above. Dec 18, 2016 at 7:32
• Thank you. I can easily see that the function is differentiable btw because $\Delta z=f(\Delta x,\Delta y)-f(0,0)=f_x(0,0)\Delta x +f_y(0,0)\Delta y+\varepsilon_1 \Delta x+\varepsilon_2\Delta y$ where $\varepsilon_i$ are tending to zero as $(\Delta x,\Delta y)\to (0,0)$ ( and, in this case, $f_x(0,0)=f_y(0,0)=0$). Dec 18, 2016 at 7:38

However you could have stayed in Cartesian coordinate. Taking the path $x=y$, you would have seen directly that $f_x$ is not continuous at $(0,0)$ with the same argument than the one you used in polar coordinate.