31
Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

  • View
    254

  • Download
    7

Embed Size (px)

Citation preview

Page 1: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann

Karin ErbertsederFerienakademie 2007

Page 2: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Outline Introduction Origin of the Lattice Boltzmann Method

Lattice Gas Automata Method Boltzmann Equation

Explanation of the Lattice Boltzmann Method

Comparison between Lattice Boltzmann Method and Navier-Stokes-Equations

Applications

Page 3: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

IntroductionComputational Fluid Dynamics(CFD): solution of transport equations simulation of mass, momentum

and energy transport processesApplications:

automotive, ship and aerospace industry, material science, …

Advantage:prediction of flow, heat and mass transportfundamental physical understandingoptimization of machines, processes, …

source: www.ansys.com

Page 4: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Introduction

Experiment

measurement often difficult or impossible

expensive and time consuming

parameter variations extremely expensive

measurement of only a few quantities at predefined locations

Numerical Simulation

compliance of similarity rules is no problem

less expensive and faster

easy parameter variation

provides detailed information on the entire flow field

Experiment vs. Simulation

Page 5: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

IntroductionGeneral Procedure

Flow Problem

ConservationEquations

Algebraic Systemof

Equations

Numerical Solution

VisualizationAnalysis

Interpretation

Solutionof the

Problemmathematical model, measured data

discretization, grid generation

algorithms

software, computer

Page 6: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

IntroductionMacroscopic Methods

e.g. Navier-Stokes fluid simulation (FDM, FVM)

Mesoscopic Methodse.g. Lattice Boltzmann method

Microscopic Methodse.g. molecular dynamics

Page 7: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Gas Automata (LGA)Cellular Automata (CA): idealized system where space and time

are discrete regular lattice of cells characterized by a

set of boolean state variables 1 or 0 particle at a lattice node

Lattice Gas Automata (LGA): special class of CA description of the dynamics of point

particles moving and colliding in a discrete space-time universe

Page 8: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Gas Automata (LGA)

streaming step

flow simulation by moving representative particles one node per time step

collision step

source: www.cmmfa.mmu.ac.uk

Page 9: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Gas Automata (LGA)

advantages stability easy introduction of

boundary conditions high performance

computing due to the intrinsic parallel structure

disadvantages statistical noise lack of Galilean

invariance velocity dependent

pressure

motivation for the transition from LGA to LBM:

removal of the statistical noise by replacing the Boolean particle number in a lattice direction with its ensemble average density distribution function [all disadvantages are improved or vanish]

Page 10: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Boltzmann Equation (BE)definition:

description of the evolution of the single particle distribution f in the phase space by a partial differential equation (PDE)

particle distribution function f (x,ξ,t):probability for particles to be located within a phase space control element dxdξabout x and ξ at time t where x and ξ are the spatial position vector and the particle velocity vector

macroscopic quantities, like density or momentum, by evaluation the first moments of the distribution function

Page 11: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Boltzmann Equation (BE)

ffQf

Gx

f

t

f,

time variation

spatial variation

effect of a force acting on the particle

velocity vector of a molecule position of

the molecule

force per unit mass acting on the particle

collision term interaction between the molecules

f = f (x, ξ, t) distribution function

The collision term is quadratic in f and has a complex integrodifferential expression simplification of the collision term with the

Bhatnagar-Gross-Krook (BGK) model

ff

ffQe

,

Page 12: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)assumptions: - neglect of external forces

- BGK model (SRT = single-relaxation-time approximation)

- velocity discretization using a finite set of velocity vectors ei

- movement of the particles only along the lattice vectors

- modeling of the fluid by many cells of the same type

- update of all cells each time step

- storage of the number of particles that move along each of the lattice vectors particle

distribution function f

eqiii

ii ff

x

fe

t

f

1

velocity discrete Boltzmann equation

Page 13: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)common lattice nomination: DXQY

number of distinct lattice velocities

number of dimensions

model for two dimensions:

source: J.Götz 2006

f6 6 7 f7 8 f8

f4 4 3 f3 2 f2

f5 5 1 f1

e4 e3 e2

e6 e7 e8

e5

e1

D2Q9 - most common model in 2D

- 9 discrete velocity directions

- eight distribution functions with the particles moving to the

neighboring cells

- one distribution function according to the resting particle

Page 14: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)models for three dimensions:

D3Q15 D3Q19 D3Q27

small range of good compromise highest

stability between the two computational

models effort

source: J.Götz 2006

19 distribution functions

one stationary velocity in the center for the particles at rest

6 velocity directions along the Cartesian axes

12 velocities combining two coordinate directions

