Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Partial differentiation and changing variables

  1. Nov 29, 2003 #1
    Maths Question: I am having a lot of problems with this question, can any undergrad physicists or mathematicians help me?

    (note: p before a differntial= partial derivative) .

    Spherical polar coordinates (r, (thetha), (phi)) are defined in terms of Cartesian coorindates (x,y,z) by:


    given that f is a function of r only, independent of theta and phi, show that

    p(df)/p(dx) = (x/r).(df/dr)

    p(d^2f)/p(dx^2) = (1/r).(df/dr) + (x^2/r).d[(1/r).(df/dr)]/dr

    and hence deduce that:

    p(d^2f)/p(dx^2) + p(d^2f)/p(dy^2) + p(d^2f)/p(dz^2) =

    a) is straigthforward, any thoughts on how to appraoch b) ???

  2. jcsd
  3. Nov 29, 2003 #2


    User Avatar
    Science Advisor
    Gold Member

    Consider the fact that x2 + y2 + z2 = r2

    What you've already shown for x also applies to y and z:

    [itex] \frac{\partial f}{\partial x} = \frac{x}{r} \cdot \frac{df}{dr} [/itex]

    [itex] \frac{\partial f}{\partial y} = \frac{y}{r} \cdot \frac{df}{dr} [/itex]

    [itex] \frac{\partial f}{\partial z} = \frac{z}{r} \cdot \frac{df}{dr} [/itex]

    [itex] \frac{\partial^2 f}{\partial x^2} = \frac{1}{r} \cdot \frac{df}{dr} + \frac{x^2}{r}\,\frac{d}{dr}\left(\frac{1}{r}\,\frac{df}{dr}\right) [/itex]

    [itex] \frac{\partial^2 f}{\partial y^2} = \frac{1}{r} \cdot \frac{df}{dr} + \frac{y^2}{r}\,\frac{d}{dr}\left(\frac{1}{r}\,\frac{df}{dr}\right) [/itex]

    [itex] \frac{\partial^2 f}{\partial z^2} = \frac{1}{r} \cdot \frac{df}{dr} + \frac{z^2}{r}\,\frac{d}{dr}\left(\frac{1}{r}\,\frac{df}{dr}\right) [/itex]

    Add them together and use the first equation to get:

    [itex] \frac{\partial^2 f}{\partial x^2} + \frac{\partial^2 f}{\partial y^2} + \frac{\partial^2 f}{\partial z^2} = r\frac{d}{dr}\left(\frac{1}{r}\,\frac{df}{dr}\right) + \frac{3}{r}\frac{df}{dr} [/itex]

    which can be simplified to:

    [itex] \frac{\partial^2 f}{\partial x^2} + \frac{\partial^2 f}{\partial y^2} + \frac{\partial^2 f}{\partial z^2} = \frac{d^2 f}{dr^2} + \frac{2}{r}\frac{df}{dr} = \frac{1}{r^2}\frac{d}{dr}\left(r^2\frac{df}{dr}\right) [/itex]
  4. Nov 29, 2003 #3

    Thanks so much, you've made it very clear!
  5. Dec 31, 2003 #4

    I would much appreciate some help in deriving the second expression in the original question below:

    p(d^2f)/p(dx^2) = (1/r).(df/dr) + (x^2/r).d[(1/r).(df/dr)]/dr

    Thanks for the help!


  6. Dec 31, 2003 #5


    User Avatar
    Science Advisor
    Gold Member

    Use the product rule to find the derivative of this equation:

    [itex] \frac{\partial f}{\partial x} = \frac{x}{r} \cdot \frac{df}{dr} [/itex]
  7. Dec 31, 2003 #6
    Thanks for the reply,

    I am trying this but am getting very confsed...

    first of all:

    I have a term: dr/dx .dx/dr. But I dont see why this is equal to one. If i accept this I get the result, but we know:

    x = r.cos(phi).sin(theta)

    and r^2 = x^2 + y^2 + z^2

    so we can verify that the 2 partial derivatives are not eqal.

    secondly, f is a function of r ony.... but df/dr (partial) is also a function of p and theta...

    Therefore, you have a lot more terms than you would expect, because you have to take the derivative wrt phi and theta and then these wrt to x.

    I dont know if I have completely misunderstood partial derivatives, but this is gettig messy!


  8. Dec 31, 2003 #7


    User Avatar
    Science Advisor
    Gold Member

    You are given that f = f(r) (function of r only).

    Using the chain rule:
    [tex] \frac{\partial f}{\partial x} = \frac{df}{dr}\cdot\frac{\partial r}{\partial x} [/tex]

    (notice that it's df/dr (not partials) because f is a function of r only)

    Now we need to find [tex] \frac{\partial r}{\partial x} [/tex].

    To do this, you can use the fact that x2 + y2 + z2 = r2.

    Take the derivative of both sides with respect to x to get:

    [tex] 2x = 2r\frac{\partial r}{\partial x} [/tex]


    [tex] \frac{\partial r}{\partial x} = \frac{x}{r} [/tex]

    plug that in to the results from the chain rule:

    [tex] \frac{\partial f}{\partial x} = \frac{x}{r}\cdot\frac{df}{dr} [/tex]

    Okay so far?

    Now on to the second part using the product rule:

    [tex] \frac{\partial^2 f}{\partial x^2} = x\frac{\partial}{\partial x}\left(\frac{1}{r}\cdot\frac{df}{dr} \right) + \frac{1}{r}\cdot\frac{df}{dr} [/tex]

    from before: [tex] \partial x = \frac{r}{x}\partial r [/tex]

    substitute that in to get:

    [tex] \frac{\partial^2 f}{\partial x^2} = x\frac{x}{r}\frac{\partial}{\partial r}\left(\frac{1}{r}\cdot\frac{df}{dr} \right) + \frac{1}{r}\cdot\frac{df}{dr} [/tex]

    which becomes:

    [itex] \frac{\partial^2 f}{\partial x^2} = \frac{1}{r} \cdot \frac{df}{dr} + \frac{x^2}{r}\,\frac{d}{dr}\left(\frac{1}{r}\,\frac{df}{dr}\right) [/itex]

    Hope that helps.
  9. Jan 1, 2004 #8
    Much Appreciated.

  10. Oct 3, 2004 #9


    User Avatar

    the function f(x,y) is transformed to F(r,a) by change of variables x=rcos a and y=rsin a. Show that
    1. p(d^2F)/p(dr^2)
    2. p(d^2F)/p(da^2)+r[p(dF/dr)]
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook