diff --git a/dumux/material/fluidmatrixinteractions/2p/brookscorey.hh b/dumux/material/fluidmatrixinteractions/2p/brookscorey.hh index 404b080c6069eaaf75545211154123aa6e271cb7..fc04aac05ce8a3e6936f8c0b00bd0f0bd45338b0 100644 --- a/dumux/material/fluidmatrixinteractions/2p/brookscorey.hh +++ b/dumux/material/fluidmatrixinteractions/2p/brookscorey.hh @@ -269,8 +269,10 @@ public: swe = min(max(swe, 0.0), 1.0); // the equation below is only defined for 0.0 <= sw <= 1.0 - return 2.0*(swe - 1)*(1 + (0.5 + 1/params.lambda())*pow(swe, 2.0/params.lambda()) - - (3.0/2.0 + 1/params.lambda())*pow(swe, 2.0/params.lambda()+1)); + const auto lambdaInv = 1.0/params.lambda(); + const auto swePow = pow(swe, 2*lambdaInv); + return 2*(swe - 1.0)*(1.0 + (0.5 + lambdaInv)*swePow - (1.5 + lambdaInv)*swePow*swe); + } };