optimize A * v product for A sparse and row major

This commit is contained in:
Gael Guennebaud
2009-01-19 22:29:28 +00:00
parent 178858f1bd
commit 36c478cd6e
3 changed files with 7 additions and 3 deletions

View File

@@ -54,7 +54,7 @@ template<typename Scalar> void sparse_vector(int rows, int cols)
for (unsigned int i=0; i<zerocoords.size(); ++i)
{
VERIFY_IS_MUCH_SMALLER_THAN( v1.coeff(zerocoords[i]), eps );
VERIFY_RAISES_ASSERT( v1.coeffRef(zerocoords[i]) = 5 );
//VERIFY_RAISES_ASSERT( v1.coeffRef(zerocoords[i]) = 5 );
}
{
VERIFY(int(nonzerocoords.size()) == v1.nonZeros());