Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
7 views11 pages

Chapter-2 Data Representation

Uploaded by

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

Chapter-2 Data Representation

Uploaded by

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

Data Representa-

tion
Introduction
In Digital Computer, data and instructions are stored in computer memory
using binary code (or machine code) represented by binary digits 0’s and 1’s
called BITS.

The data may contain digits , alphabets or special characters which are
converted to bits which are understandable by the computer.

The Number System uses well defined symbols called digits.

Number System is classified into two types. They are:


1. Non-Positional number system
2. Positional Number system
Non-Positional Number System

The Non-positional number system consists of different symbols


that are used
to represent numbers.

Example: Roman Number System: for 1-I, 2- II, 3-III etc..

This Number System cannot be used effectively to perform arith-


metic operations.
Positional Number System

Many Number System are in use in digital technology that represent the digits
in various forms.
The most common are:

1. Decimal Number System


2. Binary Number System
3. Octal Number System
4. Hexadecimal Number System
Decimal Number System (Base 10)
It is the most widely used number system.
The decimal number system consists of 10 digits from 0 to 9.
The decimal system also called the base-10 system because it has 10 digits.
A number system which uses digits from 0 to 9 to represent a number with base 10 is
the decimal system number.

Example:
(92)10 = 9×101+2×100
(213)10 = 2×102+1x101+3x100

Here 2 is aclled Most significant digit(MSD) and 3 is called least significant digit(LSD)

Note: The decimal numbers which have digits present on the right side of the decimal (.)
denote each digit with decreasing power of 10.
Binary Number System (Base 2)
Computers can understand only two conditions “On” and “Off” i.e 1 and 0.
The binary number system deals with the study of 0s and 1s.
A binary number system represents a number with the base 2, by using
the digits 1 and 0. As it uses only two digits 0 and 1 and has a base of 2, it is
called binary.
All electronic devices use a binary number system in their electronic cir-
cuit. The input 0 indicates the “OFF” state and the input 1 indicates the “ON”
state. Because of these implementations binary number systems are used in
modern computer technology.
Each digit is referred to as a bit.
A single binary digit is called a “Bit”.

Example: 10101 is a five-bit binary number


How to Calculate Binary Numbers
For example, the number to be operated is 1235.
Thousands Hundreds Tens Ones

1 2 3 5

This indicates,

1235 = 1 × 23 + 2 × 22 + 3 × 21 + 5 × 20
Octal Number System (Base 8)

A number system which has its base as ‘eight’ is called an Octal number sys-
tem. It uses numbers from 0 to 7.
Example:

2158 = 2 × 82 + 1 × 81 + 5 × 80
= 2 × 64+ 1 × 8 + 5 × 1 = 128 + 8 + 5
= 14110
Hexadecimal Number System (Base 16)
In the hexadecimal number system, the numbers are represented with
base
16.
It is also pronounced sometimes as ‘hex’. Just like the binary number, oc-
tal
number and decimal number whose base representation are 2, 8 and 10,
respectively, the hexadecimal conversion is also possible which can be repre-
sented in a table.

Applications of Hexadecimal Number System:

1. To specify memory addresses


2. To represent colour codes.
Hexadecimal Number list
Decimal um- 4-bit Binary Hexadecimal
bers Number Number
0 0000 0
1 0001 1
2 0010 2
3 0011 3
4 0100 4
5 0101 5
6 0110 6
7 0111 7
8 1000 8
9 1001 9
10 1010 A
11 1011 B
12 1100 C
13 1101 D
14 1110 E
15 1111 F
Decimal=2
Decimal to binary
1x2¹+0x2º
2+0
2
(10)₂
Decimal=4
1x2²x0x2¹+0x2º
4+0+0
4
(100) ₂

You might also like