I am trying to evaluate the integral $$\int \frac{\vec{r}-\vec{r}^{\prime}}{\left|\vec{r}-\vec{r}'\right|^{3}} d \tau^{\prime}$$

over the spherical volume $r'<R$ with $\vec{r}$ inside the integration volume and with $\vec{r}$ outside the integration volume. How can this be done? dτ Is a volume element. I know this is essentially the integral that Coulomb's law uses (though I am not considering charge here), but I am not sure how to explicitly evaluate it in these cases.

  • $\begingroup$ Use spherical polar coordinates with the $z’$ axis running through the point $\vec r$. $\endgroup$ – G. Smith Jan 20 at 22:30
  • 2
    $\begingroup$ I think you should replace $\tau'$ with $r'$. $\endgroup$ – Virgo Jan 21 at 0:20
  • $\begingroup$ @Virgo It's pretty common to write $\mathrm d\tau$ as a shorthand for the volume element $\mathrm d^3 r = \mathrm dx\,\mathrm dy\,\mathrm dz = r^2 \mathrm dr\,\mathrm d\phi\,\mathrm d(\cos\theta)$. It's also common to leave this shorthand unexplained, or explained exactly once in an out-of-the-way place, so that the beginning reader wastes an entire day trying to figure it out. $\endgroup$ – rob Jan 28 at 17:18

As I don't want to provide a complete answer to your question I will produce steps to compute the $\vec E$ field for a spherical shell of negligible thickness, centered on the origin, having radius $r_s$ and carrying a constant surface charge density $\sigma_0$. You can adapt to the volume case and to your specific intergral.

We calculate the electric field $\vec E$ at a point $\vec r_p=(0,0,z_p)$.

Note that, by symmetry, if we have the magnitude of $\vec E$ at $(0,0,z_p)$, we also have the magnitude of $\vec E$ at any point on a sphere or radius $r_p=z_p$. If we pick another point $\vec r^\prime_p=(x_p,0,0)$ with $\vert x_p\vert=\vert z_p\vert$,i.e. if the point $\vec r^\prime_p=(x_p,0,0)$ is at the same distance from the origin as the point $\vec r_p=(0,0,z_p)$, then $\vert\vec E(x_p,0,0)\vert=\vert\vec E(0,0,z_p)\vert$. The direction of $\vec E$ will be different at the two points, but the magnitude of $\vec E$ will be the same.

In other words, because the problem is spherically symmetric, there is nothing special about $z_p$: it might as well be any point on the sphere containing $z_p$. The choice of $z_p$ is convenient for calculations, nothing more.

Imagine dividing the shell small areas. Because the charge distribution is spherically symmetric, it is convenient to use spherical coordinates where \begin{align} z_s=r_s\cos\theta_s\, ,\qquad x_s=r_s\sin\theta_s\cos\phi_s\, ,\qquad y_s=r_s\sin\theta_s\sin\phi_s\, . \end{align} Note that $r_s$ is constant: it is the radius of the shell. If $r_p>r_s$, the point is outside the shell; if $r_p<r_s$ it is inside. The area of a small piece of the shell is $$ dA_s=r_s^2\sin\theta_s\,d\theta_s\,d\phi_s\, . $$

Our small patch of shell contains a small amount of charge $$ dq_s=\sigma_0\,dA_s=\sigma_0r_s^2\sin\theta_s\,d\theta_s\,d\phi_s\, , $$ and will produce at $\vec r_p=z_p\hat z$ a small field $$ d\vec E=\frac{r_s^2\sigma_0}{4\pi\epsilon_0}\,\int_{\pi}^{0}d\theta_s\sin\theta_s\,\int_{0}^{2\pi}d\phi_s\, \frac{(z_p-r_s\cos\theta_s)\hat z-r_s\sin\theta_s\cos\phi_s\hat x-r_s\sin\theta_s\sin\phi_s\hat y}{(r_s^2\sin^2\theta_s+(z_p-r_s\cos\theta_s)^2)^{3/2}}\, . $$

Simple integration over $\phi_s$ shows that $E_x=E_y=0$. Thus, the field is in the direction of $\vec r_p$. The remaining component is obtained from $$ E_z(0,0,z_p)=\frac{r_s^2\sigma_0}{4\pi\epsilon_0}\,2\pi\,\int_{\pi}^0d\theta_s\sin\theta_s\frac{(z_p-r_s\cos\theta_s)} {(r_s^2\sin^2\theta_s+(z_p-r_s\cos\theta_s)^2)^{3/2}}\, . \tag{1} $$

This last integral is moderately difficult. To unravel it, we first set $$ \xi=-r_s\cos\theta_s\,\Rightarrow\,d\xi=r_s\sin\theta_s\,d\theta_s\, ,\qquad r_s^2\sin^2\theta_s=r_s^2-\xi^2\, . $$ Inserting this in Eq.)1), we have $$ E_z(0,0,z_p)=\frac{r_s\,\sigma_0}{2\varepsilon_0}\,\int_{-r_s}^{r_s}\,d\xi\,\frac{(z_p+\xi)}{(r_s^2+2\xi\,z_p+ z_p^2)^{3/2}}\, , $$

