Number Base Conversion
Number Base Conversion
CONVERSION
1. In the first step, we perform the division operation on integer and successive
part with base 'r'. We will list down all the remainders till the quotient is zero. Then
we find out the remainders in reverse order for getting the integer part of the
equivalent number of base 'r'. In this, the least and most significant digits are
denoted by the first and the last remainders.
DECIMAL TO
OTHER NUMBER SYSTEM
2. In the next step, the multiplication operation is done with base 'r' of the
fractional and successive fraction. The carries are noted until the result is zero or
when the required number of the equivalent digit is obtained. For getting the
fractional part of the equivalent number of base 'r', the normal sequence of carrying
is considered.
DECIMAL TO BINARY CONVERSION:
For converting decimal to binary, there are two steps required to perform, which are
as follows:
1. In the first step, we perform the division operation on the integer and the
successive quotient with the base of binary(2).
2. Next, we perform the multiplication on the integer and the successive quotient
with the base of binary(2)
DECIMAL TO OTHER NUMBER SYSTEM
DECIMAL TO BINARY CONVERSION:EXAMPLE: (152.25)10
Step 1: Divide the number 152 and its successive quotients with base 2.
OPERATION QUOTIENT REMAINDER
152/2 76 0 (LSB)
76/2 38 0
38/2 19 0
19/2 9 1
9/2 4 1
4/2 2 0
(152)10=(10011000)2
2/2 1 0
1/2 0 1(MSB)
DECIMAL TO OTHER NUMBER SYSTEM
DECIMAL TO BINARY CONVERSION:
EXAMPLE: (152.25)10
Now, perform the multiplication of 0.25 and successive fraction with base 2.
0.25×2 0.50 0
0.50×2 0 1
(0.25)10=(0.01)2
So, the binary number of the decimal number 152.25 is 10011000.01
DECIMAL TO
OTHER NUMBER SYSTEM
DECIMAL TO OCTAL CONVERSION:
For converting decimal to octal, there are two steps required to perform, which are as
follows:
1. In the first step, we perform the division operation on the integer and the
successive quotient with the base of octal(8).
2. Next, we perform the multiplication on the integer and the successive quotient
with the base of octal(8).
DECIMAL TO OTHER NUMBER SYSTEM
DECIMAL TO OCTAL CONVERSION:
EXAMPLE: (152.25)10
Step 1: Divide the number 152 and its successive quotients with base 8.
152/8 19 0
19/8 2 3
2/8 0 2
(152)10=(230)8
DECIMAL TO OTHER NUMBER SYSTEM
DECIMAL TO BINARY CONVERSION:
EXAMPLE: (152.25)10
Now, perform the multiplication of 0.25 and successive fraction with base 8.
0.25×8 0 2
(0.25)10=(2)8
1. In the first step, we perform the division operation on the integer and the
successive quotient with the base of hexadecimal (16).
2. Next, we perform the multiplication on the integer and the successive quotient
with the base of hexadecimal (16).
DECIMAL TO OTHER NUMBER SYSTEM
DECIMAL TO HEXADECIMAL CONVERSION:
EXAMPLE: (152.25)10
Step 1: Divide the number 152 and its successive quotients with base 16.
152/16 9 8
9/16 0 9
(152)10=(98)16
DECIMAL TO OTHER NUMBER SYSTEM
DECIMAL TO HEXADECIMAL CONVERSION:
EXAMPLE: (152.25)10
Now, perform the multiplication of 0.25 and successive fraction with base 16.
0.25×16 0 4
(0.25)10=(4)16
1. In the first step, we will find the binary equivalent of number 25.
2. Next, we have to make the pairs of four bits on both sides of the binary point. If
there will be one, two, or three bits left in a pair of four bits pair, we add the
required number of zeros on extreme sides and write the hexadecimal digits
corresponding to each pair.
OCTAL TO
OTHER NUMBER SYSTEM
(152.25)8=(001101010.010101)2
Let's take an example to understand how the conversion is done from hexadecimal to
decimal.
HEXADECIMAL TO
OTHER NUMBER SYSTEM
HEXADECIMAL TO DECIMAL CONVERSION:
Example 1: (152A.25)16
We multiply each digit of 152A.25 with its respective positional weight, and last we add the
products of all the bits with its weight.
(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.14453125)16
So, the decimal number of the hexadecimal number 152A.25 is 5418.14453125
HEXADECIMAL TO
OTHER NUMBER SYSTEM
HEXADECIMAL TO OCTAL CONVERSION:
For converting hexadecimal to octal, there are two steps required to perform, which
are as follows:
1. In the first step, we will find the binary equivalent of the hexadecimal number.
2. Next, we have to make the pairs of three bits on both sides of the binary point. If there
will be one or two bits left in a pair of three bits pair, we add the required number of
zeros on extreme sides and write the octal digits corresponding to each pair.
HEXADECIMAL TO
OTHER NUMBER SYSTEM
HEXADECIMAL TO OCTAL CONVERSION:
Example 1: (152A.25)16
Step 1:
We write the four-bit binary digit for 1, 5, 2, A, 2, and 5.
(152A.25)16=(0001 0101 0010 1010.0010 0101)2
So, the binary number of hexadecimal number 152A.25 is (0011010101010.010101)2
Step 2:
Then, we make pairs of three bits on both sides of the binary point.
001 010 100 101 010.001 001 010
Then, we write the octal digit, which corresponds to each pair.
(001010100101010.001001010)2=(12452.112)8
So, the octal number of the hexadecimal number 152A.25 is 12452.112
THANK YOU