]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Remove usused internal function convert_cell_id_binary_type_to_level_coarse_cell_id 10551/head
authorPeter Munch <peterrmuench@gmail.com>
Fri, 19 Jun 2020 10:26:34 +0000 (12:26 +0200)
committerPeter Munch <peterrmuench@gmail.com>
Fri, 19 Jun 2020 10:26:34 +0000 (12:26 +0200)
source/grid/tria_description.cc

index b59c2e0b1f3bc78d224a7ee38c08d22a9b3a17c6..5634c81767a7fc44a337faba08cd76fa9ff2091c 100644 (file)
@@ -90,57 +90,6 @@ namespace TriangulationDescription
         if (cell->level() != 0)
           set_user_flag_and_of_its_parents(cell->parent());
       }
-
-
-      /**
-       * Convert the binary representation of a CellId to coarse-cell id as
-       * if the finest level were the coarsest level ("level coarse-grid id").
-       */
-      template <int dim>
-      types::coarse_cell_id
-      convert_cell_id_binary_type_to_level_coarse_cell_id(
-        const typename CellId::binary_type &binary_representation)
-      {
-        // exploiting the structure of CellId::binary_type
-        // see also the documentation of CellId
-
-        // actual coarse-grid id
-        const unsigned int coarse_cell_id  = binary_representation[0];
-        const unsigned int n_child_indices = binary_representation[1] >> 2;
-
-        const unsigned int children_per_value =
-          sizeof(CellId::binary_type::value_type) * 8 / dim;
-        unsigned int child_level  = 0;
-        unsigned int binary_entry = 2;
-
-        // path to the get to the cell
-        std::vector<unsigned int> cell_indices;
-        while (child_level < n_child_indices)
-          {
-            Assert(binary_entry < binary_representation.size(),
-                   ExcInternalError());
-
-            for (unsigned int j = 0; j < children_per_value; ++j)
-              {
-                unsigned int cell_index =
-                  (((binary_representation[binary_entry] >> (j * dim))) &
-                   (GeometryInfo<dim>::max_children_per_cell - 1));
-                cell_indices.push_back(cell_index);
-                ++child_level;
-                if (child_level == n_child_indices)
-                  break;
-              }
-            ++binary_entry;
-          }
-
-        // compute new coarse-grid id: c_{i+1} = c_{i}*2^dim + q;
-        types::coarse_cell_id level_coarse_cell_id = coarse_cell_id;
-        for (auto i : cell_indices)
-          level_coarse_cell_id =
-            level_coarse_cell_id * GeometryInfo<dim>::max_children_per_cell + i;
-
-        return level_coarse_cell_id;
-      }
     } // namespace
 
 

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.