Laplacian from Rectangular to Spherical Coordinates


The Laplacian from Rectangular to Spherical Coordinates Swapnil Sunil Jain June 4, 2006

Laplacian from Rectangular to Spherical Coordinates We begin by recognizing the familiar conversion from rectangular to spherical coordinatesMathworldPlanetmath11Note that convention in use here: ϕ is the azimuthal angle, whereas θ is 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 defined in the following way22Readers should note that we do not have to define the Laplacian this way. A more rigorous approach would be define the Laplacian using a coordinate-free expression.

2f = 2fx2+2fy2+2fz2. (3)

We also know that the partial derivativesMathworldPlanetmath in rectangular coordinates can be expanded in the following way by using the chain ruleMathworldPlanetmath

fx = frrx+fθθx+fϕϕx, (4)
fy = frry+fθθy+fϕϕy, (5)
fz = frrz+fθθz+fϕϕz. (6)

The next step is to manipulate the right-hand side of each of the above three equations so that it is only a function of r, θ and ϕ. We can do this by substituting the following expressions in their respective places in the above three equations33These expression can be derived simply by taking the proper derivative of the expressions in (2) and then substituting the expressions from (1) in order to eliminate any dependence on x, y, and z.

rx=sin(θ)cos(ϕ),θx=1rcos(θ)cos(ϕ),ϕx=-1rsin(ϕ)sin(θ),
ry=sin(θ)sin(ϕ),θy=1rcos(θ)sin(ϕ),ϕy=1rcos(ϕ)sin(θ),
rz=cos(θ),θz=-1rsin(θ),ϕz=0. (7)

After the substitution, equation (4) looks like the following

fx = sin(θ)cos(ϕ)fr+1rcos(θ)cos(ϕ)fθ-1rsin(ϕ)sin(θ)fϕ. (8)

Assuming that f is a sufficiently differentiable function, we can replace f by fx and arrive at the following

2fx2 = sin(θ)cos(ϕ)r[fx]+1rcos(θ)cos(ϕ)θ[fx]-1rsin(ϕ)sin(θ)ϕ[fx]. (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

2fx2 = sin(θ)cos(ϕ)r[sin(θ)cos(ϕ)fr+1rcos(θ)cos(ϕ)fθ-1rsin(ϕ)sin(θ)fϕ]+
1rcos(θ)cos(ϕ)θ[sin(θ)cos(ϕ)fr+1rcos(θ)cos(ϕ)fθ-1rsin(ϕ)sin(θ)fϕ]-
1rsin(ϕ)sin(θ)ϕ[sin(θ)cos(ϕ)fr+1rcos(θ)cos(ϕ)fθ-1rsin(ϕ)sin(θ)fϕ].

In the hopes of simplifying the above equation, we operate the derivatives on the operands and get

2fx2 = sin(θ)cos(ϕ)[sin(θ)cos(ϕ)2fr2-1r2cos(θ)cos(ϕ)fθ+1rcos(θ)cos(ϕ)2frθ+
1r2sin(ϕ)sin(θ)fϕ-1rsin(ϕ)sin(θ)2fϕr]+1rcos(θ)cos(ϕ)[cos(θ)cos(ϕ)fr+
sin(θ)cos(ϕ)2frθ-1rsin(θ)cos(ϕ)fθ+1rcos(θ)cos(ϕ)2fθ2+1rsin(ϕ)cos(θ)sin2(θ)fϕ-
1rsin(ϕ)sin(θ)2fθϕ]-1rsin(ϕ)sin(θ)[-sin(θ)sin(ϕ)fr+sin(θ)cos(ϕ)2frϕ-
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

2fx2 = [sin2(θ)cos2(ϕ)2fr2-1r2cos(θ)sin(θ)cos2(ϕ)fθ+1rcos(θ)sin(θ)cos2(ϕ)2frθ+
1r2sin(ϕ)cos(ϕ)fϕ-1rsin(ϕ)cos(ϕ)2fϕr]+[1rcos2(θ)cos2(ϕ)fr+
1rsin(θ)cos(θ)cos2(ϕ)2frθ-1r2sin(θ)cos(θ)cos2(ϕ)fθ+1r2cos2(θ)cos2(ϕ)2fθ2+
1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)fϕ-1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)2fθϕ]+[1rsin2(ϕ)fr-
1rsin(ϕ)cos(ϕ)2frϕ+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. 2fx2) in terms of spherical coordinates. We now have to do a similarMathworldPlanetmath arduous derivation for the rest of the two terms (i.e. 2fy2 and 2fz2). Lets do it!

