Title: Metamorphosis of Information
1Metamorphosis of Information
- A chess board diagram
- Satellite photos of the surface of Mars
- The fingerprint files of a police department
- The value of PI ( ) to 100,000 decimal places
- The fuel capacity of a Boeing 747
- Your name and address
- The script of Gone with the Wind
- A Bach fugue in 4 parts
- A Tarzan yell
- A computer program
- A recipe for Quiche Lorraine
2Metamorphosis of Information
- In this chapter
- What kinds of things can be stored in the
computer? - How does the computer deal with sound, pictures,
word processing documents, numbers, and programs? - What should you look for when picking out a
storage device, are they all the same? - What types of storage devices are out there?
3What Is Information?
- The five types of information that are the only
types the computer commonly manipulates - Visual (pictures)
- Numeric (numbers)
- Character (text)
- Audio (sound)
- Instructions (programs)
4What Is Information?
- Before the computer can use any type of
information, it must be stored in the computers
memory. - Problem How is information stored within the
computer? - Information is stored in numerical form within
the computer - Modern computers work in a system of numbers
called binary numbers
5What Is Information?
- Binary numbers
- Similar to familiar decimal system.
- Uses only two symbols 0 and 1.
- The choice of using binary numbers is dictated by
cost and reliability. - Binary circuits
- Electronic circuits are cheapest and most
reliable if they only assume two states or
conditions. - These binary circuits have only two states, ON or
OFF.
6Representation of Numbers
- Binary numbers use only two symbols 0 and 1.
- How can more than two possibilities be
represented? - A three light system can have up to eight
combinations. Each combination can represent a
code.
7Representation of Numbers
- Binary equivalents of the numerals 0 to 7.
0 000 1 001 2 010 3 011 4 100 5 101 6 110 7 111
Binary numerals
8Representation of Numbers
100s 10s 1s
312 3 1 2 (3x 102 ) (1x101)
(2x100) (3x100) (1x10) (2x1)
300 10 2
9Representation of Numbers
4s 2s 1s
101 binary 1 0 1 (1x 22 )
(0x21) (1x20) (1x4) (0x2)
(1x1) 4 0 1
5 101 binary 5 in decimal
10Representation of Numbers
- Translate 10011 binary into a decimal number.
1. Place the base two numerals under the
place values.
2. Multiply through by the place values.
3. Add up the column for the decimal
number.
24 23 22 21 20 16 8 4 2 1 1 0 0 1 1
24 23 22 21 20 16 8 4 2 1 1 0 0 1 1
1x1
1x2
0x4
0x8
1x16
1 2 0 0 16 19
10011 binary 19 in decimal
11Representing Symbols and Text
- Each letter and symbol in a text document must be
translated into a binary number for storage in
the computer. - Standardized means of storing these codes
- ASCII (American Standard Code for Information
Interchange) - EBCDIC (Extended Binary Coded Decimal Interchange
Code)
12Representing Pictures
- Pictures must be translated into a binary format
for storage in the computer. - The picture is broken down into small elements.
- These elements are called Pixels (Picture
Elements). - Digitizer
- A device that converts a picture into a binary
format for storage in the computer. - Examples of digitizers scanner, digital camera.
13Representing Pictures
- Digitized picture of a tiger.
14Representing Pictures
- Black and white pixels are either 0 or 1.
0001000000000000000000000000000000000000010101 010
0000000000000100000000000000000000000000101 011000
0000000000100000000000000000000000000011 101010100
0000000010000000000000000000000000011 100100000000
0000101100000000000000000000000101 010001000000000
0011110000000000000000000000111 010010010000000001
1111010101011100000000000011 000100000000000011110
1110111111101000000001011 000010100100000110111110
1111110110000000001111 000001010000000011111011110
1011101000000000111 000001010010001110101010101101
0000000000010111 000000101010000001110101010110101
0100000011111 000001011000000101010010000000000000
0000001110 000000000001100101010000000000000000000
0001111 000000000001011001010000000000000000000010
1111 001001010101010010010101000000000000000101111
1 1000001111110100101101110101011000000010110111 1
001001111010111111111110101101101011111111111 0110
010111110111111111111111111101111110111111 1010101
101111111111111111111111111111111111111 1010000111
011111111111111111111111111111111111 0101010011111
111111111111111111111111111111111 0110000101011111
111111111111101111110011110101 0101111011111111111
111111111111011010101110101 1010101011111111111111
111010110111101111011111 0000001011111111111101011
101101001111110101010 0000001011111111111101111111
110010111101101010 0000000111111010111110111011101
001111110101010 0000000111111111111111010111111101
111110111011 0000101111101101010110000101111111111
111101011
15Representing Pictures
- Gray-Scale
- Each pixel contains a value representing some
shade of gray. - The more shades of gray possible, the more memory
will be needed. - 4 shades of gray needs 2 bits per pixel
- 00, 01, 10, 11
- 8 shades of gray needs 3 bits per pixel
- 000, 001, 010, 011, 100, 101, 110, 111
- 64 shades of gray needs 6 bits per pixel
- 000000, 000001, 111110, 111111
16Representing Pictures
- Message transmission from the Arecibo radio
telescope in Puerto Rico to other stars.
17Sound as Information
- Sounds can be reduced to numbers and stored in
its binary format within the computer. - Example of musical representation
- DARMS (Digital Alternative Representation of
Musical Scores). - Used by professional musicologists.
- A graphical system based on the position of the
symbols on the staff. - Converts each symbol to binary using the
text-based ASCII code.
18Sound as Information
- DARMS translation of musical information
19Sound as Information
- Sound information is in the form of a voltage.
Because of the variation of this voltage, sound
is produced by the speaker.
20Instructions as Numbers
- Fact
- Declarative statement of being.
- Imparts knowledge.
- Instruction
- Imperative demands action.
- Controls information or activity.
21Instructions as Numbers
- Instructions
- Must be stored within the computer before use.
- Must be stored in binary form.
- A set of binary instructions is called a program.
22Instructions as Numbers
- Word Hunt - Practical example of how Instructions
are used and stored by the computer. - In order for a computer to follow instructions
- They must be stored in the computers memory in
binary form. - If the computer recognizes the commands, it will
follow and execute the instructions. - The instructions the computer can understand are
part of an Instruction Set. - Instructions have two parts
- Action - The verb that tells the computer what to
do. - Object - The modifier telling where, how much, or
what the verb requires.
23Instructions as Numbers
- The Instruction Set for Word Hunt.
Action English Action taken number Version 1 GOTO
Turn pages (1first page of this chapter)
until at the page number indicated. 2 SELECT
Count down from the top of the page, move to
the beginning of the line indicated by the
instructions . 3 FORWARD Beginning with the
word immediately to the right of the current
position, count forward the number of
words. 4 BACKUP Beginning with the word
immediately to the left of the cursor, count
backwards the number of words indicated. 5 WRITE
word Write a copy of the current
word. 0 STOP The message is complete.
24Instructions as Numbers
- A Word Hunt program puzzle
GOTO 7 SELECT 3 FORWARD 15 WRITE word SELECT 4 FOR
WARD 1 WRITE word GOTO 6 SELECT 24 FORWARD 6 WRITE
word BACKUP 3 WRITE word STOP
25Instructions as Numbers
- The Word Hunt translated into binary code.
English Version Machine Language version
(binary) (1) GOTO 7 001 00111 (2) SELECT 3 010 0
0101 (3) FORWARD 15 011 01111 (5) WRITE word 101
00000 (2) SELECT 4 010 00100 (3) FORWARD 1 011
00001 (5) WRITE word 101 00000 (1) GOTO 6 001 00
110 (2) SELECT 24 010 11000 (3) FORWARD 6 011 00
110 (5) WRITE word 101 00000 (4) BACKUP 3 100 00
011 (5) WRITE word 101 00000 (0) STOP 000 00000
26Instructions as Numbers
Arithmetic Used for computations. Data
Movement Moves information within the
computer. Logical Makes decisions. Control Changes
order of program execution. Input/Output Moves
information into and out of the computer.
27Storage of Binary Information
- Memory differs in
- Speed (Access time) - How fast information can be
taken from or stored onto a computers memory. - Cost - Cost of medium.
- Type of Access
- Sequential - Obtained by proceeding through the
storage medium from the beginning until the
designated area is reached (as in magnetic tape). - Random Access - Direct access (as in floppy and
hard disks). - Capacity - The amount of information that can be
stored on the medium.
28Storage of Binary Information
Unit Description Approximate Size 1 bit 1 binary
digit 1 nibble 4 bits 1 byte 8 bits 1 character 1
kilobyte 1,024 bytes ?1/2 page, double spaced 1
megabyte 1,048,576 bytes ?500,000 pages 1
million bytes 1 gigabyte 1,073,741,824 bytes ?5
million pages 1 billion bytes 1 terrabyte 1
trillion bytes ?5 billion pages
29Storage of Binary Information