|
Ublas : |
From: Ralf Denzer (denzer_at_[hidden])
Date: 2007-01-20 08:32:18
Nico Galoppo wrote:
> Check out these threads:
> "size2 not a member of 'boost::numeric::ublas::basic_column_major<>'"
> "boost-sandbox (numeric, lapack bindings) and error"
>
> Basically, you'll need to use an older version of some files.
Thanks for this hint.
I changed line 73 of boost/numeric/bindings/traits/ublas_sparse.hpp
from:
assert (cm.filled1() == layout_type::size1 (cm.size1(), cm.size2()) + 1);
to:
assert (cm.filled1() == layout_type::size_M (cm.size1(), cm.size2()) + 1);
in my local copy. Now
traits::sparse_matrix_traits<ublas::compressed_matrix<double>
>::index1_storage(M);
traits::sparse_matrix_traits<ublas::compressed_matrix<double>
>::index2_storage(M);
traits::sparse_matrix_traits<ublas::compressed_matrix<double>
>::value_storage(M);
traits::sparse_matrix_traits<ublas::compressed_matrix<double> >::size1(M);
traits::sparse_matrix_traits<ublas::compressed_matrix<double> >::size2(M);
traits::sparse_matrix_traits<ublas::compressed_matrix<double>
>::num_nonzeros(M);
seems to work. Somebody changes from storage(M) to value_storage(M).
This is not reflected in the documentation.
Ralf