# Why so many number systems?

1. Nov 21, 2015

### Raghav Gupta

We use decimal base system in almost all our calculations.
Computer understands only binary of base 2. Then why octal, hexadecimal etc?

2. Nov 21, 2015

### Hornbein

Because 01010100101011010101011010110100011000100000001000 is too hard to read. Decimal is too hard to decode to get the value of actual bits.

3. Nov 21, 2015

### phinds

First, they are NOT really different number systems at all, they are just shorthand for binary.

Second, as Hornbein pointed out, remembering, or even reading, long strings of 1's and 0's is just silly and HIGHLY error prone.

Early computers used octal as a shorthand for binary, later ones used hexidecimal as a shorthand for binary.

Last edited: Nov 21, 2015
4. Nov 21, 2015

### SteamKing

Staff Emeritus
Binary, octal, and hex are all different forms of the same number.

As was mentioned, binary is too cumbersome for humans to handle, so octal and hex were substituted to make binary numbers easier to read.

By grouping binary digits in sets of three, you can easily convert to octal.

By grouping binary digits in sets of four, you can easily convert to hex.

Taking 01010100101011010101011010110100011000100000001000 as an example:

01 010 100 101 011 010 101 011 010 110 100 011 000 100 000 001 000 = 12453253264304010 octal

01 0101 0010 1011 0101 0101 1010 1101 0001 1000 1000 0000 1000 = 152B55AD18808 hex

5. Nov 21, 2015

### Staff: Mentor

To expand on what SteamKing said, the memory in some early computers was organized in bytes of six bits. A half-byte was three bits, which could store any number in the range of 0 through 7. These are the digits used in the octal number system.

Not too long after that, there were computers with memory organized in eight-bit bytes. Each half of a byte (a "nybble") could store a number in the range of 0 through 15. In hexadecimal, 0 through F. The upshot is that octal numbering is there mostly for historical reasons, but hex is still very widely used, as it is very easy to convert to and from binary.