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

error occurred in LAPACKE_zposv

x_t_
Beginner
832 Views

Official example code of LAPACKE_zposv is in this webpage.

https://software.intel.com/sites/products/documentation/doclib/mkl_sa/11/mkl_lapack_examples/lapacke_zposv_row.c.htm

(already edited, the original link is not what I meant)

 

When a row-major symmetric complex matrix A is passed into, we get the wrong solution. In code provided, 

 Solution
 (  0.80,  1.62) (  2.52,  0.61)
 (  1.26, -1.78) (  0.01, -1.38)
 (  3.38, -0.29) (  2.42, -0.52)
 (  3.46,  2.92) (  3.77,  1.37)

cannot be obtained. It seems a non-conjugate transposition is needed to perform on matrix A before calling this function. I'm posting this to confirm if this is a bug in latest release version. Any comment is appreciated. Thanks.

0 Kudos
1 Solution
Gennady_F_Intel
Moderator
833 Views

Hello, we have added the fix in the latest MKL version ( MKL v.2017 update 3) which has been released yesterday. Please update, take a look and make sure that we have indeed fixed the problem. Thank you! 

View solution in original post

0 Kudos
8 Replies
mecej4
Honored Contributor III
833 Views

The link that you gave is for the Lapacke_dgesv_row example. Changing "dge" do "zpo" in the  URL takes us to the correct page.

You did not disclose details of MKL version, compiler, OS used. Using the example source code for Lapacke_dgesv_row from Parallel Studio 2016U4, I obtained the correct results. That source code and the source code from the corrected URL are identical except in a small portion of the copyright notice.

Please explain what it is that you think is wrong with the example source code and how it behaves.

0 Kudos
x_t_
Beginner
833 Views

mecej4 wrote:

The link that you gave is for the Lapacke_dgesv_row example. Changing "dge" do "zpo" in the  URL takes us to the correct page.

You did not disclose details of MKL version, compiler, OS used. Using the example source code for Lapacke_dgesv_row from Parallel Studio 2016U4, I obtained the correct results. That source code and the source code from the corrected URL are identical except in a small portion of the copyright notice.

Please explain what it is that you think is wrong with the example source code and how it behaves.

So sorry for the mistake and incompleteness.

The link should be

https://software.intel.com/sites/products/documentation/doclib/mkl_sa/11/mkl_lapack_examples/lapacke_zposv_row.c.htm

I add 

#  pragma comment(lib, "mkl_core")
#  pragma comment(lib, "mkl_sequential")
#  pragma comment(lib, "mkl_intel_lp64")

to link in vs2012 express. 

I get the solution

 ( -0.29,  1.06) (  2.00,  0.76)
 (  0.54, -1.01) ( -0.33, -0.01)
 (  2.35, -0.27) (  1.92,  0.26)
 (  2.67,  1.81) (  3.39,  0.70)

which should be the solution to conjugate(A)*x=b but not Ax=b.

Intel? Parallel Studio XE 2017 (not 2017u1) and vs2012 express( tested on vs2013 ultimate u2 as well)

I get the same result in Ubuntu14.04 with gcc-4.8 and Intel? Parallel Studio XE 2017.

Note that the source code Lapacke_dgesv_row solves a system of linear equations with real values while LAPACKE_zposv solves a system of linear equations with complex values which is the key point here. Could you please help test the code on the page I updated in this comment and let me know if the information I provided is adequate. Thanks a lot.

0 Kudos
mecej4
Honored Contributor III
833 Views

I see. This seems to be a new bug in Parallel Studio/MKL 2017. I tried the 32- and 64-bit versions of MKL 2017U1 on Windows, and both exhibit the bug. The older version that I mentioned earlier (2016U4) works correctly. Someone from the MKL team needs to look at the issue.

P.S.: The problem is also present in MKL 2017 on Linux, 32 and 64 bit.

0 Kudos
Jing_Xu
Employee
833 Views

Thank you for reporting this issue. We have recorded the problem and will update if there are any updates.

0 Kudos
Jing_Xu
Employee
833 Views

Hi all,

The fix to this issue will be available on MKL 2017.3.

0 Kudos
Shueng_Chuan_K_
Beginner
833 Views

I hit into the same issue while using LAPACKE_cposv. (MKL 2017 update 1 on Linux 64-bits)

However, manually calling LAPACKE_cpotrf and LAPACKE_cpotrs yielded the correct result.

 

0 Kudos
Gennady_F_Intel
Moderator
834 Views

Hello, we have added the fix in the latest MKL version ( MKL v.2017 update 3) which has been released yesterday. Please update, take a look and make sure that we have indeed fixed the problem. Thank you! 

0 Kudos
x_t_
Beginner
833 Views

Gennady F. (Intel) wrote:

Hello, we have added the fix in the latest MKL version ( MKL v.2017 update 3) which has been released yesterday. Please update, take a look and make sure that we have indeed fixed the problem. Thank you! 

Hi Gennady,

I've updated my MKL to 2017 update 3 on Windows and it now gives right answer. Someone else might give any feedback on this update on Linux. Thanks!

Th.

0 Kudos
Reply