Class LatticeBoltzmannSolver

java.lang.Object
org.episteme.natural.physics.classical.matter.fluids.LatticeBoltzmannSolver

public class LatticeBoltzmannSolver extends Object
2D Lattice Boltzmann Method (LBM) solver for incompressible fluid flow. Uses D2Q9 lattice (2D, 9 velocity directions).

References:

  • Succi, S. (2001). The Lattice Boltzmann Equation: For Fluid Dynamics and Beyond. Oxford University Press.
  • Chen, S., invalid input: '&' Doolen, G. D. (1998). Lattice Boltzmann method for fluid flows. Annual Review of Fluid Mechanics, 30(1), 329-364.

Since:
1.0
Author:
Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
  • Constructor Details

    • LatticeBoltzmannSolver

      public LatticeBoltzmannSolver(int width, int height, double viscosity)
      Creates an LBM solver.
      Parameters:
      width - Grid width
      height - Grid height
      viscosity - Kinematic viscosity (determines relaxation time)
  • Method Details

    • setProvider

      public void setProvider(LatticeBoltzmannProvider p)
    • setObstacle

      public void setObstacle(int x, int y, boolean isObstacle)
      Sets an obstacle at a grid point.
    • setInletVelocity

      public void setInletVelocity(double ux0, double uy0)
      Sets inlet velocity (left boundary).
    • step

      public void step()
      Performs one LBM time step using the provider.
    • getDensity

      public double[][] getDensity()
    • getVelocityX

      public double[][] getVelocityX()
    • getVelocityY

      public double[][] getVelocityY()
    • getWidth

      public int getWidth()
    • getHeight

      public int getHeight()