Presentation is loading. Please wait.

Presentation is loading. Please wait.

What is a Computer ? Computers are Electronic Machines that process (performs calculation and manipulation) Data under the control of Set of Instructions.

Similar presentations


Presentation on theme: "What is a Computer ? Computers are Electronic Machines that process (performs calculation and manipulation) Data under the control of Set of Instructions."— Presentation transcript:

1 What is a Computer ? Computers are Electronic Machines that process (performs calculation and manipulation) Data under the control of Set of Instructions. + -   store compare 1234567890 ABCDEF…. !@#$%^& If (x>0) y=x+5; cout<<“Hello”;

2 What is a Computer ? Computers are Hardware devices that process Data under the control of Computer Program or Software.

3 What is a Computer ? Computer system: –hardware + software Hardware: –the physical components Software: –the instructions that tell the hardware what to do

4 Computing Systems Computers have two kinds of components: Hardware, consisting of its physical devices (CPU, memory, bus, storage devices,...) Software, consisting of the programs it has (Operating system, applications, utilities,...)

5 Why Computers ? Computers can do many different jobs because they are programmable, we are not. They perform computations at million times faster than us. They perform computations correctly every single time compared to us.

6 Computer Hardware All computer systems consist of similar hardware components. Hardware Components can be viewed as: –Logical Components (Generic) –Physical Components (Actual Devices)

7 Logical Hardware Components The CPU Main Memory or Primary Storage Auxiliary Memory or Secondary Storage –works as Input/Output device as well Input Devices Output Devices

8 Logical Hardware Components Arithmetic Logic Unit Control Unit Auxiliary Storage Devices Main Memory ( RAM & ROM ) Central Processing Unit ( CPU ) Input Devices Output Devices Peripherals Data Main Unit Registers

9 Logical Hardware Components Processor (CPU) –Central Processing Unit –Interprets and executes the instructions Main Memory –RAM, Temporarily holds data and instructions –ROM, Permanently holds data and instructions Auxiliary Memory –Permanently holds data and instructions I nput device(s) –mouse, keyboard, etc. O utput device(s) –video display, printer, etc. Main Memory (such as RAM) Processor (CPU) Input Devices (such as keyboard and mouse) Output Devices (such as video display or printer) Auxiliary Memory (such as floppy & hard drive)

10 Physical Hardware Components Keyboard, Mouse –Input devices Peripherals Monitor –Output device Peripherals Chassis or Box –CPU –RAM Main memory –Floppy & Hard disk drives Auxiliary memory –I/O connectors to connect other Peripherals

11 Central Processing Unit has 3 components to execute program instructions –Arithmetic/Logic Unit performs arithmetic operations, and makes logical comparisons. –Control Unit controls the order in which your program instructions are executed. –Registers holds data, memory inside the processor.

12 CPU Central Processing Unit (CPU): –the “brain” of the machine? Action_Centre –performs arithmetic and logical ML statements –measurement: speed in MHz ( megahertz, millions of clock-ticks per second ) or MIPS –examples: ·Intel Pentium, ·AMD K6, ·Motorola PowerPC, ·Sun SPARC,

13 Two Kinds of Memory Main –working area, similar to our desk –temporarily stores program and data (while program is executing) Auxiliary –permanent (more or less), similar to our bookshelf –saves program and results –includes floppy & hard disk drives, CDs, tape, etc.

14 Main Memory Unit is an ordered sequence of storage cells, each capable of holding a piece of information each cell has its own unique address the information held can be input data, computed values, or your program instructions.

15 RAM Random Access Memory (RAM) –“main” memory, which is fast, but volatile... –analogous to a person’s short-term memory. –many tiny “on-off” switches: for convenience “on” is represented by 1, “off” by 0. –each switch is called a binary digit, or bit. 8 bits is called a byte. 2 10 bytes =1024 bytes is called a kilobyte (1K) 2 20 bytes is called a megabyte (1M).

