]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Extend test to negative entries.
authorMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Wed, 22 May 2013 05:35:32 +0000 (05:35 +0000)
committerMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Wed, 22 May 2013 05:35:32 +0000 (05:35 +0000)
git-svn-id: https://svn.dealii.org/trunk@29545 0785d39b-7218-0410-832d-ea1e28bc413d

tests/mpi/parallel_vector_13.cc
tests/mpi/parallel_vector_13/ncpu_10/cmp/generic
tests/mpi/parallel_vector_13/ncpu_4/cmp/generic

index 159a3ea814159ff98052cf9cf89113bd3377679f..b9b5c9c3a58174c7712af60fbaa0149d81f18bd7 100644 (file)
@@ -59,6 +59,15 @@ void test ()
   v(1) = 7;
   v.compress(VectorOperation::insert);
 
+  if (myid == 0)
+    {
+      deallog << myid*2 << ":" << v(myid*2) << std::endl;
+      deallog << myid*2+1 << ":" << v(myid*2+1) << std::endl;
+    }
+
+  v(1) = -7;
+  v.compress(VectorOperation::insert);
+
   if (myid == 0)
     {
       deallog << myid*2 << ":" << v(myid*2) << std::endl;
@@ -67,7 +76,7 @@ void test ()
 
                                 // import ghosts onto all procs
   v.update_ghost_values();
-  Assert (v(1) == 7.0, ExcInternalError());
+  Assert (v(1) == -7.0, ExcInternalError());
 
                                 // check l2 norm
   const double l2_norm = v.l2_norm();
index 10f1691ab245b0cc8a41dcc4d3727c9ae94d6dd7..1ace2d5e74bfca3b24933af9eefd822833c710b8 100644 (file)
@@ -2,5 +2,7 @@
 DEAL:0::numproc=10
 DEAL:0::0:1.000
 DEAL:0::1:7.000
+DEAL:0::0:1.000
+DEAL:0::1:-7.000
 DEAL:0::L2 norm: 103.4
 DEAL:0::OK
index 3054471d301176df8dfe12be5d2462b0efd7cfe5..7b256adb366a838b291941f19b643c02c9efe062 100644 (file)
@@ -2,5 +2,7 @@
 DEAL:0::numproc=4
 DEAL:0::0:1.000
 DEAL:0::1:7.000
+DEAL:0::0:1.000
+DEAL:0::1:-7.000
 DEAL:0::L2 norm: 26.83
 DEAL:0::OK

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.