From 6f320a7095b053a8de0a2adf674451fae7bd7f8f Mon Sep 17 00:00:00 2001 From: Timo Koch <timo.koch@iws.uni-stuttgart.de> Date: Thu, 29 Aug 2019 13:50:04 +0200 Subject: [PATCH] [vangenuchten] Improve doc --- .../2p/regularizedvangenuchten.hh | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/dumux/material/fluidmatrixinteractions/2p/regularizedvangenuchten.hh b/dumux/material/fluidmatrixinteractions/2p/regularizedvangenuchten.hh index aabd80b080..aef75f69d2 100644 --- a/dumux/material/fluidmatrixinteractions/2p/regularizedvangenuchten.hh +++ b/dumux/material/fluidmatrixinteractions/2p/regularizedvangenuchten.hh @@ -356,15 +356,14 @@ public: // phase from the parameters const Scalar swThHigh = params.krwHighSw(); - // derivative of the regualarization - if (swe < 0) { - // the slope is zero + // derivative of the regularization + // the slope is zero below sw=0.0 and above sw=1.0 + if (swe < 0) return 0.0; - } - else if (swe > 1 - std::numeric_limits<Scalar>::epsilon()) { - // the slope is zero + else if (swe > 1 - std::numeric_limits<Scalar>::epsilon()) return 0.0; - } + + // for high sw we need the slope of the interpolation spline else if (swe > swThHigh) { using Spline = Dumux::Spline<Scalar>; Spline sp(swThHigh, 1.0, // x1, x2 -- GitLab