From 1172a04ceb04fae29d5094094bdf68c7db8f44f1 Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Mon, 29 Sep 2003 15:16:52 +0000 Subject: [PATCH] Reduce amount of output. git-svn-id: https://svn.dealii.org/trunk@8049 0785d39b-7218-0410-832d-ea1e28bc413d --- tests/bits/mesh_3d_6.cc | 31 ++++++++++++++++++++++++------- tests/bits/mesh_3d_7.cc | 30 +++++++++++++++++++++++------- tests/bits/mesh_3d_8.cc | 4 +--- 3 files changed, 48 insertions(+), 17 deletions(-) diff --git a/tests/bits/mesh_3d_6.cc b/tests/bits/mesh_3d_6.cc index b912f098fa..98cc8898c8 100644 --- a/tests/bits/mesh_3d_6.cc +++ b/tests/bits/mesh_3d_6.cc @@ -41,6 +41,8 @@ void check_this (Triangulation<3> &tria) DoFHandler<3> dof_handler (tria); dof_handler.distribute_dofs (fe); + + unsigned int global_face = 0; // look at all faces, not only // active ones @@ -54,13 +56,28 @@ void check_this (Triangulation<3> &tria) fe_face_values1.reinit (cell, f); fe_face_values2.reinit (cell->neighbor(f), nn); - deallog << "Cell " << cell << ", face " << f - << " << n=" << fe_face_values1.normal_vector(0) - << " << nx=" << fe_face_values2.normal_vector(0) - << std::endl; - - Assert (fe_face_values1.normal_vector(0) == - - fe_face_values2.normal_vector(0), + // in order to reduce + // output file size, only + // write every seventeenth + // normal vector. if the + // normals differ anyway, + // then the assertion below + // will catch this, and if + // we compute _all_ normals + // wrongly, then outputting + // some will be ok, I guess + if (global_face++ % 17 == 0) + deallog << "Cell " << cell << ", face " << f + << " n=" << fe_face_values1.normal_vector(0) + << std::endl; + + // normal vectors should be + // in opposite directions, + // so their sum should be + // close to zero + Assert ((fe_face_values1.normal_vector(0) + + fe_face_values2.normal_vector(0)).square() + < 1e-20, ExcInternalError()); } } diff --git a/tests/bits/mesh_3d_7.cc b/tests/bits/mesh_3d_7.cc index 4e35cf2c1f..9d5433033a 100644 --- a/tests/bits/mesh_3d_7.cc +++ b/tests/bits/mesh_3d_7.cc @@ -43,6 +43,8 @@ void check_this (Triangulation<3> &tria) DoFHandler<3> dof_handler (tria); dof_handler.distribute_dofs (fe); + unsigned int global_datum = 0; + // look at all faces, not only // active ones for (DoFHandler<3>::cell_iterator cell=dof_handler.begin(); @@ -60,16 +62,30 @@ void check_this (Triangulation<3> &tria) for (unsigned int q=0; q &tria) for (Triangulation<3>::cell_iterator cell=tria.begin(); cell != tria.end(); ++cell) { - deallog << " Cell=" << cell << std::endl; - std::set::line_iterator> lines; for (unsigned int l=0; l::lines_per_cell; ++l) { Assert (lines.find (cell->line(l)) == lines.end(), ExcInternalError()); lines.insert (cell->line(l)); - deallog << " line(" << l << ")=" << cell->line(l) << std::endl; } } + deallog << " ok." << std::endl; } -- 2.39.5