Continuity and differentiability of a composite function Let $
     f(x,y)=\left\{\begin{array}{ll} x^2, & y >0 \\
         0, & y=0\\
   -x^2, & y<0  \end{array}  \right .
  $
I've got to check out whether $f(x,y)$ is continous and differentiable at $(0,0)$.
By limit definition, I've got:
$\displaystyle \lim_{(x,y) \to (0,0)}f(x,y)=\displaystyle \lim_{(x,y) \to (0,0)}x^2=0$ if $y>0$,
and $\displaystyle \lim_{(x,y) \to (0,0)}f(x,y)=\displaystyle \lim_{(x,y) \to (0,0)}-x^2=0$ if $y>0$ 
or $\displaystyle \lim_{(x,y) \to (0,0)}|f(x,y)-f(0,0)|=\lim_{(x,y) \to (0,0)}|x^2|=\lim_{(x,y) \to (0,0)}|-x^2|=0$.
So, as the  differential $df(0,0)=0$, we check out:
$\displaystyle\lim_{(x,y) \to (0,0)}|\frac{f(x,y)-f(0,0)}{\sqrt{x^2+y^2}}|\leq\displaystyle\lim_{(x,y) \to (0,0)}\frac{x^2}{\sqrt{x^2+y^2}}\leq \displaystyle\lim_{(x,y) \to (0,0)} \frac {x^2}{\sqrt{x^2}}=\displaystyle\lim_{(x,y) \to (0,0)}x=0$, so this function is differentiable. 
Are these arguments correct and enough to show everything?
 A: For checking the continuity condition you can use polar coordinates (it works well for some problems) so that the limit 
$$\lim\limits_{(x,y)\rightarrow (0,0)}f(x,y) = \lim\limits_{r\rightarrow0}f(r\cos\theta,r\sin\theta)$$
Since in the limit you have a $r$ with degree $2$ the limit exists and is equal to $0$. For checking that the derivatives exists you must check it for both directions. It means that checking
$$\lim\limits_{\Delta x\rightarrow0}\frac{f(0+\Delta x,0)-f(0,0)}{\Delta x}$$
which is zero since $y=0$ in $f(\Delta x,0)$. In $y$ direction you obtain:
$$\lim\limits_{\Delta y\rightarrow0}\frac{f(0,0+\Delta y)-f(0,0)}{\Delta y}$$
which again is zero based on the definition of $f(x,y)$.
So both first derivatives exists and the function is continuous so you can deduce that it is differentiable. 
Actually $f(x,y)$ is a surface which you can visualize it as a cylinder (the definition of cylinder is given in the Stewart Calculus book) which the $z$-axis is the continuity between the two parts of the surface and since it is not dependent on $y$ it does not change along the $y$-axis and the derivative with respect to $y$ is zero everywhere.
