]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Update method used to nullify Epetra_MultiVectors 3890/head
authorJean-Paul Pelteret <jppelteret@gmail.com>
Wed, 1 Feb 2017 15:05:42 +0000 (16:05 +0100)
committerJean-Paul Pelteret <jppelteret@gmail.com>
Wed, 1 Feb 2017 15:05:42 +0000 (16:05 +0100)
source/lac/trilinos_sparse_matrix.cc

index 7b598a4dc5486ed43feff460591227ea1b887111..c8eaa7f66bf402efef5c239d5e39f7ee0105a05d 100644 (file)
@@ -2805,27 +2805,37 @@ namespace TrilinosWrappers
         return_op.vmult = [](Range &tril_dst,
                              const Domain &)
         {
-          tril_dst.Scale(0);
+          const int ierr = tril_dst.PutScalar(0.0);
+
+          AssertThrow (ierr == 0, ExcTrilinosError(ierr));
         };
 
         return_op.Tvmult = [](Domain &tril_dst,
                               const Range &)
         {
-          tril_dst.Scale(0);
+          const int ierr = tril_dst.PutScalar(0.0);
+
+          AssertThrow (ierr == 0, ExcTrilinosError(ierr));
         };
 
         return_op.inv_vmult = [](Domain &tril_dst,
                                  const Range &)
         {
           AssertThrow(false, ExcMessage("Cannot compute inverse of null operator"));
-          tril_dst.Scale(0);
+
+          const int ierr = tril_dst.PutScalar(0.0);
+
+          AssertThrow (ierr == 0, ExcTrilinosError(ierr));
         };
 
         return_op.inv_Tvmult = [](Range &tril_dst,
                                   const Domain &)
         {
           AssertThrow(false, ExcMessage("Cannot compute inverse of null operator"));
-          tril_dst.Scale(0);
+
+          const int ierr = tril_dst.PutScalar(0.0);
+
+          AssertThrow (ierr == 0, ExcTrilinosError(ierr));
         };
 
         return return_op;

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.