Do It by Yourself: An Instructional Derivation of the Laplacian Operator in Spherical Polar Coordinates

For scientists and engineers, the Laplacian operator is a fundamental tool that has made it possible to carry out important frontier studies involving wave propagation, potential theory, heat conduction, the distribution of stresses in a deformable solid and quantum mechanics. Knowing, understanding, and manipulating the Laplacian operator allows us to tackle complex and exciting physics, chemistry, and engineering problems. In this paper, contained in the Special Issue “Mathematics as the M in STEM Education”, we present an instructional derivation of the Laplacian operator in spherical coordinates. Our derivation is self-contained and employs well-known mathematical concepts used in all science, technology, engineering, and mathematics (STEM) disciplines. Our lengthy but straightforward procedure shows that this fundamental tool in mathematics is not intractable but accessible to anyone who studies any of the STEM disciplines. We consider that this work may be helpful for students and teachers who wish to discuss the derivation of this vital tool from an elementary approach in their courses.


Introduction
The acronym STEM stands for science, technology, engineering, and mathematics. Surprisingly, in STEM, math appears as a separate area and at the very end; this is possibly because, that way, the acronym is easier to remember and sounds better. However, it is not difficult to identify that, factually, mathematics is present in each discipline that makes up the STEM acronym. It is complicated to imagine a programming specialist who does not extensively use mathematics. The same is true for a physicist, a chemist, or any bachelor's degree in engineering.
The number of branches studied and investigated in mathematics is enormous and continues to grow. However, a good part of the mathematics belonging to science, technology, and engineering (STE) is literally used as a tool to solve specific problems. In this regard, there are mathematical tools that, due to their "generality", are present in all fields of STE, such as arithmetic, or basic algebra. Nevertheless, it is also possible to find "more sophisticated" mathematical tools that, in the same way, are present in all science, technology and engineering disciplines, such as in the case of the Laplacian operator.
The Laplacian operator is a differential operator that accepts one function and returns another. Usually, we find the Laplacian operator in partial differential equations. In fact, most of the time, we find it operating on the unknown function of the differential equation in question. It is precisely for this reason that its applications are wide and varied. Among these are fluid dynamics and heat conduction [1], electromagnetism [2,3], modern physics [4][5][6][7], condensed matter [8], general relativity [9], structure of matter [10] and quantum mechanics [11][12][13][14]. When one faces the task of solving a partial differential equation, the first thing to try is to propose a solution function composed of the multiplication of single-variable functions. When that is possible, the partial differential equation can be decomposed into a set of ordinary differential equations, which are more accessible to solve and whose solutions constitute the solution of the original partial differential equation. On many occasions, the above decomposition is NOT possible in a certain coordinate system, but it is possible in another. Therefore, it is advantageous to know the forms this differential operator (Laplacian) can take in different coordinate systems.
There are many spherical symmetries present in our universe; therefore, it is of particular interest to the science, technology, and engineering disciplines to know and understand the Laplacian operator's form in spherical polar coordinates. Its correct use has led to the generation of essential knowledge for humanity. For example, the quantum mechanical interpretation of the periodic table would not have been possible without the analytical solution of the Schrödinger equation for the hydrogen atom and the subsequent self-consistent calculations proposed by Hartree for multielectron atoms [15][16][17]. The Laplacian in spherical coordinates is also necessary for designing devices that involve beams of charged particles and in various electrostatic problems [18,19].
With the above examples, the reader might not be wholly convinced of the ubiquity of the Laplacian in STEM areas. However, talking purely about technology, it is imperative to mention that the Laplacian operator is a fundamental tool for image processing, which allows the quality of thousands of products worldwide to be controlled. In its discretized form in spherical coordinates, the Laplacian operator can process images from fisheye cameras [20], which would be very useful in video surveillance systems. The technological applications do not end there. In atmospheric sciences, the Laplacian operator in spherical coordinates is used to make models that allow us to determine how the shape of raindrops changes. It is important to know these oscillations in shape because they can influence the propagation of electromagnetic radiation used in telecommunications [21]. The list could go on; however, what is evident is that knowing, understanding, and manipulating the Laplacian operator provides scientists and engineers with a powerful tool that allows them to tackle interesting problems related to the STEM disciplines. In our experience as teachers, we have perceived that, although the tool is contained in multiple math software, graphing calculators, and a plethora of math formula handbooks, knowing the guts of its origin allows students to handle the operator with much more skill. Therefore, this paper presents an instructional and full-fledged derivation of the Laplacian operator in spherical polar coordinates starting from the Laplacian operator in rectangular coordinates. Although the subject has been extensively treated within the literature, here, we present it with an approach that attempts to reconcile the lack of detail with which most popular books on mathematics and physics address it [22,23], with the "sophistication" of shorter derivations that make use of non-trivial concepts such as the theory of complex variable [24], or the total angular momentum operator [25]. The strategy we follow was developed over several years of experience in teaching courses in mathematics, quantum physics, the structure of matter, electron microscopy, computer-aided design, and resistance of materials. Our self-contained procedure uses standard mathematical tools available from the second year of undergraduate studies. In addition, detailed explanations are implicitly included to attempt to solve doubts that recurrently appear during our courses. We believe that this work could be helpful for the self-taught student and for academics who wish to present it fully to students whose work involves using this important tool.

