From d2916f60d3263d4a321b85e9edb8bf6f9f106f16 Mon Sep 17 00:00:00 2001 From: "leopold.stadler" Date: Wed, 2 Sep 2020 13:55:12 +0200 Subject: [PATCH 1/4] [flux][shallowwater] doc shallow water flux Add the units of the water flux and momentum fluxes in the documentation. --- dumux/flux/shallowwater/exactriemann.hh | 3 +++ dumux/flux/shallowwater/riemannproblem.hh | 3 +++ dumux/flux/shallowwaterflux.hh | 5 +++++ 3 files changed, 11 insertions(+) diff --git a/dumux/flux/shallowwater/exactriemann.hh b/dumux/flux/shallowwater/exactriemann.hh index c2c4fd8237..501cbfbcef 100644 --- a/dumux/flux/shallowwater/exactriemann.hh +++ b/dumux/flux/shallowwater/exactriemann.hh @@ -43,6 +43,9 @@ struct RiemannSolution { * \ingroup ShallowWaterFlux * \brief Exact Riemann solver for Shallow water equations. * + * The computed water flux is given in m^2/s, the momentum + * fluxes are given in m^3/s^2. + * * This Riemann solver is described in the book * "Shock-capturing methods for free-surface shallow flows" * from Toro, 2001. We keep the notation for the variables diff --git a/dumux/flux/shallowwater/riemannproblem.hh b/dumux/flux/shallowwater/riemannproblem.hh index 2d7b514ef3..96ff91d1b1 100644 --- a/dumux/flux/shallowwater/riemannproblem.hh +++ b/dumux/flux/shallowwater/riemannproblem.hh @@ -51,6 +51,9 @@ namespace ShallowWater { * after Audusse but further solvers and reconstructions ca be * implemented. * + * The computed water flux (localFlux[0]) is given in m^2/s, the + * momentum fluxes (localFlux[1], localFlux[2]) are given in m^3/s^2. + * * \param waterDepthLeft water depth on the left side * \param waterDepthRight water depth on the right side * \param velocityXLeft veloctiyX on the left side diff --git a/dumux/flux/shallowwaterflux.hh b/dumux/flux/shallowwaterflux.hh index 179b9709aa..af23f08c55 100644 --- a/dumux/flux/shallowwaterflux.hh +++ b/dumux/flux/shallowwaterflux.hh @@ -49,6 +49,11 @@ public: * Riemann solver after Torro and the reconstruction after * Audusse and a flux limiter for small water depths. * + * The computed water flux of the Riemann solver is given + * in m^2/s, the momentum fluxes are given in m^3/s^2. The + * Riemann flux is mltiplied by scv.area() to get the flux + * over the face. + * * \todo The choice of the Riemann solver should be more flexible */ template -- GitLab From ae5864168592fc616f95d1fb16f76128c78142ff Mon Sep 17 00:00:00 2001 From: "leopold.stadler" Date: Wed, 2 Sep 2020 14:00:42 +0200 Subject: [PATCH 2/4] [flux][shallowwater] fix typo --- dumux/flux/shallowwaterflux.hh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dumux/flux/shallowwaterflux.hh b/dumux/flux/shallowwaterflux.hh index af23f08c55..671d5e575b 100644 --- a/dumux/flux/shallowwaterflux.hh +++ b/dumux/flux/shallowwaterflux.hh @@ -51,8 +51,8 @@ public: * * The computed water flux of the Riemann solver is given * in m^2/s, the momentum fluxes are given in m^3/s^2. The - * Riemann flux is mltiplied by scv.area() to get the flux - * over the face. + * Riemann flux is multiplied by scvf.area() to get the + * flux over the face. * * \todo The choice of the Riemann solver should be more flexible */ -- GitLab From 9fc651ccb2ca70cdd31742219c973bef64947047 Mon Sep 17 00:00:00 2001 From: "leopold.stadler" Date: Fri, 4 Sep 2020 11:34:49 +0200 Subject: [PATCH 3/4] [flux][shallowwater] add comments for 2D only flux and scvf.area() Added some hints to explain that the shallow water Riemann problem works in 2D only. The exact Riemann solver is 1D only and the problem is rotated. The scvf.area() is given in m. --- dumux/flux/shallowwater/exactriemann.hh | 4 +++- dumux/flux/shallowwater/riemannproblem.hh | 8 +++++--- dumux/flux/shallowwaterflux.hh | 12 ++++++------ 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/dumux/flux/shallowwater/exactriemann.hh b/dumux/flux/shallowwater/exactriemann.hh index 501cbfbcef..675c5ec689 100644 --- a/dumux/flux/shallowwater/exactriemann.hh +++ b/dumux/flux/shallowwater/exactriemann.hh @@ -41,8 +41,10 @@ struct RiemannSolution { /*! * \ingroup ShallowWaterFlux - * \brief Exact Riemann solver for Shallow water equations. + * \brief Exact Riemann solver for the shallow water equations. * + * The flux of the 2D shallow water euqations must be rotated + * to a 1D problem before the Riemann solver can be applied. * The computed water flux is given in m^2/s, the momentum * fluxes are given in m^3/s^2. * diff --git a/dumux/flux/shallowwater/riemannproblem.hh b/dumux/flux/shallowwater/riemannproblem.hh index 96ff91d1b1..cfb43ca694 100644 --- a/dumux/flux/shallowwater/riemannproblem.hh +++ b/dumux/flux/shallowwater/riemannproblem.hh @@ -34,15 +34,15 @@ namespace ShallowWater { /*! * \ingroup ShallowWaterFlux - * \brief Construct Riemann Problem and solve it + * \brief Construct a Riemann problem and solve it * * - * Riemann Problem applies the hydrostatic reconstruction, uses the + * Riemann problem applies the hydrostatic reconstruction, uses the * Riemann invariants to transform the two-dimensional problem to an * one-dimensional problem and solves this new problem, and rotates * the problem back. Further it applies an flux limiter for the water * flux handle drying of elements. - * The correction of the bed slope surce terme leads to an + * The correction of the bed slope surce term leads to an * non-symetric flux term at the interface for the momentum equations * since DuMuX computes the fluxes twice from each side this does not * matter. @@ -53,6 +53,8 @@ namespace ShallowWater { * * The computed water flux (localFlux[0]) is given in m^2/s, the * momentum fluxes (localFlux[1], localFlux[2]) are given in m^3/s^2. + * Later this flux will be multiplied by the scvf.area() (given in m + * for a 2D problem) to get the flux over a face. * * \param waterDepthLeft water depth on the left side * \param waterDepthRight water depth on the right side diff --git a/dumux/flux/shallowwaterflux.hh b/dumux/flux/shallowwaterflux.hh index 671d5e575b..e1e89fd968 100644 --- a/dumux/flux/shallowwaterflux.hh +++ b/dumux/flux/shallowwaterflux.hh @@ -44,15 +44,15 @@ public: /*! * \ingroup Flux - * \brief Prepares the riemann problem for the advective flux for - * the shallow water model. The actual model uses an exact - * Riemann solver after Torro and the reconstruction after - * Audusse and a flux limiter for small water depths. + * \brief Prepares the Riemann problem for the advective flux for + * the 2D shallow water model. The actual model uses an + * exact Riemann solver after Torro and the reconstruction + * after Audusse and a flux limiter for small water depths. * * The computed water flux of the Riemann solver is given * in m^2/s, the momentum fluxes are given in m^3/s^2. The - * Riemann flux is multiplied by scvf.area() to get the - * flux over the face. + * Riemann flux is multiplied by scvf.area() (given in m + * for a 2D domain) to get the flux over the face. * * \todo The choice of the Riemann solver should be more flexible */ -- GitLab From 0271053f90388a28a10991932c1c31ec1a0bab3b Mon Sep 17 00:00:00 2001 From: "leopold.stadler" Date: Fri, 4 Sep 2020 15:16:47 +0200 Subject: [PATCH 4/4] [flux][shallowwater] fix typos --- dumux/flux/shallowwater/exactriemann.hh | 2 +- dumux/flux/shallowwater/riemannproblem.hh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dumux/flux/shallowwater/exactriemann.hh b/dumux/flux/shallowwater/exactriemann.hh index 675c5ec689..e088351d85 100644 --- a/dumux/flux/shallowwater/exactriemann.hh +++ b/dumux/flux/shallowwater/exactriemann.hh @@ -43,7 +43,7 @@ struct RiemannSolution { * \ingroup ShallowWaterFlux * \brief Exact Riemann solver for the shallow water equations. * - * The flux of the 2D shallow water euqations must be rotated + * The flux of the 2D shallow water equations must be rotated * to a 1D problem before the Riemann solver can be applied. * The computed water flux is given in m^2/s, the momentum * fluxes are given in m^3/s^2. diff --git a/dumux/flux/shallowwater/riemannproblem.hh b/dumux/flux/shallowwater/riemannproblem.hh index cfb43ca694..5c3b839150 100644 --- a/dumux/flux/shallowwater/riemannproblem.hh +++ b/dumux/flux/shallowwater/riemannproblem.hh @@ -42,8 +42,8 @@ namespace ShallowWater { * one-dimensional problem and solves this new problem, and rotates * the problem back. Further it applies an flux limiter for the water * flux handle drying of elements. - * The correction of the bed slope surce term leads to an - * non-symetric flux term at the interface for the momentum equations + * The correction of the bed slope source term leads to a + * non-symmetric flux term at the interface for the momentum equations * since DuMuX computes the fluxes twice from each side this does not * matter. * -- GitLab