**2.2.1 RANGE AND PRECISION IN FIXED POINT NUMBERS**

A ﬁxed point representation can be characterized by the range of expressible numbers (that is, the distance between the largest and smallest numbers) and the precision (the distance between two adjacent numbers on a number line.) For the ﬁxed-point decimal example above, using three digits and the decimal point placed two digits from the right, the range is from 0.00 to 9.99 inclusive of the endpoints, denoted as [0.00, 9.99], the precision is .01, and the error is 1/2 of the difference between two “adjoining” numbers, such as 5.01 and 5.02, which have a difference of .01. The error is thus .01/2 = .005. That is, we can represent any number within the range 0.00 to 9.99 to within .005 of its true or precise value.

Notice how range and precision trade off: with the decimal point on the far right, the range is [000, 999] and the precision is 1.0. With the decimal point at the far left, the range is [.000, .999] and the precision is .001. In either case, there are only 103 different decimal “objects,” ranging from 000 to 999 or from .000 to .999, and thus it is possible to represent only 1,000 different items, regardless of how we apportion range and precision.

There is no reason why the range must begin with 0. A 2-digit decimal number can have a range of [00,99] or a range of [-50, +49], or even a range of [-99, +0]. The representation of negative numbers is covered more fully in Section 2.2.6.

Range and precision are important issues in computer architecture because both are ﬁnite in the implementation of the architecture, but are inﬁnite in the real world, and so the user must be aware of the limitations of trying to represent external information in internal form.

## No comments:

## Post a Comment