B. Vector Potential also must select some particular gauge. And even after a particular type of gauge has been chosen, say a Coulomb gauge, there is still some remaining freedom [4]. One convenient Coulomb gauge choice is given by the rules To determine an associated vector potential A , we must find a solution to the coupled system of equations ∇ × A = ∇ ψ , where ψ is given by the series (11). We surface far from the axis and interpolating inward us- ing the Maxwell equations. Surface fitting methods have several advantages, including: The coefficients C [ n ] $_{m,s}$( z ) and C [ n ] $_{m,c}$( z ) describe normal and skew components, respectively. For example, in the body of a long normal dipole ( m = 1), we expect C [0] 1 $_{,s}$( z ) will be nearly constant (independent of z ) and there- fore C [ n ] 1 $_{,s}$( z ) ≃ 0 for n > 0. Correspondingly, in the body of a long normal dipole, use of (12) gives the re- sults A$_{x}$ ≃ A$_{y}$ ≃ 0 and Similarly, in the body of a long normal quadrupole ( m = 2), use of (12) gives the results A$_{x}$ ≃ A$_{y}$ ≃ 0 and For any set of analytic functions C [ n ] $_{m,α}$( z ) employed in (11), the vector potential defined by (12) satisfies the conditions: 1) ∇ × A = ∇ ψ = B , 2) ∇ × ∇ × A = 0, and 3) ∇· A = 0. Note that both Maxwell’s equations and the Coulomb gauge condition are satisfied by construction. In the following section, we will see how the coefficient functions C [ n ] $_{m,α}$( z ) can be numerically determined. There are cases in which Taylor expansions of the form (11) and (12) can be found analytically. In general, how- ever, we have available only measured or numerical three- dimensional magnetic field data on a discrete mesh of points distributed throughout the region of interest. The required high derivatives of ψ or A cannot be reliably computed directly from this data by numerical differ- entiation due to numerical noise, whose effect becomes worse with the order of derivative desired. The effect of numerical noise, and its amplification by numerical dif- ferentiation, can be overcome by fitting on a bounding Let us briefly compare this approach to that of on-axis or midplane fitting. In the case of on-axis fitting, it is common to use various analytic model profiles, such as Enge functions, and then differentiate them repeatedly 5. Because harmonic fields take their extrema on boundaries, interior values inferred from surface data are relatively insensitive to errors/noise in the surface data. Put another way, the inverse Lapla- cian (Laplace Green function), which relates inte- rior data to surface data, is smoothing . It is this smoothing that we seek to exploit. In general, the sensitivity to noise in the data decreases rapidly (as some high inverse power of distance) with increas- ing distance from the surface, and this property improves the accuracy of the high-order interior derivatives needed to compute high-order transfer maps. 4. The error is globally controlled. Fields that are harmonic (fields that satisfy the Laplace equation) take their extrema on boundaries. Both the exact and computed fields are harmonic. Therefore their difference, the error field, is also harmonic, and must take its extrema on the boundary. But this is precisely where a controlled fit is made. Thus, the error on the boundary is controlled, and the interior error must be even smaller. 3. The results are manifestly analytic in all variables. 2. The Maxwell equations are exactly satisfied. 1. Only functions with known (othonormal) complete- ness properties and known (optimal) convergence properties are employed. A$_{z}$ = − C [0] 1 $_{,s}$x. (13) A$_{z}$ = − C [0] 2 $_{,s}$( x 2 − y $^{2}$) . (14) III. SURFACE METHODS A$_{z}$ = ∞ ∑ l =0 ∞ ∑ m =0 ( − 1) l m ! 2 2 $^{l}$l !( l + m )! $^{[}$C [2 l ] $_{m,c}$( z ) F l,m s − C [2 l ] $_{m,s}$( z ) F l,m c $^{]}$. (12c) A$_{y}$ = ∞ ∑ l =0 ∞ ∑ m =0 ( − 1) l m ! 2 2 l $^{+1}$l !( l + m + 1)! $^{[}$C [2 l +1] m,c ( z ) F l,m +1 c + C [2 l +1] m,s ( z ) F l,m +1 s $^{]}$, (12b) A$_{x}$ = ∞ ∑ l =0 ∞ ∑ m =0 ( − 1) l m ! 2 2 l $^{+1}$l !( l + m + 1)! $^{[}$C [2 l +1] m,s ( z ) F l,m +1 c − C [2 l +1] m,c ( z ) F l,m +1 s $^{]}$, (12a) 3