Trends and Computer Basics CS 1 Introduction to Computers and Computer Technology

advertisement
Trends and Computer Basics
CS 1 Introduction to Computers and Computer
Technology
Rick Graziani
Spring 2015
Computer Science
•
Computer Science: The discipline that seeks to build a
scientific foundation for such topics as:
– computer design
– computer programming
– information processing
– algorithmic solutions of problems
Rick Graziani graziani@cabrillo.edu
2
Role of Algorithms
Hardware
Software
Programming
Program
Algorithm
•
•
•
•
•
Algorithm: A set of steps that defines how a task is performed
Program: A representation of an algorithm
Programming: The process of developing a program
Software: Programs and algorithms
Hardware: Equipment used to input information (data) and output the
results of the programs, algorithms.
Rick Graziani graziani@cabrillo.edu
3
An algorithm for a magic trick
Rick Graziani graziani@cabrillo.edu
4
History of Algorithms
•
•
•
The study of algorithms was originally a subject in
mathematics.
Early examples of algorithms
– Long division algorithm
– Euclidean Algorithm
Let’s take a look at Euclidean Algorithm
– Just to see that YOU can do this stuff!
Rick Graziani graziani@cabrillo.edu
5
The Euclidean algorithm
• Euclidean algorithm (also called Euclid's
algorithm) is an algorithm to determine the
greatest common divisor (GCD) of two
elements.
– One of the oldest algorithms known,
dating back to the ancient Greeks.
Euclid, 300 BC, "The Father of
Geometry“ was a Greek
– Greatest common divisor (GCD): The
mathematician
largest positive integer that divides
both numbers without remainder
– I.e. The largest number that can go
into two numbers evenly.
• Examples:
– 15 and 6, the GCD is 3
• 15 / 3 = 5
6/3=2
– 48 and 40, the GCD is 8
• 48 / 8 = 6
40 / 8 = 5
Rick Graziani graziani@cabrillo.edu
Euclid 200 ton dump truck
6
The Euclidean algorithm
Step 1:
• M = 15, N = 6
Step 2:
• M/N
• 15 / 6 = 2, R = 3
Step 3:
• R <> 0
• M = 6, N = 3
Step 2:
• M/N
• 6 / 3 = 2, R = 0
Step 3
• R=0
Greatest common divisor: N = 3
Rick Graziani graziani@cabrillo.edu
7
The Euclidean algorithm
Step 1:
• M = 48, N = 40
Step 2:
• M/N
8
48 / ___
40 = __,
1 R = __
• ___
Step 3:
• R <> 0
40 N = __
8
• M = ___,
Step 2:
• M/N
8 = __,
• ___
40 / ___
5 R = __
0
Step 3
0
• R = __
8
Greatest common divisor: N = _
Rick Graziani graziani@cabrillo.edu
8
Origins of Computing Machines
Windows Abacus 
Pascal’s mechanical calculator - 1645
• Early computing devices
– Abacus: positions of beads represent numbers
– Gear-based machines (1600s-1800s)
• Positions of gears represent numbers
• Blaise Pascal, Wilhelm Leibniz, Charles Babbage
Rick Graziani graziani@cabrillo.edu
9
Babbage’s Difference Engine
Part of the Difference Engine (below)
Replica of Difference Engine (right)
•
•
Babbage is credited with inventing the first mechanical computer that
eventually led to more complex designs.
The first difference engine was composed of around 25,000 parts, weighed
fifteen tons (13,600 kg), and stood 8 ft (2.4 m) high. Although he received
ample funding for the project, it was never completed. (Wikipedia)
Rick Graziani graziani@cabrillo.edu
10
Early Data Storage
• Punched cards
– First used in Jacquard Loom (1801) to store patterns for weaving
cloth
– Storage of programs in Babbage’s Analytical Engine
– Popular through the 1970’s
Rick Graziani graziani@cabrillo.edu
11
Jacquard loom
• The Jacquard loom was the first machine to use punch cards to
•
•
control a sequence of operations.
Did not do computation, but important in history of computer science.
The ability to change the pattern of the loom's weave by simply
changing cards
– An important conceptual precursor to the development of computer
programming. (Wikipedia)
Rick Graziani graziani@cabrillo.edu
12
Augusta Ada Byron
• Augusta Ada King, Countess of
•
•
•
Lovelace (1815-1852)
Mainly known for having written a
description of Charles Babbage's
early mechanical general-purpose
computer, the analytical engine.
She is also known as the "first
programmer".
The computer language Ada, created
by the U.S. Defense Department,
was named after Ada Lovelace.
Rick Graziani graziani@cabrillo.edu
13
Early Computers
• Here is a brief overview of some of the early computers and trends in
computing.
Rick Graziani graziani@cabrillo.edu
14
First Generation – Vacuum Tubes
•
1930’s – Vacuum tubes were used as electronic circuits
or electronic switches.
Rick Graziani graziani@cabrillo.edu
15
First Generation – Vacuum Tubes
• First electronic digital computer built by Konrad Zuse, who developed
•
his first machine, the Z1, in his parents' living room in Berlin in 1938.
Another early digital computer was built by Dr. John Atanasoff and his
assistant Clifford Berry, known as the ABC (Atanasoff Berry
Computer) built at Iowa State University during 1937-42.
Rick Graziani graziani@cabrillo.edu
16
1946 - ENIAC
• First large-scale electronic digital computer was ENIAC (Electronic
•
•
•
Numerical Integrator and Calculator)
30 feet long, 8 feet wide, and 8 feet high
3 additions every second, (incredibly slow by today’s standards).
http://www.youtube.com/watch?v=VAnhFNJgNYY
Rick Graziani graziani@cabrillo.edu
17
1946 - ENIAC
• Grace Hopper, one of the first
•
•
programmers on the ENIAC and
the developer of the programming
language COBOL, says, “It was
the first machine that assisted the
power of man’s brain instead of
the strength of his arm.”
ENIAC was developed long before
the days of silicon chips or
microchips, even before the
transistor was invented.
Like ABC, ENIAC was made up of
vacuum tubes, over 18,000 of
them!
Rick Graziani graziani@cabrillo.edu
18
1951- UNIVAC 1
•
•
•
1951 the first commercially available computer was developed, the UNIVAC I
(UNIVersal Automatic Computer) using vacuum tubes
3,000 additions every second.
In 5 years we were going a thousand times faster.
• http://www.youtube.com/watch?v=FMXT4f8C63A
Rick Graziani graziani@cabrillo.edu
19
1951- UNIVAC 1
• Rear Admiral Grace Hopper, USN, with other programmers.
• Photo taken, August 13, 1957
Rick Graziani graziani@cabrillo.edu
20
Second Generation – Transistors
•
•
1947 - Walter Brittain and Willaim Shockley invented the
transistor at Bell Laboratories
Replaced the vacuum tube as an electronic switch
Rick Graziani graziani@cabrillo.edu
21
1954 - TRADIC
•
•
•
•
TRADIC (TRAnsistorized Airborne DIgital Computer)
800 transistors.
First computer system to completely use transistors
First computer to be successfully operated in an aircraft, an
environment which was hostile to previous computer systems.
Rick Graziani graziani@cabrillo.edu
22
Second Generation - Transistors
Transistors were:
• Smaller
• Faster
• More reliable
• Less expensive
Rick Graziani graziani@cabrillo.edu
23
Third Generation – Integrated Circuits
• 1959, Jack Kirby and Robert Noyce at Fairchild Semiconductor (who
•
•
•
was later to become the cofounder of Intel Corp.) developed the first
integrated circuit (silicon chip or microchip).
An integrated circuit (IC) is a system of interrelated circuits packaged
together on a single sliver of silicon.
It is a way of placing multiple (millions) transistor devices into as single,
smaller device, the “microchip.”
http://www.youtube.com/watch?v=aWVywhzuHnQ&feature=related
Rick Graziani graziani@cabrillo.edu
24
1960 – IBM 360
•
•
1 addition every billionth of a second (nanosecond), or a
billion additions every second
http://www.youtube.com/watch?v=1OdRHImbPug
Rick Graziani graziani@cabrillo.edu
25
Third Generation – Integrated Circuits
ICs, chips, were:
• Smaller
• Faster
• More reliable
• Less expensive
Rick Graziani graziani@cabrillo.edu
26
Fourth Generation - Microprocessor
•
•
•
A microprocessor is a Central Processing Unit (CPU) on
a single chip.
1971, Intel Corp. introduced the first microprocessor chip.
– Intel 4004
108 kHz and contained (equivalent of) 2300 transistors
Rick Graziani graziani@cabrillo.edu
27
IBM used it for calculators not computers
•
•
Busicom desk-top printing calculator, the world’s first
commercial product to use a microprocessor.
Used the Intel 4004 CPU.
Rick Graziani graziani@cabrillo.edu
28
1975 - Altair 8800
• Ed Roberts and the
first microcomputer
or personal
computer (for the
consumer) the Altair
8800
•
http://www.youtube.c
om/watch?v=vAhp_L
zvSWk
Rick Graziani graziani@cabrillo.edu
29
MITS Altair 8800
•
•
Microcomputer - a
computer which has a
microprocessor.
Used the Intel 8080
Microprocessor
Rick Graziani graziani@cabrillo.edu
30
Microprocessors
Rick Graziani graziani@cabrillo.edu
31
Trends
• Faster
• Smaller
• More reliable
• Less
•
Rick Graziani graziani@cabrillo.edu
expensive
Easier to use
32
Personal Computers
•
•
We will see a series of videos, Triumph of the Nerds, which
does a great job in showing the evolution of the PC
industry.
Here is a brief introduction for now.
Rick Graziani graziani@cabrillo.edu
33
Computer Basics
Rick Graziani graziani@cabrillo.edu
34
Terms and Acronyms
•
To learn Information
Technology (IT) is to learn
the language of acronyms
and terms…
•
WYSISYG (pronounced
WHIZ-zee-wig)
“What You See Is What You
Get”
GUI: Graphical User Interface
Rick Graziani graziani@cabrillo.edu
35
What is a computer?
•
A computer is a electromechanical device which can be
programmed to change (process) information from one
form to another.
– Do exactly as they are told.
– Digital devices: Understand only two different states
(OFF and ON)
Rick Graziani graziani@cabrillo.edu
36
Computers are everywhere
Rick Graziani graziani@cabrillo.edu
37
Rich’s computers at his house
Rick Graziani graziani@cabrillo.edu
38
Traditional Types of Computers
• General purpose computers
–Mainframe
–Minicomputer
–Microcomputer (Personal Computer)
Rick Graziani graziani@cabrillo.edu
39
Traditional Types of Computers
• Mainframe
Computers
•
•
•
•
•
•
First computers, introduced in 1950s
Used by large businesses
Typically supported hundreds or thousands of users
Very expensive
Used for very large processing tasks
IBM’s new Mainframe
– http://www.youtube.com/watch?v=LN4J4mClckA
Rick Graziani graziani@cabrillo.edu
40
Traditional Types of Computers
• Minicomputers
•
•
•
•
Typically supported hundreds of users
No longer a product line
Smaller and less expensive than mainframes
The real difference is relative in terms of price, power, marketing.
Rick Graziani graziani@cabrillo.edu
41
Traditional Types of Computers
•
•
Small, self-contained computers
with their own CPUs
Uses a microprocessor, a CPU
(Central Processing Unit) on a
single chip.
Rick Graziani graziani@cabrillo.edu
42
Personal Computer
• Desktop computers
• Laptop computers
• Tablets
• Smart Phones
Rick Graziani graziani@cabrillo.edu
43
Embedded Computers
•
•
•
•
Embedded computers – Computers found
inside consumer goods in order to enhance
their function.
Cars today might have as many as 50
microprocessors on them.
Some of the reasons for this increase in the
number of microprocessors are:
– Meet emissions and fuel-economy
standards
– Advanced diagnostics
– Reduction of the amount of wiring in cars
– New safety features
– New comfort and convenience features
Sensors, wearables, medical devices, and
more
Rick Graziani graziani@cabrillo.edu
44
Special Purpose Computers
• Special purpose or dedicated computers – A device with a specific
•
purpose such as game system or information kiosk.
ATM Skimming: http://www.youtube.com/watch?v=m3qK46L2b_c
Rick Graziani graziani@cabrillo.edu
45
Computer is Hardware and Software
Rick Graziani graziani@cabrillo.edu
46
Hardware versus Software
•
•
Hardware = The
physical components
that make up a
computer system.
– More in a
moment…
Much more on all of
these items in later
presentations!
Rick Graziani graziani@cabrillo.edu
47
Hardware versus Software
•
Software = The
programs (instructions)
that tell the computer
what to do.
– System Software
– Application Software
– Stored on a storage
media such as hard
disk, CD-ROM, floppy
disk, tape, etc.
– More later…
Rick Graziani graziani@cabrillo.edu
48
Hardware Components
•
This is just an overview, more later…
Rick Graziani graziani@cabrillo.edu
49
Hardware Components
INPUT
Know these!
Rick Graziani graziani@cabrillo.edu
SYSTEM UNIT
OUTPUT
PERMANENT
STORAGE
50
The Processor
Let’s open the box!
Rick Graziani graziani@cabrillo.edu
51
The Processor
circuit board = a board with
integrated circuits
(microchips)
• system board or
motherboard
• interface boards or expansion
boards
system board or motherboard
= a single circuit board with
the components which make
up the computer’s processor
for a microcomputer, including
the:
• CPU (Central Processing
Unit)
• Memory
– RAM
– ROM or ROM BIOS
• Rickexpansion
slots
Graziani graziani@cabrillo.edu
52
Rick Graziani graziani@cabrillo.edu
53
The Processor: The CPU
CPU (Central Processing Unit) = A complex collection of electronic
circuits on one or more integrated circuits (chips) which:
1. executes the instructions in a software program
2. communicates with other parts of the computer system, especially
RAM and input devices
The CPU is the computer!
Rick Graziani graziani@cabrillo.edu
54
Moore’s Law
• The number of transistors that can be inexpensively placed on an
integrated circuit (IC) increases exponentially, doubling
approximately every two years. The observation was first made by
Intel co-founder Gordon Moore in a 1965 paper (1).
• *1 - Taken from Wikipedia http://en.wikipedia.org/wiki/Moores_law
Rick Graziani graziani@cabrillo.edu
55
Input and Output Devices
INPUT
SYSTEM UNIT
OUTPUT
PERMANENT
STORAGE
Rick Graziani graziani@cabrillo.edu
56
Input Devices
•
Enter information into
a computer
• http://www.youtube.com/
watch?v=h4FJtJKTZD8
Rick Graziani graziani@cabrillo.edu
57
Output Devices
• Send information out from a PC
• Pattie Maes: Unveiling game-changing wearable tech
– http://www.youtube.com/watch?v=nZVjUKAsao&eurl=http%3A//www.orkut.com/FavoriteVideos.aspx?rl=l
s&uid=3220410101163014300&feature=player_embedded
Rick Graziani graziani@cabrillo.edu
58
System Unit - Revisited
INPUT
SYSTEM UNIT
OUTPUT
PERMANENT
STORAGE
System Unit:
• CPU (Central Processing Unit)
• Memory
– RAM
– ROM or ROM BIOS
• expansion slots
Rick Graziani graziani@cabrillo.edu
59
RAM (Random Access Memory)
RAM (Random Access Memory) = integrated circuits (chips) used to
temporarily store software (programs, instructions) and data
• “primary” storage for the CPU
• electronic switches, storing ON’s and OFF’s
Temporarily stores for the CPU:
• Software
– operating system software
– application software
• Data
– data (documents, spreadsheets, etc.)
Rick Graziani graziani@cabrillo.edu
60
RAM
Inserting RAM
RAM is TEMPORARY memory
RAM is volatile
• stores ON and OFF bits (software and data) electrically
• when power goes off, everything in RAM is lost
Rick Graziani graziani@cabrillo.edu
61
RAM: Speed
Why does the CPU use RAM?
• The CPU is very FAST!
• The CPU needs the instructions (software) and data as quickly as
possible
• If the CPU has to wait, so does the user
Why doesn’t the CPU use permanent storage like disk drives?
• Too slow
• EXAMPLE: Spellchecker
Rick Graziani graziani@cabrillo.edu
62
RAM: Capacity
The amount of RAM determines:
• What software and data the user can work on
• How much software and data the user can work with
• Most new computers have at least 2 GB and that is steadily increasing
“out of memory” error message from the Operating System
The more complex and sophisticated the software, the more instructions
that software contains, which means larger software files.
Rick Graziani graziani@cabrillo.edu
63
ROM (Read Only Memory)
ROM (Read Only Memory) = integrated circuits (microchips) that are used
to permanently store start-up (boot) instructions and other critical
information
Read Only = information which:
• Cannot be changed
• Cannot be removed
• Cannot be appended (added to)
• Fixed by manufacturer
Rick Graziani graziani@cabrillo.edu
64
ROM (Read Only Memory)
ROM is sometimes known as ROM BIOS (Basic Input Output System
software)
ROM permanently contains:
• start-up (boot) instructions
• instructions to do “low level” processing of input and output devices,
such as the communications with the keyboard and the monitor
Firmware = software program which is stored permanently on a
microchip, such as the software on the ROM chip
Rick Graziani graziani@cabrillo.edu
65
Storage Devices
INPUT
SYSTEM UNIT
OUTPUT
PERMANENT
STORAGE
• Storage Devices:
– Floppy disks (obsolete)
– CD-ROMs, DVDs (becoming obsolete)
– Hard disks and solid state drives (SDD)
– Zip / Rev disks (obsolete)
– Tape drives
– Network drives
– Storage Area Networks
Rick Graziani graziani@cabrillo.edu
66
Computer Performance
•
•
•
CPU speed (and type)
Amount of RAM (and
speed)
Hard disk capacity
Rick Graziani graziani@cabrillo.edu
67
Software
•
•
System Software
Application Software
Rick Graziani graziani@cabrillo.edu
68
Application Software
•
•
•
Performs specific tasks:
– Word processing
– Calculations
– Information storage and
retrieval
– Accounting
Cannot function without the
OS (Operating System)
Written for a specific
operating system and
computer hardware.
Rick Graziani graziani@cabrillo.edu
69
Operating System Software
•
•
Loads automatically when
you switch on a computer
Main roles:
– Controls hardware and
software
– Permits you to manage
files
– Acts as intermediary
between user and
applications
Rick Graziani graziani@cabrillo.edu
70
Operating System Software
Software which manages the overall operation of the
computer system including:
• hardware (CPU, RAM, I/O)
• security
• system interface
• application interface
Rick Graziani graziani@cabrillo.edu
71
GUI – Graphical User Interface
Windows 3.1
Windows
95/98/XP
Rick Graziani graziani@cabrillo.edu
72
GUI – Graphical User Interface
MAC OS
UNIX/LINUX with
X-Windows
Rick Graziani graziani@cabrillo.edu
73
CLI – Command Line Interface
• No GUI
• MS DOS / Command Prompt
• Linux / Unix
Rick Graziani graziani@cabrillo.edu
74
CLI – Command Line Interface
Rick Graziani graziani@cabrillo.edu
75
WordStar on DOS
Rick Graziani graziani@cabrillo.edu
76
Putting it altogether!
•
•
•
Booting up the computer
Creating and saving a word processing document
Shutting down the computer
Rick Graziani graziani@cabrillo.edu
77
CPU
RAM
1 GB
ROM
Hard Disk Drive
Operating System Software
“The kernel”
Application Software
MS Word
User data (information)
0
Rick Graziani graziani@cabrillo.edu
78
Personal Computers
•
Review of Part 1...
Rick Graziani graziani@cabrillo.edu
79
1975 - Altair 8800
• Ed Roberts and the
first microcomputer
or personal
computer (for the
consumer) the Altair
8800
•
http://www.youtube.c
om/watch?v=vAhp_L
zvSWk
Rick Graziani graziani@cabrillo.edu
80
1972 - Xerox Alto
•
•
•
•
•
Xerox Alto – first
microcomputer.
Developed at Xerox
PARC (Palo Alto
Research Center)
Not for consumer
market.
1981 – Xerox Star
Xerox executives “just
didn’t get it”.
Rick Graziani graziani@cabrillo.edu
81
1976 - Apple I
•
•
Steve Jobs and Steve Wozniak developed the Apple I
microcomputer in their basement.
Though it was a flop, its successor became the first
popular home computer
Rick Graziani graziani@cabrillo.edu
82
1977 – Apple II
Rick Graziani graziani@cabrillo.edu
83
Others from 1977 - 1981
Commodore
PET 2001
Kaypro
Osbourne
Tandy TRS-80
Rick Graziani graziani@cabrillo.edu
84
Others from 1977 - 1981
Texas Instruments
Atari
Timex Sinclair
Rick Graziani graziani@cabrillo.edu
IMSAI
85
1981 – IBM PC
•
•
What everyone was waiting for, or fearing…
“Open Architecture” and IBM
Rick Graziani graziani@cabrillo.edu
86
1984 – Apple Macintosh
Rick Graziani graziani@cabrillo.edu
87
1985 – Microsoft Windows 1.0
Rick Graziani graziani@cabrillo.edu
88
1987 – IBM PS2 and OS2
•
•
Closed architecture (similar to Apple)
Never made it.
Rick Graziani graziani@cabrillo.edu
89
Trends and Computer Basics
CS 1 Introduction to Computers and Computer
Technology
Rick Graziani
Download