From 2adc58eab68f54faccc607bcf2e5cfa9050d0921 Mon Sep 17 00:00:00 2001 From: Peter Munch Date: Sat, 18 Sep 2021 20:11:32 +0200 Subject: [PATCH] HangingNodes: ignore artificial neighbors --- include/deal.II/matrix_free/hanging_nodes_internal.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/deal.II/matrix_free/hanging_nodes_internal.h b/include/deal.II/matrix_free/hanging_nodes_internal.h index b92fcf2316..5ec5e367dd 100644 --- a/include/deal.II/matrix_free/hanging_nodes_internal.h +++ b/include/deal.II/matrix_free/hanging_nodes_internal.h @@ -374,6 +374,9 @@ namespace internal { const auto &neighbor = cell->neighbor(face); + if (neighbor->is_artificial()) + continue; + // Neighbor is coarser than us, i.e., face is constrained if (neighbor->level() < cell->level()) { @@ -613,6 +616,10 @@ namespace internal { // If one of them is coarser than us const auto neighbor_cell = edge_neighbor.first; + + if (neighbor_cell->is_artificial()) + continue; + if (neighbor_cell->level() < cell->level()) { const unsigned int local_line_neighbor = -- 2.39.5