After we substitute the values of (7) into equation (5) we get

fy = sin(θ)sin(ϕ)fr+1rcos(θ)sin(ϕ)fθ+1rcos(ϕ)sin(θ)fϕ. (10)

We then differentiate both sides with respect to y and arrive at the following

2fy2 = sin(θ)sin(ϕ)r[fy]+1rcos(θ)sin(ϕ)θ[fy]+1rcos(ϕ)sin(θ)ϕ[fy]. (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

2fy2 = sin(θ)sin(ϕ)r[sin(θ)sin(ϕ)fr+1rcos(θ)sin(ϕ)fθ+1rcos(ϕ)sin(θ)fϕ]+
1rcos(θ)sin(ϕ)θ[sin(θ)sin(ϕ)fr+1rcos(θ)sin(ϕ)fθ+1rcos(ϕ)sin(θ)fϕ]+
1rcos(ϕ)sin(θ)ϕ[sin(θ)sin(ϕ)fr+1rcos(θ)sin(ϕ)fθ+1rcos(ϕ)sin(θ)fϕ].

Now we operate the operators and get

2fy2 = sin(θ)sin(ϕ)[sin(θ)sin(ϕ)2fr2-1r2cos(θ)sin(ϕ)fθ+1rcos(θ)sin(ϕ)2frθ-
1r2cos(ϕ)sin(θ)fϕ+1rcos(ϕ)sin(θ)2frϕ]+1rcos(θ)sin(ϕ)[sin(θ)sin(ϕ)frθ+
cos(θ)sin(ϕ)fr-1rsin(θ)sin(ϕ)fθ+1rcos(θ)sin(ϕ)2fθ2-1rcos(ϕ)cos(θ)sin2(θ)fϕ+
1rcos(ϕ)sin(θ)2fθϕ]+1rcos(ϕ)sin(θ)[sin(θ)cos(ϕ)fr+sin(θ)sin(ϕ)2frϕ+
1rcos(θ)cos(ϕ)fθ+1rcos(θ)sin(ϕ)2fθϕ-1rsin(ϕ)sin(θ)fϕ+1rcos(ϕ)sin(θ)2fϕ2],

and after some simplifications

2fy2 = [sin2(θ)sin2(ϕ)2fr2-1r2sin(θ)cos(θ)sin2(ϕ)fθ+1rsin(θ)cos(θ)sin2(ϕ)2frθ-
1r2sin(ϕ)cos(ϕ)fϕ+1rsin(ϕ)cos(ϕ)2frϕ]+[1rcos(θ)sin(θ)sin2(ϕ)frθ+
1rcos2(θ)sin2(ϕ)fr-1r2sin(θ)cos(θ)sin2(ϕ)fθ+1r2cos2(θ)sin2(ϕ)2fθ2-
1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)fϕ+1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)2fθϕ]+[1rcos2(ϕ)fr+
1rcos(ϕ)sin(ϕ)2frϕ+1r2cos(θ)cos2(ϕ)sin(θ)fθ+1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)2fθϕ-
1r2sin(ϕ)cos(ϕ)sin2(θ)fϕ+1r2cos2(ϕ)sin2(θ)2fϕ2].

Now its time to derive 2fz2. After our substitution of value in (7) into equation (6) we get

fz = cos(θ)fr-1rsin(θ)fθ. (12)

We then differentiate both sides of the above equation with respect to z resulting in the following

2fz2 = cos(θ)r[fz]-1rsin(θ)θ[fz]. (13)

Now we substitute equation (12) into equation (13) in order to eliminate any partial derivatives with respect to z and we arrive at

2fz2 = cos(θ)r[cos(θ)fr-1rsin(θ)fθ]-
1rsin(θ)θ[cos(θ)fr-1rsin(θ)fθ].

