- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I am a new user of MKL, and I'm using pardiso to factor a real nonsymmetric matrix. I've successfully run the sample program for this case, and I'm trying to do exactly the same thing, except my calls to pardiso are from a DLL instead of from an EXE. The first call with phase=11 seems to go without trouble and error=0. Then I call pardiso with phase=22 and I get a crash with an "unhandled exception. . . access violation" message.
Does calling pardiso from a DLL require doing anything differently than from an EXE?
링크가 복사됨
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I modified the pardiso example to read my matrix from a file, and even the EXE crashes at the same place. The call with phase=11 finishes with no trouble, but the call with phase=22 crashes.
The attached zip file is the entire visual studio project. The matrix is being read from uni9.txt.Matrix size is only n=152. I get a feeling it must be something really simple I'm doing wrong, but I just can't find it.
Thanks
Brian
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Before you call Pardiso, please check the matrix data in CSR format. Items in the first row should be given in increasing column order, then the second row, etc.
Row-3 is supposed to contains items 9 to 13. The column indices in ja(9:13) are, however, 78, 79, 82, 83, 4. The last item is out of order.
There are similar errors in Rows 4, 7, etc.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
two my cents - you may use sparse_matrix_checker() routine to check correctness of your input
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
You were both right. The elements were certainly not in the mandatory increasing order. I thought they were because I was making the CSR matrix from a COO matrix using dcsrcoo. But I see now that I had to tell dcsrcoo to put the elements in increasing order with ijob(1)=2, whereas I had ijob(1)=1. This fix cured the crashing problem, so I can continue with implementing pardiso in my application. I am hoping pardiso will be faster than umfpack at factoring a sparse matrix.
At least I was right about it being something simple. :)
Thanks very much for the help.
Cheers,
Brian