Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dumux-repositories
dumux
Commits
55a2be36
Commit
55a2be36
authored
Dec 17, 2018
by
Sina Ackermann
Committed by
Simon Scholz
Dec 18, 2018
Browse files
[doxygen] Adapt documentation for 1p, 1pnc, 1pncmin models
parent
b0ce2d5a
Changes
20
Hide whitespace changes
Inline
Side-by-side
dumux/porousmediumflow/1p/incompressiblelocalresidual.hh
View file @
55a2be36
...
...
@@ -22,14 +22,14 @@
* \brief Element-wise calculation of the residual and its derivatives
* for a single-phase, incompressible, test problem.
*/
#ifndef DUMUX_1P_INCOMPRESSIBLE_LOCAL_RESIDUAL_HH
#define DUMUX_1P_INCOMPRESSIBLE_LOCAL_RESIDUAL_HH
#include
<dumux/discretization/method.hh>
#include
<dumux/porousmediumflow/immiscible/localresidual.hh>
namespace
Dumux
{
namespace
Dumux
{
/*!
* \ingroup OnePModel
...
...
@@ -79,7 +79,7 @@ public:
problem
.
addSourceDerivatives
(
partialDerivatives
,
element
,
fvGeometry
,
curVolVars
,
scv
);
}
//!
f
lux derivatives for the cell-centered tpfa scheme
//!
F
lux derivatives for the cell-centered tpfa scheme
template
<
class
PartialDerivativeMatrices
,
class
T
=
TypeTag
>
std
::
enable_if_t
<
GetPropType
<
T
,
Properties
::
FVGridGeometry
>::
discMethod
==
DiscretizationMethod
::
cctpfa
,
void
>
addFluxDerivatives
(
PartialDerivativeMatrices
&
derivativeMatrices
,
...
...
@@ -105,7 +105,7 @@ public:
derivativeMatrices
[
scvf
.
outsideScvIdx
()][
conti0EqIdx
][
pressureIdx
]
-=
deriv
;
}
//!
f
lux derivatives for the cell-centered mpfa scheme
//!
F
lux derivatives for the cell-centered mpfa scheme
template
<
class
PartialDerivativeMatrices
,
class
T
=
TypeTag
>
std
::
enable_if_t
<
GetPropType
<
T
,
Properties
::
FVGridGeometry
>::
discMethod
==
DiscretizationMethod
::
ccmpfa
,
void
>
addFluxDerivatives
(
PartialDerivativeMatrices
&
derivativeMatrices
,
...
...
@@ -142,7 +142,7 @@ public:
:
tij
[
i
]
*
up
;
}
//!
f
lux derivatives for the box scheme
//!
F
lux derivatives for the box scheme
template
<
class
JacobianMatrix
,
class
T
=
TypeTag
>
std
::
enable_if_t
<
GetPropType
<
T
,
Properties
::
FVGridGeometry
>::
discMethod
==
DiscretizationMethod
::
box
,
void
>
addFluxDerivatives
(
JacobianMatrix
&
A
,
...
...
dumux/porousmediumflow/1p/indices.hh
View file @
55a2be36
...
...
@@ -21,6 +21,7 @@
* \ingroup OnePModel
* \brief Defines the indices for the one-phase fully implicit model.
*/
#ifndef DUMUX_1P_INDICES_HH
#define DUMUX_1P_INDICES_HH
...
...
dumux/porousmediumflow/1p/iofields.hh
View file @
55a2be36
...
...
@@ -19,8 +19,9 @@
/*!
* \file
* \ingroup OnePModel
* \brief Adds I/O fields specific to the one phase model
* \brief Adds I/O fields specific to the one phase model
.
*/
#ifndef DUMUX_ONEP_IO_FIELDS_HH
#define DUMUX_ONEP_IO_FIELDS_HH
...
...
@@ -32,7 +33,7 @@ namespace Dumux {
/*!
* \ingroup OnePModel
* \brief Adds I/O fields specific to the one phase model
* \brief Adds I/O fields specific to the one phase model
.
*/
class
OnePIOFields
{
...
...
dumux/porousmediumflow/1p/model.hh
View file @
55a2be36
...
...
@@ -115,7 +115,7 @@ struct OnePNI { using InheritsFrom = std::tuple<OneP>; };
}
// end namespace TTag
///////////////////////////////////////////////////////////////////////////
//
p
roperties for the isothermal single phase model
//
P
roperties for the isothermal single phase model
///////////////////////////////////////////////////////////////////////////
template
<
class
TypeTag
>
struct
IOFields
<
TypeTag
,
TTag
::
OneP
>
{
using
type
=
OnePIOFields
;
};
//!< default I/O fields specific to this model
...
...
@@ -146,9 +146,10 @@ public:
/*!
* \brief The fluid state which is used by the volume variables to
* store the thermodynamic state. This should be chosen
* appropriately for the model ((non-)isothermal, equilibrium, ...).
* This can be done in the problem.
* store the thermodynamic state.
*
* This should be chosen appropriately for the model ((non-)isothermal,
* equilibrium, ...). This can be done in the problem.
*/
template
<
class
TypeTag
>
struct
FluidState
<
TypeTag
,
TTag
::
OneP
>
...
...
@@ -161,7 +162,7 @@ public:
};
///////////////////////////////////////////////////////////////////////////
//
p
roperties for the non-isothermal single phase model
//
P
roperties for the non-isothermal single phase model
///////////////////////////////////////////////////////////////////////////
//! Add temperature to the output
...
...
dumux/porousmediumflow/1p/sequential/celldata.hh
View file @
55a2be36
...
...
@@ -16,28 +16,31 @@
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
*****************************************************************************/
/*!
* \file
* \ingroup SequentialOnePModel
* \brief Class including data of one grid cell.
*/
#ifndef DUMUX_CELLDATA1P_HH
#define DUMUX_CELLDATA1P_HH
#include
"properties.hh"
#include
"fluxdata.hh"
/*!
* \file
* \ingroup SequentialOnePModel
* \brief Class including data of one grid cell.
*/
namespace
Dumux
{
namespace
Dumux
{
template
<
class
TypeTag
>
class
FluxData1P
;
/*!
* \ingroup SequentialOnePModel
* Class including data of one grid cell.
* The variables of one-phase flow, which are the pressure as well as additional data assigned to
* cell-cell interfaces, so-called flux-data, are stored.
*
* \brief Class including data of one grid cell.
*
* The variables of one-phase flow, which are the pressure as well as
* additional data assigned to cell-cell interfaces,
* so-called flux-data, are stored.
*
* \tparam TypeTag The problem TypeTag
*/
...
...
@@ -74,22 +77,22 @@ public:
// functions returning primary variables
////////////////////////////////////////////////////////////
//!
\brief
Returns the cell pressure
//! Returns the cell pressure
Scalar
pressure
()
{
return
pressure_
;
}
//!
\brief
Returns the cell pressure
//! Returns the cell pressure
Scalar
pressure
()
const
{
return
pressure_
;
}
//!Sets the cell pressure
//!
Sets the cell pressure
void
setPressure
(
Scalar
press
)
{
pressure_
=
press
;
}
};
}
}
// end namespace Dumux
#endif
dumux/porousmediumflow/1p/sequential/diffusion/cellcentered/pressure.hh
View file @
55a2be36
...
...
@@ -16,6 +16,12 @@
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
*****************************************************************************/
/*!
* \file
* \ingroup SequentialOnePModel
* \brief Sequential OneP Model solving the equations for pressure and velocity separately.
*/
#ifndef DUMUX_FVPRESSURE1P_HH
#define DUMUX_FVPRESSURE1P_HH
...
...
@@ -24,17 +30,12 @@
#include
<dumux/porousmediumflow/sequential/cellcentered/pressure.hh>
#include
<dumux/porousmediumflow/1p/sequential/properties.hh>
/**
* \file
* \ingroup SequentialOnePModel
* \brief Sequential OneP Model solving the equations for pressure and velocity seperately.
*/
namespace
Dumux
{
namespace
Dumux
{
/*! \ingroup SequentialOnePModel
* \brief Sequential OneP Model solving the equations for pressure and velocity seperately.
/*!
* \ingroup SequentialOnePModel
* \brief Sequential OneP Model solving the equations for pressure and velocity separately.
*
* This model solves equations of the form
* \f[
* \text{div}\, \boldsymbol v = q.
...
...
@@ -110,7 +111,8 @@ public:
void
getFluxOnBoundary
(
Dune
::
FieldVector
<
Scalar
,
2
>&
,
const
Intersection
&
,
const
CellData
&
,
const
bool
);
/*! \brief Initializes the pressure model
/*!
* \brief Initializes the pressure model
*
* \copydetails FVPressure::initialize()
*
...
...
@@ -130,10 +132,10 @@ public:
return
;
}
/*! \brief Pressure update
/*!
* \brief Pressure update
*
* \copydetails FVPressure::update()
*
*/
void
update
()
{
...
...
@@ -141,8 +143,8 @@ public:
storePressureSolution
();
}
/*!
\brief Globally stores the pressure solution
*
/*!
*
\brief Globally stores the pressure solution
*/
void
storePressureSolution
()
{
...
...
@@ -155,7 +157,8 @@ public:
}
}
/*! \brief Stores the pressure solution of a cell
/*!
* \brief Stores the pressure solution of a cell
*
* \param eIdxGlobal Global cell index
* \param cellData A CellData object
...
...
@@ -167,13 +170,13 @@ public:
cellData
.
setPressure
(
press
);
}
/*! \brief Adds pressure output to the output file
/*!
* \brief Adds pressure output to the output file
*
* Adds pressures to the output.
*
* \tparam MultiWriter Class defining the output writer
* \param writer The output writer (usually a <tt>VTKMultiWriter</tt> object)
*
*/
template
<
class
MultiWriter
>
void
addOutputVtkFields
(
MultiWriter
&
writer
)
...
...
@@ -188,8 +191,9 @@ public:
return
;
}
//! Constructs a FVPressure1P object
/**
/*!
* \brief Constructs a FVPressure1P object
*
* \param problem A problem class object
*/
FVPressure1P
(
Problem
&
problem
)
:
...
...
@@ -212,7 +216,8 @@ private:
Scalar
viscosity_
;
};
/*! \brief Function which calculates the source entry
/*!
* \brief Function which calculates the source entry
*
* \copydetails FVPressure::getSource(EntryType&,const Element&,const CellData&,const bool)
*
...
...
@@ -235,10 +240,10 @@ void FVPressure1P<TypeTag>::getSource(Dune::FieldVector<Scalar, 2>& entry, const
return
;
}
/*! \brief Function which calculates the flux entry
/*!
* \brief Function which calculates the flux entry
*
* \copydetails FVPressure::getFlux(EntryType&,const Intersection&,const CellData&,const bool)
*
*/
template
<
class
TypeTag
>
void
FVPressure1P
<
TypeTag
>::
getFlux
(
Dune
::
FieldVector
<
Scalar
,
2
>&
entry
,
const
Intersection
&
intersection
...
...
@@ -283,7 +288,8 @@ void FVPressure1P<TypeTag>::getFlux(Dune::FieldVector<Scalar, 2>& entry, const I
return
;
}
/*! \brief Function which calculates the flux entry at a boundary
/*!
* \brief Function which calculates the flux entry at a boundary
*
* \copydetails FVPressure::getFluxOnBoundary(EntryType&,const Intersection&,const CellData&,const bool)
*
...
...
@@ -322,7 +328,7 @@ const Intersection& intersection, const CellData& cellData, const bool first)
{
problem_
.
dirichlet
(
boundValues
,
intersection
);
//permeability vector at boundary
//
permeability vector at boundary
// compute vectorized permeabilities
DimMatrix
meanPermeability
(
0
);
...
...
@@ -334,18 +340,18 @@ const Intersection& intersection, const CellData& cellData, const bool first)
permeability
/=
viscosity_
;
//get
d
irichlet pressure boundary condition
//
get
D
irichlet pressure boundary condition
Scalar
pressBound
=
boundValues
;
//calculate current matrix entry
//
calculate current matrix entry
entry
[
matrix
]
=
((
permeability
*
unitOuterNormal
)
/
dist
)
*
faceArea
;
entry
[
rhs
]
=
entry
[
matrix
]
*
pressBound
;
//calculate right hand side
//
calculate right hand side
entry
[
rhs
]
-=
density_
*
(
permeability
*
gravity_
)
*
faceArea
;
}
//set
n
eumann boundary condition
//
set
N
eumann boundary condition
else
if
(
bcType
.
isNeumann
(
pressEqIdx
))
{
problem_
.
neumann
(
boundValues
,
intersection
);
...
...
@@ -361,5 +367,5 @@ const Intersection& intersection, const CellData& cellData, const bool first)
return
;
}
}
}
// end namespace Dumux
#endif
dumux/porousmediumflow/1p/sequential/diffusion/cellcentered/pressureproperties.hh
View file @
55a2be36
...
...
@@ -29,8 +29,7 @@
#include
<dumux/common/properties/propertysystemmacros.hh>
#include
<dumux/porousmediumflow/1p/sequential/diffusion/properties.hh>
namespace
Dumux
{
namespace
Dumux
{
////////////////////////////////
// forward declarations
...
...
@@ -40,8 +39,7 @@ namespace Dumux
////////////////////////////////
// properties
////////////////////////////////
namespace
Properties
{
namespace
Properties
{
//////////////////////////////////////////////////////////////////
// Type tags
//////////////////////////////////////////////////////////////////
...
...
@@ -53,16 +51,14 @@ NEW_TYPE_TAG(FVPressureOneP, INHERITS_FROM(PressureOneP));
// Property tags
//////////////////////////////////////////////////////////////////
}
}
}
// end namespace Properties
}
// end namespace Dumux
#include
"velocity.hh"
#include
"pressure.hh"
namespace
Dumux
{
namespace
Properties
{
namespace
Dumux
{
namespace
Properties
{
//////////////////////////////////////////////////////////////////
// Properties
//////////////////////////////////////////////////////////////////
...
...
@@ -73,8 +69,7 @@ SET_TYPE_PROP(FVPressureOneP, PressureModel, FVPressure1P<TypeTag>);
//! Allow assembling algorithm for the pressure matrix to assemble only from one side of a cell-cell interface
SET_BOOL_PROP
(
FVPressureOneP
,
VisitFacesOnlyOnce
,
true
);
// \}
}
}
}
// end namespace Properties
}
// end namespace Dumux
#endif
dumux/porousmediumflow/1p/sequential/diffusion/cellcentered/pressurevelocity.hh
View file @
55a2be36
...
...
@@ -16,26 +16,27 @@
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
*****************************************************************************/
/*!
* \file
* \ingroup SequentialOnePModel
* \brief Single Phase Finite Volume Model
*/
#ifndef DUMUX_FVPRESSUREVELOCITY1P_HH
#define DUMUX_FVPRESSUREVELOCITY1P_HH
// dumux environment
#include
"pressure.hh"
#include
<dumux/porousmediumflow/1p/sequential/properties.hh>
#include
<dumux/porousmediumflow/sequential/cellcentered/velocity.hh>
/*!
* \file
* \ingroup SequentialOnePModel
* \brief Single Phase Finite Volume Model
*/
namespace
Dumux
{
namespace
Dumux
{
/*! \ingroup SequentialOnePModel
/*!
* \ingroup SequentialOnePModel
* \brief Single Phase Finite Volume Model
*
* This model solves equations of the form
* \f[
* \textbf{div}\, \boldsymbol v = q.
...
...
@@ -51,14 +52,14 @@ namespace Dumux
* on \f$ \Gamma_{Neumann} \f$.
*
* \tparam TypeTag The Type Tag
*
*/
template
<
class
TypeTag
>
class
FVPressureVelocity1P
:
public
FVPressure1P
<
TypeTag
>
{
using
ParentType
=
FVPressure1P
<
TypeTag
>
;
using
Problem
=
typename
GET_PROP_TYPE
(
TypeTag
,
Problem
);
public:
/*! \brief Initializes the pressure model
/*!
* \brief Initializes the pressure model
*
* \copydetails FVPressure::initialize()
*/
...
...
@@ -68,10 +69,10 @@ public:
velocity_
.
calculateVelocity
();
}
/*! \brief Pressure update
/*!
* \brief Pressure update
*
* \copydetails FVPressure::update()
*
*/
void
update
()
{
...
...
@@ -79,13 +80,13 @@ public:
velocity_
.
calculateVelocity
();
}
/*! \brief Adds velocity output to the output file
/*!
* \brief Adds velocity output to the output file
*
* Adds the velocities to the output.
*
* \tparam MultiWriter Class defining the output writer
* \param writer The output writer (usually a <tt>VTKMultiWriter</tt> object)
*
*/
template
<
class
MultiWriter
>
void
addOutputVtkFields
(
MultiWriter
&
writer
)
...
...
@@ -94,7 +95,8 @@ public:
velocity_
.
addOutputVtkFields
(
writer
);
}
/*! Constructs a FVPressure1P object
/*!
* Constructs a FVPressure1P object
*
* \param problem A problem class object
*/
...
...
@@ -106,5 +108,5 @@ private:
FVVelocity
<
TypeTag
,
typename
GET_PROP_TYPE
(
TypeTag
,
Velocity
)
>
velocity_
;
};
}
}
// end namespace Dumux
#endif
dumux/porousmediumflow/1p/sequential/diffusion/cellcentered/velocity.hh
View file @
55a2be36
...
...
@@ -16,22 +16,23 @@
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
*****************************************************************************/
#ifndef DUMUX_FVVELOCITY1P_HH
#define DUMUX_FVVELOCITY1P_HH
#include
<dumux/porousmediumflow/1p/sequential/properties.hh>
/*!
* \file
* \ingroup SequentialOnePModel
* \brief Single phase finite volume velocity reconstruction
*/
#ifndef DUMUX_FVVELOCITY1P_HH
#define DUMUX_FVVELOCITY1P_HH
namespace
Dumux
{
/*! \ingroup SequentialOnePModel
#include
<dumux/porousmediumflow/1p/sequential/properties.hh>
namespace
Dumux
{
/*!
* \ingroup SequentialOnePModel
* \brief Single phase finite volume velocity reconstruction
*
* Calculates velocities from a known pressure field applying a finite volume discretization.
* The pressure has to be given as piecewise constant cell values.
* The velocity is calculated following Darcy's law as
...
...
@@ -43,7 +44,6 @@ namespace Dumux
*
* \tparam TypeTag The Type Tag
*/
template
<
class
TypeTag
>
class
FVVelocity1P
{
...
...
@@ -79,8 +79,9 @@ class FVVelocity1P
using
DimMatrix
=
Dune
::
FieldMatrix
<
Scalar
,
dim
,
dim
>
;
public:
//! Constructs a FVVelocity1P object
/**
/*!
* \brief Constructs a FVVelocity1P object
*
* \param problem A problem class object
*/
FVVelocity1P
(
Problem
&
problem
)
...
...
@@ -97,16 +98,16 @@ public:
// Calculates the velocity at a cell-cell interface.
void
calculateVelocity
(
const
Intersection
&
,
CellData
&
);
//Calculates the velocity at a boundary.
//
Calculates the velocity at a boundary.
void
calculateVelocityOnBoundary
(
const
Intersection
&
,
CellData
&
);
/*! \brief Adds velocity output to the output file
/*!
* \brief Adds velocity output to the output file
*
* Adds the velocities to the output.
*
* \tparam MultiWriter Class defining the output writer
* \param writer The output writer (usually a <tt>VTKMultiWriter</tt> object)
*
*/
template
<
class
MultiWriter
>
void
addOutputVtkFields
(
MultiWriter
&
writer
)
...
...
@@ -190,7 +191,8 @@ private:
Scalar
viscosity_
;
};
/*! \brief Calculates the velocity at a cell-cell interface.
/*!
* \brief Calculates the velocity at a cell-cell interface.
*
* Calculates the velocity at a cell-cell interface from a given pressure field.
*
...
...
@@ -235,16 +237,16 @@ void FVVelocity1P<TypeTag>::calculateVelocity(const Intersection& intersection,
permeability
/=
viscosity_
;
//calculate potential gradients
//
calculate potential gradients
Scalar
potential
=
(
cellData
.
pressure
()
-
cellDataJ
.
pressure
())
/
dist
;
potential
+=
density_
*
(
unitOuterNormal
*
gravity_
);
//store potentials for further calculations (velocity, saturation, ...)
//
store potentials for further calculations (velocity, saturation, ...)
cellData
.
fluxData
().
setPotential
(
isIndexI
,
potential
);
cellDataJ
.
fluxData
().
setPotential
(
isIndexJ
,
-
potential
);
//calculate the gravity term
//
calculate the gravity term
VelocityVector
velocity
(
permeability
);
velocity
*=
(
cellData
.
pressure
()
-
cellDataJ
.
pressure
())
/
dist
;
...
...
@@ -253,7 +255,7 @@ void FVVelocity1P<TypeTag>::calculateVelocity(const Intersection& intersection,
velocity
+=
gravityTerm
;
//store velocities
//
store velocities
cellData
.
fluxData
().
setVelocity
(
isIndexI
,
velocity
);
cellData
.
fluxData
().
setVelocityMarker
(
isIndexI
);
...
...
@@ -262,7 +264,8 @@ void FVVelocity1P<TypeTag>::calculateVelocity(const Intersection& intersection,
return
;
}
/*! \brief Calculates the velocity at a boundary.
/*!
* \brief Calculates the velocity at a boundary.
*
* Calculates the velocity at a boundary from a given pressure field.
*
...
...
@@ -274,14 +277,14 @@ void FVVelocity1P<TypeTag>::calculateVelocityOnBoundary(const Intersection& inte
{