0

Please notice the following steps: $$x = r\cos\theta$$ $$y = r\sin\theta$$ So, $$\frac {\partial x}{\partial r} = \cos\theta$$ Again, $$r = \sqrt {x^2 + y^2}$$ So, $$\frac{\partial r}{\partial x} = \frac{x}{\sqrt {x^2 + y^2}} = \frac {r\cos\theta}{r} = \cos\theta$$

Are all of these calculations valid? Or did I make a mistake? The result seems unexpected to me. If the outcome is not an anomaly, then why partial derivative does not follow the rule $\frac {\partial y}{\partial x} = \frac{1}{\frac{\partial x}{\partial y}}$ ?

2 Answers2

8

When you compute a partial derivative in this situation, you need to have in mind which variables you are considering to be the independent variables and which are dependent.

A useful notation often used in physics is

$$ \left( \frac{\partial x}{\partial y} \right)_{z,w} $$

to indicate the partial derivative of $x$ with respect to $y$ with $z$ and $w$ held constant (i.e. considering $x$ as a function of the independent variables $y, z, w$).

In the first instance, you are taking $r$ and $\theta$ as the independent variables, and then it is true that $$ \dfrac{\partial x}{\partial r} =\left(\dfrac{ \partial x}{\partial r}\right)_\theta = \cos(\theta)$$

In the second case, you have $$ \dfrac{\partial r}{\partial x} = \left(\dfrac{ \partial r}{\partial x}\right)_y = \cos(\theta)$$

and there's no contradiction, because different variables are being held constant.

[EDIT] About the coincidence:

In general suppose you have $ x = f(z,w)$ and $y = g(z,w)$. What must be true to make $\left(\dfrac{\partial x}{\partial z}\right)_w = \left(\dfrac{\partial z}{\partial x}\right)_y$?

It turns out that the condition is $$\dfrac{\partial f}{\partial z} = \dfrac{\dfrac{\partial g}{\partial w}}{\dfrac{\partial f}{\partial z} \dfrac{\partial g}{\partial w} - \dfrac{\partial f}{\partial w} \dfrac{\partial g}{\partial z}}$$ In the case at hand, this works out because of $\cos^2 + \sin^2 = 1$.

[EDIT]

This can be obtained by writing

$$ \eqalign{ dx &= \dfrac{\partial f}{\partial z}\; dz + \dfrac{\partial f}{\partial w}\; dw\cr dy &= \dfrac{\partial g}{\partial z}\; dz + \dfrac{\partial g}{\partial w}\; dw}$$

With $w$ fixed, so $dw = 0$, you get of course $$ \left( \dfrac{\partial x}{\partial z}\right)_w = \dfrac{\partial f}{\partial z} $$ But with $y$ fixed, you want $dy = 0$ so $$dw = - \dfrac{\dfrac{\partial g}{\partial z}}{\dfrac{\partial g}{\partial w}} \; dz $$ and then $$ \left(\dfrac{\partial z}{\partial x} \right)_y = \dfrac{dz}{\dfrac{\partial f}{\partial z}\; dz + \dfrac{\partial f}{\partial w}\; dw} = \dfrac{\dfrac{\partial g}{\partial w}}{\dfrac{\partial f}{\partial z} \dfrac{\partial g}{\partial w} - \dfrac{\partial f}{\partial w} \dfrac{\partial g}{\partial z}}$$

Robert Israel
  • 470,583
  • I don't think the OP was claiming there was a contradiction, but was just noticing an odd coincidence, and wondering if it meant they'd made a mistake. Me, I don't fully understand the situation, but agree that your suggestion might help. – JonathanZ Dec 26 '24 at 17:01
  • The question is now closed, so you might not want to bother, but I'd enjoy seeing how you reach your conclusion. It seems very plausible, as it smells of inverting Jacobians, but I think even just adding a quick description would improve this answer. – JonathanZ Dec 26 '24 at 20:39
0

It might seem unexpected, especially if you've seen the (somewhat informal) "equation"

$$\frac{dy}{dx}\frac{dx}{dy} =1$$

But when you're doing multi-variable calculus, remember that you have to look at the full Jacobian matrix to understand what's going on. I suggest computing both $\partial(x,y)/\partial(r,\theta)$ and $\partial(r,\theta)/\partial(x,y)$ matrices, and multiplying them together to get more insight into what's going on.

JonathanZ
  • 12,727