  We present a code for solving the nonlinear force-free equations in spherical
polar geometry, with the motivation of modeling the magnetic field in the
corona. The code is an implementation of the Grad-Rubin method. Our method is
applicable to a spherical domain of arbitrary angular size. The implementation
is based on a global spectral representation for the magnetic field which makes
no explicit assumptions about the form of the magnetic field at the transverse
boundaries of the domain. We apply the code to a bipolar test case with
analytic boundary conditions, and we demonstrate the convergence of the
Grad-Rubin method, and the self-consistency of the resulting numerical
solution.
