Example 1: Complex variables. These statements are equivalent.
COMPLEX U, V COMPLEX*8 U, V COMPLEX U*8, V*8
Example 2: Initialize complex variables:
COMPLEX U/(1, 9.0)/,V/(4.0, 5)/
A complex constant is a pair of numbers, either integers or reals.
Example 3: Double complex, with initialization:
COMPLEX U*16 / (1.0D0, 9 ) /, V*16 / (4.0, 5.0D0) / COMPLEX*16 X / (1.0D0, 9.0) /, Y / (4.0D0, 5 ) /
A double-complex constant is a pair of numbers, and at least one number of the pair must be double precision.
Example 4: Quadruple complex, with initialization (SPARC only):
COMPLEX U*32 / (1.0Q0, 9 ) /, V*32 / (4.0, 5.0Q0) / COMPLEX*32 X / (1.0Q0, 9.0) /, Y / (4.0Q0, 5 ) /
A quadruple complex constant is a pair of numbers, and at least one number of the pair must be quadruple precision.
Example 5: Complex arrays, all of which are nonstandard (SPARC only):
COMPLEX R*16(5), S(5)*16 COMPLEX U*32(5), V(5)*32 COMPLEX X*8(5), Y(5)*8