Re: [BLAS bindings] help appreciated on using trmv and gbmv
Florent Teichteil <[email protected]>
| Newsgroups | gmane.comp.lib.boost.ublas |
|---|---|
| Message-ID | <-6474603960864336757@unknownmsgid> |
Le 7 oct. 2012 à 21:12, Rutger ter Borg <[email protected]> a écrit : > On 2012-10-07 19:03, Florent Teichteil wrote: >> Hi all, >> >> OK, the previous code works: I get R1==R2. But not if I change the >> storage to row_major. I can understand it, since BLAS requires >> column_major storage, so the bindings API should prevent from using >> row_storage by producing a compilation error, which it doesn't. > > If you use a backend that supports row major (e.g., ATLAS), the bindings will have no problem with matrices in row_major format. If you pass a row_major matrix to an implementation that does not support row_major, the bindings automatically tries to pass it as a transposed column_major matrix. > > In short: whenever possible, row_major is supported by the bindings. > > Cheers, > > Rutger > I'm actually using ATLAS as a backend, so I don't understand why I get the correct result with column_major but not with row_major (for the first test case, since all other tests, either with transposed triangular matrices or with banded matrices, give wrong results anyway). Do you observe the same thing on your computer with the code given in my post? (replace M(i,j) == std::rand with M(i,j) = std::rand , and dM with M, they were copy/paste errors). Cheers Florent _______________________________________________ ublas mailing list [email protected] http://lists.boost.org/mailman/listinfo.cgi/ublas Sent to: [email protected]