From 8f6e06212c6b676993341986468a9d95b672213c Mon Sep 17 00:00:00 2001 From: "denis.davydov" Date: Tue, 25 Mar 2014 21:23:38 +0000 Subject: [PATCH] Do DoFRenumbering::subdomain_wise inside the policy. git-svn-id: https://svn.dealii.org/branches/branch_sharedtria@32695 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/include/deal.II/dofs/dof_handler_policy.h | 1 + deal.II/source/dofs/dof_handler.cc | 4 ---- deal.II/source/dofs/dof_handler_policy.cc | 2 ++ 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/deal.II/include/deal.II/dofs/dof_handler_policy.h b/deal.II/include/deal.II/dofs/dof_handler_policy.h index 102687b0dd..0a9e97bb71 100644 --- a/deal.II/include/deal.II/dofs/dof_handler_policy.h +++ b/deal.II/include/deal.II/dofs/dof_handler_policy.h @@ -23,6 +23,7 @@ #include #include #include +#include #include #include diff --git a/deal.II/source/dofs/dof_handler.cc b/deal.II/source/dofs/dof_handler.cc index 5d1bd08b21..0eeea16276 100644 --- a/deal.II/source/dofs/dof_handler.cc +++ b/deal.II/source/dofs/dof_handler.cc @@ -1174,10 +1174,6 @@ void DoFHandler::distribute_dofs (const FiniteElementdistribute_dofs (*this,number_cache); - //since get_subdomain_association querry n_dofs() - //the need to re-work locally_owned_dofs outside of policy class - if (dynamic_cast*>(&*tria) == 0) - number_cache.locally_owned_dofs = dealii::DoFTools::locally_owned_dofs_with_subdomain(*this,(*this).get_tria().locally_owned_subdomain() ); // initialize the block info object // only if this is a sequential // triangulation. it doesn't work diff --git a/deal.II/source/dofs/dof_handler_policy.cc b/deal.II/source/dofs/dof_handler_policy.cc index bdb1d57b50..1ee0a34a2a 100644 --- a/deal.II/source/dofs/dof_handler_policy.cc +++ b/deal.II/source/dofs/dof_handler_policy.cc @@ -969,6 +969,8 @@ namespace internal NumberCache & number_cache) const { Sequential::distribute_dofs (dof_handler,number_cache); + DoFRenumbering::subdomain_wise (dof_handler); + number_cache.locally_owned_dofs = dealii::DoFTools::locally_owned_dofs_with_subdomain(dof_handler,dof_handler.get_tria().locally_owned_subdomain() ); } template -- 2.39.5