ocean_stokes
Reads a land-sea mask and converts to a series of spherical harmonics
- netCDF4 land-sea mask files from [61]
updated 1.0, 0.5 and 0.25 degree masks from ORNL as part of ISLSCP
Calling Sequence
from gravity_toolkit.ocean_stokes import ocean_stokes
ocean_Ylms = ocean_stokes(LANDMASK, LMAX, MMAX=MMAX, LOVE=(hl,kl,ll))
- gravity_toolkit.ocean_stokes(LANDMASK, LMAX, MMAX=None, LOVE=None, VARNAME='LSMASK', SIMPLIFY=False)[source]
Reads a land-sea mask and converts to a series of spherical harmonics for ocean areas
- Parameters:
- LANDMASK: str
netCDF4 land-sea mask file
- LMAX: int
maximum spherical harmonic degree
- MMAX: int or NoneType, default None
maximum spherical harmonic order of the output harmonics
- LOVE: tuple
Load Love numbers up to degree LMAX (
hl,kl,ll)- VARNAME: str, default ‘LSMASK’
variable name for mask in netCDF4 file
- SIMPLIFY: bool, default False
simplify land mask by removing isolated points
- Returns:
- clm: np.ndarray
cosine spherical harmonic coefficients
- slm: np.ndarray
sine spherical harmonic coefficients
- l: np.ndarray
spherical harmonic degree to LMAX
- m: np.ndarray
spherical harmonic order to MMAX