Math Help - Partial derivatives for the sign function

1. Partial derivatives for the sign function

Hi there. Well, I've got some doubts on the partial derivatives for the next function:

$f(x,y)=sg\{(y-x^2)(y-2x^2)\}$ Where sg is the sign function.

So, what I got is:

$f(x,y)=f(x)=\begin{Bmatrix}{ 1}&\mbox{ si }& (y-x^2)(y-2x^2)>0\\0 & \mbox{si}& (y-x^2)(y-2x^2)=0\\-1 & \mbox{si}& (y-x^2)(y-2x^2)<0\end{matrix}$

How should I get the partial derivatives? I'm sure that for the zero I must use the definition. But in the other cases should I?

Bye, and thanks.

2. Because $f(*,*)$ is a constant in the regions where is $(y-x^{2})\ (y-2\ x^{2}) >0$ or $(y-x^{2})\ (y-2\ x^{2}) < 0$ , here the partial derivatives are both equal to 0. Where is $(y-x^{2})\ (y-2\ x^{2}) = 0$ the partial derivatives don't exist...

Kind regards

$\chi$ $\sigma$

3. How did you solve it?

Is this the right way?

If $x=y=0$
$\displaystyle\frac{\partial f}{\partial x}=\displaystyle\lim_{x \to{0}}{\displaystyle\frac{f(x,0)-f(0,0}{x}}=\displaystyle\lim_{x \to{0}}{\displaystyle\frac{(0-x^2)(0-2x^2-0)}{x}}=\displaystyle\lim_{x \to{0}}{\displaystyle\frac{2x^4}{x}}=0$

If $y=x^2$, $(x,y)=(x_0,x_0^2)$

$\displaystyle\frac{\partial f}{\partial x}=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{f(x_0+h,x_0^2)-f(x_0,x_0^2)}{h}}=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{(x_0^2-(x_0+h)^2)(x_0^2-2(x_0+h)^2)-0}{h}}=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{(x_0^2-x_0^2-2x_0h-h^2)(x_0^2-2x_0^2-4x_0h-h^2)}{h}}=$

$=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{-h(2x_0-h)(x_0^2+4x_0h+h^2)}{h}}=\displaystyle\lim_{h \to{0}}{-(2x_0-h)(x_0^2+tx_0h+h^2)=-2x_0^3}$

If $(x,y)=(x_0,2x_0^2)$

$\displaystyle\frac{\partial f}{\partial x}=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{f(x_0+h,2x_0^2)-f(x_0,2x_0^2)}{h}}=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{(2x_0^2-(x_0+h)^2)(2x_0^2-2(x_0+h)^2)-0}{h}}=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{(2x_0^2-x_0^2-2x_0h-h^2)(2x_0^2-2x_0^2-4x_0h-h^2)}{h}}=$

$=\displaystyle\lim_{h \to{0}}{\displaystyle\frac{(x_0^2-2x_0h-h^2)(-h(4x_0+h))}{h}}=\displaystyle\lim_{h \to{0}}{-(x_0^2-2x_0h-h^2)(4x_0+h)=-4x_0^2$

As $-4x_0^2\neq{-2x_0^3}$ the derivative doesn't exist at the point (0,0).

Is this right?

Thanks.
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 18, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "math_score": 0.9756942391395569, "perplexity": 454.7525347637091}, "config": {"markdown_headings": false, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "plain"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "warc_path": "s3://commoncrawl/crawl-data/CC-MAIN-2014-10/segments/1394678704980/warc/CC-MAIN-20140313024504-00032-ip-10-183-142-35.ec2.internal.warc.gz"}