# Does this example contradict Earnshaw's theorem in one dimension?

This is basically a continuation of the post here.

Consider electrostatics in $$1$$-dimension (say, the $$x$$-axis). Now consider a positive charge $$+q$$ located at $$x=0$$, and two equal negative charges $$-q$$ are held fixed at $$x=+a$$ and $$x=-a$$. In this configuration, the total force on $$+q$$ at $$x=0$$ is zero i.e., the charge at $$x=0$$ is in equilibrium. Moreover, it is also a stable equilibrium i.e., if we slightly displace $$q$$ towards left or right, then it would oscillate about $$x=0$$. This means that it is possible to keep the charge $$+q$$ in stable equilibrium by electrostatic forces alone.

But this again goes against Earnshaw's theorem. Again I must be missing something. Is it that when I say the charges at $$x=\pm a$$ are held fixed, I am using mechanical forces and thus move outside the purview of Earnshaw's theorem?

In any number of dimensions, the electric field obeys Gauss's law. So in $$d$$ spatial dimensions, $$E(r) \propto \frac{1}{r^{d-1}}.$$ In particular, for $$d = 1$$, the electric field of a charge is constant. This makes sense, because the field lines don't have any direction to "spread out" in. In your setup, the electric field due to the negative charges is exactly zero everywhere between them, so the equilibrium is only neutrally stable, in accordance with Earnshaw's theorem.
• I might have held the charges at $x=\pm a$ by using mechanical forces, only electrical forces apply on the charge at $x=0$. So I'm still allowed to apply Earnshaw's theorem. Is that correct to contemplate? @knzhou – SRS Apr 4 at 15:26
• @SRS Yes, you're allowed to hold some things fixed, and then only talk about the stability of the other things. Stability is a local notion. Holding certain charges fixed is really just like saying you postulate certain boundary conditions for the electric field on $(-a, a)$. – knzhou Apr 4 at 15:28
• @lalala Yes, I skipped to Gauss's law to keep the answer short. The usual way E&M in arbitrary dimensions is specified is by the covariant form, $F = dA$ and $d \star F = 0$. If we define $E^i = F^{i0}$, then $d \star F = 0$ gives Gauss's law in all dimensions. – knzhou Apr 4 at 15:48