From: Peter Munch Date: Wed, 2 Mar 2022 11:32:11 +0000 (+0100) Subject: Simplify logic in RepartitioningPolicyTools::FirstChildPolicy X-Git-Tag: v9.4.0-rc1~414^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=15ff33cffae49dac43b2b5a2f88c5cb2e5bb14b5;p=dealii.git Simplify logic in RepartitioningPolicyTools::FirstChildPolicy --- diff --git a/source/distributed/repartitioning_policy_tools.cc b/source/distributed/repartitioning_policy_tools.cc index e4a7e0c8d4..03a5967ec6 100644 --- a/source/distributed/repartitioning_policy_tools.cc +++ b/source/distributed/repartitioning_policy_tools.cc @@ -39,8 +39,7 @@ namespace RepartitioningPolicyTools { is_fine.add_index(cell_id_translator.translate(cell)); - if (cell->level() > 0 && - (cell->index() % GeometryInfo::max_children_per_cell) == 0) + if (cell->level() > 0 && cell->parent()->child(0) == cell) add_indices_recursively_for_first_child_policy(cell->parent(), cell_id_translator, is_fine);