Computer Number System Number System: I. Ii. Iii. IV
Computer Number System Number System: I. Ii. Iii. IV
com
Tecno Society 1
[email protected]
Let’s pick them one after the other to see how the computations are done and the underlying
logic behind them!
Tecno Society 2
[email protected]
Decimal Number System to Other Bases
The underlisted are the steps/procedures:
A) Divide the Number (Decimal Number) by the base of target base system (in which you
want to convert the number to e.g. Binary (2), Octal (8) OR Hexadecimal (16)).
B) Write the remainder from step 1 as a Least Signification Bit (LSB) to Step last as a
Most Significant Bit (MSB); that is, write from down-up.
Example 1: Convert 1234510 to Base 2
Solution 1:
Tecno Society 3
[email protected]
Furthering, ….
Example 3: Convert 1234510 to Base 16
Solution 3:
Tecno Society 4
[email protected]
1 * 26 + 1 * 25 + 0 * 24 + 1 * 23 + 1 * 22 + 0 * 21 + 1 * 20
= 1 * 64 + 1 * 32 + 0 * 16 + 1 * 8 + 1 * 4 + 0 * 2 + 1 * 1
= 64 + 32 + 0 + 8 + 4 + 0 + 1
= 10910 (QED)
5 * 81 + 3 * 80 = 5 * 8 + 3 * 1 = 40 + 3 = 4310 (QED)
Tecno Society 5
[email protected]
2 * 8 + 9 * 8 + 4 * 8 (Comment: What we did here is line with step A e.g. we multiply the
given/source base’s number (e.g. Base 8 - 294) with the base index e.g. 8.
Now, to complete the conversion computation, superscript the index position starting from 0
backward increasing downward. For instance, the equation becomes:
2 * 82 + 9 * 81 + 4 * 80 = 2 * 64 + 9 * 8 + 4 * 1 = 128 + 72 + 4=
= 20410 (QED)
Tecno Society 6
[email protected]
Other Base System to Decimal Number Base
To execute this type of conversion, simply convert the given base to base ten, then convert
to the target base.
1 * 24 + 0 * 23 + 0 * 22 + 1 * 21 + 1 * 20 = 1 * 16 + 0 * 8 + 0 * 4 + 1 * 2 + 1 * 1
16 + 0 + 0 + 2 + 1 = 1910 ……this is the conversion to base ten; now to eight:
8 19 3
8 2 2
So, 100112= 238
Shouldn’t you do some exercises now? Yes, I think you should. So, have these:
Exercises
1. Convert the following Base 2 numbers to Base 10:
i. 11000011
ii. 1001111
iii. 001101111
2. Convert the underlisted Base 8 numbers to Base 10:
i. 67
ii. 21
iii. 34
3. Convert the specified Base 16 numbers to Base 10:
i. 2A5
ii. 7E3D
iii. 82CA
4. Convert the listed Base 10 numbers to Base 2, 8 and 16
i. 34
ii. 89
iii. 68
5. Convert:
i. 1101102 to base 8
ii. 6789548 to base 16
Tecno Society 7