Hamiltonia
A dimension-generic physics engine spanning mechanics, molecular dynamics, fluids, fields, and electromagnetism.
Overview
Hamiltonia is a Python physics engine built around canonical position-and-momentum state. Its dimension-generic core uses composable force providers and symplectic integrators, so the same simulation framework can support multiple physical domains.
The repository includes:
- Newtonian mechanics and rigid-body simulations in two and three dimensions
- Special-relativistic kinematics
- Molecular dynamics and smoothed-particle hydrodynamics
- Wave and diffusion fields
- Electromagnetism, including charged-particle dynamics and FDTD Maxwell simulations
Explore the source code, examples, and documentation.