  An arbitrary initial magnetic field in an A star evolves into a stable
equilibrium. Simulations are presented of the formation of non-axisymmetric
equilibria consisting of twisted flux tubes meandering under the surface of the
star, and analytic arguments are given relating the stability and form of these
equilibria. These results may help to explain observations of Ap stars with
very non-dipolar fields. This work is also applicable to other essentially
non-convective stars such as white dwarfs and neutron stars.
