From 01341551851e4b5b4ae5d9dc4a408a736097b078 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Del=20Pino?= <stephane.delpino44@gmail.com> Date: Wed, 13 Apr 2022 16:15:36 +0200 Subject: [PATCH] Fix MeshFlatNodeBoundary::_checkBoundaryIsFlat method Was incorrect in the case of concave boundaries ... --- src/mesh/MeshFlatNodeBoundary.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesh/MeshFlatNodeBoundary.cpp b/src/mesh/MeshFlatNodeBoundary.cpp index 059d6b004..d8cea01af 100644 --- a/src/mesh/MeshFlatNodeBoundary.cpp +++ b/src/mesh/MeshFlatNodeBoundary.cpp @@ -17,7 +17,7 @@ MeshFlatNodeBoundary<Dimension>::_checkBoundaryIsFlat(const TinyVector<Dimension parallel_for(this->m_node_list.size(), [=, &is_bad](int r) { const Rd& x = xr[this->m_node_list[r]]; - if (dot(x - origin, normal) > 1E-13 * length) { + if (std::abs(dot(x - origin, normal)) > 1E-13 * length) { is_bad = true; } }); -- GitLab