Boost logo

Ublas :

From: Dima Sorkin (dsorkin_at_[hidden])
Date: 2005-08-09 02:25:32

Quoting aychy :
> sparse_matrix maybe don`t support comlex number very well,I can`t get the
> real or imag part of a complex number in the sparse_matrix, how to solve it?

1) actually m(0,0) returns some proxy object.Here two ways
   to work around it :
        std::complex<double> tmp(m(0,0));
        std::cout <<tmp.real()<< std::endl;

        std::cout <<std::complex<double>(m(0,0)).real()<< std::endl;

2) You program had wrong identation and wrong amount of open and closed
brackets '{' '}'. It could not compile anyway. Attached a repaired one.