Python-JAX-based fast Stokesian dynamics

Stokesian Dynamics (SD) is a powerful computational framework for simulating the motion of particles in a viscous Newtonian fluid under Stokes-flow conditions. Traditional SD implementations can be computationally expensive as they rely on the inversion of large mobility matrices to determine hydrodynamic interactions. Recently, however, the simulation of thermalized systems with large numbers of particles has become feasible [Fiore and Swan, J. Fluid Mech. 878, 544 (2019)]. Their “fast Stokesian dynamics” (FSD) method leverages a saddle-point formulation to ensure overall scaling of the algorithm that is linear in the number of particles \mathcal{O}(N) <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" display="inline"><mml:mrow><mml:mstyle mathvariant="script"><mml:mi>𝒪</mml:mi></mml:mstyle><mml:mo stretchy="false" form="prefix">(</mml:mo><mml:mi>N</mml:mi><mml:mo stretchy="false" form="postfix">)</mml:mo></mml:mrow></mml:math> ; performance relies on dedicated graphics-processing-unit computing. Here, we present a different route toward implementing FSD, which instead leverages the Just-in-Time (JIT) compilation capabilities of Google JAX. We refer to this implementation as JFSD and perform benchmarks on it to verify that it has the right scaling and is sufficiently fast by the standards of modern computational physics. In addition, we provide a series of physical test cases that help ensure accuracy and robustness, as the code undergoes further development. Thus, JFSD is ready to facilitate the study of hydrodynamic effects in particle suspensions across the domains of soft, active, and granular matter.

Authors

Institutions

Publication Details

Journal
SciPost Physics Codebases
Published
2025-06-30
DOI
https://doi.org/10.21468/scipostphyscodeb.56
Citations
3
Primary Topic
Lattice Boltzmann Simulation Studies
Type
article
Field-Weighted Citation Impact
4.00

Funders

Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Python-JAX-based fast Stokesian dynamics

Joost de Graaf, Kim William Torre, Raoul D. Schram
3 citations
SciPost Physics Codebases
Lattice Boltzmann Simulation Studies
4.00
article

Python-JAX-based fast Stokesian dynamics

Joost de Graaf, Kim William Torre, Raoul D. Schram
article en
3 citations

Abstract

Stokesian Dynamics (SD) is a powerful computational framework for simulating the motion of particles in a viscous Newtonian fluid under Stokes-flow conditions. Traditional SD implementations can be computationally expensive as they rely on the inversion of large mobility matrices to determine hydrodynamic interactions. Recently, however, the simulation of thermalized systems with large numbers of particles has become feasible [Fiore and Swan, J. Fluid Mech. 878, 544 (2019)]. Their “fast Stokesian dynamics” (FSD) method leverages a saddle-point formulation to ensure overall scaling of the algorithm that is linear in the number of particles \mathcal{O}(N) <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" display="inline"><mml:mrow><mml:mstyle mathvariant="script"><mml:mi>𝒪</mml:mi></mml:mstyle><mml:mo stretchy="false" form="prefix">(</mml:mo><mml:mi>N</mml:mi><mml:mo stretchy="false" form="postfix">)</mml:mo></mml:mrow></mml:math> ; performance relies on dedicated graphics-processing-unit computing. Here, we present a different route toward implementing FSD, which instead leverages the Just-in-Time (JIT) compilation capabilities of Google JAX. We refer to this implementation as JFSD and perform benchmarks on it to verify that it has the right scaling and is sufficiently fast by the standards of modern computational physics. In addition, we provide a series of physical test cases that help ensure accuracy and robustness, as the code undergoes further development. Thus, JFSD is ready to facilitate the study of hydrodynamic effects in particle suspensions across the domains of soft, active, and granular matter.

SciPost Physics Codebases
Utrecht University (NL)
International Fine Particle Research Institute
Openalex Percentile: Top 7%
Lattice Boltzmann Simulation Studies
4.00
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.