Message Boards Message Boards

1
|
1861 Views
|
1 Reply
|
1 Total Likes
View groups...
Share
Share this post:

Differentials of a multivariable functions?

Let's say I have: $$x=r\sin\theta\cos\phi$$ $$y=r\sin\theta\sin\phi$$ $$z=r\cos\theta$$ I would like to get an expression for: $$dx^2+dy^2+dz^2$$ in terms of $r$, $\theta$, $\phi$. For example: $$dx=\sin\theta\cos\phi dr+r\sin\theta(-\sin\phi)d\phi+r\cos\theta\cos\phi$$ How can I achieve this with Mathematica? I know I can start with:

x[_r,_theta,_phi]=r*Sin[theta]*cos[Phi]

and so on, but then I don't see a straightforward line forward.

POSTED BY: Szabo Pal

Here is a way:

{dx, dy, dz} = Grad[FromSphericalCoordinates[{r, \[Theta], \[Phi]}],
   {r, \[Theta], \[Phi]}] . {dr, d\[Theta], d\[Phi]}
dx^2 + dy^2 + dz^2
POSTED BY: Gianluca Gorni
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract