Pages: <Previous  27    28    29    30    31    32    33    34    35    36    37  Next >

8 Logic operations

8.2 The NOT operation

The NOT operation (note that, as with all logic operators, NOT is always written in capital letters) acts bit by bit on a single binary word according the following rules:

NOT 0 = 1

NOT 1 = 0

In other words, all the 1s in the word are changed to 0s and all the 0s are changed to 1s. Hence, for example,

NOT 1101 1011 = 0010 0100

As you saw earlier, the term complement or 1's complement is sometimes used for the result of the NOT operation. In fact, you carried out the NOT operation as your first step in forming the 2's complement of a binary integer.

Another term which is used for the NOT operation, especially in electronics, is ‘inversion’.

Pages: <Previous  27    28    29    30    31    32    33    34    35    36    37  Next >