# Issues computing a directional derivative

I am trying to do a problem which wants me to compute the directional derivatives at $(0, 0)$ of $$f(x, y) = \frac{xy}{\sqrt{x^2 + y^2}}, \quad f(0, 0) = 0.$$

There are two equations I know for computing the directional derivative, and them seem to be inconsistent for some reason.

Here are the two formulas I have for directional derivatives, $(a, b)$ a unit vector $$D_{(a, b)}f(x, y) = \lim_{t \to 0} \frac{f(x + ta, y + tb) - f(x, y)}{t}.$$

$$D_{(a, b)}f(x, y) = aD_xf(x, y) + bD_yf(x, y).$$ where $D_x$ and $D_y$ are the partial derivatives.

Computing the partials derivatives I get $$D_x(0, 0) = \lim_{t \to 0} \frac{f(t, 0) - f(0, 0)}{t} = \lim_{t \to 0} \frac{\displaystyle\frac{t\cdot 0}{\sqrt{t^2 + 0^2}} - 0}{t} = 0$$

$$D_y(x, 0) = \lim_{t \to 0} \frac{f(0, t) - f(0, 0)}{t} = \lim_{t \to 0} \frac{\displaystyle\frac{0\cdot t}{\sqrt{0^2 + t^2}} - 0}{t} = 0$$

Which in turn should imply $D_{(a, b)}(0, 0) = a\cdot 0 + b\cdot 0 = 0$.

But computing with the limit formula $$D_{(a, b)}f(x, y) = \lim_{t \to 0} \frac{f(ta, tb) - f(0, 0)}{t} = \lim_{t \to 0}\frac{\displaystyle\frac{(ta)(tb)}{\sqrt{(ta)^2 + (tb)^2}} - 0}{t} = \lim_{t \to 0}\frac{t^2 ab}{t^2\sqrt{a^2 + b^2}} = \frac{ab}{\sqrt{a^2 + b^2}} = ab \neq 0$$ if $a \neq 0$ and $b \neq 0$.

I imagine I am doing something silly, or I have a formula wrong or something. But I haven't been able to correct myself yet. Can anyone tell me where my reasoning is going wrong?

-

For $u=(a,b) \ne 0$ and $t \ne 0$ one has $$\frac{f(0+tu)-f(0)}{t}=\frac{f(tu)}{t}=\frac{t^2ab}{t\sqrt{t^2(a^2+b^2)}}=\frac{t}{|t|}f(u).$$ If $ab=0$, then $D_uf(0)=0$. If $ab \ne 0$, since the limit of $t/|t|$ as $t$ tends to 0 doesn't exist, then the directional derivative does not exist.

-
Ah thank you, that clarifies where my issue was. $\sqrt{t^2} = |t|$. –  Danikar Jun 30 '12 at 0:07
So when the derivative doesn't exist the second formula, $D_{(a, b)}(x, y) = aD_x(x, y) + bD_y(x, y)$ is not correct? I believe that is the one that uses differentiability to derive. –  Danikar Jun 30 '12 at 0:03
If the derivative does not exist, you can't write $D_{(a,b)}(x,y)$, 'cause it does not exist. –  ncmathsadist Jun 30 '12 at 0:08
Well certainly it still exists in the case where $(a, b) = (1, 0)$ and $(a, b) = (0, 1)$ since those just coincide with $D_x$ and $D_y$. –  Danikar Jun 30 '12 at 0:14