WHFast: A fast and unbiased implementation of a symplectic Wisdom-Holman integrator for long term gravitational simulations

Hanno Rein, Daniel Tamayo
6/2/2015
341 citations
astro-ph.EPastro-ph.IMmath.NA

Official code: hannorein/rebound (1,161 stars, C, GPL-3.0, last commit 2026-11-03).

Abstract

We present WHFast, a fast and accurate implementation of a Wisdom-Holman symplectic integrator for long-term orbit integrations of planetary systems. WHFast is significantly faster and conserves energy better than all other Wisdom-Holman integrators tested.

Show full abstract

We achieve this by significantly improving the Kepler-solver and ensuring numerical stability of coordinate transformations to and from Jacobi coordinates. These refinements allow us to remove the linear secular trend in the energy error that is present in other implementations. For small enough timesteps we achieve Brouwer's law, i.e. the energy error is dominated by an unbiased random walk due to floating-point round-off errors. We implement symplectic correctors up to order eleven that significantly reduce the energy error. We also implement a symplectic tangent map for the variational equations. This allows us to efficiently calculate two widely used chaos indicators the Lyapunov characteristic number (LCN) and the Mean Exponential Growth factor of Nearby Orbits (MEGNO). WHFast is freely available as a flexible C package, as a shared library, and as an easy-to-use python module.

View on arXivView PDF

Code Implementations(1)

hannorein/reboundOfficial100%
GPL-3.0

💫 An open-source multi-purpose N-body code.

1,161273C, PythonJul 2, 20114 weeks agoGPL-3.0
astrophysicskeplerian-elementsn-bodyorbitsplanetary-science+1 more

Similar Papers

Cite this paper

@article{rein2015whfast,
  title  = {WHFast: A fast and unbiased implementation of a symplectic Wisdom-Holman integrator for long term gravitational simulations},
  author = {Hanno Rein and Daniel Tamayo},
  year   = {2015},
  eprint = {1506.01084},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/1506.01084}
}

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/1506.01084.svg)](https://codeofpaper.com/paper/1506.01084)

Discussion