From 145c8a8ecef89cd915e59d8e912c523fd4bed8af Mon Sep 17 00:00:00 2001 From: bangerth Date: Wed, 29 Jun 2011 17:17:08 +0000 Subject: [PATCH] Reduce test to the minimum. git-svn-id: https://svn.dealii.org/trunk@23878 0785d39b-7218-0410-832d-ea1e28bc413d --- tests/deal.II/no_flux_06.cc | 54 +++++++++++++++---------------------- 1 file changed, 22 insertions(+), 32 deletions(-) diff --git a/tests/deal.II/no_flux_06.cc b/tests/deal.II/no_flux_06.cc index bef1ad3e2b..a6068635ef 100644 --- a/tests/deal.II/no_flux_06.cc +++ b/tests/deal.II/no_flux_06.cc @@ -2,7 +2,7 @@ // $Id$ // Version: $Name$ // -// Copyright (C) 2007, 2008 by the deal.II authors +// Copyright (C) 2007, 2008, 2011 by the deal.II authors // // This file is subject to QPL and may not be distributed // without copyright and license information. Please refer @@ -12,10 +12,9 @@ //---------------------------------------------------------------------- -// no normal flux constraints on a hyper cube for all faces -// this caused ExcMessage (\"Cycle in constraints detected!\")" -// in 3d with a higher order mapping. -// TH: change mapping to order <4 and it works. +// no normal flux constraints on a hyper cube for all faces this caused +// ExcMessage (\"Cycle in constraints detected!\")" in 3d with a higher order +// mapping. to make things even weirder, mappings of order <4 work. #include "../tests.h" #include @@ -33,42 +32,33 @@ #include + template -void test (const Triangulation& tr, - const FiniteElement& fe) +void test_hyper_cube() { + Triangulation tr; + GridGenerator::hyper_cube(tr); + + FESystem fe (FE_Q(2), dim); + DoFHandler dof(tr); dof.distribute_dofs(fe); - deallog << "FE=" << fe.get_name() - << std::endl; + deallog << "FE=" << fe.get_name() + << std::endl; - std::set boundary_ids; - boundary_ids.insert (0); + std::set boundary_ids; + boundary_ids.insert (0); - ConstraintMatrix cm; - const MappingQ mapping(4); - VectorTools::compute_no_normal_flux_constraints (dof, 0, boundary_ids, cm, mapping); - cm.close(); + ConstraintMatrix cm; + const MappingQ mapping(4); + VectorTools::compute_no_normal_flux_constraints (dof, 0, + boundary_ids, cm, + mapping); + cm.close(); - cm.print (deallog.get_file_stream ()); -} - - -template -void test_hyper_cube() -{ - Triangulation tr; - GridGenerator::hyper_cube(tr); - - tr.refine_global(0); - - for (unsigned int degree=1; degree<4; ++degree) - { - FESystem fe (FE_Q(degree), dim); - test(tr, fe); - } + cm.print (deallog.get_file_stream ()); } -- 2.39.5