Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29246 Discussions

routine to do inversion of ill-conditioned matrix

phung1nguyen
Beginner
1,407 Views
I am solving a dynamics problem where the mass matrix is ill-conditioned. Its elements are represented in 64-bit IEEE floating point format, and its condition number is 10^11, based on Matlab calculation. Although the matrix is invertible, the dynamic response that I got is not what I expected. Does anybody know any routines that can do matrix inversion and eigenvalue calculation accurately enough for ill-conditioned matrices (regardless of whether it is free or not)?
0 Kudos
5 Replies
Intel_C_Intel
Employee
1,407 Views
In cases when Gaussian elimination or LU decomposition fail to give satisfactory results (your set of equation may be numerically close to singular) the simplest thing is to use the Singular Value Decomposition (SVD). You can eliminate the problem or at least diagnose it. Try to look for SVD (as far as I can remember a nice explanation and routine is in the Numerical Recipes (Fortran 77/90/C++). Other options include some regularized algorithms.

A.
0 Kudos
Jugoslav_Dujic
Valued Contributor II
1,407 Views
One generalized inverse routine can be found here. Singular Value Decomposition and far more can be downloaded from Lapack at Netlib. Compaq CXML library distributed with CVF contains Lapack so you should find optimized Lapack routines there (but I did not check it out).

Jugoslav
0 Kudos
Jugoslav_Dujic
Valued Contributor II
1,407 Views
One generalized inverse routine can be found here. Singular Value Decomposition and far more can be downloaded from Lapack at Netlib. Compaq CXML library distributed with CVF contains Lapack so you should find optimized Lapack routines there (but I did not check it out).

Jugoslav
0 Kudos
phung1nguyen
Beginner
1,407 Views
Thanks for your prompt reply. I could not get to this site to send you my reply because Intel has shut it down for maintenance till yesterday. Unfortunately I cannot remove the small eigenvalues of the (mass) matrix because I don't know its effect on the solution of my motion equation. I am trying to convert my routine into quadruple precision, do the inversion, convert output to double precision, hoping I can get better accuracy.
0 Kudos
Intel_C_Intel
Employee
1,407 Views
Unfortunately:-) you will have to (modify your set). As you see yourself some of the values do more harm than good. Naturally, everything depends on the physics and your problem (if it is a sort of inverse analisys you will always have ill-conditioned matrices). You may give a try some iterative regularization algorithms, POD, or something else but each of them modify somehow the original set of equations. Anyway, Jugoslav directed you to the places where you can get the tools you will need.

A.
0 Kudos
Reply