Top Banner
DATA REPRESENTATION IN COMPUTERS BINARY REPRESENTATION OF DATA
26

Data representation in computers

Jul 15, 2015

Download

Technology

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Data representation in computers

DATA REPRESENTATION IN

COMPUTERS

BINARY REPRESENTATION

OF DATA

Page 2: Data representation in computers
Page 3: Data representation in computers

•Bit - a fundamental unit of

information having just two

possible values, as either of the

binary digits 0 or 1.

•Byte - a unit of digital information

in computing and

telecommunications that most

commonly consists of eight bits.

Page 4: Data representation in computers

DIGITAL REPRESENTATION•Within a computer, information is

represented and stored in a

digital binary format.

• The term bit is an abbreviation of

binary digit and represents the

smallest piece of data.

• Humans interpret words and

pictures; computers interpret

only patterns of bits.

Page 5: Data representation in computers

NUMBERING SYSTEMS

•Number System Base Symbols used

• Binary 2 0,1

•Octal 8 0,1,2,3,4,5,6,7

•Decimal 10 0,1,2,3,4,5,6,7,8,9

•Hexadecimal 16

0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F

where A = 10; B = 11; C = 12; D =

13;

Page 21: Data representation in computers

Use this method to convert

from any base to decimal. Doubling is

used because the given number is of

base 2. If the given number is of a

different base, replace the 2 in the

method with the base of the given

number. For example, if the given number

is in base 37, you would replace the "x 2"

with "x 37". The final result will always be in decimal (base 10).

Page 22: Data representation in computers

PRACTICE

1. 110100012

2. 110012

3. 111100012

Page 23: Data representation in computers

CONVERT DECIMAL NUMBERS TO BINARY

• Example:

25

25/2

12/2

6/2

3/2

1/2

25 = 11001

Quotien

t

12

6

3

1

0

Remaind

er

1

0

0

1

1

Page 24: Data representation in computers

CONVERT DECIMAL NUMBERS TO BINARY

Checking:

1 1 0 0 1 multiplier

16 8 4 2 1 equivalents

16 8 0 0 1 results16+8+0+0+1 = 25

Page 25: Data representation in computers

•Direction: Convert the decimal

numbers shown below to binary.

Perform checking to verify

answers.

1) 19

2) 28

3) 37

Page 26: Data representation in computers