زاس همانرب و رتویپماک ینابم ی یمشاه اضردومحم نارهت هاگشناد
Download
Report
Transcript زاس همانرب و رتویپماک ینابم ی یمشاه اضردومحم نارهت هاگشناد
مبانی کامپیوتر و برنامه سازی
محمودرضا هاشمی
دانشکده برق و کامپيوتر
دانشگاه تهران
پاییز 84
What are we here for?
To understand Computing systems:
What are computing systems able to do and how
well can they do it?
What are computing systems used for?
How are computing systems implemented?
How can we use them to achieve our own goals
مبانی کامپیوتر و برنامه سازی
84 پايیز, 2
Computing Machines
Computers are everywhere
General purpose: servers, desktops, laptops, PDAs, etc.
Special purpose: cash registers, ATMs, games, telephone switches,
etc.
Embedded: cars, hotel doors, printers, VCRs, industrial machinery,
medical equipment, etc.
Distinguishing Characteristics
Speed
Cost
Ease of use, software support & interface
Scalability
مبانی کامپیوتر و برنامه سازی
84 پايیز, 3
Computing Machines
All computers, given enough time and
memory, are capable of computing exactly the
same things.
=
PDA
=
Workstation
مبانی کامپیوتر و برنامه سازی
Supercomputer
84 پايیز, 4
In Practice
In practice, solving problems involves
computing under constraints.
time
cost
Weather forecast, Digital Video, ...
cell phone, automotive engine controller, ...
power
cell phone, handheld video game, ...
مبانی کامپیوتر و برنامه سازی
84 پايیز, 5
Computer History
Abacus
Babbage- 1833
Calculator- 1886
Eniac- 1946
30 Tons
72 m2
140 KW
مبانی کامپیوتر و برنامه سازی
84 پايیز, 6
Programmability
, 7پايیز 84
مبانی کامپیوتر و برنامه سازی
Operating System
, 8پايیز 84
مبانی کامپیوتر و برنامه سازی
Computer Organization
Electronic
Devices
Desired
Behavior
a very wide gap between the intended behavior and the raw
(unorganized) electronic devices.
The forerunners to modern computers attempted to assemble
the raw devices (mechanical, electrical, or electronic) into a
special purpose-built machine for each desired behavior.
مبانی کامپیوتر و برنامه سازی
84 پايیز, 9
General Purpose Computer
Electronic
Devices
computer
organization
General
Purpose
Computer
software
Desired
Behavior
We will break the gap into multiple levels and build an
island in the middle.
A general purpose computer is an island that bridges the gap
between the desired behavior (application) and the raw
material (electronic devices).
مبانی کامپیوتر و برنامه سازی
84 پايیز, 10
Computing systems and Programming
Electronic
Devices
computer
organization
General
Purpose
Computer
Hardware
Architecture
مبانی کامپیوتر و برنامه سازی
software
Desired
Behavior
Software
Programming
84 پايیز, 11
Layers of Abstraction
Natural Language
Algorithm
Program
Software
Hardware
Machine Architecture
Micro-architecture
Logic Circuits
Devices
مبانی کامپیوتر و برنامه سازی
84 پايیز, 12
Solving a problem…
Problem
Solving a problem is a systematic sequence of
transformations between layers of abstraction.
Software Design:
Algorithm
choose algorithms and data structures
Programming:
Program
use language to express design
Compiling/Interpreting:
Machine
Architecture
convert language to machine
instructions
مبانی کامپیوتر و برنامه سازی
84 پايیز, 13
Solving a problem (Cont.)
Machine
Architecture
Processor Design:
choose structures to implement ISA
Microarch
Logic/Circuit Design:
Circuits
gates and low-level circuits to
implement components
Process Engineering & Fabrication:
Devices
develop and manufacture
lowest-level components
مبانی کامپیوتر و برنامه سازی
84 پايیز, 14
Algorithms
The first and most important step in solving a
problem with computers is to transform the
natural language description into an
algorithm.
For every problem there are usually many
different algorithms. Some require fewer
steps, some are more complex, …
مبانی کامپیوتر و برنامه سازی
84 پايیز, 15
Algorithm
To qualify as an algorithm a step by step
procedure should have the following properties:
Definiteness
Effective computability
Each step is precisely stated (e.g. hot or cold lack definiteness)
Each step can be carried out by a computer (e.g. take the largest
prime number lacks it)
Finiteness
The procedure terminates
مبانی کامپیوتر و برنامه سازی
84 پايیز, 16
This course is about:
How computers work
How they are organized internally
What are the design tradeoffs
What computers consist of
How design affects programming and applications
How to solve our problems with computers
How to program our solutions in C
مبانی کامپیوتر و برنامه سازی
84 پايیز, 17
This course is NOT about
While covering all the basic components underlying a program we won’t
get into too much details about:
Underlying circuits:
Logic Circuits, VLSI
CPU structures and Assembly language
Microprocessors, and Microprocessors II
Computer Architecture
Computer Architecture, Advanced Computer Architecture
Operating Systems
Operating Systems
Problem solving
Algorithm, Data Structure, Numerical Analysis
Programming Languages
Advanced Programming
مبانی کامپیوتر و برنامه سازی
84 پايیز, 18
Course Outline
Bits and Bytes
How do we represent information using electrical
signals?
Digital Logic
How do we build circuits to process information?
Processor and Instruction Set
How do we build a processor out of logic elements?
What operations (instructions) will we implement?
مبانی کامپیوتر و برنامه سازی
84 پايیز, 19
Course Outline
Algorithm/Solving problems
How to formulate our solutions in manner suitable for
computers
C Programming
How do we write programs in C?
How do we implement high-level programming
constructs?
مبانی کامپیوتر و برنامه سازی
84 پايیز, 20
Administrative Issues
Class website:
To be determined…
Time
Sunday
Tuesday
11:00-13:00
11:00-13:00
Grading
Assignments
Every Sunday, due the next week at 14:00
Late submission penalties: -20% By Monday at 10, not accepted after that.
Although working in groups is encouraged but cheating is not tolerated.
Quiz
5%
7.5%
-0.5 for each absence
3 Projects
Midterm
Final Exam
17.5%
25%
45%
مبانی کامپیوتر و برنامه سازی
84 پايیز, 21
3 Weekly lectures by TAs
TA team:
Mohsen Vakilian
: [email protected]
Erfan Azarkhish
: [email protected]
Mahboobeh Ghorbani : [email protected]
Roshanak Zilouchian : [email protected]
Reza Shahidinejad : [email protected]
مبانی کامپیوتر و برنامه سازی
84 پايیز, 22
References
Introduction to Computing Systems from
bits &gates to C & beyond, Y.N. Patt, S. J.
Patel. McGraw-Hill 2001
The C Programming Language, Brian
Kernighan and Dennis Ritchie. Published
by Prentice-Hall. 1988.
More to be provided in class or at
www.comnete.com/computing/links.htm
مبانی کامپیوتر و برنامه سازی
84 پايیز, 23
Questions?
Best way to reach me is by email:
[email protected]
مبانی کامپیوتر و برنامه سازی
84 پايیز, 24