2.2.2 Positive integers: binary numbers
Just as a denary number system uses ten different digits (0, 1, 2, 3, … 9), a binary number system uses two (0, 1).
Once again the idea of positional notation is important. You have just seen that the weightings which apply to the digits in a denary number are the exponents of ten. With binary numbers, where only two digits are used, the weightings applied to the digits are exponents of two.
The rightmost bit is given the weighting of 2°, which is 1. The next bit to the left is given a weighting of 2^{1}, which is 2, and so on.
Thus the 4bit binary number 1101 represents:
The leftmost bit is called the mostsignificant bit (m.s.b.) and the rightmost bit is called the leastsignificant bit (l.s.b.)
Computers are designed to work with binary numbers, but denary numbers suit most people better. Humans therefore need to interpret the 4bit binary number 1101 as follows:
(1 × 2^{3}) + (1 × 2^{2}) + (0 × 2^{1}) + (1 × 2^{0})
which is 8 + 4 + 0+ 1 = 13 in denary.
Activity 3 (Self assessment)
What does the 4bit binary number 1010 represent? To what denary number is it equal? What is its mostsignificant bit?
Answer
1010 represents
It is equal to 8 + 0 + 2 + 0 = 10 in denary and its mostsignificant bit is 1.
Exactly the same principles can be applied to larger binary numbers. For example, in an 8bit word the mostsignificant bit has a weighting of 2^{7}, which is 128. So 10110110 represents:
and equals 128 + 0 + 32 + 16 + 0+ 4 + 2 + 0, which is 182 in denary.
It is often convenient to number the bits in a binary word and to refer to the bits as ‘bit 5’ or ‘bit 2’. And the most convenient way of numbering the bits is to use the exponents in the weightings. So the bits are usually numbered as follows (for an 8bit word):
7  6  5  4  3  2  1  0  bit number 
2^{7}  2^{6}  2^{5}  2^{4}  2^{3}  2^{2}  2^{1}  2^{0}  weighting 
This scheme means that the leastsignificant bit is bit 0 and the mostsignificant bit is bit 7.
Just as a space between groups of three digits in large numbers (e.g. 625 127) can make them easier to read, so spaces between groups of four bits can make binary numbers easier to read. I shall use spaces in this way. So I shall write, for example, 1001 1110 rather than 10011110. Note that the space is purely for convenience in reading the number; it does not affect the value of the number in any way, nor the way the computer handles it.
Activity 4 (Self assessment)

To what denary number is the binary number 1100 0110 equal?

In a 16bit word, what is the weighting of the mostsignificant bit? What bit number should be allocated to this bit?

To what denary number is the binary number 1000 0000 0000 0001 equal?
Note that Windows has a calculator (in Accessories) that will evaluate numbers like 2^{10}, 2^{14}, etc. You will need to choose Scientific from its View menu and then use the x^{^}y key. For instance, to find 2^{10} press 2 then x^{^}y then 10 then =. You should get 1024.
Answer

Omitting the zeros because they do not contribute to the sum, this binary number is equal to:
(1 × 2^{7}) + (1 × 2^{6}) + (1 × 2^{2}) + (1 × 2^{1})
which is 128 + 64 + 4+ 2 = 198 in denary.

In an 8bit word the weighting of the mostsignificant bit is 2^{7}. By noting that 7 is one less than 8 you can see that the weighting of the mostsignificant bit in a 16bit word will be 2^{15}. 2^{15} is equal to 32 768 and the bit number is 15 (it is the same as the exponent of 2).

It is equal to:
(1 × 2^{15}) + (1 × 2^{0})
which is 32 768 + 1 = 32 769 in denary.
Counting in binary is very simple because there are only two possible digits. It proceeds as follows:

0

1

10

11

100

101

110

111

1000

etc.
Notice that when all the bits in any number are 1, the next higher number needs one more bit to represent it. This is exactly analogous to denary, where 999 is followed by 1000, which needs one more digit to represent it.
Activity 5 (Self assessment)

(a) What binary number follows

(i) 1 1111

(ii) 1 0111?


(b) What binary number precedes 1000 0000?
Answer

(a) (i)10 0000

(a) (ii) 1 1000
(b) 111 1111 (or 0111 1111 if an 8bit word is to be used).