Review of number systems

advertisement
1
SNSCE / EEE / EE6301 - DLC / REG.2013
REVIEW OF NUMBER SYSTEMS:
A number system specifies how values are represented. Human uses DECIMAL Number System.
There are ten digits in Decimal Number System: 0,1,2,3,4,5,6,7,8,9
Digital Computers use Binary Numbers, which have only two digits: 0, 1
There are other number systems, including: Octal and Hexadecimal
Number System Terminology
In Number System, a value of an n-digit number a n-1a n-2…a1 a 0 is:
N = a n-1 x r n-1 + a n-2 x r n-2 +…+ a 1 x r 1 + a 0 x r 0
Where a n-1, a n-2 ….. a1, a 0 are coefficients
r is called the Base or Radix
Decimal is Base-10 system, r = 10
Binary is Base-2 system, r = 2
Octal is Base-8 system, r = 8
Hexadecimal is Base-16 system, r = 16
Decimal Number System
The decimal system is composed of 10 numerals or symbols. These 10 symbols are 0, 1, 2, 3, 4,
5, 6, 7, 8, 9; using these symbols as digits of a number, we can express any quantity. The decimal
system, also called the base-10 system because it has 10 digits. Values are represented by the
digits and their positions in the number and the type of number system is called Positional
Number System.
103
102
101
100
=1000
=100
=10
=1
.
10-1
10-2
0-3
=0.1
=0.01
=0.001
Most
Decimal
Least
Significant
point
Significant
Digit
8973 is Eight Thousand Nine Hundred and Seventy Three:
8 = 8000 = 8 x 103 (Thousands Place)
9 = 900 = 9 x 102 (Hundreds Place)
7 = 70 = 7 x 101 (Tens Place)
3 = 3 = 3 x 100 (Units Place)
Binary Number System
An n-bit binary number a n-1a n-2…a1a 0 has a value:
Digit
2
SNSCE / EEE / EE6301 - DLC / REG.2013
N = a n-1 x 2 n-1 + a n-2 x 2 n-2 +…+ a 1 x 2 1 + a 0 x 2 0
This base-2 system can be used to represent any quantity that can be represented in decimal or
other number system.
23
22
21
20
=8
=4
=2
=1
Most
Significant
Bit
Binary
point
Least
Significant
Bit
.
2-1
2-2
2-3
=1/2
=1/4
=1/8
3
e.g. A 4-bit binary number 10112 is:
N = 1 x 23 + 0 x 22 + 1 x 21 + 1 x 20
= 8 + 0 + 2 + 1 = 1110
e.g. A 6-bit binary number 1100102 is:
N = 1x25 + 1x24 + 0x23 + 0x22 + 1x21 + 0x20
= 32 + 16 + 0 + 0 + 2 = 5010
The Binary counting sequence is shown in the table:
SNSCE / EEE / EE6301 - DLC / REG.2013
Download