From 53ace3defc1da590d8c2eadb8bc020c33b05c5a5 Mon Sep 17 00:00:00 2001 From: Timo Koch <timo.koch@iws.uni-stuttgart.de> Date: Tue, 13 Jan 2015 16:26:21 +0000 Subject: [PATCH] This implements the task of the last dumux day for the implicit tests (common/decoupled/freeflow/geomechanics see earlier commit): In test folder: 1. change SET_TYPE_PROP instead of SET_PROP where possible 2. Remove commented code where not needed 3. Remove unnecessary includes 4. Change the neumann/dirichlet,... functions to the corresponding atPos functions where globalPos is needed The task for the multidomain folder will follow by thomas Reviewed by bernd git-svn-id: svn://svn.iws.uni-stuttgart.de/DUMUX/dumux/trunk@14046 2fb0f335-1f38-0410-981e-8018bf24f1b0 --- test/implicit/1p/1pnispatialparams.hh | 4 -- test/implicit/1p/1ptestproblem.hh | 15 ++---- test/implicit/1p2c/1p2cniconductionproblem.hh | 1 - test/implicit/1p2c/1p2cniconvectionproblem.hh | 1 - test/implicit/1p2c/1p2cnispatialparams.hh | 4 -- test/implicit/1p2c/1p2coutflowproblem.hh | 1 - .../implicit/1p2c/1p2coutflowspatialparams.hh | 4 -- test/implicit/2p/lensproblem.hh | 8 --- test/implicit/2p/lensspatialparams.hh | 7 --- test/implicit/2p2c/injectionproblem.hh | 1 - test/implicit/2p2c/injectionspatialparams.hh | 1 - test/implicit/2p2c/waterairproblem.hh | 1 - test/implicit/2p2c/waterairspatialparams.hh | 1 - test/implicit/2pdfm/2pdfmtestproblem.hh | 1 - test/implicit/3p/3pniconvectionproblem.hh | 1 - test/implicit/3p/3pnispatialparams.hh | 8 ++- test/implicit/3p3c/columnxylolproblem.hh | 1 - test/implicit/3p3c/infiltrationproblem.hh | 11 +--- .../3p3c/infiltrationspatialparameters.hh | 10 ---- test/implicit/3p3c/kuevetteproblem.hh | 4 -- test/implicit/co2/heterogeneousproblem.hh | 31 +++-------- .../co2/heterogeneousspatialparameters.hh | 24 ++------- test/implicit/co2ni/heterogeneousproblemni.hh | 17 +++--- test/implicit/mpnc/combustionproblem1c.hh | 52 +++++++++--------- .../mpnc/evaporationatmosphereproblem.hh | 53 ++++--------------- test/implicit/mpnc/forchheimer1pproblem.hh | 19 +++---- test/implicit/mpnc/forchheimer2pproblem.hh | 19 +++---- .../implicit/mpnc/forchheimerspatialparams.hh | 18 +------ test/implicit/mpnc/obstacleproblem.hh | 3 +- test/implicit/mpnc/obstaclespatialparams.hh | 17 +----- .../mpnc/test_boxmpncthermalnonequil.cc | 15 +++--- test/implicit/richards/richardslensproblem.hh | 14 +++-- .../richards/richardslensspatialparams.hh | 8 --- 33 files changed, 96 insertions(+), 279 deletions(-) diff --git a/test/implicit/1p/1pnispatialparams.hh b/test/implicit/1p/1pnispatialparams.hh index 788b1740de..3a0540d9d3 100644 --- a/test/implicit/1p/1pnispatialparams.hh +++ b/test/implicit/1p/1pnispatialparams.hh @@ -25,9 +25,6 @@ #define DUMUX_1P2CNI_OUTFLOW_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams1p.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> -#include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> -#include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> namespace Dumux { @@ -52,7 +49,6 @@ class OnePNISpatialParams : public ImplicitSpatialParamsOneP<TypeTag> typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry; typedef typename GridView::template Codim<0>::Entity Element; - //typedef LinearMaterial<Scalar> EffMaterialLaw; public: OnePNISpatialParams(const GridView &gridView) : ParentType(gridView) diff --git a/test/implicit/1p/1ptestproblem.hh b/test/implicit/1p/1ptestproblem.hh index 13fd642ee5..472bbeacc3 100644 --- a/test/implicit/1p/1ptestproblem.hh +++ b/test/implicit/1p/1ptestproblem.hh @@ -65,20 +65,15 @@ public: }; // Set the grid type -SET_PROP(OnePTestProblem, Grid) -{ - typedef Dune::YaspGrid<2> type; - //typedef Dune::UGGrid<2> type; - //typedef Dune::ALUGrid<2, 2, Dune::simplex, Dune::conforming> type; -}; +SET_TYPE_PROP(OnePTestProblem, Grid, Dune::YaspGrid<2>); +//SET_TYPE_PROP(OnePTestProblem, Grid, Dune::UGGrid<2>); +//SET_TYPE_PROP(OnePTestProblem, Grid, Dune::ALUGrid<2, 2, Dune::cube, Dune::nonconforming>); // Set the problem property -SET_PROP(OnePTestProblem, Problem) -{ typedef Dumux::OnePTestProblem<TypeTag> type; }; +SET_TYPE_PROP(OnePTestProblem, Problem, Dumux::OnePTestProblem<TypeTag> ); // Set the spatial parameters -SET_PROP(OnePTestProblem, SpatialParams) -{ typedef Dumux::OnePTestSpatialParams<TypeTag> type; }; +SET_TYPE_PROP(OnePTestProblem, SpatialParams, Dumux::OnePTestSpatialParams<TypeTag> ); // Linear solver settings SET_TYPE_PROP(OnePTestProblem, LinearSolver, Dumux::BoxBiCGStabILU0Solver<TypeTag> ); diff --git a/test/implicit/1p2c/1p2cniconductionproblem.hh b/test/implicit/1p2c/1p2cniconductionproblem.hh index c1a2597d92..e08fd56952 100644 --- a/test/implicit/1p2c/1p2cniconductionproblem.hh +++ b/test/implicit/1p2c/1p2cniconductionproblem.hh @@ -25,7 +25,6 @@ #ifndef DUMUX_1P2CNI_CONDUCTION_PROBLEM_HH #define DUMUX_1P2CNI_CONDUCTION_PROBLEM_HH -#include <math.h> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/implicit/1p2c/1p2cmodel.hh> diff --git a/test/implicit/1p2c/1p2cniconvectionproblem.hh b/test/implicit/1p2c/1p2cniconvectionproblem.hh index bd7ab33509..3dd9a22160 100644 --- a/test/implicit/1p2c/1p2cniconvectionproblem.hh +++ b/test/implicit/1p2c/1p2cniconvectionproblem.hh @@ -26,7 +26,6 @@ #ifndef DUMUX_1P2CNI_CONVECTION_PROBLEM_HH #define DUMUX_1P2CNI_CONVECTION_PROBLEM_HH -#include <math.h> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/implicit/1p2c/1p2cmodel.hh> diff --git a/test/implicit/1p2c/1p2cnispatialparams.hh b/test/implicit/1p2c/1p2cnispatialparams.hh index faf285fddf..8fe220f398 100644 --- a/test/implicit/1p2c/1p2cnispatialparams.hh +++ b/test/implicit/1p2c/1p2cnispatialparams.hh @@ -25,9 +25,6 @@ #define DUMUX_1P2CNI_OUTFLOW_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams1p.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> -#include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> -#include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> namespace Dumux { @@ -52,7 +49,6 @@ class OnePTwoCNISpatialParams : public ImplicitSpatialParamsOneP<TypeTag> typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry; typedef typename GridView::template Codim<0>::Entity Element; - //typedef LinearMaterial<Scalar> EffMaterialLaw; public: OnePTwoCNISpatialParams(const GridView &gridView) : ParentType(gridView) diff --git a/test/implicit/1p2c/1p2coutflowproblem.hh b/test/implicit/1p2c/1p2coutflowproblem.hh index 6141e2c713..79a136b16c 100644 --- a/test/implicit/1p2c/1p2coutflowproblem.hh +++ b/test/implicit/1p2c/1p2coutflowproblem.hh @@ -24,7 +24,6 @@ #ifndef DUMUX_1P2C_OUTFLOW_PROBLEM_HH #define DUMUX_1P2C_OUTFLOW_PROBLEM_HH -//#include <dune/grid/alugrid/2d/alugrid.hh> #if HAVE_UG #include <dune/grid/io/file/dgfparser/dgfug.hh> #endif diff --git a/test/implicit/1p2c/1p2coutflowspatialparams.hh b/test/implicit/1p2c/1p2coutflowspatialparams.hh index 0e19ec20e9..f12a3d5ea7 100644 --- a/test/implicit/1p2c/1p2coutflowspatialparams.hh +++ b/test/implicit/1p2c/1p2coutflowspatialparams.hh @@ -26,9 +26,6 @@ #define DUMUX_1P2C_OUTFLOW_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams1p.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> -#include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> -#include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> namespace Dumux { @@ -54,7 +51,6 @@ class OnePTwoCOutflowSpatialParams : public ImplicitSpatialParamsOneP<TypeTag> typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry; typedef typename GridView::template Codim<0>::Entity Element; - //typedef LinearMaterial<Scalar> EffMaterialLaw; public: OnePTwoCOutflowSpatialParams(const GridView &gridView) : ParentType(gridView) diff --git a/test/implicit/2p/lensproblem.hh b/test/implicit/2p/lensproblem.hh index 2fe0c4128d..a18577dff4 100644 --- a/test/implicit/2p/lensproblem.hh +++ b/test/implicit/2p/lensproblem.hh @@ -38,8 +38,6 @@ #include <dumux/implicit/common/implicitporousmediaproblem.hh> #include <dumux/implicit/cellcentered/ccpropertydefaults.hh> -#include <dumux/material/fluidsystems/h2on2fluidsystem.hh> - #include "lensspatialparams.hh" namespace Dumux @@ -67,8 +65,6 @@ SET_TYPE_PROP(LensProblem, Grid, Dune::YaspGrid<2>); // Set the problem property SET_TYPE_PROP(LensProblem, Problem, Dumux::LensProblem<TypeTag>); -// TODO: remove this macro switch -#if 1 // Set the wetting phase SET_PROP(LensProblem, WettingPhase) { @@ -86,10 +82,6 @@ private: public: typedef Dumux::LiquidPhase<Scalar, Dumux::DNAPL<Scalar> > type; }; -#else -// OR: set the fluid system -SET_TYPE_PROP(LensProblem, FluidSystem, H2ON2FluidSystem<TypeTag>); -#endif // Enable partial reassembly of the jacobian matrix? SET_BOOL_PROP(LensProblem, ImplicitEnablePartialReassemble, true); diff --git a/test/implicit/2p/lensspatialparams.hh b/test/implicit/2p/lensspatialparams.hh index 718ea6ac83..c8dc33db3c 100644 --- a/test/implicit/2p/lensspatialparams.hh +++ b/test/implicit/2p/lensspatialparams.hh @@ -127,13 +127,6 @@ public: outerMaterialParams_.setVgAlpha(0.0037); outerMaterialParams_.setVgn(4.7); - // parameters for the linear law - // minimum and maximum pressures - // lensMaterialParams_.setEntryPc(0); -// outerMaterialParams_.setEntryPc(0); -// lensMaterialParams_.setMaxPc(0); -// outerMaterialParams_.setMaxPc(0); - lensK_ = 9.05e-12; outerK_ = 4.6e-10; } diff --git a/test/implicit/2p2c/injectionproblem.hh b/test/implicit/2p2c/injectionproblem.hh index dfba62ea82..3ab8337e6c 100644 --- a/test/implicit/2p2c/injectionproblem.hh +++ b/test/implicit/2p2c/injectionproblem.hh @@ -184,7 +184,6 @@ public: eps_ = 1e-6; // initialize the tables of the fluid system - //FluidSystem::init(); FluidSystem::init(/*Tmin=*/temperatureLow_, /*Tmax=*/temperatureHigh_, /*nT=*/nTemperature_, diff --git a/test/implicit/2p2c/injectionspatialparams.hh b/test/implicit/2p2c/injectionspatialparams.hh index e0980af067..beb335273d 100644 --- a/test/implicit/2p2c/injectionspatialparams.hh +++ b/test/implicit/2p2c/injectionspatialparams.hh @@ -28,7 +28,6 @@ #define DUMUX_INJECTION_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> #include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> #include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> diff --git a/test/implicit/2p2c/waterairproblem.hh b/test/implicit/2p2c/waterairproblem.hh index d0c1569c10..9f27c5fef8 100644 --- a/test/implicit/2p2c/waterairproblem.hh +++ b/test/implicit/2p2c/waterairproblem.hh @@ -25,7 +25,6 @@ #ifndef DUMUX_WATER_AIR_PROBLEM_HH #define DUMUX_WATER_AIR_PROBLEM_HH -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/material/fluidsystems/h2on2fluidsystem.hh> diff --git a/test/implicit/2p2c/waterairspatialparams.hh b/test/implicit/2p2c/waterairspatialparams.hh index 0a1b396d80..d7a42d1a75 100644 --- a/test/implicit/2p2c/waterairspatialparams.hh +++ b/test/implicit/2p2c/waterairspatialparams.hh @@ -25,7 +25,6 @@ #define DUMUX_WATER_AIR_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> #include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> #include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> diff --git a/test/implicit/2pdfm/2pdfmtestproblem.hh b/test/implicit/2pdfm/2pdfmtestproblem.hh index 29d68ff8de..9f2302f24a 100644 --- a/test/implicit/2pdfm/2pdfmtestproblem.hh +++ b/test/implicit/2pdfm/2pdfmtestproblem.hh @@ -35,7 +35,6 @@ #include <dumux/implicit/common/implicitporousmediaproblem.hh> #include <dumux/material/components/simpleh2o.hh> #include <dumux/material/components/dnapl.hh> -#include <dumux/material/fluidsystems/h2on2fluidsystem.hh> #include <dumux/io/artgridcreator.hh> #include "2pdfmspatialparams.hh" diff --git a/test/implicit/3p/3pniconvectionproblem.hh b/test/implicit/3p/3pniconvectionproblem.hh index c62ee50209..1e842603e8 100644 --- a/test/implicit/3p/3pniconvectionproblem.hh +++ b/test/implicit/3p/3pniconvectionproblem.hh @@ -329,7 +329,6 @@ public: values[pressureIdx] = -darcyVelocity_*elemVolVars[scvIdx].density(swIdx); values[temperatureIdx] = -darcyVelocity_*elemVolVars[scvIdx].density(swIdx) *IapwsH2O::liquidEnthalpy(temperatureHigh_, elemVolVars[scvIdx].pressure(swIdx)); -// std::cout<<"values[temperatureIdx]: "<<values[temperatureIdx]<<std::endl; } } diff --git a/test/implicit/3p/3pnispatialparams.hh b/test/implicit/3p/3pnispatialparams.hh index 2b4b83ab1b..712904fedb 100644 --- a/test/implicit/3p/3pnispatialparams.hh +++ b/test/implicit/3p/3pnispatialparams.hh @@ -70,7 +70,6 @@ class ThreePNISpatialParams : public ImplicitSpatialParams<TypeTag> typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry; typedef typename GridView::template Codim<0>::Entity Element; - //typedef LinearMaterial<Scalar> EffMaterialLaw; public: typedef typename GET_PROP_TYPE(TypeTag, MaterialLaw) MaterialLaw; @@ -87,7 +86,6 @@ public: // residual saturations - materialParams_.setSwr(0.12); materialParams_.setSwrx(0.12); materialParams_.setSnr(0.10); @@ -129,7 +127,7 @@ public: const FVElementGeometry &fvGeometry, const int scvIdx) const { - return permeability_; + return permeability_; } /*! @@ -143,7 +141,7 @@ public: const FVElementGeometry &fvGeometry, const int scvIdx) const { - return porosity_; + return porosity_; } /*! @@ -157,7 +155,7 @@ public: const FVElementGeometry &fvGeometry, const int scvIdx) const { - return materialParams_; + return materialParams_; } diff --git a/test/implicit/3p3c/columnxylolproblem.hh b/test/implicit/3p3c/columnxylolproblem.hh index 2f81f45658..7b7be4e61e 100644 --- a/test/implicit/3p3c/columnxylolproblem.hh +++ b/test/implicit/3p3c/columnxylolproblem.hh @@ -25,7 +25,6 @@ #ifndef DUMUX_COLUMNXYLOLPROBLEM_HH #define DUMUX_COLUMNXYLOLPROBLEM_HH -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/material/fluidsystems/h2oairxylenefluidsystem.hh> diff --git a/test/implicit/3p3c/infiltrationproblem.hh b/test/implicit/3p3c/infiltrationproblem.hh index eb4f478ff1..c81438bdc0 100644 --- a/test/implicit/3p3c/infiltrationproblem.hh +++ b/test/implicit/3p3c/infiltrationproblem.hh @@ -25,7 +25,6 @@ #ifndef DUMUX_INFILTRATIONPROBLEM_HH #define DUMUX_INFILTRATIONPROBLEM_HH -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/material/fluidsystems/h2oairmesitylenefluidsystem.hh> @@ -267,10 +266,6 @@ public: values[switch1Idx] = 1.-sgr; values[switch2Idx] = 1.e-6; } - - //initial_(values, globalPos, element); - //const MaterialLawParams& materialParams = this->spatialParams().materialLawParams(); - //MaterialLaw::pcgw(materialParams, 1.0); } /*! @@ -306,7 +301,7 @@ public: if ((globalPos[0] <= 75.+eps_) && (globalPos[0] >= 50.+eps_) && (globalPos[1] >= 10.-eps_)) { values[contiWEqIdx] = -0.0; - values[contiNEqIdx] = -0.001, // /*Molfluss, umr. über M(Mesit.)=0,120 kg/mol --> 1.2e-4 kg/(sm) + values[contiNEqIdx] = -0.001, //mole flow, convertion to mass flow with molar mass M(Mesit.)=0,120 kg/mol --> 1.2e-4 kg/(sm) values[contiAEqIdx] = -0.0; } } @@ -343,7 +338,6 @@ public: int &vIdxGlobal, const GlobalPosition &globalPos) const { - // return threePhases; return wgPhaseOnly; } @@ -380,8 +374,7 @@ public: } private: - // internal method for the initial condition (reused for the - // dirichlet conditions!) + // internal method for the initial condition void initial_(PrimaryVariables &values, const GlobalPosition &globalPos) const { diff --git a/test/implicit/3p3c/infiltrationspatialparameters.hh b/test/implicit/3p3c/infiltrationspatialparameters.hh index 647ab00bc1..bf12030d40 100644 --- a/test/implicit/3p3c/infiltrationspatialparameters.hh +++ b/test/implicit/3p3c/infiltrationspatialparameters.hh @@ -168,11 +168,6 @@ public: const FVElementGeometry &fvGeometry, int scvIdx) const { - //const GlobalPosition &globalPos = fvGeometry.subContVol[scvIdx].global; - // if (isFineMaterial_(globalPos)) - // return finePorosity_; - // else - // return coarsePorosity_; return Porosity_; } @@ -188,11 +183,6 @@ public: const FVElementGeometry &fvGeometry, int scvIdx) const { - //const GlobalPosition &globalPos = fvGeometry.subContVol[scvIdx].global; - //if (isFineMaterial_(globalPos)) - //return fineMaterialParams_; - //else - //return coarseMaterialParams_; return MaterialParams_; } diff --git a/test/implicit/3p3c/kuevetteproblem.hh b/test/implicit/3p3c/kuevetteproblem.hh index e9dba62ac2..21313afceb 100644 --- a/test/implicit/3p3c/kuevetteproblem.hh +++ b/test/implicit/3p3c/kuevetteproblem.hh @@ -26,7 +26,6 @@ #ifndef DUMUX_KUEVETTE3P3CNIPROBLEM_HH #define DUMUX_KUEVETTE3P3CNIPROBLEM_HH -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/material/fluidsystems/h2oairmesitylenefluidsystem.hh> @@ -66,9 +65,6 @@ SET_BOOL_PROP(KuevetteProblem, ProblemEnableGravity, true); // Use central differences (backward -1, forward +1) SET_INT_PROP(KuevetteProblem, ImplicitNumericDifferenceMethod, 0); -// Write newton convergence -//SET_BOOL_PROP(KuevetteProblem, NewtonWriteConvergence, true); - // Set the maximum time step SET_SCALAR_PROP(KuevetteProblem, TimeManagerMaxTimeStepSize, 60.); diff --git a/test/implicit/co2/heterogeneousproblem.hh b/test/implicit/co2/heterogeneousproblem.hh index 9fb447f7f1..3711137b91 100644 --- a/test/implicit/co2/heterogeneousproblem.hh +++ b/test/implicit/co2/heterogeneousproblem.hh @@ -30,6 +30,7 @@ #include <dune/alugrid/grid.hh> #else #warning ALUGrid is necessary for this test. +#include <dune/grid/io/file/dgfparser/dgfyasp.hh> #endif #include <dumux/implicit/co2/co2model.hh> @@ -54,20 +55,6 @@ NEW_TYPE_TAG(HeterogeneousProblem, INHERITS_FROM(TwoPTwoC, HeterogeneousSpatialP NEW_TYPE_TAG(HeterogeneousBoxProblem, INHERITS_FROM(BoxModel, HeterogeneousProblem)); NEW_TYPE_TAG(HeterogeneousCCProblem, INHERITS_FROM(CCModel, HeterogeneousProblem)); -//NEW_PROP_TAG(BaseProblem); -//SET_TYPE_PROP(HeterogeneousBoxProblem, BaseProblem, ImplicitPorousMediaProblem<TypeTag>); -//SET_TYPE_PROP(HeterogeneousCCProblem, BaseProblem, ImplicitPorousMediaProblem<TypeTag>); -//// Set the grid type -//SET_PROP(HeterogeneousProblem, Grid) -//{ -// //typedef Dune::UGGrid<2> type; -//#if HAVE_ALUGRID || HAVE_DUNE_ALUGRID -// typedef Dune::ALUGrid<2, 2, Dune::cube, Dune::nonconforming> type; -//#else -//#warning If you want to run this problem, install and use ALUGrid. -//#endif -//}; - // Set the grid type #if HAVE_ALUGRID || HAVE_DUNE_ALUGRID SET_TYPE_PROP(HeterogeneousProblem, Grid, Dune::ALUGrid<2, 2, Dune::cube, Dune::nonconforming>); @@ -76,19 +63,14 @@ SET_TYPE_PROP(HeterogeneousProblem, Grid, Dune::YaspGrid<2>); #endif // Set the problem property -SET_PROP(HeterogeneousProblem, Problem) -{ - typedef Dumux::HeterogeneousProblem<TypeTag> type; -}; +SET_TYPE_PROP(HeterogeneousProblem, Problem, Dumux::HeterogeneousProblem<TypeTag>); // Set fluid configuration -SET_PROP(HeterogeneousProblem, FluidSystem) -{ - typedef Dumux::BrineCO2FluidSystem<TypeTag> type; -}; +SET_TYPE_PROP(HeterogeneousProblem, FluidSystem, Dumux::BrineCO2FluidSystem<TypeTag>); // Set the CO2 table to be used; in this case not the the default table SET_TYPE_PROP(HeterogeneousProblem, CO2Table, Dumux::HeterogeneousCO2Tables::CO2Tables); + // Set the salinity mass fraction of the brine in the reservoir SET_SCALAR_PROP(HeterogeneousProblem, ProblemSalinity, 1e-1); @@ -233,7 +215,6 @@ public: eps_ = 1e-6; // initialize the tables of the fluid system - //FluidSystem::init(); FluidSystem::init(/*Tmin=*/temperatureLow_, /*Tmax=*/temperatureHigh_, /*nT=*/nTemperature_, @@ -434,7 +415,7 @@ public: * Negative values indicate an inflow. * * Depending on whether useMoles is set on true or false, the flux has to be given either in - * kg/(m^2*s) or mole/(m^2*s) in the input file!! + * kg/(m^2*s) or mole/(m^2*s) in the input file!! Convertion with molar mass obtained from fluid system FluidSystem::molarMass(nCompIdx) */ void neumann(PrimaryVariables &values, const Element &element, @@ -448,7 +429,7 @@ public: values = 0; if (boundaryId == injectionBottom_) { - values[contiCO2EqIdx] = -injectionRate_; ///FluidSystem::molarMass(nCompIdx); // kg/(s*m^2) or mole/(m^2*s) !! + values[contiCO2EqIdx] = -injectionRate_; //see above: either give in kg/(m^2*s) or mole/(m^2*s) depending on useMoles } } diff --git a/test/implicit/co2/heterogeneousspatialparameters.hh b/test/implicit/co2/heterogeneousspatialparameters.hh index dfa2aaaad8..92c4668262 100644 --- a/test/implicit/co2/heterogeneousspatialparameters.hh +++ b/test/implicit/co2/heterogeneousspatialparameters.hh @@ -28,7 +28,6 @@ #define DUMUX_HETEROGENEOUS_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> #include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> #include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> @@ -102,9 +101,6 @@ public: { /* * Layer Index Setup: - * barrierTop = 1 - * barrierMiddle = 2 - * reservoir = 3 */ barrierTop_ = 1; barrierMiddle_ = 2; @@ -113,26 +109,16 @@ public: // heat conductivity of granite lambdaSolid_ = 2.8; - //Set the permeability tensor for the layers - //Scalar anisotropy = 0.1; - //for (int i = 0; i < dim; i++) - barrierTopK_ = 1e-17; //sqm - //barrierTopK_[dim-1][dim-1] = barrierTopK_[0][0]*anisotropy; - - //for (int i = 0; i < dim; i++) - barrierMiddleK_ = 1e-15; //sqm - //barrierMiddleK_[dim-1][dim-1] = barrierMiddleK_[0][0]*anisotropy; - - // for (int i = 0; i < dim; i++) - reservoirK_ = 1e-14; //sqm - //reservoirK_[dim-1][dim-1] = reservoirK_[0][0]*anisotropy; + //Set the permeability for the layers + barrierTopK_ = 1e-17; //sqm + barrierMiddleK_ = 1e-15; //sqm + reservoirK_ = 1e-14; //sqm //Set the effective porosity of the layers barrierTopPorosity_ = 0.001; barrierMiddlePorosity_ = 0.05; reservoirPorosity_ = 0.2; - // Same material parameters for every layer materialParams_.setSwr(0.2); materialParams_.setSwr(0.05); @@ -220,7 +206,6 @@ public: const FVElementGeometry &fvGeometry, int scvIdx) const { - return materialParams_; } @@ -265,7 +250,6 @@ public: private: - int barrierTop_; int barrierMiddle_; int reservoir_; diff --git a/test/implicit/co2ni/heterogeneousproblemni.hh b/test/implicit/co2ni/heterogeneousproblemni.hh index e9fc1208fa..cc4c7af46d 100644 --- a/test/implicit/co2ni/heterogeneousproblemni.hh +++ b/test/implicit/co2ni/heterogeneousproblemni.hh @@ -30,6 +30,7 @@ #include <dune/alugrid/grid.hh> #else #warning ALUGrid is necessary for this test. +#include <dune/grid/io/file/dgfparser/dgfyasp.hh> #endif #include <dumux/implicit/2p2c/2p2cmodel.hh> @@ -65,19 +66,14 @@ SET_TYPE_PROP(HeterogeneousNIProblem, Grid, Dune::YaspGrid<2>); #endif // Set the problem property -SET_PROP(HeterogeneousNIProblem, Problem) -{ - typedef Dumux::HeterogeneousNIProblem<TypeTag> type; -}; +SET_TYPE_PROP(HeterogeneousNIProblem, Problem, Dumux::HeterogeneousNIProblem<TypeTag>); // Set fluid configuration -SET_PROP(HeterogeneousNIProblem, FluidSystem) -{ - typedef Dumux::BrineCO2FluidSystem<TypeTag> type; -}; +SET_TYPE_PROP(HeterogeneousNIProblem, FluidSystem, Dumux::BrineCO2FluidSystem<TypeTag>); // Set the CO2 table to be used; in this case not the the default table SET_TYPE_PROP(HeterogeneousNIProblem, CO2Table, Dumux::Heterogeneous::CO2Tables); + // Set the salinity mass fraction of the brine in the reservoir SET_SCALAR_PROP(HeterogeneousNIProblem, ProblemSalinity, 1e-1); @@ -229,7 +225,6 @@ public: eps_ = 1e-6; // initialize the tables of the fluid system - //FluidSystem::init(); FluidSystem::init(/*Tmin=*/temperatureLow_, /*Tmax=*/temperatureHigh_, /*nT=*/nTemperature_, @@ -440,7 +435,7 @@ public: * Negative values indicate an inflow. * * Depending on whether useMoles is set on true or false, the flux has to be given either in - * kg/(m^2*s) or mole/(m^2*s) in the input file!! + * kg/(m^2*s) or mole/(m^2*s) in the input file!! Convert dividing by molar mass from the fluid system FluidSystem::molarMass(CO2Idx) */ void neumann(PrimaryVariables &values, const Element &element, @@ -454,7 +449,7 @@ public: values = 0; if (boundaryId == injectionBottom_) { - values[contiCO2EqIdx] = -injectionRate_; ///FluidSystem::molarMass(CO2Idx); // kg/(s*m^2) or mole/(m^2*s) !! + values[contiCO2EqIdx] = -injectionRate_; // see above comment: kg/(s*m^2) or mole/(m^2*s) depending on useMoles!! #if !ISOTHERMAL values[energyEqIdx] = -injectionRate_/*kg/(m^2 s)*/*CO2::gasEnthalpy( injectionTemperature_, injectionPressure_)/*J/kg*/; // W/(m^2) diff --git a/test/implicit/mpnc/combustionproblem1c.hh b/test/implicit/mpnc/combustionproblem1c.hh index 5021e25345..396a371ba2 100644 --- a/test/implicit/mpnc/combustionproblem1c.hh +++ b/test/implicit/mpnc/combustionproblem1c.hh @@ -68,22 +68,23 @@ NEW_TYPE_TAG(CombustionProblemOneComponent, INHERITS_FROM(BoxMPNCKinetic, CombustionSpatialParams)); // Set the grid type -SET_PROP(CombustionProblemOneComponent, Grid){ -typedef typename Dune::OneDGrid type; -}; +SET_TYPE_PROP(CombustionProblemOneComponent, Grid, Dune::OneDGrid); -SET_TYPE_PROP(CombustionProblemOneComponent, LinearSolver, - SuperLUBackend<TypeTag>); +#if HAVE_SUPERLU +SET_TYPE_PROP(CombustionProblemOneComponent, LinearSolver, SuperLUBackend<TypeTag>); +#endif // Set the problem property -SET_TYPE_PROP (CombustionProblemOneComponent, +SET_TYPE_PROP(CombustionProblemOneComponent, Problem, Dumux::CombustionProblemOneComponent<TTAG(CombustionProblemOneComponent)>); // Set fluid configuration SET_PROP(CombustionProblemOneComponent, FluidSystem){ -private: typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; -public: typedef Dumux::FluidSystems::PureWaterSimpleFluidSystem<Scalar, /*useComplexRelations=*/false> type; +private: + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; +public: + typedef Dumux::FluidSystems::PureWaterSimpleFluidSystem<Scalar, /*useComplexRelations=*/false> type; }; // Set the newton controller @@ -125,16 +126,14 @@ SET_BOOL_PROP(CombustionProblemOneComponent, ImplicitEnableJacobianRecycling, tr SET_BOOL_PROP(CombustionProblemOneComponent, NewtonWriteConvergence, false); //! Franz Lindners simple lumping -SET_PROP(CombustionProblemOneComponent, ThermalConductivityModel){ -public: typedef ThermalConductivitySimpleFluidLumping<TypeTag> type; -}; +SET_TYPE_PROP(CombustionProblemOneComponent, ThermalConductivityModel, ThermalConductivitySimpleFluidLumping<TypeTag>); //################# // Which Code to compile // Specify whether there is any energy equation SET_BOOL_PROP(CombustionProblemOneComponent, EnableEnergy, true); // Specify whether the kinetic energy module is used -SET_INT_PROP(CombustionProblemOneComponent, NumEnergyEquations, 2 ); +SET_INT_PROP(CombustionProblemOneComponent, NumEnergyEquations, 2); // Specify whether the kinetic mass module is use SET_BOOL_PROP(CombustionProblemOneComponent, EnableKinetic, false); //################# @@ -144,10 +143,14 @@ SET_BOOL_PROP(CombustionProblemOneComponent, EnableKinetic, false); * store the thermodynamic state. This has to be chosen * appropriately for the model ((non-)isothermal, equilibrium, ...). */ -SET_PROP(CombustionProblemOneComponent, FluidState){ -private: typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; -private: typedef typename GET_PROP_TYPE(TypeTag, FluidSystem) FluidSystem; -public: typedef Dumux::CompositionalFluidState<Scalar, FluidSystem> type; +SET_PROP(CombustionProblemOneComponent, FluidState) +{ +private: + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; +private: + typedef typename GET_PROP_TYPE(TypeTag, FluidSystem) FluidSystem; +public: + typedef Dumux::CompositionalFluidState<Scalar, FluidSystem> type; }; SET_BOOL_PROP(CombustionProblemOneComponent, UseMaxwellDiffusion, false); @@ -441,10 +444,9 @@ public: * \param bTypes The bounentraldary types for the conservation equations * \param vertex The vertex for which the boundary type is set */ - void boundaryTypes(BoundaryTypes & bTypes, const Vertex &vertex) const + void boundaryTypesAtPos(BoundaryTypes &bTypes, + const GlobalPosition &globalPos) const { - const GlobalPosition & globalPos = vertex.geometry().center(); - // Default: Neumann bTypes.setAllNeumann(); @@ -463,9 +465,9 @@ public: * * For this method, the \a values parameter stores primary variables. */ - void dirichlet(PrimaryVariables &priVars, const Vertex &vertex) const + void dirichletAtPos(PrimaryVariables &priVars, + const GlobalPosition &globalPos) const { - const GlobalPosition globalPos = vertex.geometry().center(); initial_(priVars, globalPos); } @@ -584,13 +586,9 @@ public: * \param scvIdx The local index of the sub-control volume * */ - void initial(PrimaryVariables &values, - const Element &element, - const FVElementGeometry &fvGeometry, - const unsigned int scvIdx) const + void initialAtPos(PrimaryVariables &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = element.geometry().corner(scvIdx); - initial_(values, globalPos); } diff --git a/test/implicit/mpnc/evaporationatmosphereproblem.hh b/test/implicit/mpnc/evaporationatmosphereproblem.hh index 6440e0dcfc..57fbc24e32 100644 --- a/test/implicit/mpnc/evaporationatmosphereproblem.hh +++ b/test/implicit/mpnc/evaporationatmosphereproblem.hh @@ -94,15 +94,6 @@ SET_PROP(EvaporationAtmosphereProblem, Grid) #endif }; -//#if HAVE_SUPERLU -//SET_TYPE_PROP(EvaporationAtmosphereProblem, LinearSolver, SuperLUBackend<TypeTag>); -//#else -//#warning "Evaporation Atmosphere skipped, needs Super LU." << std::endl; -//return 77; -//#endif - -//SET_TYPE_PROP(EvaporationAtmosphereProblem, LinearSolver, Dumux::BoxCGGSSolver<TypeTag> ); - // Set the problem property SET_TYPE_PROP(EvaporationAtmosphereProblem, Problem, @@ -452,11 +443,9 @@ public: * \param bTypes The boundarytypes types for the conservation equations * \param vertex The vertex for which the boundary type is set */ - void boundaryTypes(BoundaryTypes & bTypes, - const Vertex & vertex) const + void boundaryTypesAtPos(BoundaryTypes &bTypes, + const GlobalPosition &globalPos) const { - const GlobalPosition & globalPos = vertex.geometry().center(); - // Default: Neumann bTypes.setAllNeumann(); @@ -464,9 +453,6 @@ public: if(onRightBoundary_(globalPos) and this->spatialParams().inFF_(globalPos) ) { bTypes.setAllOutflow(); -// values.setDirichlet(S0Idx); -// values.setDirichlet(p0Idx); -// values.setAllDirichlet(); } // Put a dirichlet somewhere: we need this for convergence @@ -495,10 +481,9 @@ public: * \param vertex The vertex for which the boundary type is set * */ - void dirichlet(PrimaryVariables & priVars, - const Vertex & vertex) const + void dirichletAtPos(PrimaryVariables &priVars, + const GlobalPosition &globalPos) const { - const GlobalPosition globalPos = vertex.geometry().center(); initial_(priVars, globalPos); } @@ -530,8 +515,8 @@ public: // distinction via vertex works better in this case, because this is also how the // permeabilities & co are defined. This way there is only injection in the free flow and // not also in the last porous medium node. - const GlobalPosition & globalPos = fvGeometry.subContVol[scvIdx].global ; - + const GlobalPosition & globalPos = fvGeometry.subContVol[scvIdx].global; + priVars = 0.0; const Scalar massFluxInjectedPhase = massFluxInjectedPhase_ ; @@ -613,13 +598,9 @@ public: * \param fvGeometry The finite volume geometry of the element * \param scvIdx The local index of the sub-control volume */ - void initial(PrimaryVariables & priVars, - const Element & element, - const FVElementGeometry & fvGeometry, - const unsigned int scvIdx) const + void initialAtPos(PrimaryVariables &priVars, + const GlobalPosition &globalPos) const { - const GlobalPosition & globalPos = element.geometry().corner(scvIdx); - initial_(priVars, globalPos); } @@ -692,15 +673,7 @@ private: Scalar p[numPhases]; if (this->spatialParams().inPM_(globalPos)){ - // hydrostatic distribution for initial water pressure distribution - // This should work better. Alas: it doesn't. - // The same pressure distribution arises, but with initially no hydrostatics prescribed - // much better convergence is achieved. -// const Scalar densityW = 998.23; // from first timestep result -// p[wPhaseIdx] = pnInitial_ + densityW*(-1)*this->gravity()[dim-1]*(this->spatialParams().heightPM() -// - globalPos[dim-1]) - std::abs(capPress[wPhaseIdx]); - - // Therefore: use homogenous pressure in the domain and let the newton find the pressure distribution + // Use homogenous pressure in the domain and let the newton find the pressure distribution p[wPhaseIdx] = pnInitial_ - std::abs(capPress[wPhaseIdx]); p[nPhaseIdx] = p[wPhaseIdx] + std::abs(capPress[wPhaseIdx]); } @@ -710,13 +683,7 @@ private: } else DUNE_THROW(Dune::InvalidStateException, "You should not be here: x=" << globalPos[0] << " y= "<< globalPos[dim-1]); - -// // In case we wanted to have elevated pressure on inflow for a dirichlet BC -// if(onLeftBoundary_(globalPos) and (this->spatialParams().inFF_(globalPos))) -// { -// p[nPhaseIdx] = pnInjection_ ; -// } - + if(pressureFormulation == mostWettingFirst){ // This means that the pressures are sorted from the most wetting to the least wetting-1 in the primary variables vector. // For two phases this means that there is one pressure as primary variable: pw diff --git a/test/implicit/mpnc/forchheimer1pproblem.hh b/test/implicit/mpnc/forchheimer1pproblem.hh index a3d93f91bd..138d297749 100644 --- a/test/implicit/mpnc/forchheimer1pproblem.hh +++ b/test/implicit/mpnc/forchheimer1pproblem.hh @@ -27,7 +27,6 @@ #include <dune/common/parametertreeparser.hh> -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/implicit/mpnc/mpncmodel.hh> @@ -283,10 +282,9 @@ public: * \param values The boundary types for the conservation equations * \param vertex The vertex for which the boundary type is set */ - void boundaryTypes(BoundaryTypes &values, const Vertex &vertex) const + void boundaryTypesAtPos(BoundaryTypes &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = vertex.geometry().center(); - if (onLeftBoundary_(globalPos) or onRightBoundary_(globalPos)) values.setAllDirichlet(); else @@ -303,10 +301,9 @@ public: * * For this method, the \a values parameter stores primary variables. */ - void dirichlet(PrimaryVariables &values, const Vertex &vertex) const + void dirichletAtPos(PrimaryVariables &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = vertex.geometry().center(); - initial_(values, globalPos); } @@ -368,13 +365,9 @@ public: * \param fvGeometry The finite volume geometry of the element * \param scvIdx The local index of the sub-control volume */ - void initial(PrimaryVariables &values, - const Element &element, - const FVElementGeometry &fvGeometry, - const unsigned int scvIdx) const + void initialAtPos(PrimaryVariables &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = element.geometry().corner(scvIdx); - initial_(values, globalPos); Valgrind::CheckDefined(values); } diff --git a/test/implicit/mpnc/forchheimer2pproblem.hh b/test/implicit/mpnc/forchheimer2pproblem.hh index 8d58f43512..29475d8b26 100644 --- a/test/implicit/mpnc/forchheimer2pproblem.hh +++ b/test/implicit/mpnc/forchheimer2pproblem.hh @@ -25,7 +25,6 @@ #include <dune/common/parametertreeparser.hh> -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/implicit/mpnc/mpncmodel.hh> @@ -275,10 +274,9 @@ public: * \param values The boundary types for the conservation equations * \param vertex The vertex for which the boundary type is set */ - void boundaryTypes(BoundaryTypes &values, const Vertex &vertex) const + void boundaryTypesAtPos(BoundaryTypes &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = vertex.geometry().center(); - if (onLeftBoundary_(globalPos) or onRightBoundary_(globalPos)) values.setAllDirichlet(); else @@ -295,10 +293,9 @@ public: * * For this method, the \a values parameter stores primary variables. */ - void dirichlet(PrimaryVariables &values, const Vertex &vertex) const + void dirichletAtPos(PrimaryVariables &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = vertex.geometry().center(); - initial_(values, globalPos); } @@ -360,13 +357,9 @@ public: * \param fvGeometry The finite volume geometry of the element * \param scvIdx The local index of the sub-control volume */ - void initial(PrimaryVariables &values, - const Element &element, - const FVElementGeometry &fvGeometry, - const unsigned int scvIdx) const + void initialAtPos(PrimaryVariables &values, + const GlobalPosition &globalPos) const { - const GlobalPosition &globalPos = element.geometry().corner(scvIdx); - initial_(values, globalPos); Valgrind::CheckDefined(values); } diff --git a/test/implicit/mpnc/forchheimerspatialparams.hh b/test/implicit/mpnc/forchheimerspatialparams.hh index 2825fb75dd..5ae01acf4b 100644 --- a/test/implicit/mpnc/forchheimerspatialparams.hh +++ b/test/implicit/mpnc/forchheimerspatialparams.hh @@ -27,9 +27,7 @@ #define DUMUX_FORCHHEIMER_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> #include <dumux/material/fluidmatrixinteractions/2p/regularizedlinearmaterial.hh> -#include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> #include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> #include <dumux/implicit/mpnc/mpncmodel.hh> @@ -59,9 +57,8 @@ private: enum {wPhaseIdx = FluidSystem::wPhaseIdx}; // define the material law typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; -// typedef RegularizedBrooksCorey<Scalar> EffMaterialLaw; - typedef RegularizedLinearMaterial<Scalar> EffMaterialLaw; - typedef EffToAbsLaw<EffMaterialLaw> TwoPMaterialLaw; + typedef RegularizedLinearMaterial<Scalar> EffMaterialLaw; + typedef EffToAbsLaw<EffMaterialLaw> TwoPMaterialLaw; public: typedef TwoPAdapter<wPhaseIdx, TwoPMaterialLaw> type; }; @@ -104,7 +101,6 @@ public: // the porosity porosity_ = 0.3; - // residual saturations materialParams_.setSwr(0.0); materialParams_.setSnr(0.0); @@ -113,16 +109,6 @@ public: // pressures materialParams_.setEntryPc(0.0); materialParams_.setMaxPc(0.0); - - - /* - // entry pressures for Brooks-Corey - materialParams_.setPe(1e3); - - // Brooks-Corey shape parameters - materialParams_.setLambda(2); - */ - } ~ForchheimerSpatialParams() diff --git a/test/implicit/mpnc/obstacleproblem.hh b/test/implicit/mpnc/obstacleproblem.hh index 5af3e7c11f..28ae7571e0 100644 --- a/test/implicit/mpnc/obstacleproblem.hh +++ b/test/implicit/mpnc/obstacleproblem.hh @@ -27,7 +27,6 @@ #include <dune/common/parametertreeparser.hh> -#include <dune/grid/io/file/dgfparser/dgfug.hh> #include <dune/grid/io/file/dgfparser/dgfyasp.hh> #include <dumux/implicit/mpnc/mpncmodel.hh> @@ -173,7 +172,7 @@ public: : ParentType(timeManager, gridView) { eps_ = 1e-6; - temperature_ = 273.15 + 25; // -> 25DegC + temperature_ = 273.15 + 25; // -> 25°C // initialize the tables of the fluid system Scalar Tmin = temperature_ - 1.0; diff --git a/test/implicit/mpnc/obstaclespatialparams.hh b/test/implicit/mpnc/obstaclespatialparams.hh index 4ea90713a8..c16abc023f 100644 --- a/test/implicit/mpnc/obstaclespatialparams.hh +++ b/test/implicit/mpnc/obstaclespatialparams.hh @@ -26,9 +26,7 @@ #define DUMUX_OBSTACLE_SPATIAL_PARAMS_HH #include <dumux/material/spatialparams/implicitspatialparams.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> #include <dumux/material/fluidmatrixinteractions/2p/regularizedlinearmaterial.hh> -#include <dumux/material/fluidmatrixinteractions/2p/regularizedbrookscorey.hh> #include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> #include <dumux/implicit/mpnc/mpncmodel.hh> @@ -58,9 +56,8 @@ private: enum {wPhaseIdx = FluidSystem::wPhaseIdx}; // define the material law typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; - // typedef RegularizedBrooksCorey<Scalar> EffMaterialLaw; - typedef RegularizedLinearMaterial<Scalar> EffMaterialLaw; - typedef EffToAbsLaw<EffMaterialLaw> TwoPMaterialLaw; + typedef RegularizedLinearMaterial<Scalar> EffMaterialLaw; + typedef EffToAbsLaw<EffMaterialLaw> TwoPMaterialLaw; public: typedef TwoPAdapter<wPhaseIdx, TwoPMaterialLaw> type; }; @@ -116,16 +113,6 @@ public: coarseMaterialParams_.setEntryPc(0.0); fineMaterialParams_.setMaxPc(0.0); coarseMaterialParams_.setMaxPc(0.0); - - /* - // entry pressures for Brooks-Corey - fineMaterialParams_.setPe(5e3); - coarseMaterialParams_.setPe(1e3); - - // Brooks-Corey shape parameters - fineMaterialParams_.setLambda(2); - coarseMaterialParams_.setLambda(2); - */ } ~ObstacleSpatialParams() diff --git a/test/implicit/mpnc/test_boxmpncthermalnonequil.cc b/test/implicit/mpnc/test_boxmpncthermalnonequil.cc index ad9b41e682..e2c062fe9d 100644 --- a/test/implicit/mpnc/test_boxmpncthermalnonequil.cc +++ b/test/implicit/mpnc/test_boxmpncthermalnonequil.cc @@ -21,10 +21,8 @@ */ #include "config.h" -//#include "combustionproblem.hh" #include "combustionproblem1c.hh" - #include <dumux/common/start.hh> /*! @@ -59,8 +57,13 @@ void usage(const char *progName, const std::string &errorMsg) } int main(int argc, char** argv) -{ -// typedef TTAG(CombustionProblem) ProblemTypeTag; - typedef TTAG(CombustionProblemOneComponent) ProblemTypeTag; - return Dumux::start<ProblemTypeTag>(argc, argv, usage); +{ +#if HAVE_SUPERLU + typedef TTAG(CombustionProblemOneComponent) ProblemTypeTag; + return Dumux::start<ProblemTypeTag>(argc, argv, usage); +#else +#warning CombustionProblemOneComponent skipped, needs Super LU! + return 77; +#endif + } diff --git a/test/implicit/richards/richardslensproblem.hh b/test/implicit/richards/richardslensproblem.hh index 8538f1260a..f691edfdd6 100644 --- a/test/implicit/richards/richardslensproblem.hh +++ b/test/implicit/richards/richardslensproblem.hh @@ -40,9 +40,8 @@ namespace Dumux template <class TypeTag> class RichardsLensProblem; -////////// + // Specify the properties for the lens problem -////////// namespace Properties { NEW_TYPE_TAG(RichardsLensProblem, INHERITS_FROM(Richards, RichardsLensSpatialParams)); @@ -53,8 +52,7 @@ NEW_TYPE_TAG(RichardsLensCCProblem, INHERITS_FROM(CCModel, RichardsLensProblem)) SET_TYPE_PROP(RichardsLensProblem, Grid, Dune::YaspGrid<2>); // Set the physical problem to be solved -SET_PROP(RichardsLensProblem, Problem) -{ typedef Dumux::RichardsLensProblem<TypeTag> type; }; +SET_TYPE_PROP(RichardsLensProblem, Problem, Dumux::RichardsLensProblem<TypeTag>); // Set the wetting phase SET_PROP(RichardsLensProblem, WettingPhase) @@ -203,6 +201,12 @@ public: const int scvIdx) const { return pnRef_; }; + /*! + * \brief Return the sources within the domain. + * + * \param values Stores the source values, acts as return value + * \param globalPos The global position + */ void sourceAtPos(PrimaryVariables &values, const GlobalPosition &globalPos) const { @@ -267,7 +271,7 @@ public: values = 0.0; if (onInlet_(globalPos)) { // inflow of water - values[contiEqIdx] = -0.04; // kg / (m * s) + values[contiEqIdx] = -0.04; // kg/(m*s) } } diff --git a/test/implicit/richards/richardslensspatialparams.hh b/test/implicit/richards/richardslensspatialparams.hh index de5539f0aa..4fec0bcfe8 100644 --- a/test/implicit/richards/richardslensspatialparams.hh +++ b/test/implicit/richards/richardslensspatialparams.hh @@ -26,7 +26,6 @@ #include <dumux/material/spatialparams/implicitspatialparams.hh> #include <dumux/material/fluidmatrixinteractions/2p/regularizedvangenuchten.hh> -#include <dumux/material/fluidmatrixinteractions/2p/linearmaterial.hh> #include <dumux/material/fluidmatrixinteractions/2p/efftoabslaw.hh> #include <dumux/implicit/richards/richardsmodel.hh> @@ -112,13 +111,6 @@ public: outerMaterialParams_.setVgAlpha(0.0037); outerMaterialParams_.setVgn(4.7); - // parameters for the linear law - // minimum and maximum pressures -// lensMaterialParams_.setEntryPc(0); -// outerMaterialParams_.setEntryPc(0); -// lensMaterialParams_.setMaxPc(0); -// outerMaterialParams_.setMaxPc(0); - lensK_ = 1e-12; outerK_ = 5e-12; } -- GitLab