diff --git a/appl/lecture/msm/1p2cvs2p/lens_1p2c.cc b/appl/lecture/msm/1p2cvs2p/lens_1p2c.cc index b3268c87bd0396ac0f78a939f85b8fc65670eff7..551aa757de3a9ff7da2969a1622f6a3ae0f98b45 100755 --- a/appl/lecture/msm/1p2cvs2p/lens_1p2c.cc +++ b/appl/lecture/msm/1p2cvs2p/lens_1p2c.cc @@ -118,7 +118,7 @@ void usage(const char *progname) int main(int argc, char** argv) { try { - typedef TTAG(LensProblem) TypeTag; + typedef TTAG(LensProblem1p2c) TypeTag; typedef GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; typedef GET_PROP_TYPE(TypeTag, PTAG(Grid)) Grid; typedef GET_PROP_TYPE(TypeTag, PTAG(Problem)) Problem; diff --git a/appl/lecture/msm/1p2cvs2p/lens_2p.cc b/appl/lecture/msm/1p2cvs2p/lens_2p.cc index 3514b23cb2b1a95d495ea4fd1f802ca24e05ce82..1f9446f0f76693e4703eeb02f2d5e51544e50ae1 100755 --- a/appl/lecture/msm/1p2cvs2p/lens_2p.cc +++ b/appl/lecture/msm/1p2cvs2p/lens_2p.cc @@ -118,7 +118,7 @@ void usage(const char *progname) int main(int argc, char** argv) { try { - typedef TTAG(LensProblem) TypeTag; + typedef TTAG(LensProblem2p) TypeTag; typedef GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; typedef GET_PROP_TYPE(TypeTag, PTAG(Grid)) Grid; typedef GET_PROP_TYPE(TypeTag, PTAG(Problem)) Problem; diff --git a/appl/lecture/msm/1p2cvs2p/lensproblem1p2c.hh b/appl/lecture/msm/1p2cvs2p/lensproblem1p2c.hh index 8280d9064ac162396e7cb818f8c1ebf425d9d8b7..958c3d44738701ec68b25a0babced8e40e9ddac5 100644 --- a/appl/lecture/msm/1p2cvs2p/lensproblem1p2c.hh +++ b/appl/lecture/msm/1p2cvs2p/lensproblem1p2c.hh @@ -19,8 +19,8 @@ * 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_LENSPROBLEM1P2C_HH -#define DUMUX_LENSPROBLEM1P2C_HH +#ifndef DUMUX_LENS_PROBLEM_1P2C_HH +#define DUMUX_LENS_PROBLEM_1P2C_HH #if HAVE_UG #include <dune/grid/uggrid.hh> @@ -42,17 +42,17 @@ namespace Dumux { template <class TypeTag> -class LensProblem; +class LensProblem1p2c; ////////// // Specify the properties for the lens problem ////////// namespace Properties { -NEW_TYPE_TAG(LensProblem, INHERITS_FROM(BoxOnePTwoC)); +NEW_TYPE_TAG(LensProblem1p2c, INHERITS_FROM(BoxOnePTwoC)); // Set the grid type -SET_PROP(LensProblem, Grid) +SET_PROP(LensProblem1p2c, Grid) { #if HAVE_UG typedef Dune::UGGrid<2> type; @@ -63,30 +63,30 @@ SET_PROP(LensProblem, Grid) }; // Set the problem property -SET_PROP(LensProblem, Problem) +SET_PROP(LensProblem1p2c, Problem) { - typedef Dumux::LensProblem<TypeTag> type; + typedef Dumux::LensProblem1p2c<TypeTag> type; }; // Set fluid configuration -SET_PROP(LensProblem, FluidSystem) +SET_PROP(LensProblem1p2c, FluidSystem) { typedef Dumux::WaterContaminant<TypeTag> type; }; // Set the spatial parameters -SET_PROP(LensProblem, SpatialParameters) +SET_PROP(LensProblem1p2c, SpatialParameters) { typedef Dumux::LensSpatialParameters1p2c<TypeTag> type; }; // Define whether mole(true) or mass(false) fractions are used -SET_BOOL_PROP(LensProblem, UseMoles, true); +SET_BOOL_PROP(LensProblem1p2c, UseMoles, true); // Disable gravity -SET_BOOL_PROP(LensProblem, EnableGravity, false); +SET_BOOL_PROP(LensProblem1p2c, EnableGravity, false); // Disable Jacobian recycling -SET_BOOL_PROP(LensProblem, EnableJacobianRecycling, false); +SET_BOOL_PROP(LensProblem1p2c, EnableJacobianRecycling, false); } /*! @@ -118,9 +118,9 @@ SET_BOOL_PROP(LensProblem, EnableJacobianRecycling, false); * <tt>./lens_1p2c 30000 100</tt> */ template <class TypeTag > -class LensProblem : public OnePTwoCBoxProblem<TypeTag> +class LensProblem1p2c : public OnePTwoCBoxProblem<TypeTag> { - typedef LensProblem<TypeTag> ThisType; + typedef LensProblem1p2c<TypeTag> ThisType; typedef OnePTwoCBoxProblem<TypeTag> ParentType; typedef typename GET_PROP_TYPE(TypeTag, PTAG(GridView)) GridView; @@ -156,12 +156,12 @@ class LensProblem : public OnePTwoCBoxProblem<TypeTag> typedef typename GET_PROP_TYPE(TypeTag, PTAG(SolutionVector)) SolutionVector; public: - LensProblem(TimeManager &timeManager, - const GridView &gridView, - const GlobalPosition &lowerLeft, - const GlobalPosition &upperRight, - const GlobalPosition &lensLowerLeft, - const GlobalPosition &lensUpperRight) + LensProblem1p2c(TimeManager &timeManager, + const GridView &gridView, + const GlobalPosition &lowerLeft, + const GlobalPosition &upperRight, + const GlobalPosition &lensLowerLeft, + const GlobalPosition &lensUpperRight) : ParentType(timeManager, gridView) { this->spatialParameters().setLensCoords(lensLowerLeft, lensUpperRight); @@ -403,7 +403,7 @@ private: && lambda > (bboxMax_[0] - 0.55*width)/width; } - static const Scalar eps_ = 3e-6; + static constexpr Scalar eps_ = 3e-6; GlobalPosition bboxMin_; GlobalPosition bboxMax_; diff --git a/appl/lecture/msm/1p2cvs2p/lensproblem2p.hh b/appl/lecture/msm/1p2cvs2p/lensproblem2p.hh index c54d50739c2cd41fb1e3c9e36ea903bb36667851..8b108f2de95ac6f7013eab195edf155cd540160a 100644 --- a/appl/lecture/msm/1p2cvs2p/lensproblem2p.hh +++ b/appl/lecture/msm/1p2cvs2p/lensproblem2p.hh @@ -19,8 +19,8 @@ * 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_LENSPROBLEM2P_HH -#define DUMUX_LENSPROBLEM2P_HH +#ifndef DUMUX_LENSPROBLEM_2P_HH +#define DUMUX_LENSPROBLEM_2P_HH #if HAVE_UG #include <dune/grid/uggrid.hh> @@ -41,17 +41,17 @@ namespace Dumux { template <class TypeTag> -class LensProblem; +class LensProblem2p; ////////// // Specify the properties for the lens problem ////////// namespace Properties { -NEW_TYPE_TAG(LensProblem, INHERITS_FROM(BoxTwoP, LensSpatialParameters2p)); +NEW_TYPE_TAG(LensProblem2p, INHERITS_FROM(BoxTwoP, LensSpatialParameters2p)); // Set the grid type -SET_PROP(LensProblem, Grid) +SET_PROP(LensProblem2p, Grid) { #if HAVE_UG typedef Dune::UGGrid<2> type; @@ -62,13 +62,13 @@ SET_PROP(LensProblem, Grid) }; // Set the problem property -SET_PROP(LensProblem, Problem) +SET_PROP(LensProblem2p, Problem) { - typedef Dumux::LensProblem<TypeTag> type; + typedef Dumux::LensProblem2p<TypeTag> type; }; // Set the wetting phase -SET_PROP(LensProblem, WettingPhase) +SET_PROP(LensProblem2p, WettingPhase) { private: typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; @@ -77,7 +77,7 @@ public: }; // Set the non-wetting phase -SET_PROP(LensProblem, NonwettingPhase) +SET_PROP(LensProblem2p, NonwettingPhase) { private: typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; @@ -86,7 +86,7 @@ public: }; // Enable gravity -SET_BOOL_PROP(LensProblem, EnableGravity, false); +SET_BOOL_PROP(LensProblem2p, EnableGravity, false); } /*! @@ -121,9 +121,9 @@ SET_BOOL_PROP(LensProblem, EnableGravity, false); * <tt>./lens_2p 50000 100</tt> */ template <class TypeTag > -class LensProblem : public TwoPProblem<TypeTag> +class LensProblem2p : public TwoPProblem<TypeTag> { - typedef LensProblem<TypeTag> ThisType; + typedef LensProblem2p<TypeTag> ThisType; typedef TwoPProblem<TypeTag> ParentType; typedef typename GET_PROP_TYPE(TypeTag, PTAG(GridView)) GridView; @@ -171,12 +171,12 @@ class LensProblem : public TwoPProblem<TypeTag> typedef typename GET_PROP(TypeTag, PTAG(ParameterTree)) Params; public: - LensProblem(TimeManager &timeManager, - const GridView &gridView, - const GlobalPosition &lowerLeft, - const GlobalPosition &upperRight, - const GlobalPosition &lensLowerLeft, - const GlobalPosition &lensUpperRight) + LensProblem2p(TimeManager &timeManager, + const GridView &gridView, + const GlobalPosition &lowerLeft, + const GlobalPosition &upperRight, + const GlobalPosition &lensLowerLeft, + const GlobalPosition &lensUpperRight) : ParentType(timeManager, gridView) { this->spatialParameters().setLensCoords(lensLowerLeft, lensUpperRight); diff --git a/appl/lecture/msm/1p2cvs2p/lensspatialparameters1p2c.hh b/appl/lecture/msm/1p2cvs2p/lensspatialparameters1p2c.hh index ded344020ced22d42eb602c6ad06d2e1d3bf2770..642af8d4a51b180ceefc15d5449b01650af86e5b 100644 --- a/appl/lecture/msm/1p2cvs2p/lensspatialparameters1p2c.hh +++ b/appl/lecture/msm/1p2cvs2p/lensspatialparameters1p2c.hh @@ -58,7 +58,7 @@ class LensSpatialParameters1p2c : public BoxSpatialParametersOneP<TypeTag> }; typedef Dune::FieldVector<CoordScalar,dimWorld> GlobalPosition; - typedef Dune::FieldMatrix<CoordScalar,dimWorld,dimWorld> FieldMatrix; + typedef Dune::FieldMatrix<Scalar,dim,dim> Tensor; typedef typename GridView::template Codim<0>::Entity Element; typedef typename GET_PROP_TYPE(TypeTag, PTAG(FVElementGeometry)) FVElementGeometry; @@ -95,9 +95,9 @@ public: * \param scvIdx The index sub-control volume face where the * intrinsic velocity ought to be calculated. */ - const FieldMatrix& intrinsicPermeability(const Element &element, - const FVElementGeometry &fvElemGeom, - int scvIdx) const + const Tensor& intrinsicPermeability(const Element &element, + const FVElementGeometry &fvElemGeom, + int scvIdx) const { const GlobalPosition &globalPos = fvElemGeom.subContVol[scvIdx].global; if (isInLens_(globalPos)) @@ -176,8 +176,8 @@ private: GlobalPosition lensLowerLeft_; GlobalPosition lensUpperRight_; - FieldMatrix lensK_; - FieldMatrix outerK_; + Tensor lensK_; + Tensor outerK_; Scalar lensPorosity_; Scalar outerPorosity_; Scalar longitudinalDispersivity_; diff --git a/appl/lecture/msm/1p2cvs2p/lensspatialparameters2p.hh b/appl/lecture/msm/1p2cvs2p/lensspatialparameters2p.hh index 93fd762501a917a47bd0f65fe165de9ceaceddfc..969ae297c2cabd313cf38d37068e7211dc5ae81a 100644 --- a/appl/lecture/msm/1p2cvs2p/lensspatialparameters2p.hh +++ b/appl/lecture/msm/1p2cvs2p/lensspatialparameters2p.hh @@ -82,7 +82,7 @@ class LensSpatialParameters2p : public BoxSpatialParameters<TypeTag> }; typedef Dune::FieldVector<CoordScalar,dimWorld> GlobalPosition; - typedef Dune::FieldMatrix<CoordScalar,dimWorld,dimWorld> FieldMatrix; + typedef Dune::FieldMatrix<Scalar,dimWorld,dimWorld> Tensor; typedef typename GridView::template Codim<0>::Entity Element; typedef typename GET_PROP_TYPE(TypeTag, PTAG(FVElementGeometry)) FVElementGeometry; @@ -142,7 +142,7 @@ public: * \param scvIdx The index sub-control volume face where the * intrinsic velocity ought to be calculated. */ - const FieldMatrix& intrinsicPermeability(const Element &element, + const Tensor &intrinsicPermeability(const Element &element, const FVElementGeometry &fvElemGeom, int scvIdx) const { @@ -196,8 +196,8 @@ private: GlobalPosition lensLowerLeft_; GlobalPosition lensUpperRight_; - FieldMatrix lensK_; - FieldMatrix outerK_; + Tensor lensK_; + Tensor outerK_; Scalar lensPorosity_; Scalar outerPorosity_; MaterialLawParams lensMaterialParams_; diff --git a/tutorial/tutorialproblem_coupled.hh b/tutorial/tutorialproblem_coupled.hh index 972493c935e8da4268621ef27916e10d29d41714..c1cfe0ff09eb9893724919bf0b743ffbb1e8b1cd 100644 --- a/tutorial/tutorialproblem_coupled.hh +++ b/tutorial/tutorialproblem_coupled.hh @@ -23,8 +23,8 @@ * * \brief Tutorial problem for a fully coupled twophase box model. */ -#ifndef DUMUX_TUTORIALPROBLEM_COUPLED_HH // guardian macro /*@\label{tutorial-coupled:guardian1}@*/ -#define DUMUX_TUTORIALPROBLEM_COUPLED_HH // guardian macro /*@\label{tutorial-coupled:guardian2}@*/ +#ifndef DUMUX_TUTORIAL_PROBLEM_COUPLED_HH // guardian macro /*@\label{tutorial-coupled:guardian1}@*/ +#define DUMUX_TUTORIAL_PROBLEM_COUPLED_HH // guardian macro /*@\label{tutorial-coupled:guardian2}@*/ // the numerical model #include <dumux/boxmodels/2p/2pmodel.hh>