Binary languege

 

Apart to its use for arithmetic the binary code is also to translate words. Computers programs are translated into binary code before they can be used. Computers are often described in terms of the 'word length'. You will hear people talk about '8-bit'or '16-bit' computers, for example. This has nothing to do with their memory size. Instead it refers to the number of binary digits (BITS) that can be transferred between the different parts of the CPU at any one time.

The word length is an important determining feature of a computer. It defines how large or small a range for numbers can be used. Every common grouping is to use a BYTE. Imagine a four-bit computer. Here is the complete range of binary digits that can be coded in 4 bits. Binary Decimal The four-bit computer can handle arithmetic so long as the answer is not more than 15! Computers designers overcome the problem by using a longer word length (16,32 and common) and by combing words together (or very small) numbers. An alternative explanation of our four-bit-codes would be to regard each combination as a letter:

What about the letter 'Q' to 'Z'? This is another case where there aren't enough codes to go round! In an 8-bit BYTE there are 256 different codes, from 00000000 to11111111! There are more than enough codes for:- Twenty six capital letters of the alphabet (A-Z) The alphabet in small letters (a-z) Currency signs like £ and $ Special letters like ones with accents in certain language Special symbols such as & and ? If it was left up to the individual designers of computers so doubt they would all have decided to use different coding system. Luckily, however, most conform to standard coding systems that have developed in recent years.

 

The binary code is the basic of computer language. To understand how
a computer works you must have some knmowledge of Binary Arithmetic

Why is the binary system so important of computers? The answer is simple.
At the heart of the computer are the heart of the computer are teh CHIPS.
One the CHIPS are the thousands of electronic cirrying electrical signals or
pulse.

A pulse is, as its name suggests, 'on' or 'off'. An early example of a binary
code is the Morse Code. This uses 'dots' and 'dashes' when it is written down
and if you ever hear Morse Code you'll recognise the dash as a longer sound
than the dot.
The word 'binary' really means 'two'. A code like the Morse Code which uses
only two symbols is a binary code. Something like a light a light switch which
only has two positions: 'on' and 'off', is a binary device. An electrical pulse can
be used to represent '1' which also means 'on'. The absence of a pulse is '0' or
'off'. The 'zero' signal or no-pulse is as important as the pulse or 'one' pulse.
How do you do arithmetic using using only the sysmbol 1 or 0? It looks
strange but it follows the same rules as ordinary arithmetic. In ordinary
decimal arithmetic we use ten different symbols. We use the numerals 0, 1, 3,
4, 5, 6, 7, 8, 9. We combine these numerals and write for example:
'500' meaning 'five hundred'
or
'29' meaning 'twenty nine'.

Actually '29' is really shorthand for saying:
two tens plus nine units.

If we write '333', meaning three hundred and thirthy three, we have used
the same symbol [3] but its value has been multiplied by 10 each time we
move one place to the left. It really means:

three hundred
plus
thirthy
plus
three
[3*10*10]

[3*10]

[3]

 


 

 

 

Click to go Top

In binary arithmetic the symbols are multiplied by 2 for each position we move to the left. Inside the computer complex calculations are reduced to arithmetic done in noughts and ones! Here are some binary numbers with their decimal equivalents:

Binary
1 equivalent to
10
100
1000
11
101
111

Decimal
1
1*2=2
1*2*2=4
1*2*2*2=8
1*2 plus 1=3
1*1*2 plus 1=5
1*2*2 plus
1*2 plus 1=7

Got that? Read it over carefully to make sure you understand the principle of binary numbers. The next few sums are example of simple arithmetic using the Rules of Binary Addition.

RULES FOR ADDITION

0+0=0
0+1=1
1+0=1
1+1=10

EXAMPLE:

Binary
10
+1
___
11
____

101
+10
____
111
_____

101
+1
____
110
_____
1
carry
11
+1
_____
100
_____
11
carry carry

Decimal
2
+1
___
3
___

5
+2
___
7
____

5
+1
____
6
____

one
3
+1
____
4
____

 

The rules for SUBTRACTION
are equally simple:

0-0=0
1-0=1
0-1=0
1-1=0

MULTIPLICATION and DIVISION
can also be done just as easily!

0*0=0
0*1=0
1*0=0
1*1=1
0/0=0
1/0=0
0/1=0
1/1=1

 

 

Home || Introduction || Histrory in Computing || Glossary of PC || About us
Thinkquest