]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Do not create arrays we do not use. 16351/head
authorWolfgang Bangerth <bangerth@colostate.edu>
Fri, 15 Dec 2023 05:39:05 +0000 (22:39 -0700)
committerWolfgang Bangerth <bangerth@colostate.edu>
Fri, 15 Dec 2023 05:39:05 +0000 (22:39 -0700)
source/grid/tria.cc

index 28011c22f76200cd246a0071a76a658777b1abd0..9d20313b0a575e7be6eff274c1b0f1485aa1be46 100644 (file)
@@ -2182,7 +2182,7 @@ namespace internal
             total_cells - tria_level.global_level_cell_indices.size(),
             numbers::invalid_dof_index);
 
-          if (dimension < space_dimension)
+          if (dimension == space_dimension - 1)
             {
               tria_level.direction_flags.reserve(total_cells);
               tria_level.direction_flags.insert(
@@ -3646,7 +3646,7 @@ namespace internal
 
         level.parents.assign((size + 1) / 2, -1);
 
-        if (dim < spacedim)
+        if (dim == spacedim - 1)
           level.direction_flags.assign(size, true);
 
         level.neighbors.assign(size * max_faces_per_cell, {-1, -1});

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.