Discussion
We start by recalling the Nabla operator: The above expression tells us that, if we apply the Nabla operator to a scalar function f, we obtain a vector that indicates the direction of maximum increment of the function f. Meanwhile, the Laplacian operator is the divergence of the gradient of a scalar function, that is, If we apply the Laplacian to a scalar function, we have a scalar.
We should identify that, in this last expression, the unit vectorsî,ĵ,k no longer appear and the results of the three-second partial derivatives are added. Consequently, the Laplacian operator in spherical polar coordinates also has to give us a scalar quantity. Unfortunately, the Laplacian operator of a function that depends on "r, θ" and "φ" is NOT obtained by applying the definition of the Laplacian in rectangular coordinates.

Discussion
We start by recalling the Nabla operator: The above expression tells us that, if we apply the Nabla operator to a scalar function f, we obtain a vector that indicates the direction of maximum increment of the function f. Meanwhile, the Laplacian operator is the divergence of the gradient of a scalar function, that is, If we apply the Laplacian to a scalar function, we have a scalar.
We should identify that, in this last expression, the unit vectors ,, no longer appear and the results of the three-second partial derivatives are added. Consequently, the Laplacian operator in spherical polar coordinates also has to give us a scalar quantity. Unfortunately, the Laplacian operator of a function that depends on "r, θ" and "ϕ" is NOT obtained by applying the definition of the Laplacian in rectangular coordinates.
∂ϕ 2 In order to derive the definition of the Laplacian operator in spherical polar coordinates, it is necessary to apply some simple rules of differential calculus with which every high school student is familiar.
In rectangular coordinates, we have that ∇ 2 f (x, y, z)= ∂z 2 , when f depends on x, y, z; however, we should carry out a coordinate change when f depends on "r," "θ" and "ϕ", i.e., spherical polar coordinates. This change of coordinates can be treated as a variable change in the function we seek to derive. Let us recall the chain rule using Leibniz's notation: The above rule tells us that, if, initially, f is a function of x and we make a change in the variable from x to u, then we have to derive ( ) and multiply by the derivative of u with respect to x . When we change variables from x, y, z to r, θ, ϕ, we have to identify that each rectangular variable is expressed using the three spherical variables. In other words, to describe the x coordinate in spherical coordinates, one has to give a value for r, another for θ and another for ϕ; the same occurs for y and z coordinates. Therefore, to find the derivative of ( , , ) with respect to x, we apply the chain rule three times. The same is true for y and for z. Let  In order to derive the definition of the Laplacian operator in spherical polar coordinates, it is necessary to apply some simple rules of differential calculus with which every high school student is familiar.
In rectangular coordinates, we have that ∇ 2 f (x, y, z) = ∂ 2 f ∂x 2 + ∂ 2 f ∂y 2 + ∂ 2 f ∂z 2 , when f depends on x, y, z; however, we should carry out a coordinate change when f depends on "r," "θ" and "φ", i.e., spherical polar coordinates. This change of coordinates can be treated as a variable change in the function we seek to derive. Let us recall the chain rule using Leibniz's notation: df dx = df du du dx The above rule tells us that, if, initially, f is a function of x and we make a change in the variable from x to u, then we have to derive f (u) du and multiply by the derivative of u with respect to x du dx . When we change variables from x, y, z to r, θ, φ, we have to identify that each rectangular variable is expressed using the three spherical variables. In other words, to describe the x coordinate in spherical coordinates, one has to give a value for r, another for θ and another for φ; the same occurs for y and z coordinates. Therefore, to find the derivative of f (r, θ, φ) with respect to x, we apply the chain rule three times. The same is true for y and for z. Let us see that

