Floating-point data

This chapter describes the built-in types float and double, along with the platform-dependent long double. It explains briefly how a floating-point number system relates to the real number system of mathematics. And it shows how not-quite-numerical values help cope with the floating-point numbers' lack of fidelity with the real numbers. It exposes the bit-encodings of floating-point data types, along with programming techniques for the manipulation of floating-point values as concatenated integers.

The examples "Using long double" on page 190 and "Manipulating numbers without arithmetic" on page 199 showed how you can use library functions to decompose values into their constituents: sign, exponent, and significand. These techniques have the advantage of depending strictly on a number's value rather than its representation.

Floating-point number systems
Numerical specifications of the floating-point types
Encodings of the floating-point types

[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker