PlanetMag: Software for Evaluation of Outer Planet Magnetic Fields and Corresponding Excitations at Their Moons

Spacecraft magnetic field measurements are able to tell us much about the planets' interior dynamics, composition, and evolutionary timeline. Magnetic fields also serve as the source for passive magnetic sounding of moons. Time‐varying magnetic fields experienced by the moons, due to relative planetary motion, interact electrically with conductive layers within these bodies (including salty subsurface oceans) to produce induced magnetic fields that are measurable by nearby, magnetometer‐equipped spacecraft. Many factors influence the character of the induced field, including the precise amplitude and phase of the time‐varying field, known as the excitation or driving field and represented by excitation moments. In this work, we present an open‐source Matlab software package named PlanetMag that features calculation of planetary magnetic field models available in the literature at arbitrary positions and times. The implemented models enable simultaneous inversion of the excitation moments across a range of oscillation frequencies using linear least‐squares methods and ephemeris data with the SPICE toolkit. Here we summarize the available magnetic field models and their associated coordinate systems. Precisely determined excitation moments are a critical input to forward models of global induced fields. Our results serve as a prerequisite to any precise comparison to spacecraft data for magnetic sounding investigation of giant planet moons—connecting the induced magnetic field to a moon's interior requires accurate representation of the oscillating excitation field. We calculate complex excitation moments relative to the J2000 epoch and share the results as ASCII tables compatible with related software packages intended for induction response calculations.


