1

In electrostatics, one often desires to know the electrostatic potential generated from the outside of a charge distribution; however, I am interested in finding the electrostatic potential inside of a charge distribution.

For example, let's consider a parabolic charge distribution: $\rho(x) = x(L-x)$ Where L is the length of the distribution. Now if we wish to calculate the electrostatic potential, we would need to calculate:

$\Phi(z) = \int_0^L \frac{\rho(x)}{|z-x|} dx = \int_0^L \frac{x(L-x)}{|z-x|} dx$

In turn one could take the derivative of $\Phi(z)$ to obtain the electric field inside the distribution.

My attempt to do this in mathematica:

L = 1;
s[z_] := z (L-z)
fen[x_] := Integrate[s[z]/Abs[z - x], {z, 0, L}, PrincipalValue -> True, Assumptions :> {L > x > 0}]
V = fen[x]
El = fen'[x]
Plot[{V, El}, {x, 0, 1}]

Any ideas? Thanks!

1 Answers1

3

Surely you can do it for any charge distribution as it is just evaluating integrals!

However, I have to point out a severe problem in what you are going to calculate. What I am going to say may not be an answer to your question. (I would like to make this a comment but I dont have enough reputation to do so.)

Your charge distribution is 1-dimensional, $$ \rho(x) = x(L-x). $$

The problem is, you are using a 3-D green function $\frac{1}{|\vec{x}-\vec{x}'|}$ of the 3-D Laplacian $\nabla^2$ to calculate a 1-D problem. The correct result is not showing up for sure.

Instead you should use the 1-D green function $ \frac{1}{2}|x-x'|$ for the potential, i.e.

$$ \Phi(x) = \int_0^L\frac{1}{2}|x-x'|\rho(x') dx' $$

mastrok
  • 591
  • 2
  • 9
  • 1
    First, thank you for understanding that I did not understand @LeonidShifrin comment/answer in my original question's comment. Second, it is to my surprise that I have not covered this (or perhaps forgotten) that these Green's function's are dimension-dependent.
    Lastly for discussion, I am somewhat disturbed by the implication that it is only in 3D, that the force between two charged particles scales as 1/r^2. Many thanks, my simulations make much more sense now :)!
    – StarStrides Jan 18 '14 at 17:19