Commit d7705dd7 authored by Praetorius, Simon's avatar Praetorius, Simon
Browse files

Merge branch 'issue/marker_evaluation_strategy' into 'master'

evaluate marker-function only on the barycenter of the element

See merge request !92
parents f5c04c79 b2970767
......@@ -284,11 +284,10 @@ Flag GridFunctionMarker<Grid, PreGridFct>::markGrid(AdaptInfo& adaptInfo)
int currentLevel = e.level();
auto geo = e.geometry();
auto const& ref = Dune::referenceElement(geo);
int targetLevel = 0;
int codim = ref.dimension;
for (int i = 0; i < ref.size(codim); i++)
targetLevel = std::max(targetLevel, int(std::round(localFct(ref.position(i, codim)))));
// evaluate in the center of the element
int targetLevel = int(std::round(localFct(ref.position(0,0))));
int m = ((((targetLevel > currentLevel) && (currentLevel < this->maxRefineLevel_))
|| (currentLevel < this->minRefineLevel_))
......
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