www.mooseframework.org
Public Member Functions | Protected Attributes | List of all members
RichardsRelPermPowerGas Class Reference

PowerGas form of relative permeability Define s = (seff - simm)/(1 - simm). More...

#include <RichardsRelPermPowerGas.h>

Inheritance diagram for RichardsRelPermPowerGas:
[legend]

Public Member Functions

 RichardsRelPermPowerGas (const InputParameters &parameters)
 
Real relperm (Real seff) const
 Relative permeability. More...
 
Real drelperm (Real seff) const
 Derivative of relative permeability wrt seff. More...
 
Real d2relperm (Real seff) const
 Second derivative of relative permeability wrt seff. More...
 
void initialize ()
 
void execute ()
 
void finalize ()
 

Protected Attributes

Real _simm
 immobile saturation More...
 
Real _n
 exponent More...
 

Detailed Description

PowerGas form of relative permeability Define s = (seff - simm)/(1 - simm).

Then relperm = 1 - (n+1)(1-s)^n + n(1-s)^(n+1) if s<simm, otherwise relperm=1

Definition at line 25 of file RichardsRelPermPowerGas.h.

Constructor & Destructor Documentation

◆ RichardsRelPermPowerGas()

RichardsRelPermPowerGas::RichardsRelPermPowerGas ( const InputParameters &  parameters)

Definition at line 38 of file RichardsRelPermPowerGas.C.

39  : RichardsRelPerm(parameters), _simm(getParam<Real>("simm")), _n(getParam<Real>("n"))
40 {
41 }
RichardsRelPerm(const InputParameters &parameters)
Real _simm
immobile saturation

Member Function Documentation

◆ d2relperm()

Real RichardsRelPermPowerGas::d2relperm ( Real  seff) const
virtual

Second derivative of relative permeability wrt seff.

Parameters
seffeffective saturation

Implements RichardsRelPerm.

Definition at line 83 of file RichardsRelPermPowerGas.C.

84 {
85  if (seff >= 1.0)
86  return 0.0;
87 
88  if (seff <= _simm)
89  return 0.0;
90 
91  Real s_internal = (seff - _simm) / (1.0 - _simm);
92  Real krelpp = -(_n + 1) * _n * (_n - 1) * std::pow(1 - s_internal, _n - 2) +
93  _n * (_n + 1) * _n * std::pow(1 - s_internal, _n - 1);
94  return krelpp / std::pow(1.0 - _simm, 2);
95 }
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)
Real _simm
immobile saturation

◆ drelperm()

Real RichardsRelPermPowerGas::drelperm ( Real  seff) const
virtual

Derivative of relative permeability wrt seff.

Parameters
seffeffective saturation

Implements RichardsRelPerm.

Definition at line 68 of file RichardsRelPermPowerGas.C.

69 {
70  if (seff >= 1.0)
71  return 0.0;
72 
73  if (seff <= _simm)
74  return 0.0;
75 
76  Real s_internal = (seff - _simm) / (1.0 - _simm);
77  Real krelp = (_n + 1) * _n * std::pow(1 - s_internal, _n - 1) -
78  _n * (_n + 1) * std::pow(1 - s_internal, _n);
79  return krelp / (1.0 - _simm);
80 }
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)
Real _simm
immobile saturation

◆ execute()

void RichardsRelPerm::execute ( )
inherited

Definition at line 34 of file RichardsRelPerm.C.

35 {
36 }

◆ finalize()

void RichardsRelPerm::finalize ( )
inherited

Definition at line 39 of file RichardsRelPerm.C.

40 {
41 }

◆ initialize()

void RichardsRelPerm::initialize ( )
inherited

Definition at line 29 of file RichardsRelPerm.C.

30 {
31 }

◆ relperm()

Real RichardsRelPermPowerGas::relperm ( Real  seff) const
virtual

Relative permeability.

Parameters
seffeffective saturation

Implements RichardsRelPerm.

Definition at line 44 of file RichardsRelPermPowerGas.C.

45 {
46  if (seff >= 1.0)
47  return 1.0;
48 
49  if (seff <= _simm)
50  return 0.0;
51 
52  Real s_internal = (seff - _simm) / (1.0 - _simm);
53  Real krel = 1 - (_n + 1) * std::pow(1 - s_internal, _n) + _n * std::pow(1 - s_internal, _n + 1);
54 
55  // bound, just in case
56  if (krel < 0)
57  {
58  krel = 0;
59  }
60  if (krel > 1)
61  {
62  krel = 1;
63  }
64  return krel;
65 }
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)
Real _simm
immobile saturation

Member Data Documentation

◆ _n

Real RichardsRelPermPowerGas::_n
protected

exponent

Definition at line 53 of file RichardsRelPermPowerGas.h.

Referenced by d2relperm(), drelperm(), and relperm().

◆ _simm

Real RichardsRelPermPowerGas::_simm
protected

immobile saturation

Definition at line 50 of file RichardsRelPermPowerGas.h.

Referenced by d2relperm(), drelperm(), and relperm().


The documentation for this class was generated from the following files: