NUMBER SYSTEM
- Asst. Prof. Meenakshi Paul
G. N. Khalsa College
OUTLINE
 1.1 Numbering system
 Binary number system
 Octal number system
 Decimal number system
 Hexadecimal number system
 1.2 Conversion from one number system to another
 1.3 Floating point numbers,
1.1 NUMBERING SYSTEM
 A mathematical notation for representing numbers is
known as number system.
 A number system is a system for expressing numbers .
 The number system is used for representing the
information.
 The number system has different bases and the most
common of them are the decimal, binary, octal, and
hexadecimal.
 The base or radix of the number system is the
total number of the digit used in the number system.
1.1 NUMBERING SYSTEM
CONTD…
 Collection of digits forms a number, which can be divided in two parts :
Integer and fractional part that set apart by a radix point , shown below
1.1 NUMBERING SYSTEM
CONTD…
STORAGE (MEMORY) SIZE UNIT TABLE
TYPES OF NUMBER SYSTEMS
 Some of the important types of number system
are:
 Decimal Number System
 Binary Number System
 Octal Number System
 Hexadecimal N.S.
8
BASE-N NUMBER SYSTEM
 Base N
 N Digits: 0, 1, 2, 3, 4, 5, …, N-1
 Example: 1045N
 Positional Number System
• Digit do is the least significant digit (LSD).
• Digit dn-1 is the most significant digit (MSD).
1 4 3 2 1 0
1 4 3 2 1 0
n
n
N N N N N N
d d d d d d


L
L
9
DECIMAL NUMBER SYSTEM
 Base/Radix 10
 Ten Digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
 Example: 104510
 Positional Number System
 Digit d0 is the least significant digit (LSD).
 Digit dn-1 is the most significant digit (MSD).
1 4 3 2 1 0
1 4 3 2 1 0
10 10 10 10 10 10n
nd d d d d d


L
L
10
BINARY NUMBER SYSTEM
 Base 2
 Two Digits: 0, 1
 Example: 10101102
 Positional Number System
 Binary Digits are called Bits
 Bit bo is the least significant bit (LSB).
 Bit bn-1 is the most significant bit (MSB).
1 4 3 2 1 0
1 4 3 2 1 0
2 2 2 2 2 2n
nb b b b b b


L
L
OCTAL NUMBER SYSTEM
 Base 8
 Two Digits: 0, 1,2,3,4,5,6,7,
 Example: 01458
 Positional Number System
8n-1 …. 83 82 81 80
000 0
001 1
010 2
011 3
100 4
101 5
110 6
111 7
12
HEXADECIMAL NUMBER SYSTEM
 Base 16
 Sixteen Digits: 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
 Example: EF5616
 Positional Number System
0000 0
0001 1
0010 2
0011 3
0100 4
0101 5
0110 6
0111 7
1000 8
1001 9
1010 A
1011 B
1100 C
1101 D
1110 E
1111 F
1 4 3 2 1 0
16 16 16 16 1616n
L
CONVERSION TABLE BINARY, OCTAL, DECIMAL
AND HEXADECIMAL
CONVERSION OF BASE
1.2 CONVERSION OF BASE
1.2.1 Decimal to Binary, Octal and Hexadecimal
1.2.2 Binary to Decimal, Octal and Hexadecimal
1.2.3 Octal to Binary, Decimal and Hexadecimal
1.2.4 Hexadecimal to Binary, Octal and Decimal
1.2.1 DECIMAL TO BINARY CONVERSION
 Step 1: Divide the decimal
number by 2, get the integer
quotient and the remainder.
 Step 2: Convert the remainder to
the binary digit in that position.
 Step 3: Using the integer
quotient to repeat the steps until
the integer quotient equals to 0.
DECIMAL TO BINARY CONVERSION
 (62)10=?  (43)10=?
EXAMPLES
1. (78)10=? 2. (156)10=? 3.(266)10= ?
DECIMAL TO FRACTION BINARY CONVERSION
DECIMAL FRACTION TO BINARY CONVERSION
 (0.692)10=?  (0.188)10=?
DECIMAL TO OCTAL
 Step 1: Divide the decimal number
by 8, get the integer quotient and
the remainder.
 Step 2: Convert the remainder to
