Skip to main content

SHTOOLS - Tools for working with spherical harmonics

Project description

![LOGO](misc/logo.png)

[![Join the chat at https://gitter.im/SHTOOLS/SHTOOLS](https://badges.gitter.im/SHTOOLS/SHTOOLS.svg)](https://gitter.im/SHTOOLS/SHTOOLS?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![DOI](https://zenodo.org/badge/doi/10.5281/zenodo.206114.svg)](http://dx.doi.org/10.5281/zenodo.206114)

SHTOOLS is a Fortran 95 / Python library that can be used to perform spherical harmonic transforms and reconstructions, rotations of data expressed in spherical harmonics, and multitaper spectral analyses on the sphere.

### FEATURES ###

  • A wide range of supported spherical harmonic functions:
    • real and complex,

    • different normalizations (Geodesy 4π, Schmidt semi-normalized, orthonormalized, unnormalized),

    • Condon-Shortley phase factor of (-1)<sup>m</sup>.

  • Selected applications and routines:
    • global spectral analysis, spherical harmonic rotations, Wigner 3j symbols,

    • localized multitaper spectral analyses, optimal window generation, spherical harmonic coupling matrices,

    • standard gravity and magnetic field calculations, computation of the geoid, finite-amplitude potential from topography.

  • Clean implementation of the spherical harmonic transforms: * Exact quadrature rules using either the sampling theorem of Driscoll and Healy (1994) where data are equally sampled (or spaced) in latitude and longitude, or Gauss-Legendre quadrature.

    • Accurate and fast to approximately degree 2800, corresponding to a spatial resolution higher than 4 arc minutes. Transforms and reconstructions take on the order of 1 second for bandwidths less than 600 and about 3 minutes for bandwidths close to 2800 on standard machines. The Fortran 95 routines are OpenMP compatible and OpenMP thread-safe.

### INSTALLATION ### #### Requirements #### Linux: `bash sudo apt-get install libblas-dev liblapack-dev g++ gfortran libfftw3-dev tcsh ` OSX: `bash brew install fftw --with-fortran `

#### Python Library #### `bash pip install pyshtools ` Or, to install a developer version, [download](https://github.com/SHTOOLS/SHTOOLS/zipball/master) or clone the SHTOOLS repository, enter the SHTOOLS folder and then execute one of the following commands: `bash pip install . # installs into the active python environment lib folder pip install -v -e . # installs into the SHTOOLS/pyshtools folder and links to the active python environment `

#### Fortran Library #### To install the Fortran 95 library, enter one of the following `bash make fortran make fortran-mp # Open-MP Fortran routines `

Or, with OSX, use the [brew](http://brew.sh/) package manager: `bash brew tap shtools/shtools brew install shtools ` To also install the OpenMP components, add `--with-openmp` to the last command.

More installation instructions and options can be found in the [web documentation](https://shtools.oca.eu) and GitHub [wiki](https://github.com/SHTOOLS/SHTOOLS/wiki).

### HOW TO USE ###

SHTOOLS can be invoked from Fortran 95, Python 2, or Python 3. The base SHTOOLS software is written in Fortran 95, and the Python library allows simple access to all fortran-compiled routines and offers helper routines as well as simple interfaces.

To get started, check out the following Python tutorial notebooks:

  • Introduction 1: Grids and Spherical Harmonic Coefficients [[ipynb]](examples/notebooks/Introduction-1.ipynb)

  • Introduction 2: Localization Windows and Spectral Analysis [[ipynb]](examples/notebooks/Introduction-2.ipynb)

  • Tutorial 1: Simple Spherical Harmonic Analyses [[ipynb]](examples/notebooks/tutorial_1.ipynb)

  • Tutorial 2: Localized Spectral Analysis on the Sphere [[ipynb]](examples/notebooks/tutorial_2.ipynb)

  • Tutorial 3: The SHTOOLS Class Interface [[ipynb]](examples/notebooks/tutorial_3.ipynb)

  • Tutorial 4: Spherical Harmonic Normalizations and Parseval’s theorem [[ipynb]](examples/notebooks/tutorial_4.ipynb)

  • Tutorial 5: Multitaper Spectral Analysis Class Interface [[ipynb]](examples/notebooks/tutorial_5.ipynb)

  • Tutorial 6: 3D Spherical Harmonic Plots [[ipynb]](examples/notebooks/tutorial_6.ipynb)

You can keep up to date by following SHTOOLS on [Twitter](https://twitter.com/SH_tools).

### ACKNOWLEDGMENTS ### SHTOOLS is open source (revised BSD license) and makes use of the freely available Fourier transform package [FFTW](http://www.fftw.org) and the linear algebra packages [LAPACK](http://www.netlib.org/lapack/) and [BLAS](http://www.netlib.org/blas/).

### CITATION ### Wieczorek, M. A., M. Meschede, I. Oshchepkov, E. Sales de Andrade, and heroxbd (2016). SHTOOLS: Version 4.0. Zenodo. doi:[10.5281/zenodo.206114](http://dx.doi.org/10.5281/zenodo.206114).

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

pyshtools-4.1-cp36-cp36m-win_amd64.whl (31.2 MB view details)

Uploaded CPython 3.6m Windows x86-64

pyshtools-4.1-cp36-cp36m-manylinux1_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.6m

pyshtools-4.1-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (2.7 MB view details)

Uploaded CPython 3.6m macOS 10.10+ intel macOS 10.10+ x86-64 macOS 10.6+ intel macOS 10.9+ intel macOS 10.9+ x86-64

pyshtools-4.1-cp35-cp35m-win_amd64.whl (31.2 MB view details)

Uploaded CPython 3.5m Windows x86-64

pyshtools-4.1-cp35-cp35m-manylinux1_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.5m

pyshtools-4.1-cp35-cp35m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (2.7 MB view details)

Uploaded CPython 3.5m macOS 10.10+ intel macOS 10.10+ x86-64 macOS 10.6+ intel macOS 10.9+ intel macOS 10.9+ x86-64

pyshtools-4.1-cp34-cp34m-manylinux1_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.4m

pyshtools-4.1-cp34-cp34m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (2.7 MB view details)

Uploaded CPython 3.4m macOS 10.10+ intel macOS 10.10+ x86-64 macOS 10.6+ intel macOS 10.9+ intel macOS 10.9+ x86-64

pyshtools-4.1-cp27-cp27mu-manylinux1_x86_64.whl (10.7 MB view details)

Uploaded CPython 2.7mu

pyshtools-4.1-cp27-cp27m-manylinux1_x86_64.whl (10.7 MB view details)

Uploaded CPython 2.7m

pyshtools-4.1-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (2.7 MB view details)

Uploaded CPython 2.7m macOS 10.10+ intel macOS 10.10+ x86-64 macOS 10.6+ intel macOS 10.9+ intel macOS 10.9+ x86-64

File details

Details for the file pyshtools-4.1-cp36-cp36m-win_amd64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 a70111087f47ed7ea0118fb1a6d53cf667a3602a8c9f9e75851ab7998da08d59
MD5 db91305aa55c384b351295fa7084cc1c
BLAKE2b-256 803333ac323342d5f9bff68917a52f76f31c1bc9cb2864fdaf0939a62f07f1f1

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 96066f82036b2da20b8d5552ade171f79f6466f2786e5d4677a64090a107a9a4
MD5 57c953b5e593b1c5fb8a9958db65bf5e
BLAKE2b-256 38f529e08cf42752f7c9cc475ae23bcf60a80db85fc9c136cf332204811d70c2

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 2a3ffc9fd40566082cadabd9511def1650c78a2c2cd1c1a8b9edc8e9360ce67f
MD5 6a80a2b433ec491f34ed953892ceb540
BLAKE2b-256 307a3c59244c41c857452d0b10b0b89d86c34f075dfacfbf362a4f74983b51e9

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp35-cp35m-win_amd64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp35-cp35m-win_amd64.whl
Algorithm Hash digest
SHA256 44f50b1dd9eb5e915dc90578c89331ff35412d4667c485442ab2095c98b789b1
MD5 ac9d67e0dc6abd90964043b96c3a55c3
BLAKE2b-256 028dd546f73055315f1ab4f8b2575c86a07c79497a131dddcc83312deeb978ef

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp35-cp35m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp35-cp35m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 b63836e4eff1b3c0656185e2a032d0d041440efe0faa76ce99ac9bcbb1677dc8
MD5 1560d440eefe692e391968f9007eb745
BLAKE2b-256 ae18775b7b5850d53a55207ffc3b5bc3e447a2ae757b185265463d2bf8fc1540

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp35-cp35m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp35-cp35m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 8072c9fad1d229109f8b836643d494c530bf86fef59837a4dc10d923a3b6417f
MD5 83854c03bdcfc04f01b81a0f488ae39f
BLAKE2b-256 46439790b3da36c8c80bc9ae09894bf93ac95149ad7cb6fdd02eb3cb59477782

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp34-cp34m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp34-cp34m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 b64681e393cac36c6450c1795cd6b82d09aa3359184178e30620a06a7c7894ac
MD5 970ccf60c747294e8bd6e5c84603a6d9
BLAKE2b-256 a8aa580805cd17174b2ca09dc66239db5eb0d80341473f7906d7d7efbae8dcd4

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp34-cp34m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp34-cp34m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 0d0265d01a310cf2b101ae029ace907df50e32d5a548fe6dc6f0e7e4af47b080
MD5 dc9bfea4b331989e590d41772a281123
BLAKE2b-256 1ce6fecba7f1060f7960f83071e6cffdf7e214ceb25030e4c39bc15148238f89

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp27-cp27mu-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp27-cp27mu-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 7ef7db675fccb0530e40f9817143f1b6711982d68549d8fc68f094e61b0d6a22
MD5 458b005b55e8bc1ff9ebd2a2a4d7555e
BLAKE2b-256 33affb97a1153ebeab6509700dacae044d241a07017b36a81ce6c1daf66fca99

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp27-cp27m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp27-cp27m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 d0a8227095b2037465d0e0b82c744986fcb11b530b549523a29e8f9280d31527
MD5 907628c1bc4cb2f6f14bd213ef41fa12
BLAKE2b-256 20a54d333eed854588827400033a816fd06da49cd45a233d2fb1b3e2be777e83

See more details on using hashes here.

File details

Details for the file pyshtools-4.1-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for pyshtools-4.1-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 b42235e6038c971162fca71928fd85f4929cbae841bd19c273a49a822ab80669
MD5 a9b7f3498694fb6c9a81fd845152fd2e
BLAKE2b-256 eeaff701ec60ba16d9e59b7d77c3c3c7eef1f5201bf631b9669c2768f8be9734

See more details on using hashes here.

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