Graphics Reference
In-Depth Information
Combining that with the free surface boundary condition p =0at y = h
gives
p ( x, y, z, t )= ρg ( h ( x, z, t )
y ) .
(12.1)
Again, this isn't strictly true if the water is moving, but it's a good ap-
proximation. The fact that we can directly write down the pressure in the
shallow water case, as opposed to solving a big linear system for pressure
as we had to in fully three-dimensional flow, is one of the key speed-ups.
12.1.2 Velocity
Assuming that u and w are constant along y means ∂u/∂y = ∂w/∂y =0,
which means the horizontal parts of the momentum equation are reduced
to
∂u
∂t + u ∂u
∂x + w ∂u
∂z + 1
∂p
∂x =0 ,
ρ
∂p
∂z =0 .
This is just two-dimensional advection along with the horizontal parts of
the pressure gradient. Note that although pressure varies linearly in y ,the
horizontal components of its gradient are in fact constant in y ; substituting
in Equation (12.1) gives
∂w
∂t
+ u ∂w
∂x + w ∂w
+ 1
ρ
∂z
∂u
∂t + u ∂u
∂x + w ∂u
∂z + g ∂h
∂x =0 ,
(12.2)
∂w
∂t
+ u ∂w
∂x + w ∂w
+ g ∂h
∂z
=0 .
∂z
That is, the horizontal velocity components are advected in the plane as
usual, with an additional acceleration proportional to gravity that pulls
water down from higher regions to lower regions.
What about vertical velocity v ? It turns out this is fully determined
from the “primary” shallow water variables ( u , w and d ) that we will be
simulating. We won't actually need v in the simulation (unless for some
reason you need to evaluate it for, say, particle advection in the flow) but
it will come in handy to figure out how the surface height evolves in a
moment.
First take a look at the incompressibility condition:
∂u
∂x + ∂v
∂y + ∂w
= 0
(12.3)
∂z
∂v
∂y =
∂u
∂x
∂w
∂z .
(12.4)
Search WWH ::




Custom Search