]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
update test
authorheister <heister@0785d39b-7218-0410-832d-ea1e28bc413d>
Fri, 31 May 2013 22:34:35 +0000 (22:34 +0000)
committerheister <heister@0785d39b-7218-0410-832d-ea1e28bc413d>
Fri, 31 May 2013 22:34:35 +0000 (22:34 +0000)
git-svn-id: https://svn.dealii.org/trunk@29700 0785d39b-7218-0410-832d-ea1e28bc413d

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

index bd0bfb60cd4e960641d2c7ca51b879e7f709d3d6..8baed67990b0a56a844d315041561bbecb1ee8da 100644 (file)
 
 #include <fstream>
 
+template <class TRIA>
+void check (TRIA & tr)
+{
+  typename TRIA::cell_iterator cell = tr.begin(),
+        endc = tr.end();
+  
+  for (; cell!=endc; ++cell)
+    {
+      deallog << "cell level=" << cell->level() << " index=" << cell->index();
+      if (!cell->has_children())
+       deallog << " subdomain: " << cell->subdomain_id();
+      deallog << std::endl;
+    }
+  
+  deallog << "OK" << std::endl;
+}
+
 
 template<int dim>
 void test()
@@ -57,7 +74,10 @@ void test()
       deallog << "Checksum: "
              << checksum
              << std::endl;
-    }
+
+      check(tr); 
+      }
+
 
 
   if (Utilities::MPI::this_mpi_process (MPI_COMM_WORLD) == 0)
@@ -68,24 +88,10 @@ void test()
 int main(int argc, char *argv[])
 {
   Utilities::MPI::MPI_InitFinalize mpi_initialization(argc, argv, 1);
+  MPILogInitAll log(__FILE__);
 
-  unsigned int myid = Utilities::MPI::this_mpi_process (MPI_COMM_WORLD);
-
-
-  deallog.push(Utilities::int_to_string(myid));
-
-  if (myid == 0)
-    {
-      std::ofstream logfile(output_file_for_mpi("p4est_2d_refine_02").c_str());
-      deallog.attach(logfile);
-      deallog.depth_console(0);
-      deallog.threshold_double(1.e-10);
-
-      deallog.push("2d");
-      test<2>();
-      deallog.pop();
-    }
-  else
-    test<2>();
+  deallog.push("2d");
+  test<2>();
+  deallog.pop();
 
 }
index b6840363c40457cd6ed11fe0c11582cf1590d36a..897bac5bbb6e5d41061f6463e6d32dc92554268b 100644 (file)
@@ -2,4 +2,83 @@
 DEAL:0:2d::hyper_cube
 DEAL:0:2d::#cells = 7
 DEAL:0:2d::Checksum: 426967244
+DEAL:0:2d::cell level=0 index=0 subdomain: 4294967294
 DEAL:0:2d::OK
