Commit 00047336 authored by Kilian Weishaupt's avatar Kilian Weishaupt
Browse files

[test][navierstokes][channel3d] Only use subgrid for 3d case

* fixes compiler warning 'array subscript 2 is outside array bounds'
  for pseudo 3d case
parent a66a1021
......@@ -68,7 +68,7 @@ int main(int argc, char** argv)
using Grid = GetPropType<TypeTag, Properties::Grid>;
Dumux::GridManager<Grid> gridManager;
#if HAVE_DUNE_SUBGRID
#if HAVE_DUNE_SUBGRID && GRID_DIM == 3
const bool isStaircaseGeometry = getParam<bool>("Problem.IsStaircaseGeometry", false);
auto selector = [&](const auto& element)
......
......@@ -31,7 +31,7 @@
#include <dune/common/float_cmp.hh>
#include <dune/grid/yaspgrid.hh>
#if HAVE_DUNE_SUBGRID
#if HAVE_DUNE_SUBGRID && GRID_DIM == 3
#include <dune/subgrid/subgrid.hh>
#endif
......@@ -71,7 +71,7 @@ struct Grid<TypeTag, TTag::ThreeDChannelTest>
using HostGrid = Dune::YaspGrid<dim, Dune::EquidistantOffsetCoordinates<GetPropType<TypeTag, Properties::Scalar>, dim> >;
#if HAVE_DUNE_SUBGRID
#if HAVE_DUNE_SUBGRID && GRID_DIM == 3
using type = Dune::SubGrid<HostGrid::dimension, HostGrid>;
#else
using type = HostGrid;
......
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