Discussion
We start by recalling the Nabla operator: The above expression tells us that, if we apply the Nabla oper f, we obtain a vector that indicates the direction of maximum incr Meanwhile, the Laplacian operator is the divergence of the gradi that is, If we apply the Laplacian to a scalar function, we have a scala We should identify that, in this last expression, the unit v appear and the results of the three-second partial derivatives are the Laplacian operator in spherical polar coordinates also has to g Unfortunately, the Laplacian operator of a function that depends o obtained by applying the definition of the Laplacian in rectangula ∂ϕ 2 In order to derive the definition of the Laplacian opera coordinates, it is necessary to apply some simple rules of different every high school student is familiar.
In rectangular coordinates, we have that ∇ 2 f (x, y, z)= ∂y on x, y, z; however, we should carry out a coordinate change whe and "ϕ", i.e., spherical polar coordinates. This change of coordin variable change in the function we seek to derive. Let us reca Leibniz's notation: The above rule tells us that, if, initially, f is a function of x an the variable from x to u, then we have to derive ( ) and multipl with respect to x . When we change variables from x, y, z to r, θ, ϕ, we hav rectangular variable is expressed using the three spherical variab describe the x coordinate in spherical coordinates, one has to giv for θ and another for ϕ; the same occurs for y and z coordinates derivative of ( , , ) with respect to x, we apply the chain rule is true for y and for z. Let  To carry out this task, we must first express r, θ, φ in terms of x, y, z and vice versa, i.e., to pose the coordinate transformations. Figure 1 shows a point P in a three-dimensional space where the coordinates x, y, z, and r, θ, φ are indicated for the same point. To carry out this task, we must first express r, θ, ϕ in terms of x, y, z and vice versa, i.e., to pose the coordinate transformations. Figure 1 shows a point P in a three-dimensional space where the coordinates x, y, z, and r, θ, ϕ are indicated for the same point. We can relate the x, y, z coordinates with r, θ, ϕ using the different colored triangles that appear in Figure 1. Using the same color code, we can redraw, in 2D, the triangles of   We can relate the x, y, z coordinates with r, θ, φ using the different colored triangles that appear in Figure 1. Using the same color code, we can redraw, in 2D, the triangles of  To carry out this task, we must first express r, θ, ϕ in terms of x, y, z and vice versa, i.e., to pose the coordinate transformations. Figure 1 shows a point P in a threedimensional space where the coordinates x, y, z, and r, θ, ϕ are indicated for the same point. We can relate the x, y, z coordinates with r, θ, ϕ using the different colored triangles that appear in Figure 1. Using the same color code, we can redraw, in 2D, the triangles of    From Figure 2, it is easy to identify that the change of coordinates from x, y, z to r, θ, ϕ is as follows: x=r sin θ cos ϕ y=r sin θ sin ϕ z=r cos θ  From Figure 2, it is easy to identify that the change of coordinates from x, y, z to r, θ, φ is as follows: x = r sin θ cos φ y = r sin θ sin φ z = r cos θ To express r, θ, φ in terms of x, y, z, we can also use Figures 2 and 3. From Figure 2, it is possible to identify that ρ 2 = x 2 + y 2 and, from Figure 3, one can observe that ρ 2 + z 2 = r 2 ; consequently, we can write r 2 = x 2 +y 2 +z 2 Using Figure 2, we can also write We are now able to fully express the transformations from rectangular to spherical coordinates and vice versa. From Figure 2, it is easy to identify that the change of coordinates from x, y, z to r, θ ϕ is as follows: x=r sin θ cos ϕ y=r sin θ sin ϕ z=r cos θ To express r, θ, ϕ in terms of x, y, z, we can also use Figures 2 and 3. From Figure 2 it is possible to identify that ρ 2 =x 2 +y 2 and, from Figure 3, one can observe that ρ 2 +z 2 =r 2 consequently, we can write r 2 =x 2 +y 2 +z 2 Using Figure 2, we can also write cos θ = z r  = cos 1 z x 2 +y 2 +z 2 1 2 and tan ϕ= y x  ϕ= tan 1 y x We are now able to fully express the transformations from rectangular to spherical coordinates and vice versa.
x=r sin θ cos ϕ ; r= x 2 +y 2 +z 2 y=r sin θ sin ϕ = cos 1 z With the coordinate transformations of Equation (2), we can calculate the nine derivatives of the "new variables" (r, θ, φ) with respect to the "old variables" (x, y, z). Let us start with ∂r ∂x : ∂r ∂x Let us make a change of variable as follows: u = x 2 +y 2 +z 2 , then we have By implicit derivation, it is known that the derivative of the arc cosine is defined as follows: For our case, we have to perform the following: Let us make a change of variable as follows: u = x 2 +y 2 +z 2 , hence we have to calculate 3 2 We know that u We insert this last result in the expression for the derivative of the arc cosine and we have Negative signs cancel out and it results Remember that z = r cos θ and x = r sin θ cosφ, while z r = cos θ; thus, Since sin 2 θ + cos 2 θ = 1, then sin 2 θ = 1 − cos 2 θ and sin θ = ∂θ ∂y Using the definition for the derivative of the arc cosine, we have Applying it to our case, For ∂ ∂y z r , we do not repeat the derivative because the procedure is exactly the same as that for the variable x. We just have to substitute x for y. Therefore, Inserting this result into the expression for the derivative of the arc cosine, we have We know that z = r cos θ; y = r sin θ sinφ; z r = cos θ; sin θ = √ 1 − cos 2 θ. The last expression we rewrite as follows: Now, we carry out the corresponding procedure for ∂θ ∂z .
∂θ ∂z Again, we use the definition for the derivative of the arc cosine.
Applying it to our case, we have Mathematics 2021, 9, 2943 8 of 32 We know that z r = cos θ; then the denominator is √ 1 − cos 2 θ . We know that sin θ = √ 1 − cos 2 θ; so, from now on, we can write In the previous cases, z was a constant and left the derivative. Now, we have that z is a variable, so we have to use the quotient rule for derivatives. Let us remember the quotient rule.
So, for our case, we have Let us perform separately the only partial derivative that appears in the numerator: We use the following variable change: u = x 2 +y 2 +z 2 , then: We insert this last result in the quotient expression to have: Remember that z = r cos θ; thus, Dividing the numerator and denominator by r, we have We insert this last result in the expression for the original derivative of the arcsine and we have: We make a change of variable: u = y x , then: For ∂ ∂u tan −1 (u) , let us remember that there is a formula for the derivative of the tangent arc of a function, which is So, in our case, it is applied directly.
Substituting both results in our original expression we have: Recall again that y = r sin θ sinφ and x = r sin θ cosφ , then we have: Substituting both results in our original expression: Multiplying by x numerator and denominator, ∂φ ∂y Recall again that y = r sin θ sinφ and x = r sin θ cosφ, Since the variable z does not appear in the expression, then tan −1 y x is constant; therefore, we can write ∂φ ∂z = 0 So far, we calculated the nine derivatives of the "new" variables with respect to the "old" ones. We present them together in Equation (3). So far, we calculated the nine derivatives of the "new" variables with respect to the "old" ones. We present them together in Equation (3).
We should now use the nine equations presented in Equation (3) We should now use the nine equations presented in Equation (3) Let us notice that, on the right side of the above equation, we still have one of the "old" variables, which is x. Therefore, we need to replace it using the coordinate transformation that we presented in Equation (2).
In the last expression for ∂ f ∂x , we derive f with respect to x. Now, we can express it as an operator, so that it "operates" on whatever function appearing to its right. For this, it is only necessary to remove the function f.
Let us recall the Laplacian operator in rectangular coordinates: Let us recall the Laplacian operator in rectangular coordinates: The Laplacian operates "twice" on the scalar function. We can interpret it as a "multiplication" of two Nabla operators.
We use the same concept to obtain the Laplacian operator in spherical coordinates. To make this procedure easily digestible, we divided it in sections.

