# Thread: Line element definition by differentiating plane polar coordinates

1. ## Line element definition by differentiating plane polar coordinates

Hi folks, hopefully this is in the right forum. My textbook tells me I can use the product rule to go from the functions x = r cos phi and y = r sin phi to find expressions for dx and dy. I'm not clear whether this is partial differentiation (I thought I understood that!), or what I am differentiating with respect to! I have attached a jpg of the textbook section which should be clearer that typing it all out. I think I can get to the final expression, it's finding the middle two I don't understand. Can anyone help?

My jpg refers to equation 3.4, this is simply dl^2 = dx^2 + dy^2.

2. ## Re: Line element definition by differentiating plane polar coordinates

taking the derivattive w/r to $\phi$ ...

$\frac{d}{d\phi}(x = r\cos{\phi})$

$\frac{dx}{d\phi} = -r\sin{\phi} + \cos{\phi} \cdot \frac{dr}{d\phi}$

$dx = \cos{\phi} \cdot dr - r\sin{\phi} \cdot d\phi$

same idea for $dy$

3. ## Re: Line element definition by differentiating plane polar coordinates

It's the "total differential". If f(x,y) is a function of two variables, and each of those variables is a function of the single variable t, x(t), y(t), (think of an object moving along some trajectory in the plane with t as time), then, by the chain rule
$\frac{df}{dt}= \frac{\partial f}{\partial x}\frac{dx}{dt}+ \frac{\partial f}{\partial y}\frac{dy}{dt}$

Since that is now a function of a single variable, we can write its "differential", $df= \frac{df}{dt} dt$:
$df= \frac{\partial f}{\partial x}\frac{dx}{dt} dt+ \frac{\partial f}{\partial y}\frac{dy}{dt} dt= \frac{\partial f}{\partial x}dx+ \frac{\partial f}{\partial y} dy$
(Which no longer has any dependence on t!)

In particular, if $x= r cos(\phi)$ and $y= r sin(\phi)$, then $dx= \frac{\partial x}{\partial r}dr+ \frac{\partial x}{\partial \phi}d\phi= cos(\phi)dr- r sin(\phi)\d\phi$. And if $y= r sin(\phi)$, then $dy= \frac{\partial y}{\partial x}dr+ \frac{\partial y}{\partial \phi}d\phi= sin(\phi)dr+ r cos(\phi)d\phi$.

Squaring those,
$dx^2= cos^2(\phi)dr^2- 2r^2sin(\phi)cos(\phi)drd\phi+ r^2sin^2(\phi)d\phi^2$ and
$dy^2= sin^2(\phi)dr^2+ 2r^2sin(\phi)cos(\phi)drd\phi+ r^2 cos^2(\phi)d\phi^2$

Adding, the " $drd\phi$" terms cancel while $sin^2(\phi)+ cos^2(\phi)= 1$ so that
$ds^2= dx^2+ dy^2= dr^2+ r^2 d\phi^2$

4. ## Re: Line element definition by differentiating plane polar coordinates

Thanks very much for taking the time to answer chaps, having quoted one of your responses I can see the effort that goes into a properly formatted answer!

Skeeter: Your response was the same as I had seen in another textbook; whilst undoubtedly correct, unfortunately I am not able to make sense of it. I don;'t quite see why dx/dphi is not as simple as -r sin phi. Entirely my failing, not yours!

HallsofIvy: I have been able to follow quite a lot of your answer, but I still have a couple of questions about it. If you have time to explain further it would be much appreciated, if not it has at least got me to a working solution!

Originally Posted by HallsofIvy
It's the "total differential". If f(x,y) is a function of two variables,
In my case I have x(r,phi) as one function of two variables, and y(r,phi) as a second function of two variables...

and each of those variables is a function of the single variable t, x(t), y(t), (think of an object moving along some trajectory in the plane with t as time),
I can't quite see how this works in my case. Aren't r and phi two independant variables? What is the analogy to your t variable in my example?

then, by the chain rule
$\frac{df}{dt}= \frac{\partial f}{\partial x}\frac{dx}{dt}+ \frac{\partial f}{\partial y}\frac{dy}{dt}$
I get this part! This is partial differentiation as I understand it

Since that is now a function of a single variable, we can write its "differential", $df= \frac{df}{dt} dt$:
$df= \frac{\partial f}{\partial x}\frac{dx}{dt} dt+ \frac{\partial f}{\partial y}\frac{dy}{dt} dt= \frac{\partial f}{\partial x}dx+ \frac{\partial f}{\partial y} dy$
(Which no longer has any dependence on t!)
Is this 'thing' df the "total differential"? And does the operation where you "multiply though" by dt have a name (I realise it is not as simple as multiplying through!)

In particular, if $x= r cos(\phi)$ and $y= r sin(\phi)$, then $dx= \frac{\partial x}{\partial r}dr+ \frac{\partial x}{\partial \phi}d\phi= cos(\phi)dr- r sin(\phi)\d\phi$. And if $y= r sin(\phi)$, then $dy= \frac{\partial y}{\partial x}dr+ \frac{\partial y}{\partial \phi}d\phi= sin(\phi)dr+ r cos(\phi)d\phi$.

Squaring those,
$dx^2= cos^2(\phi)dr^2- 2r^2sin(\phi)cos(\phi)drd\phi+ r^2sin^2(\phi)d\phi^2$ and
$dy^2= sin^2(\phi)dr^2+ 2r^2sin(\phi)cos(\phi)drd\phi+ r^2 cos^2(\phi)d\phi^2$

Adding, the " $drd\phi$" terms cancel while $sin^2(\phi)+ cos^2(\phi)= 1$ so that
$ds^2= dx^2+ dy^2= dr^2+ r^2 d\phi^2$
That last bit all makes sense to me, I have never seen this type of differential manipulation before though which is why I am struggling!

5. ## Re: Line element definition by differentiating plane polar coordinates

Skeeter: Your response was the same as I had seen in another textbook; whilst undoubtedly correct, unfortunately I am not able to make sense of it. I don;'t quite see why dx/dphi is not as simple as -r sin phi.
if $r$ were a constant, then $\frac{d}{d\phi}(r \cos{\phi}) = -r\sin{\phi}$ ... however, $r$ is not a constant, it is an implicit function of $\phi$ .