the octal digit in that position.
 Step 3: Using the integer quotient
to repeat the steps until the integer
quotient equals to 0.
DECIMAL TO OCTAL
 (100)10=?  (473)10=?
DECIMAL FRACTION TO OCTAL CONVERSION
DECIMAL TO HEXADECIMAL
DECIMAL TO HEXADECIMAL
 Step 1: Divide the decimal number
by 16, get the integer quotient and
the remainder.
 Step 2: Convert the remainder to
the hex digit in that position.
 Step 3: Using the integer quotient
to repeat the steps until the integer
quotient equals to 0.
DECIMAL FRACTION TO HEXADECIMAL
1.2.2 BINARY TO DECIMAL
EXAMPLES
BINARY FRACTION TO DECIMAL
BINARY TO OCTAL
 For binary representation of octal
number, each octal number is
represented by 3 binary bits.
 For example, the octal number 5 is
represented by 101 while the octal
45 by 100101.
BINARY TO OCTAL
BINARY FRACTION TO OCTAL
BINARY TO HEXADECIMAL
 Start from the right-hand side by
dividing the given binary digits into
groups of four.
 Convert each group into the
hexadecimal number by applying
binary to decimal conversion
methods and then represent
decimal value to their
corresponding hexadecimal value.
BINARY TO HEXADECIMAL
1.2.3. OCTAL TO DECIMAL
1.2.3 OCTAL TO BINARY
OCTAL TO HEXADECIMAL
1.2.4 HEXADECIMAL TO OCTAL
1.2.4 HEXADECIMAL TO OCTAL
1.2.4 HEXADECIMAL TO DECIMAL
1.2.4 HEXADECIMAL TO BINARY
FLOATING POINT NUMBER
1.3 FLOATING POINT NUMBER
 very large integer number, storage problem
 Fixed point number means the fractional point(decimal point)
 Floating point numbers are also called as the real numbers.
 So representation of such number in floating form which have both integer and
fraction parts. It uses power 10.
 Parts of floating point number: 1. Mantissa II. Exponent
 Mantissa: It holds the main digits of floating point
 Exponent: It defines where the decimal point should be placed
 Example
 Only the mantissa and the exponent are stored. The base is implied (known already)
As it is not stored this will save memory capacity
A 32 BIT FLOATING POINTNUMBER
Sign Exponent Mantissa
1bit 8 bits 23 bits

