Source-linked AI summary

SWASHES: a compilation of Shallow Water Analytic Solutions for Hydraulic and Environmental Studies

Olivier Delestre, Carine Lucas, Pierre-Antoine Ksinant, Frédéric Darboux, Christian Laguerre, Thi Ngoc Tuoi Vo, Francois James, Stephane Cordier

arXiv:1110.0288v7math.NAmath.APphysics.class-phphysics.flu-dyn

TL;DR

Shallow Water codes require validation, but analytic solutions are scarce and numerical methods must be checked against suitable references. This paper gathers analytic solutions and source codes into the SWASHES software, providing freely available cases for testing numerical schemes, source terms, and boundary conditions.

  • Problem

    Analytic solutions for validating Shallow Water numerical codes are scarce, while code validation is essential for assessing whether models and implementations describe the considered phenomena.

  • Method

    The paper gathers a significant set of analytic solutions, describes them with comments on their use, and provides corresponding source codes through SWASHES.

  • Results

    SWASHES includes the paper’s analytic solutions and freely available source code for testing steady states, source-term treatments, and boundary-condition handling under varied flow conditions.

  • Takeaways & Limitations

    The SWASHES library gives Shallow Water model users an adaptable collection of analytic benchmarks for numerical-method validation.

  • Takeaways & Limitations

    The analytic solutions are obtained numerically, so their spatial step must be smaller than that of the code being validated.

Abstract

from arXiv · show

