Class LatticeBoltzmannSolver
java.lang.Object
org.episteme.natural.physics.classical.matter.fluids.LatticeBoltzmannSolver
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 Summary
ConstructorsConstructorDescriptionLatticeBoltzmannSolver(int width, int height, double viscosity) Creates an LBM solver. -
Method Summary
Modifier and TypeMethodDescriptiondouble[][]intdouble[][]double[][]intgetWidth()voidsetInletVelocity(double ux0, double uy0) Sets inlet velocity (left boundary).voidsetObstacle(int x, int y, boolean isObstacle) Sets an obstacle at a grid point.voidvoidstep()Performs one LBM time step using the provider.
-
Constructor Details
-
LatticeBoltzmannSolver
public LatticeBoltzmannSolver(int width, int height, double viscosity) Creates an LBM solver.- Parameters:
width- Grid widthheight- Grid heightviscosity- Kinematic viscosity (determines relaxation time)
-
-
Method Details
-
setProvider
-
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()
-