Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Unstable calculation result

hillyuan
Beginner
392 Views
I have encountered a strange problem when doing FEM calculation recently, i.e., different results obtainedeach time withcompletely the same data inputted. Although the difference is rather subtle at initial, but with large number of iteration included in my calculation, it becomes a obvious problem. This problem arose when problem is compilered in Release version with full optimization (my compiler is CVF6.6) and when problem size is bigger than 5500 dofs. If program compilered in Debug version or problem size is small, no problem. Could anybody give me any suggestion on whta kind of this problem is? Is it a software or hardware problem? If a software problem is suggested,is thereany method to find out it?
Thank you very much.
0 Kudos
3 Replies
Steven_L_Intel1
Employee
392 Views
This is almost always due to use of an uninitialized variable.
0 Kudos
hillyuan
Beginner
392 Views
I see. It would be quite an annoying problem because I am notquite understand the details of the program.
Thank you very much.
0 Kudos
Jugoslav_Dujic
Valued Contributor II
392 Views
A few advice how to fix it without deeper understanding:
1) Switch on Project/Settings/Fortran/Optimizations/Variables default to automatic
2) Switch on .../Compilation diagnostics/Uninitialized variables
Rebuild & fix any warnings about uninitialized variables.
This option is not a panacea, though, as it can miss many (mis)usages, especially ones related with arrays. If it does not solve the problem, put up your sleeves and explicitly zero-out all the arrays around (if they're in common blocks, use BLOCK DATAs).
Good luck,
Jugoslav
0 Kudos
Reply