Hello All,
I am trying to use cusolver library and want to find solution of linear system. I saw this example on nvidia docs for the same:
http://docs.nvidia.com/cuda/cusolver/index.html#ormqr-example1
The problem is my matrix is not square and it 838 matrix. I tried to check this code for 43 matrix but I am getting this error:
a.out: main1.cu:112: int main(): Assertion `CUSOLVER_STATUS_SUCCESS == cusolver_status' failed.
which is from this part of the code:
// step 5: compute Q^T*B
cusolver_status= cusolverDnDormqr( cusolverH, CUBLAS_SIDE_LEFT, CUBLAS_OP_T, m, n, n, d_A, lda, d_tau, d_B, ldb, d_work, lwork, devInfo);
cudaStat1 = cudaDeviceSynchronize();
assert(CUSOLVER_STATUS_SUCCESS == cusolver_status);
assert(cudaSuccess == cudaStat1);
I looked into the documentation of this cusolverDnDorqmr function also
Here : http://docs.nvidia.com/cuda/cusolver/index.html#cuds-lt-t-gt-ormqr
And I found that in the example they used nrhs(==1) instead of n as suggested in the documentation. I changed this and got the same error even for 3*3 matrix.
I don’t understand what I am doing wrong. Is there is any problem in the example?? or there is some other way to use library for rectangular matrices?? Please help me guys. This thing is the major part of my project and I really have to submit this soon.