Introduction
The giant planets-Jupiter, Saturn, Uranus, and Neptune-all have strong, internally generated magnetic fields (Schubert & Soderlund, 2011).The intrinsic field of each rotates with the planet.For this reason, they are believed to be generated deep in the interior, by the action of a dynamo (Stanley & Glatzmaier, 2010)-fluid motion of electrically conductive materials in the rotating frame of the planet generate stable magnetic fields.The magnetic fields of the planets demonstrate considerable variability.Properties of the dynamo region are expected to be what dictates the structure of the intrinsic field, which is represented by multipole magnetic moments.Multipole moments are spherical harmonic coefficients used to describe the magnetic field outside the body.
In the reference frame of each moon orbiting these planets, the ambient magnetic field oscillates with time, owing to non-zero eccentricity and inclination, the rotation of the parent planet to which the magnetic moments are fixed, or both.These relative planetary motions typically give rise to magnetic field variations at the orbital period of the moon and apparent rotation rate of the planet, respectively, due to positional differences between the two bodies.Time-varying magnetic fields drive electrical currents within conductive layers of the moons, thereby producing an induced magnetic field that is measurable outside the body.
Induced magnetic fields, properly isolated from other magnetic field contributions such as the background planetary field, fields associated with magnetospheric plasma currents, and spacecraft contaminate fields, can be used to detect and characterize subsurface saltwater and magma oceans.Magnetic measurements can thus be used to constrain the properties of subsurface oceans that affect the conductivity profile versus depth, such as the thickness of ice crust and ocean layers, salinity and temperature profiles, etc.Indeed, such measurements have offered the strongest evidence yet available for the presence of a subsurface ocean within Europa (Kivelson et al., 2000), and have been used to place some constraints on the properties of its ocean and ice shell (Hand & Chyba, 2007;Schilling et al., 2007;Zimmer et al., 2000).
Magnetic sounding investigation of moons is a multi-step process.Relating magnetic measurements from a spacecraft to constraints on interior structure requires all of the following steps: 1.An estimate of the periodic oscillations in the applied field (the "excitation" field) in the frame of the moon 2. Hypothesized electrical conductivity structure of the interior-the layer configuration and conductivity of each 3.A calculation of the induced magnetic field consistent with both (1) and ( 2) 4. Removal of the planetary magnetic field, transient fields from plasma currents, and spacecraft fields from measurements 5. Statistical comparison of the induced magnetic field for each hypothesized interior structure (3) against measurements processed for background removal (4).
This work focuses primarily on the first of these steps.
The time-varying excitation field is best represented using complex coefficients that represent the amplitude and phase of the magnetic field vector components at the moon, called the excitation moments B e (Styczinski et al., 2022).Excitation moments can be retrieved from a magnetic field time series derived from a planetary field model evaluated at the position of the moon.Spectral analysis (e.g., a Fourier transform) can be used to determine the specific frequencies or periods of the oscillations, while conventional linear least-squares (LLS) methods are able to estimate the amplitude and phases of the oscillations at different periods.There are numerous magnetic field models that are available in the literature, each developed by fitting a set of spherical harmonic coefficients to magnetometer data acquired by various spacecraft.Past studies examining Europa and Callisto (Kivelson et al., 1999) and Ganymede (Kivelson et al., 2002) have used simplified approximations of the excitation moments, typically considering only a single vector component with the largest amplitude (usually associated with the synodic period, the planet's apparent rotation rate in the frame of the moon).Past study of induction at Io (Khurana et al., 2011) included full vectors and additional excitation periods, but the authors did not provide sufficient information to determine how the relative phases of each component and period were handled or which magnetic field model was applied.
The spectra of magnetic oscillations experienced by the moons of the giant planets have been considered in past work.However, no prior studies have provided numerical results for both the amplitude and phase of the complex excitation moments that are required to calculate the induced magnetic field.Cochrane et al. (2021Cochrane et al. ( , 2022) ) each performed a frequency decomposition of the excitation spectra for the moons of Uranus and Neptune, respectively, using an LLS inversion (see Section 2.1) in body-fixed frames defined by the International Astronomical Union (IAU), as in this work.Arridge and Eggington (2021) used a similar LLS inversion in study of the uranian moons.Biersteker et al. (2023) used an LLS inversion for Europa in the IAU frame as a test case, but the excitation moments were not detailed.All other prior studies have evaluated the amplitude of periodic oscillations using a Fast Fourier Transform (FFT) method, which is incapable of accurately determining the amplitudes and phases of excitation moments due to spectral leakage that results when one or multiple sinusoids are not perfectly periodic within the FFT sampling time series.The excitation spectra of Jupiter's large moons were evaluated in System III (1965) coordinates of the planet by Seufert et al. (2011) and in IAU frames by Vance et al. (2021, excluding Io).Excitation spectra for the large moons of Uranus were evaluated in System III coordinates by Arridge and Eggington (2021) and in moon-centric frames close to, but not identical to, IAU frames by Weiss et al. (2021).A detailed description of each coordinate system is contained in Supporting Information S1 (Text S1).

Earth and Space Science
10.1029/2024EA003552 In this work, we provide a means of calculating the complex excitation moments for all major moons of the giant planets relative to the J2000 epoch via the open-source framework PlanetMag and include ASCII tables of results for each moon (Styczinski & Cochrane, 2024c).Magnetic field models for the internal and external contributions (e.g., current sheets, magnetopause currents, etc.) are available in the literature, but the diversity of employed coordinate systems, model formats, and software inconsistencies can make evaluation of these models difficult and time consuming.Software for evaluation of some models is available, but existing frameworks are limited in scope (Table 1).PlanetMag includes all peer-reviewed magnetospheric field models for all of the giant planets in a common Matlab package, which can be evaluated at arbitrary locations and times.Each model is validated against magnetic measurements from relevant spacecraft available from the Planetary Data System (PDS, see Table 4).Spacecraft, planet, and moon positions and trajectories are precisely determined for any input time by integration with the SPICE toolkit developed by the NASA Navigation and Ancillary Information Facility (NAIF; Acton, 1996).The excitation moments are evaluated for each moon for a selected model over an era relevant to a selected spacecraft.A limited duration pertaining to the residence time of a spacecraft must be selected because the orbital and rotational parameters of the planets and moons drift over time due to tidal forcing, and so too must the excitation moments.
Our  (2023).Because of the variation in magnetic field that is expected over long time periods (known as secular variation), for future missions that entail multiple moon flybys such as Europa Clipper (Vance et al., 2023) and JUICE (Fletcher et al., 2023), the excitation moments can be more accurately solved for directly from joint flyby measurements.However, for single-flyby mission concepts, where long periods cannot be measured over the course of the mission, using excitation moments extracted from a magnetic field model as described in this work is essential for magnetic investigation of icy bodies (Cochrane et al., 2022).
Several open-source software libraries and frameworks are already available for the evaluation of planetary field models for the outer planets, detailed in Table 1.Most available models focus on a single planet.To our knowledge, Table 1 includes all currently available open-source software packages for evaluation of giant planet magnetic fields as of this writing.No available models include features for calculation of excitation moments or integration with SPICE.Therefore, we created PlanetMag (Styczinski & Cochrane, 2024b) to offer these features within a single software package.The software is thoroughly documented (documentation is available at https:// coreyjcochrane.github.io/PlanetMag/)and a Python port is in development.

Methods
For most moons, the magnetic field of the parent planet varies little on the spatial scale of the moon.As a result, it is customary to consider only the oscillations in the mean field across each moon, approximated as that evaluated at the body center.Notable exceptions are Io, with as much as a 58 nT difference, Europa with a 7.3 nT difference, and Mimas with a 4.9 nT difference from the sub-planetary point to its antipode, all of which we have calculated using the default models implemented in PlanetMag (Tables 2 and 3).Periodic oscillations in the difference in the local magnetic field across the body contribute excitation moments of degree 2 and higher, which will decay faster than 1/r 3 except in the case of highly asymmetric bodies (Styczinski et al., 2022).Magnetic induction from excitations of degree 2 may be significant for sounding of Io, but calculation of these moments is left for future work.
Excitation moments associated with the time-varying portion of the mean field are of spherical harmonic degree 1 and can be represented by complex vector components aligned to the axes of the desired coordinate system.The ambient field at the body center at time t can be represented with where B e k are the time-varying field vectors periodically oscillating at angular frequencies ω k , including the static field at ω DC = 0.The ambient field is complex in general-the measurable field is evaluated by taking the real part of the complex total (Jackson, 1999).
To retrieve the excitation moments in the frame of the moon, we first determine the location of the moon in the coordinates of the planetary field model using SPICE-each required frame is defined in our custom frames kernel or built-in to the SPICE satellites kernels.Next, we evaluate the planetary magnetic field model (Tables 2  and 3) over a period of time that spans the desired epoch with a number of sampling times N (by default, O 10 6 ) )  2007)) along with the analytical current sheet model of Connerney et al. (1981).
O6 + K Degree-6 partial fit of Connerney (1992) to primarily Voyager 1 magnetic data, along with the current sheet model of Khurana (1997).

