Fast evaluation of spherical harmonics with sphericart

Filippo Bigi, Guillaume Fraux, Nicholas J. Browning, Michele Ceriotti
2/16/2023
23 citations
physics.chem-phcs.LG

Official code: lab-cosmo/sphericart (105 stars, C++, MIT, PyTorch, last commit 2026-04-30).

Abstract

Spherical harmonics provide a smooth, orthogonal, and symmetry-adapted basis to expand functions on a sphere, and they are used routinely in physical and theoretical chemistry as well as in different fields of science and technology, from geology and atmospheric sciences to signal processing and computer graphics. More recently, they have become a key component of rotationally equivariant models in geometric machine learning, including applications to atomic-scale modeling of molecules and materials.

Show full abstract

We present an elegant and efficient algorithm for the evaluation of the real-valued spherical harmonics. Our construction features many of the desirable properties of existing schemes and allows to compute Cartesian derivatives in a numerically stable and computationally efficient manner. To facilitate usage, we implement this algorithm in sphericart, a fast C++ library which also provides C bindings, a Python API, and a PyTorch implementation that includes a GPU kernel.

View on arXivView PDF

Code Implementations(1)

PyTorchMIT

Multi-language library for the calculation of spherical harmonics in Cartesian coordinates

10517C++, PythonFeb 4, 20237 months agoMIT
geometric-deep-learningpythonpytorchspherical-harmonics

Similar Papers

Cite this paper

@article{bigi2023fast,
  title  = {Fast evaluation of spherical harmonics with sphericart},
  author = {Filippo Bigi and Guillaume Fraux and Nicholas J. Browning and Michele Ceriotti},
  year   = {2023},
  eprint = {2302.08381},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2302.08381v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2302.08381.svg)](https://codeofpaper.com/paper/2302.08381)

Discussion