0% found this document useful (0 votes)
53 views17 pages

CH 5 - Number System

The document introduces different number systems including decimal, binary, octal, and hexadecimal. It explains how each system uses a different set of digits and base to represent numbers in a unique way. Examples are provided of converting between number systems like binary to decimal and hexadecimal to decimal.

Uploaded by

Aryan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
53 views17 pages

CH 5 - Number System

The document introduces different number systems including decimal, binary, octal, and hexadecimal. It explains how each system uses a different set of digits and base to represent numbers in a unique way. Examples are provided of converting between number systems like binary to decimal and hexadecimal to decimal.

Uploaded by

Aryan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 17

Introduction to Number Systems

Dr. Biswajit Nayak


Assistant Professor
Faculty of Management
• A number system is a system of writing for expressing
numbers. It is the mathematical notation for representing
numbers of a given set by using digits or other symbols in
a consistent manner.
• It provides a unique representation to every number.
• Different number systems are mentioned below.
– Decimal number system (Base- 10)
– Binary number system (Base- 2)
– Octal number system (Base-8)
– Hexadecimal number system (Base- 16)
Number Systems
• Decimal numbers
– Digits={0,1,2,3,4,5,6,7,8,9}
• Binary numbers
– Digits = {0, 1}
• Octal numbers
– Digits = {0, 1, 2, 3, 4, 5, 6, 7}
• Hexadecimal numbers
– Digits = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F}

Chapter 1 3
Decimal numbers

1439 = 1 x 103 + 4 x 102 + 3 x 101 + 9 x 100


3210
Thousands Hundreds Tens Ones

• Radix = 10
Binary Decimal
(1101)2 = (?)10
1101 = 1 x 23 + 1 x 22 + 0 x 21 + 1 x 20
3210
=1x8+1x4+0x2+1x1
=8+4+0+1

(1101)2 = (13)10

1, 2, 4, 8, 16, 32, 64, 128, 256, 512, ….


Binary Decimal
(1101.11)2= (?)10
1101.11 = 1x23 + 1x22 + 0x21 + 1x20 + 1x2-1 + 1x2-2
3210 -1 -2
= 1 x 8 + 1 x 4 + 0 x 2 + 1 x 1+1/21+1/22
= 1 x 8 +1 x 4+ 0 x 2+1 x1+1/2+1/4
= 8 + 4 + 0 + 1 + .5 +.25
= 13.75

(1101.11)2 = (13.75)10
Decimal Binary
(13.75)10 = (?)2
2 13 1 LSB
2 6 0
2 3 1
2 1 1 MSB
0

(13)10 = (1101)2
Decimal Binary

.75*2 1.5 1
.5*2 1.0 1
0

(.75)10 = (.11)2

(13.75)10 = (1101.11)2
Octal Decimal
• Octal numbers{0, 1, 2, 3, 4, 5, 6, 7}
• (137)8 = (?)10
137 = 1 x 82 + 3 x 81 + 7 x 80
= 1 x 64 + 3 x 8 + 7 x 1
= 64 + 24 + 7

(137)8 = (95)10

• Digits used in Octal number system – 0 to 7


Decimal Octal
(95)10 = (?)8
8 95 7 LSP
8 11 3
8 1 1
0 MSP

(95)10 = (137)8
• Example 4: Convert (0.513)10 to octal.
Solution:
0.513 × 8 = 4 .104 =4
0.104 × 8 = 0.832 =0
0.832 × 8 = 6.656 =6
0.656 × 8 = 5.248 =5
0.248 × 8 = 1.984 =1
0.984 × 8 = 7.872 =7
Result= .406517.... = ~ .406517
Hex Decimal
(BAD)16 = (?)10
(BAD)16 = 11 x 162 + 10 x 161 + 13 x 160
= 11 x 256 + 10 x 16 + 13 x 1
= 2816 + 160 + 13

(BAD)16 = (2989)10

A = 10, B = 11, C = 12, D = 13, E = 14, F = 15


Decimal Hex
(2989)10 = (?)16
16 2989 13 LSP
16 186 10
16 11 11
0 MSP

(2989)10 = (BAD)16
• 16*1=16
• 16*16=256
• 16*16*16=4096
• 16*16*16*16=65536
• Convert the hexdecimal number (3B.F) 16 to
decimal
3 B . F
=(3 *161 ) + (11 *160 ) + (15 *16-1 )
= 48 + 11 + 0.9375
= 59.9375

(3B.F)16=(59.9375)10
Binary-Octal and Binary-Hex
• Ease of use and conversion
• Three bits make one octal digit
111 010 110 101
7 2 6 5 => 7265 in octal

• Four bits make one hexadecimal digit


1110 1011 0101
E B 5 => EB5 in hex
Examples
• Binary numbers
(11010.11)2 = 1 x 24 + 1 x 23 + 0 x 22 + 1 x 21 + 0 x 20 + 1 x 2-1 + 1 x 2-2
= (26.75)10
• Octal numbers
(127.4)8 = 1 x 82 + 2 x 81 + 7 x 80 + 4 x 8-1 = (87.5)10

• Hexadecimal numbers
(B65F)16 = 11 x 163 + 6 x 162 + 5 x 161 + 15 x 160 = (46,687)10

You might also like