Skip to content
Snippets Groups Projects
Commit a92843d2 authored by Sander, Oliver's avatar Sander, Oliver
Browse files

Merge branch 'fix_compiler_error_with_onedgrid' into 'master'

OneDGrid does not have method leafbegin (anymore?)

See merge request !6
parents 28971b3a 49c04474
No related branches found
No related tags found
1 merge request!6OneDGrid does not have method leafbegin (anymore?)
Pipeline #2087 failed
...@@ -47,10 +47,14 @@ static void geodesicFEFunctionAdaptor(GridType& grid, std::vector<TargetSpace>& ...@@ -47,10 +47,14 @@ static void geodesicFEFunctionAdaptor(GridType& grid, std::vector<TargetSpace>&
P1NodalBasis<typename GridType::LeafGridView> p1Basis(grid.leafGridView()); P1NodalBasis<typename GridType::LeafGridView> p1Basis(grid.leafGridView());
x.resize(grid.size(dim)); x.resize(grid.size(dim));
for (const auto& element : elements(grid.leafGridView())) for (const auto& element : elements(grid.leafGridView())) {
{
// Set up a local gfe function on the father element // Set up a local gfe function on the father element
#if DUNE_VERSION_NEWER(DUNE_GRID,2,4)
size_t nFatherDofs = element.father().subEntities(dim); size_t nFatherDofs = element.father().subEntities(dim);
#else
size_t nFatherDofs = element.father()->template count<dim>();
#endif
std::vector<TargetSpace> coefficients(nFatherDofs); std::vector<TargetSpace> coefficients(nFatherDofs);
for (int i=0; i<nFatherDofs; i++) for (int i=0; i<nFatherDofs; i++)
...@@ -63,8 +67,11 @@ static void geodesicFEFunctionAdaptor(GridType& grid, std::vector<TargetSpace>& ...@@ -63,8 +67,11 @@ static void geodesicFEFunctionAdaptor(GridType& grid, std::vector<TargetSpace>&
// The embedding of this element into the father geometry // The embedding of this element into the father geometry
const auto& geometryInFather = element.geometryInFather(); const auto& geometryInFather = element.geometryInFather();
#if DUNE_VERSION_NEWER(DUNE_GRID,2,4)
size_t nDofs = element.subEntities(dim); size_t nDofs = element.subEntities(dim);
#else
size_t nDofs = element.template count<dim>();
#endif
for (int i=0; i<nDofs; i++) { for (int i=0; i<nDofs; i++) {
if (dofMap.find(idSet.subId(element,i,dim)) != dofMap.end()) { if (dofMap.find(idSet.subId(element,i,dim)) != dofMap.end()) {
......
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