comment code for non orthogonal boundarylayers

(not working if multiple surfaces come together)
This commit is contained in:
Christopher Lackner 2020-07-17 18:00:38 +02:00
parent dd4110a351
commit b37a3e6cf6

View File

@ -238,24 +238,24 @@ namespace netgen
} }
// project growthvector on surface for inner angles // project growthvector on surface for inner angles
for(const auto& sel : mesh.SurfaceElements()) // for(const auto& sel : mesh.SurfaceElements())
if(!blp.surfid.Contains(sel.GetIndex())) // if(!blp.surfid.Contains(sel.GetIndex()))
{ // {
auto n = GetSurfaceNormal(mesh, sel); // auto n = GetSurfaceNormal(mesh, sel);
for(auto pi : sel.PNums()) // for(auto pi : sel.PNums())
{ // {
if(growthvectors[pi].Length2() == 0.) // if(growthvectors[pi].Length2() == 0.)
continue; // continue;
auto& g = growthvectors[pi]; // auto& g = growthvectors[pi];
auto ng = n * g; // auto ng = n * g;
auto gg = g * g; // auto gg = g * g;
auto nn = n * n; // auto nn = n * n;
if(fabs(ng*ng-nn*gg) < 1e-12 || fabs(ng) < 1e-12) continue; // if(fabs(ng*ng-nn*gg) < 1e-12 || fabs(ng) < 1e-12) continue;
auto a = -ng*ng/(ng*ng-nn * gg); // auto a = -ng*ng/(ng*ng-nn * gg);
auto b = ng*gg/(ng*ng-nn*gg); // auto b = ng*gg/(ng*ng-nn*gg);
g += a*g + b*n; // g += a*g + b*n;
} // }
} // }
if (!blp.grow_edges) if (!blp.grow_edges)
{ {