From 151f0e8ea9db5d434a6df280fa4eaec474eee016 Mon Sep 17 00:00:00 2001 From: wolf Date: Wed, 1 Oct 2003 22:57:59 +0000 Subject: [PATCH] Fix one problem with misoriented faces. There's another one lurking somewhere, though, see mesh_3d_12. git-svn-id: https://svn.dealii.org/trunk@8085 0785d39b-7218-0410-832d-ea1e28bc413d --- .../source/numerics/error_estimator.cc | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/deal.II/deal.II/source/numerics/error_estimator.cc b/deal.II/deal.II/source/numerics/error_estimator.cc index 51fe74f0c8..a9c4bf9884 100644 --- a/deal.II/deal.II/source/numerics/error_estimator.cc +++ b/deal.II/deal.II/source/numerics/error_estimator.cc @@ -987,14 +987,26 @@ integrate_over_irregular_face (const DoFHandler &dof_handler, { // get an iterator pointing to the // cell behind the present subface + const bool orientation_flag + = (dim != 3 ? + true : + cell->get_face_orientation(face_no) == true + && + neighbor->get_face_orientation(neighbor_neighbor) == true); + static const unsigned int subface_translation[4] + = { 0, 3, 2, 1 }; + const unsigned int neighbor_child_index + = (GeometryInfo:: + child_cell_on_face(neighbor_neighbor, + (orientation_flag ? + subface_no : + subface_translation[subface_no]))); const active_cell_iterator neighbor_child - = neighbor->child(GeometryInfo:: - child_cell_on_face(neighbor_neighbor,subface_no)); + = neighbor->child(neighbor_child_index); Assert (neighbor_child->face(neighbor_neighbor) == cell->face(face_no)->child(subface_no), ExcInternalError()); - Assert (!neighbor->child(GeometryInfo:: - child_cell_on_face(neighbor_neighbor,subface_no))->has_children(), + Assert (!neighbor->child(neighbor_child_index)->has_children(), ExcInternalError()); // restrict the finite element on the -- 2.39.5