The page you are reading is part of a draft (v2.0) of the "No bullshit guide to math and physics."

The text has since gone through many edits and is now available in print and electronic format. The current edition of the book is v4.0, which is a substantial improvement in terms of content and language (I hired a professional editor) from the draft version.

I'm leaving the old wiki content up for the time being, but I highly engourage you to check out the finished book. You can check out an extended preview here (PDF, 106 pages, 5MB).


Electrostatic integrals

The electric field produced by a point charge $Q$ placed at the origin is given by $\vec{E}(\vec{r})=\frac{k_eQ}{r^2}\hat{r}$. What if the charge is not a point but some continuous object? It could be a line-charge, or some charged surface. How would you calculate the electric field produced by such an object $O$?

What you will do is cut up the object into little pieces $dO$ and calculate the electric field produced by each piece and then add up all the contribution. In other words you need to do an integral.

Concepts

  • $Q$: the total charge. The units are Coulombs [C].
  • $\lambda$: linear charge density. The units are coulombs per meter [C/m].

The charge density of a long wire of length $L$ is $\lambda = \frac{Q}{L}$.

  • $\sigma$: the surface charge density. Units are [C/m$^2$].

The charge density of a disk with radius $R$ is $\sigma = \frac{Q}{\pi R^2}$.

  The charge on a sphere of radius $R$ made of conducting material will be concentrated
  on its surface and will have density $\rho =\frac{Q}{4 \pi R^2}$.
* $\rho$: the volume charge density. Units are [C/m$^3$].
  The charge density of a cube of uniform charge and side length $c$ is $\rho = \frac{Q}{c^3}$.
  The charge density of a solid sphere made of insulator with a uniform
  charge distribution will be $\rho = \frac{Q}{\frac{4}{3} \pi R^3}$.

One-over-r-squared quantities:

  • $\vec{F}_e$: Electric force.
  • $\vec{E}$: Electric field.

One-over-r quantities:

  • $U$: electric potential energy.
  • $V$: electric potential.

Integration techniques review

Both the formulas for electric force (field) and potential energy (electric potential) contain a denominator of the form $r\equiv |\vec{r}| = \sqrt{x^2 + y^2}$. As you can imagine, these kind of integrals will be quite hairy to calculate if you don't know what you are doing.

But you know what you are doing! Well, you know if you remember your techniques_of_integration. Now I realize we saw this quite a long time ago so a little refresher is in order.

The reason why they make you practice all those trigonometric substitutions is that they will be useful right now. For example, how would you evaluate the integral \[ \int_{-\infty}^{\infty} \frac{1}{(1+x^2)^{\frac{3}{2}} } \ dx, \] if you were forced to – like on an exam question or something. Relax. You are not in an exam. I just said that to get your attention. The above integral may look complicated, but actually you will see that it is not too hard: we just have to use a trig substitution trick. You will see that all that time spent learning about integration techniques was not wasted.

Recall that the trigonometric substitution trick necessary to handle the terms like $\sqrt{1 + x^2}$is to use the identity: \[ 1 + \tan^2 \theta = \sec^2 \theta, \] which comes from $\cos^2 \theta + \sin^2 \theta = 1$ divided by $\cos^2 \theta$.

If we make the substitution $x=\tan\theta$, $dx=\sec^2\theta \ d\theta$ in the above integral we will get \[ 1 + x^2 = \sec^2 \theta. \] But we don't just have $1+x^2$, but $(1+x^2)^{\frac{3}{2}}$. So we need to take the $\frac{3}{2}$th power of the above equation, which is equivalent to taking the square root and then raising to the third power: \[ (1+x^2)^{\frac{3}{2}} = (\sec^2\theta)^{\frac{3}{2}} = \left( \sqrt{ \sec^2\theta} \right)^{3} = (\sec\theta)^{3} = \sec^3\theta. \] Next, we have to calculate the new limits of integration due to the change of variable $x=\tan\theta$. The upper limit $x_f=+\infty$ becomes $\theta_f = \tan^{-1}(+\infty)=\frac{\pi}{2}$ and the lower limit $x_i=-\infty$ becomes $\theta_i = \tan^{-1}(-\infty)=-\frac{\pi}{2}$.

