Our familiar decimal number system is based on powers of 10.
The number 123 is actually 100 + 20 + 3
or
1 x 10`<sup>`2`</sup>` +
2 x 10`<sup>`1`</sup>` +
3 x 10`<sup>`0`</sup>`.

The binary number system is based on powers of 2.
The number 100101`<sub>`2`</sub>`
(that is, ``100101 base two'')
is
1 x 2`<sup>`5`</sup>` +
0 x 2`<sup>`4`</sup>` +
0 x 2`<sup>`3`</sup>` +
1 x 2`<sup>`2`</sup>` +
0 x 2`<sup>`1`</sup>` +
1 x 2`<sup>`0`</sup>`
or 32 + 4 + 1 or 37.

We usually speak of the individual numerals in a decimal number as digits, while the ``digits'' of a binary number are usually called ``bits.''

Besides decimal and binary, we also occasionally speak of octal
(base 8) and hexadecimal (base 16) numbers.
These work similarly:
The number 45`<sub>`8`</sub>` is
4 x 8`<sup>`1`</sup>` +
5 x 8`<sup>`0`</sup>`
or 32 + 5 or 37.
The number 25`<sub>`16`</sub>` is
2 x 16`<sup>`1`</sup>` +
5 x 16`<sup>`0`</sup>`
or 32 + 5 or 37.
(So
37`<sub>`10`</sub>`,
100101`<sub>`2`</sub>`,
45`<sub>`8`</sub>`,
and
25`<sub>`16`</sub>`
are all the same number.)

Read sequentially: prev next up top

This page by Steve Summit // Copyright 1995, 1996 // mail feedback