I have been trying to figure out a way to extract the L and U factors of a matrix using pardiso. I read somewhere that this is not possible, but I just wanted to check with people here to see if there is a way to do it.
Thanks for the help!
Pardiso is an example of a "black-box" routine. You are trying to peek into the black-box, with some expectations of how it should work, and you seek to do things with Pardiso that it was not intended to do.
Do you have a definite purpose for the L and U factors, supposing that they were obtainable? How do you propose to handle the question of permutation?
I think you can set iparm(5) = 2 so that you can get the permuation vector that was computed in phase 1. I need to use the L and U factors in a different part of my code. So I was hoping that pardiso would be able to return it.
Hi Prapti N.
You can get the permuation vector or diag element i.e using pardiso_getdiag , or phase 332 to get D when A=LDL*.
As mecej4 mentioned, you can't get L and U directly from pardiso, but what kind of operation you hope to do with the L and U?
For example, you can use phase 331 to L*y=b and phase=333 do Ux=y. Where you can specify b and y.
A real symmetric positive definite matrix A(mtype= 2) is factored by Intel MKL PARDISO as A= L*LT
. In this case the solution of the system A*x=bcan be found as sequence of substitutions: L*y=b(forward
substitution, phase=331) and L*x=y(backward substitution, phase=333).
A real nonsymmetric matrix A(mtype= 11) is factored by Intel MKL PARDISO as A= L*U. In this case the
solution of the system A*x=bcan be found by the following sequence: L*y=b(forward substitution, phase
=331) and U*x=y(backward substitution, phase=333).
Solving a system with a real symmetric indefinite matrix A(mtype= -2) is slightly different from the cases
above. Intel MKL PARDISO factors this matrix as A=LDLT , and the solution of the system A*x=bcan be
calculated as the following sequence of substitutions: L*y=b(forward substitution, phase=331), D*v=y
(diagonal substitution, phase=332), and finally L
*x=v(backward substitution, phase=333). Diagonal
substitution makes sense only for symmetric indefinite matrices (mtype= -2, -4, 6). For matrices of
other types a solution can be found as described in the first two examples.