FRACTION(X)
returns the fractional part of the model representation of X
.
Fortran 95 and later
Elemental function
Y = FRACTION(X)
X | The type of the argument shall be a REAL . |
The return value is of the same type and kind as the argument. The fractional part of the model representation of X
is returned; it is X * RADIX(X)**(-EXPONENT(X))
.
program test_fraction real :: x x = 178.1387e-4 print *, fraction(x), x * radix(x)**(-exponent(x)) end program test_fraction
© Free Software Foundation
Licensed under the GNU Free Documentation License, Version 1.3.
https://gcc.gnu.org/onlinedocs/gcc-7.2.0/gfortran/FRACTION.html