From 24ef57c046da273d53d5f3565c1a61658cb4afef Mon Sep 17 00:00:00 2001
From: "Dennis.Glaeser" <dennis.glaeser@iws.uni-stuttgart.de>
Date: Wed, 29 Jul 2020 15:04:47 +0200
Subject: [PATCH] [flux][box] doc flux functions

---
 dumux/flux/box/darcyslaw.hh                 | 10 ++++++++++
 dumux/flux/box/effectivestresslaw.hh        |  4 +++-
 dumux/flux/box/fickslaw.hh                  |  6 ++++++
 dumux/flux/box/fourierslaw.hh               |  7 +++++++
 dumux/flux/box/fourierslawnonequilibrium.hh |  4 ++++
 dumux/flux/box/hookeslaw.hh                 |  4 +++-
 dumux/flux/box/maxwellstefanslaw.hh         |  5 +++++
 7 files changed, 38 insertions(+), 2 deletions(-)

diff --git a/dumux/flux/box/darcyslaw.hh b/dumux/flux/box/darcyslaw.hh
index 37d973d0e6..0c011f5d1d 100644
--- a/dumux/flux/box/darcyslaw.hh
+++ b/dumux/flux/box/darcyslaw.hh
@@ -73,6 +73,16 @@ class BoxDarcysLaw
 
 public:
 
+    /*!
+     * \brief Returns the advective flux of a fluid phase
+     *        across the given sub-control volume face.
+     * \note This assembles the term
+     *       \f$-|\sigma| \mathbf{n}^T \mathbf{K} \left( \nabla p - \rho \mathbf{g} \right)\f$,
+     *       where \f$|\sigma|\f$ is the area of the face and \f$\mathbf{n}\f$ is the outer
+     *       normal vector. Thus, the flux is given in N*m, and can be converted
+     *       into a volume flux (m^3/s) or mass flux (kg/s) by applying an upwind scheme
+     *       for the mobility or the product of density and mobility, respectively.
+     */
     template<class Problem, class ElementVolumeVariables, class ElementFluxVarsCache>
     static Scalar flux(const Problem& problem,
                        const Element& element,
diff --git a/dumux/flux/box/effectivestresslaw.hh b/dumux/flux/box/effectivestresslaw.hh
index d3409cf484..629ef693e2 100644
--- a/dumux/flux/box/effectivestresslaw.hh
+++ b/dumux/flux/box/effectivestresslaw.hh
@@ -63,7 +63,9 @@ public:
     //! state the discretization method this implementation belongs to
     static constexpr DiscretizationMethod discMethod = DiscretizationMethod::box;
 
-    //! computes the force acting on a sub-control volume face
+    /*!
+     * \brief Computes the force (in Newton) acting on a sub-control volume face.
+     */
     template<class Problem, class ElementVolumeVariables, class ElementFluxVarsCache>
     static ForceVector force(const Problem& problem,
                              const Element& element,
diff --git a/dumux/flux/box/fickslaw.hh b/dumux/flux/box/fickslaw.hh
index 6b6e1e10f6..61b7a17b26 100644
--- a/dumux/flux/box/fickslaw.hh
+++ b/dumux/flux/box/fickslaw.hh
@@ -83,6 +83,12 @@ public:
     static constexpr ReferenceSystemFormulation referenceSystemFormulation()
     { return referenceSystem; }
 
+    /*!
+     * \brief Returns the diffusive fluxes of all components within
+     *        a fluid phase across the given sub-control volume face.
+     *        The computed fluxes are given in mole/s or kg/s, depending
+     *        on the template parameter ReferenceSystemFormulation.
+     */
     static ComponentFluxVector flux(const Problem& problem,
                                     const Element& element,
                                     const FVElementGeometry& fvGeometry,
diff --git a/dumux/flux/box/fourierslaw.hh b/dumux/flux/box/fourierslaw.hh
index efe091e988..988f87024b 100644
--- a/dumux/flux/box/fourierslaw.hh
+++ b/dumux/flux/box/fourierslaw.hh
@@ -55,6 +55,13 @@ class FouriersLawImplementation<TypeTag, DiscretizationMethod::box>
     using Element = typename GridView::template Codim<0>::Entity;
 
 public:
+    /*!
+     * \brief Returns the heat flux within the porous medium
+     *        (in J/s) across the given sub-control volume face.
+     * \note This law assumes thermal equilibrium between the fluid
+     *       and solid phases, and uses an effective thermal conductivity
+     *       for the overall aggregate.
+     */
     static Scalar flux(const Problem& problem,
                        const Element& element,
                        const FVElementGeometry& fvGeometry,
diff --git a/dumux/flux/box/fourierslawnonequilibrium.hh b/dumux/flux/box/fourierslawnonequilibrium.hh
index 1b7df33d16..40bf51f39a 100644
--- a/dumux/flux/box/fourierslawnonequilibrium.hh
+++ b/dumux/flux/box/fourierslawnonequilibrium.hh
@@ -65,6 +65,10 @@ class FouriersLawNonEquilibriumImplementation<TypeTag, DiscretizationMethod::box
     static constexpr auto sPhaseIdx = ModelTraits::numFluidPhases();
 
 public:
+    /*!
+     * \brief Returns the heat flux within a fluid or solid
+     *        phase (in J/s) across the given sub-control volume face.
+     */
     static Scalar flux(const Problem& problem,
                        const Element& element,
                        const FVElementGeometry& fvGeometry,
diff --git a/dumux/flux/box/hookeslaw.hh b/dumux/flux/box/hookeslaw.hh
index dc51c8b1db..e7dfe83832 100644
--- a/dumux/flux/box/hookeslaw.hh
+++ b/dumux/flux/box/hookeslaw.hh
@@ -63,7 +63,9 @@ public:
     //! state the discretization method this implementation belongs to
     static constexpr DiscretizationMethod discMethod = DiscretizationMethod::box;
 
-    //! computes the force acting on a sub-control volume face
+    /*!
+     * \brief Returns the force (in Newton) acting on a sub-control volume face.
+     */
     template<class Problem, class ElementVolumeVariables, class ElementFluxVarsCache>
     static ForceVector force(const Problem& problem,
                              const Element& element,
diff --git a/dumux/flux/box/maxwellstefanslaw.hh b/dumux/flux/box/maxwellstefanslaw.hh
index 3eff2b115c..76b2b5b583 100644
--- a/dumux/flux/box/maxwellstefanslaw.hh
+++ b/dumux/flux/box/maxwellstefanslaw.hh
@@ -79,6 +79,11 @@ public:
     static constexpr ReferenceSystemFormulation referenceSystemFormulation()
     { return referenceSystem; }
 
+    /*!
+     * \brief Returns the diffusive fluxes of all components within
+     *        a fluid phase across the given sub-control volume face.
+     *        The computed fluxes are given in kg/s.
+     */
     static ComponentFluxVector flux(const Problem& problem,
                                     const Element& element,
                                     const FVElementGeometry& fvGeometry,
-- 
GitLab