Skip to content
Snippets Groups Projects
Commit 6badfc0e authored by Porrmann, Maik's avatar Porrmann, Maik
Browse files

Bugfix clamped BC

parent 1b8f7915
No related branches found
No related tags found
No related merge requests found
......@@ -153,10 +153,10 @@ namespace Dune
return true;
else if (localKey.index() == 3) // first direction, second derivative, clamped if
// tangential or normal to this element
return isTangential(localKey.subEntity(), 0) || isNormal(localKey.subEntity(), 0);
return isTangential(localKey.subEntity(), 0);
else if (localKey.index() == 5) // second direction, second derivative, clamped if
// tangential or normal to this element
return isTangential(localKey.subEntity(), 1) || isNormal(localKey.subEntity(), 1);
return isTangential(localKey.subEntity(), 1);
else // cross derivative, always clamped
return true;
}
......@@ -930,7 +930,19 @@ namespace Dune
if (setTangential[2]) // if first is tangential
{
if (setTangential[3])
continue; // both are tangetials, i.e. vertex is corner
// both are tangetials, i.e. vertex is corner
{
// check if orthogonal
if (dir[0].dot(dir[1]) < 1e-14)
{
// direction is normal to all elements that other direction is tangential to
auto lenInd_1 = indices[1].size();
for (auto const &index : indices[0])
indices[1].push_back(index);
for (std::size_t i = 0; i < lenInd_1; ++i)
indices[0].push_back(indices[1][i]);
}
}
else // straight boundary segment
{
// set second direction normal to first
......
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