Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
Welcome to the Intel Community. If you get an answer you like, please mark it as an Accepted Solution to help others. Thank you!
26758 Discussions

remark #7960: The floating overflow condition was detected while evaluating this operation; the result is an infinity.

S__MPay
Beginner
188 Views

I need to define a very large constant for the cases that I need infinity; but I noticed this warning:

remark #7960: The floating overflow condition was detected while evaluating this operation; the result is an infinity.

Now I wonder if there is a standard way to define +infinity or -infinity?
 

0 Kudos
1 Solution
Steve_Lionel
Black Belt Retired Employee
188 Views

use, intrinsic :: IEEE_ARITHMETIC
...
x = IEEE_VALUE(x,IEEE_POSITIVE_INF)

You will want to compile with /fp:strict in order to support exceptional values.

View solution in original post

1 Reply
Steve_Lionel
Black Belt Retired Employee
189 Views

use, intrinsic :: IEEE_ARITHMETIC
...
x = IEEE_VALUE(x,IEEE_POSITIVE_INF)

You will want to compile with /fp:strict in order to support exceptional values.

View solution in original post

Reply