# The Chain Rule for General Scalar Fields

Let $f$ be a scalar field defined on $(x,y)$ where $x=r\cos(\theta), y=r\sin(\theta)$ and for which the mixed partials are equal: $$\frac{\partial^2 f}{\partial x \partial y}=\frac{\partial^2 f}{\partial y \partial x}.$$ Find $\frac{\partial f}{\partial r}$ and $\frac{\partial f}{\partial \theta}$ in terms of the partial derivatives of $f$ with respect to $x$ and $y$.

There is more to the question than this, but I really need a starting point because I can't seem get an answer that I'm satisfied with. I'm completely unsure of how to complete this and some guidance would be appreciated.

• Do you want the partial derivatives expressed in terms of $x$ and $y$ or of $r$ and $\theta$? – amd Oct 27 '15 at 20:12
• Ah, I was just trying to cut out the rest of the partial derivatives it wanted me to find. Forgot that piece of info. Fixed now – Algebraic Oct 27 '15 at 20:23
• OK. So, what do you get when you expand $\frac{\partial f}{\partial r}$ with the chain rule? – amd Oct 27 '15 at 20:25
• I don't know why it took you saying that for me to understand, but now I've got it. f_xx_r + f_yy_r. Thanks a lot. – Algebraic Oct 27 '15 at 20:29

There is almost a bad notation behind confusions in using chain-rule! :)
You will agree with me in a minute!

Let us consider the following

$$g(r,\theta ) = f(x(r,\theta ),y(r,\theta ))\tag{1}$$

Now apply chain rule to get

\eqalign{ & {{\partial g} \over {\partial r}}(r,\theta ) = {{\partial f} \over {\partial x}}\left( {x(r,\theta ),y(r,\theta )} \right){{\partial x} \over {\partial r}}\left( {r,\theta } \right) + {{\partial f} \over {\partial y}}\left( {x(r,\theta ),y(r,\theta )} \right){{\partial y} \over {\partial r}}\left( {r,\theta } \right) \cr & {{\partial g} \over {\partial \theta }}(r,\theta ) = {{\partial f} \over {\partial x}}\left( {x(r,\theta ),y(r,\theta )} \right){{\partial x} \over {\partial \theta }}\left( {r,\theta } \right) + {{\partial f} \over {\partial y}}\left( {x(r,\theta ),y(r,\theta )} \right){{\partial y} \over {\partial \theta }}\left( {r,\theta } \right) \cr}\tag{2}

everything looks good. But most of the times, people do not distinguish between $g$ and $f$ and this leaves them with a bad confusion as they just think of $(1)$ like this

$$f(r,\theta ) = f(x(r,\theta ),y(r,\theta ))\tag{3}$$

Which really is not true and can cause ambiguity! :)