www.mooseframework.org
PorousFlowRogersStallybrassClements.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 
9 
11 {
12 Real
13 effectiveSaturation(Real pc, Real shift, Real scale)
14 {
15  Real x = (pc - shift) / scale;
16  Real ex = std::exp(x);
17  return std::pow(1.0 + ex, -0.5);
18 }
19 
20 Real
21 dEffectiveSaturation(Real pc, Real shift, Real scale)
22 {
23  Real x = (pc - shift) / scale;
24  Real ex = std::exp(x);
25  return -0.5 * ex * std::pow(1.0 + ex, -1.5) / scale;
26 }
27 
28 Real
29 d2EffectiveSaturation(Real pc, Real shift, Real scale)
30 {
31  Real x = (pc - shift) / scale;
32  Real ex = std::exp(x);
33  return (0.75 * ex * ex * std::pow(1.0 + ex, -2.5) - 0.5 * ex * std::pow(1.0 + ex, -1.5)) / scale /
34  scale;
35 }
36 }
Real dEffectiveSaturation(Real pc, Real shift, Real scale)
Derivative of effective saturation wrt capillary pressure.
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)
Rogers-Stallybrass-Clements version of effective saturation as a function of capillary pressure...
Real d2EffectiveSaturation(Real pc, Real shift, Real scale)
Second derivative of effective saturation wrt capillary pressure.
Real effectiveSaturation(Real pc, Real shift, Real scale)
Effective saturation as a function of capillary pressure.