This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Pardiso solver and singularity

Tags: None
(comma "," separated)
sullyf
Registered Member
Posts
8
Karma
0
OS

Pardiso solver and singularity

Thu Oct 11, 2012 2:42 pm
Hello,

First of all let me tell you this: support for MKL/Pardiso in eigen is for me one of the top feature of Eigen. This has significantly improved the computation time of my problem.

I facing a minor problem though:

As for now I just give the A matrix to the solver, then call .solve() on the solver multiple time, and even though my A matrix was singular, the whole process just goes forward, and sure enough just using the result of .solve() when A is singular is wrong.


In my situation, what would the fastest way (performance wise) to check if the A matrix is singular (I would then just throw an exception)?

S
Dee33
Registered Member
Posts
54
Karma
0
OS

Re: Pardiso solver and singularity

Thu Oct 11, 2012 2:55 pm
As far as I know, given a matrix, there is no cheap way to detect the singularity of the matrix without computing the decomposition.
Besides, the Pardiso solver will detect it during the factorization.
You can call first .compute() and before calling .solve(), you check the value of .info(). It should be equal to Numericalissue if the matrix is singular.
Hope it helps!!
sullyf
Registered Member
Posts
8
Karma
0
OS

Re: Pardiso solver and singularity

Thu Oct 11, 2012 3:16 pm
Dee33 thanks a lot for the answer. I am having trouble finding which compute() method you are talking about.

As far as the PardisoLU class, there is no compute method for it:

Code: Select all
162:42: error: no matching function for call to ‘Eigen::PardisoLU<Eigen::SparseMatrix<double, 0, int> >::compute()’


Where should I look for it?

S
Dee33
Registered Member
Posts
54
Karma
0
OS

Re: Pardiso solver and singularity

Thu Oct 11, 2012 3:23 pm
Yes this is curious. It should have one. All decomposition classes should have a .compute(matrix)
Try analyzePattern() and factorize() http://eigen.tuxfamily.org/dox-devel/cl ... isoLU.html


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]