37 libmesh_assert_equal_to (M1.
m(), M2.
m());
38 libmesh_assert_equal_to (M1.
n(), M3.
n());
39 libmesh_assert_equal_to (M2.
n(), M3.
m());
41 const unsigned int m_s = M2.
m();
42 const unsigned int p_s = M2.
n();
43 const unsigned int n_s = M1.
n();
48 for (
unsigned int k=0; k<p_s; k++)
49 for (
unsigned int j=0; j<n_s; j++)
51 for (
unsigned int i=0; i<m_s; i++)
52 M1.
el(i,j) += M2.
el(i,k) * M3.
el(k,j);
59 const unsigned int jv,
63 libmesh_assert_equal_to (this->_m, rhs.
size());
64 libmesh_assert_equal_to (iv, jv);
69 for (
unsigned int i=0; i<this->m(); i++)
71 rhs.
el(i) -= this->el(i,jv)*val;
76 for (
unsigned int j=0; j<this->n(); j++)
89 std::ios_base::fmtflags os_flags = os.flags();
92 for (
unsigned int i=0; i<this->m(); i++)
94 for (
unsigned int j=0; j<this->n(); j++)
97 << std::setprecision(precision)
98 << this->el(i,j) <<
" ";
112 for (
unsigned int i=0; i<this->m(); i++)
114 for (
unsigned int j=0; j<this->n(); j++)
116 << this->el(i,j) <<
" ";
136 #ifdef LIBMESH_USE_COMPLEX_NUMBERS
void print(std::ostream &os=libMesh::out) const
virtual T el(const unsigned int i, const unsigned int j) const =0
virtual unsigned int size() const =0
void print_scientific(std::ostream &os, unsigned precision=8) const
static void multiply(DenseMatrixBase< T > &M1, const DenseMatrixBase< T > &M2, const DenseMatrixBase< T > &M3)
virtual T el(const unsigned int i) const =0
void condense(const unsigned int i, const unsigned int j, const T val, DenseVectorBase< T > &rhs)