KS2005
Combined magnetosphere model of Khurana and Schwarzl (2005).Uses the VIP4 intrinsic field model, but with the dipole moment rotated to match the O6 orientation, and a current sheet model constrained by crossings inferred from magnetic data of Galileo and all prior spacecraft to visit the planet.
JRM09 + C2020 Juno Reference Model through 9 orbits, a degree-20 intrinsic field model (Connerney et al., 2018) and the analytical current sheet model of Connerney et al. (2020), updated to pair with the JRM09 model.Both are fit to Juno data.Moments are well-resolved up to degree 10.For C2020, we use the overall fit parameters contained in Table 1 of Connerney et al. (2020).
VIP4 + K VIP4 model with current sheet of Khurana (1997).This is the model studied by Seufert et al. (2011).

JRM33 + C2020
Degree-30 intrinsic field of Connerney et al. ( 2022) through Juno's first 33 orbits along with current sheet model of Connerney et al. (2020), also fit to Juno data.Moments up to degree 13 are well-resolved.
Note.The default model, under which we have calculated excitation moments for the major moons, is highlighted in bold.
Parameters for each model are hard-coded, with spherical harmonic coefficients read from text files at run time.Analytical current sheet models for both C1981 and C2020 use the formulation of Connerney et al. (1981) with overall fit parameters listed in each publication.
Earth and Space Science 10.1029/2024EA003552 and rotate this field vector into the desired frame of the moon using transformation functions implemented in SPICE.The excitation moments can then be extracted from the resultant time series, B i = B model (t i ).For rapid evaluation of the underlying models in PlanetMag, we have implemented a direct calculation of spherical harmonics and their derivatives in the Schmidt normalization up to degree 10.At distances of the orbiting moons, the higher-degree harmonics have negligible contributions.We have also have begun to implement an evaluation of each available model of the magnetic fields from selected magnetopause current models, but these models are considered preliminary and have not been used in determining the excitation moments in this work.
Numerous coordinate systems have been considered in past magnetic sounding investigations.In this work, we evaluate all excitation moments in the IAU frame of each moon in Cartesian coordinates.This approach has several advantages.The IAU frames are implemented in all SPICE kernels containing the moons, which enables simple conversion between coordinate systems and evaluation of spacecraft trajectories using functions built-in to SPICE.More importantly, IAU frames are fixed to the surface of the body.Integration with SPICE in evaluating the excitation moments in the frame of the body thus enables a proper accounting for all motional effects on the periodic components of the excitation field, including libration, apsidal precession, etc.These effects are significant for some bodies, as in the case of Europa, where excitation at the true anomaly period (TA; the time between periapsis crossings) differs from that at the orbital period (the time between ascending node crossings), including in terms of the affected components (Table 5).IAU frames are the only ones considered in past work

