Skip to content
Snippets Groups Projects
Commit 35c7838f authored by Christoph Grüninger's avatar Christoph Grüninger Committed by Timo Koch
Browse files

[mpfa] Compatibility code for GeometryTypes

parent 13e054b2
No related branches found
No related tags found
1 merge request!725Fix/compiler errors and warnings clang
...@@ -533,6 +533,16 @@ public: ...@@ -533,6 +533,16 @@ public:
*/ */
static std::size_t getNumLocalScvfs(const Dune::GeometryType gt) static std::size_t getNumLocalScvfs(const Dune::GeometryType gt)
{ {
#if DUNE_VERSION_NEWER(DUNE_COMMON,2,6)
if (gt == Dune::GeometryTypes::tetrahedron)
return 12;
else if (gt == Dune::GeometryTypes::pyramid)
return 16;
else if (gt == Dune::GeometryTypes::prism)
return 18;
else if (gt == Dune::GeometryTypes::hexahedron)
return 24;
#else
if (gt == Dune::GeometryType(Dune::GeometryType::simplex, 3)) if (gt == Dune::GeometryType(Dune::GeometryType::simplex, 3))
return 12; return 12;
else if (gt == Dune::GeometryType(Dune::GeometryType::pyramid, 3)) else if (gt == Dune::GeometryType(Dune::GeometryType::pyramid, 3))
...@@ -541,6 +551,7 @@ public: ...@@ -541,6 +551,7 @@ public:
return 18; return 18;
else if (gt == Dune::GeometryType(Dune::GeometryType::cube, 3)) else if (gt == Dune::GeometryType(Dune::GeometryType::cube, 3))
return 24; return 24;
#endif
else else
DUNE_THROW(Dune::NotImplemented, "Mpfa for 3d geometry type " << gt); DUNE_THROW(Dune::NotImplemented, "Mpfa for 3d geometry type " << gt);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment