Tuesday, 4 August 2015

Number Systems and Conversions

What is decimal number system ?
A decimal number system is the one which uses numerals from the set 0,1,2,3,4,5,6,7,8,9 to represent a number in the system. It is also called as base 10 or sometimes denary.
Examples :
153   = 1x102 + 5x101 + 3x100                          =   100 +   50 +   3       =   153
3489 = 3x103  4x102 + 8x101 + 9x100    = 3000 + 400 + 80 + 9 = 3489

What is Binary number system ?
In binary number system, we represent a number by using only two numerals viz. 0 and 1. The main use of binary number system is in computers to represent bits as on or off.
Example :
101       =                                   1x2+  0x2+1x20  =                        4 + 0 + 1 =   5
110011 = 1x25 + 1x24 + 0x23 + 0x22 + 1x21 +1x20  =  32 +16 + 0 + 0 + 2 + 1 = 51

Decimal To Binary Conversion
Humans use decimal number system but computers use binary number systems. Without this conversion it would be very difficult to interact with computers. Let us see how we can achieve conversion of decimal number to binary number.

Following steps are involved in converting a decimal number into a binary
1. Take the decimal number
2. Divide the number with 2 and append the reminder in a sequence.
3. Take the quotient and make it as a number.
4. Repeat steps 2 and 3 until quotient becomes 0.
5. Read all the appended reminders backwards - giving you the desired binary number.

Example :
Decimal Number - 169                


No comments:

Post a Comment