Cassini 11+ Saturn
Degree-14 intrinsic field model of Cao et al. (2020); similar to Cassini 11 but with different regularization and using a subset of Grand Finale orbits.

Q3 Uranus
Quadrupole-resolved, degree-3 fit of Connerney (1987) to Voyager 2 magnetic data.Includes a degree-1 fit to an externally applied field.

AH5 Uranus
Auroral Hexadecapole L = 5 intrinsic field model of Herbert (2009).Moments up to degree 4 fit to Voyager 2 magnetic data and auroral observations.This is the model studied by Weiss et al. (2021) and Cochrane et al. (2021) a .
Moments above degree 3 are not uniquely determined.
Note.Default models, under which we have calculated excitation moments for the major moons, are highlighted in bold.

Earth and Space Science
10.1029/2024EA003552 that have been body-fixed frames.See Text S1 in Supporting Information S1 for a description of the IAU frames and others implemented in PlanetMag, including those used in past studies.

Inversion of Excitation Moments
Using the magnetic field vector time series B i sampled at times t i in the IAU frame of a moon, we perform a frequency decomposition of the excitation moments using an LLS optimization approach.The model magnetic field can be estimated as the real part of a superposition of sinusoids in terms of the excitation moments and their corresponding angular frequencies: where B e k = B e k,Re + iB e k,Im .These coefficients can be found by minimizing the sum of squared errors, that is, ∑ i (B model (t i ) Re{B amb (t i )}) 2 .There are a total of 6F + 3 coefficients for each inversion, where F is the number of frequencies used in the inversion.This includes 6 coefficients for every excitation frequency-the real and imaginary part for each vector component of the magnetic field vector-and 3 coefficients in the static background magnetic field vector.
In the following, the index k refers specifically to the real or imaginary part of a frequency component.Given a list of expected excitation frequencies f = {f k }, the LLS-optimized coefficients for the excitation moments can be directly calculated using classical methods (for reference, see Markovsky & Van Huffel, 2007).The LLS inversion is calculated as follows.For ω k = 2πf k , the columns of the design matrix X ik are cos(ω k t i ) for the real part of each excitation moment and sin(ω k t i ) for the imaginary part.Each row in X ik corresponds to a time t i in the time series, that is, The same design matrix with 2F + 1 columns is used for each vector component.The eigenvectors of X ik are the columns of the weight matrix W, such that Note.These moments were evaluated with the JRM33 intrinsic field model (Connerney et al., 2022) and the analytical current sheet model of Connerney et al. (2020).No magnetopause currents were modeled in calculating these values.A full list of excitation moments for all large moons of the giant planets and for all implemented models and spacecraft eras is available as a Zenodo archive (Styczinski & Cochrane, 2024c).

10.1029/2024EA003552
where B e j,k lists the real and imaginary parts of the excitation moment for vector component j and êj is a unit vector in the direction of component j.The product X ik W is commonly referred to as the pseudo-inverse.The results for B e j,k from Equation 5 are those that minimize the sum of squared errors.The complex excitation moments for each frequency k are then constructed from and the LLS fit to the input time series can be evaluated with The list of excitation frequencies f of the moments are identified from the natural spectrum of oscillations in an FFT of the time series B i .Each Fourier spectrum is rich in driving field oscillations, typically including the synodic period, the orbital period, and the harmonics and beats of these two fundamental periods.These frequencies are precisely calculated from information contained in cartographic reports (see Text S1.1 in Supporting Information S1) and retrieved from the SPICE planetary constants kernel.
The list f is refined iteratively in order to best reproduce the time series B i with Equation 2 after inverting for the excitation moments.At each of the following steps, we evaluate an FFT of the residuals, that is, the difference between the input time series and its reproduction using Equation 2. The process is continued until the residual spectrum has no peaks over 1 nT, a commonly considered detection threshold, and minimal peaks below this threshold, which essentially represent noise.An example residual FFT for the magnetic field that Europa experiences, after completion of this process, is shown in Figure 1.  2. The residuals are the differences for each evaluation time between a vector component of the model field and the reproduction generated with the inverted excitation moments, that is, Several key excitation periods that are very stable over the input era exhibit a marked reduction in power in the residual spectrum, demonstrating that these excitation periods are well-represented by the inverted moments.Some other excitations, such as those at the true anomaly and orbital periods, do not show the same reduction despite being well-captured because these periods drift over time.

