Quantcast
Channel: Intel® Fortran Compiler
Viewing all articles
Browse latest Browse all 3270

Minus zero instead of zero?

$
0
0

Greetings,

I am modifying some Fortran77 code to Fortran90 and I observe a strange phenomenon. The old code was compiled with the 2011 XE composer under Visual Studio 2010, the new one under 2016 XE composer under Visual Studio 2015 Community edition. To check that the code conversion did not introduce any mistake, I am both executable with the same input file. I do get the same output on a number of tests (quite encouraging), with one difference: the new executable writes -0.000 instead of 0.000. It should not be a matter of decimal positions, because the result is the cosine of 90 degrees. The code runs in simple precision: I doubt that could be the culprit. If it is, then it's a matter of F90 vs. F77 or of the new version of the compiler? Any idea?

Thanks is advance.


Viewing all articles
Browse latest Browse all 3270

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>