]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Things changed in the Trilinos class. To make the test pass, need to copy the matrix...
authorkronbichler <kronbichler@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 5 Mar 2009 00:33:16 +0000 (00:33 +0000)
committerkronbichler <kronbichler@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 5 Mar 2009 00:33:16 +0000 (00:33 +0000)
git-svn-id: https://svn.dealii.org/trunk@18454 0785d39b-7218-0410-832d-ea1e28bc413d

tests/trilinos/block_sparse_matrix_add_01.cc
tests/trilinos/block_sparse_matrix_set_01.cc

index f406c7a55822cedf5e543e5bd440355a9b68d400..7dce1f9003b9e33c5b2ca0c49a7bf9660674f77f 100644 (file)
@@ -58,13 +58,12 @@ void test ()
   m2.reinit(3,2);
   for (unsigned int block_row = 0; block_row<m.n_block_rows(); ++block_row)
     for (unsigned int block_col = 0; block_col<m.n_block_cols(); ++block_col)
-      m.block(block_row, block_col).reinit(m_small);
+      m.block(block_row, block_col).copy_from(m_small);
   m.collect_sizes();
 
-                                  // Set the small matrix to zero and fill
-                                  // the second matrix with the sparsity
-                                  // pattern (but not the values)
-  m_small = 0;
+                                  // fill the second matrix with the
+                                  // sparsity pattern (but not the
+                                  // values)
   for (unsigned int block_row = 0; block_row<m.n_block_rows(); ++block_row)
     for (unsigned int block_col = 0; block_col<m.n_block_cols(); ++block_col)
       m2.block(block_row, block_col).reinit(m_small);
index 7faa4b31403e5adc33d41f9b71752843c276af25..aec1dd67219976ab99b3d44bb8bb73a50e33a248 100644 (file)
@@ -59,13 +59,12 @@ void test ()
   m2.reinit(3,2);
   for (unsigned int block_row = 0; block_row<m.n_block_rows(); ++block_row)
     for (unsigned int block_col = 0; block_col<m.n_block_cols(); ++block_col)
-      m.block(block_row, block_col).reinit(m_small);
+      m.block(block_row, block_col).copy_from(m_small);
   m.collect_sizes();
 
-                                  // Set the small matrix to zero and fill
-                                  // the second matrix with the sparsity
-                                  // pattern (but not the values)
-  m_small = 0;
+                                  // fill the second matrix with the
+                                  // sparsity pattern (but not the
+                                  // values)
   for (unsigned int block_row = 0; block_row<m.n_block_rows(); ++block_row)
     for (unsigned int block_col = 0; block_col<m.n_block_cols(); ++block_col)
       m2.block(block_row, block_col).reinit(m_small);

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.