Ok now let's see how all of this comes together: \[ \begin{align} \int_{x=-\infty}^{x=\infty} \frac{1}{(1+x^2)^{\frac{3}{2}} } \ dx &= \int_{ \theta=-\frac{\pi}{2} }^{ \theta=\frac{\pi}{2} } \frac{1}{(1+\tan^2\theta)^{\frac{3}{2}} } \sec^2 \theta \ d\theta \nl &= \int_{ -\frac{\pi}{2} }^{ \frac{\pi}{2} } \frac{1}{\sec^3\theta} \sec^2 \theta \ d\theta \nl &= \int_{ -\frac{\pi}{2} }^{ \frac{\pi}{2} } \cos \theta \ d\theta \nl &= \sin \theta \bigg|_{ -\frac{\pi}{2} }^{ \frac{\pi}{2} } = \sin\left( \frac{\pi}{2} \right) - \sin\left( - \frac{\pi}{2} \right) = 1 - (-1) = 2. \end{align} \]

Exercise

Now I need you to put the book down for a moment and try to reproduce the above steps by practicing on the similar problem: \[ \int_{-\infty}^{\infty} \frac{a}{(a^2+x^2)^{\frac{3}{2}} } \ dx, \] where $a$ is some fixed constant. Hint: substitute $x = a \tan\theta$. This integral corresponds to the strength of the electric field at a distance $a$ from an infinitely long line charge. Ans: $\frac{2}{a}$. We will use this result in Example 1 below, so go take a piece of paper and do it.

The tan substation is also useful when calculating the electric potential, but the denominator will be of the form $\frac{1}{(1+x^2)^{\frac{1}{2}} }$ instead of $\frac{1}{(1+x^2)^{\frac{3}{2}} }$. We show how to compute this integral in Example 3.

Formulas

Let $\vec{E} = ( E_x, E_y )=( \vec{E}\cdot \hat{x}, \vec{E}\cdot \hat{y} )$ be the electric field strength at some point $P$ due to the charge on some object $O$. We can calculate the total electric field by analyzing the individual contribution $dE$ due to each tiny part of the object $dO$.

The total field strength in the $\hat{x}$ direction is given by \[ E_x = \int dE_x = \int_O \vec{E}\cdot \hat{x}\ dO. \]

The above formula is too abstract to be useful. Think of it more as a general statement of the principle that the electric field due to the object as a whole, is equal to sum of the electric field due to its parts.

Charge density

The linear charge density of an object of length $L$ with charge $Q$ on it is \[ \lambda = \frac{Q}{L}, \qquad \textrm{ [C/m] } \] where $\lambda$ is the Greek letter lambda which is also used to denote wavelength.

Similarly the surface charge density is defined as the total charge divided by the total area and the volume charge density as the total charge divided by the total volume: \[ \sigma = \frac{Q}{A} \ \ \ \left[ \frac{\textrm{C}} { \textrm{m}^2} \right], \qquad \rho = \frac{Q}{V} \ \ \ \left[ \frac{ \textrm{C} }{ \textrm{m}^3} \right], \] where $\sigma$ and $\rho$ are the Greek letters sigma and rho.

Examples

Example 1: Electric field of an infinite line charge

Consider a horizontal line charge of charge density $\lambda$ [C/m]. What is the strength of the electric field strength at a distance $a$ from the wire?

The wire has a line symmetry so we can choose any point along the wire, so long as it is $a$[m] away from it. Suppose we pick the point $P=(0,a)$ which lies on the $y$ axis. We want to calculate $\vec{E}({P}) = ( E_x, E_y )=( \vec{E}\cdot \hat{x}, \vec{E}\cdot \hat{y} )$.

Consider first the term $E_y$. It is given by the following integral: \[ \begin{align} E_y & = \int dE_y = \int d\vec{E} \cdot \hat{y} \nl & = \int_{x=-\infty}^{x=\infty} \vec{E}(dx) \cdot \hat{y} \nl & = \int_{x=-\infty}^{x=\infty} \frac{ k_e (\lambda dx)} { r^2} \hat{r} \cdot \hat{y} \nl & = \int_{x=-\infty}^{x=\infty} \frac{ k_e \lambda dx} { r^2} \hat{r} \cdot \hat{y} \nl & = \int_{-\infty}^{\infty} \frac{k_e \lambda}{(a^2+x^2)} ( \hat{r} \cdot \hat{y} ) \ dx \nl & = \int_{-\infty}^{\infty} \frac{k_e \lambda}{(a^2+x^2)} \left( \frac{ a }{ \sqrt{ a^2+x^2} } \right) \ dx \nl & = \int_{-\infty}^{\infty} \frac{k_e \lambda a}{(a^2+x^2)^{\frac{3}{2}} } \ dx. \end{align} \]

