// ---------------------------------------------------------------------
//
-// Copyright (C) 2001 - 2015 by the deal.II authors
+// Copyright (C) 2001 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
deallog << dof_handler.n_dofs() << std::endl;
std::vector<bool> selected_dofs (dof_handler.n_dofs());
- for (unsigned int subdomain=0; subdomain<(1<<dim); ++subdomain)
+ for (types::subdomain_id subdomain=0; subdomain<(1<<dim); ++subdomain)
{
// count number on dofs on
// subdomain. note that they add up to
// ---------------------------------------------------------------------
//
-// Copyright (C) 2001 - 2015 by the deal.II authors
+// Copyright (C) 2001 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
dof_handler.distribute_dofs (fe);
deallog << dof_handler.n_dofs() << std::endl;
- std::vector<unsigned int> subdomain_association (dof_handler.n_dofs());
+ std::vector<types::subdomain_id> subdomain_association (dof_handler.n_dofs());
DoFTools::get_subdomain_association (dof_handler,
subdomain_association);
for (unsigned int subdomain=0; subdomain<(1<<dim); ++subdomain)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2001 - 2015 by the deal.II authors
+// Copyright (C) 2001 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
// subdomain numbers. first output these
// numbers, then also check that this is
// indeed so
- std::vector<unsigned int> subdomain_association (dof_handler.n_dofs());
+ std::vector<types::subdomain_id> subdomain_association (dof_handler.n_dofs());
DoFTools::get_subdomain_association (dof_handler, subdomain_association);
for (unsigned int i=0; i<dof_handler.n_dofs(); ++i)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2001 - 2015 by the deal.II authors
+// Copyright (C) 2001 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
dof_handler.distribute_dofs (fe);
deallog << dof_handler.n_dofs() << std::endl;
- std::vector<unsigned int> subdomain_association (dof_handler.n_dofs());
+ std::vector<types::subdomain_id> subdomain_association (dof_handler.n_dofs());
DoFTools::get_subdomain_association (dof_handler,
subdomain_association);
for (unsigned int subdomain=0; subdomain<(1<<dim); ++subdomain)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2001 - 2015 by the deal.II authors
+// Copyright (C) 2001 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
cell->set_subdomain_id (subdomain);
}
- std::vector<unsigned int> subdomain_association (tria.n_active_cells());
+ std::vector<types::subdomain_id> subdomain_association (tria.n_active_cells());
GridTools::get_subdomain_association (tria,
subdomain_association);
for (unsigned int subdomain=0; subdomain<(1<<dim); ++subdomain)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2001 - 2015 by the deal.II authors
+// Copyright (C) 2001 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
dof_handler.distribute_dofs (fe);
deallog << dof_handler.n_dofs() << std::endl;
- std::vector<unsigned int> subdomain_association (dof_handler.n_dofs());
+ std::vector<types::subdomain_id> subdomain_association (dof_handler.n_dofs());
DoFTools::get_subdomain_association (dof_handler,
subdomain_association);
for (unsigned int subdomain=0; subdomain<(1<<dim); ++subdomain)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
<< tr.begin_active()->subdomain_id()
<< std::endl;
-// std::vector< unsigned int > cell_subd;
-// cell_subd.resize(tr.n_active_cells());
+// std::vector<types::subdomain_id> cell_subd(tr.n_active_cells());
// GridTools::get_subdomain_association(tr, cell_subd);
// for (unsigned int i=0;i<tr.n_active_cells();++i)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
if (myid==0)
{
- std::vector< unsigned int > cell_subd;
- cell_subd.resize(tr.n_active_cells());
+ std::vector<types::subdomain_id> cell_subd(tr.n_active_cells());
GridTools::get_subdomain_association(tr, cell_subd);
for (unsigned int i=0; i<tr.n_active_cells(); ++i)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
if (myid==0)
{
- std::vector< unsigned int > cell_subd;
- cell_subd.resize(tr.n_active_cells());
+ std::vector<types::subdomain_id> cell_subd(tr.n_active_cells());
GridTools::get_subdomain_association(tr, cell_subd);
for (unsigned int i=0; i<tr.n_active_cells(); ++i)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
GridGenerator::hyper_cube(tr);
tr.refine_global(1);
- std::vector< unsigned int > cell_subd;
- cell_subd.resize(tr.n_active_cells());
+ std::vector<types::subdomain_id> cell_subd(tr.n_active_cells());
GridTools::get_subdomain_association(tr, cell_subd);
if (Utilities::MPI::this_mpi_process (MPI_COMM_WORLD) == 0)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
if (myid==0)
{
- std::vector< unsigned int > cell_subd;
- cell_subd.resize(tr.n_active_cells());
+ std::vector<types::subdomain_id> cell_subd(tr.n_active_cells());
GridTools::get_subdomain_association(tr, cell_subd);
for (unsigned int i=0; i<tr.n_active_cells(); ++i)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
// make sure if i is in s on proc j, j is in s on proc i
-void mpi_check(const std::set<unsigned int> &s)
+void mpi_check(const std::set<types::subdomain_id> &s)
{
MPI_Barrier(MPI_COMM_WORLD);
unsigned int tag = 1234;
- for (std::set<unsigned int>::iterator it = s.begin();
+ for (std::set<types::subdomain_id>::iterator it = s.begin();
it != s.end(); ++it)
MPI_Send(NULL, 0, MPI_INT, *it, tag, MPI_COMM_WORLD);
deallog << "* cycle " << ref << std::endl;
deallog << "ghost owners: ";
- std::set<unsigned int> ghost_owners = tr.ghost_owners();
- for (std::set<unsigned int>::iterator it = ghost_owners.begin(); it!=ghost_owners.end(); ++it)
+ std::set<types::subdomain_id> ghost_owners = tr.ghost_owners();
+ for (std::set<types::subdomain_id>::iterator it = ghost_owners.begin(); it!=ghost_owners.end(); ++it)
deallog << *it << " ";
deallog << std::endl;
mpi_check(ghost_owners);
deallog << "level ghost owners: ";
- std::set<unsigned int> level_ghost_owners = tr.level_ghost_owners();
- for (std::set<unsigned int>::iterator it = level_ghost_owners.begin(); it!=level_ghost_owners.end(); ++it)
+ std::set<types::subdomain_id> level_ghost_owners = tr.level_ghost_owners();
+ for (std::set<types::subdomain_id>::iterator it = level_ghost_owners.begin(); it!=level_ghost_owners.end(); ++it)
deallog << *it << " ";
deallog << std::endl;
Assert(is_subset, ExcInternalError());
Vector<float> indicators (tr.n_active_cells());
- std::set<unsigned int> neighbors;
+ std::set<types::subdomain_id> neighbors;
{
for (typename Triangulation<dim>::active_cell_iterator
cell = tr.begin_active(); cell != tr.end(); ++cell)
// ---------------------------------------------------------------------
//
-// Copyright (C) 2009 - 2015 by the deal.II authors
+// Copyright (C) 2009 - 2016 by the deal.II authors
//
// This file is part of the deal.II library.
//
// make sure if i is in s on proc j, j is in s on proc i
-void mpi_check(const std::set<unsigned int> &s)
+void mpi_check(const std::set<types::subdomain_id> &s)
{
MPI_Barrier(MPI_COMM_WORLD);
unsigned int tag = 1234;
- for (std::set<unsigned int>::iterator it = s.begin();
+ for (std::set<types::subdomain_id>::iterator it = s.begin();
it != s.end(); ++it)
MPI_Send(NULL, 0, MPI_INT, *it, tag, MPI_COMM_WORLD);
deallog << "* cycle " << ref << std::endl;
deallog << "ghost owners: ";
- std::set<unsigned int> ghost_owners = tr.ghost_owners();
- for (std::set<unsigned int>::iterator it = ghost_owners.begin(); it!=ghost_owners.end(); ++it)
+ std::set<types::subdomain_id> ghost_owners = tr.ghost_owners();
+ for (std::set<types::subdomain_id>::iterator it = ghost_owners.begin(); it!=ghost_owners.end(); ++it)
deallog << *it << " ";
deallog << std::endl;
mpi_check(ghost_owners);
deallog << "level ghost owners: ";
- std::set<unsigned int> level_ghost_owners = tr.level_ghost_owners();
- for (std::set<unsigned int>::iterator it = level_ghost_owners.begin(); it!=level_ghost_owners.end(); ++it)
+ std::set<types::subdomain_id> level_ghost_owners = tr.level_ghost_owners();
+ for (std::set<types::subdomain_id>::iterator it = level_ghost_owners.begin(); it!=level_ghost_owners.end(); ++it)
deallog << *it << " ";
deallog << std::endl;
Assert(is_subset, ExcInternalError());
Vector<float> indicators (tr.n_active_cells());
- std::set<unsigned int> neighbors;
+ std::set<types::subdomain_id> neighbors;
{
for (typename Triangulation<dim>::active_cell_iterator
cell = tr.begin_active(); cell != tr.end(); ++cell)