8. INDEX
1. Common Number Systems
2. Quantities/Counting (1 of 2)
3. Conversion Among Bases
4. Decimal to Decimal (just for fun)
5. Binary to Decimal
6. Octal to Decimal
7. Hexadecimal to Decimal
8. Decimal to Binary
9. Octal to Binary
10. Hexadecimal to Binary
11. Decimal to Octal
12. Decimal to Octal
13. Decimal to Hexadecimal
14. Binary Addition (1 of 2)
15. Multiplication (1 of 3)
16. Fractions
2
17. Binary to Decimal
17
• Technique
• Multiply each bit by 2n, where n is the “weight” of the bit
• The weight is the position of the bit, starting from 0 on the right
• Add the results
18. Example
18
1010112 => 1 x
1 x
0 x
1 x
0 x
1 x
20
21
22
23
24
25
= 1
= 2
= 0
= 8
= 0
= 32
4310
Bit
22. Octal to Decimal
22
• Technique
• Multiply each bit by 8n, where n is the “weight” of the bit
• The weight is the position of the bit, starting from 0 on the right
• Add the results
25. Hexadecimal to Decimal
25
• Technique
• Multiply each bit by 16n, where n is the “weight” of the bit
• The weight is the position of the bit, starting from 0 on the right
• Add the results
26. Example
26
ABC16 => = 12 x
= 11 x
1 = 12
16 = 176
C x 160
B x 161
A x 162 = 10 x 256 = 2560
274810
A=10,b=11,C=12,D=13,E=14,F=15
28. Decimal to Binary
28
• Technique
• Divide by two, keep track of the remainder
• First remainder is bit 0 (LSB, least-significant bit)
• Second remainder is bit 1
• Etc.