]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Produce a bit of output to check
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 3 Sep 2006 20:00:33 +0000 (20:00 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 3 Sep 2006 20:00:33 +0000 (20:00 +0000)
git-svn-id: https://svn.dealii.org/trunk@13818 0785d39b-7218-0410-832d-ea1e28bc413d

tests/bits/mesh_3d_18.cc

index ca58ed9c2a99e52de86e5e8b0f9c4de2fb97d342..1aa8c3cf382845df6cb2a5fa0b753e69947974a1 100644 (file)
@@ -43,36 +43,42 @@ void test_with_wrong_face_orientation ()
   triangulation.begin_active()->set_refine_flag ();
   triangulation.execute_coarsening_and_refinement ();
 
-  Triangulation<3>::active_cell_iterator cell = triangulation.begin_active(),
-                                        endc = triangulation.end();
+  Triangulation<3>::active_cell_iterator cell = triangulation.begin_active();
+  ++cell;
+  ++cell;
+
+  deallog << "Cell=" << cell << std::endl;
+  deallog << "Neighbor=" << cell->neighbor(3) << std::endl;
+  
+  const Triangulation<3>::active_cell_iterator neighbor_child
+    = cell->neighbor_child_on_subface (3, 1);
+
+  deallog << "Neighbor_child(3,1)=" << neighbor_child << std::endl;
+  for (unsigned int i=0; i<6; ++i)
+    {
+      deallog << "Neighbor_child neighbors=";
+      if (neighbor_child->at_boundary(i))
+       deallog << "(at boundary)";
+      else
+       deallog << neighbor_child->neighbor(i);
+      deallog << std::endl;
+    }
+
+  deallog << "Neighbor_of_neighbor=" << cell->neighbor_of_neighbor(3) << std::endl;
+
+  deallog << "Face=" << cell->face(3) << std::endl;
+  for (unsigned int i=0; i<4; ++i)
+    deallog << "Face_child=" << cell->face(3)->child(i) << std::endl;
+  
+  for (unsigned int i=0; i<4; ++i)
+    deallog << "Neighbor_face=" << cell->neighbor(3)->face(i) << std::endl;
+
+  for (unsigned int i=0; i<4; ++i)
+    deallog << "Neighbor_child_face=" << neighbor_child->face(i) << std::endl;
   
-  for (; cell!=endc; ++cell)
-    for (unsigned int face=0; face<GeometryInfo<3>::faces_per_cell; ++face)
-      if (cell->face(face)->has_children()) 
-       {
-                                          // so now we've found a face of an
-                                          // active cell that has
-                                          // children. that means that there
-                                          // are hanging nodes
-         for (unsigned int c=0; c<GeometryInfo<3>::subfaces_per_face; ++c)
-           {
-             Triangulation<3>::active_cell_iterator neighbor_child
-               = cell->neighbor_child_on_subface (face, c);
-
-                                              // some sanity checks
-                                              // -- particularly
-                                              // useful if you start
-                                              // to think about faces
-                                              // with
-                                              // face_orientation==false
-                                              // and whether we
-                                              // really really have
-                                              // the right face...
-             Assert (cell->face(face)->child(c) ==
-                     neighbor_child->face(cell->neighbor_of_neighbor(face)),
-                     ExcInternalError());
-           }
-       }
+  Assert (cell->face(3)->child(1) ==
+         neighbor_child->face(cell->neighbor_of_neighbor(3)),
+         ExcInternalError());
 }
 
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.