Charge density → Electric field → Electrostatic potential

Sometimes the charge distribution, electric field, the electrostatic potential only change in one direction. Diodes and capacitors often have this character. There are two contact planes and the electric field points perpendicular to the planes so the charge density and electrostatic potential stay constant as you move parallel to the planes. This page takes an expression for a charge density that only varies in the $x-$direction and integrates it to determine the corresponding electric field and electrostatic potential. The general expressions for the relationships between the charge density $\rho$, the electric field $\vec{E}$, and to the electrostatic potential $\varphi$ are:

\[ \begin{equation} \vec{E}(\vec{r})=-\nabla \varphi(\vec{r}),\qquad \text{and}\qquad \nabla\cdot\vec{E}(\vec{r})=\frac{\rho(\vec{r})}{\epsilon_r\epsilon_0}. \end{equation} \]

Here $\epsilon_r$ is the relative dielectric constant and $\epsilon_0$ is the permittivity constant. If the charge density, the electric field, and the electrostatic potential are constant in the $y-$ and $z-$directions and only vary in the $x-$direction, then these equations can be written as,

$\rho(x),$

$E(x)=\int\limits_{x_1}^{x}\frac{\rho(x')}{\epsilon_r\epsilon_0}dx'+E(x_1), $

$\varphi(x) = -\int\limits_{x_1}^{x} E(x')dx'+\phi(x_1), $

$F(x) = qE(x)= q\int\limits_{x_1}^{x}\frac{\rho(x')}{\epsilon_r\epsilon_0}dx'+qE(x_1).$

Where the last equation is the force on a particle with charge $q$. Calculations of this sort can be performed with the Numerical integration and differentiation app. The integration part of this app has been copied below to calculate the electric field and the electrostatic potential from the charge density.

$\large \frac{\rho(x)}{\epsilon_r\epsilon_0}=$  [V/m²]
in the range from $x_1=$  [m] to $x_2=$  [m].

 $x$ [m]    $\large \frac{\rho(x)}{\epsilon_r\epsilon_0}$ [V/m²]

  

$\large \frac{\rho(x)}{\epsilon_r\epsilon_0}$ [V/m²]

$x$ [m]

The electric field is the integral of the charge density,

$\large E(x)=\frac{1}{\epsilon_r\epsilon_0}\int\limits_{x_1}^{x}\rho(x')dx'+E(x_1)$.

$E(x_1)=$

The integral is calculated numerically using a method called Simpson's rule.

 $x$ [m]   $E(x)$ [V/m]

  

$E(x)$ [V/m]

$x$ [m]

The electrostatic potential is minus the integral of the electric field,

$\large \varphi(x) = -\int \limits_{x_1}^{x} E(x')dx' + \varphi(x_1).$

$\varphi(x_1)=$

 $x$ [m]    $\varphi(x)$ [V]

  

$\varphi$ [V]

$x$ [m]