Software Archive
Read-only legacy content
17061 Discussions

Double Precision

Intel_C_Intel
Employee
463 Views
Hi all:
Is there any way to compile with global double precision, i.e., setting all constants,variables and intrinsics in double precision a la UNIX -r8 ?
Thanks,
Raul
0 Kudos
3 Replies
Steven_L_Intel1
Employee
463 Views
Yes. /real_size:64, though I think -r8 is also accepted. In DevStudio, its a setting under Fortran..Floating Point. Note that if you explicitly declare a variable REAL*4, it stays REAL*4. If you say just REAL, then it will get doubled.

Steve
0 Kudos
Intel_C_Intel
Employee
463 Views
Steve: I added your compile option (it is not available as a DevStudio Fortran/Floating Point choice, and I can't find it anywhere in the documentation), ran a CFD code, and got slightly different results, so I take it that double precision "took". Much obliged by your timely help. Raul
0 Kudos
wkramer
Beginner
463 Views
From DevStudio go to Project Settings|Fortran|Fortran data. You can define a default real and integer kind there.

Walter Kramer
0 Kudos
Reply