Numerical Scheme¶
hippoLBM solves the weakly compressible Navier-Stokes equations with the Lattice Boltzmann Method on a D3Q19 lattice. The algorithm advances the distribution functions \(f_i(\mathbf{x}, t)\) in two alternating steps — collision and streaming — repeated at each time iteration:
\[
f_i^*(\mathbf{x}, t) = f_i(\mathbf{x}, t) + \Omega_i(\mathbf{x}, t) + F_i(\mathbf{x}, t),
\qquad
f_i(\mathbf{x} + \mathbf{e}_i \Delta t, t + \Delta t) = f_i^*(\mathbf{x}, t)
\]
where \(\Omega_i\) is the collision operator (BGK or MRT) and \(F_i\) the body-force term.
One time step¶
flowchart LR
A[compute_macro_variables] --> B[collision]
B --> C[pre_stream_bcs]
C --> D[streaming]
D --> E[post_stream_bcs]
E --> F[boundary_conditions]
F --> G[end_iteration]
| Step | Default operator | Page |
|---|---|---|
compute_macro_variables |
macro_variables |
Macroscopic variables |
collision |
bgk (or mrt) |
Collision |
pre_stream_bcs |
bounce-back (domain walls, obstacles) | Bounce-back |
streaming |
streaming |
Streaming |
post_stream_bcs |
bounce-back completion | Bounce-back |
boundary_conditions |
nop |
Boundary Conditions |
The physical parameters (viscosity, body force, time step) are converted to lattice units once, by
lbm_parameters.