The document discusses converting between binary and hexadecimal numbers. It provides two methods: 1) Divide the binary number into groups of 4 bits and convert each group to hexadecimal. 2) Convert the binary number to decimal first, then convert the decimal to hexadecimal. Examples are given to demonstrate converting binary numbers to hexadecimal using both methods.
1. Conversions of binary number to
hexadecimal, Conversions of
hexadecimal to binary
http://improvec.blogspot.in/ 1
2. Objective
On completion of this period, you would be able
to know
Conversion of a binary number to hexa
decimal
Conversion of a hexa decimal number to
binary
http://improvec.blogspot.in/ 2
4. Prerequisite
Representation of Binary system
Representation of Hexadecimal system
Relationship between Binary and Hexadecimal
http://improvec.blogspot.in/ 4
6. Conversion of a binary number to
hexadecimal number
METHOD 1
As base16 = 24, to convert a binary number to
hexadecimal
4-bit binary groups (each group contains 4
binary bits) are formed in the binary number
After forming the groups, each group of 4 binary
bits is converted to its hexadecimal number
http://improvec.blogspot.in/ 6
7. 1.Convert the binary number 01101110 to
its equivalent hexadecimal
Divide the given binary number into 4-bit binary
groups
(01101110)2 = (0110) (1110)
= 6E (hex)
(01101110)2=(6E)16
http://improvec.blogspot.in/ 7
8. 2.Convert the binary number 1101001101 to its
equivalent hexadecimal
Forming of groups of 4-bits from right hand side
to left
(1101001101)2 = (11) (0100) (1101)
We see that the group of the most significant
binary bits
contains only 2 binary bits
http://improvec.blogspot.in/ 8
9. Convert the binary number 1101001101 to its
equivalent hexadecimal (contd)
This can be extended to 4 binary bits by adding
zeros in MSB position
If MSBs are extended by adding zeros the
number remains unaffected
(1101001101)2 = (0011) (0100) (1101)
= 34D (hex)
http://improvec.blogspot.in/ 9
10. 3. Convert the binary number 1011100.1000101
to its equivalent hexadecimal
The formation of grouping of binary bits which are
after the binary point, is made from left to right
1011100.1000101 = (101)(1100).(1000)(101)
= (0101)(1100).(1000)(1010)
= 5C.8A (hex)
http://improvec.blogspot.in/ 10
11. Conversion of a binary number to
hexadecimal number
METHOD 2
First convert a binary number to decimal number
Then convert the decimal number so obtained to
hexadecimal number
http://improvec.blogspot.in/ 11
12. 1.Convert the binary number 101101 to its
equivalent hexadecimal
101101 = 1*25 + 0*24 + 1*23 +1*22 + 0*21 +1*20
= 32 + 0 + 8 + 4 +0 + 1
= (45)10
http://improvec.blogspot.in/ 12
13. Convert the binary number 101101 to its
equivalent hexadecimal (contd)
Now convert 45 into hexadecimal number.
division remainder
16 45
16 2 13 = D
0 2
(45)10 = (2D)16
Thus (101101)2 = (45)10 = (2D)16
http://improvec.blogspot.in/ 13