Section corresponding to
We must operate term by term. Observe that since we have three terms, in each ∂ ∂x we will have nine terms at the end. Let us proceed. The Laplacian operates "twice" on the scalar function. We can interpret it as a "multiplication" of two Nabla operators.

First-term operating on the first term for
We use the same concept to obtain the Laplacian operator in spherical coordinates. To make this procedure easily digestible, we divided it in sections.
Section corresponding to Please remember that at this moment, we are "operating" the second term on the first term. In other words, in this particular case, the first term belonging to ∂ ∂x appears to the right of the second term belonging to ∂ ∂x . Let us treat the first term as a multiplication of functions, as follows: sinθ cosϕ r 2 sinθ ∂ϕ − r sinθ ∂r ∂ϕ Performing just the derivative instruction: Performing just the derivative instruction: Inserting the result of our derivative in the original expression: We treat the second term as a multiplication of two functions: Let us treat the second term as a multiplication of two functions: Performing just the derivative instruction: Inserting the result of our derivative in the original expression: Performing just the derivative instruction: Second-term operating on the second term .
Let us treat the second term as a multiplication of two functions: Performing just the derivative instruction: Inserting the result of our derivative in the original expression: Performing just the derivative instruction: Inserting the result of our derivative in the original expression: Expanding, 1 r 2 cos θ sin θ We organize our terms using a convention of colors and lines as presented in Figure 4.