[Date Index] [Thread Index] [Author Index]
Re: Why does Derivative fail in this case?
This works: f[x_, y_] := x y g = f[##]*f[##] &; h[x_, y_] := D[g[x, y], x] g[x, y] h[x, y] x^2 y^2 2 x y^2 As to why the other did not? Not sure. I do know it's often a poor idea to write functions without arguments. Bobby On Mon, 16 Feb 2009 05:58:26 -0600, Aaron Fude <aaronfude at gmail.com> wrote: > Hi, > > This example is self-explanatory: > > f[x_, y_] := x y > g = f[##]*f[##] &; > h = Derivative[1, 0][g]; > g[x, y] > h[x, y] > > I should expect that h[x, y] is 2 x y^2, but instead it is zero. How > come? > > Version 6.0 > > Many thanks in advance, > > Aaron > -- DrMajorBob at longhorns.com