]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
GrowingVectorMemory now uses a global pool, so we don't need a mutable object any...
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 26 Feb 2008 14:40:52 +0000 (14:40 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 26 Feb 2008 14:40:52 +0000 (14:40 +0000)
git-svn-id: https://svn.dealii.org/trunk@15780 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/examples/step-21/step-21.cc

index a5d093599bc6e0d85563c9ef5146f250fdec3c7a..c6745dc69ccf00667f9b3589da2f09f39f55d9bd 100644 (file)
@@ -512,8 +512,6 @@ class InverseMatrix : public Subscriptor
 
   private:
     const SmartPointer<const Matrix> matrix;
-
-    mutable GrowingVectorMemory<> vector_memory;    
 };
 
 
@@ -529,8 +527,9 @@ template <class Matrix>
 void InverseMatrix<Matrix>::vmult (Vector<double>       &dst,
                                    const Vector<double> &src) const
 {
-  SolverControl solver_control (src.size(), 1e-8*src.l2_norm());
-  SolverCG<> cg (solver_control, vector_memory);
+  SolverControl         solver_control (src.size(), 1e-8*src.l2_norm());
+  GrowingVectorMemory<> vector_memory;    
+  SolverCG<>            cg (solver_control, vector_memory);
 
   dst = 0;
   

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.