49 std::shared_ptr<const GridGeometry> gridGeometry,
53 for(
const auto& element : elements(leafGridView))
55 auto fvGeometry =
localView(*gridGeometry);
56 fvGeometry.bind(element);
58 for (
auto&& scvf : scvfs(fvGeometry))
62 const auto boundaryMarkerId = gridData->getBoundaryDomainMarker(scvf.boundaryFlag());
63 const auto& pos = scvf.center();
64 std::cout <<
"z-coordinate: " << pos[dim-1] <<
", actual ID = " << boundaryMarkerId <<
", ";
73 const int bottomId = 0;
76 const bool isTop = pos[dim-1] > 1.0 - eps_;
77 const bool isBottom = pos[dim-1] < eps_;
78 const bool isSide = !isTop && !isBottom;
82 std::cout <<
"correct ID = " << topId <<
" (is top surface)" << std::endl;
83 if (boundaryMarkerId != topId)
84 DUNE_THROW(Dune::Exception,
"BoundaryMarkerId for top is wrong!");
88 std::cout <<
"correct ID = " << bottomId <<
" (is bottom surface)" << std::endl;
89 if (boundaryMarkerId != bottomId)
90 DUNE_THROW(Dune::Exception,
"BoundaryMarkerId for bottom is wrong!");
94 std::cout <<
"correct ID = " << sideId <<
" (is side surface)" << std::endl;
95 if (boundaryMarkerId != sideId)
96 DUNE_THROW(Dune::Exception,
"BoundaryMarkerId for side is wrong!");