resting particles don`t move in the following time step, but: changing amount of resting particles due to collisions

Page 15: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)

eqiii

ii ff

x

fe

t

f

1

next step: calculation of the density and momentum fluxes in the discrete velocity space

starting point: velocity discrete BE

equilibrium distribution function for D2Q9 model:

uu

cue

cue

cwf iii

eqi 2

242 2

3)(

2

931

t

xc

discrete particle velocity vector

weighting factor

iw 4/9 i = 0

= 1/9 i = 1, 3, 5, 7

1/36 i = 2, 4, 6, 8

lattice speed with the lattice cell size x and the lattice time step t

Page 16: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)calculation of the density and the momentum:

density

momentum

N

i

eqi

N

ii fffd

00

N

i

eqiii

N

ii fefefdu

00

Discretization:

discretization in time and space leads to the lattice BGK equation

txftxftxftttexf eqiiiii ,,

1,,

t dimensionless relaxation

timepoint in the discretized physical space

Page 17: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)lattice BGK equation is solved in two steps:

collision step:

streaming step:

collision step:

• interpretation as many particle collisions

•calculation of the equilibrium distribution function for each cell and at each time step from the local density ρ and the local macroscopic flow velocity u using the equations of the slide before

txftxftxftxf eqi

ini

ini

outi ,,

1,,

distribution values after collision

values after collision and propagation, values entering the neighboring cell = data for the next time step

txftttexf outii

ini ,,

Page 18: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Lattice Boltzmann Method (LBM)streaming step: streaming of the particles to their neighboring cells according to

their velocity directions lattice vector 0 no change of its particle distribution function in

the streaming step

particle distribution before stream step

particle distribution after stream step

source: J.Götz 2006

Page 19: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

LBM Parametrizationstandard parameters describing a given fluid flow problem: size of a LBM cell ∆x [m] fluid density ρ [kg/m3] fluid viscosity ν [m2/s] fluid velocity u [m/s] strength of the external force g [m/s2]

lattice time step ∆t*, lattice density ρ*, lattice cell size ∆x* constant during simulation

no multiplications with real world values of the time step, the density, the lattice size are necessary

1*

t

tt 1*

x

xx 1*

Page 20: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

LBM Parametrizationcalculation of the dimensionless lattice values:

lattice viscosity:

lattice velocity:

lattice gravity:

relation of all lattice values to the physical ones:calculation of the physical time step restricted time step depending on the maximal lattice velocity

2*

x

t

x

tuu

*

x

tgg

2

*

lattice viscosity, lattice velocity, lattice gravity are dimensionless

lattice velocity of 0.3 means that the fluid moves 0.3 lattice cells per time step

Page 21: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

LBM Parametrizationcalculation of the lattice viscosity ν*:

Calculation of the relaxation time:fluid velocity v is given calculation of the relaxation time needed for a simulation with the formula above

due to stability reasons:

6

12

2

1* 2

sc

relaxation time

speed of sound = 1/√3

2

1*6

5.251.0 3103.3*67.0

Page 22: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

LBM Boundary Treatment no-slip:

no movement of the fluid close to the boundary each cell next to a boundary has the same amount of particles moving into the boundary as moving into the opposite direction zero velocity (along the wall and in wall direction)

reflection of all distribution functions at the wall in the opposite direction

source:N.Thürey 2005

Page 23: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

LBM Boundary Treatment free slip:

reflection of the velocities normal to the boundaryboundaries with no friction (zero velocity only in wall direction)

inflow:given velocities calculation of the distribution function based on the equilibrium function (only on special type)

outflow several different types

source:N.Thürey 2005

Page 24: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

LBM Boundary Treatment periodic

particles that leave the domain through the periodic wall reenter the domain at the corresponding periodic wall copying the PDFs leaving the domain to the corresponding cells during the streaming step

source: C.Feichtinger 2006

Page 25: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Navier-Stokes Equations (NSE)

description of the macroscopic behavior of an isothermal fluid:conservation of mass:

incompressible fluid (ρ = constant):

momentum equation

0

i

i

x

u

t

velocity in i-direction

(i = 1,2,3 for x,y,z)density

0 i

i

x

u

ji

ij

ji

ji

j gxx

P

x

uu

t

u

advection pressure momentum

forces acting due to molecule

upon the fluid movement

viscous stress tensor

Page 26: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Comparison between LBM and NSE

second order partial differential equations

non-linearity quadratic velocity terms

need to solve the Poisson equation for pressure calculation

global solution for all lattice cells grid generation needs longer than simulation

set of first order partial differential equations

linear non linear convective term becomes a simple advection

pressure through an equation of state

regular square grids kinetic-based easy

application to micro-scale fluid flow problems

complicate simulation of stationary flow problems

Navier-Stokes Equations Lattice Boltzmann Method

Page 27: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Applications

Java-Simulation

Page 28: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Applications

source: N.Thürey

Page 29: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Applications

metal foam simulation: source:N.Thürey 2005

D3Q19 model free-surface model

filled with fluid interface: contains both liquid and gas gas: not considered in fluid simulation

computation of the fill level of a cell by dividing by the density of this cell (0 = empty cell; ρ = filled cell)

transformation of fluid and gas cells into interface cells and vice versa

Page 30: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Applications

source: N.Thürey

Page 31: Lattice Boltzmann Karin Erbertseder Ferienakademie 2007

Thanks For Your Attention

any

questions ?