SET_EXPONENT(X,I)

Purpose

Returns the number whose fractional part is the fractional part of the model representation of X, and whose exponent part is I.

Class

Elemental function

Argument type and attributes

X
An INTENT(IN) REAL
I
An INTENT(IN) INTEGER

Result type and attributes

Same as X.

Result value

IBM extension begins

If X = 0 the result is zero.

Otherwise, the result is:

FRACTION(X) * 2.0I 
IBM extension ends

Example

IBM extension begins SET_EXPONENT (10.5, 1) = 0.65625 * 2.01 = 1.3125 IBM extension ends

See Real data model.