Commit a9155c51 authored by Timo Koch's avatar Timo Koch
Browse files

[embedded][1prichards] Add reference solutions. Resize domain. Use Neumann no-flow for soil.

parent ef829a73
dune_add_test(SOURCES test_1p_richards.cc)
dune_add_test(NAME test_embedded_1p_richards_tpfatpfa
SOURCES test_1p_richards.cc
COMPILE_DEFINITIONS SOILTYPETAG=SoilCCTypeTag
COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
CMAKE_GUARD dune-foamgrid_FOUND
CMD_ARGS --script fuzzy
--files ${CMAKE_SOURCE_DIR}/test/references/test_embedded_1p_richards_tpfa_1d.vtp
${CMAKE_CURRENT_BINARY_DIR}/test_embedded_1p_richards_tpfatpfa_1d-00014.vtp
${CMAKE_SOURCE_DIR}/test/references/test_embedded_1p_richards_tpfa_3d.vtu
${CMAKE_CURRENT_BINARY_DIR}/test_embedded_1p_richards_tpfatpfa_3d-00014.vtu
--command "${CMAKE_CURRENT_BINARY_DIR}/test_embedded_1p_richards_tpfatpfa test_1p_richards.input \
-Problem.Name test_embedded_1p_richards_tpfatpfa")
dune_add_test(NAME test_embedded_1p_richards_tpfabox
SOURCES test_1p_richards.cc
COMPILE_DEFINITIONS SOILTYPETAG=SoilBoxTypeTag
COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
CMAKE_GUARD dune-foamgrid_FOUND
CMD_ARGS --script fuzzy
--files ${CMAKE_SOURCE_DIR}/test/references/test_embedded_1p_richards_tpfa_1d.vtp
${CMAKE_CURRENT_BINARY_DIR}/test_embedded_1p_richards_tpfabox_1d-00017.vtp
${CMAKE_SOURCE_DIR}/test/references/test_embedded_1p_richards_box_3d.vtu
${CMAKE_CURRENT_BINARY_DIR}/test_embedded_1p_richards_tpfabox_3d-00017.vtu
--command "${CMAKE_CURRENT_BINARY_DIR}/test_embedded_1p_richards_tpfabox test_1p_richards.input \
-Problem.Name test_embedded_1p_richards_tpfabox")
dune_symlink_to_source_files(FILES "lupine.dgf" "test_1p_richards.input")
set(CMAKE_BUILD_TYPE Release)
......@@ -33,6 +33,7 @@
#include <dumux/common/parameters.hh>
#include <dumux/common/properties.hh>
#include <dumux/discretization/cellcentered/tpfa/properties.hh>
#include <dumux/discretization/box/properties.hh>
#include <dumux/porousmediumflow/richards/model.hh>
#include <dumux/porousmediumflow/problem.hh>
......@@ -46,7 +47,9 @@ class SoilProblem;
namespace Properties {
NEW_TYPE_TAG(SoilTypeTag, INHERITS_FROM(CCTpfaModel, Richards));
NEW_TYPE_TAG(SoilTypeTag, INHERITS_FROM(Richards));
NEW_TYPE_TAG(SoilCCTypeTag, INHERITS_FROM(CCTpfaModel, SoilTypeTag));
NEW_TYPE_TAG(SoilBoxTypeTag, INHERITS_FROM(BoxModel, SoilTypeTag));
// Set the grid type
SET_TYPE_PROP(SoilTypeTag, Grid, Dune::YaspGrid<3, Dune::EquidistantOffsetCoordinates<typename GET_PROP_TYPE(TypeTag, Scalar), 3> >);
......@@ -148,21 +151,10 @@ public:
BoundaryTypes boundaryTypesAtPos(const GlobalPosition &globalPos) const
{
BoundaryTypes values;
values.setAllDirichlet();
values.setAllNeumann();
return values;
}
/*!
* \brief Evaluate the boundary conditions for a dirichlet
* boundary segment.
*
* \param globalPos The position for which the bc type should be evaluated
*
* For this method, the \a values parameter stores primary variables.
*/
PrimaryVariables dirichletAtPos(const GlobalPosition &globalPos) const
{ return initialAtPos(globalPos); }
// \}
/*!
......
......@@ -51,7 +51,7 @@
namespace Dumux {
namespace Properties {
SET_PROP(SoilTypeTag, CouplingManager)
SET_PROP(SOILTYPETAG, CouplingManager)
{
using Traits = MultiDomainTraits<TypeTag, TTAG(RootTypeTag)>;
using type = EmbeddedCouplingManager1d3d<Traits, EmbeddedCouplingMode::average>;
......@@ -59,13 +59,13 @@ SET_PROP(SoilTypeTag, CouplingManager)
SET_PROP(RootTypeTag, CouplingManager)
{
using Traits = MultiDomainTraits<TTAG(SoilTypeTag), TypeTag>;
using Traits = MultiDomainTraits<TTAG(SOILTYPETAG), TypeTag>;
using type = EmbeddedCouplingManager1d3d<Traits, EmbeddedCouplingMode::average>;
};
SET_TYPE_PROP(SoilTypeTag, PointSource, typename GET_PROP_TYPE(TypeTag, CouplingManager)::PointSourceTraits::template PointSource<0>);
SET_TYPE_PROP(SOILTYPETAG, PointSource, typename GET_PROP_TYPE(TypeTag, CouplingManager)::PointSourceTraits::template PointSource<0>);
SET_TYPE_PROP(RootTypeTag, PointSource, typename GET_PROP_TYPE(TypeTag, CouplingManager)::PointSourceTraits::template PointSource<1>);
SET_TYPE_PROP(SoilTypeTag, PointSourceHelper, typename GET_PROP_TYPE(TypeTag, CouplingManager)::PointSourceTraits::template PointSourceHelper<0>);
SET_TYPE_PROP(SOILTYPETAG, PointSourceHelper, typename GET_PROP_TYPE(TypeTag, CouplingManager)::PointSourceTraits::template PointSourceHelper<0>);
SET_TYPE_PROP(RootTypeTag, PointSourceHelper, typename GET_PROP_TYPE(TypeTag, CouplingManager)::PointSourceTraits::template PointSourceHelper<1>);
} // end namespace Properties
......@@ -86,7 +86,7 @@ int main(int argc, char** argv) try
Parameters::init(argc, argv);
// Define the sub problem type tags
using BulkTypeTag = TTAG(SoilTypeTag);
using BulkTypeTag = TTAG(SOILTYPETAG);
using LowDimTypeTag = TTAG(RootTypeTag);
// try to create a grid (from the given grid file or the input file)
......
......@@ -3,7 +3,7 @@ NumCircleSegments = 10
[TimeLoop]
DtInitial = 8640 # [s]
TEnd = 864000 # [s]
TEnd = 86400 # [s]
EpisodeLength = 21700 # [s]
[Root.Grid]
......@@ -11,9 +11,9 @@ File = lupine.dgf
Refinement = 0
[Soil.Grid]
LowerLeft = -0.05 -0.05 -0.1
UpperRight = 0.05 0.05 0
Cells = 20 20 20
LowerLeft = -0.035 -0.035 -0.1
UpperRight = 0.035 0.035 0
Cells = 12 12 12
[Problem]
Name = test_soilroot
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
This diff is collapsed.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment