I have another one for you. I'm afraid I can't give you a lot of details, as I am having difficulty reproducing it outside of our program. Maybe you can give me some advice about where to look.

Basically, we are trying to calculater the eigenvalues and eigenvectors for a 135x135 matrix using DSYEVX. The matrix seems fine on input, but during the operation a floating-point invalid operation exception is triggered (we have the FPEs enabled). When I catch that exception and examine the matrix, it has a number of NANs.

Any idea what could cause that to happen? I just need a push in the right direction.


5 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

just wondering if DSYEV works and gives the correct answer?

Which version of MKL do you have? Do NaNs appear at the tridiagonal reduction step, or further?

I've done some more digging, and the more I do, the more confused I get. If I try to reproduce this outside of my program, it all works fine as I said. Interestingly, a different path through my program also works fine.

We have FPEs enabled, so I tried disabling them for the call to DSYEVX. Suddenly the calculation takes WAY longer and when it pops out the number of eigenvalues is lower than expected (only 32). Interestingly, when it pops out the invalid operation bit must still be set, because the very next floating point operation causes an FPE to be thrown.

Now to your questions:

1) I switched the call over to DSYEV and it does work fine. Not sure that is necessarily indicative of anything, however, as it is difficult to reproduce at the best of times, and this could be one of the bad times.

2) We use MKL version 7.2.

3) How can you tell when the NANs appear?

Probably, the issue is due to denormalized numbers appear during the computation. If you're using Intel compilers 8.x, you can fix it to turning on flush-to-zero flag: -ftz.

As to #3, you could call DSYTRD on your matrix to reduce it to tridiagonal form (it's a part of DSYEV/DSYEVX), and examine the result to see if NaNs appear.

Did you register this issue on QuAD?

Leave a Comment

Please sign in to add a comment. Not a member? Join today