From 739301b27cc39b43e396e03fd54d89450227e9ff Mon Sep 17 00:00:00 2001 From: heister Date: Sat, 23 Nov 2013 22:08:21 +0000 Subject: [PATCH] update test and output (and remove the one added that is useless) git-svn-id: https://svn.dealii.org/trunk@31780 0785d39b-7218-0410-832d-ea1e28bc413d --- tests/mpi/crash_05.cc | 9 ++- tests/mpi/crash_05.mpirun=2.output | 23 +++++- tests/mpi/crash_05a.cc | 107 ---------------------------- tests/mpi/crash_05a.mpirun=2.output | 27 ------- 4 files changed, 30 insertions(+), 136 deletions(-) delete mode 100644 tests/mpi/crash_05a.cc delete mode 100644 tests/mpi/crash_05a.mpirun=2.output diff --git a/tests/mpi/crash_05.cc b/tests/mpi/crash_05.cc index dc58e13408..fe9e9cb031 100644 --- a/tests/mpi/crash_05.cc +++ b/tests/mpi/crash_05.cc @@ -68,13 +68,20 @@ void test() triangulation.execute_coarsening_and_refinement(); deallog << "n_cells: " << triangulation.n_global_active_cells() << std::endl; FE_RaviartThomas fe(0); // crashing - //FESystem fe(FE_Q(1), 2); // working + //FESystem fe(FE_Q(2), 1); // working DoFHandler dof_handler(triangulation); dof_handler.distribute_dofs(fe); ConstraintMatrix constraints; DoFTools::make_hanging_node_constraints(dof_handler, constraints); + + IndexSet relevant_set; + DoFTools::extract_locally_relevant_dofs (dof_handler, relevant_set); + deallog << "relevant set:" << std::endl; + relevant_set.print(deallog.get_file_stream()); + deallog << "constraints:" << std::endl; + constraints.print(deallog.get_file_stream()); if (Utilities::MPI::this_mpi_process (MPI_COMM_WORLD) == 0) deallog << "OK" << std::endl; diff --git a/tests/mpi/crash_05.mpirun=2.output b/tests/mpi/crash_05.mpirun=2.output index f445833684..a502e6bb3e 100644 --- a/tests/mpi/crash_05.mpirun=2.output +++ b/tests/mpi/crash_05.mpirun=2.output @@ -1,2 +1,23 @@ -DEAL:2d::OK +DEAL:0::n_cells: 8 +DEAL:0::relevant set: +{[0,22]} +DEAL:0::constraints: + 6 0: 0.500000 + 9 0: 0.500000 + 8 16: 0.500000 + 14 16: 0.500000 + 13 22: 0.500000 + 15 22: 0.500000 +DEAL:0::OK + +DEAL:1::n_cells: 8 +DEAL:1::relevant set: +{[0,3], 5, [7,22]} +DEAL:1::constraints: + 9 0: 0.500000 + 8 16: 0.500000 + 14 16: 0.500000 + 13 22: 0.500000 + 15 22: 0.500000 + diff --git a/tests/mpi/crash_05a.cc b/tests/mpi/crash_05a.cc deleted file mode 100644 index 1f4fad6ecd..0000000000 --- a/tests/mpi/crash_05a.cc +++ /dev/null @@ -1,107 +0,0 @@ -// --------------------------------------------------------------------- -// $Id$ -// -// Copyright (C) 2008 - 2013 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 at -// the top level of the deal.II distribution. -// -// --------------------------------------------------------------------- - - - -// test hits an exception in hanging_node constraints when using RT elements in parallel -// reported by francesco.cattoglio on the mailing list on 2013/11/22 -// simplified version - -#include "../tests.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - -template -void test() -{ - parallel::distributed::Triangulation triangulation(MPI_COMM_WORLD); - GridGenerator::hyper_ball(triangulation); - - if (Utilities::MPI::this_mpi_process(MPI_COMM_WORLD) == 0) - { - typename Triangulation::active_cell_iterator - cell = triangulation.begin_active(); - //cell->set_refine_flag (); - (++cell)->set_refine_flag (); - } - - triangulation.execute_coarsening_and_refinement(); - deallog << "n_cells: " << triangulation.n_global_active_cells() << std::endl; - FE_RaviartThomas fe(0); // crashing - //FESystem fe(FE_Q(1), 2); // working - DoFHandler dof_handler(triangulation); - - dof_handler.distribute_dofs(fe); - - typename DoFHandler<2>::active_cell_iterator cell = - dof_handler.begin_active(); - std::vector local_dof_indices(fe.dofs_per_cell); - - for (; cell != dof_handler.end(); ++cell) - if (!cell->is_artificial()) - { - cell->get_dof_indices(local_dof_indices); - deallog << "dof_indices: "; - for (unsigned int i=0;i::faces_per_cell; ++face) - if (cell->face(face)->has_children()) - { - deallog << "face " << face << ": "; - for (unsigned int child=0; child<2; ++child) - for (unsigned int dof=0; dof!=fe.dofs_per_line; ++dof) - { - types::global_dof_index dofidx = cell->face(face)->child(child)->dof_index(dof, 0); - - deallog << dofidx << " "; - // Assert(dofidx!=numbers::invalid_dof_index, ExcInternalError()); - } - - deallog << std::endl; - } - } - - if (Utilities::MPI::this_mpi_process (MPI_COMM_WORLD) == 0) - deallog << "OK" << std::endl; -} - - -int main(int argc, char *argv[]) -{ - Utilities::MPI::MPI_InitFinalize mpi_initialization(argc, argv, 1); - MPILogInitAll log; - - test<2>(); - -} diff --git a/tests/mpi/crash_05a.mpirun=2.output b/tests/mpi/crash_05a.mpirun=2.output deleted file mode 100644 index 41a6c0247e..0000000000 --- a/tests/mpi/crash_05a.mpirun=2.output +++ /dev/null @@ -1,27 +0,0 @@ - -DEAL:0::n_cells: 8 -DEAL:0::dof_indices: 0 1 2 3 -DEAL:0::face 0: 6 9 -DEAL:0::dof_indices: 16 17 3 18 -DEAL:0::face 0: 8 14 -DEAL:0::dof_indices: 1 19 20 17 -DEAL:0::dof_indices: 21 18 22 19 -DEAL:0::face 2: 13 15 -DEAL:0::dof_indices: 4 5 6 7 -DEAL:0::dof_indices: 5 8 9 10 -DEAL:0::dof_indices: 11 12 7 13 -DEAL:0::dof_indices: 12 14 10 15 -DEAL:0::OK - -DEAL:1::n_cells: 8 -DEAL:1::dof_indices: 0 1 2 3 -DEAL:1::face 0: 6 9 -DEAL:1::dof_indices: 16 17 3 18 -DEAL:1::face 0: 8 14 -DEAL:1::dof_indices: 1 19 20 17 -DEAL:1::dof_indices: 21 18 22 19 -DEAL:1::face 2: 13 15 -DEAL:1::dof_indices: 5 8 9 10 -DEAL:1::dof_indices: 11 12 7 13 -DEAL:1::dof_indices: 12 14 10 15 - -- 2.39.5