What dose d-8 mean in Fortran?

  • Context: Fortran 
  • Thread starter Thread starter nnnnn
  • Start date Start date
  • Tags Tags
    Fortran Mean
Click For Summary
SUMMARY

The term "d-8" in Fortran signifies a double precision representation of a floating-point number. Specifically, "2.0d-8" is equivalent to "2.0e-8," but it is stored as a double precision real number, which offers greater accuracy than single precision. In FORTRAN 77, this would be declared using REAL*16 instead of REAL*8. This distinction is crucial for developers working with numerical computations requiring high precision.

PREREQUISITES
  • Understanding of Fortran programming language
  • Knowledge of floating-point number representation
  • Familiarity with precision types in programming (single vs. double precision)
  • Basic concepts of scientific notation in programming
NEXT STEPS
  • Research Fortran data types and their precision levels
  • Learn about floating-point arithmetic and its implications in numerical computing
  • Explore the differences between REAL*8 and REAL*16 in Fortran
  • Study best practices for handling precision in scientific computations
USEFUL FOR

This discussion is beneficial for Fortran developers, numerical analysts, and anyone involved in scientific computing who needs to understand precision in floating-point representations.

nnnnn
Messages
5
Reaction score
0
What dose "d-8" mean in Fortran?

Dear friends;
What dose "d-8" mean in Fortran?
Thanks
 
Technology news on Phys.org


2.0d-8 is the same value as 2.0e-8 except that it's stored as a double precision real number instead of single precision. In FORTRAN 77 it would be declared as REAL*16 instead of REAL*8.
 


Much thanks to jtbell ;

you mean 2.0d-8 is equal to 2*10^ (-8) ?
 


Yes.
 

Similar threads

  • · Replies 25 ·
Replies
25
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 20 ·
Replies
20
Views
4K
  • · Replies 12 ·
Replies
12
Views
2K
  • · Replies 37 ·
2
Replies
37
Views
5K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 75 ·
3
Replies
75
Views
18K
  • · Replies 17 ·
Replies
17
Views
6K
  • · Replies 9 ·
Replies
9
Views
4K