# differentiability-continuity of derivatives

I am trying to come up with a function $g:\mathbb{R}^{2} \to\mathbb{R}$ which is differentiable at each point $(x,y)$ in $\mathbb{R}^{2}$ but whose partial derivatives are not continuous at $(0,0)$. Can anyone give me examples of such functions?

-

From Counterexamples in Analysis, Gelbaum and Olmsted , page 119 $$f(x,y)=\cases{ x^2\sin(1/x)+y^2\sin(1/y),&xy \ne 0\cr x^2\sin(1/x), &x \ne 0, y=0 \cr y^2\sin(1/y), &x=0, y\ne0 \cr 0,&x=y=0 }$$
I believe, but haven't proved, that if you take the graph of $$g(x)=\cases{x^2\sin(1/x), &x\ne0 \cr 0,&x=0 }$$ in the $x$-$z$-plane and "spin the right half of it about" the $z$-axis, you'll obtain an example of the function you want. At any rate, this captures the flavor of the Gelbaum and Olmsted example (but would be harder to work with).
Note that $$g'(x)=\cases{2x\sin(1/x)-\cos(1/x),&x\ne0\cr0,&x=0 };$$ so, $g'$ is discontinuous at $x=0$.
$\ \ \color{darkgreen}{z= g(x)},\quad \color{maroon}{z=x^2},\quad\color{darkblue}{z=-x^2}$