필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

BLAS1 ddot function for matrix matrix multiplication...

조회 수: 1 (최근 30일)
Nina
Nina 2012년 10월 10일
I need to do the Cij = Aiq * Bqj, where A and B are matrices that are stored column wise and that do not necessarily have the same dimensions. I need to use ddot from BLAS1 to do this and this is what I have so far:
for(j=0;j<m;j++)
for (i = 0 ; i < n ; i++){
l_C[i+j*n]= ddot(n,&(l_A[i]),n,&(l_B[j*k]),1);
}
This is in C language by the way where A is n by k matrix, B is a k by m matrix and they should result in a matrix C of dimensions n by m. Again A and B are set up this way to be stored column wise:
for (j = 0; j < k; j++)
for (i = 0; i < n; i++){
A[i+j*n] = sqrt(2)/double(n);
}
And B is set up in a similar way.
Let me know if my logic is wrong because i do not get the right output.
Thanks everyone and let me know if you need more details.

답변 (0개)

이 질문은 마감되었습니다.

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by