#include #include int main () { using boost::numeric::ublas::vector; // vector from boost vector v(3); for (unsigned i = 0; i < v.size (); i++) v(i) = i; // boost vector element is v(i) std::cout << v << "\n"; }