Question is in the title... I was wondering if someone could help me with that partial derivative, preferably with the total derivative if possible. Thanks a lot
Compute $\dfrac{\partial f(x,y,g(x,y))}{\partial x}$
-
0Are $x$ and $y$ independent? – 2012-03-13
-
0Yessir [char limit] – 2012-03-13
2 Answers
The chain rule gives us a general formula
$$\frac{\partial}{\partial x} f(\alpha,\beta,\gamma)=\frac{\partial f}{\partial\alpha}\frac{\partial\alpha}{\partial x}+\frac{\partial f}{\partial\beta}\frac{\partial\beta}{\partial x}+\frac{\partial f}{\partial\gamma}\frac{\partial\gamma}{\partial x}. $$
Now what if $\alpha=x$ and $\beta=y$ and $\gamma=g(x,y)$?
To summarize the discussion below: partially differentiating $f$ with assumed independent arguments, and then evaluating at dependent arguments, obtains different results from first creating a new function by evaluating $f$ at dependent arguments and then differentiating that.
-
0so $f_x(x,y,g(x,y))=f_x\cdot1 + f_x\cdot0 + f_x\cdot g_x(x,y)$? I don't think that's right because the left-hand side appears as a term in the right hand side. – 2012-03-13
-
0@aengle: You're confused. The partial derivative of $f(x,y,g)$ wrt $x$ is **not** the same as $f_x$ *evaluated* at $(x,y,g)$ - which is what you have written in your comment. Furthermore the RHS of your equation should not have a subscript $x$ on each individual instance of $f$; look at the chain rule more closely! It should be $\frac{\partial}{\partial x}\big[f(x,y,g(x,y))\big]=f_x\cdot1+f_y\cdot0+f_g\cdot\frac{\partial g}{\partial x}.$ The term $f_g$ should be understood to mean "the derivative of $f$ wrt its third argument, evaluated at $(x,y,g(x,y))$." – 2012-03-13
-
0Ok, so $\frac{\partial}{\partial x} f(x,y,g)=\frac{\partial f}{\partial x}\frac{\partial x}{\partial x}+\frac{\partial f}{\partial y}\frac{\partial y}{\partial x}+\frac{\partial f}{\partial g(x,y)}\frac{\partial g(x,y)}{\partial x}$. So what is the difference between the term on the left and the first on the right in this case? (and thanks for the help :) ) – 2012-03-13
-
0@aengle: Consider a simpler case, $f(u,v)=u+v$. Now $f_u=1$. But if we let $v=v(u)=u^2$ be *dependent* on $u$, then $\frac{\partial}{\partial u}f(u,v(u))=\partial(u+u^2)/\partial u=1+2u$. If we simply evaluated $f_u$ at $(t,t^2)$ we'd still get $1$. Why are these different? Because in the former case you formally treat all arguments as independent to create a partial derivative of $f$, while in the latter case you're really partially differentiating a function *created from* $f$ - created by evaluating $f$ at *dependent* arguments before any differentiation. Obviously the results may differ. – 2012-03-13
-
0OK. That maeks sense. Thanks a lot! – 2012-03-13
To make things clearer, I thought I'd write a comment, but this is too big. Let $h(x,y) = f(x,y,g(x,y))$. What I believe that you want to compute is $\frac {\partial h}{\partial x}$, which is different from $\frac{\partial f}{\partial x} f(x,y,z)$ where $z$ happens to be such that $z = g(x,y)$. In other words, you're taking the limit $$ \lim_{t \to x} \frac{f(t,y,g(\overset{\downarrow}{t},y)) - f(x,y,g(x,y))}{t-x} = \frac{\partial h(x,y)}{\partial x} $$ which is not the same thing as taking the limit $$ \lim_{t \to x} \frac{f(t,y,g(\overset{\downarrow}{x},y)) - f(x,y,g(x,y))}{t-x} = \left. \frac{\partial f(x,y,z)}{\partial x} \right|_{z = g(x,y)} $$ (notice how in one expression the $x$ in $g(x,y)$ varies as $t$, but in the second one the $x$ remains fixed as $t$ varies). The first expression measures the variation of $f(x,y,g(x,y))$ when $x$ varies, but the second expression measures the variation of $f(x,y,z)$ when $x$ varies, then evaluates the derivative at $z = g(x,y)$. Those two are totally different.
Hope that helps, feel free to comment.
-
1I understand what you mean. This wasn't my question at all actually, but it really does help clarify the subtle difference that I wasn't 100% understanding until after reading this. Thank you :) – 2012-03-13
-
0It wasn't your question, but it was your problem. =P – 2012-03-13