10.1029/2024EA003552
We first find the excitation moments with just the known synodic period and sidereal orbit period.Next, we add a wide array of beats and harmonics associated with these excitation periods.The frequencies of remaining unknown peaks in the residual spectrum are determined numerically using linear combinations of the leakage-spread points in the spectrum near the peak, successively until the peak is precisely determined.Examples of such peaks unrelated to beats and harmonics include true anomaly periods for moons with marked apsidal precession, including Europa and Enceladus.After each such peak is precisely determined, its harmonics and beats with other excitation periods are added to f.Finally, once all peaks in the residual spectrum are below 1 nT, frequencies are removed from f, starting with those associated with the lowest amplitudes in the LLS-inverted excitation moments, until as few amplitudes below 1 nT are included among the moments and no peaks in the residual spectrum are over 1 nT.

Model Validation
To confirm the correct implementation of the many models we have included in PlanetMag, we compare each against spacecraft magnetic measurements gathered near the relevant planet.The data sets we compare are all available from the PDS.All data comparisons demonstrate close agreement with the evaluated model (Figure 2).
PlanetMag employs a direct calculation of spherical harmonics and their derivatives up to degree 10 in spherical coordinates in the Schmidt normalization for evaluation of intrinsic field models.In order to confirm that these calculations have been implemented correctly, we undertook a cross-comparison with the same calculations under different normalizations with MoonMag (Styczinski, 2023).MoonMag features the same calculations with complex, orthonormal spherical harmonics and with real-valued Schmidt-normalized harmonics, both in Cartesian coordinates.We constructed a HEALpix map (Gorski et al., 2005) for evaluation under all 3 methods of Earth and Space Science 10.1029/2024EA003552 calculating the magnetic field at the planet surface for each pure multipole moment (e.g., each combination of n, m, and sin mϕ or cos mϕ) and compared the results, addressing any discrepancies until all methods produced the same results up to machine precision.

Results
The magnitude of the magnetic field for each of the giant planets evaluated with PlanetMag at the IAU-defined planetary radius is shown in Figure 3. PlanetMag is designed for evaluation of planetary field models at arbitrary locations and times in the middle magnetosphere for each planet, where the majority of the moons reside.Magnetodisk models and spherical-harmonic intrinsic field models break down at distances on the scale of the magnetopause standoff distance (e.g., ∼50R J for Jupiter) and limiting our evaluation to degree 10 for the intrinsic field means that regions within 1to2 planetary radii of the 1 bar surface will not be modeled accurately due to the missing higher-order moments.We have used the capabilities of our implementation with the default models described in Tables 2 and 3, precise ephemerides from SPICE, and our LLS inversion method to determine the excitation moments for all major moons in the outer solar system.A subset of the excitation moments for Europa is detailed in Table 5.The excitation field can be calculated at arbitrary times using Equation 2. For example, ignoring the smaller excitations not included in where t is in TDB seconds relative to J2000 (also called ephemeris time ET in SPICE), ω k = 2π/T k with T k in s, and B e k are the complex excitation moment vectors listed in Table 5.The full set of excitation moments we have calculated using default models is compiled into ASCII data tables (Styczinski & Cochrane, 2024c).et al., 2022) shows similar trends, but use of planetocentric versus planetographic coordinates and our degree-10 limit for the intrinsic field will exhibit some differences on short distance scales.
Earth and Space Science 10.1029/2024EA003552 STYCZINSKI AND COCHRANE Hodograms showing a planar projection of the path traced by the magnetic field vector in a selected plane are shown in Figure 4. Lines in these diagrams appear thick or smeared due to superposition of multiple excitations, each contributing vectors of varying amplitudes and phases.The hodograms have been constructed from the same data as those used to calculate the excitation moments-a time series of the default model for each planet at the location of each moon for approximately 10 6 equally spaced time steps spanning a particular era.We chose the Juno era for Io, Europa, and Ganymede due to relevance for analyzing Juno flyby data from each moon, and the Galileo era for Callisto.We used the VIP4+K model to calculate the excitation moments for Callisto instead of the default in Table 2.This is because the planar models of Connerney et al. (1981Connerney et al. ( , 2020) ) do not capture the bendback of the current sheet, which contributes significantly to the field at Callisto's relatively large orbital distance (about 26.3R J ), as compared to hinged current sheet models such as Khurana (1997) (Khurana & Schwarzl, 2005).For the moons of Saturn, we used the Cassini era because of the wealth of data available from  (Styczinski & Cochrane, 2024c), that is, the default models in Tables 2 and 3 Earth and Space Science 10.1029/2024EA003552 that mission.For moons of Uranus and Neptune, we used the Voyager era, a 6-month period centered on the Voyager 2 flyby of each planet from which in situ data were gathered.The excitation moments shift over time and will yield different results when calculated with different planetary field models.All magnetic field models implemented in PlanetMag can be used to calculate excitation moments over any duration supported by the loaded SPICE kernels.

