Number System Conversion
Decimal to other Number System (3)
1. Decimal to Binary Conversion
Example : (152.25)10
Step 1: Successive division for integer part
Divide the number 152 and its successive quotients with base 2.
Collect Remainder from MSB to LSB (Bottom to Top Direction)
(152)10=(10011000)2
Step 2: Successive multiplication for fractional part
Perform the multiplication of 0.25 and successive fraction with base 2.
Collect Re from LSB to MSB (Top to Bottom Direction)
(0.25)10=(.01)2
So (152.25)10 =(10011000.01)2
Exercise
1. (345.67) 10 = (?)2
2. (567.89) 10 = (?)2
2. Decimal to Octal Conversion
Example : (152.25)10
Step 1: Successive division for integer part
Divide the number 152 and its successive quotients with base 8.
Collect Remainder from MSB to LSB (Bottom to Top Direction)
(152)10=(230)8
Step 2: Successive multiplication for fractional part
Perform the multiplication of 0.25 and successive fraction with base 8.
(0.25)10=(.2)8
So (152.25)10 =(230.2)8
Exercise
1. (345.67) 10 = (?)8
2. (567.89) 10 = (?)8
3. Decimal to hexadecimal conversion
Example : (152.25)10
Step 1: Successive division for integer part
Divide the number 152 and its successive quotients with base 16.
Collect Remainder from MSB to LSB (Bottom to Top Direction)
(152)10=(98)16
Step 2: Successive multiplication for fractional part
Perform the multiplication of 0.25 and successive fraction with base 16.
(0.25)10=(.4)16
So (152.25)10 =(98.4)16
Exercise
1. (345.67) 10 = (?)16
2. (567.89) 10 = (?)16
Other Number System to Decimal (3)
(Multiply by positional weight and add together)
4. Binary to Decimal Conversion
Example : (10110.001)2
(10110.001)2=(1×24)+(0×23)+(1×22)+(1×21)+(0×20)+(0×2-1)+(0×2-2)+(1×2-3)
(10110.001)2=(1×16)+(0×8)+(1×4)+(1×2)+(0×1)+(0×1⁄2)+(0×1⁄4)+(1×1⁄8)
(10110.001)2=16+0+4+2+0+0+0+0.125
(10110.001)2=(22.125 )10
Exercise
1. (1100110.11) 2 = (?)10
2. (100101.01) 2 = (?)10
5. Octal to Decimal Conversion
Example : (152.25)8
(152.25)8=(1×82)+(5×81)+(2×80)+(2×8-1)+(5×8-2)
(152.25)8=64+40+2+(2×1⁄8)+(5×1⁄64)
(152.25)8=64+40+2+0.25+0.078125
(152.25)8=106.3281
Exercise
1. (345.67) 8 = (?)10
2. (567.24) 8 = (?)10
6. Hexa-decimal to Decimal Conversion
Example : (152A.25)16
(152A.25)16=(1×163)+(5×162)+(2×161)+(A×160)+(2×16-1)+(5×16-2)
(152A.25)16=(1×4096)+(5×256)+(2×16)+(10×1)+(2×16-1)+(5×16-2)
(152A.25)16=4096+1280+32+10+(2×1⁄16)+(5×1⁄256)
(152A.25)16=5418+0.125+0.125
(152A.25)16 = 5418.1445
Exercise
1. (3C5.D7) 16 = (?)10
2. (ECE.A1) 16 = (?)10
Direct Conversions (4)
3 Bit Binary Counting
4 Bit Binary Counting
7. Binary to Octal Conversion
Example : (111110101011.0011)2
1. Firstly, we make pairs of three bits on both sides of the binary point.
111 110 101 011 . 001 1
On the right side of the binary point, the last pair has only one bit. To make it a
complete pair of three bits, we added two zeros on the extreme side.
111 110 101 011 . 001 100
2. Then, write the octal digits, which correspond to each pair.
7 6 5 3 . 1 4
So (111110101011.0011)2=(7653.14)8
Exercise
1. (1110001101.1101)2 = (?)8
2. (01011101.1011)2 = (?)8
8. Binary to Hexadecimal Conversion
Example 1: (11110101011.0011)2
1. Firstly, we make pairs of four bits on both sides of the binary point.
111 1010 1011 . 0011
On the left side of the binary point, the first pair has three bits. To make it a complete
pair of four bits, add one zero on the extreme side.
0111 1010 1011 . 0011
2. Then, we write the hexadecimal digits, which correspond to each pair.
7 A B . 3
(011110101011.0011)2=(7AB.3)16
Exercise
1. (1110001101.1101)2 = (?)16
2. (01011101.10111)2 = (?)16
9. Octal to Binary Conversion
Example 1: (152.25)8
We write the three-bit binary digit for 1, 5, 2, and 5.
(152.25)8=(001 101 010 . 010 101)2
So, the binary number of the octal number
(152.25) 8 = (1101010.010101)2
Exercise
1. (567.32)8 = (?)2
2. (765.43)8 = (?)2
10. Hexadecimal to Binary Conversion
Example 1: (152A.25)16
We write the four-bit binary digit for 1, 5, A, 2, and 5.
(152A.25)16=(0001 0101 0010 1010 . 0010 0101)2
So, the binary number of the hexadecimal number
(152.25) 16 = (1010100101010.00100101)2
Exercise
1. (ABC.DE)16= (?)2
2. (5C7.F9)16 = (?)2
Indirect Conversions (2)
11. Octal to Hexadecimal conversion
Example 1: (152.25)8
Step 1:
We write the three-bit binary digit for 1, 5, 2, and 5.
(152.25)8=(001 101 010 . 010 101)2
So, the binary number of the octal number 152.25 is (1101010.010101)2
Step 2:
1. Now, we make pairs of four bits on both sides of the binary point.
110 1010 . 0101 01
On the left side of the binary point, the first pair has only three digit, and on the right
side, the last pair has only two-digit. To make them complete pairs of four bits, add
zeros on extreme sides.
0110 1010 . 0101 0100
2. Now, we write the hexadecimal digits, which correspond to each pair.
( 0110 1010 . 0101 0100)2 = (6A.54)16
So (152.25)8 = (6A.54)16
Exercise
1. (345.67)8 = (?)16
2. (567.43) 8 = (?)16
12. Hexadecimal to Octal Conversion
Example 1: (152A.25)16
Step 1:
We write the four-bit binary digit for 1, 5, 2, A, and 5.
(152A.25)16=(0001 0101 0010 1010 . 0010 0101)2
So, the binary number of hexadecimal number 152A.25
is (1010100101010.00100101)2
Step 2:
3. Then, we make pairs of three bits on both sides of the binary point.
001 010 100 101 010 . 001 001 010
4. Then, we write the octal digit, which corresponds to each pair.
1 2 4 5 2 . 1 1 2
(001010100101010.001001010)2=(12452.112)8
So (152A.25) 16 = (12452.112) 8
Exercise
1. (E45.B7) 16 = (?)8
2. (5A7.D9) 16 = (?)8