Library

E.1 INTRODUCTION TO BINARY NUMBERS

A decimal number can be expanded into its constituent components, with each digit being shown with its associated power of ten (the subscript in the Equations (E.1) and (E.2) indicates the base of the number system—10 for decimal, 2 for binary):

432710=(4×103)+(3×102)+(2×101)+(7×100)
(E.1)

The location of a digit in a decimal number therefore serves as a place holder. The further towards the left of a number the digit lies, the larger the power of ten by which it is multiplied, and thus the greater its contribution to the value of the number (or, we could say, the greater its significance in the total value).

A similar expansion can be written for a binary number (that is, when it is represented in base-2), for example:

110102=(1×24)+(1×23)+(0×22)+(1×21)+(0×20)
(E.2)

The binary number 11010 is therefore equivalent to the decimal number 26. Table E.1 lists all five-bit binary numbers and their decimal equivalents.

Table E.1. 5-bit binary numbers and their decimal equivalents.

BinaryDecimalBinaryDecimal
0000001000016
0000111000117
0001021001018
0001131001119
0010041010020
0010151010121
0011061011022
0011171011123
0100081100024
0100191100125
01010101101026
01011111101127
01100121110028
01101131110129
01110141111030
01111151111131

An n-bit binary number can represent values in the range between 0 and 2n–1: