]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Introduced CellDataTransfer. 8331/head
authorMarc Fehling <marc.fehling@gmx.net>
Wed, 10 Jul 2019 15:02:37 +0000 (17:02 +0200)
committerMarc Fehling <marc.fehling@gmx.net>
Wed, 10 Jul 2019 15:02:37 +0000 (17:02 +0200)
14 files changed:
doc/news/changes/minor/20190626Fehling [new file with mode: 0644]
include/deal.II/numerics/cell_data_transfer.h [new file with mode: 0644]
include/deal.II/numerics/cell_data_transfer.templates.h [new file with mode: 0644]
source/numerics/CMakeLists.txt
source/numerics/cell_data_transfer.cc [new file with mode: 0644]
source/numerics/cell_data_transfer.inst.in [new file with mode: 0644]
tests/numerics/cell_data_transfer.cc [new file with mode: 0644]
tests/numerics/cell_data_transfer.output [new file with mode: 0644]
tests/sharedtria/cell_data_transfer_01.cc [new file with mode: 0644]
tests/sharedtria/cell_data_transfer_01.with_mpi=true.with_petsc=true.mpirun=1.output [new file with mode: 0644]
tests/sharedtria/cell_data_transfer_01.with_mpi=true.with_petsc=true.mpirun=2.output [new file with mode: 0644]
tests/sharedtria/cell_data_transfer_02.cc [new file with mode: 0644]
tests/sharedtria/cell_data_transfer_02.with_mpi=true.with_petsc=true.mpirun=1.output [new file with mode: 0644]
tests/sharedtria/cell_data_transfer_02.with_mpi=true.with_petsc=true.mpirun=2.output [new file with mode: 0644]

diff --git a/doc/news/changes/minor/20190626Fehling b/doc/news/changes/minor/20190626Fehling
new file mode 100644 (file)
index 0000000..25818c9
--- /dev/null
@@ -0,0 +1,4 @@
+New: Class CellDataTransfer has been introduced to transfer cell by cell
+data across meshes in case of refinement/serialization.
+<br>
+(Marc Fehling, 2019/06/26)
diff --git a/include/deal.II/numerics/cell_data_transfer.h b/include/deal.II/numerics/cell_data_transfer.h
new file mode 100644 (file)
index 0000000..cea9761
--- /dev/null
@@ -0,0 +1,206 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+#ifndef dealii_cell_data_transfer_h
+#define dealii_cell_data_transfer_h
+
+#include <deal.II/base/config.h>
+
+#include <deal.II/base/smartpointer.h>
+
+#include <deal.II/grid/tria.h>
+
+#include <deal.II/numerics/coarsening_strategies.h>
+
+#include <algorithm>
+#include <functional>
+#include <set>
+
+
+DEAL_II_NAMESPACE_OPEN
+
+/**
+ * Transfer data that is associated with each active cell (like error
+ * indicators) while refining and/or coarsening a triangulation.
+ *
+ * This class therefore does for cell-related information what
+ * SolutionTransfer does for the values of degrees of freedom defined on a
+ * Triangulation.
+ *
+ * A non-distributed container (like Vector or `std::vector`) has to be
+ * provided, which holds the cell-wise data in the same order as active cells
+ * are traversed. In other words, each entry corresponds to the cell with the
+ * same index CellAccessor::active_cell_index(), and the container has to be of
+ * size Triangulation::n_active_cells().
+ *
+ * <h3>Transferring cell-wise data</h3>
+ *
+ * The following code snippet demonstrates how to transfer cell-related data
+ * across refinement/coarsening of the registered triangulation.
+ *
+ * @code
+ * // prepare the triangulation,
+ * triangulation.prepare_coarsening_and_refinement();
+ *
+ * // prepare the CellDataTransfer object for coarsening and refinement
+ * // and give the cell data vector that we intend to unpack later,
+ * Vector<double> data_to_transfer(triangulation.n_active_cells());
+ * //[fill data_to_transfer with cell-wise values...]
+ *
+ * CellDataTransfer<dim, spacedim, Vector<double>>
+ *   cell_data_trans(triangulation);
+ * cell_data_trans.prepare_for_coarsening_and_refinement();
+ *
+ * // actually execute the refinement,
+ * triangulation.execute_coarsening_and_refinement();
+ *
+ * // unpack transferred data,
+ * Vector<double> transferred_data(triangulation.n_active_cells());
+ * cell_data_trans.unpack(data_to_transfer, transferred_data);
+ * @endcode
+ *
+ * When using a parallel::shared::Triangulation, we need to ensure that we have
+ * the global data available in our local vector before refinement happened. We
+ * can achieve this as follows:
+ *
+ * @code
+ * Vector<double> data_to_transfer(triangulation.n_active_cells());
+ * //[fill data_to_transfer with cell-wise values...]
+ *
+ * PETScWrappers::MPI::Vector
+ * distributed_data_to_transfer(mpi_communicator,
+ *                              triangulation.n_active_cells(),
+ *                              triangulation.n_locally_owned_active_cells());
+ * for (const auto &cell : triangulation.active_cell_iterators())
+ *   if (cell->is_locally_owned())
+ *     {
+ *       const unsigned int index = cell->active_cell_index();
+ *       distributed_data_to_transfer(index) = data_to_transfer(index);
+ *     }
+ * distributed_data_to_transfer.compress(VectorOperation::insert);
+ *
+ * data_to_transfer = distributed_data_to_transfer;
+ * @endcode
+ *
+ * For the parallel distributed case, a designated class
+ * parallel::distributed::CellDataTransfer is available. Please refer to this
+ * particular class when using a parallel::distributed::Triangulation.
+ *
+ * @note See the documentation of SolutionTransfer for matching code snippets
+ *   for transfer.
+ *
+ * @ingroup numerics
+ * @author Marc Fehling, 2019
+ */
+template <int dim, int spacedim = dim, typename VectorType = Vector<double>>
+class CellDataTransfer
+{
+private:
+  /**
+   * An alias that defines the data type of provided container template.
+   */
+  using value_type = typename VectorType::value_type;
+
+public:
+  /**
+   * Constructor.
+   *
+   * @param[in] triangulation The triangulation on which all operations will
+   *   happen. At the time when this constructor is called, the refinement
+   *   in question has not happened yet.
+   * @param[in] coarsening_strategy Function deciding which data to store on
+   *   a cell whose children will get coarsened into.
+   */
+  CellDataTransfer(
+    const Triangulation<dim, spacedim> &                triangulation,
+    const std::function<value_type(
+      const std::vector<value_type> &children_indices)> coarsening_strategy =
+      &CoarseningStrategies::check_equality<value_type>);
+
+  /**
+   * Prepare the current object for coarsening and refinement.
+   *
+   * Stores the active_cell_indices of all active cells on the associated
+   * triangulation and attribute them to either persisting, refined or coarsened
+   * cells.
+   */
+  void
+  prepare_for_coarsening_and_refinement();
+
+  /**
+   * Transfer the information from the previous mesh to the updated one.
+   *
+   * Data from the previous mesh supplied by @p in will be transferred to the updated
+   * mesh and stored in @p out. @p out has to provide enough space to hold the
+   * transferred data, i.e. has to be of size `triangulation.n_active_cells()`.
+   */
+  void
+  unpack(const VectorType &in, VectorType &out);
+
+private:
+  /**
+   * Pointer to the triangulation to work with.
+   */
+  SmartPointer<const Triangulation<dim, spacedim>,
+               CellDataTransfer<dim, spacedim, VectorType>>
+    triangulation;
+
+  /**
+   * Function deciding on how to process data from children to be stored on the
+   * parent cell.
+   */
+  const std::function<value_type(
+    const std::vector<value_type> &children_indices)>
+    coarsening_strategy;
+
+  /**
+   * Container to temporarily store the iterator and active cell index
+   * of cells that persist.
+   */
+  std::map<const typename Triangulation<dim, spacedim>::cell_iterator,
+           const unsigned int>
+    persisting_cells_active_index;
+
+  /**
+   * Container to temporarily store the iterator and active cell index
+   * of cells that will be refined.
+   */
+  std::map<const typename Triangulation<dim, spacedim>::cell_iterator,
+           const unsigned int>
+    refined_cells_active_index;
+
+  /**
+   * Container to temporarily store the iterator of parent cells that will
+   * remain after coarsening along with the active cell indices of the
+   * corresponding children cells.
+   */
+  std::map<const typename Triangulation<dim, spacedim>::cell_iterator,
+           const std::set<unsigned int>>
+    coarsened_cells_active_index;
+
+  /**
+   * Number of active cells on the initial triangulation that has not been
+   * refined yet.
+   *
+   * It will be set in prepare_for_coarsening_and_refinement() and used to
+   * validate user inputs after refinement happened (only in debug mode).
+   */
+  unsigned int n_active_cells_pre;
+};
+
+
+DEAL_II_NAMESPACE_CLOSE
+
+#endif /* dealii_cell_data_transfer_h */
diff --git a/include/deal.II/numerics/cell_data_transfer.templates.h b/include/deal.II/numerics/cell_data_transfer.templates.h
new file mode 100644 (file)
index 0000000..6ed30be
--- /dev/null
@@ -0,0 +1,197 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+#ifndef dealii_cell_data_transfer_templates_h
+#define dealii_cell_data_transfer_templates_h
+
+
+#include <deal.II/base/config.h>
+
+#include <deal.II/distributed/tria.h>
+
+#include <deal.II/numerics/cell_data_transfer.h>
+
+
+DEAL_II_NAMESPACE_OPEN
+
+
+namespace internal
+{
+  namespace CellDataTransferImplementation
+  {
+    template <typename VectorType>
+    void
+    post_unpack_action(VectorType &out)
+    {
+      out.compress(::dealii::VectorOperation::insert);
+    }
+
+    template <typename value_type>
+    void
+    post_unpack_action(std::vector<value_type> &)
+    {
+      // Do nothing for std::vector as VectorType.
+    }
+  } // namespace CellDataTransferImplementation
+} // namespace internal
+
+
+
+template <int dim, int spacedim, typename VectorType>
+CellDataTransfer<dim, spacedim, VectorType>::CellDataTransfer(
+  const Triangulation<dim, spacedim> &                triangulation,
+  const std::function<value_type(
+    const std::vector<value_type> &children_indices)> coarsening_strategy)
+  : triangulation(&triangulation, typeid(*this).name())
+  , coarsening_strategy(coarsening_strategy)
+  , n_active_cells_pre(numbers::invalid_unsigned_int)
+{
+  Assert(
+    (dynamic_cast<const parallel::distributed::Triangulation<dim, spacedim> *>(
+       &triangulation) == nullptr),
+    ExcMessage("You are calling the CellDataTransfer class "
+               "with a parallel::distributed::Triangulation. "
+               "You probably want to use the "
+               "parallel::distributed::CellDataTransfer class."));
+}
+
+
+
+template <int dim, int spacedim, typename VectorType>
+void
+CellDataTransfer<dim, spacedim, VectorType>::
+  prepare_for_coarsening_and_refinement()
+{
+  // Cleanup previous indices.
+  refined_cells_active_index.clear();
+  coarsened_cells_active_index.clear();
+  persisting_cells_active_index.clear();
+
+  for (const auto &cell : triangulation->active_cell_iterators())
+    {
+      // Store iterator and active cell index of cells that will be refined.
+      if (cell->refine_flag_set())
+        {
+          refined_cells_active_index.insert({cell, cell->active_cell_index()});
+        }
+      else if (cell->coarsen_flag_set())
+        {
+          // Gather the iterator to the parent cell of cells that will be
+          // coarsened. Store it together with the active cell indices of all
+          // its children.
+          Assert(cell->level() > 0, ExcInternalError());
+          const auto &parent = cell->parent();
+
+          // Check if the active_cell_indices for the current cell have
+          // been determined already.
+          if (coarsened_cells_active_index.find(parent) ==
+              coarsened_cells_active_index.end())
+            {
+              std::set<unsigned int> indices_children;
+              for (unsigned int child_index = 0;
+                   child_index < parent->n_children();
+                   ++child_index)
+                {
+                  const auto sibling = parent->child(child_index);
+                  Assert(sibling->active() && sibling->coarsen_flag_set(),
+                         typename dealii::Triangulation<
+                           dim>::ExcInconsistentCoarseningFlags());
+
+                  indices_children.insert(sibling->active_cell_index());
+                }
+              AssertDimension(indices_children.size(), parent->n_children());
+
+              coarsened_cells_active_index.insert({parent, indices_children});
+            }
+        }
+      else
+        {
+          // Store iterator and active cell index of all other cells.
+          persisting_cells_active_index.insert(
+            {cell, cell->active_cell_index()});
+        }
+    }
+
+#ifdef DEBUG
+  n_active_cells_pre = triangulation->n_active_cells();
+#else
+  (void)n_active_cells_pre;
+#endif
+}
+
+
+
+template <int dim, int spacedim, typename VectorType>
+void
+CellDataTransfer<dim, spacedim, VectorType>::unpack(const VectorType &in,
+                                                    VectorType &      out)
+{
+#ifdef DEBUG
+  Assert(in.size() == n_active_cells_pre,
+         ExcDimensionMismatch(in.size(), n_active_cells_pre));
+  Assert(out.size() == triangulation->n_active_cells(),
+         ExcDimensionMismatch(out.size(), triangulation->n_active_cells()));
+#else
+  (void)n_active_cells_pre;
+#endif
+
+  // Transfer data of persisting cells.
+  for (const auto &persisting : persisting_cells_active_index)
+    {
+      Assert(persisting.first->active(), ExcInternalError());
+      out[persisting.first->active_cell_index()] = in[persisting.second];
+    }
+
+  // Transfer data of the parent cell to all of its children that it has been
+  // refined to.
+  for (const auto &refined : refined_cells_active_index)
+    for (unsigned int child_index = 0;
+         child_index < refined.first->n_children();
+         ++child_index)
+      {
+        const auto child = refined.first->child(child_index);
+        Assert(child->active(), ExcInternalError());
+        out[child->active_cell_index()] = in[refined.second];
+      }
+
+  // Transfer data from the former children to the cell that they have been
+  // coarsened to.
+  std::vector<value_type> children_values;
+  for (const auto &coarsened : coarsened_cells_active_index)
+    {
+      // Get previous values of former children.
+      children_values.resize(coarsened.second.size());
+
+      auto indices_it = coarsened.second.cbegin();
+      auto values_it  = children_values.begin();
+      for (; indices_it != coarsened.second.cend(); ++indices_it, ++values_it)
+        *values_it = in[*indices_it];
+      Assert(values_it == children_values.end(), ExcInternalError());
+
+      // Decide how to handle the previous data.
+      const value_type parent_value = coarsening_strategy(children_values);
+
+      // Set value for the parent cell.
+      Assert(coarsened.first->active(), ExcInternalError());
+      out[coarsened.first->active_cell_index()] = parent_value;
+    }
+
+  internal::CellDataTransferImplementation::post_unpack_action(out);
+}
+
+
+DEAL_II_NAMESPACE_CLOSE
+
+#endif /* dealii_cell_data_transfer_templates_h */
index 67f5568b683958ca9b64e3a9b8bacd237a1c6cb3..e3e9eb1863c773571a19e1a87e038a0e64e22b73 100644 (file)
@@ -35,6 +35,7 @@ SET(_unity_include_src
   )
 
 SET(_separate_src
+  cell_data_transfer.cc
   data_out_dof_data.cc
   data_out_dof_data_inst2.cc
   data_out_dof_data_codim.cc
@@ -73,6 +74,7 @@ SETUP_SOURCE_LIST("${_unity_include_src}"
   )
 
 SET(_inst
+  cell_data_transfer.inst.in
   data_out_dof_data.inst.in
   data_out_dof_data_codim.inst.in
   data_out_faces.inst.in
diff --git a/source/numerics/cell_data_transfer.cc b/source/numerics/cell_data_transfer.cc
new file mode 100644 (file)
index 0000000..aacbbbb
--- /dev/null
@@ -0,0 +1,23 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+#include <deal.II/numerics/cell_data_transfer.templates.h>
+
+DEAL_II_NAMESPACE_OPEN
+
+// explicit instantiations
+#include "cell_data_transfer.inst"
+
+DEAL_II_NAMESPACE_CLOSE
diff --git a/source/numerics/cell_data_transfer.inst.in b/source/numerics/cell_data_transfer.inst.in
new file mode 100644 (file)
index 0000000..0bc52b1
--- /dev/null
@@ -0,0 +1,26 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+
+
+for (deal_II_dimension : DIMENSIONS; deal_II_space_dimension : SPACE_DIMENSIONS;
+     SCALAR : REAL_SCALARS)
+  {
+#if deal_II_dimension <= deal_II_space_dimension
+    template class CellDataTransfer<deal_II_dimension,
+                                    deal_II_space_dimension,
+                                    Vector<SCALAR>>;
+#endif
+  }
diff --git a/tests/numerics/cell_data_transfer.cc b/tests/numerics/cell_data_transfer.cc
new file mode 100644 (file)
index 0000000..dfb5921
--- /dev/null
@@ -0,0 +1,110 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+
+
+// CellDataTransfer test by refinement
+// for sequential Triangulation
+
+
+#include <deal.II/grid/grid_generator.h>
+#include <deal.II/grid/tria.h>
+
+#include <deal.II/numerics/cell_data_transfer.templates.h>
+
+#include <string>
+
+#include "../tests.h"
+
+
+template <int dim, int spacedim>
+void
+test()
+{
+  // ------ setup ------
+  Triangulation<dim, spacedim> tria;
+
+  GridGenerator::subdivided_hyper_cube(tria, 2);
+  tria.refine_global(1);
+  deallog << "cells before: " << tria.n_global_active_cells() << std::endl;
+
+  // ----- prepare -----
+  // set refinement/coarsening flags
+  for (auto &cell : tria.active_cell_iterators())
+    {
+      if (cell->id().to_string() == "0_1:0")
+        cell->set_refine_flag();
+      else if (((dim == 1) && (cell->parent()->id().to_string() == "1_0:")) ||
+               ((dim == 2) && (cell->parent()->id().to_string() == "3_0:")) ||
+               ((dim == 3) && (cell->parent()->id().to_string() == "7_0:")))
+        cell->set_coarsen_flag();
+    }
+
+  // ----- gather -----
+  // store parent id of all cells
+  std::vector<unsigned int> cell_ids_pre(tria.n_active_cells());
+  for (auto &cell : tria.active_cell_iterators())
+    {
+      const std::string  parent_cellid = cell->parent()->id().to_string();
+      const unsigned int parent_coarse_cell_id =
+        static_cast<unsigned int>(std::stoul(parent_cellid));
+      cell_ids_pre[cell->active_cell_index()] = parent_coarse_cell_id;
+
+      deallog << "cellid=" << cell->id()
+              << " parentid=" << cell_ids_pre[cell->active_cell_index()];
+      if (cell->coarsen_flag_set())
+        deallog << " coarsening";
+      else if (cell->refine_flag_set())
+        deallog << " refining";
+      deallog << std::endl;
+    }
+
+  // ----- transfer -----
+  CellDataTransfer<dim, spacedim, std::vector<unsigned int>> cell_data_transfer(
+    tria);
+
+  cell_data_transfer.prepare_for_coarsening_and_refinement();
+  tria.execute_coarsening_and_refinement();
+  deallog << "cells after: " << tria.n_global_active_cells() << std::endl;
+
+  std::vector<unsigned int> cell_ids_post(tria.n_active_cells());
+  cell_data_transfer.unpack(cell_ids_pre, cell_ids_post);
+
+  // ------ verify ------
+  // check if all children adopted the correct id
+  for (auto &cell : tria.active_cell_iterators())
+    deallog << "cellid=" << cell->id()
+            << " parentid=" << cell_ids_post[(cell->active_cell_index())]
+            << std::endl;
+
+  deallog << "OK" << std::endl;
+}
+
+
+int
+main(int argc, char *argv[])
+{
+  initlog();
+
+  deallog.push("1d");
+  test<1, 1>();
+  deallog.pop();
+  deallog.push("2d");
+  test<2, 2>();
+  deallog.pop();
+  deallog.push("3d");
+  test<3, 3>();
+  deallog.pop();
+}
diff --git a/tests/numerics/cell_data_transfer.output b/tests/numerics/cell_data_transfer.output
new file mode 100644 (file)
index 0000000..a2bf27f
--- /dev/null
@@ -0,0 +1,178 @@
+
+DEAL:1d::cells before: 4
+DEAL:1d::cellid=0_1:0 parentid=0 refining
+DEAL:1d::cellid=0_1:1 parentid=0
+DEAL:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:1d::cells after: 4
+DEAL:1d::cellid=1_0: parentid=1
+DEAL:1d::cellid=0_1:1 parentid=0
+DEAL:1d::cellid=0_2:00 parentid=0
+DEAL:1d::cellid=0_2:01 parentid=0
+DEAL:1d::OK
+DEAL:2d::cells before: 16
+DEAL:2d::cellid=0_1:0 parentid=0 refining
+DEAL:2d::cellid=0_1:1 parentid=0
+DEAL:2d::cellid=0_1:2 parentid=0
+DEAL:2d::cellid=0_1:3 parentid=0
+DEAL:2d::cellid=1_1:0 parentid=1
+DEAL:2d::cellid=1_1:1 parentid=1
+DEAL:2d::cellid=1_1:2 parentid=1
+DEAL:2d::cellid=1_1:3 parentid=1
+DEAL:2d::cellid=2_1:0 parentid=2
+DEAL:2d::cellid=2_1:1 parentid=2
+DEAL:2d::cellid=2_1:2 parentid=2
+DEAL:2d::cellid=2_1:3 parentid=2
+DEAL:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:2d::cells after: 16
+DEAL:2d::cellid=3_0: parentid=3
+DEAL:2d::cellid=0_1:1 parentid=0
+DEAL:2d::cellid=0_1:2 parentid=0
+DEAL:2d::cellid=0_1:3 parentid=0
+DEAL:2d::cellid=1_1:0 parentid=1
+DEAL:2d::cellid=1_1:1 parentid=1
+DEAL:2d::cellid=1_1:2 parentid=1
+DEAL:2d::cellid=1_1:3 parentid=1
+DEAL:2d::cellid=2_1:0 parentid=2
+DEAL:2d::cellid=2_1:1 parentid=2
+DEAL:2d::cellid=2_1:2 parentid=2
+DEAL:2d::cellid=2_1:3 parentid=2
+DEAL:2d::cellid=0_2:00 parentid=0
+DEAL:2d::cellid=0_2:01 parentid=0
+DEAL:2d::cellid=0_2:02 parentid=0
+DEAL:2d::cellid=0_2:03 parentid=0
+DEAL:2d::OK
+DEAL:3d::cells before: 64
+DEAL:3d::cellid=0_1:0 parentid=0 refining
+DEAL:3d::cellid=0_1:1 parentid=0
+DEAL:3d::cellid=0_1:2 parentid=0
+DEAL:3d::cellid=0_1:3 parentid=0
+DEAL:3d::cellid=0_1:4 parentid=0
+DEAL:3d::cellid=0_1:5 parentid=0
+DEAL:3d::cellid=0_1:6 parentid=0
+DEAL:3d::cellid=0_1:7 parentid=0
+DEAL:3d::cellid=1_1:0 parentid=1
+DEAL:3d::cellid=1_1:1 parentid=1
+DEAL:3d::cellid=1_1:2 parentid=1
+DEAL:3d::cellid=1_1:3 parentid=1
+DEAL:3d::cellid=1_1:4 parentid=1
+DEAL:3d::cellid=1_1:5 parentid=1
+DEAL:3d::cellid=1_1:6 parentid=1
+DEAL:3d::cellid=1_1:7 parentid=1
+DEAL:3d::cellid=2_1:0 parentid=2
+DEAL:3d::cellid=2_1:1 parentid=2
+DEAL:3d::cellid=2_1:2 parentid=2
+DEAL:3d::cellid=2_1:3 parentid=2
+DEAL:3d::cellid=2_1:4 parentid=2
+DEAL:3d::cellid=2_1:5 parentid=2
+DEAL:3d::cellid=2_1:6 parentid=2
+DEAL:3d::cellid=2_1:7 parentid=2
+DEAL:3d::cellid=3_1:0 parentid=3
+DEAL:3d::cellid=3_1:1 parentid=3
+DEAL:3d::cellid=3_1:2 parentid=3
+DEAL:3d::cellid=3_1:3 parentid=3
+DEAL:3d::cellid=3_1:4 parentid=3
+DEAL:3d::cellid=3_1:5 parentid=3
+DEAL:3d::cellid=3_1:6 parentid=3
+DEAL:3d::cellid=3_1:7 parentid=3
+DEAL:3d::cellid=4_1:0 parentid=4
+DEAL:3d::cellid=4_1:1 parentid=4
+DEAL:3d::cellid=4_1:2 parentid=4
+DEAL:3d::cellid=4_1:3 parentid=4
+DEAL:3d::cellid=4_1:4 parentid=4
+DEAL:3d::cellid=4_1:5 parentid=4
+DEAL:3d::cellid=4_1:6 parentid=4
+DEAL:3d::cellid=4_1:7 parentid=4
+DEAL:3d::cellid=5_1:0 parentid=5
+DEAL:3d::cellid=5_1:1 parentid=5
+DEAL:3d::cellid=5_1:2 parentid=5
+DEAL:3d::cellid=5_1:3 parentid=5
+DEAL:3d::cellid=5_1:4 parentid=5
+DEAL:3d::cellid=5_1:5 parentid=5
+DEAL:3d::cellid=5_1:6 parentid=5
+DEAL:3d::cellid=5_1:7 parentid=5
+DEAL:3d::cellid=6_1:0 parentid=6
+DEAL:3d::cellid=6_1:1 parentid=6
+DEAL:3d::cellid=6_1:2 parentid=6
+DEAL:3d::cellid=6_1:3 parentid=6
+DEAL:3d::cellid=6_1:4 parentid=6
+DEAL:3d::cellid=6_1:5 parentid=6
+DEAL:3d::cellid=6_1:6 parentid=6
+DEAL:3d::cellid=6_1:7 parentid=6
+DEAL:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:3d::cells after: 64
+DEAL:3d::cellid=7_0: parentid=7
+DEAL:3d::cellid=0_1:1 parentid=0
+DEAL:3d::cellid=0_1:2 parentid=0
+DEAL:3d::cellid=0_1:3 parentid=0
+DEAL:3d::cellid=0_1:4 parentid=0
+DEAL:3d::cellid=0_1:5 parentid=0
+DEAL:3d::cellid=0_1:6 parentid=0
+DEAL:3d::cellid=0_1:7 parentid=0
+DEAL:3d::cellid=1_1:0 parentid=1
+DEAL:3d::cellid=1_1:1 parentid=1
+DEAL:3d::cellid=1_1:2 parentid=1
+DEAL:3d::cellid=1_1:3 parentid=1
+DEAL:3d::cellid=1_1:4 parentid=1
+DEAL:3d::cellid=1_1:5 parentid=1
+DEAL:3d::cellid=1_1:6 parentid=1
+DEAL:3d::cellid=1_1:7 parentid=1
+DEAL:3d::cellid=2_1:0 parentid=2
+DEAL:3d::cellid=2_1:1 parentid=2
+DEAL:3d::cellid=2_1:2 parentid=2
+DEAL:3d::cellid=2_1:3 parentid=2
+DEAL:3d::cellid=2_1:4 parentid=2
+DEAL:3d::cellid=2_1:5 parentid=2
+DEAL:3d::cellid=2_1:6 parentid=2
+DEAL:3d::cellid=2_1:7 parentid=2
+DEAL:3d::cellid=3_1:0 parentid=3
+DEAL:3d::cellid=3_1:1 parentid=3
+DEAL:3d::cellid=3_1:2 parentid=3
+DEAL:3d::cellid=3_1:3 parentid=3
+DEAL:3d::cellid=3_1:4 parentid=3
+DEAL:3d::cellid=3_1:5 parentid=3
+DEAL:3d::cellid=3_1:6 parentid=3
+DEAL:3d::cellid=3_1:7 parentid=3
+DEAL:3d::cellid=4_1:0 parentid=4
+DEAL:3d::cellid=4_1:1 parentid=4
+DEAL:3d::cellid=4_1:2 parentid=4
+DEAL:3d::cellid=4_1:3 parentid=4
+DEAL:3d::cellid=4_1:4 parentid=4
+DEAL:3d::cellid=4_1:5 parentid=4
+DEAL:3d::cellid=4_1:6 parentid=4
+DEAL:3d::cellid=4_1:7 parentid=4
+DEAL:3d::cellid=5_1:0 parentid=5
+DEAL:3d::cellid=5_1:1 parentid=5
+DEAL:3d::cellid=5_1:2 parentid=5
+DEAL:3d::cellid=5_1:3 parentid=5
+DEAL:3d::cellid=5_1:4 parentid=5
+DEAL:3d::cellid=5_1:5 parentid=5
+DEAL:3d::cellid=5_1:6 parentid=5
+DEAL:3d::cellid=5_1:7 parentid=5
+DEAL:3d::cellid=6_1:0 parentid=6
+DEAL:3d::cellid=6_1:1 parentid=6
+DEAL:3d::cellid=6_1:2 parentid=6
+DEAL:3d::cellid=6_1:3 parentid=6
+DEAL:3d::cellid=6_1:4 parentid=6
+DEAL:3d::cellid=6_1:5 parentid=6
+DEAL:3d::cellid=6_1:6 parentid=6
+DEAL:3d::cellid=6_1:7 parentid=6
+DEAL:3d::cellid=0_2:00 parentid=0
+DEAL:3d::cellid=0_2:01 parentid=0
+DEAL:3d::cellid=0_2:02 parentid=0
+DEAL:3d::cellid=0_2:03 parentid=0
+DEAL:3d::cellid=0_2:04 parentid=0
+DEAL:3d::cellid=0_2:05 parentid=0
+DEAL:3d::cellid=0_2:06 parentid=0
+DEAL:3d::cellid=0_2:07 parentid=0
+DEAL:3d::OK
diff --git a/tests/sharedtria/cell_data_transfer_01.cc b/tests/sharedtria/cell_data_transfer_01.cc
new file mode 100644 (file)
index 0000000..caf10a8
--- /dev/null
@@ -0,0 +1,138 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+
+
+// CellDataTransfer test by refinement
+// for parallel::shared::Triangulation without artificial cells
+
+
+#include <deal.II/distributed/shared_tria.h>
+
+#include <deal.II/grid/grid_generator.h>
+
+#include <deal.II/lac/petsc_vector.h>
+#include <deal.II/lac/vector.templates.h>
+
+#include <deal.II/numerics/cell_data_transfer.templates.h>
+
+#include <string>
+
+#include "../tests.h"
+
+
+template <int dim, int spacedim>
+void
+test()
+{
+  // ------ setup ------
+  MPI_Comm                             mpi_communicator(MPI_COMM_WORLD);
+  parallel::shared::Triangulation<dim> tria(mpi_communicator,
+                                            ::Triangulation<dim>::none,
+                                            false);
+
+  GridGenerator::subdivided_hyper_cube(tria, 2);
+  tria.refine_global(1);
+  deallog << "cells before: " << tria.n_global_active_cells() << std::endl;
+
+  // ----- prepare -----
+  // set refinement/coarsening flags
+  for (auto &cell : tria.active_cell_iterators())
+    {
+      if (cell->id().to_string() == "0_1:0")
+        cell->set_refine_flag();
+      else if (((dim == 1) && (cell->parent()->id().to_string() == "1_0:")) ||
+               ((dim == 2) && (cell->parent()->id().to_string() == "3_0:")) ||
+               ((dim == 3) && (cell->parent()->id().to_string() == "7_0:")))
+        cell->set_coarsen_flag();
+    }
+
+  // ----- gather -----
+  // store parent id of all locally owned cells
+  Vector<unsigned int> cell_ids_pre(tria.n_active_cells());
+  for (const auto &cell : tria.active_cell_iterators())
+    if (cell->is_locally_owned())
+      {
+        const std::string  parent_cellid = cell->parent()->id().to_string();
+        const unsigned int parent_coarse_cell_id =
+          static_cast<unsigned int>(std::stoul(parent_cellid));
+        cell_ids_pre(cell->active_cell_index()) = parent_coarse_cell_id;
+      }
+
+  // distribute local vector (as presented in step-18)
+  PETScWrappers::MPI::Vector distributed_cell_ids_pre(
+    mpi_communicator,
+    tria.n_active_cells(),
+    tria.n_locally_owned_active_cells());
+
+  for (const auto &cell : tria.active_cell_iterators())
+    if (cell->is_locally_owned())
+      distributed_cell_ids_pre(cell->active_cell_index()) =
+        cell_ids_pre(cell->active_cell_index());
+  distributed_cell_ids_pre.compress(VectorOperation::insert);
+
+  cell_ids_pre = distributed_cell_ids_pre;
+
+  // output initial situation
+  for (const auto &cell : tria.active_cell_iterators())
+    {
+      deallog << "cellid=" << cell->id()
+              << " parentid=" << cell_ids_pre(cell->active_cell_index());
+      if (cell->coarsen_flag_set())
+        deallog << " coarsening";
+      else if (cell->refine_flag_set())
+        deallog << " refining";
+      deallog << std::endl;
+    }
+
+  // ----- transfer -----
+  CellDataTransfer<dim, spacedim, Vector<unsigned int>> cell_data_transfer(
+    tria);
+
+  cell_data_transfer.prepare_for_coarsening_and_refinement();
+  tria.execute_coarsening_and_refinement();
+  deallog << "cells after: " << tria.n_global_active_cells() << std::endl;
+
+  Vector<unsigned int> cell_ids_post(tria.n_active_cells());
+  cell_data_transfer.unpack(cell_ids_pre, cell_ids_post);
+
+  // ------ verify ------
+  // check if all children adopted the correct id
+  for (auto &cell : tria.active_cell_iterators())
+    deallog << "cellid=" << cell->id()
+            << " parentid=" << cell_ids_post(cell->active_cell_index())
+            << std::endl;
+
+  deallog << "OK" << std::endl;
+}
+
+
+int
+main(int argc, char *argv[])
+{
+  Utilities::MPI::MPI_InitFinalize mpi_initialization(argc, argv, 1);
+
+  MPILogInitAll all;
+
+  deallog.push("1d");
+  test<1, 1>();
+  deallog.pop();
+  deallog.push("2d");
+  test<2, 2>();
+  deallog.pop();
+  deallog.push("3d");
+  test<3, 3>();
+  deallog.pop();
+}
diff --git a/tests/sharedtria/cell_data_transfer_01.with_mpi=true.with_petsc=true.mpirun=1.output b/tests/sharedtria/cell_data_transfer_01.with_mpi=true.with_petsc=true.mpirun=1.output
new file mode 100644 (file)
index 0000000..10496a9
--- /dev/null
@@ -0,0 +1,178 @@
+
+DEAL:0:1d::cells before: 4
+DEAL:0:1d::cellid=0_1:0 parentid=0 refining
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:0:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:0:1d::cells after: 4
+DEAL:0:1d::cellid=1_0: parentid=1
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=0_2:00 parentid=0
+DEAL:0:1d::cellid=0_2:01 parentid=0
+DEAL:0:1d::OK
+DEAL:0:2d::cells before: 16
+DEAL:0:2d::cellid=0_1:0 parentid=0 refining
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:0:2d::cells after: 16
+DEAL:0:2d::cellid=3_0: parentid=3
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=0_2:00 parentid=0
+DEAL:0:2d::cellid=0_2:01 parentid=0
+DEAL:0:2d::cellid=0_2:02 parentid=0
+DEAL:0:2d::cellid=0_2:03 parentid=0
+DEAL:0:2d::OK
+DEAL:0:3d::cells before: 64
+DEAL:0:3d::cellid=0_1:0 parentid=0 refining
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:0:3d::cells after: 64
+DEAL:0:3d::cellid=7_0: parentid=7
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=0_2:00 parentid=0
+DEAL:0:3d::cellid=0_2:01 parentid=0
+DEAL:0:3d::cellid=0_2:02 parentid=0
+DEAL:0:3d::cellid=0_2:03 parentid=0
+DEAL:0:3d::cellid=0_2:04 parentid=0
+DEAL:0:3d::cellid=0_2:05 parentid=0
+DEAL:0:3d::cellid=0_2:06 parentid=0
+DEAL:0:3d::cellid=0_2:07 parentid=0
+DEAL:0:3d::OK
diff --git a/tests/sharedtria/cell_data_transfer_01.with_mpi=true.with_petsc=true.mpirun=2.output b/tests/sharedtria/cell_data_transfer_01.with_mpi=true.with_petsc=true.mpirun=2.output
new file mode 100644 (file)
index 0000000..fe542aa
--- /dev/null
@@ -0,0 +1,357 @@
+
+DEAL:0:1d::cells before: 4
+DEAL:0:1d::cellid=0_1:0 parentid=0 refining
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:0:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:0:1d::cells after: 4
+DEAL:0:1d::cellid=1_0: parentid=1
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=0_2:00 parentid=0
+DEAL:0:1d::cellid=0_2:01 parentid=0
+DEAL:0:1d::OK
+DEAL:0:2d::cells before: 16
+DEAL:0:2d::cellid=0_1:0 parentid=0 refining
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:0:2d::cells after: 16
+DEAL:0:2d::cellid=3_0: parentid=3
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=0_2:00 parentid=0
+DEAL:0:2d::cellid=0_2:01 parentid=0
+DEAL:0:2d::cellid=0_2:02 parentid=0
+DEAL:0:2d::cellid=0_2:03 parentid=0
+DEAL:0:2d::OK
+DEAL:0:3d::cells before: 64
+DEAL:0:3d::cellid=0_1:0 parentid=0 refining
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:0:3d::cells after: 64
+DEAL:0:3d::cellid=7_0: parentid=7
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=0_2:00 parentid=0
+DEAL:0:3d::cellid=0_2:01 parentid=0
+DEAL:0:3d::cellid=0_2:02 parentid=0
+DEAL:0:3d::cellid=0_2:03 parentid=0
+DEAL:0:3d::cellid=0_2:04 parentid=0
+DEAL:0:3d::cellid=0_2:05 parentid=0
+DEAL:0:3d::cellid=0_2:06 parentid=0
+DEAL:0:3d::cellid=0_2:07 parentid=0
+DEAL:0:3d::OK
+
+DEAL:1:1d::cells before: 4
+DEAL:1:1d::cellid=0_1:0 parentid=0 refining
+DEAL:1:1d::cellid=0_1:1 parentid=0
+DEAL:1:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:1:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:1:1d::cells after: 4
+DEAL:1:1d::cellid=1_0: parentid=1
+DEAL:1:1d::cellid=0_1:1 parentid=0
+DEAL:1:1d::cellid=0_2:00 parentid=0
+DEAL:1:1d::cellid=0_2:01 parentid=0
+DEAL:1:1d::OK
+DEAL:1:2d::cells before: 16
+DEAL:1:2d::cellid=0_1:0 parentid=0 refining
+DEAL:1:2d::cellid=0_1:1 parentid=0
+DEAL:1:2d::cellid=0_1:2 parentid=0
+DEAL:1:2d::cellid=0_1:3 parentid=0
+DEAL:1:2d::cellid=1_1:0 parentid=1
+DEAL:1:2d::cellid=1_1:1 parentid=1
+DEAL:1:2d::cellid=1_1:2 parentid=1
+DEAL:1:2d::cellid=1_1:3 parentid=1
+DEAL:1:2d::cellid=2_1:0 parentid=2
+DEAL:1:2d::cellid=2_1:1 parentid=2
+DEAL:1:2d::cellid=2_1:2 parentid=2
+DEAL:1:2d::cellid=2_1:3 parentid=2
+DEAL:1:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:1:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:1:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:1:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:1:2d::cells after: 16
+DEAL:1:2d::cellid=3_0: parentid=3
+DEAL:1:2d::cellid=0_1:1 parentid=0
+DEAL:1:2d::cellid=0_1:2 parentid=0
+DEAL:1:2d::cellid=0_1:3 parentid=0
+DEAL:1:2d::cellid=1_1:0 parentid=1
+DEAL:1:2d::cellid=1_1:1 parentid=1
+DEAL:1:2d::cellid=1_1:2 parentid=1
+DEAL:1:2d::cellid=1_1:3 parentid=1
+DEAL:1:2d::cellid=2_1:0 parentid=2
+DEAL:1:2d::cellid=2_1:1 parentid=2
+DEAL:1:2d::cellid=2_1:2 parentid=2
+DEAL:1:2d::cellid=2_1:3 parentid=2
+DEAL:1:2d::cellid=0_2:00 parentid=0
+DEAL:1:2d::cellid=0_2:01 parentid=0
+DEAL:1:2d::cellid=0_2:02 parentid=0
+DEAL:1:2d::cellid=0_2:03 parentid=0
+DEAL:1:2d::OK
+DEAL:1:3d::cells before: 64
+DEAL:1:3d::cellid=0_1:0 parentid=0 refining
+DEAL:1:3d::cellid=0_1:1 parentid=0
+DEAL:1:3d::cellid=0_1:2 parentid=0
+DEAL:1:3d::cellid=0_1:3 parentid=0
+DEAL:1:3d::cellid=0_1:4 parentid=0
+DEAL:1:3d::cellid=0_1:5 parentid=0
+DEAL:1:3d::cellid=0_1:6 parentid=0
+DEAL:1:3d::cellid=0_1:7 parentid=0
+DEAL:1:3d::cellid=1_1:0 parentid=1
+DEAL:1:3d::cellid=1_1:1 parentid=1
+DEAL:1:3d::cellid=1_1:2 parentid=1
+DEAL:1:3d::cellid=1_1:3 parentid=1
+DEAL:1:3d::cellid=1_1:4 parentid=1
+DEAL:1:3d::cellid=1_1:5 parentid=1
+DEAL:1:3d::cellid=1_1:6 parentid=1
+DEAL:1:3d::cellid=1_1:7 parentid=1
+DEAL:1:3d::cellid=2_1:0 parentid=2
+DEAL:1:3d::cellid=2_1:1 parentid=2
+DEAL:1:3d::cellid=2_1:2 parentid=2
+DEAL:1:3d::cellid=2_1:3 parentid=2
+DEAL:1:3d::cellid=2_1:4 parentid=2
+DEAL:1:3d::cellid=2_1:5 parentid=2
+DEAL:1:3d::cellid=2_1:6 parentid=2
+DEAL:1:3d::cellid=2_1:7 parentid=2
+DEAL:1:3d::cellid=3_1:0 parentid=3
+DEAL:1:3d::cellid=3_1:1 parentid=3
+DEAL:1:3d::cellid=3_1:2 parentid=3
+DEAL:1:3d::cellid=3_1:3 parentid=3
+DEAL:1:3d::cellid=3_1:4 parentid=3
+DEAL:1:3d::cellid=3_1:5 parentid=3
+DEAL:1:3d::cellid=3_1:6 parentid=3
+DEAL:1:3d::cellid=3_1:7 parentid=3
+DEAL:1:3d::cellid=4_1:0 parentid=4
+DEAL:1:3d::cellid=4_1:1 parentid=4
+DEAL:1:3d::cellid=4_1:2 parentid=4
+DEAL:1:3d::cellid=4_1:3 parentid=4
+DEAL:1:3d::cellid=4_1:4 parentid=4
+DEAL:1:3d::cellid=4_1:5 parentid=4
+DEAL:1:3d::cellid=4_1:6 parentid=4
+DEAL:1:3d::cellid=4_1:7 parentid=4
+DEAL:1:3d::cellid=5_1:0 parentid=5
+DEAL:1:3d::cellid=5_1:1 parentid=5
+DEAL:1:3d::cellid=5_1:2 parentid=5
+DEAL:1:3d::cellid=5_1:3 parentid=5
+DEAL:1:3d::cellid=5_1:4 parentid=5
+DEAL:1:3d::cellid=5_1:5 parentid=5
+DEAL:1:3d::cellid=5_1:6 parentid=5
+DEAL:1:3d::cellid=5_1:7 parentid=5
+DEAL:1:3d::cellid=6_1:0 parentid=6
+DEAL:1:3d::cellid=6_1:1 parentid=6
+DEAL:1:3d::cellid=6_1:2 parentid=6
+DEAL:1:3d::cellid=6_1:3 parentid=6
+DEAL:1:3d::cellid=6_1:4 parentid=6
+DEAL:1:3d::cellid=6_1:5 parentid=6
+DEAL:1:3d::cellid=6_1:6 parentid=6
+DEAL:1:3d::cellid=6_1:7 parentid=6
+DEAL:1:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:1:3d::cells after: 64
+DEAL:1:3d::cellid=7_0: parentid=7
+DEAL:1:3d::cellid=0_1:1 parentid=0
+DEAL:1:3d::cellid=0_1:2 parentid=0
+DEAL:1:3d::cellid=0_1:3 parentid=0
+DEAL:1:3d::cellid=0_1:4 parentid=0
+DEAL:1:3d::cellid=0_1:5 parentid=0
+DEAL:1:3d::cellid=0_1:6 parentid=0
+DEAL:1:3d::cellid=0_1:7 parentid=0
+DEAL:1:3d::cellid=1_1:0 parentid=1
+DEAL:1:3d::cellid=1_1:1 parentid=1
+DEAL:1:3d::cellid=1_1:2 parentid=1
+DEAL:1:3d::cellid=1_1:3 parentid=1
+DEAL:1:3d::cellid=1_1:4 parentid=1
+DEAL:1:3d::cellid=1_1:5 parentid=1
+DEAL:1:3d::cellid=1_1:6 parentid=1
+DEAL:1:3d::cellid=1_1:7 parentid=1
+DEAL:1:3d::cellid=2_1:0 parentid=2
+DEAL:1:3d::cellid=2_1:1 parentid=2
+DEAL:1:3d::cellid=2_1:2 parentid=2
+DEAL:1:3d::cellid=2_1:3 parentid=2
+DEAL:1:3d::cellid=2_1:4 parentid=2
+DEAL:1:3d::cellid=2_1:5 parentid=2
+DEAL:1:3d::cellid=2_1:6 parentid=2
+DEAL:1:3d::cellid=2_1:7 parentid=2
+DEAL:1:3d::cellid=3_1:0 parentid=3
+DEAL:1:3d::cellid=3_1:1 parentid=3
+DEAL:1:3d::cellid=3_1:2 parentid=3
+DEAL:1:3d::cellid=3_1:3 parentid=3
+DEAL:1:3d::cellid=3_1:4 parentid=3
+DEAL:1:3d::cellid=3_1:5 parentid=3
+DEAL:1:3d::cellid=3_1:6 parentid=3
+DEAL:1:3d::cellid=3_1:7 parentid=3
+DEAL:1:3d::cellid=4_1:0 parentid=4
+DEAL:1:3d::cellid=4_1:1 parentid=4
+DEAL:1:3d::cellid=4_1:2 parentid=4
+DEAL:1:3d::cellid=4_1:3 parentid=4
+DEAL:1:3d::cellid=4_1:4 parentid=4
+DEAL:1:3d::cellid=4_1:5 parentid=4
+DEAL:1:3d::cellid=4_1:6 parentid=4
+DEAL:1:3d::cellid=4_1:7 parentid=4
+DEAL:1:3d::cellid=5_1:0 parentid=5
+DEAL:1:3d::cellid=5_1:1 parentid=5
+DEAL:1:3d::cellid=5_1:2 parentid=5
+DEAL:1:3d::cellid=5_1:3 parentid=5
+DEAL:1:3d::cellid=5_1:4 parentid=5
+DEAL:1:3d::cellid=5_1:5 parentid=5
+DEAL:1:3d::cellid=5_1:6 parentid=5
+DEAL:1:3d::cellid=5_1:7 parentid=5
+DEAL:1:3d::cellid=6_1:0 parentid=6
+DEAL:1:3d::cellid=6_1:1 parentid=6
+DEAL:1:3d::cellid=6_1:2 parentid=6
+DEAL:1:3d::cellid=6_1:3 parentid=6
+DEAL:1:3d::cellid=6_1:4 parentid=6
+DEAL:1:3d::cellid=6_1:5 parentid=6
+DEAL:1:3d::cellid=6_1:6 parentid=6
+DEAL:1:3d::cellid=6_1:7 parentid=6
+DEAL:1:3d::cellid=0_2:00 parentid=0
+DEAL:1:3d::cellid=0_2:01 parentid=0
+DEAL:1:3d::cellid=0_2:02 parentid=0
+DEAL:1:3d::cellid=0_2:03 parentid=0
+DEAL:1:3d::cellid=0_2:04 parentid=0
+DEAL:1:3d::cellid=0_2:05 parentid=0
+DEAL:1:3d::cellid=0_2:06 parentid=0
+DEAL:1:3d::cellid=0_2:07 parentid=0
+DEAL:1:3d::OK
+
diff --git a/tests/sharedtria/cell_data_transfer_02.cc b/tests/sharedtria/cell_data_transfer_02.cc
new file mode 100644 (file)
index 0000000..e49db83
--- /dev/null
@@ -0,0 +1,138 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2019 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE.md at
+// the top level directory of deal.II.
+//
+// ---------------------------------------------------------------------
+
+
+
+// CellDataTransfer test by refinement
+// for parallel::shared::Triangulation with artificial cells
+
+
+#include <deal.II/distributed/shared_tria.h>
+
+#include <deal.II/grid/grid_generator.h>
+
+#include <deal.II/lac/petsc_vector.h>
+#include <deal.II/lac/vector.templates.h>
+
+#include <deal.II/numerics/cell_data_transfer.templates.h>
+
+#include <string>
+
+#include "../tests.h"
+
+
+template <int dim, int spacedim>
+void
+test()
+{
+  // ------ setup ------
+  MPI_Comm                             mpi_communicator(MPI_COMM_WORLD);
+  parallel::shared::Triangulation<dim> tria(mpi_communicator,
+                                            ::Triangulation<dim>::none,
+                                            true);
+
+  GridGenerator::subdivided_hyper_cube(tria, 2);
+  tria.refine_global(1);
+  deallog << "cells before: " << tria.n_global_active_cells() << std::endl;
+
+  // ----- prepare -----
+  // set refinement/coarsening flags
+  for (auto &cell : tria.active_cell_iterators())
+    {
+      if (cell->id().to_string() == "0_1:0")
+        cell->set_refine_flag();
+      else if (((dim == 1) && (cell->parent()->id().to_string() == "1_0:")) ||
+               ((dim == 2) && (cell->parent()->id().to_string() == "3_0:")) ||
+               ((dim == 3) && (cell->parent()->id().to_string() == "7_0:")))
+        cell->set_coarsen_flag();
+    }
+
+  // ----- gather -----
+  // store parent id of all locally owned cells
+  Vector<unsigned int> cell_ids_pre(tria.n_active_cells());
+  for (const auto &cell : tria.active_cell_iterators())
+    if (cell->is_locally_owned())
+      {
+        const std::string  parent_cellid = cell->parent()->id().to_string();
+        const unsigned int parent_coarse_cell_id =
+          static_cast<unsigned int>(std::stoul(parent_cellid));
+        cell_ids_pre(cell->active_cell_index()) = parent_coarse_cell_id;
+      }
+
+  // distribute local vector (as presented in step-18)
+  PETScWrappers::MPI::Vector distributed_cell_ids_pre(
+    mpi_communicator,
+    tria.n_active_cells(),
+    tria.n_locally_owned_active_cells());
+
+  for (const auto &cell : tria.active_cell_iterators())
+    if (cell->is_locally_owned())
+      distributed_cell_ids_pre(cell->active_cell_index()) =
+        cell_ids_pre(cell->active_cell_index());
+  distributed_cell_ids_pre.compress(VectorOperation::insert);
+
+  cell_ids_pre = distributed_cell_ids_pre;
+
+  // output initial situation
+  for (const auto &cell : tria.active_cell_iterators())
+    {
+      deallog << "cellid=" << cell->id()
+              << " parentid=" << cell_ids_pre(cell->active_cell_index());
+      if (cell->coarsen_flag_set())
+        deallog << " coarsening";
+      else if (cell->refine_flag_set())
+        deallog << " refining";
+      deallog << std::endl;
+    }
+
+  // ----- transfer -----
+  CellDataTransfer<dim, spacedim, Vector<unsigned int>> cell_data_transfer(
+    tria);
+
+  cell_data_transfer.prepare_for_coarsening_and_refinement();
+  tria.execute_coarsening_and_refinement();
+  deallog << "cells after: " << tria.n_global_active_cells() << std::endl;
+
+  Vector<unsigned int> cell_ids_post(tria.n_active_cells());
+  cell_data_transfer.unpack(cell_ids_pre, cell_ids_post);
+
+  // ------ verify ------
+  // check if all children adopted the correct id
+  for (auto &cell : tria.active_cell_iterators())
+    deallog << "cellid=" << cell->id()
+            << " parentid=" << cell_ids_post(cell->active_cell_index())
+            << std::endl;
+
+  deallog << "OK" << std::endl;
+}
+
+
+int
+main(int argc, char *argv[])
+{
+  Utilities::MPI::MPI_InitFinalize mpi_initialization(argc, argv, 1);
+
+  MPILogInitAll all;
+
+  deallog.push("1d");
+  test<1, 1>();
+  deallog.pop();
+  deallog.push("2d");
+  test<2, 2>();
+  deallog.pop();
+  deallog.push("3d");
+  test<3, 3>();
+  deallog.pop();
+}
diff --git a/tests/sharedtria/cell_data_transfer_02.with_mpi=true.with_petsc=true.mpirun=1.output b/tests/sharedtria/cell_data_transfer_02.with_mpi=true.with_petsc=true.mpirun=1.output
new file mode 100644 (file)
index 0000000..10496a9
--- /dev/null
@@ -0,0 +1,178 @@
+
+DEAL:0:1d::cells before: 4
+DEAL:0:1d::cellid=0_1:0 parentid=0 refining
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:0:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:0:1d::cells after: 4
+DEAL:0:1d::cellid=1_0: parentid=1
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=0_2:00 parentid=0
+DEAL:0:1d::cellid=0_2:01 parentid=0
+DEAL:0:1d::OK
+DEAL:0:2d::cells before: 16
+DEAL:0:2d::cellid=0_1:0 parentid=0 refining
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:0:2d::cells after: 16
+DEAL:0:2d::cellid=3_0: parentid=3
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=0_2:00 parentid=0
+DEAL:0:2d::cellid=0_2:01 parentid=0
+DEAL:0:2d::cellid=0_2:02 parentid=0
+DEAL:0:2d::cellid=0_2:03 parentid=0
+DEAL:0:2d::OK
+DEAL:0:3d::cells before: 64
+DEAL:0:3d::cellid=0_1:0 parentid=0 refining
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:0:3d::cells after: 64
+DEAL:0:3d::cellid=7_0: parentid=7
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=0_2:00 parentid=0
+DEAL:0:3d::cellid=0_2:01 parentid=0
+DEAL:0:3d::cellid=0_2:02 parentid=0
+DEAL:0:3d::cellid=0_2:03 parentid=0
+DEAL:0:3d::cellid=0_2:04 parentid=0
+DEAL:0:3d::cellid=0_2:05 parentid=0
+DEAL:0:3d::cellid=0_2:06 parentid=0
+DEAL:0:3d::cellid=0_2:07 parentid=0
+DEAL:0:3d::OK
diff --git a/tests/sharedtria/cell_data_transfer_02.with_mpi=true.with_petsc=true.mpirun=2.output b/tests/sharedtria/cell_data_transfer_02.with_mpi=true.with_petsc=true.mpirun=2.output
new file mode 100644 (file)
index 0000000..fe542aa
--- /dev/null
@@ -0,0 +1,357 @@
+
+DEAL:0:1d::cells before: 4
+DEAL:0:1d::cellid=0_1:0 parentid=0 refining
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:0:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:0:1d::cells after: 4
+DEAL:0:1d::cellid=1_0: parentid=1
+DEAL:0:1d::cellid=0_1:1 parentid=0
+DEAL:0:1d::cellid=0_2:00 parentid=0
+DEAL:0:1d::cellid=0_2:01 parentid=0
+DEAL:0:1d::OK
+DEAL:0:2d::cells before: 16
+DEAL:0:2d::cellid=0_1:0 parentid=0 refining
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:0:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:0:2d::cells after: 16
+DEAL:0:2d::cellid=3_0: parentid=3
+DEAL:0:2d::cellid=0_1:1 parentid=0
+DEAL:0:2d::cellid=0_1:2 parentid=0
+DEAL:0:2d::cellid=0_1:3 parentid=0
+DEAL:0:2d::cellid=1_1:0 parentid=1
+DEAL:0:2d::cellid=1_1:1 parentid=1
+DEAL:0:2d::cellid=1_1:2 parentid=1
+DEAL:0:2d::cellid=1_1:3 parentid=1
+DEAL:0:2d::cellid=2_1:0 parentid=2
+DEAL:0:2d::cellid=2_1:1 parentid=2
+DEAL:0:2d::cellid=2_1:2 parentid=2
+DEAL:0:2d::cellid=2_1:3 parentid=2
+DEAL:0:2d::cellid=0_2:00 parentid=0
+DEAL:0:2d::cellid=0_2:01 parentid=0
+DEAL:0:2d::cellid=0_2:02 parentid=0
+DEAL:0:2d::cellid=0_2:03 parentid=0
+DEAL:0:2d::OK
+DEAL:0:3d::cells before: 64
+DEAL:0:3d::cellid=0_1:0 parentid=0 refining
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:0:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:0:3d::cells after: 64
+DEAL:0:3d::cellid=7_0: parentid=7
+DEAL:0:3d::cellid=0_1:1 parentid=0
+DEAL:0:3d::cellid=0_1:2 parentid=0
+DEAL:0:3d::cellid=0_1:3 parentid=0
+DEAL:0:3d::cellid=0_1:4 parentid=0
+DEAL:0:3d::cellid=0_1:5 parentid=0
+DEAL:0:3d::cellid=0_1:6 parentid=0
+DEAL:0:3d::cellid=0_1:7 parentid=0
+DEAL:0:3d::cellid=1_1:0 parentid=1
+DEAL:0:3d::cellid=1_1:1 parentid=1
+DEAL:0:3d::cellid=1_1:2 parentid=1
+DEAL:0:3d::cellid=1_1:3 parentid=1
+DEAL:0:3d::cellid=1_1:4 parentid=1
+DEAL:0:3d::cellid=1_1:5 parentid=1
+DEAL:0:3d::cellid=1_1:6 parentid=1
+DEAL:0:3d::cellid=1_1:7 parentid=1
+DEAL:0:3d::cellid=2_1:0 parentid=2
+DEAL:0:3d::cellid=2_1:1 parentid=2
+DEAL:0:3d::cellid=2_1:2 parentid=2
+DEAL:0:3d::cellid=2_1:3 parentid=2
+DEAL:0:3d::cellid=2_1:4 parentid=2
+DEAL:0:3d::cellid=2_1:5 parentid=2
+DEAL:0:3d::cellid=2_1:6 parentid=2
+DEAL:0:3d::cellid=2_1:7 parentid=2
+DEAL:0:3d::cellid=3_1:0 parentid=3
+DEAL:0:3d::cellid=3_1:1 parentid=3
+DEAL:0:3d::cellid=3_1:2 parentid=3
+DEAL:0:3d::cellid=3_1:3 parentid=3
+DEAL:0:3d::cellid=3_1:4 parentid=3
+DEAL:0:3d::cellid=3_1:5 parentid=3
+DEAL:0:3d::cellid=3_1:6 parentid=3
+DEAL:0:3d::cellid=3_1:7 parentid=3
+DEAL:0:3d::cellid=4_1:0 parentid=4
+DEAL:0:3d::cellid=4_1:1 parentid=4
+DEAL:0:3d::cellid=4_1:2 parentid=4
+DEAL:0:3d::cellid=4_1:3 parentid=4
+DEAL:0:3d::cellid=4_1:4 parentid=4
+DEAL:0:3d::cellid=4_1:5 parentid=4
+DEAL:0:3d::cellid=4_1:6 parentid=4
+DEAL:0:3d::cellid=4_1:7 parentid=4
+DEAL:0:3d::cellid=5_1:0 parentid=5
+DEAL:0:3d::cellid=5_1:1 parentid=5
+DEAL:0:3d::cellid=5_1:2 parentid=5
+DEAL:0:3d::cellid=5_1:3 parentid=5
+DEAL:0:3d::cellid=5_1:4 parentid=5
+DEAL:0:3d::cellid=5_1:5 parentid=5
+DEAL:0:3d::cellid=5_1:6 parentid=5
+DEAL:0:3d::cellid=5_1:7 parentid=5
+DEAL:0:3d::cellid=6_1:0 parentid=6
+DEAL:0:3d::cellid=6_1:1 parentid=6
+DEAL:0:3d::cellid=6_1:2 parentid=6
+DEAL:0:3d::cellid=6_1:3 parentid=6
+DEAL:0:3d::cellid=6_1:4 parentid=6
+DEAL:0:3d::cellid=6_1:5 parentid=6
+DEAL:0:3d::cellid=6_1:6 parentid=6
+DEAL:0:3d::cellid=6_1:7 parentid=6
+DEAL:0:3d::cellid=0_2:00 parentid=0
+DEAL:0:3d::cellid=0_2:01 parentid=0
+DEAL:0:3d::cellid=0_2:02 parentid=0
+DEAL:0:3d::cellid=0_2:03 parentid=0
+DEAL:0:3d::cellid=0_2:04 parentid=0
+DEAL:0:3d::cellid=0_2:05 parentid=0
+DEAL:0:3d::cellid=0_2:06 parentid=0
+DEAL:0:3d::cellid=0_2:07 parentid=0
+DEAL:0:3d::OK
+
+DEAL:1:1d::cells before: 4
+DEAL:1:1d::cellid=0_1:0 parentid=0 refining
+DEAL:1:1d::cellid=0_1:1 parentid=0
+DEAL:1:1d::cellid=1_1:0 parentid=1 coarsening
+DEAL:1:1d::cellid=1_1:1 parentid=1 coarsening
+DEAL:1:1d::cells after: 4
+DEAL:1:1d::cellid=1_0: parentid=1
+DEAL:1:1d::cellid=0_1:1 parentid=0
+DEAL:1:1d::cellid=0_2:00 parentid=0
+DEAL:1:1d::cellid=0_2:01 parentid=0
+DEAL:1:1d::OK
+DEAL:1:2d::cells before: 16
+DEAL:1:2d::cellid=0_1:0 parentid=0 refining
+DEAL:1:2d::cellid=0_1:1 parentid=0
+DEAL:1:2d::cellid=0_1:2 parentid=0
+DEAL:1:2d::cellid=0_1:3 parentid=0
+DEAL:1:2d::cellid=1_1:0 parentid=1
+DEAL:1:2d::cellid=1_1:1 parentid=1
+DEAL:1:2d::cellid=1_1:2 parentid=1
+DEAL:1:2d::cellid=1_1:3 parentid=1
+DEAL:1:2d::cellid=2_1:0 parentid=2
+DEAL:1:2d::cellid=2_1:1 parentid=2
+DEAL:1:2d::cellid=2_1:2 parentid=2
+DEAL:1:2d::cellid=2_1:3 parentid=2
+DEAL:1:2d::cellid=3_1:0 parentid=3 coarsening
+DEAL:1:2d::cellid=3_1:1 parentid=3 coarsening
+DEAL:1:2d::cellid=3_1:2 parentid=3 coarsening
+DEAL:1:2d::cellid=3_1:3 parentid=3 coarsening
+DEAL:1:2d::cells after: 16
+DEAL:1:2d::cellid=3_0: parentid=3
+DEAL:1:2d::cellid=0_1:1 parentid=0
+DEAL:1:2d::cellid=0_1:2 parentid=0
+DEAL:1:2d::cellid=0_1:3 parentid=0
+DEAL:1:2d::cellid=1_1:0 parentid=1
+DEAL:1:2d::cellid=1_1:1 parentid=1
+DEAL:1:2d::cellid=1_1:2 parentid=1
+DEAL:1:2d::cellid=1_1:3 parentid=1
+DEAL:1:2d::cellid=2_1:0 parentid=2
+DEAL:1:2d::cellid=2_1:1 parentid=2
+DEAL:1:2d::cellid=2_1:2 parentid=2
+DEAL:1:2d::cellid=2_1:3 parentid=2
+DEAL:1:2d::cellid=0_2:00 parentid=0
+DEAL:1:2d::cellid=0_2:01 parentid=0
+DEAL:1:2d::cellid=0_2:02 parentid=0
+DEAL:1:2d::cellid=0_2:03 parentid=0
+DEAL:1:2d::OK
+DEAL:1:3d::cells before: 64
+DEAL:1:3d::cellid=0_1:0 parentid=0 refining
+DEAL:1:3d::cellid=0_1:1 parentid=0
+DEAL:1:3d::cellid=0_1:2 parentid=0
+DEAL:1:3d::cellid=0_1:3 parentid=0
+DEAL:1:3d::cellid=0_1:4 parentid=0
+DEAL:1:3d::cellid=0_1:5 parentid=0
+DEAL:1:3d::cellid=0_1:6 parentid=0
+DEAL:1:3d::cellid=0_1:7 parentid=0
+DEAL:1:3d::cellid=1_1:0 parentid=1
+DEAL:1:3d::cellid=1_1:1 parentid=1
+DEAL:1:3d::cellid=1_1:2 parentid=1
+DEAL:1:3d::cellid=1_1:3 parentid=1
+DEAL:1:3d::cellid=1_1:4 parentid=1
+DEAL:1:3d::cellid=1_1:5 parentid=1
+DEAL:1:3d::cellid=1_1:6 parentid=1
+DEAL:1:3d::cellid=1_1:7 parentid=1
+DEAL:1:3d::cellid=2_1:0 parentid=2
+DEAL:1:3d::cellid=2_1:1 parentid=2
+DEAL:1:3d::cellid=2_1:2 parentid=2
+DEAL:1:3d::cellid=2_1:3 parentid=2
+DEAL:1:3d::cellid=2_1:4 parentid=2
+DEAL:1:3d::cellid=2_1:5 parentid=2
+DEAL:1:3d::cellid=2_1:6 parentid=2
+DEAL:1:3d::cellid=2_1:7 parentid=2
+DEAL:1:3d::cellid=3_1:0 parentid=3
+DEAL:1:3d::cellid=3_1:1 parentid=3
+DEAL:1:3d::cellid=3_1:2 parentid=3
+DEAL:1:3d::cellid=3_1:3 parentid=3
+DEAL:1:3d::cellid=3_1:4 parentid=3
+DEAL:1:3d::cellid=3_1:5 parentid=3
+DEAL:1:3d::cellid=3_1:6 parentid=3
+DEAL:1:3d::cellid=3_1:7 parentid=3
+DEAL:1:3d::cellid=4_1:0 parentid=4
+DEAL:1:3d::cellid=4_1:1 parentid=4
+DEAL:1:3d::cellid=4_1:2 parentid=4
+DEAL:1:3d::cellid=4_1:3 parentid=4
+DEAL:1:3d::cellid=4_1:4 parentid=4
+DEAL:1:3d::cellid=4_1:5 parentid=4
+DEAL:1:3d::cellid=4_1:6 parentid=4
+DEAL:1:3d::cellid=4_1:7 parentid=4
+DEAL:1:3d::cellid=5_1:0 parentid=5
+DEAL:1:3d::cellid=5_1:1 parentid=5
+DEAL:1:3d::cellid=5_1:2 parentid=5
+DEAL:1:3d::cellid=5_1:3 parentid=5
+DEAL:1:3d::cellid=5_1:4 parentid=5
+DEAL:1:3d::cellid=5_1:5 parentid=5
+DEAL:1:3d::cellid=5_1:6 parentid=5
+DEAL:1:3d::cellid=5_1:7 parentid=5
+DEAL:1:3d::cellid=6_1:0 parentid=6
+DEAL:1:3d::cellid=6_1:1 parentid=6
+DEAL:1:3d::cellid=6_1:2 parentid=6
+DEAL:1:3d::cellid=6_1:3 parentid=6
+DEAL:1:3d::cellid=6_1:4 parentid=6
+DEAL:1:3d::cellid=6_1:5 parentid=6
+DEAL:1:3d::cellid=6_1:6 parentid=6
+DEAL:1:3d::cellid=6_1:7 parentid=6
+DEAL:1:3d::cellid=7_1:0 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:1 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:2 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:3 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:4 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:5 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:6 parentid=7 coarsening
+DEAL:1:3d::cellid=7_1:7 parentid=7 coarsening
+DEAL:1:3d::cells after: 64
+DEAL:1:3d::cellid=7_0: parentid=7
+DEAL:1:3d::cellid=0_1:1 parentid=0
+DEAL:1:3d::cellid=0_1:2 parentid=0
+DEAL:1:3d::cellid=0_1:3 parentid=0
+DEAL:1:3d::cellid=0_1:4 parentid=0
+DEAL:1:3d::cellid=0_1:5 parentid=0
+DEAL:1:3d::cellid=0_1:6 parentid=0
+DEAL:1:3d::cellid=0_1:7 parentid=0
+DEAL:1:3d::cellid=1_1:0 parentid=1
+DEAL:1:3d::cellid=1_1:1 parentid=1
+DEAL:1:3d::cellid=1_1:2 parentid=1
+DEAL:1:3d::cellid=1_1:3 parentid=1
+DEAL:1:3d::cellid=1_1:4 parentid=1
+DEAL:1:3d::cellid=1_1:5 parentid=1
+DEAL:1:3d::cellid=1_1:6 parentid=1
+DEAL:1:3d::cellid=1_1:7 parentid=1
+DEAL:1:3d::cellid=2_1:0 parentid=2
+DEAL:1:3d::cellid=2_1:1 parentid=2
+DEAL:1:3d::cellid=2_1:2 parentid=2
+DEAL:1:3d::cellid=2_1:3 parentid=2
+DEAL:1:3d::cellid=2_1:4 parentid=2
+DEAL:1:3d::cellid=2_1:5 parentid=2
+DEAL:1:3d::cellid=2_1:6 parentid=2
+DEAL:1:3d::cellid=2_1:7 parentid=2
+DEAL:1:3d::cellid=3_1:0 parentid=3
+DEAL:1:3d::cellid=3_1:1 parentid=3
+DEAL:1:3d::cellid=3_1:2 parentid=3
+DEAL:1:3d::cellid=3_1:3 parentid=3
+DEAL:1:3d::cellid=3_1:4 parentid=3
+DEAL:1:3d::cellid=3_1:5 parentid=3
+DEAL:1:3d::cellid=3_1:6 parentid=3
+DEAL:1:3d::cellid=3_1:7 parentid=3
+DEAL:1:3d::cellid=4_1:0 parentid=4
+DEAL:1:3d::cellid=4_1:1 parentid=4
+DEAL:1:3d::cellid=4_1:2 parentid=4
+DEAL:1:3d::cellid=4_1:3 parentid=4
+DEAL:1:3d::cellid=4_1:4 parentid=4
+DEAL:1:3d::cellid=4_1:5 parentid=4
+DEAL:1:3d::cellid=4_1:6 parentid=4
+DEAL:1:3d::cellid=4_1:7 parentid=4
+DEAL:1:3d::cellid=5_1:0 parentid=5
+DEAL:1:3d::cellid=5_1:1 parentid=5
+DEAL:1:3d::cellid=5_1:2 parentid=5
+DEAL:1:3d::cellid=5_1:3 parentid=5
+DEAL:1:3d::cellid=5_1:4 parentid=5
+DEAL:1:3d::cellid=5_1:5 parentid=5
+DEAL:1:3d::cellid=5_1:6 parentid=5
+DEAL:1:3d::cellid=5_1:7 parentid=5
+DEAL:1:3d::cellid=6_1:0 parentid=6
+DEAL:1:3d::cellid=6_1:1 parentid=6
+DEAL:1:3d::cellid=6_1:2 parentid=6
+DEAL:1:3d::cellid=6_1:3 parentid=6
+DEAL:1:3d::cellid=6_1:4 parentid=6
+DEAL:1:3d::cellid=6_1:5 parentid=6
+DEAL:1:3d::cellid=6_1:6 parentid=6
+DEAL:1:3d::cellid=6_1:7 parentid=6
+DEAL:1:3d::cellid=0_2:00 parentid=0
+DEAL:1:3d::cellid=0_2:01 parentid=0
+DEAL:1:3d::cellid=0_2:02 parentid=0
+DEAL:1:3d::cellid=0_2:03 parentid=0
+DEAL:1:3d::cellid=0_2:04 parentid=0
+DEAL:1:3d::cellid=0_2:05 parentid=0
+DEAL:1:3d::cellid=0_2:06 parentid=0
+DEAL:1:3d::cellid=0_2:07 parentid=0
+DEAL:1:3d::OK
+

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.