Data Types and Limits for Math APIs

Following is a description of the data types used in the math bindable APIs. The special values and limits of the data types are also listed.

The semantics and requirements of a high-level language may affect the values of the data types.

For the data type definitions of the ILE CEE APIs across the ILE languages, see Data Type Definitions of ILE CEE APIs.


Integer Data Types

The following table shows the range of values that math bindable APIs can represent and use with the integer data types.

Precise Limit Values of Integer Data Types

Data Type Length (bytes) Range of values
INT2 2 -32 768 through 32 767
INT4 4 -2 147 483 648 through 2 147 483 647
INT8 (See note) 8 -9223372036854775808 through 9223372036854775807
Note: The data type is not currently available. For ILE C, storage for this variable could be defined as char(8).

The operating system represents integers internally in two's complement notation, and the leftmost bit is the sign of the number.


Real Data Types

The following table shows the range of values that math bindable APIs can represent and use with the real data types.

Approximate Limit Values of Real Data Types

Data Type Length (bytes) Approximate Absolute Nonzero Minimum Approximate Absolute Maximum Approximate Precision (Decimal Digits)
FLOAT4 4 1.175494 x 10-38 3.402823 x 1038 7
FLOAT8 8 2.225074 x 10-308 1.797693 x 10308 15

The operating system represents real data type values in IEEE floating-point format.

The following table lists the special values for floating-point operations. The values adhere to the IEEE standard for binary floating-point arithmetic.

Floating-point Special Values

Data Type Description Values
FLOAT4 +INF 0x7F800000
FLOAT4 HUGE 0x7F7FFFFF
FLOAT4 +0 0x00000000
FLOAT4 -0 0x80000000
FLOAT4 -INF 0xFF800000
FLOAT4 masked NaN 0x7FC00000
FLOAT4 unmasked NaN 0x7F800010
FLOAT8 +INF 0x7FF00000 0x00000000
FLOAT8 HUGE 0x7FEFFFFF 0xFFFFFFFF
FLOAT8 +0 0x00000000 0x00000000
FLOAT8 -0 0x80000000 0x00000000
FLOAT8 -INF 0xFFF00000 0x00000000
FLOAT8 masked NaN 0x7FF80000 0x00000000
FLOAT8 unmasked NaN 0x7FF00000 0x00000001

Complex Data Yypes

The following table shows the range of values that the math bindable APIs can represent and can use with complex data types.

Approximate Limit Values of Complex Data Types

Data Type Length (bytes) Approximate Values
COMPLEX8 8 Both real and imaginary parts are _FLOAT4. See Approximate Limit Values of Real Data Types
COMPLEX16 16 Both real and imaginary parts are FLOAT8. See Approximate Limit Values of Real Data Types



[ Back to top | ILE CEE APIs | APIs by category ]