From 3e4643603011273c8cee8790aa4e007f5d4d6c20 Mon Sep 17 00:00:00 2001 From: DennisGlaeser <dennis.glaeser@iws.uni-stuttgart.de> Date: Tue, 19 Dec 2017 22:04:56 +0100 Subject: [PATCH] [mineralization] fix documentation --- .../mineralization/localresidual.hh | 22 +++++++------- .../porousmediumflow/mineralization/model.hh | 11 ++++--- .../mineralization/volumevariables.hh | 29 +++++++++---------- .../mineralization/vtkoutputfields.hh | 6 ++-- 4 files changed, 36 insertions(+), 32 deletions(-) diff --git a/dumux/porousmediumflow/mineralization/localresidual.hh b/dumux/porousmediumflow/mineralization/localresidual.hh index af85e08c67..83c785ca53 100644 --- a/dumux/porousmediumflow/mineralization/localresidual.hh +++ b/dumux/porousmediumflow/mineralization/localresidual.hh @@ -18,9 +18,9 @@ *****************************************************************************/ /*! * \file - * + * \ingroup MineralizationModel * \brief Element-wise calculation of the local residual for problems using a - * compositional fully implicit model that also considers solid phases. + * compositional model that also considers mineralization of solid phases. */ #ifndef DUMUX_COMPOSITIONAL_MINERALIZATION_LOCAL_RESIDUAL_HH #define DUMUX_COMPOSITIONAL_MINERALIZATION_LOCAL_RESIDUAL_HH @@ -30,10 +30,9 @@ namespace Dumux { /*! - * \ingroup Mineralization - * \ingroup LocalResidual + * \ingroup MineralizationModel * \brief Element-wise calculation of the local residual for problems - * using a one/two-phase n-component mineralization fully implicit model. + * using a one/two-phase n-component mineralization model. */ template<class TypeTag> class MineralizationLocalResidual: public CompositionalLocalResidual<TypeTag> @@ -59,12 +58,15 @@ public: * \brief Evaluate the amount of all conservation quantities * (e.g. phase mass) within a sub-control volume. * - * The result should be averaged over the volume (e.g. phase mass - * inside a sub control volume divided by the volume) + * We consider the volume-average here (e.g. phase mass inside a + * sub control volume divided by the volume). The volume is multiplied + * onto it afterwards in the local residual of the respective spatial + * discretization scheme. * - * \param storage The mass of the component within the sub-control volume - * \param scvIdx The SCV (sub-control-volume) index - * \param usePrevSol Evaluate function with solution of current or previous time step + * \param problem The problem (Initial/Boundary conditions...) to be solved + * \param scv The sub-control volume of the finite volume grid + * \param volVars The volume variables (primary/secondary variables) in the scv + * \return Amount per volume of the conserved quantities */ ResidualVector computeStorage(const Problem& problem, const SubControlVolume& scv, diff --git a/dumux/porousmediumflow/mineralization/model.hh b/dumux/porousmediumflow/mineralization/model.hh index 6ec7775ac4..b523d0c3ba 100644 --- a/dumux/porousmediumflow/mineralization/model.hh +++ b/dumux/porousmediumflow/mineralization/model.hh @@ -17,13 +17,16 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. * *****************************************************************************/ /*! - * \ingroup Mineralization * \file + * \ingroup MineralizationModel + * \brief Defines the properties required for compositional porous medium flow + * models considering mineralization processes of one or more of the + * components. * - * \brief Defines the properties required for the - * implicit mineralization models. + * The solid or mineral phases are assumed to consist of a single component. + * Their mass balance consist only of a storage and a source term: + * \f$\frac{\partial \varrho_\lambda \phi_\lambda )} {\partial t} = q_\lambda\f$ */ - #ifndef DUMUX_MINERALIZATION_MODEL_HH #define DUMUX_MINERALIZATION_MODEL_HH diff --git a/dumux/porousmediumflow/mineralization/volumevariables.hh b/dumux/porousmediumflow/mineralization/volumevariables.hh index c63547a794..03f3feb2f7 100644 --- a/dumux/porousmediumflow/mineralization/volumevariables.hh +++ b/dumux/porousmediumflow/mineralization/volumevariables.hh @@ -18,9 +18,9 @@ *****************************************************************************/ /*! * \file - * - * \brief Contains the quantities which are constant within a - * finite volume in the two-phase, n-component mineralization model. + * \ingroup MineralizationModel + * \brief Contains the quantities which are constant within a sub-control volume + * of the finite volume grid in the two-phase, n-component mineralization model. */ #ifndef DUMUX_MINERALIZATION_VOLUME_VARIABLES_HH #define DUMUX_MINERALIZATION_VOLUME_VARIABLES_HH @@ -34,9 +34,8 @@ namespace Dumux /*! * \ingroup Mineralization - * \ingroup ImplicitVolumeVariables - * \brief Contains the quantities which are are constant within a - * finite volume in a mineralization n-component model. + * \brief Contains the quantities which are are constant within a sub-control volume + * of the finite volume grid in an m-phase, n-component, mineralization model. */ template <class TypeTag> class MineralizationVolumeVariables : public GET_PROP_TYPE(TypeTag, NonMineralizationVolumeVariables) @@ -63,9 +62,7 @@ class MineralizationVolumeVariables : public GET_PROP_TYPE(TypeTag, NonMineraliz public: using FluidState = typename GET_PROP_TYPE(TypeTag, FluidState); - /*! - * \copydoc ImplicitVolumeVariables::update - */ + //! updates all required quantities inside the given scv void update(const ElementSolutionVector &elemSol, const Problem &problem, const Element &element, @@ -74,9 +71,7 @@ public: // Update parent type (also completes the fluid state) ParentType::update(elemSol, problem, element, scv); - ///////////// // calculate the remaining quantities - ///////////// auto&& priVars = elemSol[scv.indexInElement()]; sumPrecipitates_ = 0.0; @@ -89,7 +84,7 @@ public: /*! * \brief Returns the volume fraction of the precipitate (solid phase) - * for the given phaseIdx + * for the given phaseIdx * * \param phaseIdx the index of the solid phase */ @@ -128,10 +123,12 @@ public: * * \param phaseIdx the index of the fluid phase * \param compIdx the index of the component - * \f$\mathrm{molality}=\frac{n_\mathrm{component}}{m_\mathrm{solvent}} - * =\frac{n_\mathrm{component}}{n_\mathrm{solvent}*M_\mathrm{solvent}}\f$ - * compIdx of the main component (solvent) in the - * phase is equal to the phaseIdx + * \f$\mathrm{molality} + * = \frac{n_\mathrm{component}}{m_\mathrm{solvent}} + * = \frac{n_\mathrm{component}}{n_\mathrm{solvent}*M_\mathrm{solvent}}\f$ + * + * \note compIdx of the main component (solvent) in the + * phase is equal to the phaseIdx */ Scalar molality(int phaseIdx, int compIdx) const // [moles/Kg] { diff --git a/dumux/porousmediumflow/mineralization/vtkoutputfields.hh b/dumux/porousmediumflow/mineralization/vtkoutputfields.hh index 70e7a2acf5..7c58cde9ba 100644 --- a/dumux/porousmediumflow/mineralization/vtkoutputfields.hh +++ b/dumux/porousmediumflow/mineralization/vtkoutputfields.hh @@ -18,7 +18,8 @@ *****************************************************************************/ /*! * \file - * \brief Adds vtk output fields specific to the twop-nc-min model + * \brief Adds vtk output fields specific to the models considering + * mineralization processes. */ #ifndef DUMUX_MINERALIZATION_VTK_OUTPUT_FIELDS_HH #define DUMUX_MINERALIZATION_VTK_OUTPUT_FIELDS_HH @@ -46,9 +47,10 @@ public: template <class VtkOutputModule> static void init(VtkOutputModule& vtk) { + // output of the model without mineralization NonMineralizationVtkOutputFields::init(vtk); - //additional output + // additional output for (int i = 0; i < numSPhases; ++i) { vtk.addVolumeVariable([i](const VolumeVariables& v){ return v.precipitateVolumeFraction(numPhases + i); },"precipVolFrac_"+ FluidSystem::phaseName(numPhases + i)); -- GitLab