Wavelet Adaptive Multilevel Representation (WAMR) and Intrinsic...
Transcript of Wavelet Adaptive Multilevel Representation (WAMR) and Intrinsic...
Wavelet Adaptive Multilevel Representation (WAMR)
and Intrinsic Low Dimensional Manifold (ILDM) for
Reactive Flows
by
Joseph M. Powers
Associate Professor
Department of Aerospace and Mechanical Engineering
University of Notre Dame
presented to the
Workshop on Adaptive Methods for Flow Computation
AMFLOW 2001
Heidelberg University, Heidelberg, Germany
22 October 2001
Acknowledgments
Prof. Samuel Paolucci, Faculty, Notre Dame,
Mr. Sandeep Singh, Ph.D. Candidate, Notre Dame,
Mr. Yevgenii Rastigejev, Ph.D. Candidate, Notre Dame.
Los Alamos National Laboratory
National Science Foundation
Air Force Office of Scientific Research
Outline
• Motivation
• Wavelet Adaptive Multilevel Representation (WAMR) technique
(Paolucci & Vasilyev, 1997, Journal of Computational Physics)
for spatial discretization
• Intrinsic Low Dimensional Manifold (ILDM) technique (Maas &
Pope, 1992, Combustion and Flame) for reactive source terms
• One-dimensional results: viscous detonation in H2/O2/Ar sys-
tem (Singh, Rastigejev, Paolucci, & Powers, 2001, Combustion
Theory and Modeling), and laminar ozone flame (Singh, Powers,
& Paolucci, ICDERS, 2001)
• Two-dimensional results: lid-driven fluid in rectangular cavity at
high Reynolds number
• Conclusions
General Motivation
• Combustion problems are among the most demanding computa-
tional problems solved in science and engineering (auto, jet, and
rocket engines, atmospheric chemistry, fire safety,...)
• Combustion characterized by phenomena evolving on widely dis-
parate space (1 nm to 10 m) and time (1 ns to 10 s) scales.
• Disparity of scales generated by
– geometry
– heterogeneities in material properties
– diffusive boundary layers
– fine and coarse reaction zones
– interacting shock waves
– intrinsic non-linear effects
• Solutions
– faster and larger compuational hardware
– more efficient software
• Our focus: adaptive methods suited for parallel architectures
Compressible Reactive Navier-Stokes Equations
∂ρ
∂t+
∂
∂x(ρu) = 0, mass
∂
∂t(ρu) +
∂
∂x
(ρu2 + p − τ
)= 0, momentum
∂
∂t
(ρ
(e +
u2
2
))+
∂
∂x
(ρu
(e +
u2
2
)+ u (p − τ) + q
)= 0, energy
∂
∂t(ρyl) +
∂
∂x(ρuyl + jl) = 0, (l = 1, . . . , L − 1) , elements
∂
∂t(ρYi) +
∂
∂x(ρuYi + Jm
i ) = ω̇iMi, (i = 1, . . . , N − L) , species
τ =43µ
∂u
∂x, Newtonian gas with Stokes’ assumption
Jq = −k∂T
∂x+
N∑i=1
Jmi
(ho
i +∫ T
To
cpi(T̂ )dT̂
)−<T
N∑i=1
DTi
Mi
(1χi
∂χi
∂x+(
1 − Mi
M
)1p
∂p
∂x
), Fourier’s law
Jmi = ρ
N∑j=1,j 6=i
Mi
MYjDij
(1χj
∂χj
∂x+(
1 − Mj
M
)1p
∂p
∂x
)−DT
i
1T
∂T
∂x, (i = 1, . . . , N) , Fick’s law
yl = ml
N∑i=1
φil
MiYi, (l = 1, . . . , L − 1) , element mass fraction
M =N∑
i=1
Miχi, mean molecular mass
χi =M
MiYi, (i = 1, . . . , N), mole fraction
jl = ml
N∑i=1
φil
MiJi, (l = 1, . . . , L − 1) , element mass flux
N∑i=1
Yi = 1, mass fraction constraint
L∑l=1
yl = 1, element mass fraction constraint
ω̇i =J∑
j=1
ajTβj exp
(−Ej
<T
)(ν′′
ij − ν′ij
) N∏k=1
(ρYk
Mk
)ν′kj
, (i = 1, . . . , N − L) law of mass action
p = ρ<T
N∑i=1
Yi
Mi, thermal equation of state
e =N∑
i=1
Yi
(ho
i +∫ T
To
cpi(T̂ )dT̂ − <T
Mi
). caloric equation of state
N species, L elements, J reactions
4N + L + 7 equations in 4N + L + 7 unknowns
Operator Splitting Technique
• Equations are of form
∂
∂tq(x, t) +
∂
∂xf(q(x, t))︸ ︷︷ ︸
convection/diffusion
= g(q(x, t))︸ ︷︷ ︸reaction
, q, f ,g ∈ <N+2.
where
q =
ρ, ρu, ρ
e +
u2
2
, ρyl, ρYi
T
.
• Splitting
1. Inert convection-diffusion step:
∂
∂tq(x, t) +
∂
∂xf(q(x, t)) = 0,
d
dtqi(t) = −∆xf(qi(t)) WAMR.
∆x is any spatial discretization operator, here a wavelet oper-
ator.
2. Reaction source term step:
∂
∂tq(x, t) = g(q(x, t)),
d
dtqi(t) = g(qi(t)) ILDM.
Wavelet Adaptive Multilevel Representation (WAMR) Technique
• Summary of standard spatial discretization techniques
– Finite difference-good spatial localization, poor spectral local-
ization, and slow convergence,
– Finite element- good spatial localization, poor spectral local-
ization, and slow convergence,
– Spectral–good spectral localization, poor spatial localization,
but fast convergence.
• Wavelet technique
– See e.g. Vasilyev and Paolucci, “A Fast Adaptive Wavelet Col-
location Algorithm for Multidimensional PDEs,” J. Comp.
Phys., 1997,
– Basis functions have compact support,
– Well-suited for problems with widely disparate spatial scales,
– Good spatial and spectral localization, and fast (spectral) con-
vergence,
– Easy adaptable to steep gradients via adding collocation points,
– Spatial adaptation is automatic and dynamic to achieve pre-
scribed error tolerance.
Wavelet Basis Functions
-0.5
0.0
0.5
1.0
-0.5
0.0
0.5
1.0
0.0 0.2 0.4 0.6 0.8 1.0
-0.5
0.0
0.5
1.0
-0.5
0.0
0.5
1.0
0.0 0.2 0.4 0.6 0.8 1.0
0.0 0.2 0.4 0.6 0.8 1.00.0 0.2 0.4 0.6 0.8 1.0
-0.5
0.0
0.5
1.0
0.0 0.2 0.4 0.6 0.8 1.0
Left Boundary Wavelets
Interior Wavelet
• Boundary-modified Daubechies autocorrelation functions and in-
terior Daubechies autocorrelation function of order four
• Scaling function
φj,k(x) = φ(2jx− k)
• Definition of the wavelet function on the first level
ψ1,0(x) = φ(2x− 1)
• Definition of the wavelet function on j level
ψj,k+1(x) = ψ(2j−1x− k)
Algorithm Description
• Approximate initial function using wavelet basis,
PJu(x) =∑ku0,kφ0,k(x) +
J∑j=1
∑kdj,kψj,k(x)
• Discard non-essential wavelets if amplitude below threshold value
(here we look only at P , T , u, and ρ, species could be included),
PJu(x) = uJ≥(x) + uJ<(x)
uJ≥(x) =∑ku0,kφ0,k(x) +
J∑j=1
∑kdj,kψj,k(x), |dj,k| ≥ ε
uJ<(x) =J∑j=1
∑kdj,kψj,k(x), |dj,k| < ε
• Assign a collocation point to every essential wavelet,
• Establish a neighboring region of potentially essential wavelets,
• Discretize the spatial derivatives; five points used here (related
to order of wavelet family),
• Integrate in time; linearized trapezoidal method (implicit) used
here,
• Repeat
Sample Wavelet Approximation to Arbitrary Function
0.0 0.2 0.4 0.6 0.8 1.0
0.1
0.3
0.5
0.7
0.9
1.1
0.0 0.2 0.4 0.6 0.8 1.0-1
1
3
5
7•
Arbitrary Function with Variation on Long and Short Scales
f(x)
Leve
l
irregular grid
neighboringregion
+
x
x
• Function shown has large and small length scale variation,
• Wavelets concentrated in regions of steep gradients.
Intrinsic Low-Dimensional Manifold Method (ILDM)
• Uses a dynamical systems approach,
• Most appropriate for spatially homogeneous systems (ODEs)
• Does not require imposition of ad hoc partial equilibrium or
steady state assumptions,
• Fast time scale phenomena are systematically equilibrated,
• Slow time scale phenomena are resolved in time,
• Computation time reduced by factor of ∼ 3 for non-trivial com-
bustion problem considered here; manifold gives much better
roadmap to find solution relative to general implicit solution tech-
niques (Singh, et al., 2001)
• Speed up factor depends on
– initial conditions,
– stiffness ratio
– dimension of ILDM
Simplest Example
dx
dt= −10x, x(0) = xo,
dy
dt= −y, y(0) = yo.
• Stable equilibrium at (x, y) = (0,0); stiffness ratio = 10.
• ILDM is x = 0
-1 -0.5 0.5 1x
-7.5
-5
-2.5
2.5
5
7.5
y
• Parameterization of manifold: x(s) = 0; y(s) = s.
dy
dt=dy
ds
ds
dt, chain rule
−y(s) =dy
ds
ds
dt, substitute from ODE and manifold
−s = (1)ds
dt, no longer stiff!
s = soe−t,
x(t) = 0; y(t) = soe−t.
• Projection onto manifold for so, induces small phase error.
ILDM Implementation in Operator Splitting
• Form of equations in source term step:
d
dt
ρ
ρu
ρ(e + u2
2
)
ρyl
ρYi
=
0
0
0
0
ω̇iMi
.
l = 1, . . . , L− 1, i = 1, . . . , N − L.
• Equations reduce to
ρ = ρo, u = uo, e = eo, yl = ylo,
dYidt
=ω̇iMi
ρo, i = 1, . . . , N − L
• ω̇i has dependency on ρ, e, yl, and Yi
• ODEs for Yi are stiff, usually solved with implicit methods.
• ODEs for Yi can be attacked with manifold methods to remove
stiffness with ILDM with ρ, e, yl, . . . , yL−1 parameterization.
Implementation of ILDMs with convection-diffusion
and operator splitting
• To minimize phase error, must integrate full equations until suf-
ficiently close to ILDM
• When near ILDM, M slow equations are integrated, other vari-
ables found by table lookup
• Convection-diffusion step applied to all variables perturbs sys-
tem from ILDM
• In next reaction step, project to ILDM at different value of ρ, e,
y1, . . . , yN−1.
Projection ontomanifold at a different statePerturbation off the
manifold due toconvection anddiffusion
ILDM (ρ , e , y ..., y )1 1
ILDM (ρ , e , y ,..., y )2 2
Y
Y
A
B
1, 2 L-1,2
1,1 L-1,1
Formulation of General ILDMs
• A spatially homogeneous adiabatic, isochoric chemically reactive
system of N species in L elements is modeled by a set of non-
linear ordinary differential equations:
dx
dt= F(x), x(0) = xo,
x : species concentration; x ∈ <N−L
• Equilibrium points defined by
x = xeq such that F(xeq) = 0.
• Consider a system near equilibrium (the argument can and must
be extended for systems away from equilibrium) with x̃ = x−xeq.
• Linearization givesdx̃
dt= Fx · x̃,
where Fx is a constant Jacobian matrix.
• Schur decompose the Jacobian matrix:
Fx = Q · U ·QT
Q =
......
...
q1 q2 · · · qN−L
......
...
, U =
λ1 u1,2 · · · u1,N−L
0 λ2 · · · u2,N−L
0 · · · . . ....
0 · · · 0 λN−L
, QT =
· · · qT1 · · ·
· · · qT2 · · ·...
· · · qTN−L · · ·
Formulation of General Manifolds (cont.)
• Q is an orthogonal matrix with real Schur vectors qi in its columns.
• U is an upper triangular matrix with eigenvalues of Fx on its
diagonal, sometimes placed in order of decreasing magnitude.
• The Schur vectors qi form an orthonormal basis which spans the
phase space, <N−L.
• We then define M slow time scales, M < N − L.
• Next define a non-square matrix W which has in its rows the
Schur vectors associated with the fast time scales:
W =
· · · · · · qTM+1 · · · · · ·· · · · · · qTM+2 · · · · · ·
...
· · · · · · qTN−L · · · · · ·
.
• Letting the fast time scale events equilibrate defines the manifold:
W · F(x) = 0.
Sample ILDM for H2/O2/Ar
• Based on N = 9, J = 37 mechanism of Maas and Warnatz,
• Projection in YH2O, YH2O2 plane and YH2O, YH2O2, e space
• Adiabatic (e = 8×105 J/kg), isochoric (ρ = 5.0×10−4 kg/m3),
yH = 0.01277, yO = 0.10137, yAr = 0.88586,
• We can get e.g. p (ρ, e, YH2O) , T (ρ, e, YH2O) , YH (ρ, e, YH2O) , . . .
• Linear interpolation used for points not in table,
• Captures ∼ 0.1 µs reaction events.
0.04 0.045 0.05 0.055 0.06 0.065 0.07 0.075 0.080
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1x 10
−5
YH
2O
2
ILDM
equilibrium point
phase spacetrajectories
YH
2O
0.05
0.06
0.07
0.08
0.09
0.1 0
2
4
6
8
10
x 105
0
0.5
1
1.5
2
x 10−5
e (J/kg)YH
2O
YH
2O
2
2-D projection 3-D projection
Ignition Delay in Premixed H2/O2/Ar
• Consider standard problem of Fedkiw, Merriman, and Osher, J.
Comp. Phys., 1996,
• Shock tube with premixed H2, O2, and Ar in 2/1/7 molar ratio,
• Initial inert shock propagating in tube,
• Reaction commences shortly after reflection off end wall,
• Detonation soon develops,
• Model assumptions
– One-dimensional,
– Mass, momentum, and energy diffusion,
– Nine species, thirty-seven reactions,
– Ideal gases with variable specific heats.
Viscous H2 −O2 Ignition Delay with Wavelets and ILDM
• t = 195 µs, 300 collocation points, 15 wavelet scale levels
• ILDM gives nearly identical results as full chemistry
• WAMR spatial discretization, implicit linear trapezoidal convection-
diffusion time stepping, explicit (ILDM)/implicit (non-ILDM) re-
action time stepping
• Viscous shocks, inductions zones, and entropy layers spatially
resolved!
0 0.02 0.04 0.06 0.08 0.1500
1000
1500
2000
2500
3000
x (m)
Tem
pera
ture
(K
)
0 0.02 0.04 0.06 0.08 0.1
−600
−400
−200
0
200
400
600
x (m)
Vel
ocity
(m
/s)
0 0.02 0.04 0.06 0.08 0.10
1
2
3
4
5x 10
5
x (m)
Pre
ssur
e (P
a)
0 0.02 0.04 0.06 0.08 0.10.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
x (m)
Den
sity
(kg
/m3 )
Viscous H2 −O2 Ignition Delay with Wavelets and ILDM
• t = 195 µs
• ILDM gives nearly identical results as full chemistry
0 0.05 0.10
0.5
1
1.5
2
2.5x 10
−3 H
0 0.05 0.10
0.005
0.01
0.015O
0 0.05 0.10
0.005
0.01
0.015H2
0 0.05 0.10
0.05
0.1
0.15O2
0 0.05 0.10
0.005
0.01
0.015OH
0 0.05 0.10
0.05
0.1H2O
0 0.05 0.10
2
4
6
8
x 10−5 HO2
m0 0.05 0.1
0
1
2
3
x 10−5 H2O2
m0 0.05 0.1
0
0.5
1Ar
m
Viscous H2 − O2 Ignition Delay with Wavelets
Global and Fine Scale Structures
• t = 230 µs, Induction zone length: ∼ 470 µm, Viscous shock
thickness: ∼ 50 µm (should use smaller µ),
• No significant reaction in viscous shock zone.
0 0.02 0.04 0.06 0.08 0.10
0.5
1
1.5
2
2.5
3
3.5x 10
5
x (m)
Pre
ssur
e (P
a)
Global View
0.028 0.0282 0.0284 0.0286 0.02880
0.5
1
1.5
2
2.5
3
3.5x 10
5
Pre
ssur
e (P
a)
x (m)
Fine Scale Structure
ViscousLayer
Induction Zone
Viscous H2 −O2 Ignition Delay with Wavelets,
Instantaneous Distributions of Collocation Points
• t = 180 µs, two-shock structure with consequent collocation
point distribution,
• t = 230 µs, one-shock structure with evolved collocation point
distribution.
0 0.02 0.04 0.06 0.08 0.1 0.120
5
10
15
x (m)
Leve
l
0 0.02 0.04 0.06 0.08 0.1 0.120
5
10
15
x (m)
Leve
l
Laminar Ozone Flame with Improved ILDM
• One dimensional, low Mach number limit
• see Margolis, J. Comp. Phys., 1978
• Classical ILDM for ODEs only
• Project PDEs onto fast and slow bases defined by ILDM.
• Solve slow PDEs and new elliptic equation: Elliptic Convection-
Diffusion Corrector, ECDC
ψ✱
ECDCFull PDE Solution
ψ✱
maa
s fra
ctio
n
Yo2
Yo3
0 200 400 600 800 1000 1200 1400 1600 1800 200010
−14
10−12
10−10
10−8
10−6
10−4
10−2
100
Yo
Laminar Ozone Flame with Improved ILDM: Phase Error
• ECDC gives improved accuracy in wave speed predictions relative
to Maas-Pope projection.
• ECDC has stronger coupling with full equations.
• ECDC analagous to elliptic equation for pressure in incompress-
ible Navier-Stokes, where fast acoustics have been filtered.
ECDCFull PDE Solution ✶
MPP ●
0 1000 2000 3000 4000 5000 6000 7000 8000 9000 10000−0.005
0
0.005
0.01
0.015
0.02
0.025
0.03
t ✶
d✶
Laminar Ozone Flame with Improved ILDM: Amplitude Error
• ECDC gives improved accuracy in amplitude predictions at long
time relative to Maas-Pope projection.
ECDCFull PDE Solution ✶
MPP ●
t ✶
L∞
0 1000 2000 3000 4000 5000 6000 7000 8000 9000 100000
1
2
3
4
5
6x 10
−5
Lid-Driven Fluid in Rectangular Cavity
• Standard two-dimensional test problem (Ghia, et al., J. Comp.
Phys., 1982)
• Consider incompressible Navier-Stokes equations
∂u
∂x+∂v
∂y= 0,
∂u
∂t+ u
∂u
∂x+ v
∂u
∂y= −∂p
∂x+
1
Re
∂
2u
∂x2+∂2u
∂y2
,
∂v
∂t+ u
∂v
∂x+ v
∂v
∂y= −∂p
∂y+
1
Re
∂
2v
∂x2+∂2v
∂y2
.
• Project dependent variables onto wavelet basis localized in two-
dimensions.
• Fast Poisson solver developed for resulting equation for pressure.
• Dynamic memory allocation utilized for variable storage require-
ments.
• Adaptive nature of the method requires a robust computational
technique for computing derivatives.
• Wavelets which are physically close may be far removed in mem-
ory storage.
• Method prepared to handle a wide variety of stencil combinations.
Velocity Vector Field, Re = 10000, t = 4
• Re = 10000 equivalent to highest Re for this problem in the
published literature with long time steady results.
• Initial transients have not yet relaxed here.
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 10
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
x
y
Re = 10000, time = 4
Velocity Vector Field, Re = 10000, t = 12
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 10
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
x
yRe = 10000, time = 12
Velocity Vector Field, Re = 10000, t = 100
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 10
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
x
yRe = 10000, time = 100
Velocity Vector Field, Re = 3200
• Long time results t = 100; initial transients have relaxed.
• Wavelets only present in regions of steep gradients.; ε = 0.01.
• Five levels of wavelets: coarsest 16 × 16, finest 257× 257; equiv-
alent to Ghia’s uniform grid.
• Results are more accurate than Ghia, as a higher order stencil
was used on an equivalent grid.
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 10
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
x
y
Re = 3200, time = 100
Comparison with Ghia’s Results for u, Re = 3200
• Midplane predictions of long-time u velocity agree well with Ghia’s
predictions.
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−0.5
0
0.5
1U−velocity along x = 0.5, Re = 3200
U−
velo
city
y−coordinate
WAMR Ghia et al.
Comparison with Ghia’s Results for v, Re = 3200
• Midplane predictions of long-time v velocity agree well with Ghia’s
predictions.
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−0.8
−0.6
−0.4
−0.2
0
0.2
0.4
0.6V−velocity along y = 0.5, Re = 3200
V−
velo
city
x−coordinate
WAMR Ghia et al.
Conclusions
• The WAMR method gives dramatic spatial resolution in viscous
one-dimensional H2/O2/Ar detonations with detailed kinetics;
viscous shocks, entropy layers, and induction zones are resolved,
• The ILDM method, coupled appropriate use of full integration,
with operator spitting accurately recovers most results of full
chemistry with decrease (factor of three for our case) in com-
putational time,
• The ILDM method can be made more accurate at roughly the
same computational cost by solving an elliptic equation for ac-
counting for effects of convection and diffusion (ECDC)
• The WAMR method can be extended to multiple dimensions and
can enable extremely detailed and accurate results on a challeng-
ing two-dimensional test problem.
• The extension to three-dimensional compressible reactive flows
within complex geometries is underway.