Discussion and Conclusions
The planetary magnetic field models in PlanetMag show favorable comparison to the spacecraft measurements from which the models were derived (e.g., Figure 2), which implies they have been correctly implemented.Spurious signals from disturbances in the surrounding plasma environment, which are not captured in planetary field models, will not affect the long-term periodicity of the excitation field, and so will not affect the excitation moments.However, periodic motion or variance in the plasma around each moon, oscillating at the same key periods, especially that driven by the same excitations as those we calculate in this work, will affect the excitation moments.Accounting for such effects is beyond the scope of this work.The principle of superposition dictates that the contributions from plasma can be summed independently from those of the excitation field from the broader magnetosphere, but the contributions from plasma that react to the same excitations will tend to decrease the driving field and thus change the net time-varying field in the frame of the moon.
The effects of periodic variance in the plasma environment have never been self-consistently modeled along with the excitation field in magnetic sounding investigations, although Schilling et al. (2007) modeled how the variance in Europa's plasma environment may affect inferences of its interior structure.Future work, including analysis of measurements from the Europa Clipper mission, must account for periodicity in the plasma environment to most accurately estimate the excitation moments applied to the moon.Plasma motion may also contribute its own excitations at periods not matching those from the planetary field (e.g., Blöcker et al., 2016;Harris et al., 2021;Schilling et al., 2008), which could confound efforts to isolate the induced magnetic field.
Magnetic fields in the frame of each moon are not constructed of perfectly sinusoidal contributions, so the excitation moments can never perfectly reproduce the input time series.The excitation frequencies f are not constant over time, because tidal perturbations from mutual gravity and the dissipation of energy inside each body change their orbital elements and rotational properties over time.Many such effects are considered in the development of IAU frames and in trajectory calculations with SPICE.However, while accounting for these drifts in motional parameters promotes a more complete description of excitation moments, as in the case of the TA period at Europa, it also adds a small amount of noise to the excitation spectrum.This is why the orbital and TA periods do not show the same dramatic reduction in represented power as the shorter-period, more stable excitations in the residual spectrum for Europa (Figure 1).
As currently implemented in PlanetMag, the list of excitation frequencies f used to define the design matrix X ik is specified manually using the procedure detailed in Section 2.1.The list f is hard-coded for each moon and calculated at run time from parameters in the SPICE planetary constants kernel and some manually determined excitation periods.An algorithmic method of determining the signal components, as is typical with the related method of Independent Components Analysis (Hyärinen & Oja, 2000;Hyvärinen, 2013), would have advantages and disadvantages.Removing the need for applying judgment or an arbitrary cutoff in acceptable residual power would improve the reproducibility of the determined excitation periods.However, drift in orbital and rotational parameters over time suggests that prioritizing expected oscillation periods may result in excitation moments that are of greater explanatory value in magnetic sounding investigations, and may be more accurate when extrapolated beyond the calculated time series era.
Calculation of spherical harmonics and their derivatives for intrinsic field models is limited in PlanetMag to degree 10.We have written bespoke functions for this purpose, which speeds up calculations dramatically because of the recursion relations used to evaluate arbitrary spherical harmonics, and the more complicated solutions that are required for their derivatives, both of which are required to calculate magnetic fields from multipole moments.We evaluated the harmonics and their derivatives with Mathematica for all spherical harmonic calculations implemented in PlanetMag and MoonMag.Transcribing these to machine-readable calculations and validating the result was a tedious process.Although future versions may include calculations to greater than degree 10, the induced fields at the locations of the large moons are primarily dominated by multipole Earth and Space Science 10.1029/2024EA003552 moments of octupole order and below.Current sheet models typically have a large influence on the field experienced by each moon, and at their orbital distances typically the dipole moment is the only significant multipole moment.Therefore, we caution users of the software about its use in regions near the planet, where the unmodeled high-degree moments will have the greatest effect, and very far from the planet, where current sheet models are less accurate, but we consider the current implementation well-suited for application near the moons.
PlanetMag is the first open-source package to feature the calculation of the excitation moments B e critical for magnetic sounding investigations.It is also the first software supporting the evaluation of magnetic field models across the outer solar system with SPICE integration, which extends its utility far beyond our intended development purpose, which is the precise calculation of B e .Complex excitation moments determined with as much attention to the well-known orbital and rotational parameters of the planets and moons as we have included enable time-dependent comparisons to spacecraft data of planetary and induced fields with unprecedented accuracy.We make this software and data available so that they may be used to improve current estimates and future analyses of spacecraft magnetic data.

