From: Martin Kronbichler Date: Sat, 25 Jun 2022 14:16:03 +0000 (+0200) Subject: Also add specialization for quadrilaterals X-Git-Tag: v9.5.0-rc1~1143^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3b27fe58fea4594fc429406e34bc80f9c6319a94;p=dealii.git Also add specialization for quadrilaterals --- diff --git a/source/grid/tria.cc b/source/grid/tria.cc index f2d99de001..5fc10e7bf5 100644 --- a/source/grid/tria.cc +++ b/source/grid/tria.cc @@ -14591,6 +14591,18 @@ Triangulation::reset_cell_vertex_indices_cache() for (unsigned int i = 0; i < 4; ++i) cache[index + i] = raw_vertex_indices[vertex_order[i]]; } + else if (ref_cell == ReferenceCells::Quadrilateral) + { + const std::array line_orientations{ + {cell->line_orientation(0), cell->line_orientation(1)}}; + std::array raw_vertex_indices{ + {cell->line(0)->vertex_index(1 - line_orientations[0]), + cell->line(1)->vertex_index(1 - line_orientations[1]), + cell->line(0)->vertex_index(line_orientations[0]), + cell->line(1)->vertex_index(line_orientations[1])}}; + for (unsigned int i = 0; i < 4; ++i) + cache[my_index + i] = raw_vertex_indices[i]; + } else for (const unsigned int i : cell->vertex_indices()) cache[my_index + i] = internal::TriaAccessorImplementation::