Numerous codes are being developed to solve Shallow Water equations. Because there are used in hydraulic and environmental studies, their capability to simulate properly flow dynamics is critical to guarantee infrastructure and human safety. While validating these codes is an important issue, code validations are currently restricted because analytic solutions to the Shallow Water equations are rare and have been published on an individual basis over a period of more than five decades. This article aims at making analytic solutions to the Shallow Water equations easily available to code developers and users. It compiles a significant number of analytic solutions to the Shallow Water equations that are currently scattered through the literature of various scientific disciplines. The analytic solutions are described in a unified formalism to make a consistent set of test cases. These analytic solutions encompass a wide variety of flow conditions (supercritical, subcritical, shock, etc.), in 1 or 2 space dimensions, with or without rain and soil friction, for transitory flow or steady state. The corresponding source codes are made available to the community (http://www.univ-orleans.fr/mapmo/soft/SWASHES), so that users of Shallow Water-based models can easily find an adaptable benchmark library to validate their numerical methods.

1 Introduction

Shallow-Water code validation is difficult because realistic equations rarely admit analytic solutions, while published analytic cases are scattered and limited in scope. The paper gathers these solutions in a unified library and provides freely available source code for numerical benchmarking.

  • Realistic Shallow-Water equations generally cannot be solved explicitly, so numerical methods are needed and their implementations must be validated.
  • Validation can combine numerical convergence tests, comparisons with analytic solutions, and experimental data; this paper focuses on analytic-solution comparisons.
  • Published analytic solutions are scattered and individually limited in flow-condition scope, despite collectively covering many conditions.
  • The work compiles analytic solutions, describes them consistently, and releases corresponding SWASHES source code for community use.
  • The paper presents governing-equation properties, analytic solutions, the software, and an illustration using a Shallow-Water code.

2 Equations, notations and properties

The paper formulates viscous two-dimensional and simplified one-dimensional Shallow-Water balance laws with topography, rain, infiltration, viscosity, and friction. It then describes hyperbolicity, flow regimes, critical height, and boundary-condition requirements.

  • The model’s unknowns are water height and the horizontal components of vertically averaged velocity.
  • The balance laws contain mass and momentum equations, with gravity, topography, rain, infiltration, viscosity, and friction represented through source or constitutive terms.
  • Friction is represented using families including Manning-Strickler, Darcy-Weisbach, and Chézy laws, with coefficients tied to soil and flow properties.
  • For positive water height, the transport matrix is diagonalizable and the system is strictly hyperbolic; dry zones lose this property when characteristic velocities coincide.
  • Flows are subcritical when |u| < √gh, supercritical when |u| > √gh, and transcritical when both regimes occur in different regions.
  • Subcritical simulations require one upstream and one downstream value, whereas supercritical inflow requires both variables and supercritical outflow uses free boundary conditions.
  • The Froude number and critical height provide criteria for classifying flow as subcritical or supercritical.

3 Steady state solutions

The steady-state solution family is built from balance relations that connect discharge, topography, and water height. These cases are designed to test steady-state preservation, boundary conditions, and source-term treatment across varied flow settings.

  • Steady-state solutions satisfy a specialized equilibrium system for which the mass equation yields a discharge relation involving rain intensity.
  • The construction chooses either topography and derives water height or water height and deduces the associated topography.
  • The solution family tests preservation of rest and dynamic steady states, boundary-condition handling, and source terms including topography, friction, rain, and diffusion.
  • SWASHES lists the available steady-state solutions and their principal features in Table 1.

3.1 Bumps

The bump cases use steady-state relations to construct flows over flat or varying topography, including resting lakes, subcritical and transcritical regimes, and hydraulic jumps. Together they provide varied tests for numerical treatment of equilibria and transitions.

  • Bump construction: For regular bump solutions without rain, friction, or diffusion, the Bernoulli relation links topography and water height.
  • Bump construction: The cases include subcritical and supercritical regimes, with slope variation and Manning or Darcy-Weisbach friction represented among the listed features.
  • Lakes at rest: Lake-at-rest cases initialize zero velocity with a flat water surface, either fully immersing the bump or leaving part of it emerged.
  • Dynamical steady states: For a subcritical flow, water height is constant over constant topography, changes oppositely with bed slope, and reaches its minimum at the bump crest.
  • Transcritical flow: A transcritical flow can change from fluvial upstream to torrential over the bump, with specified upstream discharge and downstream height conditions.
  • Transcritical flow: When a hydraulic jump occurs, the shock location is determined using a Rankine-Hugoniot relation, and the flow becomes fluvial after the jump.

3.2 Mac Donald’s type 1D solutions

This section constructs Mac Donald type 1D steady solutions by prescribing water height and discharge, then computing compatible topography. The cases cover subcritical, supercritical, transcritical, and hydraulic-jump flows for validating boundary and friction treatments.

  • Construction: Prescribed water-height profiles and discharge values are used to compute corresponding channel topographies from equation (11).An alternative approach starts with topography and discharge, then deduces the steady-state water height.
  • Validation use: The solutions provide more intricate tests of boundary conditions and can assess whether bottom-friction terms preserve steady states.The construction also includes a periodic configuration relevant to overland-flow validation on agricultural fields.
  • Validation use: Because the analytic solutions are obtained by numerical equation resolution, their generating space step must be smaller than the validation code’s space step.This condition is required for sufficiently precise reference solutions.
  • Flow regimes: The transcritical cases transition from subcritical to supercritical flow through a sonic point, or from supercritical to subcritical flow through a hydraulic jump.One hydraulic jump is located at x = 500 m.
  • Flow regimes: A 100 m case combines subcritical and supercritical flow with both a sonic transition and a hydraulic jump at x = 200/3 ≈66.67 m.The flow becomes subcritical again after the shock.

3.3 Mac Donald’s type 1D solutions with rain

This section extends Mac Donald type 1D steady solutions to uniform rainfall, modifying discharge and topography relations. The resulting cases validate numerical treatment of rain in subcritical and supercritical settings.

  • Rain formulation: Uniform rainfall is introduced at steady state without viscosity, with constant intensity R0 and prescribed inflow discharge q0.The rain changes both the discharge relation and the topography expression.
  • Rain formulation: The rain term replaces equation (11) with a modified relation for computing topography.The underlying solutions remain the same as in section 3.2 except for the rainfall-dependent discharge.
  • Validation use: These rainfall solutions support validation of numerical rain treatment.The numerical-resolution space-step requirement from the preceding section also applies.
  • Long-channel case: For the long-channel case, rainfall is recommended to begin after the initial time, using a delayed event with tR = 1500 s.This produces two successive steady states: one with spatially constant discharge q0 and another with rainfall-modified discharge.

3.4 Mac Donald’s type 1D solutions with diffusion

This section presents analytic 1D solutions with a diffusion source term, including subcritical and supercritical flows. The cases are intended to validate diffusion treatment and can be adapted to common friction laws.

  • Diffusion formulation: The diffusion solutions are among the only analytic Shallow-Water solutions available with a diffusion source term.They use source terms involving vertical and horizontal eddy viscosity and laminar and turbulent friction coefficients.
  • Diffusion formulation: Topography is evaluated from the momentum equation of system (15) at steady state.The steady-state formulation uses R = 0 m/s.
  • Validation use: The cases validate numerical treatment of the diffusion source term and can be adapted to Manning’s and Darcy-Weisbach’s friction terms.The numerical-resolution space-step requirement also applies.
  • Example cases: The presented examples include a 1000 m subcritical channel with q = 1.5 m2/s and a 1000 m supercritical channel with q = 2.5 m2/s.The two cases use distinct parameter sets for the diffusion and friction coefficients.

3.5 Mac Donald pseudo-2D solutions

The pseudo-2D section develops analytic cases for variable-width, variable-slope channels represented by width-averaged equations. Six configurations span subcritical, supercritical, smooth transcritical, and hydraulic-jump behavior.

  • Model and geometry: Pseudo-2D equations model flow in a rectilinear three-dimensional channel averaged vertically and across its width.The section treats these equations as intermediate between one-dimensional and two-dimensional models.
  • Model and geometry: The non-prismatic channels have spatially variable bottom width and boundary slope, described using the B1 and B2 channel-shape functions.The cases use rectangular or isosceles-trapezoidal cross sections depending on the configuration.
  • Case coverage: The six cases cover short and long domains with subcritical, supercritical, smooth-transition, and hydraulic-jump regimes.Their parameters include Manning friction with n = 0.03 m-1/3s and discharge q = 20 m3s−1 for the pseudo-2D cases.
  • Short-channel cases: In short rectangular channels with B1 geometry, the flow can remain subcritical, remain supercritical, or transition from subcritical to supercritical.The domain length for these cases is L = 200 m.
  • Short-channel cases: A short-domain case produces supercritical flow that becomes subcritical through a hydraulic jump.The construction prescribes the discharge at inflow and water height at both inflow and outflow.
  • Longer-channel cases: For B2 trapezoidal channels of length L = 400 m, one case stays subcritical while another transitions smoothly to supercritical flow and then returns subcritical through a hydraulic jump.The second configuration combines a smooth transition and a shock in the remaining domain.

4 Transitory solutions

The transitory benchmark set covers dam-break flows of increasing complexity and tests numerical treatment of shocks, wet/dry fronts, and friction effects.

  • Transitory solutions complement steady-state tests by assessing numerical behavior when initial conditions differ from the expected steady state.Many cases include wet/dry transitions, enabling additional checks of numerical treatment.
  • Dam break on a wet domain: Stoker’s solution models an instantaneous dam break on a wet, flat, frictionless domain using the characteristics method.The solution contains a left-going rarefaction and a right-going shock, testing the location of a moving shock.
  • SWASHES specifies benchmark parameters for the dam-break cases, including domain lengths, initial depths, dam locations, and simulation times.For example, Stoker’s case uses hl = 0.005 m, hr = 0.001 m, x0 = 5 m, L = 10 m, and T = 6 s.
  • Dam break on a dry domain: Ritter’s solution models an instantaneous dam break from a constant-height reservoir onto a dry, flat, frictionless domain.Its parabolic free-surface region tests wet/dry-front treatment and preservation of positive water height.
  • Dam break with friction: Dressler’s solution extends the dry-domain dam-break case with Chézy friction using a perturbation expansion in the friction coefficient.The approach divides the flow into steady, corrected, tip, and dry regions, but does not modify water height in the tip zone.

4.2 Oscillations

The oscillation benchmarks represent moving wet/dry boundaries over variable topographies, with frictionless periodic Thacker cases and a damped Sampson case.

  • Thacker’s and Sampson’s solutions test moving wet/dry transitions over variable slopes for tsunami run-up and ocean-flow numerical simulations.Thacker’s solutions omit the Coriolis effect; the one-dimensional topography is parabolic and the two-dimensional topography is paraboloidal.
  • Planar surface in a parabola without friction: The one-dimensional Thacker benchmark simplifies an artificially two-dimensional solution to an infinite channel with a parabolic cross section and one nonzero velocity component.It combines a sloping bed with wetting and drying.
  • Planar surface in a parabola without friction: Thacker’s one-dimensional solution is periodic without friction, retains a planar free surface, and tracks wet/dry interfaces at x1(t) and x2(t).Its periodic height variation also tests numerical diffusion and repeated wetting and drying.
  • Two dimensional cases: The two-dimensional Thacker cases provide periodic moving-boundary solutions on paraboloids, including radially symmetrical and planar-surface configurations.The radially symmetrical case is an undamped oscillating paraboloid, while the planar-surface case has a circular moving shoreline.
  • Sampson’s one-dimensional solution adds linear friction to Thacker’s approach, producing moving boundaries with damping while retaining a planar free surface.The velocity includes exponential decay and the wet/dry transitions remain located at x1(t) and x2(t).

5 The SWASHES software

SWASHES packages the paper’s analytic solutions as freely available, extensible C++ software for generating discretized benchmark cases.

  • SWASHES includes all analytic solutions presented in the paper and distributes their source code freely under the CeCILL-V2 license.The repository is hosted at the URL specified by the authors.
  • Users select the solution, dimension, type, domain, solution number, and discretization cell count from the command line.The computed solution can be redirected to a gnuplot-compatible ASCII file.
  • The object-oriented ISO C++ structure assigns solution types to specific classes and supports adding new solutions within existing or new classes.Solution parameters are coded explicitly, while the number of cells is user-specified.
  • The library is intended to let developers evaluate code performance and properties by selecting benchmark subsets suited to their target applications.The authors recommend retaining default parameters for comparisons, while allowing modified cases to be renamed.

6 Some numerical results: comparison with FullSWOF approximate solutions

The FullSWOF comparisons show generally close agreement with analytic solutions across one- and two-dimensional test cases, while localized errors remain near shocks and wet-dry transitions. The results also demonstrate conservation and physically appropriate dry-surface behavior in selected benchmarks.

  • Numerical method: FullSWOF uses finite volumes on structured meshes with hydrostatic reconstruction to conserve mass, preserve positivity, and maintain hydrostatic equilibria.The method supports one-dimensional simulations and extends to two dimensions.
  • One-dimensional results: For transcritical flow with shock, FullSWOF agrees closely overall, with differences from -0.001% before the bump to +1.2% at the bump and localized smearing at the shock.The analytic shock is sharp, whereas the numerical shock spans four cells; the maximum difference at the shock is +100% on one cell.
  • One-dimensional results: In the short-domain smooth-transition case, errors remain below -0.5% before the shock, reach +24% at the shock, and decline to 0% at the outlet.The numerical solution underestimates before and after the subcritical-to-supercritical transition, then overestimates around the shock.
  • One-dimensional results: For the dry-domain dam break, FullSWOF moves slightly too slowly but correctly keeps dry areas at zero height without spurious wet-dry points.The numerical water front is predicted earlier than the analytic front, with a dry surface for x > 7.3 m versus x = 7.6 m analytically.
  • Two-dimensional results: In the planar-surface two-dimensional case, errors range from -1.55 × 10^-3 m to +7.65 × 10^-4 m for a maximum water height of 0.1 m.At the wet-dry transition, overestimation reaches +43% locally, while another transition produces -97% where the analytic height is only 1.6 × 10^-3 m.
  • Two-dimensional results: The pseudo-two-dimensional cases show larger localized discrepancies: FullSWOF underestimates by up to -11.85% in one case and -8.8% in another, while overestimation reaches +4.1% downstream.These comparisons retain the overall free-surface shape in the second case despite underestimation over most of the domain.
Loading 1110.0288v7…