healpix_analyse.powerspectra#

Attributes#

Functions#

powerspectra(cell_ids, level, data[, ltf, ellipsoid, ...])

Compute the isotropic 1D power spectrum of a 2D HEALPix field.

Module Contents#

healpix_analyse.powerspectra.ArrayLike#
healpix_analyse.powerspectra.powerspectra(cell_ids, level, data, ltf=None, ellipsoid: str = 'sphere', method: str = 'fft', indexing_scheme: str = '2D_array', dx=1.0, cross=None, plot_2D_fft=False)[source]#

Compute the isotropic 1D power spectrum of a 2D HEALPix field.

Parameters:
  • data (ndarray (ny, nx)) – Input 2D field.

  • dx (float) – Pixel size in the same spatial unit as desired frequency inverse. If dx is in meters, returned frequencies are in m^-1 (cycles per meter).

Returns:

  • f_centers (ndarray) – Array of radial spatial frequencies (cycles per unit length), e.g., m^-1 if dx is in meters.

  • Pk (ndarray) – Azimuthally averaged power spectrum over radial frequency bins (arbitrary units unless you add a normalization).