NUMBER SYSTEMS
William Stallings
The Decimal System ......................................................................................................2
The Binary System.........................................................................................................3
Converting between Binary and Decimal ......................................................................3
Integers...............................................................................................................4
Fractions.............................................................................................................5
Hexadecimal Notation....................................................................................................6
This document available at WilliamStallings.com/StudentSupport.html
Copyright 2000 William Stallings
-1-
The Decimal System
In everyday life we use a system based on decimal digits (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) to represent
numbers and refer to the system as the decimal system. Consider what the number 83 means. It
means eight tens plus three:
83 = (8 × 10) + 3
The number 4728 means four thousands, seven hundreds, two tens, plus eight:
4728 = (4 × 1000) + (7 × 100) + (2 × 10) + 8
The decimal system is said to have a base, or radix, of 10. This means that each digit in the
number is multiplied by 10 raised to a power corresponding to that digit’s position:
83 = (8 × 101 ) + (3 × 100 )
4728 = (4 × 103 ) + (7 × 102 ) + (2 × 101 ) + (8 × 100 )
The same principle holds for decimal fractions but negative powers of 10 are used. Thus,
the decimal fraction 0.256 stands for 2 tenths plus 5 hundredths plus 6 thousandths:
0.256 = (2 × 10–1) + (5 × 10–2) + (6 × 10–3)
A number with both an integer and fractional part has digits raised to both positive and
negative powers of 10:
472. 256 = (4 × 102 ) + (7 × 101 ) + (2 × 100 ) + (2 × 10–1) + (5 × 10–2) + (6 × 10–3)
In general, for the decimal...