13#ifndef DUMUX_MATERIAL_FLUIDMATRIX_FRICTIONLAW_HH 
   14#define DUMUX_MATERIAL_FLUIDMATRIX_FRICTIONLAW_HH 
   19#include <dune/common/fvector.hh> 
   35template <
typename VolumeVariables >
 
   38    using Scalar = 
typename VolumeVariables::PrimaryVariables::value_type;
 
   51    virtual Dune::FieldVector<Scalar, 2> 
bottomShearStress(
const VolumeVariables& volVars) 
const = 0;
 
   90    Scalar 
limitRoughH(
const Scalar roughnessHeight, 
const Scalar waterDepth, 
const Scalar eps=1.0e-12)
 const 
   95        if (roughnessHeight < eps) 
return 0.0;
 
   98        const Scalar mobilityMax = 1.0; 
 
  100        const Scalar minUpperH = roughnessHeight * 2.0;
 
  101        const Scalar sw = clamp(waterDepth * (1.0/minUpperH), 0.0, 1.0);
 
  102        const Scalar mobility = mobilityMax /(1.0 + (1.0-sw)*(1.0-sw));
 
  103        return roughnessHeight * (1.0 - mobility);
 
 
 
Implementation of the abstract base class for friction laws.
Definition frictionlaw.hh:37
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:90
virtual Dune::FieldVector< Scalar, 2 > bottomShearStress(const VolumeVariables &volVars) const =0
Compute the bottom shear stress.