Re: [BLAS bindings] help appreciated on using trmv and gbmv

Rutger ter Borg <[email protected]>
Newsgroups gmane.comp.lib.boost.ublas
Message-ID <[email protected]>
On 2012-10-07 22:50, Florent Teichteil wrote:
>>
>> OK, but for the moment, it would be wonderful if binding functions
>> like trmv and gbmv work properly with dense matrices and triangular
>> and banded adaptors. (Perhaps they work properly, but I'm misusing
>> them, see my attached test files).
>>
>> Cheers
>> Florent
>>

Hey Florent,

not sure why it compiles, but

ublas::some_triangular_adaptor<>( bindings::trans( .. ) )

isn't supposed to work. The bindings meta-machinery isn't understood by 
ublas, but the other way around in many cases it is. Please try 
bindings::lower( bindings::trans( M ) ) to achieve the same.

As for the test cases, after some checking, I think it has to do with 
accumulation of error. The results print to identical values, but 
norm_inf shows differences (due to std::rand() being large). If you 
replace std::rand() with, say, 1.0, all results become identical and 
tests say "CORRECT". I would have to check "What Every Computer 
Scientist Should Know About Floating Point Arithmetic", but I am sure 
the answer can be found in that direction.

Cheers,

Rutger


_______________________________________________
ublas mailing list
[email protected]
http://lists.boost.org/mailman/listinfo.cgi/ublas
Sent to: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.