Introduction: Lattice Boltzmann Method for Non-fluid Applications Ye Zhao
Lattice Boltzmann Method Microscopic numerical solver initially desinged for fluid dynamics Microscopic numerical solver initially desinged for fluid dynamics Simple, explicit and parallel scheme Simple, explicit and parallel scheme Parallel scheme for hardware acceleration Parallel scheme for hardware acceleration Graphics hardware: GPU, GPU cluster Graphics hardware: GPU, GPU cluster
LBM in Computer Graphics Natural phenomena with fluids Natural phenomena with fluids Fluid Flows Fluid Flows Smoke and fire Smoke and fire Ink dispersion Ink dispersion Snowing Snowing Liquid mixture (Wang et al. 2006) Liquid mixture (Wang et al. 2006) More … More … Non-fluids Non-fluids Lighting (Geist et al. 2004) Lighting (Geist et al. 2004) Image Processing Image Processing
Navier-Stokes Equation Model the macroscopic behavior of fluid Model the macroscopic behavior of fluid
Microscopic Dynamics Microscopic particles inside fluids Fictitious particles moving along lattice links
Lattice Boltzmann Equation f : probability distribution function of particle populations on each link f : probability distribution function of particle populations on each link Recover the Navier-Stokes equation Recover the Navier-Stokes equation At the limit of low Mach number fluids At the limit of low Mach number fluids Discretize Boltzmann equation on discrete moving directions i (1988) Discretize Boltzmann equation on discrete moving directions i (1988)
Lattice Structure
Single-relaxation-time LBM Collision Collision BGK model (1954) for equilibrium BGK model (1954) for equilibrium Streaming along a link to a neighbor Streaming along a link to a neighbor
Macroscopic Properties Density, velocity and viscosity Density, velocity and viscosity
Body Forces
Graphics Hardware Graphics processing units (GPU) Graphics processing units (GPU) Low price Low price Inherently parallel Inherently parallel Programmable Programmable Booming growth rate on speed Booming growth rate on speed 3.0 GHz dual-core Pentium4: 24.6 GFLOPs 3.0 GHz dual-core Pentium4: 24.6 GFLOPs NVIDIA GeForce FX 7800: 165 GFLOPs NVIDIA GeForce FX 7800: 165 GFLOPs Ideal general-purpose applications Ideal general-purpose applications Large data sets Large data sets High parallelism High parallelism Minimal dependencies between data elements Minimal dependencies between data elements
Computation on GPU Texture Images Fragment Processing Fragments Fragment w/ Colors Graphics: Data Numerical Calculation Fragments Results Computation:
LBM Acceleration on GPU Simple addition, subtraction and multiplication Simple addition, subtraction and multiplication Computation on cluster Computation on cluster Large-scale simulation Large-scale simulation Domain decomposition Domain decomposition
LBM for Non-fluids Applications Actually LBM is a special numerical solver for partial differential equations (PDE) Actually LBM is a special numerical solver for partial differential equations (PDE) PDEs are widely used in graphics and visualization applications PDEs are widely used in graphics and visualization applications Image processing Image processing Surface processing Surface processing Volume graphics and visualization Volume graphics and visualization Computer vision … Computer vision …
Use LBM in these fields? Pros: Pros: LBM is simple to implement LBM is simple to implement both CPU and GPU both CPU and GPU Flexible and easy to modify its scheme Flexible and easy to modify its scheme Computational speed very fast with hardware acceleration Computational speed very fast with hardware acceleration Cons: Cons: Difficult understanding at the beginning Difficult understanding at the beginning Memory usage Memory usage Worth a try! Worth a try!
Research Topics How to modify LBM scheme in order to theoretically recover the preferred PDEs How to modify LBM scheme in order to theoretically recover the preferred PDEs How to improve hardware acceleration performance How to improve hardware acceleration performance New-generation GPU architecture New-generation GPU architecture Memory use optimization Memory use optimization How to incorporate with particular applications How to incorporate with particular applications
Modify LBM Equilibrium Equation for Diffusion For fluid dynamics For fluid dynamics BGK model (1954) for equilibrium BGK model (1954) for equilibrium For diffusion only For diffusion only
Recover Diffusion Equation Chapman-Enskog expansion, ε represents a small expansion parameter (Knudsen number) Chapman-Enskog expansion, ε represents a small expansion parameter (Knudsen number) Use this and Taylor expansion on LBM equation Use this and Taylor expansion on LBM equation
Recover Diffusion Equation (Continue) We get expanded equation : We get expanded equation : Constraints Constraints Summation on expanded equation over i Summation on expanded equation over i
Recover Diffusion Equation (Continue) Diffusion tensor defined by lattice structure Diffusion tensor defined by lattice structure For a particular lattice structure we obtain For a particular lattice structure we obtain For D3Q19 For D3Q19
Applications Volume Smoothing Volume Smoothing
Volume Smoothing
Surface Smoothing
Image De-noising
Poisson Image Editing Poisson Equation with Dirichlet boundary Poisson Equation with Dirichlet boundary is a computed guidance field computed from origin image is a computed guidance field computed from origin image
Performance GPU NVidia 8800GTX with 768MB memory GPU NVidia 8800GTX with 768MB memory
More Applications Apply to others beyond diffusion Apply to others beyond diffusion Use level set equation as a pivot example Use level set equation as a pivot example It has many application fields It has many application fields Combine several different types of PDEs Combine several different types of PDEs
Propagation interface as zero level set Propagation interface as zero level set d is distance to interface d is distance to interface Surface motion Surface motion F = Signed speed in direction of normal Level Set
F Speed Function Curvature flow diffusion on distance field Curvature flow diffusion on distance field Advected propagation by a external field Advected propagation by a external field Constant speed expansion Constant speed expansion
LBM for Level Set Use distance field as the computational primitive in LBM Use distance field as the computational primitive in LBM Play the role as density in fluids Play the role as density in fluids Design appropriate equlibrium function for PDEs Design appropriate equlibrium function for PDEs
Thanks