After operating the operators we get

2fz2 = cos(θ)[cos(θ)2fr2+1r2sin(θ)fθ-1rsin(θ)2frθ]-
1rsin(θ)[-sin(θ)fr+cos(θ)2frθ-1rcos(θ)fθ-
1rsin(θ)2fθ2],

and then simplifying

2fz2 = [cos2(θ)2fr2+1r2cos(θ)sin(θ)fθ-1rcos(θ)sin(θ)2frθ]+[1rsin2(θ)fr-
1rsin(θ)cos(θ)2frθ+1r2sin(θ)cos(θ)fθ+1r2sin2(θ)2fθ2].

Now that we have all three terms of the right hand side of equation (3)(i.e. 2fx2, 2fy2 and 2fz2), we add them all together (because of equation (3)) to get the laplacian in terms of r, θ and ϕ

2f = [sin2(θ)cos2(ϕ)2fr2-1r2cos(θ)sin(θ)cos2(ϕ)fθ+1rcos(θ)sin(θ)cos2(ϕ)2frθ+
1r2sin(ϕ)cos(ϕ)fϕ-1rsin(ϕ)cos(ϕ)2fϕr]+[1rcos2(θ)cos2(ϕ)fr+
1rsin(θ)cos(θ)cos2(ϕ)2frθ-1r2sin(θ)cos(θ)cos2(ϕ)fθ+1r2cos2(θ)cos2(ϕ)2fθ2+
1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)fϕ-1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)2fθϕ]+[1rsin2(ϕ)fr-
1rsin(ϕ)cos(ϕ)2frϕ+1r2cos(θ)sin2(ϕ)sin(θ)fθ-1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)2fθϕ+
1r2sin(ϕ)cos(ϕ)sin2(θ)fϕ+1r2sin2(ϕ)sin2(θ)2fϕ2]+[sin2(θ)sin2(ϕ)2fr2-
1r2sin(θ)cos(θ)sin2(ϕ)fθ+1rsin(θ)cos(θ)sin2(ϕ)2frθ-1r2sin(ϕ)cos(ϕ)fϕ+
1rsin(ϕ)cos(ϕ)2frϕ]+[1rcos(θ)sin(θ)sin2(ϕ)frθ+1rcos2(θ)sin2(ϕ)fr-
1r2sin(θ)cos(θ)sin2(ϕ)fθ+1r2cos2(θ)sin2(ϕ)2fθ2-1r2sin(ϕ)cos(ϕ)cos2(θ)sin2(θ)fϕ+
1r2cos(θ)sin(ϕ)cos(ϕ)sin(θ)2fθϕ]+[1rcos2(ϕ)fr+1rcos(ϕ)sin(ϕ)2frϕ+
1r2cos(θ)cos2(ϕ)sin(θ)fθ+1r2cos(θ)cos(ϕ)sin(ϕ)sin(θ)2fθϕ-1r2sin(ϕ)cos(ϕ)sin2(θ)fϕ+
1r2cos2(ϕ)sin2(θ)2fϕ2]+[cos2(θ)2fr2+1r2cos(θ)sin(θ)fθ-1rcos(θ)sin(θ)2frθ]+
[1rsin2(θ)fr-1rsin(θ)cos(θ)2frθ+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 expression and we finally arrive at the Laplacian in spherical coordinates!

2f = 2fr2+1r22fθ2+1r21sin2(θ)2fϕ2+2rfr+1r2cos(θ)sin(θ)fθ. (14)

By further manipulating the above expression, we can write the Laplacian in a more compact form as

2f = 1r2r[r2fr]+1r2sin(θ)θ[sin(θ)fθ]+1r2sin2(θ)2fϕ2. (15)
Title Laplacian from Rectangular to Spherical Coordinates
Canonical name LaplacianFromRectangularToSphericalCoordinates1
Date of creation 2013-03-11 19:24:44
Last modified on 2013-03-11 19:24:44
Owner swapnizzle (13346)
Last modified by (0)
Numerical id 1
Author swapnizzle (0)
Entry type Definition