jax-md/jax-md

Differentiable, Hardware Accelerated, Molecular Dynamics

What it solves

Traditional molecular dynamics (MD) packages are often complex, specialized, and require separate codebases for CPU and GPU execution. They also typically require manual implementation of derivatives for computing forces from energy gradients. JAX MD simplifies this by providing a concise, hardware-accelerated, and end-to-end differentiable framework for simulating materials and small-scale interactions.

How it works

Built on JAX, the library compiles Python code to XLA, enabling seamless execution across CPUs, GPUs, and TPUs. It treats molecular dynamics as a functional and data-driven process where data is stored in arrays and functions transform these states. Because it leverages JAX's automatic differentiation, the entire simulation pipeline is differentiable, allowing users to take derivatives of the simulation results with respect to input parameters.

Who it’s for

It is designed for researchers in computational condensed matter physics and machine learning who need to simulate materials, explore complex large-scale phenomenology, or implement differentiable physics models.

Highlights

  • Hardware Agnostic: Runs on CPU, GPU, and TPU via JAX/XLA.
  • End-to-End Differentiable: Allows for automatic differentiation of the entire simulation process.
  • Functional Design: Uses a data-driven approach with arrays and transformation functions.
  • Versatile Applications: Supports a wide range of simulations including NVE, NVT, and NPT ensembles, as well as neural network potentials.

Related

  • Project
  • Project
  • Project
  • Project
  • Project