]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
FullMatrix::operator *=
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 3 Sep 2001 16:09:56 +0000 (16:09 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 3 Sep 2001 16:09:56 +0000 (16:09 +0000)
git-svn-id: https://svn.dealii.org/trunk@4938 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/lac/include/lac/full_matrix.templates.h

index b2b9b6e6b699b872e0fddf25dd0a02a4be5d0edd..c9d8869047358fb382014f51303fce99c64ababf 100644 (file)
@@ -67,6 +67,21 @@ FullMatrix<number>::all_zero () const
 };
 
 
+
+template <typename number>
+FullMatrix<number> &
+FullMatrix<number>::operator *= (const double factor)
+{
+  number       *p = data();
+  const number *e = data() + n()*m();
+  while (p != e)
+    *p++ *= factor;
+
+  return *this;
+};
+
+
+
 template <typename number>
 template <typename number2>
 void

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.