Shallow water turbulent diffusion wrong mobility
Problem description:
The computation of the momentum exchange in ShallowWaterViscousFlux
is wrong for "waterfall" cases when no direct water to water connection exists at the interface there should be no transport/flux of momentum.
Explanation:
In the actual code the flux is computed as:
uViscousFlux = turbViscosity * averageDepth * gradU;
vViscousFlux = turbViscosity * averageDepth * gradV;
With averageDepth
as harmonic average between the water depths from the left/right side. Later the momentum flux is limited by a mobility (depending on water depths). For the ShallowWaterFlux
the same mobility term is applied to limit the water flux, but not the momentum flux. For the ShallowWaterFlux
the limiting works since the water depth is taken based on the hydrostatic reconstruction.
Possible fix:
Instead of averageDepth
the connected water surface:
h_{interface} = max[min(z_{left} + h_{left}, z_{right} + h_{right}) - max(z_{left},z_{right}), 0.0]
can be used. No limiting will be needed.