Number System

  • 1.
    NUMBER SYSTEM - Asst.Prof. Meenakshi Paul G. N. Khalsa College
  • 2.
    OUTLINE  1.1 Numberingsystem  Binary number system  Octal number system  Decimal number system  Hexadecimal number system  1.2 Conversion from one number system to another  1.3 Floating point numbers,
  • 3.
    1.1 NUMBERING SYSTEM A mathematical notation for representing numbers is known as number system.  A number system is a system for expressing numbers .  The number system is used for representing the information.  The number system has different bases and the most common of them are the decimal, binary, octal, and hexadecimal.  The base or radix of the number system is the total number of the digit used in the number system.
  • 4.
    1.1 NUMBERING SYSTEM CONTD… Collection of digits forms a number, which can be divided in two parts : Integer and fractional part that set apart by a radix point , shown below
  • 5.
  • 6.
  • 7.
    TYPES OF NUMBERSYSTEMS  Some of the important types of number system are:  Decimal Number System  Binary Number System  Octal Number System  Hexadecimal N.S.
  • 8.
    8 BASE-N NUMBER SYSTEM Base N  N Digits: 0, 1, 2, 3, 4, 5, …, N-1  Example: 1045N  Positional Number System • Digit do is the least significant digit (LSD). • Digit dn-1 is the most significant digit (MSD). 1 4 3 2 1 0 1 4 3 2 1 0 n n N N N N N N d d d d d d   L L
  • 9.
    9 DECIMAL NUMBER SYSTEM Base/Radix 10  Ten Digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9  Example: 104510  Positional Number System  Digit d0 is the least significant digit (LSD).  Digit dn-1 is the most significant digit (MSD). 1 4 3 2 1 0 1 4 3 2 1 0 10 10 10 10 10 10n nd d d d d d   L L
  • 10.
    10 BINARY NUMBER SYSTEM Base 2  Two Digits: 0, 1  Example: 10101102  Positional Number System  Binary Digits are called Bits  Bit bo is the least significant bit (LSB).  Bit bn-1 is the most significant bit (MSB). 1 4 3 2 1 0 1 4 3 2 1 0 2 2 2 2 2 2n nb b b b b b   L L
  • 11.
    OCTAL NUMBER SYSTEM Base 8  Two Digits: 0, 1,2,3,4,5,6,7,  Example: 01458  Positional Number System 8n-1 …. 83 82 81 80 000 0 001 1 010 2 011 3 100 4 101 5 110 6 111 7
  • 12.
    12 HEXADECIMAL NUMBER SYSTEM Base 16  Sixteen Digits: 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F  Example: EF5616  Positional Number System 0000 0 0001 1 0010 2 0011 3 0100 4 0101 5 0110 6 0111 7 1000 8 1001 9 1010 A 1011 B 1100 C 1101 D 1110 E 1111 F 1 4 3 2 1 0 16 16 16 16 1616n L
  • 13.
    CONVERSION TABLE BINARY,OCTAL, DECIMAL AND HEXADECIMAL
  • 14.
  • 15.
    1.2 CONVERSION OFBASE 1.2.1 Decimal to Binary, Octal and Hexadecimal 1.2.2 Binary to Decimal, Octal and Hexadecimal 1.2.3 Octal to Binary, Decimal and Hexadecimal 1.2.4 Hexadecimal to Binary, Octal and Decimal
  • 17.
    1.2.1 DECIMAL TOBINARY CONVERSION  Step 1: Divide the decimal number by 2, get the integer quotient and the remainder.  Step 2: Convert the remainder to the binary digit in that position.  Step 3: Using the integer quotient to repeat the steps until the integer quotient equals to 0.
  • 18.
    DECIMAL TO BINARYCONVERSION  (62)10=?  (43)10=?
  • 19.
    EXAMPLES 1. (78)10=? 2.(156)10=? 3.(266)10= ?
  • 20.
    DECIMAL TO FRACTIONBINARY CONVERSION
  • 21.
    DECIMAL FRACTION TOBINARY CONVERSION  (0.692)10=?  (0.188)10=?
  • 23.
    DECIMAL TO OCTAL Step 1: Divide the decimal number by 8, get the integer quotient and the remainder.  Step 2: Convert the remainder to the octal digit in that position.  Step 3: Using the integer quotient to repeat the steps until the integer quotient equals to 0.
  • 24.
    DECIMAL TO OCTAL (100)10=?  (473)10=?
  • 25.
    DECIMAL FRACTION TOOCTAL CONVERSION
  • 26.
  • 27.
    DECIMAL TO HEXADECIMAL Step 1: Divide the decimal number by 16, get the integer quotient and the remainder.  Step 2: Convert the remainder to the hex digit in that position.  Step 3: Using the integer quotient to repeat the steps until the integer quotient equals to 0.
  • 28.
  • 30.
  • 31.
  • 32.
  • 33.
    BINARY TO OCTAL For binary representation of octal number, each octal number is represented by 3 binary bits.  For example, the octal number 5 is represented by 101 while the octal 45 by 100101.
  • 34.
  • 35.
  • 36.
    BINARY TO HEXADECIMAL Start from the right-hand side by dividing the given binary digits into groups of four.  Convert each group into the hexadecimal number by applying binary to decimal conversion methods and then represent decimal value to their corresponding hexadecimal value.
  • 37.
  • 39.
  • 40.
  • 41.
  • 42.
  • 43.
  • 45.
  • 47.
  • 48.
  • 50.
    1.3 FLOATING POINTNUMBER  very large integer number, storage problem  Fixed point number means the fractional point(decimal point)  Floating point numbers are also called as the real numbers.  So representation of such number in floating form which have both integer and fraction parts. It uses power 10.  Parts of floating point number: 1. Mantissa II. Exponent  Mantissa: It holds the main digits of floating point  Exponent: It defines where the decimal point should be placed  Example  Only the mantissa and the exponent are stored. The base is implied (known already) As it is not stored this will save memory capacity
  • 51.
    A 32 BITFLOATING POINTNUMBER Sign Exponent Mantissa 1bit 8 bits 23 bits