Boost logo

Ublas :

From: pipehappy (pipehappy_at_[hidden])
Date: 2007-12-28 10:24:27


Hi, all,

I want to use ublas of boost on mac and I failed to compile the
following code in xcode:

#include <iostream>

#include <boost/numeric/ublas/io.hpp>
#include <boost/numeric/ublas/matrix_proxy.hpp>

namespace ublas = boost::numeric::ublas;

int main (int argc, char * const argv[]) {
    // insert code here...
    std::cout << "Hello, World!\n";
        ublas::matrix<double> A(2,2);
    return 0;
}

I add /usr/local/include/boost-1_34_1 in Header search Paths.

The error is like this:

'... A' has initializer but incomplete type

Any one know how I should avoid this problem?

Thank you!