Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.

Eigenvalues for singular matrices

perholm
Beginner
343 Views
Hi,
I am using IPP 5.2 and ippmEigenValuesVectorsSym_m_32f to calculate the eigenvectors of a symmetric matrix. In my case the matrix can sometimes be singular, and that's fine, but then the function returns ippStsSingularErr and no eigenvectors are calculated. I find this quite strange since e.g Matlab has no problem calculating eigenvectors for singular matrices.

Q1) Does anyone have any workaround for this?
Q2) Intel, do you plan on or maby already have, solved this in newer versions?

/Per

0 Kudos
2 Replies
Ying_H_Intel
Employee
343 Views
Quoting - perholm
Hi,
I am using IPP 5.2 and ippmEigenValuesVectorsSym_m_32f to calculate the eigenvectors of a symmetric matrix. In my case the matrix can sometimes be singular, and that's fine, but then the function returns ippStsSingularErr and no eigenvectors are calculated. I find this quite strange since e.g Matlab has no problem calculating eigenvectors for singular matrices.

Q1) Does anyone have any workaround for this?
Q2) Intel, do you plan on or maby already have, solved this in newer versions?

/Per


Hi Per,

IPP's ippmEigenValuesVectorsSym function uses QR algorithm for solving eigenvalue problem.
the algorithm are numerical unstable for badly conditioned matrix (det is close to 0). That's is why there are error condition (ippStsSingularErr)for the function. When Abs(det) < ( 2.2204460492503131e-016, the function willreturn "ippStsSingularErr". As i knew, we haven't planed to change the algorithm at least in recently version, IPP 6.x.

I guess, Matlab use different algorithm for calculating this.

For workaround, you may tryother function like ippsSVDSort, which is in ippsman.pdf and can do singular value decomposition.
or you maycheck IPP's sister library - math kernal library (MKL, http://software.intel.com/en-us/intel-mkl/, which provide much more functions for Eigenvalue Problem.

Regards,
Ying
0 Kudos
Michael_C_Intel4
Employee
343 Views
Actually, QR algorithm is quite stable, at least, it's known as most stable among other algorithms. You should try MKL, there's no problem for MKL to solve eigenproblem with the singular matrix.

You may look at the example of the MKL eigensolver usage at http://software.intel.com/sites/products/documentation/hpc/mkl/lapack/mkl_lapack_examples/ssyev_ex.c.htm.

Michael.
0 Kudos
Reply