# General derivation of the potential energy of a dipole in an external electric field

In a external electric field, the torque that a dipole feels is $\vec{\tau} = \vec{\mu} \times \vec{E}$, and the corresponding potential energy is given by $U = - \vec{\mu} \cdot \vec{E}$.

If the electric field is uniform, since $U = \frac{1}{2} (q_1 V(r_1) + q_2 V(r_2) )$, by just finding the difference of the potentials between the positions of the charges, we can derive the above $U$ expression, but if electric field is not uniform, how can we do that ? what is the general method for deriving this $U$ expression from the torque expression ?

• I think if the electric field is not uniform, there is a force acting on the dipole which is $\mathbf F=\nabla(\mathbf \mu\cdot \mathbf E)$. Consequently, since $\mathbf F= -\nabla U$, the energy must be $U=-\mathbf \mu\cdot \mathbf E$. However, I am not sure if the expression of the force is not derived from the knowledge of the energy. – Ronan Tarik Drevon Mar 26 '17 at 16:59

Since the two charges in the dipole are opposite, the total potential is just (the magnitude of the charge times) the difference in the potential at two nearby points. But this potential difference can be well approximated by the gradient of the potential dotted into the displacement between the points. Therefore we get $\newcommand{\Vd}{U_\mathrm{dip}}\Vd\approx \newcommand{\p}{\mathbf{p}}\p \cdot \nabla V$.

A bit more rigorously, let's put the origin of our coordinate system at the negative charge, and call the position of the positive charge $\newcommand{\d}{\mathbf{d}}\d$. Let's call the magnitude of the charge $q$. Then we have that the dipole moment is $\p=q\d$. Meanwhile, the potential of the dipole is given by $$\Vd=qV(\d)-qV(\mathbf{0})=q\left(V(\d)- V(\mathbf{0})\right).$$ Now for small $\d$, we can use the Taylor expansion, $$V(\d)- V(\mathbf{0})=\d \cdot \nabla V|_\mathbf{0}+O(|\d|^2).$$

Thus a good approximation in the limit of small $\d$ is $$\Vd \approx q\d \cdot \nabla V|_\mathbf{0} = \p \cdot \nabla V|_\mathbf{0}.$$

In the limit of an ideal dipole, where $|\d| \to 0$ with $\p$ fixed (so that $q \to \infty$), the $O(|\d|^2)$ error term goes to zero, so the above expression for the potential is exact.

Another way of looking at the problem is to notice that the potential of any charge configuration (characterized by charge density $\rho$) in an external potential $V$ is given by $U=\int \rho V dV$. By Taylor expanding $V$ about the origin, we get $$U= \int \rho \left(V(\mathbf{0}) + r_i \partial_i V\newcommand{\z}{\mathbf{0}}|_\z + r_i r_j \partial_i \partial_j V|_\z + \left[\textrm{higher derivative terms}\right] \right) dV$$

this since the derivatives are constants with respect to the integration variable, they can be taken out of the integration to get

$$U= V(\mathbf{0}) \int \rho dV + \partial_i V|_\z \int \rho r_i dV + \partial_i \partial_j V|_\z \int \rho r_i r_j dV + \cdots$$

Now we can define the total charge of the charge distribution to be $q$, we define the dipole moment $\p$ by $\p=\int \rho \mathbf{r}dV$, and higher multipole moments $Q^{(m)}_{ij\cdots}$ of order $m$ by integration $\rho$ against $m$ copies of $\mathbf{r}$ (times dimensionless factors). Then we get the potential energy $U$ is given by $$U=q V(\z) + \p \cdot \nabla V |_\z + \frac{1}{6}Q_{ij} \partial_i \partial_j V|_\z + \left[ \textrm{higher multipole terms Q^{(m)}_{ij\cdots} \partial_i \partial_j \cdots V|_\z}\right]$$

Now a pure (another way of saying ideal) dipole has dipole moment $\p$ and all other multipole moments zero, so its potential energy is simply $\p \cdot \nabla V$. But even for an arbitrary charge distribution $\rho$, we can still say the dipole contribution to the potential energy is $\p \cdot \nabla V$.