Boost logo

Ublas :

From: Gunter Winkler (guwi17_at_[hidden])
Date: 2007-09-12 17:48:39


Am Freitag, 7. September 2007 01:13 schrieb pinacle:
> Dear all,
>
> I've been using UBLAS for solving problems like Ax=b, where A is a
> complex dense matrix, and x and b are complex dense vectors. Today, I
> tried to change A to a sparse matrix, but I got compiling errors as:
> Error 10 error C2784: 'matrix_binary_scalar2_traits<E1,const
> T2,boost::numeric::ublas::scalar_divides<E1::value_type,T2>>::result_
>type boost::numeric::ublas::operator /(const
> boost::numeric::ublas::matrix_expression<E> &,const T2 &)' : could
> not deduce template argument for 'const
> boost::numeric::ublas::matrix_expression<E> &' from
> 'std::complex<double>' D:\boost\boost\numeric\ublas\lu.hpp 147
>

I just committed a patch to SVN. I changed

project( ... ) *= 1 / m(i,i);

to

t = 1/m(i,i);
project( ... ) *= t;

Thus the compiler should now be able to deduce the correct parameters.

mfg
Gunter