]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fix issues pointed out by @slazav.
authorDavid Wells <wellsd2@rpi.edu>
Thu, 17 Dec 2015 20:51:27 +0000 (15:51 -0500)
committerDavid Wells <wellsd2@rpi.edu>
Fri, 18 Dec 2015 16:49:42 +0000 (11:49 -0500)
This commit fixes several compilation issues with
ShiftedMatrixGeneralized. This bug has been present since
cd072f5b77 (June 2001), so it looks like this class has never worked as
advertised.

include/deal.II/lac/shifted_matrix.h

index 2bb727396ff2c8fd18879804e9b791649740f660..6cc0c6918362a2e6675528b0b60826fd04efa4d8 100644 (file)
@@ -147,7 +147,7 @@ private:
   /**
    * Auxiliary vector.
    */
-  VectorType aux;
+  mutable VectorType aux;
 
   /**
    * Shift parameter.
@@ -249,7 +249,7 @@ ShiftedMatrixGeneralized<MatrixType, MatrixType2, VectorType>::vmult
   if (sigma != 0.)
     {
       aux.reinit(dst);
-      M.vmult(aux, src);
+      M->vmult(aux, src);
       dst.add(sigma, aux);
     }
 }
@@ -266,7 +266,7 @@ ShiftedMatrixGeneralized<MatrixType, MatrixType2, VectorType>::residual
   if (sigma != 0.)
     {
       aux.reinit(dst);
-      M.vmult(aux, src);
+      M->vmult(aux, src);
       dst.add(sigma, aux);
     }
   dst.sadd(-1.,1.,rhs);

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.