Upload
cody-barber
View
227
Download
0
Tags:
Embed Size (px)
Citation preview
Information representation
Base 2 positional numbering
system
Decimal to binary conversion table
111001 ?
?23
Same amount of information in more number of digits in binary form
57
10111
Simple examples
Arithmetic overflow
1 1 11 1 1 1 1
integer storing capacity
1 1 11 1 1 1 11 1 11 1 1 1 1
2027
20215
0-255
0-6553567890?
Arithmetic overflow! Should be handled!
Sign-magnitude notation
1 1 11 1 1 1 12027 26
sign bit
1 0 00 1 0 1 1170?
- 86?
1
0 positive
negative
Interpretation?ball?
Negation
1 00 0 0 1 00 + 12
0 11 1 1 0 11
Take one’s complement
Add 1
1 01 1 1 0 01 - 12
This is two’s complement technique for negation
Binary addition
1 00 0 0 1 00 + 12
1 10 0 0 0 00 + 5
0 11 1 1 1 11 - 5
12 + (- 5)
1 10 0 0 0 10 + 7
Binary addition
1 10 0 0 0 00 + 5
1 00 0 0 1 00 + 12
1 01 1 1 0 01 - 12
5 + (- 12)
0 11 1 1 1 01 - ?
1 10 0 0 0 10
- 7
Binary multiplication and division
(- 3) X 2
6 / 3
http://courses.cs.vt.edu/~cs1104/BuildingBlocks/divide.010.html
Decimal to binary conversion
47 20 21 22 23 24 25 2615
1 0
7
1
3
1
1
1
0
1
47 1
46
23 1
22
11 1
10
5 1
4
2 01
0
1
http://www.math.grinnell.edu/~rebelsky/Courses/CS152/97F/Readings/student-binary.html
Storing text / code mapping
0 0 10 0 0 0 0
0 0 00 0 0 0 1
A
B
0 0 10 0 0 0 1 C
0 1 00 0 0 0 0 D
8-bit code representation
0 0 10 0 0 0 0 0 1 00 0 0 0 0A D
AD
ASCII coding standard
American Standard Code for Information Interchange
ASCII art
Reliability of binary representation
Why not decimal, octal or ternary computers?
Nature of electrical systems: bistability!
Reliability v.s. conversion time
Binary storage devices
Two stable energy states (for 0 and 1)
States separated by large energy barrier
Sense the state without destroying information
Switch states by applying energy
How about a light switch?
bulky and slow, but OK!
Binary storage devices
Magnetic core memories (1955 – 1975)
16 cm X 16 cm
each ring stores 1 bit
128 X 128 bits = 2 KB memory
each ring is ~ 1 mm
speed up to 1 MHz
non-volatile storage
Binary storage devices
Transistor memories
transistor
Integrated Circuit
extremely small
extremely fast
extremely cheap
Binary storage devices
IC: Integrated Circuits (1950’s)
SSI: Small-Scale Integration (1960’s) (10’s)
MSI: Medium-Scale Integration (1960’s) (100’s)
LSI: Large-Scale Integration (1970’s) (1000’s)
VLSI: Very-Large-Scale Integration (1980’s) (millions of transistors)
ULSI: Ultra-Large-Scale Integration (> 1M)
Attacking the complexity problem
WSI: Wafer-Scale Integration (1980’s)
Binary storage devices
Extreme intregration techniques
SOC: System-On-Chip Design (today)
FPGA: Field Programmable Gate Arrays (today) (ten thousands of LSI circuits)
Summary
• What is binary representation?
• Why is it suitable to be used in computers?
• How is it realized? (abstract level)
References
• An Invitation to Computer Science, 1st Edition (1995) (Schneider & Gersting) (Section 4.2)
• Wikipedia & Google
September, 2006