Spherical harmonics and spherical Fourier neural operators
Before this lesson: lesson 08 (the FFT, spectral derivatives, aliasing and the Fourier neural operator). Helpful: linear algebra lesson 19 (equivariance) and calculus lesson 11 (Gauss–Hermite quadrature, a close relative of the Gauss–Legendre rule used here). Time: about 100 minutes, plus the notebook.
Why this matters #
- Weather and climate models are on the sphere. ERA5, the standard reanalysis used to train ML weather models, has points (a grid). Every row has 1440 points. The east–west spacing is about 28 km at the equator and about 120 m on the row next to the pole. Methods that treat the grid as a flat image waste points near the poles and see a false seam.
- Spectral models. ECMWF's IFS computes derivatives, diffusion and its semi-implicit time step in spherical-harmonic space. Its high-resolution forecast uses the truncation TCo1279, about 9 km grid spacing (ECMWF documentation, as of 2026). The dynamical core of the hybrid model NeuralGCM (Kochkov et al., 2024) is also spectral, at resolutions from 2.8° to 0.7°.
- ML weather and climate models. The SFNO (Bonev et al., 2023) replaced the flat 2D FFT of FourCastNet by the SHT. The paper reports stable autoregressive rollouts over a simulated year (1460 steps of 6 hours). SFNO is also the base of the ACE climate emulator (Watt-Meyer et al., 2023). Lesson 16 puts these models side by side.
- Geophysics and seismology. Global models of the mantle from seismic tomography (for example S40RTS, up to degree 40), Earth's gravity field (EGM2008, to degree 2159) and the main geomagnetic field (IGRF, to degree 13) are all published as spherical-harmonic coefficients. The free oscillations of the Earth after a large earthquake are labelled by their degree .
- Equivariant networks. Real spherical harmonics are the features of the E(3)-equivariant networks of lesson 10.
1. Predict first #
2. The picture #
The grid problem #
Use the colatitude ( at the North Pole, on the equator) and the longitude . The latitude is . The area element of the unit sphere is : a band near a pole has little area because is small there.
A regular latitude–longitude grid puts the same number of points on every row. So the points crowd together near the poles.
Move the latitude slider and compare the two bars: the share of the grid points (orange) with |latitude| ≥ and the share of the area (blue) there, which is . Notice that at the polar caps (yellow) hold 34 % of the points of a 1° grid but only 13 % of the area. Drag the sphere to look at a pole: the rows become tiny circles.
So a lat–lon field is not a nice periodic image. Latitude is not periodic at all: the row at the North Pole is not a neighbour of the row at the South Pole. The right basis must be built for the sphere.
From the circle to the sphere #
On one circle of latitude, a field is a periodic function of . So it is a Fourier series in , exactly as in lesson 08: modes and with an integer order . The coefficient of each mode is a function of the colatitude. For each we expand this function in a second family, the associated Legendre functions with The product of the two is a spherical harmonic:
The degree is the total wavenumber. The order , with , is the east–west wavenumber. Each is a standing wave on the sphere. Its zero set (the nodal lines) has great circles through the poles and circles of latitude.
The first few, up to constant factors:
- : a constant (the global mean);
- : warm in the north, cold in the south;
- and : an east–west tilt;
- ; .
Move the degree and the order . Orange is positive, blue is negative, and the dark lines are the nodal lines. Count them: great circles through the poles and circles of latitude. Try "zonal" (: bands of latitude), "sectoral" (: only meridians) and "tesseral" (a checkerboard). Switch to the map view to see the same harmonic on a longitude–latitude rectangle.
Why the poles cause no trouble. contains the factor . So a mode with a large order is almost zero near the poles. Fine east–west waves cannot live on the tiny circles near a pole, and the basis does not need them there. A degree has a wavelength of about on a sphere of radius : on Earth ( km), gives about 63 km.
How many nodal lines does have, and of which kind?
The number of meridian great circles is , and the number of circles of latitude is , so there are nodal lines in total. The number counts the harmonics of degree 4, not the nodal lines of one of them.
The Laplacian on the unit sphere maps to which multiple of itself (for every from to )?
Theorem 1 below gives , the same for all seven harmonics of degree 3. The value is the eigenvalue of on a circle; on the sphere the extra comes from the curvature of the latitude direction.
3. Definitions and main results #
3.1 The Laplacian on the sphere #
Write (so at the North Pole and at the South Pole). On the unit sphere the Laplace–Beltrami operator (the Laplacian of the sphere) is
For the second form use and . The area element is (up to the sign of ).
3.2 Associated Legendre functions and spherical harmonics #
Definition. For integers , with the Legendre polynomial of degree , the normalised associated Legendre function is
It solves the associated Legendre equation
and is bounded at . The real spherical harmonics are the products of section 2. They are orthonormal: . The factor for is there because , while .
3.3 Theorem 1: spherical harmonics are eigenfunctions of the Laplacian #
Why this is true (intuition). In longitude, is an eigenfunction of with eigenvalue , as on a circle. In latitude, the associated Legendre equation is exactly the condition that the remaining part gives .
Proof.
- Take and write with (the case is the same). Then .
- With the form of the operator, .
- solves the associated Legendre equation, so the bracket equals . A constant factor does not change this, so the normalisation plays no role.
- Hence . On a sphere of radius , each of the two derivatives carries a factor , which gives .
Consequences.
- The eigenvalue depends on only. All harmonics of degree share it. This is the rotation symmetry of the sphere at work (section 3.8).
- Spectral calculus. If , then has the coefficients .
- Poisson's equation is a division. The streamfunction of a vorticity field solves , so for . At the eigenvalue is 0: the global mean of must be zero, and the mean of is free (set it to 0).
- Diffusion is a damping per degree. multiplies each coefficient by . Spectral models apply (hyper)diffusion this way.
- The longitude derivative is also diagonal: it maps the pair to . The latitude derivative is not diagonal: maps degree to a combination of degrees and .
3.4 Triangular truncation #
A field is band-limited to if it has no harmonics of degree above . The triangular truncation keeps all and : that is real coefficients. "T79" or "T639" in the weather literature means this truncation.
Triangular truncation is the natural choice because its resolution is the same everywhere on the globe. The addition theorem says at every point. So no place, and no direction, is preferred. The set of all fields is also mapped to itself by every rotation (section 3.8).
Move the band limit and watch the map and the power spectrum (one dot per degree). The orange dots are kept, the grey ones are dropped, and the dashed line is . Notice that the small storm (the narrow bump) needs about to appear with its full height. Switch to "sharp front": its spectrum falls slowly, and the truncated field shows ripples along the front (the Gibbs effect of lesson 08). Use "error" to see where the truncated field differs from the original.
3.5 Computing : the stable recursion #
The closed formula of section 3.2 is useless for large . The factorials overflow (171! is larger than the largest float64), and high derivatives of polynomials lose all digits to cancellation. Use a recursion for each order , directly on the normalised functions:
- Start: .
- Diagonal: .
- First step off the diagonal: .
- Three-term recursion in , for :
The numbers and are fixed; they are not the coefficients of a field. All values stay of moderate size, so nothing overflows. The values agree with SciPy (after the phase and the normalisation are matched) to about for . This is the recursion of torch-harmonics and, in an equivalent form, of SHTns.
Very high degrees
For in the thousands, underflows near the poles. At the polar node of a 1280-latitude Gauss grid, , and . These values are negligible: the harmonic is zero there for all practical purposes. Libraries skip them, or use scaled (extended-exponent) arithmetic.
3.6 Gauss–Legendre quadrature #
The SHT must compute integrals over latitude, , from samples. A quadrature rule with nodes and weights approximates . With equispaced nodes and well-chosen weights you can integrate every polynomial of degree exactly. If you may also choose the nodes, you can do twice as well.
Definition. The Gauss–Legendre rule with nodes uses the roots of the Legendre polynomial as nodes, and the weights , where is the Lagrange polynomial that is 1 at and 0 at the other nodes.
Proof
- Let have degree . Divide by : , with and .
- is orthogonal to every polynomial of lower degree, so . Hence .
- At the nodes , so . Hence .
- has degree , so it equals its Lagrange interpolant . Integrate: .
- Steps 2–4 give . For degree , take : its integral is positive, but the rule gives 0.
Choose the number of nodes and the degree of the test integrand (blue curve). The orange dots and bars are the nodes and the weights. The lower chart shows the relative error for every degree: it stays at rounding level inside the aqua band () and jumps up right after it. The yellow dot is your .
A latitude integrand is a polynomial of degree 9. What is the smallest number of Gauss–Legendre nodes that integrates it exactly?
nodes are exact up to degree . We need , so . Four nodes are exact only up to degree 7. Ten nodes would be the count for equispaced (interpolatory) rules.
3.7 Theorem 2: the SHT on a Gauss grid is exact #
Grid. Gauss–Legendre nodes (colatitudes ) with weights , and equispaced longitudes . This is a Gaussian grid.
Analysis (grid → coefficients). For each order :
- FFT along each row: .
- Legendre step, one matrix–vector product per : .
- Real coefficients: and, for , , .
Synthesis (coefficients → grid): set and ; then , and (an inverse real FFT).
Proof of Theorem 2
- The continuous formula. By orthonormality . Do the longitude integral first. With and , one checks and (use and ).
- Longitude. On a row, is a trigonometric polynomial with orders . The discrete sum is 1 if is a multiple of and 0 otherwise (lesson 08, Theorem 1). Since , only survives: step 1 gives the exact .
- Latitude. is a combination of with . Each is times a polynomial of degree . So the product of two functions with the same is times a polynomial of degree : a polynomial of degree . (For odd one alone is not a polynomial; the product is.)
- Quadrature. Gauss nodes are exact up to degree . So step 2 equals the integral of proof step 1. The synthesis is the exact evaluation of a finite sum, and the coefficients determine the field.
Two traps show that both bounds are sharp (we use them again in section 4):
- With nodes, the nodes are the roots of , and is zero at every grid point. The grid cannot see it.
- With , at every grid longitude. The mode is invisible.
Cost. The FFTs cost . The Legendre step costs about per order, so in total: it dominates for large . The symmetry saves a factor 2, and on GPUs the step is a batch of dense matrix products.
Products, dealiasing and other grids
The product of two fields has degrees up to , as in 1D (lesson 08). To get the coefficients of a product without aliasing, the integrands have degree up to . Then you need and : the quadratic grid, the spherical form of the 2/3 rule (Boyd, §18.12). The minimal grid of Theorem 2 is the linear grid. ECMWF's IFS uses an even finer cubic octahedral grid, which also has fewer points per row near the poles. An equiangular grid such as ERA5's has no Gauss nodes. Exact quadrature on it needs about twice as many latitudes (Driscoll and Healy, 1994).
3.8 Rotations, spherical convolution and the SFNO layer #
Rotations keep the degree. Let be a rotation and the rotated field. The rotated version of a degree- harmonic is again a combination of degree- harmonics. Reason: the Laplacian commutes with rotations (it is defined by the geometry of the sphere), so it maps the eigenspace of to itself. A rotation also keeps the inner product . Hence the vector of the degree- coefficients changes by an orthogonal matrix:
is the real Wigner-D matrix; lesson 10 studies it in detail. Two consequences:
- The power spectrum does not change under rotations. It is the standard diagnostic of small-scale energy. An ML forecast trained with the MSE often loses power at high : it is blurry.
- A rotation about the polar axis does not mix orders: it turns each pair by the angle . Any other rotation mixes all orders of the same degree.
Proof. On degree , is the matrix . Rotate first, then filter: . Filter first, then rotate: . A multiple of the identity commutes with every matrix, so the two are equal for every .
A diagonal factor that changes with is a diagonal matrix that is not a multiple of the identity. It does not commute with a that mixes the orders. Schur's lemma (lesson 10) says more: the only linear maps of the degree- space that commute with all rotations are multiples of the identity.
Compare the two lower maps ("A: rotate, then filter" and "B: filter, then rotate") while you move the tilt . With the factor the maps are identical and the difference is about . Switch to the factor (it smooths only in the east–west direction): now the maps differ. Then set and move only the spin : the difference drops to rounding level again, because a rotation about the polar axis does not mix orders.
Spherical convolution. On the circle, a convolution is a multiplication of Fourier coefficients (lesson 08). On the sphere, the convolution of a field with a kernel that is symmetric about the pole (a zonal kernel) multiplies the coefficients of degree by one number per degree. That number is proportional to the coefficient of the kernel at degree (Driscoll and Healy, 1994; SFNO paper, §4.1). So degree-wise filters are exactly the spherical convolutions.
The SFNO layer. With channels at each point of the sphere, one layer is
where are the SHT coefficients of the channels and is a learned matrix for each degree, with no dependence on . It is the FNO layer of lesson 08 with the FFT replaced by the SHT. acts on the channel index and on the order index, so they commute: the linear part is exactly rotation-equivariant (Theorem 3 for each channel pair). The pointwise skip and the activation are equivariant on the continuous sphere; on a discrete grid the activation creates high degrees that alias, so the full network is only approximately equivariant (SFNO paper, §4.2).
A spectral layer multiplies by learned weights that depend on both and . Is it equivariant under all rotations of the sphere?
A general rotation acts on degree by , which mixes all orders . A diagonal matrix commutes with all such only if it is a multiple of the identity. With the layer commutes with rotations about the polar axis (they only turn each pair ), but not with a tilt.
Answers to section 1. (1) No. Latitude is not periodic: a 2D FFT makes the North-Pole row a neighbour of the South-Pole row and creates a false seam. The rows near the poles are tiny circles with as many points as the equator, and the flat Fourier modes are not smooth at the poles. Use the FFT only in longitude, and associated Legendre functions with Gauss quadrature in latitude. (2) Gauss latitudes and longitudes (Theorem 2). For exact products, use latitudes and longitudes. (3) Yes. A factor that depends only on the degree commutes with every rotation (Theorem 3). A factor that depends on does not, except for rotations about the polar axis.
4. Worked example #
Take . Its highest degree is .
Step 1: the coefficients by hand. We need three harmonics:
- . So and .
- , so . Then and .
- (because ). So , and .
All other coefficients are 0.
Step 2: the grid. Theorem 2 needs and . The 3-node Gauss rule has nodes (that is and 0) and weights . Check its limit:
- degree 4: (exact);
- degree 6: , but .
Degree is all we need.
Step 3: analysis of . On each row, the mean over the 5 longitudes is : the term sums to zero over 5 equispaced points. Then
which equals . So . ✓
Step 4: analysis of . On each row, . (Only the half of survives; sums to 0 on 5 points.) Then
The sum is , which is . So and . ✓
Step 5: the Laplacian. Multiply each coefficient by : , , . Synthesis gives
You can check this with the operator of section 3.1. The inverse Laplacian gives back up to a constant: the part is lost.
Step 6: the two traps.
- : the nodes are the roots of , so is zero at every grid point. Also, the 2-node rule gives , not .
- : at all four longitudes. The orders and alias, and the part of a field is invisible.
How many real coefficients does a field in the truncation have, and how many does have?
keeps all harmonics of every degree : . That is 9 for and for . The count (6 and 3240) is the number of complex coefficients with that a real SHT stores.
5. In code #
The code checks the quadrature limit and computes the worked example with the recursion and the
SHT of Theorem 2. Only NumPy and SciPy's roots_legendre are used.
import numpy as np
from scipy.special import roots_legendre
# (a) Gauss-Legendre with K nodes is exact up to degree 2K - 1.
x, w = roots_legendre(3)
print(x, w) # [-0.7746 0. 0.7746] [0.5556 0.8889 0.5556]
print(w @ x**4, w @ x**6, 2 / 7) # 0.4 (= 2/5, exact) 0.24 0.2857
# (b) Normalised associated Legendre functions by the recursion (no (-1)^m phase).
def pbar_table(N, x):
s, P = np.sqrt(1 - x**2), np.zeros((N + 1, N + 1, x.size))
P[0, 0] = 1 / np.sqrt(4 * np.pi)
for m in range(1, N + 1):
P[m, m] = np.sqrt((2 * m + 1) / (2 * m)) * s * P[m - 1, m - 1]
for m in range(N):
P[m + 1, m] = np.sqrt(2 * m + 3) * x * P[m, m]
for l in range(m + 2, N + 1):
a = np.sqrt((4 * l * l - 1) / (l * l - m * m))
b = np.sqrt(((l - 1) ** 2 - m * m) * (2 * l + 1) / ((l * l - m * m) * (2 * l - 3)))
P[l, m] = a * x * P[l - 1, m] - b * P[l - 2, m]
return P
# (c) Analysis on the Gauss grid: rfft in longitude, quadrature in latitude.
def sht(f, N):
nlat, nlon = f.shape
x, w = roots_legendre(nlat)
P, F = pbar_table(N, x), np.fft.rfft(f, axis=1) / nlon
A = np.zeros((N + 1, 2 * N + 1)) # A[l, N + m] = a_l^m
for m in range(N + 1):
c = 2 * np.pi * (P[m:, m] * w) @ F[:, m]
if m == 0:
A[:, N] = c.real
else:
A[m:, N + m], A[m:, N - m] = np.sqrt(2) * c.real, -np.sqrt(2) * c.imag
return A
x, _ = roots_legendre(3)
th, ph = np.arccos(x)[:, None], 2 * np.pi * np.arange(5)[None, :] / 5
f = 1 + 3 * np.cos(th) + np.sin(th) ** 2 * np.cos(2 * ph)
A = sht(f, 2)
print(A[0, 2], A[1, 2], A[2, 4]) # 3.5449 6.1400 1.8306
print(np.sqrt(4 * np.pi), 2 * np.sqrt(3 * np.pi), 4 * np.sqrt(np.pi / 15)) # the same
print(np.abs(A).sum() - A[0, 2] - A[1, 2] - A[2, 4]) # all other coefficients: 4e-15
# (d) The Laplacian: multiply degree l by -l(l+1).
print(A[[0, 1, 2], [2, 2, 4]] * -np.array([0, 2, 6])) # [0. -12.2799 -10.9835]
In the notebook you also write the synthesis, check a round trip with random coefficients (error about ), solve the Poisson equation and test the rotation property of Theorem 3.
6. Where it shows up #
- Spectral dynamical cores. The IFS (ECMWF) and the core of NeuralGCM compute derivatives, diffusion and the semi-implicit solver in spectral space, and the nonlinear terms on a Gaussian grid (the "transform method"). NeuralGCM's core is written in JAX, so the learned physics is trained through it (lesson 03).
- ML weather and climate models. SFNO-based models (FourCastNet with SFNO, the ACE climate emulator) use the degree-wise filters of section 3.8. The open-source library torch-harmonics provides a differentiable SHT on GPUs. Spherical power spectra are a standard check of blurriness in lesson 16.
- Positional encodings on the globe. Spherical harmonics of the latitude and longitude of a point are used as location encodings for geospatial ML (Rußwurm et al., 2024).
- Seismology and geophysics. Global tomography models of seismic velocity in the mantle, gravity models of the geoid, and the geomagnetic reference field are spherical-harmonic expansions. A seismic "spheroidal mode" of the free oscillations of the Earth has the angular shape of a degree- harmonic.
- Equivariant networks. In lesson 10, the real harmonics of an edge direction are the features of E(3)-equivariant networks, and the matrices of section 3.8 appear again.
- Practice tools. torch-harmonics (PyTorch), SHTns (fast C library), pyshtools (geodesy and geophysics).
7. Common mistakes #
- Colatitude versus latitude. Gauss nodes are values of . Mixing the two flips or shifts the field.
- Wrong argument order in SciPy. The new function is
sph_harm_y(l, m, colatitude, longitude). The oldersph_harm(m, l, longitude, colatitude), still in old code, used the opposite order in both pairs. - Mixing conventions. Orthonormal, -normalised and Schmidt semi-normalised functions differ by factors, and the phase may be on or off. Match both before comparing.
- Too few latitudes, or Gauss weights on the wrong grid. Fewer than Gauss latitudes, or Gauss weights on an equiangular grid, silently drop modes (section 4).
- Dividing by at , or forgetting the radius. The constant mode is the null space of the Laplacian. On Earth the eigenvalue is .
- Spectra from storage. If you store complex for only, then : count each twice.
- Factorial formulas at high degree. Use the normalised recursion.
- Treating the lat–lon grid as a periodic image. A 2D FFT (as in FNO or AFNO) creates a seam between the poles and artefacts near them. This is what SFNO fixes.
- Weights that depend on . They break rotation equivariance (Theorem 3 and the quiz above).
8. Check yourself #
- What is the eigenvalue of for degree on the unit sphere, and on Earth
( km)?
Answer
on the unit sphere. On Earth . All seven harmonics of degree 3 share it. - A model uses the truncation T79. Give the minimal Gauss grid for an exact transform, and the
minimal grid for exact (dealiased) quadratic products.
Answer
Linear grid: and (160 in practice, for the FFT). Quadratic grid: and (often ). - On the unit sphere the vorticity is . Find the streamfunction with
.
Answer
has degree 2 only (it is a multiple of ), so divide by : , plus any constant. - Why does a weight that depends on break rotation equivariance, while does not?
Answer
A rotation acts on the degree- coefficients by the orthogonal matrix , which mixes the orders . The filter is the diagonal matrix . It commutes with every only if it is a multiple of the identity, that is, if (Schur's lemma, lesson 10). - Which step of the SHT dominates at large , and how does it scale?
Answer
The Legendre step: about coefficients times latitudes, so . The FFTs cost only . The parity symmetry halves the Legendre step, and GPUs run it as batched matrix products. - You compare the power spectra of an ML forecast and of the analysis at a lead time of 5
days, and the forecast has much less power for . What does this tell you?
Answer
The forecast is too smooth at scales shorter than about km. This is typical of models trained with the MSE: under uncertainty the MSE-optimal forecast is the conditional mean, which averages out small features. The rotation invariance of makes it a clean, orientation-free diagnostic.
What is the eigenvalue of the Laplacian for on a sphere of radius ?
(on the unit sphere ), the same for all orders .
How many real coefficients does the triangular truncation have?
, because degree has harmonics and .
Up to which degree is a -node Gauss–Legendre rule exact?
Up to degree (the nodes are the roots of ).
What are the two steps of the spherical harmonic transform on a Gauss grid?
An FFT along each circle of latitude, then for each order a Gauss–Legendre quadrature in latitude with the functions .
Which grid makes the SHT exact for a band limit ?
At least Gauss latitudes and equispaced longitudes.
Why compute with the three-term recursion instead of the closed formula?
The closed formula needs factorials that overflow (171! does not fit in float64) and high derivatives that lose digits; the normalised recursion keeps all values of moderate size.
Which spectral filters commute with all rotations of the sphere?
Those whose factor depends only on the degree : . A rotation mixes the orders within each degree.
How do you solve on the unit sphere with the SHT?
Divide each coefficient by for ; the mean of must be zero, and set .
What does the SFNO change compared with the FNO?
The FFT is replaced by the SHT, and the learned weight is a channel matrix per degree, independent of , so the linear part is rotation-equivariant.
9. Interview angle #
- "Why spherical harmonics and not a 2D FFT on the lat–lon grid?" Latitude is not periodic and the grid is singular at the poles. Spherical harmonics are the eigenfunctions of the Laplacian on the sphere, and the triangular truncation has the same resolution everywhere.
- "What does SFNO change compared with FNO?" The SHT replaces the flat FFT, and the weights depend on the degree only, so the linear part commutes with rotations. The paper reports stable rollouts over one simulated year (1460 steps of 6 hours).
- "How would you show that an ML forecast is blurry?" Compare the spherical power spectrum of the forecasts with that of the analysis (for example ERA5). Models trained with the MSE lose power at high , more at longer lead times.
- "Why is Poisson's equation easy on the sphere, and what is the catch?" Divide each coefficient by . The catch is : the constant is the null space, so the mean of the right-hand side must be zero.
- "How do you choose a grid for the truncation ?" Gauss latitudes and longitudes for linear terms; the quadratic grid ( latitudes and longitudes) to avoid aliasing in products; about twice the latitudes on an equiangular grid.
10. Practice #
The notebook for this lesson runs in Colab and in the browser. It has five exercises, each with a check cell and a folded solution:
- Build the Gauss–Legendre rule with the Golub–Welsch eigenvalue method and test its exactness up to degree .
- Compute the normalised associated Legendre functions with the recursion; compare with
scipy.special.lpmvand check orthonormality. - Write the forward and inverse SHT on a Gauss grid; reproduce the worked example and get a round-trip error near .
- Solve Poisson's equation on the sphere (vorticity to streamfunction) and handle the mode.
- Test numerically that a filter commutes with rotations and a filter does not.
11. Watch and read #
Reading
- Bonev et al., Spherical Fourier Neural Operators: Learning Stable Dynamics on the Sphere (ICML 2023): §3–4 for the SHT, spherical convolution and equivariance. arXiv 2306.03838
- Boyd, Chebyshev and Fourier Spectral Methods (2nd ed., free PDF), chapter 18: spherical harmonics, triangular truncation, Gaussian grids and dealiasing. PDF
- Schaeffer, Efficient spherical harmonic transforms aimed at pseudo-spectral numerical simulations (G-cubed, 2013; the SHTns paper): definitions, the recursion and the exactness argument. arXiv 1202.6522
- torch-harmonics notebooks (NVIDIA): the SHT, quadrature and a Poisson solver in PyTorch. GitHub
Runs in your browser with nothing to install. The notebook repeats the key demos and has exercises with checks; solutions are inside, folded.
No Google account needed: Python runs inside your browser. The first start downloads about 40 MB; your changes are saved in this browser only.