+DEAL:0:2d::OK
+
+DEAL:1:2d::Checksum: 0
+DEAL:1:2d::cell level=0 index=0
+DEAL:1:2d::cell level=1 index=0
+DEAL:1:2d::cell level=1 index=1 subdomain: 7
+DEAL:1:2d::cell level=1 index=2 subdomain: 8
+DEAL:1:2d::cell level=1 index=3 subdomain: 9
+DEAL:1:2d::cell level=2 index=0 subdomain: 1
+DEAL:1:2d::cell level=2 index=1 subdomain: 1
+DEAL:1:2d::cell level=2 index=2 subdomain: 1
+DEAL:1:2d::cell level=2 index=3 subdomain: 1
+DEAL:1:2d::OK
+
+
+DEAL:2:2d::Checksum: 0
+DEAL:2:2d::cell level=0 index=0 subdomain: 4294967294
+DEAL:2:2d::OK
+
+
+DEAL:3:2d::Checksum: 0
+DEAL:3:2d::cell level=0 index=0 subdomain: 4294967294
+DEAL:3:2d::OK
+
+
+DEAL:4:2d::Checksum: 0
+DEAL:4:2d::cell level=0 index=0 subdomain: 4294967294
+DEAL:4:2d::OK
+
+
+DEAL:5:2d::Checksum: 0
+DEAL:5:2d::cell level=0 index=0 subdomain: 4294967294
+DEAL:5:2d::OK
+
+
+DEAL:6:2d::Checksum: 0
+DEAL:6:2d::cell level=0 index=0 subdomain: 4294967294
+DEAL:6:2d::OK
+
+
+DEAL:7:2d::Checksum: 0
+DEAL:7:2d::cell level=0 index=0
+DEAL:7:2d::cell level=1 index=0
+DEAL:7:2d::cell level=1 index=1 subdomain: 7
+DEAL:7:2d::cell level=1 index=2 subdomain: 8
+DEAL:7:2d::cell level=1 index=3 subdomain: 9
+DEAL:7:2d::cell level=2 index=0 subdomain: 4294967294
+DEAL:7:2d::cell level=2 index=1 subdomain: 1
+DEAL:7:2d::cell level=2 index=2 subdomain: 4294967294
+DEAL:7:2d::cell level=2 index=3 subdomain: 1
+DEAL:7:2d::OK
+
+
+DEAL:8:2d::Checksum: 0
+DEAL:8:2d::cell level=0 index=0
+DEAL:8:2d::cell level=1 index=0
+DEAL:8:2d::cell level=1 index=1 subdomain: 7
+DEAL:8:2d::cell level=1 index=2 subdomain: 8
+DEAL:8:2d::cell level=1 index=3 subdomain: 9
+DEAL:8:2d::cell level=2 index=0 subdomain: 4294967294
+DEAL:8:2d::cell level=2 index=1 subdomain: 4294967294
+DEAL:8:2d::cell level=2 index=2 subdomain: 1
+DEAL:8:2d::cell level=2 index=3 subdomain: 1
+DEAL:8:2d::OK
+
+
+DEAL:9:2d::Checksum: 0
+DEAL:9:2d::cell level=0 index=0
+DEAL:9:2d::cell level=1 index=0
+DEAL:9:2d::cell level=1 index=1 subdomain: 7
+DEAL:9:2d::cell level=1 index=2 subdomain: 8
+DEAL:9:2d::cell level=1 index=3 subdomain: 9
+DEAL:9:2d::cell level=2 index=0 subdomain: 4294967294
+DEAL:9:2d::cell level=2 index=1 subdomain: 4294967294
+DEAL:9:2d::cell level=2 index=2 subdomain: 4294967294
+DEAL:9:2d::cell level=2 index=3 subdomain: 1
+DEAL:9:2d::OK
+
index b6840363c40457cd6ed11fe0c11582cf1590d36a..8badce8cc9dcbca0a8efcf24c38d4ce68c51bb99 100644 (file)
@@ -2,4 +2,45 @@
 DEAL:0:2d::hyper_cube
 DEAL:0:2d::#cells = 7
 DEAL:0:2d::Checksum: 426967244
+DEAL:0:2d::cell level=0 index=0 subdomain: 4294967294
 DEAL:0:2d::OK
+DEAL:0:2d::OK
+
+DEAL:1:2d::Checksum: 0
+DEAL:1:2d::cell level=0 index=0
+DEAL:1:2d::cell level=1 index=0
+DEAL:1:2d::cell level=1 index=1 subdomain: 2
+DEAL:1:2d::cell level=1 index=2 subdomain: 3
+DEAL:1:2d::cell level=1 index=3 subdomain: 3
+DEAL:1:2d::cell level=2 index=0 subdomain: 1
+DEAL:1:2d::cell level=2 index=1 subdomain: 1
+DEAL:1:2d::cell level=2 index=2 subdomain: 1
+DEAL:1:2d::cell level=2 index=3 subdomain: 1
+DEAL:1:2d::OK
+
+
+DEAL:2:2d::Checksum: 0
+DEAL:2:2d::cell level=0 index=0
+DEAL:2:2d::cell level=1 index=0
+DEAL:2:2d::cell level=1 index=1 subdomain: 2
+DEAL:2:2d::cell level=1 index=2 subdomain: 3
+DEAL:2:2d::cell level=1 index=3 subdomain: 3
+DEAL:2:2d::cell level=2 index=0 subdomain: 4294967294
+DEAL:2:2d::cell level=2 index=1 subdomain: 1
+DEAL:2:2d::cell level=2 index=2 subdomain: 4294967294
+DEAL:2:2d::cell level=2 index=3 subdomain: 1
+DEAL:2:2d::OK
+
+
+DEAL:3:2d::Checksum: 0
+DEAL:3:2d::cell level=0 index=0
+DEAL:3:2d::cell level=1 index=0
+DEAL:3:2d::cell level=1 index=1 subdomain: 2
+DEAL:3:2d::cell level=1 index=2 subdomain: 3
+DEAL:3:2d::cell level=1 index=3 subdomain: 3
+DEAL:3:2d::cell level=2 index=0 subdomain: 4294967294
+DEAL:3:2d::cell level=2 index=1 subdomain: 4294967294
+DEAL:3:2d::cell level=2 index=2 subdomain: 1
+DEAL:3:2d::cell level=2 index=3 subdomain: 1
+DEAL:3:2d::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.