Why Binary

From Compsci1

Why Binary

The binary system is important in computing for the simple reason that computers only understand binary. Every other piece of information they get is translated for them into binary. To a computer a switch is on or off – 1 is on 0 is off, receives a current or not, is magnetised or not. These situations with just two outcomes can be represented by the binary digits 0 and 1.

The problem with binary is that numbers become huge quite quickly. With larger bases we use fewer digits. However it is also use ful to be able to convert quickly between binary and other bases. Octal and hexadecimal are useful for this reason – octal, base 8 as 8 = 23 and hexadecimal – base 16 as 16 = 24. If we use any base bigger than 16 it becomes too complicated using new symbols to represent all the new digits so hexadecimal is the best we currently have.

Because 2 is a root of 8 and 16 these are useful as we can convert directly from binary and hexadecimal to binary and vice versa.

To convert from octal to binary write the 3 bit representation of each octal digit and the answer is in binary,

Eg 2378 = 010 011 1112

To convert from binary to octal we divide the binary digits into groups of three, adding more zeros in front of the number if necessary and convert directly to the octal equivalent.

001 111 101 1102 = 17568

To convert from hexadecimal to binary we group the binary bits in groups of 4.

Eg:59516 = 0101 1001 01012

11 0001 1110 010116 = 31E516

The digits 0 and 1 in binary are called bits. A group of 8 bits is called a byte. A word is a complete unit of information consisting of a unit of binary date. A word is normally 2 bytes = 16 bits. Numbers are stored in computer locations as a fixed number of bits. The number of bits = length of the word. A 4 bit unit is sometimes called a nibble.

Personal tools
Handy Pages