From: Guido Kanschat Date: Thu, 9 Dec 1999 22:41:57 +0000 (+0000) Subject: Assert correct matrix dimensions X-Git-Tag: v8.0.0~21325 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7b3a91f3be7a70286e2542e288283cb11466328d;p=dealii.git Assert correct matrix dimensions git-svn-id: https://svn.dealii.org/trunk@2035 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/source/numerics/matrices.cc b/deal.II/deal.II/source/numerics/matrices.cc index 4226088910..d57cf1c2ae 100644 --- a/deal.II/deal.II/source/numerics/matrices.cc +++ b/deal.II/deal.II/source/numerics/matrices.cc @@ -1004,7 +1004,11 @@ MatrixCreator::create_interpolation_matrix(const FiniteElement &high, Assert (high.n_components() == low.n_components(), ExcInvalidFE()); - result.reinit (low.dofs_per_cell, high.dofs_per_cell); + Assert (result.m() == low.dofs_per_cell, + ExcDimensionMismatch(result.m(), low.dofs_per_cell)); + Assert (result.n() == high.dofs_per_cell, + ExcDimensionMismatch(result.n(), high.dofs_per_cell)); + // Initialize FEValues at the support points // of the low element.