]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Make test work
authorkronbichler <kronbichler@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 7 May 2013 07:01:29 +0000 (07:01 +0000)
committerkronbichler <kronbichler@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 7 May 2013 07:01:29 +0000 (07:01 +0000)
git-svn-id: https://svn.dealii.org/trunk@29470 0785d39b-7218-0410-832d-ea1e28bc413d

tests/lac/bicgstab_large.cc
tests/lac/bicgstab_large/cmp/generic

index 13262582a04d08e6ee86eca1cd1f7acac5c0daf4..665c2f6ae4d93c4b93f0dbb03290268acdc33f35 100644 (file)
@@ -44,8 +44,7 @@ int main()
   M.diag_element(3) = 42;
 
   Vector<double> rhs(4);
-  rhs(0) = rhs(2) = 0;
-  rhs(1) = rhs(3) = 0.0975;
+  rhs = 1;
 
   Vector<double> solution (4);
 
@@ -55,8 +54,7 @@ int main()
     bicgstab.solve (M, solution, rhs, PreconditionIdentity());
   }
 
-  for (unsigned int i=0; i<4; ++i)
-    deallog << solution(i) << std::endl;
+  solution.print(deallog);
 
   Vector<double> res (4);
   M.residual (res, solution, rhs);
@@ -68,16 +66,14 @@ int main()
   SparseMatrix<double> M1 (sparsity_pattern);
   M1.add(1e10,M);
   rhs *= 1e10;
+  solution = 0;
 
   {
     SolverControl control(100, 1.e7);
     SolverBicgstab<> bicgstab(control);
     bicgstab.solve (M1, solution, rhs, PreconditionIdentity());
   }
-
-  for (unsigned int i=0; i<4; ++i)
-    deallog << solution(i) << std::endl;
-
+  solution.print(deallog);
   M1.residual (res, solution, rhs);
   deallog << "residual=" << res.l2_norm()
          << std::endl;
index 6946662a5a751352cbc0dfc7f82c84ff6365ace2..abf5725509f02b7c533d90a13ee7e67c626ba070 100644 (file)
@@ -1,15 +1,9 @@
 
-DEAL:Bicgstab::Starting value 0.1379
-DEAL:Bicgstab::Convergence step 2 value 0
-DEAL::0
-DEAL::0.009750
-DEAL::0
-DEAL::0.002321
+DEAL:Bicgstab::Starting value 2.000
+DEAL:Bicgstab::Convergence step 4 value 0
+DEAL::1.000  0.1000 0.09091 0.02381 
 DEAL::residual=0
-DEAL:Bicgstab::Starting value 2.384e-07
-DEAL:Bicgstab::Convergence step 0 value 2.384e-07
-DEAL::0
-DEAL::0.009750
-DEAL::0
-DEAL::0.002321
-DEAL::residual=2.384e-07
+DEAL:Bicgstab::Starting value 2.000e+10
+DEAL:Bicgstab::Convergence step 4 value 0.001939
+DEAL::1.000  0.1000 0.09091 0.02381 
+DEAL::residual=0.001937

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.