1 Introduction

Magnetic helicity (hereafter “helicity”; e.g. Berger, 1999) is an invariant of the ideal magnetohydrodynamic (MHD) equations (Woltjer, 1958), and is approximately conserved in plasma with high magnetic Reynolds number (Berger, 1993) such as the solar corona. Closely related to helicity is magnetic winding (hereafter “winding”; e.g. Prior and MacTaggart, 2020), which measures the entanglement of magnetic field lines (hereafter “field lines”), and helicity is simply the flux-weighted winding (e.g. Moffatt, 1969; Berger and Field, 1984; Moffatt and Ricca, 1992; Arnold and Khesin, 2021). Significant changes in helicity and/or winding correspond to magnetic reconnections and are often correlated with the onset of flares and coronal mass ejections (e.g., LaBonte, Georgoulis, and Rust, 2007; Wyper, Antiochos, and DeVore, 2017; Thalmann et al., 2019; Raphaldini, Prior, and MacTaggart, 2022; Soós et al., 2022).

For a given magnetic field \(\boldsymbol {B}\) in a connected volume \(V\), the usual definition (e.g. Moffatt and Dormy, 2019) of helicity is:

$$ H(\boldsymbol {B})=\int \boldsymbol {A}\cdot \boldsymbol {B} \ {\mathrm {d}} {V}\,. $$
(1)

It involves the non-unique choice of vector potential \(\boldsymbol {A}\) such that \({\boldsymbol{\nabla} } \times \boldsymbol {A}=\boldsymbol {B}\). Indeed, any gauge transformation \(\boldsymbol {A}\mapsto \boldsymbol {A}+ {\boldsymbol{\nabla} } \chi \) for a scalar function \(\chi \) recovers the same field, while helicity is changed by a boundary integral if there are non-zero normal field components on the boundary of \(V\) (or “open domains”). This applies to coronal magnetic fields that typically penetrate the photosphere, and Prior and Yeates (2014) showed that helicity can indeed take arbitrary values.

For helicity to be compared for different coronal active regions (ARs), it is therefore crucial to have alternative definitions immune to such ambiguities. A popular choice is relative helicity (Berger and Field, 1984; Finn and Antonsen, 1985) converting vector potential choices to choices of reference magnetic fields (commonly chosen to be the potential field). More geometrical in nature is the winding-based definition proposed in Prior and Yeates (2014, 2021), defining helicity as the flux-weighted winding of field lines in Cartesian tubular domains. This formalism has recently been generalised by Xiao, Prior, and Yeates (2023) to spherical domains in which ARs are best described. Over a full sphere, it is equivalent to the relative helicity.

Although ARs responsible for some of the most powerful solar activities span a large proportion of the solar disc, the intrinsic curvature of the photosphere has been only partially accounted for in most studies involving helicity and/or winding (e.g. Liu and Schuck, 2012; Vemareddy, 2019; MacTaggart and Prior, 2021). Magnetic-field components in spherical coordinates are used on Cartesian projections of photospheric patches, mostly in the cylindrical equal-area projection to match vector magnetogram data provided by Space-Weather Active Region Patches (SHARP) from the Helioseismic and Magnetic Imager (HMI) onboard Solar Dynamical Observatory (SDO) (Hoeksema et al., 2014).

Nevertheless, several studies have started including the full spherical geometry (see Moraitis et al., 2018 and references therein). Given the little consensus on which definitions, assumptions, and approximations should be adopted, the geometrical formalism proposed in Xiao, Prior, and Yeates (2023) seems a promising candidate – it provides closed-form expressions for helicity and winding directly in terms of the observed magnetic field in spherical coordinates. This facilitates a numerical investigation into the role of spherical geometry in helicity and winding computations compared to those obtained from Cartesian approximations. Our results will confirm quantitatively that curvature effects indeed become more significant as AR size increases, as qualitatively predicted in Gary and Hagyard (1990), further demonstrating the needs of spherical methods for future global modelling of solar magnetic fields.

The layout of this paper is as follows. In Section 2 we introduce the definitions of winding and winding-based helicity in both Cartesian and spherical domains. Section 3 reviews properties of the CEA projection used by SHARP magnetograms and by Cartesian approximations. Then, in Section 4, we compute winding-based helicity and winding in both geometries and analyse the absolute and relative errors that would have been incurred by not accounting for the full spherical geometry. We summarise our findings in Section 5.

