diff --git a/exercises/exercise-basic/injection2p2cproblem.hh b/exercises/exercise-basic/injection2p2cproblem.hh index 754e80bfffd9b24276acfc087db246e20650c24a..790098527f172f945830c38383869b308cff43a1 100644 --- a/exercises/exercise-basic/injection2p2cproblem.hh +++ b/exercises/exercise-basic/injection2p2cproblem.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_EX_BASIC_PROBLEM_2P2C_HH #define DUMUX_EX_BASIC_PROBLEM_2P2C_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p2c/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/exercise-basic/injection2pniproblem.hh b/exercises/exercise-basic/injection2pniproblem.hh index b6ccceb7d9c5d3724e35307ab67c4681bbc05862..8f0bd5d4ca245806d189621b91c59acef63af23f 100644 --- a/exercises/exercise-basic/injection2pniproblem.hh +++ b/exercises/exercise-basic/injection2pniproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EX_BASIC_PROBLEM_2PNI_HH #define DUMUX_EX_BASIC_PROBLEM_2PNI_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/exercise-basic/injection2pproblem.hh b/exercises/exercise-basic/injection2pproblem.hh index fda74466f6e474e25794fb9759d477335c447f86..49257b1232682541981047ee238bb3a7a2a39cce 100644 --- a/exercises/exercise-basic/injection2pproblem.hh +++ b/exercises/exercise-basic/injection2pproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EX_BASIC_PROBLEM_2P_HH #define DUMUX_EX_BASIC_PROBLEM_2P_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/exercise-biomineralization/biominproblem.hh b/exercises/exercise-biomineralization/biominproblem.hh index 489d26576f5f77b491a31a52a176463debffecfc..1ed4ccec8a1288002cf9d0940ad78df18aad349e 100644 --- a/exercises/exercise-biomineralization/biominproblem.hh +++ b/exercises/exercise-biomineralization/biominproblem.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_EXERCISE_FOUR_PROBLEM_HH #define DUMUX_EXERCISE_FOUR_PROBLEM_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2pncmin/model.hh> #include <dumux/porousmediumflow/problem.hh> @@ -62,16 +64,8 @@ template<class TypeTag> struct Problem<TypeTag, TTag::ExerciseFourBioMin> { using type = ExerciseFourBioMinProblem<TypeTag>; }; //! Set grid and the grid creator to be used -#if HAVE_DUNE_ALUGRID -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFourBioMin> { using type = Dune::ALUGrid</*dim=*/2, 2, Dune::cube, Dune::nonconforming>; }; -#elif HAVE_UG -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFourBioMin> { using type = Dune::UGGrid<2>; }; -#else template<class TypeTag> struct Grid<TypeTag, TTag::ExerciseFourBioMin> { using type = Dune::YaspGrid<2>; }; -#endif // HAVE_DUNE_ALUGRID //! Set the fluid system type template<class TypeTag> diff --git a/exercises/exercise-fluidsystem/2p2cproblem.hh b/exercises/exercise-fluidsystem/2p2cproblem.hh index d6f89ad9907ac229ce22e6fcf6b434e8d4f890fc..d89d54e12dcab874d79bb8344ba45d9e7f093cb0 100644 --- a/exercises/exercise-fluidsystem/2p2cproblem.hh +++ b/exercises/exercise-fluidsystem/2p2cproblem.hh @@ -24,6 +24,9 @@ #ifndef DUMUX_EXERCISE_FLUIDSYSTEM_B_PROBLEM_HH #define DUMUX_EXERCISE_FLUIDSYSTEM_B_PROBLEM_HH +// The grid manager +#include <dune/grid/yaspgrid.hh> + // The numerical model #include <dumux/porousmediumflow/2p2c/model.hh> @@ -60,16 +63,8 @@ SET_TYPE_PROP(ExerciseFluidsystemTwoPTwoC, SpatialParams, GetPropType<TypeTag, Properties::Scalar>>); // Set grid and the grid creator to be used -#if HAVE_DUNE_ALUGRID -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoPTwoC> { using type = Dune::ALUGrid</*dim=*/2, 2, Dune::cube, Dune::nonconforming>; }; -#elif HAVE_UG -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoPTwoC> { using type = Dune::UGGrid<2>; }; -#else template<class TypeTag> struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoPTwoC> { using type = Dune::YaspGrid<2>; }; -#endif // HAVE_DUNE_ALUGRID // The fluid system property template<class TypeTag> @@ -115,9 +110,6 @@ public: : ParentType(fvGridGeometry) , eps_(3e-6) { -#if !(HAVE_DUNE_ALUGRID || HAVE_UG) - std::cout << "If you want to use simplices instead of cubes, install and use dune-ALUGrid or UGGrid." << std::endl; -#endif // !(HAVE_DUNE_ALUGRID || HAVE_UG) // initialize the fluid system FluidSystem::init(); diff --git a/exercises/exercise-fluidsystem/2pproblem.hh b/exercises/exercise-fluidsystem/2pproblem.hh index 2f945fab700c09d57162f1481440acee23a72492..f0f257204a8f7d7527eb79e3ad23b79a5df0b654 100644 --- a/exercises/exercise-fluidsystem/2pproblem.hh +++ b/exercises/exercise-fluidsystem/2pproblem.hh @@ -24,21 +24,15 @@ #ifndef DUMUX_EXERCISE_FLUIDSYSTEM_A_PROBLEM_HH #define DUMUX_EXERCISE_FLUIDSYSTEM_A_PROBLEM_HH +// The grid manager +#include <dune/grid/yaspgrid.hh> + // The numerical model #include <dumux/porousmediumflow/2p/model.hh> // The box discretization #include <dumux/discretization/box.hh> -// The grid managers -#if HAVE_DUNE_ALUGRID -#include <dune/alugrid/grid.hh> -#elif HAVE_UG -#include <dune/grid/uggrid.hh> -#else -#include <dune/grid/yaspgrid.hh> -#endif - // The porous media base problem #include <dumux/porousmediumflow/problem.hh> @@ -83,16 +77,8 @@ SET_TYPE_PROP(ExerciseFluidsystemTwoP, SpatialParams, GetPropType<TypeTag, Properties::Scalar>>); // Set grid to be used -#if HAVE_DUNE_ALUGRID -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoP> { using type = Dune::ALUGrid</*dim=*/2, 2, Dune::cube, Dune::nonconforming>; }; -#elif HAVE_UG -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoP> { using type = Dune::UGGrid<2>; }; -#else template<class TypeTag> struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoP> { using type = Dune::YaspGrid<2>; }; -#endif // HAVE_DUNE_ALUGRID // we use the immiscible fluid system here template<class TypeTag> @@ -154,9 +140,6 @@ public: : ParentType(fvGridGeometry) , eps_(3e-6) { -#if !(HAVE_DUNE_ALUGRID || HAVE_UG) - std::cout << "If you want to use simplices instead of cubes, install and use dune-ALUGrid or UGGrid." << std::endl; -#endif // !(HAVE_DUNE_ALUGRID || HAVE_UG) // initialize the tables for the water properties Components::TabulatedComponent<Components::H2O<Scalar>>::init(/*tempMin=*/273.15, diff --git a/exercises/exercise-grids/injection2pproblem.hh b/exercises/exercise-grids/injection2pproblem.hh index c5dcc7838b74bd5e439ca25d3be6a7a47895f989..b99e7eb79b21a05c0c6f09cc1a6910bdef5d82bd 100644 --- a/exercises/exercise-grids/injection2pproblem.hh +++ b/exercises/exercise-grids/injection2pproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EXGRIDS_INJECTION_PROBLEM_2P_HH #define DUMUX_EXGRIDS_INJECTION_PROBLEM_2P_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/exercise-runtimeparams/injection2pproblem.hh b/exercises/exercise-runtimeparams/injection2pproblem.hh index 456a1ab3458e5d6f8e1ab86216d2ec31d7c69508..cdae77bfb6ea1f566a33dd4c2022423bfc9bf67b 100644 --- a/exercises/exercise-runtimeparams/injection2pproblem.hh +++ b/exercises/exercise-runtimeparams/injection2pproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EXRUNTIMEPARAMS_INJECTION_PROBLEM_2P_HH #define DUMUX_EXRUNTIMEPARAMS_INJECTION_PROBLEM_2P_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/solution/exercise-basic/injection2pniproblem.hh b/exercises/solution/exercise-basic/injection2pniproblem.hh index 0fe71defd0a7d130101aa07da80525c43acaae82..6c9c835857a3bfc1445c5d1b7e46dd56dc4dc33e 100644 --- a/exercises/solution/exercise-basic/injection2pniproblem.hh +++ b/exercises/solution/exercise-basic/injection2pniproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EX_BASIC_PROBLEM_2PNI_HH #define DUMUX_EX_BASIC_PROBLEM_2PNI_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/solution/exercise-biomineralization/biominproblem.hh b/exercises/solution/exercise-biomineralization/biominproblem.hh index 672b544f177e1411734e508208bd7ef56cf617b7..9a75f3cc9e0c3288ec37af45ea72ae223057a5ce 100644 --- a/exercises/solution/exercise-biomineralization/biominproblem.hh +++ b/exercises/solution/exercise-biomineralization/biominproblem.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_EXERCISE_FOUR_PROBLEM_HH #define DUMUX_EXERCISE_FOUR_PROBLEM_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2pncmin/model.hh> #include <dumux/porousmediumflow/problem.hh> @@ -63,16 +65,8 @@ template<class TypeTag> struct Problem<TypeTag, TTag::ExerciseFourBioMin> { using type = ExerciseFourBioMinProblem<TypeTag>; }; //! Set grid and the grid creator to be used -#if HAVE_DUNE_ALUGRID -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFourBioMin> { using type = Dune::ALUGrid</*dim=*/2, 2, Dune::cube, Dune::nonconforming>; }; -#elif HAVE_UG -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFourBioMin> { using type = Dune::UGGrid<2>; }; -#else template<class TypeTag> struct Grid<TypeTag, TTag::ExerciseFourBioMin> { using type = Dune::YaspGrid<2>; }; -#endif // HAVE_DUNE_ALUGRID //! Set the fluid system type template<class TypeTag> diff --git a/exercises/solution/exercise-coupling-ff-pm/interface/ex_interface_coupling_ff-pm.cc b/exercises/solution/exercise-coupling-ff-pm/interface/ex_interface_coupling_ff-pm.cc index 0d35daec020679e40d5e42d1d41526a00d10fabc..812cae47dad7fd9a031794ae6c01560586997d04 100644 --- a/exercises/solution/exercise-coupling-ff-pm/interface/ex_interface_coupling_ff-pm.cc +++ b/exercises/solution/exercise-coupling-ff-pm/interface/ex_interface_coupling_ff-pm.cc @@ -27,6 +27,7 @@ #include <dune/common/parallel/mpihelper.hh> #include <dune/istl/io.hh> +#include <dune/grid/yaspgrid.hh> #include <dumux/common/properties.hh> #include <dumux/common/parameters.hh> diff --git a/exercises/solution/exercise-fluidsystem/2p2cproblem.hh b/exercises/solution/exercise-fluidsystem/2p2cproblem.hh index c53e9e53118c81828ef845f1dcd18d5eb8773639..09221c49e68b0eeb5faac71b70db0cf4a95a04c1 100644 --- a/exercises/solution/exercise-fluidsystem/2p2cproblem.hh +++ b/exercises/solution/exercise-fluidsystem/2p2cproblem.hh @@ -24,6 +24,9 @@ #ifndef DUMUX_EXERCISE_FLUIDSYSTEM_B_PROBLEM_HH #define DUMUX_EXERCISE_FLUIDSYSTEM_B_PROBLEM_HH +// The grid manager +#include <dune/grid/yaspgrid.hh> + // The numerical model #include <dumux/porousmediumflow/2p2c/model.hh> @@ -60,16 +63,8 @@ SET_TYPE_PROP(ExerciseFluidsystemTwoPTwoC, SpatialParams, GetPropType<TypeTag, Properties::Scalar>>); // Set grid and the grid creator to be used -#if HAVE_DUNE_ALUGRID -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoPTwoC> { using type = Dune::ALUGrid</*dim=*/2, 2, Dune::cube, Dune::nonconforming>; }; -#elif HAVE_UG -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoPTwoC> { using type = Dune::UGGrid<2>; }; -#else template<class TypeTag> struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoPTwoC> { using type = Dune::YaspGrid<2>; }; -#endif // HAVE_DUNE_ALUGRID // The fluid system property template<class TypeTag> @@ -115,10 +110,6 @@ public: : ParentType(fvGridGeometry) , eps_(3e-6) { -#if !(HAVE_DUNE_ALUGRID || HAVE_UG) - std::cout << "If you want to use simplices instead of cubes, install and use dune-ALUGrid or UGGrid." << std::endl; -#endif // !(HAVE_DUNE_ALUGRID || HAVE_UG) - // initialize the fluid system FluidSystem::init(); diff --git a/exercises/solution/exercise-fluidsystem/2pproblem.hh b/exercises/solution/exercise-fluidsystem/2pproblem.hh index b30010a2dfc58781d89c9ec025e08929ce761149..e289f9d8340d2284d2930f34a259907aa16b73eb 100644 --- a/exercises/solution/exercise-fluidsystem/2pproblem.hh +++ b/exercises/solution/exercise-fluidsystem/2pproblem.hh @@ -24,21 +24,15 @@ #ifndef DUMUX_EXERCISE_FLUIDSYSTEM_A_PROBLEM_HH #define DUMUX_EXERCISE_FLUIDSYSTEM_A_PROBLEM_HH +// The grid manager +#include <dune/grid/yaspgrid.hh> + // The numerical model #include <dumux/porousmediumflow/2p/model.hh> // The box discretization #include <dumux/discretization/box.hh> -// The grid managers -#if HAVE_DUNE_ALUGRID -#include <dune/alugrid/grid.hh> -#elif HAVE_UG -#include <dune/grid/uggrid.hh> -#else -#include <dune/grid/yaspgrid.hh> -#endif - // The porous media base problem #include <dumux/porousmediumflow/problem.hh> @@ -83,16 +77,8 @@ SET_TYPE_PROP(ExerciseFluidsystemTwoP, SpatialParams, GetPropType<TypeTag, Properties::Scalar>>); // Set grid to be used -#if HAVE_DUNE_ALUGRID -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoP> { using type = Dune::ALUGrid</*dim=*/2, 2, Dune::cube, Dune::nonconforming>; }; -#elif HAVE_UG -template<class TypeTag> -struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoP> { using type = Dune::UGGrid<2>; }; -#else template<class TypeTag> struct Grid<TypeTag, TTag::ExerciseFluidsystemTwoP> { using type = Dune::YaspGrid<2>; }; -#endif // HAVE_DUNE_ALUGRID // we use the immiscible fluid system here template<class TypeTag> @@ -154,10 +140,6 @@ public: : ParentType(fvGridGeometry) , eps_(3e-6) { -#if !(HAVE_DUNE_ALUGRID || HAVE_UG) - std::cout << "If you want to use simplices instead of cubes, install and use dune-ALUGrid or UGGrid." << std::endl; -#endif // !(HAVE_DUNE_ALUGRID || HAVE_UG) - // initialize the tables for the water properties std::cout << "Initializing the tables for the water properties" << std::endl; Components::TabulatedComponent<Components::H2O<Scalar>>::init(/*tempMin=*/273.15, diff --git a/exercises/solution/exercise-grids/injection2pproblem.hh b/exercises/solution/exercise-grids/injection2pproblem.hh index 0d9c8ba23e4f90620ae0eebce00824a7bc94b3e6..91d8701572610dc726ab0888d26d0d3c99cdaa48 100644 --- a/exercises/solution/exercise-grids/injection2pproblem.hh +++ b/exercises/solution/exercise-grids/injection2pproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EXGRIDS_INJECTION_PROBLEM_2P_HH #define DUMUX_EXGRIDS_INJECTION_PROBLEM_2P_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh> diff --git a/exercises/solution/exercise-runtimeparams/injection2pproblem.hh b/exercises/solution/exercise-runtimeparams/injection2pproblem.hh index 698432c35df4b1b23a9bd973b4428d6cfb38700d..d0ca6596626c23491b6b5b026222aec094b2b5c4 100644 --- a/exercises/solution/exercise-runtimeparams/injection2pproblem.hh +++ b/exercises/solution/exercise-runtimeparams/injection2pproblem.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_EXRUNTIMEPARAMS_INJECTION_PROBLEM_2P_HH #define DUMUX_EXRUNTIMEPARAMS_INJECTION_PROBLEM_2P_HH +#include <dune/grid/yaspgrid.hh> + #include <dumux/discretization/cctpfa.hh> #include <dumux/porousmediumflow/2p/model.hh> #include <dumux/porousmediumflow/problem.hh>