Skip to main content

Library for computing spin-weighted spheroidal harmonics

Project description

GitHub release (with filter) Test Status PyPI - Version Conda Version Documentation Status GitHub License

Spheroidal

spheroidal is a python library for computing spin weighted spheroidal harmonics along with their eigenvalues and derivatives. It supports both integer and half integer spin weights. The library provides implementations of the spherical expansion method described in (Hughes, 2000) and the continued fraction method from (Leaver, 1985). Also included is code for computing spin weighted spherical harmonics and spherical-spheroidal mixing coefficients. See the documentation for more information.

Installation

Install using Anaconda

   conda install -c conda-forge spheroidal

or using pip

   pip install spheroidal

Basic Usage

   import spheroidal
   from math import pi

   # Compute the spin weighted spheroidal eigenvalue with s = -2, l = 2, m = 2, gamma = 1.5
   spheroidal.eigenvalue(-2, 2, 2, 1.5)
   # -5.5776273646788255

   # Compute the corresponding spin weighted spheroidal harmonic
   S = spheroidal.harmonic(-2, 2, 2, 1.5)

   # Evaluate at theta = pi/2, phi = 0
   S(pi/2, 0)
   # (0.06692950919170575+0j)

   # Compute the derivative wrt theta at the same point
   spheroidal.harmonic_deriv(-2, 2, 2, 1.5)(pi/2, 0)
   # (-0.20852146386265577+0j)

Authors

  • Seyong Park
  • Zach Nasipak

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spheroidal-0.1.1.tar.gz (11.9 kB view hashes)

Uploaded Source

Built Distribution

spheroidal-0.1.1-py3-none-any.whl (12.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page