How to convert
Method 1
- Divide the leftmost digit of octal number by 2 until the quotient is 0. Write down the remainders of each division in reverse order, thus getting binary number.
- If the binary number obtained on the previous step has less than 3 digits, add leading zeros to get 3 digits.
- Repeat same actions for all next digits of source number. After that, you will have a set of 3-bit groups.
- Write them one after another and drop leading zeroes.
Let's convert 2568.
-
Divide the leftmost digit by 2, get remainders:
2 / 2 = 1, remainder 01 / 2 = 0, remainder 1
- Write down the remainders in reverse order: 10
- Add leading zeroes: 010
-
Repeat for other digits:
5 / 2 = 2, remainder 12 / 2 = 1, remainder 01 / 2 = 0, remainder 1Got 1016 / 2 = 3, remainder 03 / 2 = 1, remainder 11 / 2 = 0, remainder 1Got 110
- Write results together (010)(101)(110), drop leading zero: 101011102
Method 2
Replace each digit of octal number with corresponding 3-bit group using the conversion table:
Octal | Binary |
---|---|
0 | 000 |
1 | 001 |
2 | 010 |
3 | 011 |
4 | 100 |
5 | 101 |
6 | 110 |
7 | 111 |
2728 = (010) (111) (010) = 101110102