2 Magnetic Winding and Winding Helicity Density

As aforementioned, helicity in open domains would be affected by the choice of vector potentials if it were defined by Equation (1). In this paper, we instead adopt the winding-based, geometrical definition of helicity that is independent of such choices. We first introduce the concept of intrinsic winding in Cartesian geometry (Prior and Yeates, 2014). On a certain \(z\)-level, the mutual entanglement of a pair of field lines through points \(\boldsymbol {x}\) and \(\boldsymbol {x}'\) in the \(z\)-direction can be measured by the (pairwise) winding rate, defined by

$$ \frac{\mathrm{d}\mathcal{L}}{\mathrm{d}z}(\boldsymbol {x},\boldsymbol {x}') = \frac{ {-}1}{{2}\pi |\boldsymbol {x}-\boldsymbol {x}'|}\left [ \frac{B_{\chi}(\boldsymbol {x})}{B_{z}(\boldsymbol {x})}+ \frac{B_{\chi}(\boldsymbol {x}')}{B_{z}(\boldsymbol {x}')}\right ]\,, $$
(2)

with components

$$ B_{z}(\boldsymbol {x})=\boldsymbol {B}(\boldsymbol {x})\cdot \hat{\boldsymbol {e}} _{z}(\boldsymbol {x}), \quad B_{\chi}(\boldsymbol {x}) = \boldsymbol {B}(\boldsymbol {x})\cdot \hat{\boldsymbol {e}} _{z}( \boldsymbol {x})\boldsymbol{\times }\frac{\boldsymbol {x}'-\boldsymbol {x}}{|\boldsymbol {x}'-\boldsymbol {x}|} \,, $$
(3)

and similarly for \(B_{z}(\boldsymbol {x}')\) and \(B_{\chi}(\boldsymbol {x}')\) with \(\boldsymbol {x}\leftrightarrow \boldsymbol {x}'\) (same below). This is illustrated in Figure 1(a) and note that it is the \(B_{\chi}\) component that is responsible for the rotation of one field line against another (as also in the spherical case).

Figure 1
figure 1

Pairwise winding rates defined on (a) Cartesian planes and (b) spheres. Relevant quantities are defined in Equations (2) – (5). Note that \(|\boldsymbol {x}-\boldsymbol {x}'|\) and \(\xi (\boldsymbol {x},\boldsymbol {x}')\) are Cartesian and spherical distances between points \(\boldsymbol {x}\) and \(\boldsymbol {x}'\), respectively.

In the spherical case, Xiao, Prior, and Yeates (2023) constructed the analogous winding rate in the \(r\)-direction for field lines through \(\boldsymbol {x}\) and \(\boldsymbol {x}'\) at the same \(r\)-level:

$$ \frac{\mathrm{d}\mathcal{L}}{\mathrm{d}r}(\boldsymbol {x},\boldsymbol {x}') = \frac{ {-}1}{4\pi r}\frac{\sin \xi}{1-\cos \xi} \left [ \frac{B_{\chi}(\boldsymbol {x})}{B_{r}(\boldsymbol {x})}+ \frac{B_{\chi}(\boldsymbol {x}')}{B_{r}(\boldsymbol {x}')}\right ] \,. $$
(4)

Here, \(\xi (\boldsymbol {x},\boldsymbol {x}')=\arccos (\boldsymbol {x}\cdot \boldsymbol {x}'/r^{2})\) is the spherical distance between \(\boldsymbol {x}\) and \(\boldsymbol {x}'\), and relevant field components are given as

$$ B_{r}(\boldsymbol {x}) = \boldsymbol {B}(\boldsymbol {x})\cdot \hat{\boldsymbol {e}} _{r}(\boldsymbol {x}), \quad B_{\chi}(\boldsymbol {x}) = \boldsymbol {B}(\boldsymbol {x})\cdot \frac{ \hat{\boldsymbol {e}} _{r}(\boldsymbol {x})\boldsymbol{\times }\boldsymbol {x}'}{| \hat{\boldsymbol {e}} _{r}(\boldsymbol {x})\boldsymbol{\times }\boldsymbol {x}'|} \,, $$
(5)

where \(\hat{\boldsymbol {e}} _{r}(\boldsymbol {x})=\boldsymbol {x}/r\) and \(|\boldsymbol {x}\boldsymbol{\times }\boldsymbol {x}'| =\) \(r^{2} \sin \xi \). This is illustrated in Figure 1(b).

The factor \(\Gamma (\xi )\equiv \sin \xi /(1-\cos \xi )\) manifests the difference between the two geometries, which is related to the stereographic projection from spheres to planes (Kimura, 1999). From its Laurent expansion about \(\xi =0\), i.e.

$$ \Gamma (\xi )\equiv \frac{\sin \xi}{1-\cos \xi} = \frac{2}{\xi} - \frac{\xi}{6} - \frac{\xi ^{3}}{360} + O(\xi ^{5}) \,, $$
(6)

one recovers the Cartesian result (2) from the leading term by recognising \(r\xi \approx |\boldsymbol {x}-\boldsymbol {x}'|\) for small \(\xi \). Deviations are expected on a more global scale, especially for patches with large spatial extents. Also, the fact that spheres are closed surfaces leads to near-zero winding for points near opposing poles (\(\xi \simeq \pi \)).

Note that the winding rates, (2) or (4), only depend on pointwise field information. By integrating them over all pairs of points on each \(\zeta \)-level \(S_{\zeta}\), where \(\zeta \) is either \(z\) (Cartesian) or \(r\) (spherical), and then over all \(\zeta \), Prior and Yeates (2014, 2021), Xiao, Prior, and Yeates (2023) defined (magnetic) winding as

$$ L^{\mathrm{W}} = \int _{\zeta _{0}}^{\zeta _{1}}\int _{S_{\zeta}} \int _{S_{\zeta}'}\frac{\mathrm{d}\mathcal{L}}{\mathrm{d}\zeta}( \boldsymbol {x}, \boldsymbol {x}')\, \ {\mathrm {d}} ^{2}{\boldsymbol {x}'} \ {\mathrm {d}} ^{2}{ \boldsymbol {x}} \ {\mathrm {d}} {\zeta}, $$
(7)

and (magnetic) winding helicity as

$$ H^{\mathrm{W}} = \int _{\zeta _{0}}^{\zeta _{1}}\int _{S_{\zeta}} \int _{S_{\zeta}'}\frac{\mathrm{d}\mathcal{L}}{\mathrm{d}\zeta}( \boldsymbol {x}, \boldsymbol {x}')B_{\zeta}(\boldsymbol {x})B_{\zeta}(\boldsymbol {x}')\, \ { \mathrm {d}} ^{2}{\boldsymbol {x}'} \ {\mathrm {d}} ^{2}{\boldsymbol {x}} \ {\mathrm {d}} { \zeta}. $$
(8)

When \(S_{\zeta}\) is either an infinite plane or a sphere, \(H^{\mathrm{W}}\) corresponds to the usual definition (1) with the winding gauge \(\boldsymbol {A}^{\mathrm{W}}\), which satisfies

$$ {\boldsymbol{\nabla} } _{\mathcal{S}} \cdot \boldsymbol {A}^{\mathrm{W}} \equiv \boldsymbol{\nabla } \cdot \boldsymbol {A}^{\mathrm{W}} - \hat{\boldsymbol {e}} _{\zeta} \cdot \frac{\partial \boldsymbol {A}^{\mathrm{W}}}{\partial \zeta} = 0 \,. $$
(9)

While the use of \(\boldsymbol {A}^{\mathrm{W}}\) was first proposed in Cartesian geometry (Prior and Yeates, 2014, 2021), it was later recognised as a special case from the poloidal - toroidal decomposition (Berger and Hornig, 2018; Yi and Choe, 2022). In this case, \(L^{\mathrm{W}}\) and \(H^{\mathrm{W}}\) are topological invariants based only on the magnetic field and the domain (Prior and Yeates, 2021).

In this study, we will instead consider finite \(S_{\zeta}\) patches corresponding to individual SHARPs, rather than full planes or spheres. Moreover, we will compute only the photospheric contributions from SHARP magnetograms to the integrals (7) and (8). Specifically, when we refer to winding or helicity, we mean their densities over finite patches \(S_{\zeta _{0}}\) of the photosphere \(\zeta =\zeta _{0}\):

$$ L^{\mathrm{W}}(\zeta _{0}) = \int _{S_{\zeta _{0}}}\left (\int _{S_{ \zeta _{0}}'}\frac{\mathrm{d}\mathcal{L}}{\mathrm{d}\zeta}(\boldsymbol {x}, \boldsymbol {x}') \ {\mathrm {d}} ^{2}{\boldsymbol {x}'}\right ) \ {\mathrm {d}} ^{2}{ \boldsymbol {x}} = \int _{S_{\zeta _{0}}}\mathcal{L}^{\mathrm{W}}(\boldsymbol {x}; \zeta _{0}) \ {\mathrm {d}} ^{2}{\boldsymbol {x}}, $$
(10)

and

$$ H^{\mathrm{W}}(\zeta _{0}) = \int _{S_{\zeta _{0}}}\left (\int _{S_{ \zeta _{0}}'}\frac{\mathrm{d}\mathcal{L}}{\mathrm{d}\zeta}(\boldsymbol {x}, \boldsymbol {x}')B_{\zeta}(\boldsymbol {x})B_{\zeta}(\boldsymbol {x}')\mathrm{d}^{2}\boldsymbol {x}' \right )\mathrm{d}^{2}\boldsymbol {x} = \int _{S_{\zeta _{0}}}\mathcal{H}^{ \mathrm{W}} (\boldsymbol {x};\zeta _{0})\mathrm{d}^{2}\boldsymbol {x}\,. $$
(11)

The inner integrals \(\mathcal{L}^{\mathrm{W}}(\boldsymbol {x};\zeta _{0})\) and \(\mathcal{H}^{\mathrm{W}}(\boldsymbol {x};\zeta _{0})\) are spatial distributions which serve as finer-grained measures, later used in Section 4.1. Since our objective is to investigate the effect of curvature on helicity and winding, we outline two reasons for choosing finite surface densities instead of full volume integrals:

  1. i)

    Magnetograms are available only as finite patches on the photosphere \(\zeta =\zeta _{0}\), and it is standard to perform computations of helicity and winding on finite domains (e.g. Pariat et al., 2006; Liu and Schuck, 2012; MacTaggart et al., 2021). We did not want to prejudice the results by assuming particular boundary conditions or field extrapolations. The winding-based definition of helicity allows meaningful and consistent comparisons between two geometries for finite domain and it leaves the curvature factor as the main difference, although it may not correspond exactly to the usual relative helicity.

  2. ii)

    Winding helicity (or winding) density has a very similar form as that for helicity (or winding) flux through the photosphere, except that the latter also involves plasma velocities (e.g. Pariat, Démoulin, and Berger, 2005; Liu and Schuck, 2013; MacTaggart and Prior, 2021). More uncertainties, however, would be introduced from computing the latter from velocity inversions (e.g. Schuck, 2008; Yang, Zhang, and Büchner, 2009), which we would like to avoid. We use the comparisons made here between the Cartesian and spherical helicity (or winding) calculations as an indicator of the effect of ignoring spherical geometry in helicity (or winding) flux calculations.

3 SHARP Magnetograms in Cylindrical Equal-Area (CEA) Projection

SHARP magnetograms for coronal magnetic fields are available in two projected coordinates: CCD image coordinates (hmi.sharp_720s) and recentered cylindrical equal-area (CEA) projection coordinates (hmi.sharp_cea_720s), as illustrated in Figure 2 for SHARP 4920. The commonly used standard CEA projection maps a point with spherical coordinates \((\lambda ,\phi )\) to CEA coordinates \((x^{*},y^{*})\) as follows (Calabretta and Greisen, 2002):

$$\begin{aligned} x^{*} = \phi , \end{aligned}$$
(12)
$$\begin{aligned} y^{*} = \sin \lambda , \end{aligned}$$
(13)

where \(\lambda =\pi /2-\theta \) is the latitude. The CEA projection allows magnetic flux to be computed conveniently from magnetograms, since areas are preserved in the projection, i.e. equal-area. It is, however, not angle-preserving, and that could lead to potentially significant errors in helicity and winding computations, which are based on angular measures. While distortions are inevitable due to the curvature, they can be largely reduced by choosing the projection centre appropriately at or close to the region of interest, as in CEA-projected SHARP magnetograms (hereafter “SHARP magnetograms”). The recentered projection is given by (20) and (21) in the Appendix, with a self-contained derivation from the standard version (12) and (13) (Calabretta and Greisen, 2002; Sun, 2022).

Figure 2
figure 2

SHARP 4920 on 20 December 2014 at 00:24:00 is shown in CCD coordinates in the AIA 171Å EUV channel (upper left, white box) and in the full-disc radial magnetogram (upper right, white box), as well as in the recentered CEA magnetogram (bottom).

From Bobra et al. (2014) and Hoeksema et al. (2014), magnetic-field components in SHARP magnetograms are provided in the local spherical basis \(( \hat{\boldsymbol {e}} _{r}, \hat{\boldsymbol {e}} _{\theta}, \hat{\boldsymbol {e}} _{\phi})\), whereas the numerical grid is CEA-projected, both converted from CCD coordinates. Here, \(\hat{\boldsymbol {e}} _{r}\) is normal to the photosphere, \(\hat{\boldsymbol {e}} _{\theta}\) (or \(\hat{\boldsymbol {e}} _{\phi}\)) points southward (or westward) in the direction of solar rotation. In most observational studies that we are aware of, helicity and winding for SHARP and ARs are computed using Cartesian Equations (2) and (3), approximating both (i) the CEA grid and (ii) the spherical field components as Cartesian. In particular, \(( \hat{\boldsymbol {e}} _{\theta}, \hat{\boldsymbol {e}} _{\phi})\) is treated as \(( \hat{\boldsymbol {e}} _{y^{*}}, - \hat{\boldsymbol {e}} _{x^{*}})\), where the inherent CEA basis vectors \(\hat{\boldsymbol {e}} _{x^{*}}\) and \(\hat{\boldsymbol {e}} _{y^{*}}\) point along lines of constant \(x^{*}\) or \(y^{*}\). Take SHARP 4920 in Figure 2 as an example; we computed such misalignment between the two bases according to Equation (9) in Sun (2022), shown in Figure 3. One can see significant discrepancies that are greater than \(10^{\circ}\) towards patch corners.

Figure 3
figure 3

Angular deviation between the spherical basis \(( \hat{\boldsymbol {e}} _{\theta}, \hat{\boldsymbol {e}} _{\phi})\) used for field components and the CEA basis \(( \hat{\boldsymbol {e}} _{x^{*}}, \hat{\boldsymbol {e}} _{y^{*}})\) for the underlying grid, both for SHARP 4920 in Figure 2. The CEA-origin coincides with the patch/projection centre \((\lambda _{\mathrm{c}},\phi _{\mathrm{c}})=(-15.2^{\circ},256.1^{ \circ})\). Parallels (blue) and meridians (red) with step-sizes \(7.5^{\circ}\) and \(10^{\circ}\), respectively, are also shown.

It remains challenging to quantify the errors involved in this Cartesian approach, even if (ii) partially accounts for the surface curvature. After Xiao, Prior, and Yeates (2023) proposed the fully spherical expressions for helicity and winding reviewed in Section 2, it is thus natural to examine the extent to which Cartesian approximations fail to be accurate for SHARP magnetograms.

4 Results

In this section, we compute and compare densities of winding-based helicity \(H^{\mathrm{W}}(\zeta _{0})\) and winding \(L^{\mathrm{W}}(\zeta _{0})\) for a selection of SHARP magnetograms from Solar Cycle 24, in both Cartesian and spherical coordinates. Key information is summarised in Table 1. Note that, to implement the spherical approach, the numerical grid of a given SHARP magnetogram needs to first be converted to spherical coordinates using the relevant recentered CEA projection (20) and (21).

Table 1 Summary of Cartesian/CEA and spherical approaches of helicity and winding densities computations.

The YY.MM.DD format is used for dates and HH.MM for times. We adopt the CGS system of units, so magnetic field strengths are in units of Gauss (G), flux in maxwell (Mx), helicity density in \(\textrm{G}^{2}\cdot \textrm{cm}^{3} = \textrm{Mx}^{2}/\textrm{cm}\) from Equation (11), and winding density in \(\textrm{cm}^{3}\) from Equation (10). SHARP sizes are measured in either CEA-projected degrees \(x^{*}\) (longitudes) and \(y^{*}\) (latitudes) or photospheric areas in units of millionths of a solar hemisphere (mH).

From Bobra et al. (2014), each CEA pixel has a constant \(x^{*}\)-dimension of \(\Delta x^{*} = 0.03^{\circ}\) in heliographic degrees, so the \(x^{*}\)-coordinate of the \(n\)th pixel is given by \(x^{*}_{n}=n\Delta x^{*}\) where \(n\) is an integer and \(n=0\) corresponds to the patch/projection centre. In contrast, \(y^{*}\) are measured in constant steps of sines, which implies the \(n\)th pixel’s \(y^{*}\)-dimension, denoted by \(\Delta y^{*}(y^{*}_{n})\), is a non-linear function of its \(y^{*}\)-coordinate \(y^{*}_{n}\):

$$ \sin {[}\Delta y^{*}(y_{n}^{*}){]} - \sin {[}\Delta y^{*}(y_{n-1}^{*}){]} = 0.03^{\circ}\times \frac{\pi}{180^{\circ}} \,, $$
(14)

where \(\Delta y^{*}(y_{0}^{*})=0.03^{\circ}\). This recursively gives \(y^{*}_{n}= y^{*}_{n\pm 1}+\Delta y^{*}(y_{n\pm 1})\) with + (or −) for \(n>0\) (or \(n<0\)). Moreover, each CEA pixel has an area of \(1.3\times 10^{15} \ \mathrm{cm}^{2}\), used in comparisons between Cartesian and spherical results.

4.1 Spatial Distributions of Errors

We first compute spatial distributions of local helicity \(\mathcal{H}^{\mathrm{W}}(\boldsymbol {x};\zeta _{0})\) from Equation (11) and winding \(\mathcal{L}^{\mathrm{W}}(\boldsymbol {x};\zeta _{0})\) from Equation (10) in both Cartesian and spherical coordinates. Note that the surface-integrated helicity and winding densities, \(H^{\mathrm{W}}(\zeta _{0})\) and \(L^{\mathrm{W}}(\zeta _{0})\), can be recovered from integrating the local quantities over the patch on \(\zeta =\zeta _{0}\). To compare the results, we use both the absolute errors \(P_{\mathrm{car}} - P_{\mathrm{sph}}\) (i.e. the difference between Cartesian approximation and spherical value) and relative errors \((P_{\mathrm{car}} - P_{\mathrm{sph}})/P_{\mathrm{sph}}\), where \(P\) denotes (local) helicity or winding and subscript denotes the method used. As examples, we choose snapshots of two SHARP, 3926 (medium-sized, relatively quiet) and 4920 (large-sized, very active and flaring); see Table 2 for details.

Table 2 SHARP chosen for (field line) helicity and winding computations in Figures 4 and 5, where “12242+” stands for 12235, 12237, 12238, 12242.

Results are shown in Figure 4 and key observations are summarised as follows:

  1. i)

    Absolute errors are greatest near regions with large actual values that are typically associated with strong fields. In contrast, relative errors generally do not exhibit such behaviour – most large values are physically insignificant caused by near-zero denominators.

  2. ii)

    Errors in helicity are more localised, likely due to sharp drops in field strengths outside ARs, but errors in winding are more disperse, probably because winding is not flux-weighted.

  3. iii)

    Compared to the actual values, the smaller, quieter SHARP 3926 has maximum absolute errors an order of magnitude (OM) lower, whereas for the larger, more active SHARP 4920 they are of the same OM. This confirms that the patch size and/or total flux are indeed contributing factors to differences between the two methods, as expected from Section 2.

Figure 4
figure 4

Spatial distributions of absolute and relative errors for local helicity \(\mathcal{H}^{\mathrm{W}}(\boldsymbol {x};\zeta _{0})\) and winding \(\mathcal{L}^{\mathrm{W}}(\boldsymbol {x};\zeta _{0})\) for (a) SHARP 3926 on 1 April 2014 at 00:00:00, and (b) SHARP 4920 on 20 December 2014 at 00:24:00. For reference, (radial) magnetograms are shown for both SHARP, top left for 3926 and top right for 4920. Contours of constant field strengths are superimposed on all plots, with thresholds \(\pm \,450 \mathrm{G}\) for 3926 and \(\pm \,550 \mathrm{G}\) for 4920.

4.2 Time Series of Errors

Errors in the Cartesian approximation for one particular snapshot might be caused by observational noise, so it is important to test their robustness for certain periods. Here, we compute time series for both absolute and relative errors (defined in Section 4.1) of the surface-integrated helicity \(H^{\mathrm{W}}(\zeta _{0})\) from Equation (11) and winding densities \(L^{\mathrm{W}}(\zeta _{0})\) from Equation (10) in both spherical and Cartesian coordinates. For consistency, the same SHARP 3926 and 4920 are used with relevant temporal information in Table 3.

Table 3 Temporal information of SHARP chosen for helicity and winding computations in Figure 5.

From results plotted in Figure 5, both series exhibit persistent errors of comparable OM to the actual values. Excluding non-physically large values, relative errors for 3926 are moderate – \(0\,\text{--}\,5\%\) for helicity and \(0\,\text{--}\,20\%\) for winding. They are more significant for 4920 – around \(15\%\) for helicity and \(25\%\) for winding. Note that the time series for helicity show smoother variations than those for winding, partly because, unlike helicity, winding is not flux-weighted and tend to be dominated by the more varying field components near the polarity inversion line and on the edge of the large flux patches (Prior and MacTaggart, 2020).

Figure 5
figure 5

Time series of spherical helicity \(H^{\mathrm{W}}(r_{0})\) and winding \(L^{\mathrm{W}}(r_{0})\) (both red curves), and corresponding absolute and relative errors (blue and black curves, respectively), for SHARP (a). 3926 and (b). 4920. Note that the absolute errors are suitably scaled both in (a) by a factor of 100 and in (b) by a factor of −1.

4.3 Correlation Analysis Between Errors and Patch Indicators

The case studies in Sections 4.1 and 4.2 coincide with the theoretical prediction in Section 2 that errors arising from the Cartesian approximation of both helicity and winding are greater for larger patches or those with more net magnetic flux. In this subsection, we numerically test such correlations for a larger sample of SHARP from 2014 (solar maximum) and 2017 (towards solar minimum), listed in Table 4. Indicators related to patch sizes include de-projected patch area (keyword AREA) and number of CEA-projected pixels. The unsigned magnetic flux (keyword USFLUX) is used.

Table 4 The list of SHARP for correlation analysis in Figure 6. On each date at midnight, the SHARP with the smallest number and no blank pixels is chosen.

Results are shown in scatter plots in Figure 6. While there is an absence of a clear correlation for relative errors, absolute errors are strongly correlated with all these indicators. It demonstrates again the necessity to perform helicity and winding computations in the native spherical coordinates for large SHARP (often containing multiple ARs with localised strong magnetic fields). Moreover, we observe that the best-fits for the size dependence (first two columns) have gradients of approximately 2. This could partly be explained from integrating the second term in Equation (6) in Section 2 to obtain errors of leading order \(O(\xi ^{2})\) as the first term would be the Cartesian value.

Figure 6
figure 6

Log-log scatter plots of unsigned absolute and relative errors in helicity and winding against potential indicators for a selection of SHARP from 2014 and 2017 (including SHARP 3926 and 4920 used in Sections 4.1 and 4.2) listed in Table 4. Best-fit lines are shown with respective Pearson correlation coefficients or \(r\)-values. Colours are used to indicate the actual signs of errors, red for positive and black for negative.

5 Conclusion & Discussions

Magnetic helicity and winding are of increasing importance in modelling magnetic fields in ARs, and thus predicting extreme solar events such as flares and CMEs. It is necessary to have an unambiguous, accurate, and efficient method for computing both quantities in the native spherical coordinates. The geometrically motivated, winding-based definition of helicity proposed in Xiao, Prior, and Yeates (2023) is a promising candidate. It is independent of vector potentials with a simple and closed-form expression based only on the observed magnetic fields, allowing direct and meaningful comparisons for magnetic structures with different boundary conditions.

In this work, by performing computations in both Cartesian and spherical coordinates using CEA-projected SHARP magnetograms, we quantitatively investigated the extent to which spherical curvature manifests in helicity and winding of SHARP. We found persistent and sometimes significant errors of both quantities if they were calculated in the approximated, Cartesian/CEA approach instead of the exact, spherical version. Also, we found that absolute errors of both quantities correlate strongly with patch sizes and total unsigned magnetic flux, which confirms the theoretical predictions numerically. Since the spherical approach is computationally as efficient as the Cartesian one, it is apparent that spherical expressions should be preferred in future uses.

As mentioned in Section 2, we expect errors of similar magnitudes in helicity and winding flux computations as they share almost identical forms as helicity and winding densities discussed in this work. Velocity inversions, however, are needed in fluxes, which would potentially involve more uncertainties, as they require more observational data such as Doppler spectrograms in addition to vector magnetograms. A fully spherical formalism for velocity inversions and the incorporation into flux computations are not yet available, which could be a future direction for generalisation. Additionally, since the photosphere is not perfectly spherical or not even clearly defined, modifications could be introduced to the definitions of spherical helicity and winding in Xiao, Prior, and Yeates (2023) for more accuracy.