]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Fix the mess I created: the whole rearranging I did earlier meant that
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Fri, 19 Nov 2010 00:12:16 +0000 (00:12 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Fri, 19 Nov 2010 00:12:16 +0000 (00:12 +0000)
we couldn't do any anisotropic refinement any more -- which happens
internally when building some of the elements.

git-svn-id: https://svn.dealii.org/trunk@22812 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/source/grid/tria.cc

index c5783dadb17200a1e570c97871645681cddafb0f..21ac85c0fc75465a16b69677dccbb15d95c06d33 100644 (file)
@@ -3820,18 +3820,6 @@ namespace internal
    |0 | 1|
    .--.--.
 */
-
-                                            // find the next
-                                            // unused vertex and
-                                            // allocate it for
-                                            // the new vertex we
-                                            // need here
-           while (triangulation.vertices_used[next_unused_vertex] == true)
-             ++next_unused_vertex;
-           Assert (next_unused_vertex < triangulation.vertices.size(),
-                   ExcTooFewVerticesAllocated());
-           triangulation.vertices_used[next_unused_vertex] = true;
-
                                             // collect the
                                             // indices of the
                                             // eight
@@ -3848,10 +3836,23 @@ namespace internal
            for (unsigned int line_no=0; line_no<4; ++line_no)
              if (cell->line(line_no)->has_children())
                new_vertices[4+line_no]=cell->line(line_no)->child(0)->vertex_index(1);
-           new_vertices[8] = next_unused_vertex;
 
            if (ref_case==RefinementCase<dim>::cut_xy)
              {
+
+                                                // find the next
+                                                // unused vertex and
+                                                // allocate it for
+                                                // the new vertex we
+                                                // need here
+               while (triangulation.vertices_used[next_unused_vertex] == true)
+                 ++next_unused_vertex;
+               Assert (next_unused_vertex < triangulation.vertices.size(),
+                       ExcTooFewVerticesAllocated());
+               triangulation.vertices_used[next_unused_vertex] = true;
+
+               new_vertices[8] = next_unused_vertex;
+
                                                 // if this quad lives
                                                 // in 2d, then we can
                                                 // compute the new

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.