This is the mail archive of the gsl-discuss@sourceware.org mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [row/column majority] gslclapack


Using RowMajor instead of ColMajor is like matrix transpose operation.

so A*B = (B^T * A^T)^T.
That is why the answers are the same. 
Why the switch is needed? I do not know, but can speculate...
I suspect it is because fortran 77 can not allocate memory,
and to facilitate memory management, Col/Row Major and transpose might
be different operations if the size of matrix is smaller than the
allocated memory.

Lazar

> Can someone explain why we have CblasRowMajor and CblasColMajor?
> 
> I just did a little test to convince myself, and indeed (with
> -lgslcblas) the two following calls seem to produce the same answers
> in the variable c.
> 
>     cblas_dgemm(CblasRowMajor, T2, T1, ...  a, b, c)
>     cblas_dgemm(CblasColMajor, T2, T1, ...  b, a, c)
> 
> T1 and T2 are each one of CblasNoTrans and CblasTrans.
> 
> Did I make a mistake?  Are there other BLAS functions for which you
> need to specify the data format for things to work?
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]