Subject: Computer
To convert the decimal number to binary number, repeated division by two is needed.
Examples: Convert following into binary numbers:
To convert binary to the decimal number system, multiply given number by 2.
1. (1101)_{2}=(?)_{10}
=1x2^{3}+ 1 x 2^{2}+ 0x 2^{1}+ 1x 2^{0}=8 + 4 + 0 + 1
=13
A | B | A+B |
0 | 0 | 0 |
0 | 1 | 1 |
1 | 0 | 1 |
1 | 1 | 0 with carry 1 |
1 | Carry | |||
1 | 1 | 0 | 0 | |
1 | 1 | 1 | 1 | |
11 | 0 | 1 | 1 |
A | B | A*B |
0 | 0 | 0 |
0 | 1 | 0 |
1 | 0 | 0 |
1 | 1 | 1 |
What is a binary addition? Write the rules for binary addition.
Binary numbers are added to the same manner as decimal numbers. There are only four possible combinations resulting from the addition of two binary digits.
Rules for binary addition:
A | B | A+B |
0 | 0 | 0 |
0 | 1 | 1 |
1 | 0 | 1 |
1 | 1 | 10 |
i.e. 0 carry 1
The rules for subtraction are the same in the binary system as in the decimal system. The result of the subtraction of binary digit is either 0 or 1.
Rules for binary subtraction:
A | B | A-B |
0 | 0 | 0 |
1 | 0 | 1 |
1 | 1 | 0 |
0 | 1 | 1 |
Binary numbers are multiplied in the same manner as decimal numbers. We need to remember the rules of binary addition.
Rules for binary multiplication:
A | B | A×B |
0 | 0 | 0 |
1 | 0 | 0 |
0 | 1 | 0 |
1 | 1 | 1 |
(1110)_{2}=(?)_{10}
=1x2^{3}+ 1 x 2^{2}+ 1x 2^{1}+ 0x 2^{0}=8 + 4 + 2 + 0
=14
(45)_{10}= (101101)_{2}
2 | 45 | 1 |
2 | 22 | 0 |
2 | 11 | 1 |
2 | 5 | 1 |
2 | 2 | 0 |
1 |
=(101101)_{2}
© 2019-20 Kullabs. All Rights Reserved.