Commit 5e2dd340 authored by Bernd Flemisch's avatar Bernd Flemisch
Browse files

cleaned up documentation

git-svn-id: svn://svn.iws.uni-stuttgart.de/DUMUX/dumux/trunk@4668 2fb0f335-1f38-0410-981e-8018bf24f1b0
parent e6b54145
......@@ -92,7 +92,7 @@
Universit\"at Stuttgart, Paffenwaldring 61, D-70569 Stuttgart, Germany}\\
%
\bigskip
{\normalsize \texttt{\url{http://www.dumux.uni-stuttgart.de}}}\\
{\normalsize \texttt{\url{http://dumux.org}}}\\
}
\makeindex
......
......@@ -287,7 +287,7 @@ namespace Properties
* \brief Access the 'value' attribute of a property for a type tag.
*
* This is just for convenience and equivalent to GET_PROP(TypeTag,
* PropTag)::value. If the property doesn't have an attribute named
* PropTag) :: value. If the property doesn't have an attribute named
* 'value', this yields a compiler error.
*/
#define GET_PROP_VALUE(TypeTag, PropTag) \
......@@ -297,7 +297,7 @@ namespace Properties
* \brief Access the 'type' attribute of a property for a type tag.
*
* This is just for convenience and equivalent to GET_PROP(TypeTag,
* PropTag)::type. If the property doesn't have an attribute named
* PropTag) :: type. If the property doesn't have an attribute named
* 'type', this yields a compiler error. Also, if you use this macro
* within a template, it must be preceeded by the 'typename' keyword.
*/
......
......@@ -142,16 +142,16 @@ public:
* the medium implied by the Brooks-Corey
* parameterization.
*
* \param Sw The mobile saturation of the wetting phase.
* \param Swe effective saturation of the wetting phase.
* \param params A container object that is populated with the appropriate coefficients for the respective law.
* Therefore, in the (problem specific) spatialParameters first, the material law is chosen, and then the params container
* is constructed accordingly. Afterwards the values are set there, too.
*/
static Scalar krw(const Params &params, Scalar Sw)
static Scalar krw(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
assert(0 <= Swe && Swe <= 1);
return pow(Sw, 2.0/params.alpha() + 3);
return pow(Swe, 2.0/params.alpha() + 3);
};
/*!
......@@ -159,16 +159,16 @@ public:
* wetting phase with regard to the wetting saturation of the
* medium implied by the Brooks-Corey parameterization.
*
* \param Sw The mobile saturation of the wetting phase.
* \param Swe effective saturation of the wetting phase.
* \param params A container object that is populated with the appropriate coefficients for the respective law.
* Therefore, in the (problem specific) spatialParameters first, the material law is chosen, and then the params container
* is constructed accordingly. Afterwards the values are set there, too.
*/
static Scalar dkrw_dSw(const Params &params, Scalar Sw)
static Scalar dkrw_dSw(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
assert(0 <= Swe && Swe <= 1);
return (2.0/params.alpha() + 3)*pow(Sw, 2.0/params.alpha() + 2);
return (2.0/params.alpha() + 3)*pow(Swe, 2.0/params.alpha() + 2);
};
/*!
......@@ -176,18 +176,18 @@ public:
* the medium as implied by the Brooks-Corey
* parameterization.
*
* \param Sw The mobile saturation of the wetting phase.
* \param Swe effective saturation of the wetting phase.
* \param params A container object that is populated with the appropriate coefficients for the respective law.
* Therefore, in the (problem specific) spatialParameters first, the material law is chosen, and then the params container
* is constructed accordingly. Afterwards the values are set there, too.
*/
static Scalar krn(const Params &params, Scalar Sw)
static Scalar krn(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
assert(0 <= Swe && Swe <= 1);
Scalar exponent = 2.0/params.alpha() + 1;
Scalar tmp = 1. - Sw;
return tmp*tmp*(1. - pow(Sw, exponent));
Scalar tmp = 1. - Swe;
return tmp*tmp*(1. - pow(Swe, exponent));
}
/*!
......@@ -196,21 +196,21 @@ public:
* the medium as implied by the Brooks-Corey
* parameterization.
*
* \param Sw The mobile saturation of the wetting phase.
* \param Swe effective saturation of the wetting phase.
* \param params A container object that is populated with the appropriate coefficients for the respective law.
* Therefore, in the (problem specific) spatialParameters first, the material law is chosen, and then the params container
* is constructed accordingly. Afterwards the values are set there, too.
*/
static Scalar dkrn_dSw(const Params &params, Scalar Sw)
static Scalar dkrn_dSw(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
assert(0 <= Swe && Swe <= 1);
return
2.0*(Sw - 1)*(
2.0*(Swe - 1)*(
1 +
pow(Sw, 2.0/params.alpha())*(
pow(Swe, 2.0/params.alpha())*(
1.0/params.alpha() + 1.0/2 -
Sw*(1.0/params.alpha() + 1.0/2)
Swe*(1.0/params.alpha() + 1.0/2)
)
);
};
......
......@@ -45,6 +45,10 @@ public:
/*!
* \brief The capillary pressure-saturation curve.
*
* \param params material law parameters
* \param Sw wetting phase saturation
* \return the capillary pressure
*/
static Scalar pC(const Params &params, Scalar Sw)
{
......@@ -54,8 +58,9 @@ public:
/*!
* \brief The saturation-capillary pressure curve.
*
* \param pC Capillary pressure \f$p_C\f$
* \return The absolute saturation of the wetting phase \f$S_w\f$
* \param params material law parameters
* \param pC capillary pressure
* \return the absolute saturation of the wetting phase \f$S_w\f$
*/
static Scalar Sw(const Params &params, Scalar pC)
{
......@@ -65,6 +70,10 @@ public:
/*!
* \brief Returns the partial derivative of the capillary
* pressure to the absolute saturation.
*
* \param params material law parameters
* \param Sw wetting phase saturation
* \return the derivative of the capillary pressure w.r.t. saturation
*/
static Scalar dpC_dSw(const Params &params, Scalar Sw)
{
......@@ -74,6 +83,10 @@ public:
/*!
* \brief Returns the partial derivative of the absolute
* saturation to the capillary pressure.
*
* \param params material law parameters
* \param pC capillary pressure
* \return the derivative of the saturation w.r.t. capillary pressure
*/
static Scalar dSw_dpC(const Params &params, Scalar pC)
{
......@@ -83,7 +96,9 @@ public:
/*!
* \brief The relative permeability for the wetting phase.
*
* \param Sw The absolute saturation of the wetting phase.
* \param params material law parameters
* \param Sw wetting phase saturation
* \return the relative permeability of the wetting phase
*/
static Scalar krw(const Params &params, Scalar Sw)
{
......@@ -93,7 +108,9 @@ public:
/*!
* \brief The relative permeability for the non-wetting phase.
*
* \param Sw The absolute saturation of the wetting phase.
* \param params material law parameters
* \param Sw wetting phase saturation
* \return the relative permeability of the nonwetting phase
*/
static Scalar krn(const Params &params, Scalar Sw)
{
......@@ -102,6 +119,10 @@ public:
/*!
* \brief Convert an absolute wetting saturation to an effective one.
*
* \param params material law parameters
* \param Sw absolute wetting phase saturation
* \return effective wetting phase saturation
*/
static Scalar SwToSwe(const Params &params, Scalar Sw)
{
......@@ -110,6 +131,10 @@ public:
/*!
* \brief convert an absolute wetting saturation to an effective one
*
* \param params material law parameters
* \param Sn absolute nonwetting phase saturation
* \return effective nonwetting phase saturation
*/
static Scalar SnToSne(const Params &params, Scalar Sn)
{
......
......@@ -54,7 +54,9 @@ public:
p_C = (1 - \overline{S}_w) (p_{C,max} - p_{C,entry}) + p_{C,entry}
\f]
*
* \param Swe Effective saturation of of the wetting phase \f$\overline{S}_w\f$
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the capillary pressure
*/
static Scalar pC(const Params &params, Scalar Swe)
{
......@@ -69,8 +71,9 @@ public:
S_w = 1 - \frac{p_C - p_{C,entry}}{p_{C,max} - p_{C,entry}}
\f]
*
* \param pC Capillary pressure \f$p_C\f$
* \return The effective saturaion of the wetting phase \f$\overline{S}_w\f$
* \param params material law parameters
* \param pC capillary pressure
* \return the effective saturation of the wetting phase
*/
static Scalar Sw(const Params &params, Scalar pC)
{
......@@ -86,6 +89,10 @@ public:
\frac{\partial p_C}{\partial \overline{S}_w} =
- (p_{C,max} - p_{C,min})
\f]
*
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the derivative of capillary pressure w.r.t. saturation
*/
static Scalar dpC_dSw(const Params &params, Scalar Swe)
{
......@@ -95,6 +102,10 @@ public:
/*!
* \brief Returns the partial derivative of the effective
* saturation to the capillary pressure.
*
* \param params material law parameters
* \param pC capillary pressure
* \return the derivative of saturation w.r.t. capillary pressure
*/
static Scalar dSw_dpC(const Params &params, Scalar pC)
{
......@@ -104,7 +115,9 @@ public:
/*!
* \brief The relative permeability for the wetting phase.
*
* \param Swe The mobile saturation of the wetting phase.
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the relative permability of the wetting phase
*/
static Scalar krw(const Params &params, Scalar Swe)
{
......@@ -114,7 +127,9 @@ public:
/*!
* \brief The relative permeability for the non-wetting phase.
*
* \param Swe The mobile saturation of the wetting phase.
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the relative permability of the nonwetting phase
*/
static Scalar krn(const Params &params, Scalar Swe)
{
......
......@@ -193,7 +193,7 @@ public:
* - high saturation: connect the high regularization point with \f$ \overline S_w =1\f$ by a straight line and use that slope (yes, there is a kink :-( ).
*
* For not-regularized part:
\copydoc BrooksCorey::dSw_dpc()
\copydoc BrooksCorey::dSw_dpC()
*/
static Scalar dSw_dpC(const Params &params, Scalar pC)
{
......
......@@ -57,7 +57,9 @@ public:
p_C = (1 - \overline{S}_w) (p_{C,max} - p_{C,entry}) + p_{C,entry}
\f]
*
* \param Swe Effective saturation of of the wetting phase \f$\overline{S}_w\f$
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the capillary pressure
*/
static Scalar pC(const Params &params, Scalar Swe)
{
......@@ -72,8 +74,9 @@ public:
S_w = 1 - \frac{p_C - p_{C,entry}}{p_{C,max} - p_{C,entry}}
\f]
*
* \param pC Capillary pressure \f$p_C\f$
* \return The effective saturaion of the wetting phase \f$\overline{S}_w\f$
* \param params material law parameters
* \param pC capillary pressure
* \return the effective saturation of the wetting phase
*/
static Scalar Sw(const Params &params, Scalar pC)
{
......@@ -89,6 +92,10 @@ public:
\frac{\partial p_C}{\partial \overline{S}_w} =
- (p_{C,max} - p_{C,min})
\f]
*
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the derivative of capillary pressure w.r.t. saturation
*/
static Scalar dpC_dSw(const Params &params, Scalar Swe)
{
......@@ -98,6 +105,10 @@ public:
/*!
* \brief Returns the partial derivative of the effective
* saturation to the capillary pressure.
*
* \param params material law parameters
* \param pC capillary pressure
* \return the derivative of saturation w.r.t. capillary pressure
*/
static Scalar dSw_dpC(const Params &params, Scalar pC)
{
......@@ -107,7 +118,9 @@ public:
/*!
* \brief The relative permeability for the wetting phase.
*
* \param Swe The mobile saturation of the wetting phase.
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the relative permability of the wetting phase
*/
static Scalar krw(const Params &params, Scalar Swe)
{
......@@ -117,7 +130,9 @@ public:
/*!
* \brief The relative permeability for the non-wetting phase.
*
* \param Swe The mobile saturation of the wetting phase.
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the relative permability of the nonwetting phase
*/
static Scalar krn(const Params &params, Scalar Swe)
{
......
......@@ -51,14 +51,9 @@ public:
typedef typename Params::Scalar Scalar;
/*!
* \brief The capillary pressure-saturation curve.
* \brief \copybrief VanGenuchten::pC
*
* Van Genuchten's empirical capillary pressure <-> saturation
* function is given by
* \f[
p_C = (\overline{S}_w^{-1/m} - 1)^{1/n}/\alpha
\f]
* \param Swe Effective saturation of of the wetting phase \f$\overline{S}_w\f$
* \copydetails VanGenuchten::pC
*/
static Scalar pC(const Params &params, Scalar Swe)
{
......@@ -85,15 +80,9 @@ public:
}
/*!
* \brief The saturation-capillary pressure curve.
* \brief \copybrief VanGenuchten::Sw
*
* This is the inverse of the capillary pressure-saturation curve:
* \f[
\overline{S}_w = {p_C}^{-1} = ((\alpha p_C)^n + 1)^{-m}
\f]
*
* \param pC Capillary pressure \f$p_C\f$
* \return The effective saturaion of the wetting phase \f$\overline{S}_w\f$
* \copydetails VanGenuchten::Sw
*/
static Scalar Sw(const Params &params, Scalar pC)
{
......@@ -128,34 +117,29 @@ public:
}
/*!
* \brief Returns the partial derivative of the capillary
* pressure to the effective saturation.
* \brief \copybrief VanGenuchten::dpC_dSw
*
* This is equivalent to
* \f[
\frac{\partial p_C}{\partial \overline{S}_w} =
-\frac{1}{\alpha} (\overline{S}_w^{-1/m} - 1)^{1/n - }
\overline{S}_w^{-1/m} / \overline{S}_w / m
\f]
*/
static Scalar dpC_dSw(const Params &params, Scalar Sw)
* \copydetails VanGenuchten::dpC_dSw
*/
static Scalar dpC_dSw(const Params &params, Scalar Swe)
{
// derivative of the regualarization
if (Sw < params.pCLowSw()) {
if (Swe < params.pCLowSw()) {
// the slope of the straight line used in pC()
return mLow_(params);
}
else if (Sw > params.pCHighSw()) {
else if (Swe > params.pCHighSw()) {
// the slope of the straight line used in pC()
return mHigh_(params);
}
return VanGenuchten::dpC_dSw(params, Sw);
return VanGenuchten::dpC_dSw(params, Swe);
}
/*!
* \brief Returns the partial derivative of the effective
* saturation to the capillary pressure.
* \brief \copybrief VanGenuchten::dSw_dpC
*
* \copydetails VanGenuchten::dSw_dpC
*/
static Scalar dSw_dpC(const Params &params, Scalar pC)
{
......@@ -182,61 +166,57 @@ public:
}
/*!
* \brief The relative permeability for the wetting phase of
* the medium implied by van Genuchten's
* parameterization.
* \brief \copybrief VanGenuchten::krw
*
* \param Sw The mobile saturation of the wetting phase.
* \copydetails VanGenuchten::krw
*/
static Scalar krw(const Params &params, Scalar Sw)
static Scalar krw(const Params &params, Scalar Swe)
{
// retrieve the high threshold saturation for the
// unregularized relative permeability curve of the wetting
// phase from the parameters
const Scalar SwThHigh = params.krwHighSw();
if (Sw < 0)
if (Swe < 0)
return 0;
else if (Sw > 1)
else if (Swe > 1)
return 1;
else if (Sw > SwThHigh) {
else if (Swe > SwThHigh) {
typedef Dumux::Spline<Scalar> Spline;
Spline sp(SwThHigh, 1.0, // x1, x2
VanGenuchten::krw(params, SwThHigh), 1.0, // y1, y2
VanGenuchten::dkrw_dSw(params, SwThHigh), 0); // m1, m2
return sp.eval(Sw);
return sp.eval(Swe);
}
return VanGenuchten::krw(params, Sw);
return VanGenuchten::krw(params, Swe);
};
/*!
* \brief The relative permeability for the non-wetting phase
* of the medium implied by van Genuchten's
* parameterization.
* \brief \copybrief VanGenuchten::krn
*
* \param Sw The mobile saturation of the wetting phase.
* \copydetails VanGenuchten::krn
*/
static Scalar krn(const Params &params, Scalar Sw)
static Scalar krn(const Params &params, Scalar Swe)
{
// retrieve the low threshold saturation for the unregularized
// relative permeability curve of the non-wetting phase from
// the parameters
const Scalar SwThLow = params.krnLowSw();
if (Sw <= 0)
if (Swe <= 0)
return 1;
else if (Sw >= 1)
else if (Swe >= 1)
return 0;
else if (Sw < SwThLow) {
else if (Swe < SwThLow) {
typedef Dumux::Spline<Scalar> Spline;
Spline sp(0.0, SwThLow, // x1, x2
1.0, VanGenuchten::krn(params, SwThLow), // y1, y2
0.0, VanGenuchten::dkrn_dSw(params, SwThLow)); // m1, m2
return sp.eval(Sw);
return sp.eval(Swe);
}
return VanGenuchten::krn(params, Sw);
return VanGenuchten::krn(params, Swe);
}
private:
......
......@@ -54,12 +54,15 @@ public:
* \f[
p_C = (\overline{S}_w^{-1/m} - 1)^{1/n}/\alpha
\f]
* \param Sw Effective saturation of of the wetting phase \f$\overline{S}_w\f$
*
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the capillary pressure
*/
static Scalar pC(const Params &params, Scalar Sw)
static Scalar pC(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
return pow(pow(Sw, -1.0/params.vgM()) - 1, 1.0/params.vgN())/params.vgAlpha();
assert(0 <= Swe && Swe <= 1);
return pow(pow(Swe, -1.0/params.vgM()) - 1, 1.0/params.vgN())/params.vgAlpha();
}
/*!
......@@ -70,8 +73,9 @@ public:
\overline{S}_w = {p_C}^{-1} = ((\alpha p_C)^n + 1)^{-m}
\f]
*
* \param pC Capillary pressure \f$p_C\f$
* \return The effective saturaion of the wetting phase \f$\overline{S}_w\f$
* \param params material law parameters
* \param pC capillary pressure
* \return the effective saturation of the wetting phase
*/
static Scalar Sw(const Params &params, Scalar pC)
{
......@@ -90,19 +94,27 @@ public:
-\frac{1}{\alpha} (\overline{S}_w^{-1/m} - 1)^{1/n - }
\overline{S}_w^{-1/m} / \overline{S}_w / m
\f]
*
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the derivative of capillary pressure w.r.t. saturation
*/
static Scalar dpC_dSw(const Params &params, Scalar Sw)
static Scalar dpC_dSw(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
assert(0 <= Swe && Swe <= 1);
Scalar powSw = pow(Sw, -1/params.vgM());
Scalar powSw = pow(Swe, -1/params.vgM());
return - 1/params.vgAlpha() * pow(powSw - 1, 1/params.vgN() - 1)/params.vgN()
* powSw/Sw/params.vgM();
* powSw/Swe/params.vgM();
}
/*!
* \brief Returns the partial derivative of the effective
* saturation to the capillary pressure.
*
* \param params material law parameters
* \param pC capillary pressure
* \return the derivative of saturation w.r.t. capillary pressure
*/
static Scalar dSw_dpC(const Params &params, Scalar pC)
{
......@@ -118,14 +130,16 @@ public:
* the medium implied by van Genuchten's
* parameterization.
*
* \param Sw The mobile saturation of the wetting phase.
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the relative permability of the wetting phase
*/
static Scalar krw(const Params &params, Scalar Sw)
static Scalar krw(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);
assert(0 <= Swe && Swe <= 1);
Scalar r = 1. - pow(1 - pow(Sw, 1/params.vgM()), params.vgM());
return sqrt(Sw)*r*r;
Scalar r = 1. - pow(1 - pow(Swe, 1/params.vgM()), params.vgM());
return sqrt(Swe)*r*r;
};
/*!
......@@ -133,15 +147,17 @@ public:
* wetting phase in regard to the wetting saturation of the
* medium implied by the van Genuchten parameterization.
*
* \param Sw The mobile saturation of the wetting phase.
* \param params material law parameters
* \param Swe effective saturation of the wetting phase
* \return the derivative of the wetting phase relative permability w.r.t. saturation
*/
static Scalar dkrw_dSw(const Params &params, Scalar Sw)
static Scalar dkrw_dSw(const Params &params, Scalar Swe)
{
assert(0 <= Sw && Sw <= 1);