We showed how to compute this integral in the review section on integration techniques. If you did as I asked you, you will know that \[ \int_{-\infty}^{\infty} \frac{a}{(a^2+x^2)^{\frac{3}{2}} } \ dx \ = \ \frac{2}{a}. \]

The total electric field in the $y$ direction is therefore given by: \[ E_y = k_e \lambda \int_{-\infty}^{\infty} \frac{ a}{(a^2+x^2)^{\frac{3}{2}} } \ dx \ = \ \frac{ 2 k_e \lambda }{ a }. \]

By symmetry $E_x=0$, since there is an equal amount of charge to the left and to the right of the origin. Therefore, the electric field $\vec{E}({P})$ at the point $P$ at a distance $a$ from the line charge is given by $\vec{E}({P})=(E_x, E_y) = \left( 0, \frac{ 2 k_e \lambda }{ a } \right)$.

Example 2: Charged disk

What is the electric field in the $z$ direction directly above the a disk with charge density $\sigma$[C/m$^2$] and radius $R$ that is lying in the centre of the $xy$-plane?











Example 3: Electric potential of a line charge of finite length

Consider a line charge of length $2L$ and linear charge density $\lambda$. The integral in that case will be \[ \begin{align} \int_{-L}^{L} \frac{1}{ \sqrt{ 1+x^2} } \ dx &= \int \frac{1}{ \sqrt{ 1+\tan^2\theta} } \sec^2 \theta \ d\theta \nl &= \int \frac{1}{\sec\theta} \sec^2 \theta \ d\theta \nl &= \int \sec \theta \ d\theta. \end{align} \] To proceed we need to remember a sneaky trick, which is to use the substitution $u = \tan\theta +\sec\theta$, $du=\sec^\theta + \tan\theta\sec\theta$ and to multiply top and bottom by $\tan\theta +\sec\theta$. \[ \begin{eqnarray} \int \sec(\theta) \, dx &=& \int \sec(\theta)\ 1 \, d\theta \nl &=& \int \sec(\theta)\frac{\tan(\theta) +\sec(\theta)}{\tan(\theta) +\sec(\theta)} \ d\theta \nl &=& \int \frac{\sec^2(\theta) + \sec(\theta) \tan(\theta)}{\tan(\theta) +\sec(\theta)} \ d\theta\nl &=& \int \frac{1}{u} du \nl &=& \ln |u| \nl &=& \ln |\tan(\theta) + \sec(\theta) | \nl &=& \ln \left| x + {\sqrt{ 1 + x^2} } \right| \bigg|_{-L}^L \nl &=& \ln \left| L + {\sqrt{ 1 + L^2}} \right| - \ln \left| -L + {\sqrt{ 1 + L^2} } \right| \nl &=& \ln \left| \frac{ L + {\sqrt{ 1 + L^2} } } { -L + {\sqrt{ 1 + L^2} } } \right|. \end{eqnarray} \]

Exercise: The above calculation is showing the important calculus core of the problem. The necessary physical constants like $\lambda$ (charge density) and $a$ (distance from wire) are missing. Add them to obtain the final answer. You can check your answer in the link below.




Discussion

If you find the steps in this chapter complicated, then you are not alone. I had to think quite hard to get all the things right so don't worry: you won't be expected to do this on an exam on your own. In a homework problem maybe.

The important things to remember is to split the object $O$ into pieces $dO$ and then keep in mind the vector nature of $\vec{E}$ and $\vec{F}_e$ (two integrals: one for the $x$ component of the quantity and one for the $y$ component).

An interesting curiosity is that the electric potential at a distance $a$ from an infinitely long wire is infinite. The potential scales as $\frac{1}{r}$ and so integrating all the way to infinity makes it blow up. This is why we had to choose a finite length $2L$ in Example 3.

Links

 
home about buy book