
30 May
2006
30 May
'06
9:20 p.m.
Hi, I read through the Ublas documentation but did not see any examples with the iterator1 and iterator2 being used with a matrix. I am having trouble working with them. Does anyone know how to recreate this example using the iterators? http://www.boost.org/libs/numeric/ublas/doc/matrix.htm int main () { using namespace boost::numeric::ublas; matrix<double> m (3, 3); for (unsigned i = 0; i < m.size1 (); ++ i) for (unsigned j = 0; j < m.size2 (); ++ j) m (i, j) = 3 * i + j; std::cout << m << std::endl; } Many thanks, Ed Johnson