derivation of the Laplacian from rectangular to spherical coordinates
We begin by recognizing the familiar conversion from rectangular to spherical coordinates (note that ϕ is used to denote the azimuthal angle, whereas θ is used to denote the polar angle)
x=rsin(θ)cos(ϕ),y=rsin(θ)sin(ϕ),z=rcos(θ), | (1) |
and conversely from spherical to rectangular coordinates
r=√x2+y2+z2,θ=arccos(zr),ϕ=arctan(yx). | (2) |
Now, we know that the Laplacian in rectangular coordinates is defined11Readers should note that we do not have to define the Laplacian this way. A more rigorous approach would be to define the Laplacian in some coordinate free manner. in the following way
∇2f | = | ∂2f∂x2+∂2f∂y2+∂2f∂z2. | (3) |
We also know that the partial derivatives in rectangular coordinates can be expanded in the following way by using the chain rule
∂f∂x | = | ∂f∂r∂r∂x+∂f∂θ∂θ∂x+∂f∂ϕ∂ϕ∂x, | (4) | ||
∂f∂y | = | ∂f∂r∂r∂y+∂f∂θ∂θ∂y+∂f∂ϕ∂ϕ∂y, | (5) | ||
∂f∂z | = | ∂f∂r∂r∂z+∂f∂θ∂θ∂z+∂f∂ϕ∂ϕ∂z. | (6) |
The next step is to convert the right-hand side of each of the above three equations so that it only has partial derivatives in terms of r, θ and ϕ. We can do this by substituting the following values (which are easily derived from (2)) in their respective places in the above three equations
∂r∂x=sin(θ)cos(ϕ),∂θ∂x=1rcos(θ)cos(ϕ),∂ϕ∂x=-1rsin(ϕ)sin(θ), | |||
∂r∂y=sin(θ)sin(ϕ),∂θ∂y=1rcos(θ)sin(ϕ),∂ϕ∂y=1rcos(ϕ)sin(θ), | |||
∂r∂z=cos(θ),∂θ∂z=-1rsin(θ),∂ϕ∂z=0. | (7) |
After the substitution, equation (4) looks like the following
∂f∂x | = | sin(θ)cos(ϕ)∂f∂r+1rcos(θ)cos(ϕ)∂f∂θ-1rsin(ϕ)sin(θ)∂f∂ϕ. | (8) |
Assuming that f is a sufficiently differentiable function, we can replace f by ∂f∂x in the above equation and arrive at the following
∂2f∂x2 | = | sin(θ)cos(ϕ)∂∂r[∂f∂x]+1rcos(θ)cos(ϕ)∂∂θ[∂f∂x]-1rsin(ϕ)sin(θ)∂∂ϕ[∂f∂x]. | (9) |
Now the trick is to substitute equation (8) into equation (9) in order to eliminate any partial derivatives with respect to x. The result is the following equation
∂2f∂x2 | = | sin(θ)cos(ϕ)∂∂r[sin(θ)cos(ϕ)∂f∂r+1rcos(θ)cos(ϕ)∂f∂θ-1rsin(ϕ)sin(θ)∂f∂ϕ]+ | ||
1rcos(θ)cos(ϕ)∂∂θ[sin(θ)cos(ϕ)∂f∂r+1rcos(θ)cos(ϕ)∂f∂θ-1rsin(ϕ)sin(θ)∂f∂ϕ]- | ||||
1rsin(ϕ)sin(θ)∂∂ϕ[sin(θ)cos(ϕ)∂f∂r+1rcos(θ)cos(ϕ)∂f∂θ-1rsin(ϕ)sin(θ)∂f∂ϕ]. |
In the hopes of simplifying the above equation, we operate the derivates on the operands and get
∂2f∂x2 | = | sin(θ)cos(ϕ)[sin(θ)cos(ϕ)∂2f∂r2-1r2cos(θ)cos(ϕ)∂f∂θ+1rcos(θ)cos(ϕ)∂2f∂r∂θ+ | ||
1r2sin(ϕ)sin(θ)∂f∂ϕ-1rsin(ϕ)sin(θ)∂2f∂ϕ∂r]+1rcos(θ)cos(ϕ)[cos(θ)cos(ϕ)∂f∂r+ | ||||
sin(θ)cos(ϕ)∂2f∂r∂θ-1rsin(θ)cos(ϕ)∂f∂θ+1rcos(θ)cos(ϕ)∂2f∂θ2+1rsin(ϕ)cos(θ)sin2(θ)∂f∂ϕ- | ||||
1rsin(ϕ)sin(θ)∂2f∂θ∂ϕ]-1rsin(ϕ)sin(θ)[-sin(θ)sin(ϕ)∂f∂r+sin(θ)cos(ϕ)∂2f∂r∂ϕ- | ||||
1rcos(θ)sin(ϕ)∂f∂θ+1rcos(θ)cos(ϕ)∂2f∂θ∂ϕ-1rcos(ϕ)sin(θ)∂f∂ϕ-1rsin(ϕ)sin(θ)∂2f∂ϕ2]. |
After further simplifying the above equation, we arrive at the following form
∂2f∂x2 | = | [sin2(θ)cos2(ϕ)∂2f∂r2-1r2cos(θ)sin(θ)cos2(ϕ)∂f∂θ+1rcos(θ)sin(θ)cos2(ϕ)∂2f∂r∂θ+ | ||
1r2sin(ϕ)cos(ϕ)∂f∂ϕ-1rsin(ϕ)cos(ϕ)∂2f∂ϕ∂r]+[1rcos2(θ)cos2(ϕ)∂f∂r+ | ||||
1rsin(θ)cos(θ)cos2(ϕ)∂2f∂r∂θ-1r2sin(θ)cos(θ)cos2(ϕ)∂f∂θ+1r2cos2(θ)cos2(ϕ)∂2f∂θ2+ | ||||
1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)∂f∂ϕ-1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)∂2f∂θ∂ϕ]+[1rsin2(ϕ)∂f∂r- | ||||
1rsin(ϕ)cos(ϕ)∂2f∂r∂ϕ+1r2cos(θ)sin2(ϕ)sin(θ)∂f∂θ-1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)∂2f∂θ∂ϕ+ | ||||
1r2sin(ϕ)cos(ϕ)sin2(θ)∂f∂ϕ+1r2sin2(ϕ)sin2(θ)∂2f∂ϕ2]. |
Notice that we have derived the first term of the right-hand side of equation (3) (i.e. ∂2f∂x2) in terms of spherical coordinates. We now have to do a similar arduous derivation for the rest of the two terms (i.e. ∂2f∂y2 and ∂2f∂z2). Lets do it!
After we substitute the values of (7) into equation (5) we get
∂f∂y | = | sin(θ)sin(ϕ)∂f∂r+1rcos(θ)sin(ϕ)∂f∂θ+1rcos(ϕ)sin(θ)∂f∂ϕ. | (10) |
Again, assuming that f is a sufficiently differentiable function, we can replace f by ∂f∂y in the above equation and arrive at the following
∂2f∂y2 | = | sin(θ)sin(ϕ)∂∂r[∂f∂y]+1rcos(θ)sin(ϕ)∂∂θ[∂f∂y]+1rcos(ϕ)sin(θ)∂∂ϕ[∂f∂y]. | (11) |
Now we substitute equation (10) into equation (11) in order to eliminate any partial derivatives with respect to y. The result is the following
∂2f∂y2 | = | sin(θ)sin(ϕ)∂∂r[sin(θ)sin(ϕ)∂f∂r+1rcos(θ)sin(ϕ)∂f∂θ+1rcos(ϕ)sin(θ)∂f∂ϕ]+ | ||
1rcos(θ)sin(ϕ)∂∂θ[sin(θ)sin(ϕ)∂f∂r+1rcos(θ)sin(ϕ)∂f∂θ+1rcos(ϕ)sin(θ)∂f∂ϕ]+ | ||||
1rcos(ϕ)sin(θ)∂∂ϕ[sin(θ)sin(ϕ)∂f∂r+1rcos(θ)sin(ϕ)∂f∂θ+1rcos(ϕ)sin(θ)∂f∂ϕ]. |
Now we operate the operators and get
∂2f∂y2 | = | sin(θ)sin(ϕ)[sin(θ)sin(ϕ)∂2f∂r2-1r2cos(θ)sin(ϕ)∂f∂θ+1rcos(θ)sin(ϕ)∂2f∂r∂θ- | ||
1r2cos(ϕ)sin(θ)∂f∂ϕ+1rcos(ϕ)sin(θ)∂2f∂r∂ϕ]+1rcos(θ)sin(ϕ)[sin(θ)sin(ϕ)∂f∂r∂θ+ | ||||
cos(θ)sin(ϕ)∂f∂r-1rsin(θ)sin(ϕ)∂f∂θ+1rcos(θ)sin(ϕ)∂2f∂θ2-1rcos(ϕ)cos(θ)sin2(θ)∂f∂ϕ+ | ||||
1rcos(ϕ)sin(θ)∂2f∂θ∂ϕ]+1rcos(ϕ)sin(θ)[sin(θ)cos(ϕ)∂f∂r+sin(θ)sin(ϕ)∂2f∂r∂ϕ+ | ||||
1rcos(θ)cos(ϕ)∂f∂θ+1rcos(θ)sin(ϕ)∂2f∂θ∂ϕ-1rsin(ϕ)sin(θ)∂f∂ϕ+1rcos(ϕ)sin(θ)∂2f∂ϕ2], |
and after some simplifications
∂2f∂y2 | = | [sin2(θ)sin2(ϕ)∂2f∂r2-1r2sin(θ)cos(θ)sin2(ϕ)∂f∂θ+1rsin(θ)cos(θ)sin2(ϕ)∂2f∂r∂θ- | ||
1r2sin(ϕ)cos(ϕ)∂f∂ϕ+1rsin(ϕ)cos(ϕ)∂2f∂r∂ϕ]+[1rcos(θ)sin(θ)sin2(ϕ)∂f∂r∂θ+ | ||||
1rcos2(θ)sin2(ϕ)∂f∂r-1r2sin(θ)cos(θ)sin2(ϕ)∂f∂θ+1r2cos2(θ)sin2(ϕ)∂2f∂θ2- | ||||
1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)∂f∂ϕ+1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)∂2f∂θ∂ϕ]+[1rcos2(ϕ)∂f∂r+ | ||||
1rcos(ϕ)sin(ϕ)∂2f∂r∂ϕ+1r2cos(θ)cos2(ϕ)sin(θ)∂f∂θ+1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)∂2f∂θ∂ϕ- | ||||
1r2sin(ϕ)cos(ϕ)sin2(θ)∂f∂ϕ+1r2cos2(ϕ)sin2(θ)∂2f∂ϕ2]. |
Now its time to derive ∂2f∂z2. After our substitution of value in (7) into equation (6) we get
∂f∂z | = | cos(θ)∂f∂r-1rsin(θ)∂f∂θ. | (12) |
Once more, assuming that f is a sufficiently differentiable function, we can replace f by ∂f∂z in the above equation which gives us the following
∂2f∂z2 | = | cos(θ)∂∂r[∂f∂z]-1rsin(θ)∂∂θ[∂f∂z]. | (13) |
Now we substitute equation (12) into equation (13) in order to eliminate any partial derivatives with respect to z and we arrive at
∂2f∂z2 | = | cos(θ)∂∂r[cos(θ)∂f∂r-1rsin(θ)∂f∂θ]- | ||
1rsin(θ)∂∂θ[cos(θ)∂f∂r-1rsin(θ)∂f∂θ]. |
After operating the operators we get
∂2f∂z2 | = | cos(θ)[cos(θ)∂2f∂r2+1r2sin(θ)∂f∂θ-1rsin(θ)∂2f∂r∂θ]- | ||
1rsin(θ)[-sin(θ)∂f∂r+cos(θ)∂2f∂r∂θ-1rcos(θ)∂f∂θ- | ||||
1rsin(θ)∂2f∂θ2], |
and then simplifying
∂2f∂z2 | = | [cos2(θ)∂2f∂r2+1r2cos(θ)sin(θ)∂f∂θ-1rcos(θ)sin(θ)∂2f∂r∂θ]+[1rsin2(θ)∂f∂r- | ||
1rsin(θ)cos(θ)∂2f∂r∂θ+1r2sin(θ)cos(θ)∂f∂θ+1r2sin2(θ)∂2f∂θ2]. |
Now that we have all three terms of the right hand side of equation (3)(i.e. ∂2f∂x2, ∂2f∂y2 and ∂2f∂z2), we add them all together (because of equation (3)) to get the laplacian in terms of r, θ and ϕ
∇2f | = | [sin2(θ)cos2(ϕ)∂2f∂r2-1r2cos(θ)sin(θ)cos2(ϕ)∂f∂θ+1rcos(θ)sin(θ)cos2(ϕ)∂2f∂r∂θ+ | ||
1r2sin(ϕ)cos(ϕ)∂f∂ϕ-1rsin(ϕ)cos(ϕ)∂2f∂ϕ∂r]+[1rcos2(θ)cos2(ϕ)∂f∂r+ | ||||
1rsin(θ)cos(θ)cos2(ϕ)∂2f∂r∂θ-1r2sin(θ)cos(θ)cos2(ϕ)∂f∂θ+1r2cos2(θ)cos2(ϕ)∂2f∂θ2+ | ||||
1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)∂f∂ϕ-1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)∂2f∂θ∂ϕ]+[1rsin2(ϕ)∂f∂r- | ||||
1rsin(ϕ)cos(ϕ)∂2f∂r∂ϕ+1r2cos(θ)sin2(ϕ)sin(θ)∂f∂θ-1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)∂2f∂θ∂ϕ+ | ||||
1r2sin(ϕ)cos(ϕ)sin2(θ)∂f∂ϕ+1r2sin2(ϕ)sin2(θ)∂2f∂ϕ2]+[sin2(θ)sin2(ϕ)∂2f∂r2- | ||||
1r2sin(θ)cos(θ)sin2(ϕ)∂f∂θ+1rsin(θ)cos(θ)sin2(ϕ)∂2f∂r∂θ-1r2sin(ϕ)cos(ϕ)∂f∂ϕ+ | ||||
1rsin(ϕ)cos(ϕ)∂2f∂r∂ϕ]+[1rcos(θ)sin(θ)sin2(ϕ)∂f∂r∂θ+1rcos2(θ)sin2(ϕ)∂f∂r- | ||||
1r2sin(θ)cos(θ)sin2(ϕ)∂f∂θ+1r2cos2(θ)sin2(ϕ)∂2f∂θ2-1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)∂f∂ϕ+ | ||||
1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)∂2f∂θ∂ϕ]+[1rcos2(ϕ)∂f∂r+1rcos(ϕ)sin(ϕ)∂2f∂r∂ϕ+ | ||||
1r2cos(θ)cos2(ϕ)sin(θ)∂f∂θ+1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)∂2f∂θ∂ϕ-1r2sin(ϕ)cos(ϕ)sin2(θ)∂f∂ϕ+ | ||||
1r2cos2(ϕ)sin2(θ)∂2f∂ϕ2]+[cos2(θ)∂2f∂r2+1r2cos(θ)sin(θ)∂f∂θ-1rcos(θ)sin(θ)∂2f∂r∂θ]+ | ||||
[1rsin2(θ)∂f∂r-1rsin(θ)cos(θ)∂2f∂r∂θ+1r2sin(θ)cos(θ)∂f∂θ+1r2sin2(θ)∂2f∂θ2]. |
It may be hard to believe but the truth is that the above expression, after some miraculous simplifications of course, reduces to the following succinct form and we finally arrive at the Laplacian in spherical coordinates!
∇2f | = | ∂2f∂r2+1r2∂2f∂θ2+1r21sin2(θ)∂2f∂ϕ2+2r∂f∂r+1r2cos(θ)sin(θ)∂f∂θ. | (14) |
We can write the Laplacian in an even more compact form as22Readers might be surprised how I got from expression (14) to expression (15) so fast! Even though it is true that expression (14) is equivalent
to expression (15), I wouldn’t have been able to write the expression (15) if I hadn’t known about it beforehand.
∇2f | = | 1r2∂∂r[r2∂f∂r]+1r2sin(θ)∂∂θ[sin(θ)∂f∂θ]+1r2sin2(θ)∂2f∂ϕ2. | (15) |
Title | derivation of the Laplacian from rectangular to spherical coordinates |
---|---|
Canonical name | DerivationOfTheLaplacianFromRectangularToSphericalCoordinates |
Date of creation | 2013-03-22 17:04:57 |
Last modified on | 2013-03-22 17:04:57 |
Owner | swapnizzle (13346) |
Last modified by | swapnizzle (13346) |
Numerical id | 11 |
Author | swapnizzle (13346) |
Entry type | Topic |
Classification | msc 53A45 |