Chapter 1 digital systems and binary numbers
Binary Conversion
Divide by 2 and the remainder goes to the. Coefficient. The first remainder goes to the 0th Coefficient, the second remainder goes to the first Coefficient etc
Subtraction using 2's complement
If M is the minuend. And N is the subtrehend. M >= N Then adding M and the 2's complement of N is equal to M-N. There will be a carry in the largest bit. This is discarded. M < N Then adding M and the 2's complement of N will give the result in 2's complement because it will be a negative number. There is no carry.
2's complement
Radix complement. Leave all least significant 0's and the least significant 1 unchanged. Flip the rest. 1101100 2's complement is 0010100 0110111 2's complement is 1001001
Radix
The base of the number. Base 2 is binary. Base 8 octal. Base 10 decimal. Base 16 hexadecimal.
1's complement
The diminished radix complement. Just flipping the bits of a binary number makes it into a 1's complement. The 1's complement of 10101100 is 01010011
Complement
Used to simplify subtraction. If a number has base of r, the radix complement is referred to as the r's complement and the diminished radix complement is the (r-1)'s complement.