A little cleaning up of the denominator yields \begin{align} E_z(0,0,z_p)&= \frac{r_s\,\sigma_0}{2\varepsilon_0}\,\int_{-r_s}^{r_s}\,d\xi\,\frac{z_p}{(r_s^2+2\xi\,z_p+ z_p^2)^{3/2}}+\frac{r_s\,\sigma_0}{2\varepsilon_0}\,\int_{-r_s}^{r_s}\,d\xi\,\frac{\xi}{(r_s^2+2\xi\,z_p+ z_p^2)^{3/2}}\, ,\\ &=\frac{r_s\,\sigma_0}{2\varepsilon_0}\frac{1}{\sqrt{r_s^2+z_p^2+2z_p\,r_s}}\Bigl\vert_{-r_s}^{r_s} +\frac{r_s\,\sigma_0}{2\varepsilon_0}\,\int_{-r_s}^{r_s}\,d\xi\, \frac{\xi}{(r_s^2+2\xi\,z_p+z_p^2)^{3/2}}\, ,\\ \end{align}

The rightmost integral is easily simplified using integration by parts: $$ u=\xi\, ,\qquad du=d\xi\, ,\qquad dv=\frac{d\xi}{(r_s^2+2\xi\,z_p+z_p^2)^{3/2}}\, ,\qquad v=-\frac{1}{z_p}\frac{1}{\sqrt{r_s^2+z_p^2+2z_p\xi}}\, , $$ so that \begin{align} \displaystyle\int\,d\xi\frac{\xi}{(r_s^2+2\xi\,z_p+z_p^2)^{3/2}}&=-\frac{\xi}{z_p}\frac{1}{\sqrt{r_s^2+z_p^2+2z_p\xi}} +\frac{1}{z_p}\displaystyle\int\,d\xi\,\frac{1}{\sqrt{r_s^2+z_p^2+2z_p\xi}}\, ,\\ &= -\frac{\xi}{z_p}\frac{1}{\sqrt{r_s^2+z_p^2+2z_p\xi}} +\frac{1}{z_p^2}\sqrt{r_s^2+z_p^2+2z_p\,r_s}\, ,\\ &=\frac{r_s^2+z_p^2+z_p\,r_s}{z_p^2\sqrt{r_s^2+z_p^2+2z_p\,r_s}}\, , \end{align} Inserting the limits and straightforward manipulations eventually yield \begin{align} \int_{-r_s}^{r_s}\,d\xi\frac{(z_p+\xi)}{(r_s^2+2\xi\,z_p+z_p^2)^{3/2}}&=\left[ -\frac{1}{\sqrt{r_s^2+z_p^2+2z_p\,\xi}}+\frac{(r_s^2+z_p^2+z_p\xi)}{z_p^2\sqrt{r_s^2+2\xi\,z_p+z_p^2}}\right]_{-r_s}^{r_s}\, , \\ &=\frac{r_s}{z_p^2}\left[1+\frac{(z_p-r_s)}{\sqrt{(r_s-z_p)^2}}\right]\, . \end{align}

This last result must be simplified very carefully because we are taking the square root of a square. Thus:

$$\frac{(z_p-r_s)}{\sqrt{(r_s-z_p)^2}}=\left\{\begin{array}{cc} -1 & \hbox{ if $z_p<r_s\, ,$}\\ +1 & \hbox{ if $z_p>r_s$}\, ,\end{array}\right. $$ so that $$ \int_{-r_s}^{r_s}\,d\xi\frac{(z_p+\xi)}{(r_s^2+2\xi\,z_p+z_p^2)^{3/2}}= \left\{\begin{array}{cc} 0 & \hbox{ if $z_p<r_s\, ,$}\\ \frac{2\,r_s}{z_p^2} & \hbox{if $z_p>r_s$}\, .\end{array}\right. $$ The $E_z$ then becomes $$ E_z(0,0,z_p)=\left\{\begin{array}{cc} 0& \hbox{ if $z_p<r_s\, ,$}\\ \frac{4\pi\,r_s^2\,\sigma_0}{4\pi\varepsilon_0\,z_p^2}\,\ & \hbox{ if $z_p>r_s$}\, .\end{array}\right. $$ Note that $4\pi\,r_s^2\,\sigma_0$ is the total area of the sphere multiplied by the surface charge density. Thus, we can write $q_{0}=4\pi\,r_s^2\,\sigma_0$ as the net charge on the sphere and simplify our final answer to $$ E_z(0,0,z_p)=\left\{\begin{array}{cc} 0& \hbox{ if $z_p<r_s\, ,$}\\ \frac{q_{0}}{4\pi\varepsilon_0\,z_p^2}\,\ & \hbox{ if $z_p>r_s$}\, .\end{array}\right. $$

In summary, the field is $0$ if $\vec r_p$ is inside the shell. If $\vec r_p$ is outside the shell, then the field at $\vec r_p$ is just the field of a charge $q_{0}$ located at the origin. By symmetry, this conclusion holds for any point. Thus, we can write $$ \vec E(\vec r_p)=\left\{\begin{array}{cc} 0& \hbox{ if $r_p<r_s\, ,$}\\ \frac{q_{0}}{4\pi\varepsilon_0\,r_p^2}\,\hat r_p\,\ & \hbox{ if $r_p>r_s$}\, ,\end{array}\right. $$ where $\hat r_p$ is a unit vector along the line connecting the origin to $\vec r_p$.

The volume case is done along the same lines, but I leave that adaptation to you.

| cite | improve this answer | |

To solve this integral, you can make use of a handy theorem: $\nabla \cdot \left( \frac{{\bf r}}{|{\bf r}|^3} \right) = 4 \pi \delta({\bf r})$. This is proved, for example, in Griffiths.

You can integrate this function over a closed surface, and then use the divergence theorem on the result to obtain the integral that you want.

| cite | improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.