Figure 1 .
Figure1.Fast Fourier Transform (FFT) of the residuals from inversion of the excitation spectrum for Europa, during the Juno era and with the JRM33+C2020 model as detailed in Table2.The residuals are the differences for each evaluation time between a vector component of the model field and the reproduction generated with the inverted excitation moments, that is, ΔB i = B model (t i ) Re{B amb (t i )}.Several key excitation periods that are very stable over the input era exhibit a marked reduction in power in the residual spectrum, demonstrating that these excitation periods are well-represented by the inverted moments.Some other excitations, such as those at the true anomaly and orbital periods, do not show the same reduction despite being well-captured because these periods drift over time.

Figure 2 .
Figure 2. Comparison of Cassini 11+ model predictions and measurements from the Cassini spacecraft for the B θ component (top) and differences for all components (bottom) in System III spherical coordinates during the year 2016.Each row shows the same data-on the left, the comparison is chronological, and on the right, the comparison is organized by distance from Saturn.Models implemented for the other giant planets show similar agreement with the compared measurements.

Figure 3 .
Figure3.Magnetic field magnitude in gauss evaluated with PlanetMag at the IAU-defined equatorial radius for each planet, that is, the 1 bar radius, in planetocentric System III coordinates.Jupiter: R J = 71,492 km; Saturn: R S = 60,268 km; Uranus: R U = 25,559 km; Neptune: R N = 24,764 km.Note that comparison to similar diagrams from past studies (e.g.,Connerney et al., 2022) shows similar trends, but use of planetocentric versus planetographic coordinates and our degree-10 limit for the intrinsic field will exhibit some differences on short distance scales.

Figure 4 .
Figure 4. Hodograms for large moons in the outer solar system.The represented data are those used to calculate the excitation moments(Styczinski & Cochrane, 2024c), that is, the default models in Tables2 and 3, except for Callisto, for which we have used VIP4+K.Each diagram shows the path traced by the tip of the magnetic field vector projected into the IAU xy (equatorial) plane in nT, except for the moons of Saturn which show the IAU xz plane.All panels have an equal aspect ratio, showing an equivalent range along both axes.
Figure 4. Hodograms for large moons in the outer solar system.The represented data are those used to calculate the excitation moments(Styczinski & Cochrane, 2024c), that is, the default models in Tables2 and 3, except for Callisto, for which we have used VIP4+K.Each diagram shows the path traced by the tip of the magnetic field vector projected into the IAU xy (equatorial) plane in nT, except for the moons of Saturn which show the IAU xz plane.All panels have an equal aspect ratio, showing an equivalent range along both axes.
prior work has used excitation moments calculated from precursors to what has now become PlanetMag:

Table 1
Open-Source Software Packages Currently Available for Evaluation of Planetary Magnetic Field ModelsNote.All packages focus on a single planet except planetMagFields and libinternalfield, both of which feature only intrinsic field models.None of the available packages features a calculation of excitation moments or integration with SPICE, both of which we implement in PlanetMag.a Non-archived IDL code is currently available at https://lasp.colorado.edu/mop/resources/code/.

Table 2
Model Combinations Implemented in PlanetMag for Jupiter

Table 3
Models Implemented in PlanetMag for Planets Beyond Jupiter

Table 4
Default Combinations of Planetary Magnetic Field Models and Data Sources Used for Validation