12#ifndef DUMUX_MATERIAL_FLUIDMATRIX_FRICTIONLAW_HH
13#define DUMUX_MATERIAL_FLUIDMATRIX_FRICTIONLAW_HH
18#include <dune/common/fvector.hh>
29template <
typename VolumeVariables >
32 using Scalar =
typename VolumeVariables::PrimaryVariables::value_type;
45 virtual Dune::FieldVector<Scalar, 2>
bottomShearStress(
const VolumeVariables& volVars)
const = 0;
84 Scalar
limitRoughH(
const Scalar roughnessHeight,
const Scalar waterDepth,
const Scalar eps=1.0e-12)
const
89 if (roughnessHeight < eps)
return 0.0;
92 const Scalar mobilityMax = 1.0;
94 const Scalar minUpperH = roughnessHeight * 2.0;
95 const Scalar sw = clamp(waterDepth * (1.0/minUpperH), 0.0, 1.0);
96 const Scalar
mobility = mobilityMax /(1.0 + (1.0-sw)*(1.0-sw));
97 return roughnessHeight * (1.0 -
mobility);
Implementation of the abstract base class for friction laws.
Definition: frictionlaw.hh:31
virtual ~FrictionLaw()=default
Scalar limitRoughH(const Scalar roughnessHeight, const Scalar waterDepth, const Scalar eps=1.0e-12) const
Limit the friction for small water depth.
Definition: frictionlaw.hh:84
virtual Dune::FieldVector< Scalar, 2 > bottomShearStress(const VolumeVariables &volVars) const =0
Compute the bottom shear stress.
std::string mobility(int phaseIdx) noexcept
I/O name of mobility for multiphase systems.
Definition: name.hh:89