16 Memory Organization two circuit states of digital electronics correspond to 0 and 1 bit (binary digit) refers to a single 0 or 1. Bit patterns represent both the computer instructions and computer data 1 byte = 8 bits 1 KB = 1024 bytes 1 MB = 1024 x 1024 = 1,048,576 bytes

17 Main Memory Organization Bit = one binary digit –Binary digit can have only one of two values, 0 or 1 Byte = 8 bits –“Byte is Addressable” –Main memory is a list of numbered locations that contain one byte of data in each location –Number of bytes per data item may vary

18 How Many Possible Digits? binary (base 2) numbers use 2 digits: JUST 0 and 1 decimal (base 10) numbers use 10 digits: 0 1 2 3 4 5 6 7 8 9 A B C D E F hexadecimal (base 16) numbers use 16 digits: 0 1 2 3 4 5 6 7 8 9 A B C D E F

19 Disks Secondary Memory (Disk): –Stable storage using magnetic or optical media. –Analogous to a person’s long-term memory. –Slower to access than RAM. –Examples: floppy disk (measured in kilobytes) hard disk (measured in gigabytes (2 30 bytes)) CD-ROM (measured in megabytes),...

20 Auxiliary Storage Organization

21 Peripherals are input, output, or auxiliary storage devices attached to a computer –Input Devices include keyboard and mouse, microphone, camera. –Output Devices include printers, video display, LCD screens, speakers. –Auxiliary Storage Devices include disk drives, CD-ROM and DVD-ROM drives.

22 The Bus –Connects CPU to other hardware devices. –Analogous to a person’s spinal cord. –Speed measured in megahertz (like the CPU), but typically much slower than the CPU... –The bottleneck in most of today’s PCs.

23 Cache While accessing RAM is faster than accessing secondary memory, it is still quite slow, relative to the rate at which the CPU runs. To circumvent this problem, most systems add a fast cache memory to the CPU, to store recently used instructions and data. (Assumption: Since such instructions/data were needed recently, they will be needed again in the near future.)

24 Connected Together Putting the pieces together: CPU Bus Main Memory Secondary Memory cache Programs are stored (long-term) in secondary memory, and loaded into main memory to run, from which the CPU retrieves and executes their statements.

25 Software Operating Systems –DOS, MS- Windows(3.x, 95, 98, NT), MacOS, UNIX, etc. Application Software –word-processor/editor –web browser –compiler or assembler –etc.

26 OS The OS acts as the “manager” of the system, making sure that each hardware device interacts smoothly with the others. It also provides the interface by which the user interacts with the computer, and awaits user input if no application is running. Examples: MacOS, Windows-95, Windows- NT, UNIX, Linux, Solaris,...

27 OS The operating system (OS) is loaded from secondary storage into main memory when the computer is turned on, and remains in memory until the computer is turned off. RAM Disk CPU Cache Bus OS

28 Applications Applications are non-OS programs that perform some useful task, including word processors, spreadsheets, databases, web browsers, C++ compilers,... Example C++ compilers/environments: –CodeWarrior (MacOS, Win95, WinNT, Solaris) –GNU C++ (UNIX, Linux) –Turbo/Borland C++ (Win95, WinNT) –Visual C++ (Win95, WinNT)

29 Putting it all together Programs and applications that are not running are stored on disk. RAM Disk CPU Cache Bus OS App

30 Putting it all together When you launch a program, the OS controls the CPU and loads the program from disk to RAM. RAM Disk CPU Cache Bus OS App OS

31 Putting it all together The OS then relinquishes the CPU to the program, which begins to run. RAM Disk CPU Cache Bus OS App

32 The Fetch-Decode-Execute Cycle As the program runs, it repeatedly fetches the next instruction (from memory/cache), executes it, and stores any results back to memory. RAM Disk CPU Cache Bus OS App That’s all a computer does: fetch-execute-store, millions of times each second!

33 Summary A computer has two kinds of components: –Hardware: its CPU, RAM, Disk(s), … –Software, its OS, Applications, and User Programs.


Download ppt "What is a Computer ? Computers are Electronic Machines that process (performs calculation and manipulation) Data under the control of Set of Instructions."

Similar presentations


Ads by Google