FORTRAN Reference Manual

Language Elements
FORTRAN Reference Manualβ€”528615-001
2-12
Arithmetic Constants
You can also express a real constant in β€œexponential” form:
where coefficient is a decimal integer or real constant, and exponent is a decimal
integer constant. For example:
The number following the letter E designates a power of 10. For example:
3.2E2 is the same as 3.2 * 10**2
1.23E-3 is the same as 1.23 * 10**-3
The following real constants are invalid:
2,345,125 <-- Number must not include commas
$3.21E5 <-- Number must not include special characters
23E83 <-- Number is too large
Double Precision Constants
A double precision constant is a quadrupleword real constant. Write a double precision
constant like a real constant, but use the letter D to indicate the exponent part of the
constant, as shown in the following syntax:
This shows examples of double precision constants:
Exponential Notation Value
2.5E2 250
-1E-5 -.00001
-.00028E5 -28
Exponential Notation Value
5.834D2 583.4
3122D5 312,200,000
14.D-6 .000014
+
-
coefficient E
+
-
exponent
+
-
coefficient D
+
-
exponent