3 – COMPUTER ARITHMETIC
1985
Publisher Summary
This chapter discusses the ways in which numbers are stored in computers. It also explains how the computer performs arithmetic on real numbers and integers and how round-off errors are generated in computer programs. The 16-bit integer storage scheme uses a 1 in the first bit if the number to be stored is negative and a 0 in the first bit if the number is positive. Negative numbers are stored using the 2's complement method. The Univac uses a 36-bit word to store floating point numbers. The first bit indicates if the number stored is positive or negative with a 1 indicating a negative number and a 0 indicating a positive number. Bits 2 through 9 are used to store a characteristic that is a code for the exponent. The IBM storage scheme uses a 32-bit word, with the first bit indicating whether the number is positive or negative. Bits 1 through 7 contain a characteristic that is a code for the exponent. The decimal number to be stored is expressed in binary exponential form. If the exponent is not a multiple of 4, the binary point is moved to change the exponent to a multiple of 4. The exponent is changed from a base of 2 to a base of 16 by dividing the exponent by 4. Bits 8 through 31 are used for the binary fraction. Negative numbers are stored by using a one in bit 0. The rest of the 32-bit word would be the same as for a positive number.
Keywords:
- Correction
- Cite
- Save
- Machine Reading By IdeaReader
0
References
1
Citations
NaN
KQI