torch_harmonics.filter_basis.FourierBesselFilterBasis#
- class torch_harmonics.filter_basis.FourierBesselFilterBasis(kernel_shape)[source]#
Bases:
FilterBasisFourier-Bessel (Disk Harmonic) filter basis on the unit disk.
Basis functions are the Dirichlet Laplacian eigenfunctions on the disk:
\[\psi_{m,n,c}(r, \phi) = J_m(\alpha_{m,n} \cdot r/r_cutoff) \cdot \{cos(m\phi), sin(m\phi)\}\]where \(\alpha_{m,n}\) is the n-th positive zero of \(J_m\), so \(\psi = 0\) on the boundary \(r = r_{cutoff}\).
The basis is ordered by eigenvalue \(\lambda = \alpha_{m,n}^2 / r_{cutoff}^2\), from lowest to highest. For m > 0 each (m, n) pair yields two basis functions (cosine and sine), while m = 0 yields one (cosine only, i.e., purely radial).
- kernel_shapeint or tuple of two ints (n_radial, n_angular)
If int: same value for both (\(n_{radial}\), \(n_{angular}\)) = (\(kernel_{shape}\), \(kernel_{shape}\)). If tuple of length 2: (\(n_{radial}\), \(n_{angular}\)). \(n_{radial}\) controls the radial degree (number of zeros of \(J_0\) used to set \(\alpha_{max}\)). n_angular is the max azimuthal order \(m\).
- compute_l2_norms(
- r_cutoff=1.0,
- nr=50,
- nphi=200,
Analytic L2 norms of the Fourier-Bessel basis on a disk of radius r_cutoff.
nr and nphi are accepted for signature compatibility with the base class.
Radial: integral_0^R J_m(alpha r/R)^2 r dr = R^2 * J_{m+1}(alpha)^2 / 2. Angular: integral_0^{2pi} cos^2(m phi) dphi = 2pi (m=0) or pi (m>0).