Skip to content
Snippets Groups Projects
Commit f368aa49 authored by Thomas Fetzer's avatar Thomas Fetzer
Browse files

[material]

- added doxygen comments and cleanup of defaultcomponents.hh
- improved documentation of constant.hh

[test]
- added units in test_navierstokes.input

reviewed by natalies



git-svn-id: svn://svn.iws.uni-stuttgart.de/DUMUX/dumux/trunk@15420 2fb0f335-1f38-0410-981e-8018bf24f1b0
parent 09739122
No related branches found
No related tags found
No related merge requests found
...@@ -71,14 +71,17 @@ public: ...@@ -71,14 +71,17 @@ public:
/*! /*!
* \brief Sets the liquid dynamic viscosity in \f$\mathrm{[Pa*s]}\f$. * \brief Sets the liquid dynamic viscosity in \f$\mathrm{[Pa*s]}\f$.
* *
* Although the dynamic viscosity \f$\mathrm{[Pa*s]} is returned,
* the kinematic viscosity \f$\mathrm{[m^2/s]} is requested from run time input.
*
* \param temperature phase temperature in \f$\mathrm{[K]}\f$ * \param temperature phase temperature in \f$\mathrm{[K]}\f$
* \param pressure phase pressure in \f$\mathrm{[Pa]}\f$ * \param pressure phase pressure in \f$\mathrm{[Pa]}\f$
*/ */
static Scalar liquidViscosity(Scalar temperature, Scalar pressure) static Scalar liquidViscosity(Scalar temperature, Scalar pressure)
{ {
static const Scalar viscosity static const Scalar kinematicViscosity
= GET_RUNTIME_PARAM_FROM_GROUP(TypeTag, Scalar, Problem, LiquidKinematicViscosity); = GET_RUNTIME_PARAM_FROM_GROUP(TypeTag, Scalar, Problem, LiquidKinematicViscosity);
return viscosity * liquidDensity(temperature, pressure); return kinematicViscosity * liquidDensity(temperature, pressure);
} }
...@@ -104,14 +107,17 @@ public: ...@@ -104,14 +107,17 @@ public:
/*! /*!
* \brief Sets the gas dynamic viscosity in \f$\mathrm{[Pa*s]}\f$. * \brief Sets the gas dynamic viscosity in \f$\mathrm{[Pa*s]}\f$.
* *
* Although the dynamic viscosity \f$\mathrm{[Pa*s]} is returned,
* the kinematic viscosity \f$\mathrm{[m^2/s]} is requested from run time input.
*
* \param temperature phase temperature in \f$\mathrm{[K]}\f$ * \param temperature phase temperature in \f$\mathrm{[K]}\f$
* \param pressure phase pressure in \f$\mathrm{[Pa]}\f$ * \param pressure phase pressure in \f$\mathrm{[Pa]}\f$
*/ */
static Scalar gasViscosity(Scalar temperature, Scalar pressure) static Scalar gasViscosity(Scalar temperature, Scalar pressure)
{ {
static const Scalar viscosity static const Scalar kinematicViscosity
= GET_RUNTIME_PARAM_FROM_GROUP(TypeTag, Scalar, Problem, GasKinematicViscosity); = GET_RUNTIME_PARAM_FROM_GROUP(TypeTag, Scalar, Problem, GasKinematicViscosity);
return viscosity * gasDensity(temperature, pressure); return kinematicViscosity * gasDensity(temperature, pressure);
} }
}; };
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
/*! /*!
* \file * \file
* *
* \brief Provides defaults for all available components. * \brief Provides defaults for the members of a fluidsystem.
*/ */
#ifndef DUMUX_DEFAULT_COMPONENTS_HH #ifndef DUMUX_DEFAULT_COMPONENTS_HH
#define DUMUX_DEFAULT_COMPONENTS_HH #define DUMUX_DEFAULT_COMPONENTS_HH
...@@ -44,19 +44,20 @@ namespace Dumux ...@@ -44,19 +44,20 @@ namespace Dumux
{ {
namespace Properties namespace Properties
{ {
//! defines the components which are being used by the fluid system by //! Defines the components which are being used by the fluid system by
//! default and how they are initialized //! default and how they are initialized
NEW_PROP_TAG(DefaultComponents); NEW_PROP_TAG(DefaultComponents);
//! defines the components which are actually being used by the fluid //! Defines, if a detailed description for members of the fluidsystem is used
//! system
NEW_PROP_TAG(Components);
NEW_PROP_TAG(EnableComplicatedFluidSystem); NEW_PROP_TAG(EnableComplicatedFluidSystem);
NEW_PROP_TAG(Scalar);
//! Defines the components which are actually being used by the fluidsystem
NEW_PROP_TAG(Components);
//! Specifies default component names and initializes the H2O fluid properties
SET_PROP(NumericModel, DefaultComponents) SET_PROP(NumericModel, DefaultComponents)
{ private: {
private:
typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar;
typedef Dumux::H2O<Scalar> H2O_IAPWS; typedef Dumux::H2O<Scalar> H2O_IAPWS;
...@@ -82,23 +83,18 @@ public: ...@@ -82,23 +83,18 @@ public:
} }
}; };
SET_PROP(NumericModel, Components) //! Initialize the components with default behavior
: public GET_PROP(TypeTag, DefaultComponents) SET_PROP(NumericModel, Components) : public GET_PROP(TypeTag, DefaultComponents) {};
{};
//! Enables detailed description of fluidsystems /*!
/* * \brief Enables a detailed description of the fluidsystem
*
* Complicated but detailed members of fluidsystems (e.g. phase viscosity, * Complicated but detailed members of fluidsystems (e.g. phase viscosity,
* phase density) can be simplified for efficiency reasons with this property. * phase density) can be simplified for efficiency reasons with this property.
* Typically, such high demands on accuracy are not needed, so this property * Typically, such high demands on accuracy are not needed, so this property
* is set to "false" as the default. * is set to "false" as the default.
*
* To enable it, use
* SET_BOOL_PROP(MyTypeTag, EnableComplicatedFluidSystem, true);
*/ */
SET_BOOL_PROP(NumericModel, EnableComplicatedFluidSystem, false);
SET_PROP(NumericModel, EnableComplicatedFluidSystem)
{ static const bool value = false; };
} // namespace Properties } // namespace Properties
} // namespace Dumux } // namespace Dumux
......
...@@ -8,5 +8,5 @@ File = ./grids/test_navierstokes.dgf ...@@ -8,5 +8,5 @@ File = ./grids/test_navierstokes.dgf
[Problem] [Problem]
EnableGravity = 0 # Disable gravity EnableGravity = 0 # Disable gravity
GasDensity = 1.1903 GasDensity = 1.1903 # [kg/m^3]
GasKinematicViscosity = 0.011903 GasKinematicViscosity = 0.011903 # [m^2/s]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment