Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.

Calculate determinant for matrix using MKL

nguyen_k_
Beginner
1,720 Views

Hi, I need to calculate the determinant of a square matrix with MKL(ipp 9.0 - parallel_studio_xe_2016). I searched solution for whole day but still not find the solution.

Which approach should I follow?

Thank you.

0 Kudos
3 Replies
mecej4
Honored Contributor III
1,720 Views

One way is to perform the permuted LU decomposition using ?getrf(). Those routines replace the input matrix A by L and U, with L having a unit diagonal. Therefore, the determinant is simply evaluated as Πi=1..n (aii) after the call to ?getrf() has returned.

0 Kudos
Alexander_K_Intel2
1,720 Views

Hi,

Are you interested in determinant of sparse or dense matrix? If dense than mecej4 is correct - dgetrf is the way to find it. For sparse matrix dss routine return determinant value

Thanks,

Alex

0 Kudos
nguyen_k_
Beginner
1,720 Views

Thank you all, I'll try ?getrf()

0 Kudos
Reply