Shallow water
description
Transcript of Shallow water
-
Finite Volume Method for Shallow WaterEquations
Oto Havle, Jir Felcman
Workshop Dresden-Prague on Numerical Analysis 2008
-
Contents
Shallow water equations
SWE without source term
SWE with topographic source term
Conclusion
-
Shallow water equationsA system of PDEs
ht
+ div(hv) = 0,
t(hvs) + div(hvsv) +
12
g
xsh2 = gh z
xs, s = 1,2.
z ... given function, g > 0 ... given constant
z
h v
-
Shallow water equations - a hyperbolic system
wt
+2
i=1
xif i(w) = r(x ,w)
where
w (
hq
)(
hhv
)
hhv1hv2
f 1(w) =
q1h1q21 + 12gh2h1q1q2
= hv1hv21 + 12gh2
hv1v2
f 2(w) =
q2h1q1q2h1q22 +
12gh
2
= hv2hv1v2
hv22 +12gh
2
r(x ,w) =
(0
ghz(x)
)
-
Shallow water equations - a hyperbolic system
Difficulties with Shallow Water EquationsI existence / uniqueness theorems not availableI dry areas - SWEs do not have sense for h = 0I source term
-
Shallow water equations - a hyperbolic system
Flat bottom case z = const .I system of conservation laws
I standard FVM discretizationI we need a numerical flux
wt
+2
s=1
xsf s(w) = 0
-
Shallow water equations - a hyperbolic system
Flat bottom case z = const .I system of conservation lawsI standard FVM discretization
I we need a numerical flux
Di
w(x , tk+1) dx
Diw(x , tk ) dx
+
tk+1tk
Di
2i=1
ni f i(w) H(w |Di ,w |Dj ,nij )
dS = 0
-
Shallow water equations - a hyperbolic system
Flat bottom case z = const .I system of conservation lawsI standard FVM discretizationI we need a numerical flux
wki w on the cell Diand time interval (tk , tk+1)
wk+1i = wki
k
|Di |
jS(i)
|ij |H(wki ,wkj ,nij)
-
Numerical flux
How to derive a numerical flux H(wL,wR,n)I Choose a new coordinate system such that n = (1,0).I Linearize and solve a linear 1D Riemann problem.
wt
+ Awx1
= 0
w(x1, t = 0) =
{wL, x1 < 0wR, x1 > 0
I Take the linear flux Aw at x1 = 0 and rewrite in the originalcoordinate system.
-
How to linearize the Riemann problem
We adapt the Vijayasundaram flux,
gV (wL,wR) = A+(w?)wL + A(w?)wR (?)
where w? =wL + wR
2A1(w) = D f 1(w)
As A1(w)w 6= f 1(w), the 1D flux (?) is not consistent with theShallow Water Equations. We fix it with additional term
gV1(wL,wR) = A+(w?)wL + A(w?)wR
12
gh2??
010
where h?? =
hL + hR2
-
SWE with no source term - Numerical resultsElementary Riemann problems in 1D
I continuous solution (rarefaction wave) - EOC 0.75I discontinuous solution (contact discontinuity) - EOC 0.5
2D test problem - circular dam break
-200 -150 -100 -50 0 50 100 150 200-200-150
-100-50
0 50
100 150
200
0 1 2 3 4 5 6 7 8 9
10
-200 -150 -100 -50 0 50 100 150 200-200-150
-100-50
0 50
100 150
200
0
1
2
3
4
5
6
-
Source term - stationary solution
Shallow water equations
ht
+ div(hv) = 0,
t(hvs) + div(hvsv) +
12
g
xsh2 = gh z
xs, s = 1,2.
Stationary solution (lake at rest)
h(x , t) = H0 z(x), v(x , t) = 0.
Discrete stationary solution
wki =
H0 zi00
, zi zDi
-
Discretization of source terms
Rewrite to a system of conservation laws with a nonzero RHS
wt
+2
s=1
xsf s(w) = r(x ,w)
Operator splitting
wt
+2
s=1
xsf s(w) = 0
wt
+ 0 = r(x ,w)
would not work. Stationary solutions are different.
-
Discretization of source terms
Difficulty with the source termI We use a piecewise-constant approximation of the
topography function z.
hi = H0 zi
The source term is now a distribution.
r(x ,w) =(
0ghz(x)
)I Source term must be taken into account when
approximating convective term.
-
Linearised Riemann problem with a source termWe construct a linear Riemann problem with nonzero RHS
wt
+ Awx
= (x)r , t > 0
w(x ,0) =
{wL, x < 0wR, x > 0
The matrix A is the same as before
A = A1(w?) = Df 1(w?) w? =12(wL + wR)
The right hand side has special form
r =
0gh?(zL zR)0
-
Linear Riemann problem with a source term
To solve the Riemann problemI Use diagonal form A = UU1 to decouple equations.
I Use characteristics to solve scalar problems.I The solution is a function, unless v1 = c.I For the purposes of deriving a numerical flux, ignore the
distributional case.
ut
+ ux
= (x), t > 0
u(x ,0) = u0(x)
-
Linear Riemann problem with a source term
To solve the Riemann problemI Use diagonal form A = UU1 to decouple equations.I Use characteristics to solve scalar problems.
I The solution is a function, unless v1 = c.I For the purposes of deriving a numerical flux, ignore the
distributional case.
= 0 = u(x , t) = u0(x) + t(x),
6= 0 = u(x , t) = u0(x t) +
||K(x , t),
where K(x , t) =
{1, x(x t) < 0,0, x(x t) 0.
-
Linear Riemann problem with a source term
To solve the Riemann problemI Use diagonal form A = UU1 to decouple equations.I Use characteristics to solve scalar problems.I The solution is a function, unless v1 = c.
I For the purposes of deriving a numerical flux, ignore thedistributional case.
|v | < c ... subcritical|v | = c ... critical|v | > c ... supercritical
c =
gh
w =
hhv1hv2
-
Linear Riemann problem with a source term
To solve the Riemann problemI Use diagonal form A = UU1 to decouple equations.I Use characteristics to solve scalar problems.I The solution is a function, unless v1 = c.I For the purposes of deriving a numerical flux, ignore the
distributional case.
The linear flux Aw at x = 0 is
A(12
limx0+
w(x , t) +12
limx0
w(x , t))
= A+wL + AwR +12(sgnA)r?.
-
New numerical fluxThe numerical flux (discretization of convective term)
gconv (wL,wR, zL, zR)
= A+1 (w?)wL + A1 (w?)wR
12
gh2??e2
12
gh?(zR zL)(sgnA1)e2
In fact, the numerical flux does not depend on sgn2.
1 = v1 c, 2 = v1, 3 = v1 + c, c =
gh
Therefore, it is continuous in the subcritical case |v | < c,
sgnA1(w?)e2 =
1/cv1/cv2/c
.
-
Discretizing the source term
We discretize the source term proper
Di
tk+1tk
r(x ,w(x , t)) dx dt ghiDi
tk+1tk
(0
z(x)
)dx dt
= kghiDi
z(x)(0nij
)dS
kghi
jS(i)
|ij |z?ij nij
where z?ij =zi + zj
2is an approximation to z at the interface ij .
-
The numerical scheme
Both convective and source have a quasi-flux form
k
jS(i)
|ij |(. . . )
We can write
wk+1i = wki
k
|Di |
jS(i)
|ij |H total(
wki ,wkj , zi , zj ,nij
)Theoretical properties
I The scheme is conservative with respect to h.I The discrete "lake at rest" is a stationary solution.
-
Numerical resultsThe scheme seems to work in the subcritical case |v | < c, butnot in the supercritical case. It gets better if we replace
h?? =hL + hR
2
with
h?? =
hR, < 1,
1+2 h
2L +
12 h
2R, 1 < < 1,
hL, > 1,
=v1,?c?
gconv (wL,wR, zL, zR)
= A+1 (w?)wL + A1 (w?)wR
12
gh2??e2
12
gh?(zR zL)(sgnA1)e2
-
Summary
Numerical scheme for Shallow Water Equations.I Simple first order Finite Volume scheme.I Handles topographic source term.
Future workI Enhance with mesh adaptivity.I Investigate the case h = 0.
Thank you for your attention.
-
Summary
Numerical scheme for Shallow Water Equations.I Simple first order Finite Volume scheme.I Handles topographic source term.
Future workI Enhance with mesh adaptivity.I Investigate the case h = 0.
Thank you for your attention.
Shallow water equationsSWE without source termSWE with topographic source termConclusion