$extrastylesheet
dense_submatrix.C
Go to the documentation of this file.
00001 // The libMesh Finite Element Library.
00002 // Copyright (C) 2002-2014 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
00003 
00004 // This library is free software; you can redistribute it and/or
00005 // modify it under the terms of the GNU Lesser General Public
00006 // License as published by the Free Software Foundation; either
00007 // version 2.1 of the License, or (at your option) any later version.
00008 
00009 // This library is distributed in the hope that it will be useful,
00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012 // Lesser General Public License for more details.
00013 
00014 // You should have received a copy of the GNU Lesser General Public
00015 // License along with this library; if not, write to the Free Software
00016 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017 
00018 
00019 // Local Includes
00020 #include "libmesh/dense_submatrix.h"
00021 
00022 namespace libMesh
00023 {
00024 
00025 
00026 
00027 
00028 // // ------------------------------------------------------------
00029 // // Dense Matrix member functions
00030 template<typename T>
00031 void DenseSubMatrix<T>::left_multiply (const DenseMatrixBase<T>& M2)
00032 {
00033   // (*this) <- M2 * M3
00034   // Where:
00035   // (*this) = (m x n),
00036   // M2      = (m x p),
00037   // M3      = (p x n)
00038 
00039   // M3 is a simply a copy of *this
00040   DenseSubMatrix<T> M3(*this);
00041 
00042   // Call the multiply function in the base class
00043   this->multiply(*this, M2, M3);
00044 }
00045 
00046 
00047 
00048 template<typename T>
00049 void DenseSubMatrix<T>::right_multiply (const DenseMatrixBase<T>& M3)
00050 {
00051   // (*this) <- M2 * M3
00052   // Where:
00053   // (*this) = (m x n),
00054   // M2      = (m x p),
00055   // M3      = (p x n)
00056 
00057   // M2 is simply a copy of *this
00058   DenseSubMatrix<T> M2(*this);
00059 
00060   // Call the multiply function in the base class
00061   this->multiply(*this, M2, M3);
00062 }
00063 
00064 
00065 
00066 //--------------------------------------------------------------
00067 // Explicit instantiations
00068 template class DenseSubMatrix<Real>;
00069 
00070 #ifdef LIBMESH_USE_COMPLEX_NUMBERS
00071 template class DenseSubMatrix<Complex>;
00072 #endif
00073 
00074 } // namespace libMesh