dedalus.libraries.dedalus_sphere.sphere
Module Contents
- dtype = 'longdouble'
- quadrature(Lmax, dtype=dtype)
- Generates the Gauss quadrature grid and weights for spherical harmonics transform.
Returns cos_theta, weights
Will integrate polynomials on (-1,+1) exactly up to degree = 2*Lmax+1.
- Parameters:
Lmax (int >=0; spherical-harmonic degree.)
- spin2Jacobi(Lmax, m, s, ds=None, dm=None)
- harmonics(Lmax, m, s, cos_theta, **kwargs)
Gives spin-wieghted spherical harmonic functions on the Gauss quaduature grid. Returns an array with
- shape = ( Lmax - Lmin(m,s) + 1, len(z) )
or (Lmax - Lmin(m,s) + 1,) if z is a single point.
- Parameters:
Lmax (int >=0; spherical-harmonic degree.)
m,s (int) – spherical harmonic parameters.
cos_theta (np.ndarray or float.)
dtype (output dtype. internal dtype = ‘longdouble’.)
- operator(name, dtype=dtype)
Interface to base ShereOperator class.
- class SphereOperator(name, radius=1, dtype=dtype)
- property radius
- property dtype
- static identity(dtype=dtype)
- static parity(dtype=dtype)
- static L(dtype=dtype)
- static M(dtype=dtype)
- static S(dtype=dtype)
- class SphereCodomain(dL=0, dm=0, ds=0, pi=0)
Base class for Jacobi codomain.
codomain = JacobiCodomain(dn,da,db,pi)
n’, a’, b’ = codomain(n,a,b)
- if pi == 0:
n’, a’, b’ = n+dn, a+da, b+db
- if pi == 1:
n’, a’, b’ = n+dn, b+da, a+db
pi_0 + pi_1 = pi_0 XOR pi_1
- Variables:
__arrow (stores dn,da,db,pi.)
- self[0:3]: returns dn,da,db,pi respectively.
- str(self): displays codomain mapping.
- self + other: combines codomains.
- self(n,a,b): evaluates current codomain.
- -self: inverse codomain.
- n*self: iterated codomain addition.
- self == other: determines equivalent codomains (a,b,pi).
- self | other: determines codomain compatiblity and returns larger-n space.