[UP]


Manual Reference Pages  - fraction (3)

NAME

fraction(3f) - [FORTRAN:INTRINSIC:MODEL_COMPONENTS] Fractional part of the model representation

CONTENTS

Description
Syntax
Arguments
Return Value
Example
Standard
Class

DESCRIPTION

fraction(x) returns the fractional part of the model representation of X.

SYNTAX

y = fraction(x)

ARGUMENTS

X - The type of the argument shall be a REAL.

RETURN VALUE

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)).

EXAMPLE

Sample program:

    program demo_fraction
      real :: x
      x = 178.1387e-4
      print *, fraction(x), x * radix(x)**(-exponent(x))
    end program demo_fraction

STANDARD

[[Fortran 95]] and later

CLASS

[[Elemental procedure|Elemental function]]


fraction (3) March 18, 2019
Generated by manServer 1.08 from 75c5c47f-f473-47bb-aa7e-ccf2f932bb81 using man macros.