[Trilinos-Users] SerialDenseSolver not working for rectangular matrices?
Holger Brandsmeier
holger.brandsmeier at sam.math.ethz.ch
Tue Jun 12 10:18:55 MDT 2012
Dear list,
it seems that SerialDenseSolver is supposed to work also for
rectangular matrices "The Teuchos::SerialDenseSolver class is intended
to provide full-featured support for solving linear problems for
general dense rectangular (or square) matrices." (doxygen). I do not
see that in the code though.
In the routine SerialDenseSolver::setVectors, there is a test
// Check that these new vectors are consistent.
TEUCHOS_TEST_FOR_EXCEPTION(B->numRows()!=X->numRows() ||
B->numCols() != X->numCols(), std::invalid_argument,
"SerialDenseSolver<T>::setVectors: X and B are not the same size!");
this is not the proper test for rectangular matrices, the right hand
side and the solution vector should not be of the same size. Or how
should I interpret a rectangular system where X and B are of the same
size?
But even if I disable that test, it does not work. The funny thing is,
that the solution vector is reshaped to the size of the right hand
side, why?
-Holger
More information about the Trilinos-Users
mailing list