Chapter 6: Delta Function
NOTE: Math will not display properly in Safari  please use another browser
The material covered in this chapter is also presented in Boas Chapter 8, Section 11.
6.1 Introduction
A typical introductory course in electromagnetism begins with a discussion of Coulomb's law and the electric field produced by point charges. Eventually a very large number of these charges are introduced, too many to count, and the description of the charge distribution switches to the volume density of charge $\rho(\boldsymbol{r})$. This is defined to be the total charge $dq$ in a small volume $dV$ at position $\boldsymbol{r}$, divided by the volume $dV$. The charge density can vary from place to place, and is therefore a function of the position vector. With this language in place, one proceeds with a formulation of Gauss's law. Its differential form,
\begin{equation} \boldsymbol{\nabla} \cdot \boldsymbol{E} = \rho/\epsilon_0, \tag{6.1} \end{equation}
There is long way from Coulomb's law to Gauss's law, but is there a way back? In other words, can we apply Eq.(6.1) to a point charge, and verify that the solution for $\boldsymbol{E}$ is the expected statement of Coulomb's law? The answer is in the affirmative, but it requires us to understand what we might mean by the charge density of a point charge. Suppose that a charge $q_1$ is situated at $\boldsymbol{r}=\boldsymbol{r}_1$. When $\rho(\boldsymbol{r})$ is evaluated at any position $\boldsymbol{r} \neq \boldsymbol{r}_1$ away from the charge, it returns zero: there is no charge at that position. But when $\rho(\boldsymbol{r})$ is evaluated at $\boldsymbol{r} = \boldsymbol{r}_1$, it returns infinity: the charge $q_1$ occupies a zero volume $dV$, and $\rho = q_1/dV = \infty$. The density of a point charge is therefore a function that is zero everywhere, except at the position of the charge where it is infinite. This, to be sure, is a strange mathematical object, with which we must come to terms before we can hope to apply Eq.(6.1) directly to a point charge.
A function that vanishes everywhere except at a single point, where it is infinite, is known as a delta function, and it is the topic of this chapter. The delta function was famously introduced in physics by Dirac, and the idea was initially received with much suspicion by mathematicians. Eventually the idea was given a rigorous mathematical foundation, and incorporated into the framework of distribution theory.
6.2 Step Function
We begin by introducing the step function $\theta(x)$, defined by
\begin{equation} \theta(x) = \left\{ \begin{array}{ll} 1 & \quad x > 0 \\ 0 & \quad x < 0 \end{array} \right. . \tag{6.2} \end{equation}
The function is zero when $x$ is negative, and it suddenly jumps to one when $x$ turns positive; its value is indeterminate at $x=0$. The step function is an example of a discontinuous function. It is often used inside integrals to restrict the range of integration. For example,
\begin{equation} \int_{\infty}^\infty f(x) \theta(x)\, dx = \int_0^\infty f(x)\, dx, \tag{6.3} \end{equation}
where $f(x)$ is any smooth function that vanishes at infinity, to ensure the convergence of the integral. Such ``nice'' functions are known as test functions, and they shall play an important role in this chapter.
The discontinuity of the step function can easily be moved from $x=0$ to $x = a$ by shifting its argument to $xa$. The definition of Eq.(6.2) implies that
\begin{equation} \theta(xa) = \left\{ \begin{array}{ll} 1 & \quad xa > 0 \quad \rightarrow \quad x > a \\ 0 & \quad x a < 0 \quad \rightarrow \quad x < a \end{array} \right. . \tag{6.4} \end{equation}
Its action within an integral is given by
\begin{equation} \int_{\infty}^\infty f(x) \theta(xa)\, dx = \int_a^\infty f(x)\, dx. \tag{6.5} \end{equation}
6.3 Delta Function
The delta function $\delta(x)$ is defined as the derivative of $\theta(x)$ with respect to $x$. Because the step function is constant for $x > 0$ and $x < 0$, the delta function vanishes almost everywhere. But the step function jumps discontinuously at $x=0$, and this implies that its derivative is infinite at this point. We therefore have
\begin{equation} \delta(x) := \frac{d}{dx} \theta(x) = \left\{ \begin{array}{ll} 0 & \quad x \neq 0 \\ \infty & \quad x = 0 \end{array} \right. . \tag{6.6} \end{equation}
This is clearly the type of mathematical object we were looking for.
Like the step function, the delta function is often used inside integrals. (Mathematicians tell us that It should always be used inside integrals, and never be left alone in the wild. Physicists are more pragmatic.) We will show that
\begin{equation} \int_{\infty}^\infty f(x) \delta(x)\, dx = f(0), \tag{6.7} \end{equation}
and this is the most important property of the delta function. In effect, the equation states that the delta function is sufficiently singular to single out only $f(0)$ from the entire range of values assumed by the test function. The equation also tells us that the delta function is not so singular as to return an infinite integral. A special case of Eq.(6.7) is
\begin{equation} \int_{\infty}^\infty \delta(x)\, dx = 1, \tag{6.8} \end{equation}
and this equation reveals that although the delta function is infinite at $x=0$, The ``area under the curve'' is nevertheless equal to one. This can be understood intuitively: the height of the function is infinite, but its width is zero, so its area $A = \infty \cdot 0$ can be interpreted as a finite number.
To establish Eq.(6.7) we make use of the definition of Eq.(6.6), and write
\begin{equation} \int_{\infty}^\infty f(x) \delta(x)\, dx =\int_{\infty}^\infty f(x) \theta'(x)\, dx, \tag{6.9} \end{equation}
with a prime indicating differentiation with respect to $x$. We may write $f \theta' = (f\theta)'  f'\theta$ and integrate by parts. This gives
\begin{align} \int_{\infty}^\infty f(x) \delta(x)\, dx &= f\theta \biggr^\infty_{\infty}  \int_{\infty}^\infty f' \theta\, dx \nonumber \\ &= f(\infty)  \int_0^\infty f'\, dx \nonumber \\ &= f(\infty)  f \biggr^\infty_0 \nonumber \\ &= f(0), \tag{6.10} \end{align}
and we have obtained Eq.(6.7). In the second step we used the fact that $\theta(\infty) = 0$ and the property of the step function expressed by Eq.(6.3). In the third step we evaluated the integral, and in the last step we cancelled out the boundary terms at $x=\infty$. This demonstration is typical of manipulations involving delta and step functions inside integrals; integration by parts is your friend.
The singularity of the delta function can easily be moved from $x=0$ to $x=a$ by shifting its argument to $xa$, just as we did for the step function. The displaced delta function is defined by
\begin{equation} \delta(xa) := \frac{d}{dx} \theta(xa) = \left\{ \begin{array}{ll} 0 & \quad x \neq a \\ \infty & \quad x = a \end{array} \right. , \tag{6.11} \end{equation}
and its action within an integral is given by
\begin{equation} \int_{\infty}^\infty f(x) \delta(xa)\, dx = f(a). \tag{6.12} \end{equation}
In this equation (and others involving the delta function), the domain of integration is taken to be from $x=\infty$ to $x=+\infty$. But it is clear that all the action takes place at $x=a$, and that the domain could be limited to any interval that includes $x=a$. If, however, the interval were to exclude $x=a$, then the delta function would be zero everywhere in that interval, and the integral would vanish. We therefore have
\begin{equation} \int_{x_1}^{x_2} f(x) \delta(xa)\, dx = \left\{ \begin{array}{ll} f(a) & \quad \mbox{when $(x_1, x_2)$ includes $x=a$}\\ 0 & \quad \mbox{when $(x_1, x_2)$ excludes $x=a$} \end{array} \right. \tag{6.13} \end{equation}
as an alternative expression of Eq.(6.12).
Exercise 6.1: Prove Eq.(6.12). There are two ways to proceed. The first is to follow the same steps that led us to Eq.(6.7). The second is to change the variable of integration in Eq.(6.12). Do it both ways.
In addition to Eq.(6.12), the delta function satisfies the properties
\begin{equation} \delta(ax) = \delta(xa), \qquad \delta(c x) = \frac{1}{c} \delta(x). \tag{6.14} \end{equation}
The way to prove identities such as these is always to show that the quantity on the lefthand side has the same action within an integral as the quantity on the righthand side. Let us, for example, consider the first identity. The delta function on the lefthand side is $\delta(ax)$, and its action on a test function $f(x)$ is
\[ \int_{\infty}^\infty f(x) \delta(ax)\, dx. \]
To evaluate this we change the integration variable to $y = ax$, so that $x = ay$ and $dx = dy$. The integral becomes
\begin{equation} \int_{+\infty}^{\infty} f(ay) \delta(y)\, (dy) = \int_{\infty}^{+\infty} f(ay) \delta(y)\, dy = f(a  y) \biggr_{y=0} = f(a). \tag{6.15} \end{equation}
The same result is obtained by letting $\delta(xa)$ act on the test function, and we conclude that $\delta(ax) = \delta(xa)$, as claimed.
Exercise 6.2: Prove that $\delta(c x) = \delta(x)/c$. Consider both cases, $c$ positive and $c$ negative, separately.
Exercise 6.3: Evaluate $\int_0^\infty x^3 \delta(x^21)\, dx$. This requires some care. There is a temptation to conclude that since the delta function is singular at $x = 1$, the integral should evaluate to $1$. This is wrong. To get the correct answer, change the integration variable to $y := x^21$ so that the argument of the delta function becomes simple. What happens if the integral is taken from $x=\infty$ to $x=+\infty$? Hint: the function $y(x)$ is multivalued in this interval.
Exercise 6.4: Evaluate $\int_{\pi/2}^{\pi/2} \cos^2\theta\, \delta(\sin\theta)\, d\theta$.
6.4 Derivatives of the Delta Function
The delta function is the derivative of the step function, and it is much more singular than the step function. You may think that to keep differentiating the delta function would be asking for trouble, but in fact we can make sense of such wildly singular objects.
The strategy is always to ask what action the object would have on a test function, when placed inside an integral. Let us consider $\delta'(xa)$, with the prime indicating differentiation with respect to $x$. To evaluate $\int f \delta'\, dx$ we express the integrand as $(f\delta)'  f' \delta$ and integrate by parts. The boundary terms at $x = \pm\infty$ contribute nothing, because the delta function vanishes there, and the remaining integral returns $f'$ evaluated at $x=a$. We have obtained
\begin{equation} \int_{\infty}^\infty f(x) \delta'(xa)\, dx = f'(a), \tag{6.16} \end{equation}
an identity that allows us to make sense of $\delta'(x)$.
The procedure can be applied to any number of derivatives of the delta function. For example,
\begin{equation} \int_{\infty}^\infty f(x) \delta''(xa)\, dx = f''(a), \qquad \int_{\infty}^\infty f(x) \delta'''(xa)\, dx = f'''(a), \tag{6.17} \end{equation}
and so on.
Exercise 6.5: Prove the preceding results.
6.5 Three Dimensional Delta Function
The delta function can be promoted to a threedimensional version. We simply merge three of them together, one for each dimension. The definition is
\begin{equation} \delta(\boldsymbol{r}\boldsymbol{r'}) := \delta(xx') \delta(yy') \delta(zz'), \tag{6.18} \end{equation}
where $(x, y, z)$ are the variables contained in $\boldsymbol{r}$, while $(x',y',z')$ are those contained in $\boldsymbol{r'}$. The threedimensional delta function refers to two positions in space, and it can be considered a function of either $\boldsymbol{r}$ or $\boldsymbol{r'}$; it is an example of a twopoint function. Its action on a test function $f(\boldsymbol{r})$ is given by
\begin{equation} \int f(\boldsymbol{r}) \delta(\boldsymbol{r}\boldsymbol{r'})\, dV = f(\boldsymbol{r'}), \tag{6.19} \end{equation}
where the integration is over threedimensional space, and $dV := dxdydz$ is the volume element.
Equation (6.19) is a natural generalization of Eq.(6.12), but it is in fact a direct consequence. To see this, let us write $f(\boldsymbol{r})$ explicitly as $f(x,y,z)$, and insert the definition of Eq.(6.18). We get
\begin{equation} \int f(\boldsymbol{r}) \delta(\boldsymbol{r}\boldsymbol{r'})\, dV = \int_{\infty}^\infty \int_{\infty}^\infty \int_{\infty}^\infty f(x,y,z) \delta(xx') \delta(yy') \delta(zz')\, dxdydz, \tag{6.20} \end{equation}
and we can do each integral one by one. Performing the $x$integral gives
\begin{equation} \int f(\boldsymbol{r}) \delta(\boldsymbol{r}\boldsymbol{r'})\, dV = \int_{\infty}^\infty \int_{\infty}^\infty f(x',y,z) \delta(yy') \delta(zz')\, dydz, \tag{6.21} \end{equation}
with the function now evaluated at $x=x'$. Performing the $y$integral gives
\begin{equation} \int f(\boldsymbol{r}) \delta(\boldsymbol{r}\boldsymbol{r'})\, dV = \int_{\infty}^\infty f(x',y',z) \delta(zz')\, dz, \tag{6.22} \end{equation}
and the last step returns
\begin{equation} \int f(\boldsymbol{r}) \delta(\boldsymbol{r}\boldsymbol{r'})\, dV = f(x',y',z') = f(\boldsymbol{r'}), \tag{6.23} \end{equation}
as expected.
Equation (6.19) must be valid in any coordinate system, not just the Cartesian system that has been in use up to now. In a general system of orthogonal coordinates the equation becomes
\begin{equation} \int f(q_1, q_2, q_3) \delta(\boldsymbol{r}\boldsymbol{r'})\, dV = f(q_1', q_2', q_3'), \tag{6.24} \end{equation}
where $(q_1, q_2, q_3)$ are the coordinates associated with $\boldsymbol{r}$, while $(q_1', q_2', q_3')$ are those associated with $\boldsymbol{r'}$. We saw back in Sec.1.3  refer to Eq.(1.45)  that the volume element is given by $dV = (h_1 h_2 h_3)\, dq_1 dq_2 dq_3$ in the new system, where $h_1$, $h_2$, and $h_3$ are the scale factors. A more concrete version of the equation is therefore
\begin{equation} \int \int \int f(q_1, q_2, q_3) \delta(\boldsymbol{r}\boldsymbol{r'})\, h_1 h_2 h_3\, dq_1 dq_2 dq_3 = f(q_1', q_2', q_3'), \tag{6.25} \end{equation}
and we wish to relate $\delta(\boldsymbol{r}\boldsymbol{r'})$ to the individual delta functions $\delta(q_1  q_1')$, $\delta(q_2  q_2')$, and $\delta(q_3  q_3')$. Because
\begin{equation} \int f(q_j) \delta(q_j  q_j')\, dq_j = f(q_j') \tag{6.26} \end{equation}
holds as a matter of identity  this is simply Eq.(6.12) in an alternative notation  we must have that
\begin{equation} \delta(\boldsymbol{r}\boldsymbol{r'}) = \frac{\delta(q_1  q_1')}{h_1} \frac{\delta(q_2  q_2')}{h_2} \frac{\delta(q_3  q_3')}{h_3} \tag{6.27} \end{equation}
in the orthogonal coordinates. It is easy to see that substitution of Eq.(6.27) into the integral on the lefthand side of Eq.(6.25) returns $f(q_1', q_2', q_3')$, in agreement with the righthand side.
6.6 $\nabla^2 r^{1}$
The Laplacian of $1/r$, where $r := \boldsymbol{r}$ is the distance from the origin of a point $P$ with position vector $\boldsymbol{r}$, is a curious object that can be related to the threedimensional delta function. We shall show that $\mu := \nabla^2 r^{1}$ vanishes everywhere except at the origin, where it is infinite. The precise link with the delta function will be revealed at the end of this discussion.
The vector field
\begin{equation} \boldsymbol{v} := \boldsymbol{\nabla} r^{1} \tag{6.28} \end{equation}
has a divergence given by $\boldsymbol{\nabla} \cdot \boldsymbol{v} = \boldsymbol{\nabla} \cdot (\boldsymbol{\nabla} r^{1}) = \nabla^2 r^{1} = \mu$. We may calculate its components with the help of
\begin{equation} \boldsymbol{\nabla} f = \frac{\partial f}{\partial r}\, \boldsymbol{\hat{r}} + \frac{1}{r} \frac{\partial f}{\partial \theta}\, \boldsymbol{\hat{\theta}} + \frac{1}{r\sin\theta} \frac{\partial f}{\partial \phi}\, \boldsymbol{\hat{\phi}}, \tag{6.29} \end{equation}
which gives the gradient of a function $f$ in spherical coordinates  refer back to Sec.1.8. Because $f := r^{1}$ depends on $r$ only, we get
\begin{equation} \boldsymbol{v} = r^{2}\, \boldsymbol{\hat{r}}, \tag{6.30} \end{equation}
and we see that the vector field diverges when $r=0$. In fact, the expression becomes meaningless at the origin, where the vector $\boldsymbol{\hat{r}}$ points in all directions at once, and to be safe we shall consider that Eq.(6.30) applies only when $r \neq 0$.
We next calculate $\boldsymbol{\nabla} \cdot \boldsymbol{v}$ with the help of
\begin{equation} \boldsymbol{\nabla} \cdot \boldsymbol{v} = \frac{1}{r^2} \frac{\partial}{\partial r} \bigl( r^2\, v_r \bigr) + \frac{1}{r\sin\theta} \frac{\partial}{\partial \theta} \bigl( \sin\theta\, v_\theta \bigr) + \frac{1}{r\sin\theta} \frac{\partial v_\phi}{\partial \phi}, \tag{6.31} \end{equation}
the expression of the divergence in spherical coordinates. With $v_r =r^{2}$ and all other components of the vector vanishing, we get
\begin{equation} \boldsymbol{\nabla} \cdot \boldsymbol{v} = 0, \tag{6.32} \end{equation}
with the important proviso that the result applies only when $r \neq 0$. We conclude that as claimed, $\mu = \nabla^2 r^{1} = \boldsymbol{\nabla} \cdot \boldsymbol{v}$ vanishes everywhere, except possibly at $r = 0$. Its value at $r=0$ cannot be obtained on the basis of this calculation, because the vector field $\boldsymbol{v}$ is too singular there.
Let us leave the issue aside for a moment, and as a fun diversion, let us calculate $\oint \boldsymbol{v} \cdot d\boldsymbol{a}$ over the surface of a sphere of radius $R$. The vector field evaluated on the sphere is $\boldsymbol{v} = R^{2}\, \boldsymbol{\hat{r}}$, the element of surface area is $d \boldsymbol{a} = (R\, d\theta) (R\sin\theta\, d\phi)\, \boldsymbol{\hat{r}} = R^2\sin\theta\, d\theta d\phi\, \boldsymbol{\hat{r}}$, and it follows that $\boldsymbol{v} \cdot d\boldsymbol{a} = \sin\theta\, d\theta d\phi$. Integration yields
\begin{equation} \oint \boldsymbol{v} \cdot d\boldsymbol{a} = 4\pi, \tag{6.33} \end{equation}
and we observe that the result is independent of $R$.
Exercise 6.6: Be sure you can reproduce the steps that lead to Eq.(6.33).
Why bring Eq.(6.33) up? The reason is that we can invoke the divergence theorem,
\begin{equation} \int \boldsymbol{\nabla} \cdot \boldsymbol{v}\, dV = \oint \boldsymbol{v} \cdot d\boldsymbol{a}, \tag{6.34} \end{equation}
to relate the surface integral of $\boldsymbol{v}$ to the volume integral of $\boldsymbol{\nabla} \cdot \boldsymbol{v} = \mu$, with the result
\begin{equation} \int \mu\, dV = 4\pi. \tag{6.35} \end{equation}
This is most strange, because $\mu$ is known to vanish everywhere within the domain of integration (a sphere of radius $R$), except possibly at the origin. And yet its volume integral is $4\pi$, which is definitely not zero. Clearly something must be happening at the origin to explain this curious result.
Our recent experience with the delta function allows us to resolve the matter. Like $\mu$, the threedimensional delta function $\delta(\boldsymbol{r})$ vanishes everywhere except at $\boldsymbol{r}=\boldsymbol{0}$, and its volume integral returns a nonzero value. In view of Eq.(6.12) with $f = 1$, it is clear that to explain Eq.(6.35), we must have that $\mu = 4\pi \delta(\boldsymbol{r})$. We may express this as
\begin{equation} \boldsymbol{\nabla} \cdot \boldsymbol{v} = 4\pi \delta(\boldsymbol{r}), \tag{6.36} \end{equation}
or as
\begin{equation} \nabla^2 r^{1} = 4\pi \delta(\boldsymbol{r}). \tag{6.37} \end{equation}
The Laplacian of $r^{1}$ vanishes everywhere except at the origin, where it is infinite; it is proportional to the threedimensional delta function.
A generalized version of Eq.(6.37) is
\begin{equation} \nabla^2 \frac{1}{\boldsymbol{r}\boldsymbol{r'}} = 4\pi \delta(\boldsymbol{r}\boldsymbol{r'}), \tag{6.38} \end{equation}
where $\boldsymbol{r}\boldsymbol{r'}$ is the distance between the points associated with $\boldsymbol{r}$ and $\boldsymbol{r'}$, respectively. The version of Eq.(6.37) refers to the origin and features its distance $r$ to a point at position $\boldsymbol{r}$. The generalized version refers to an arbitrary point at position $\boldsymbol{r'}$ and features its distance $\boldsymbol{r}\boldsymbol{r'}$ to the point at $\boldsymbol{r}$. Both equations have the same content. In fact, we can always choose the origin of the coordinate system to coincide with $\boldsymbol{r'}$, and the derivation of Eq.(6.38) is then no different from that of Eq.(6.37). The advantage of the generalized expression is that it allows us to place the origin elsewhere if we so choose. This power can be useful in applications, as we shall see in Sec.6.7 and again in Chapter 12.
6.7 Point Charge and Electrostatic Potential
We may now return to the discussion initiated at the beginning of the chapter. What is the density of a point charge? Our knowledge of the delta function allows us to state the answer: The charge density of a point charge $q_1$ at position $\boldsymbol{r}_1$ is given by
\begin{equation} \rho(\boldsymbol{r}) =q_1\, \delta(\boldsymbol{r}\boldsymbol{r}_1). \tag{6.39} \end{equation}
The relation states that the density is zero everywhere, except at $\boldsymbol{r}_1$ where it is infinite; this is precisely what we expect of the density of a point charge. The factor of $q_1$ in front of the delta function ensures that the total charge associated with $\rho$ is precisely equal to $q_1$. This can be seen by a simple calculation of the total charge,
\begin{equation} \int \rho(\boldsymbol{r})\, dV = \int q_1\, \delta(\boldsymbol{r}\boldsymbol{r}_1)\, dV = q_1, \tag{6.40} \end{equation}
where we used Eq.(6.19) in the last step.
The construction can be generalized to any number of charges. Suppose that we have a number $N$ of charges, with $q_1$ at position $\boldsymbol{r}_1$, $q_2$ at position $\boldsymbol{r}_2$, and so on. In this situation the charge density is
\begin{align} \rho(\boldsymbol{r}) &= q_1\, \delta(\boldsymbol{r}\boldsymbol{r}_1) + q_2\, \delta(\boldsymbol{r}\boldsymbol{r}_2) + \cdots + q_N\, \delta(\boldsymbol{r}\boldsymbol{r}_N) \nonumber \\ &= \sum_{j=1}^N q_j\, \delta(\boldsymbol{r}\boldsymbol{r}_j). \tag{6.41} \end{align}
It can be verified that in this case, the total charge is $q_1 + q_2 + \cdots + q_N = \sum_{j=1}^N q_j$, as expected.
Exercise 6.7: Calculate the total charge associated with the density of Eq.(6.41).
The electrostatic potential $V$ is related to the electric field $\boldsymbol{E}$ by $\boldsymbol{E} = \boldsymbol{\nabla} V$. Gauss's law of Eq.(6.1) can be reformulated as
\begin{equation} \nabla^2 V = \rho/\epsilon_0 \tag{6.42} \end{equation}
in terms of the potential, and we know that the solution to this equation is
\begin{equation} V(\boldsymbol{r}) = \frac{1}{4\pi\epsilon_0} \int \frac{\rho(\boldsymbol{r'})}{\boldsymbol{r}\boldsymbol{r'}}\, dV', \tag{6.43} \end{equation}
where $\boldsymbol{r'} = (x', y', z')$ is the position vector of an element of charge $dq' = \rho\, dV'$ inside the distribution, and $dV' := dx' dy' dz'$is the volume element.
Our recently acquired expertise with the delta function allows us to verify that Eq.(6.43) is indeed a solution to Eq.(6.42). Applying the Laplacian operator gives
\begin{align} \nabla^2 V &= \frac{1}{4\pi\epsilon_0} \nabla^2 \int \frac{\rho(\boldsymbol{r'})}{\boldsymbol{r}\boldsymbol{r'}}\, dV' \nonumber \\ &= \frac{1}{4\pi\epsilon_0} \int \nabla^2 \biggl( \frac{\rho(\boldsymbol{r'})}{\boldsymbol{r}\boldsymbol{r'}} \biggr) \, dV' \nonumber \\ &= \frac{1}{4\pi\epsilon_0} \int \rho(\boldsymbol{r'}) \biggl( \nabla^2 \frac{1}{\boldsymbol{r}\boldsymbol{r'}} \biggr)\, dV'. \tag{6.44} \end{align}
In the second step we moved the Laplacian operator within the integral, since the order of these operations can always be switched. In the third step we indicated that since $\nabla^2$ refers to the variables $(x, y, z)$ contained in $\boldsymbol{r}$, it leaves $\rho(\boldsymbol{r'})$ alone and acts only on $\boldsymbol{r}\boldsymbol{r'}^{1}$. At this stage we recall Eq.(6.38), write
\begin{equation} \nabla^2 V = \frac{1}{4\pi\epsilon_0} \int \rho(\boldsymbol{r'}) \biggl( 4\pi \delta(\boldsymbol{r}\boldsymbol{r'}) \biggr)\, dV', \tag{6.45} \end{equation}
and perform the integral to obtain Eq.(6.42), as required.
Exercise 6.8: A subtlety of the preceding derivation is that the integration carried out in the last step is performed with respect to the primed coordinates $(x', y', z')$, while Eq.(6.19) involves an integration over the unprimed coordinates $(x, y, z)$. Resolve this matter. You may take a hint from Eq.(6.14).
The potential of a point charge $q_1$ can be obtained by inserting the charge density of Eq.(6.40) into the general solution of Eq.(6.43). For this we must reexpress the density as a function of $\boldsymbol{r'}$, $\rho(\boldsymbol{r'}) = q_1\, \delta(\boldsymbol{r'}  \boldsymbol{r}_1)$, before we make the substitution. We get
\begin{equation} V(\boldsymbol{r}) = \frac{1}{4\pi \epsilon_0} \int \frac{q_1\, \delta(\boldsymbol{r'}\boldsymbol{r}_1)}{\boldsymbol{r}\boldsymbol{r'}}\, dV' \tag{6.46} \end{equation}
and integration yields
\begin{equation} V(\boldsymbol{r}) = \frac{1}{4\pi \epsilon_0} \frac{q_1}{\boldsymbol{r}\boldsymbol{r}_1}, \tag{6.47} \end{equation}
the wellknown expression for the potential of a point charge. This reduces to the familiar $V = q_1/(4\pi\epsilon_0 r)$ when the charge is placed at the origin of the coordinate system.
Equation (6.47) can be generalized to any number of charges by repeating the calculation with the density of Eq.(6.41). In this case we get
\begin{equation} V(\boldsymbol{r}) = \frac{1}{4\pi \epsilon_0} \sum_{j=1}^N \frac{q_j}{\boldsymbol{r}\boldsymbol{r}_j}, \tag{6.48} \end{equation}
also a wellknown result.
Exercise 6.9: Verify that the solution to Eq.(6.42) for a system of $N$ point charges is given by Eq.(6.48).
6.7 Practice Problems

(Boas Chapter 8, Section 11, Problem 13b) Using the delta function, write the charge density for a system involving 3 units of charge at $x = 5$ and $4$ units of charge at $x = 10$.

(Boas Chapter 8, Section 11, Problem 13a) Using the delta function, write the mass density for a system involving 5 units of mass at $x = 2$ and 3 units of mass at $x = 7$.

(Boas Chapter 8, Section 11, Problem 15a) Evaluate the integral $\int_0^\pi \sin(x) \delta(x\pi/2)\, dx$.

(Boas Chapter 8, Section 11, Problem 15b) Evaluate the integral $\int_0^\pi \sin(x) \delta(x+\pi/2)\, dx$.

(Boas Chapter 8, Section 11, Problem 15c) Evaluate the integral $\int_{1}^1 e^{3x} \delta'(x)\, dx$.

(Boas Chapter 8, Section 11, Problem 15d) Evaluate the integral $\int_0^\pi \cosh(x) \delta''(x1)\, dx$.

(Boas Chapter 8, Section 11, Problem 16) The sign function $\text{sgn}(x)$ is defined to be $+1$ when $x>0$ and $1$ when $x<0$. Relate the sign function to the step function, and relate $\text{sgn}'(x)$ to the delta function.

(Boas Chapter 8, Section 11, Problem 21a) Evaluate the integral $\int_0^3 (5x2) \delta(2x)\, dx$.

(Boas Chapter 8, Section 11, Problem 21c) Evaluate the integral $\int_{1}^1 \cos x \, \delta(2x)\, dx$.

(Boas Chapter 8, Section 11, Problem 21d) Evaluate the integral $\int_{\pi/2}^{\pi/2} \cos x\, \delta(\sin x)\, dx$. Hint: perform a change of variables to simplify the appearance of the delta function.
6.8 Challenge Problems

Prove the following identities involving the Dirac delta function:
a) $\delta(c x) = \delta(x)/c$,
b) $x \delta(x) = 0$,
c) $x \delta'(x) = \delta(x)$,
d) $x^2 \delta''(x) = 2\delta(x)$.
Hint: To prove an identity $\psi_1 = \psi_2$, where $\psi_1$ and $\psi_2$ are quantities related to the delta function, you must prove that $\int_{\infty}^\infty \psi_1 f(x)\, dx = \int_{\infty}^\infty \psi_2 f(x)\, dx$ for {\it any} smooth function $f(x)$.

Consider the sequence of Gaussian functions
\[\delta_n(x) = \frac{n}{\sqrt{\pi}} e^{n^2 x^2}, \qquad n = 1, 2, 3, \cdots, \infty. \]
a) In a single graph, plot $\delta_n(x)$ for $n = \{ 1, 3, 8 \}$. Choose an interval $x_0 < x < x_0$ so that each function is clearly displayed.
b) Calculate $\int_{\infty}^\infty \delta_n(x) f(x)\, dx$ for any function $f(x)$. Hint: Expand $f(x)$ in an infinite Taylor series about $x=0$. Your result should take the form of an infinite sum.
c) Show that in the limit $n \to \infty$, the result of the integral is $f(0)$.
The last result reveals that in the limit $n \to \infty$, $\delta_n(x)$ behaves as a delta function.