Direct Numerical Simulations of Multiphase Flows - PowerPoint PPT Presentation

1 / 37
About This Presentation
Title:

Direct Numerical Simulations of Multiphase Flows

Description:

A Finite Difference Code for the Navier-Stokes Equations in Vorticity/Stream Function ... Finite Difference Approximation of the Vorticity/Streamfunction equations ... – PowerPoint PPT presentation

Number of Views:39
Avg rating:3.0/5.0
Slides: 38
Provided by: grtartry
Category:

less

Transcript and Presenter's Notes

Title: Direct Numerical Simulations of Multiphase Flows


1
A Finite Difference Code for the Navier-Stokes
Equations in Vorticity/Stream Function Formulation
Instructor Hong G. Im University of Michigan
Fall 2005
Lecture notes were prepared jointly with Prof.
Gretar Tryggvason, Department of Mechanical
Engineering, Worcester Polytechnic Institute.
2
Objectives
Develop an understanding of the steps involved in
solving the Navier-Stokes equations using a
numerical method Write a simple code to solve
the driven cavity problem using the
Navier-Stokes equations in vorticity form
3
Outline
  • The Driven Cavity Problem
  • The Navier-Stokes Equations in Vorticity/Stream
    Function form
  • Boundary Conditions
  • Finite Difference Approximations to the
    Derivatives
  • The Grid
  • Finite Difference Approximation of the
    Vorticity/Streamfunction equations
  • Finite Difference Approximation of the Boundary
    Conditions
  • Iterative Solution of the Elliptic Equation
  • The Code
  • Results
  • Convergence Under Grid Refinement

4
The Driven Cavity Problem
Moving wall
Stationary walls
5
Nondimensional N-S Equation
Incompressible N-S Equation in 2-D
6
The vorticity/stream function equations
The Vorticity Equation
7
The vorticity/stream function equations
The Stream Function Equation
Define the stream function
which automatically satisfies the
incompressibility conditions
by substituting
8
The vorticity/stream function equations
Substituting
into the definition of the vorticity
yields
9
The vorticity/stream function equations
The Navier-Stokes equations in vorticity-stream
function form are
Advection/diffusion equation
Elliptic equation
10
Boundary Conditions for the Stream Function
At the right and the left boundary
11
Boundary Conditions for the Stream Function
At the top and the bottom boundary
12
Boundary Conditions for the Stream Function
Since the boundaries meet, the constant must be
the same on all boundaries
13
Boundary Conditions for the Vorticity
The normal velocity is zero since the stream
function is a constant on the wall, but the zero
tangential velocity must be enforced
At the right and left boundary
At the bottom boundary
At the top boundary
14
Boundary Conditions for the Vorticity
The wall vorticity must be found from the
streamfunction. The stream function is constant
on the walls.
At the right and the left boundary
Similarly, at the top and the bottom boundary
15
Summary of Boundary Conditions
16
Finite Difference Approximations
To compute an approximate solution numerically,
the continuum equations must be discretized.
There are a few different ways to do this, but we
will use FINITE DIFFERENCE approximations here.
17
Discretizing the Domain
Uniform mesh (hconstant)
jNY
Stored at each grid point
j2
j1
i1
i2
iNX
18
Finite Difference Approximations
When using FINITE DIFFERENCE approximations, the
values of f are stored at discrete points and the
derivatives of the function are approximated
using a Taylor series Start by expressing the
value of f(xh) and f(x-h) in terms of f(x)
f(x-h) f(x) f(xh)
h
h
19
Finite Difference Approximations
Finite difference approximations
2nd order in space, 1st order in time
20
Finite Difference Approximations
For a two-dimensional flow discretize the
variables on a two-dimensional grid
j1 j j-1
i -1 i i1
21
Finite Difference Approximations
Laplacian
22
Finite Difference Approximations
Using these approximations, the vorticity
equation becomes
23
Finite Difference Approximations
The vorticity at the new time is given by
24
Finite Difference Approximations
The stream function equation is
25
Discretized Domain
Discretize the domain
jny
for
j2
j1
i1
i2
inx
26
Discrete Boundary Condition
j3 j2 j1
i -1 i i1
27
Discrete Boundary Condition
Using
This becomes
Solving for the wall vorticity
28
Discrete Boundary Condition
At the bottom wall (j1)
Similarly, at the top wall (jny)
At the left wall (i1)
Fill the blank
At the right wall (inx)
Fill the blank
29
Solving the Stream Function Equation
Solving the elliptic equation
Rewrite as
j1
j
j-1
i
i1
i-1
30
Solving the Stream Function Equation
If the grid points are done in order, half of the
points have already been updated
j1
j
j-1
i
i1
i-1
Successive Over Relaxation (SOR)
31
Time Step Control
Limitations on the time step
32
Solution Algorithm
for i1MaxIterations for i2nx-1 for
j2ny-1 s(i,j)SOR for the stream
function end end end
v(i,j)
for i2nx-1 for j2ny-1
rhs(i,j)Advectiondiffusion end end
v(i,j)v(i,j)dtrhs(i,j)
33
MATLAB Code

34
Solution Fields
nx17, ny17, dt 0.005, Re 10, Uwall 1.0
35
Solution Fields
nx17, ny17, dt 0.005, Re 10, Uwall 1.0
36
Accuracy by Resolution
Stream Function at t 1.2
37
Accuracy by Resolution
Vorticity at t 1.2
Write a Comment
User Comments (0)
About PowerShow.com