You are on page 1of 97

Introduction to computers

• Accept data • Process data to convert it into info that is useful to people Controlled by programmed instructions

Based on data representation Digital Analog Hybrid

Analog represent data as a variable point along a continuous spectrum of values.Digital process data in terms of binary digits. Hybrid exhibits features both analog and digital data .

Digital computer • Accept and process data in terms of digital information such as 0’s and 1’s.PCs . EXAMPLE: . • Binary digit 1 represents presence of voltage/current and 0 represents absence of voltage/current. • Based on the instruction it can perform various task accurately and quickly. • Series of eight consecutive bits is called byte. Series of byte represent data or instruction.

Analog computer • Uses the continuously-changeable aspects of physical phenomena such as electrical. . or hydraulic quantities to model the problem being solved. mechanical.


hydraulic. or electronic . mechanical.general or specific-purpose Construction .Analog computer • Is classified based on Use .

.Analog computer • Solve a problem .procedure General analysis Data preparation Analog circuit development Patchboard programming.


. while the analog component normally serves as a solver of differential equations.Hybrid computers • Exhibits features both analog and digital data • The digital component normally serves as the controller and provides logical operations.

Hybrid computer .

Parts of computer system • • • • Hardware Software Data User .

input. output .Hardware • Mechanical devices • Able to touch and feel physically • Consists of inter connected electronic devices .control computer’s operation.

software • Set of instructions – perform tasks • System software – computer’s use to help it perform tasks and manage its own resources • Application software – enables users to perform tasks .

Data • Individual facts or pieces of info • Primary job – process tiny pieces of data I various ways – converting them to useful info .

creation of documents . etc.Users • Computer operators • Tasks .programming. • They are a part of computer because they are required to perform various functions with the help of computer. .

ESSENTIAL COMPUTER HARDWARE Computer’s hardware devices fall into 4 categories: • Processor • Memory • Input & output • Storage .

ESSENTIAL COMPUTER HARDWARE Input unit memory Output unit Control Control unit unit CPU ALU ALU .

processing. • Uses two components .PROCESSING DEVICES • Procedure that transforms raw data into useful information .processor & memory • Brain of the computer .

. • Motherboard connects processor to a hardware.passes electricity through the circuits.PROCESSING DEVICES • Organizes & carries out instructions • Consists of one or more specialized chips called microprocessors to complete or process instruction . • Executes instructions with the help of control unit (CU) & arithmetic logic unit (ALU).

controls & co-ordinates activities of all units by issuing proper commands. memory.issues proper commands to ALU. • CU . i/p& o/p unit • ALU – responsible for arithmetic and logical operation .PROCESSING DEVICES • Control unit .

• There are two types of memory: a) RAM: Random access memory b) ROM: Read only memory. .Memory devices • Memory is one or more sets of chips that store data & program instructions either temporarily or permanently.

Random access memory • Most common type • Holds data and program instructions temporarily while CPU works with them • Made up of a set of chips mounted on a small computer • Volatile • 256MB . 512MB or more .

Read only memory • Permanent storage • Non-volatile • Stores directions that help computer start up and info about hardware device .

Input and output devices • Input devices accept data & instruction from the user or from another computer • Output device return processed data to the user or to another computer system. • Mouse – important input device – used to select options from on-screen menus . • Common i/p device is keyboard .accepts letters. numbers and commands from user etc.

. memory.Input and output devices Other input devices: • Trackball & touchpad enable to draw or point on screen. • Digital camera for still images. • Scanner to copy a printed page of text or a graphic into computers. • Stylus for directly writing on the screen. • Joystick for playing games.

Input and output devices • Microphone to i/p voice or music data. . • Most common o/p devices are monitor & printer. • Touchscreen monitor can be considered as both i/p & o/p device because i/p is given by touching the screen & o/p is seen on the same screen.

Joystick .

Trackball .

Scanner .

.STORAGE DEVICES • The purpose of storage device is to hold data permanently. • These data should not be erased when system is turned off.

Differences • Distinctions between storage and memory: Capacity is more Contents are retained even when computer is shutdown Operate slower than memory chips .

STORAGE DEVICES • Two types of storage devices are: a) Magnetic storage. . b) Optical storage.

• Ex: Floppy . flat • Read/write heads are used to read data and write data • Device that holds disk is called a disk drive.MAGNETIC STORAGE • The most commonly used storage device. • The disk is a round.


DVD. • Most commonly used are CD-ROM.OPTICAL STORAGE • Devices that use lasers to read data from or write data to the reflective surface of an optical disc. • 2 types : CD-R CD-RW .

In DVD the data can be stored even more compactly.OPTICAL STORAGE • • • • CD-r which can be written only once. • Size varies from 4 GB to & 17GB. . CD-RW which can erased and rewritten. Capacity – 650 to 900 MB.

Based on usage Computers for individual users Computers for organization

Computers for individual Users
• • • • • • Desktop Workstations Notebook Tablet computers Handheld computers Smart phones

These are examples of PC

Desktop Computers
• Common – schools, colleges, homes, offices • Placed on top of a desk or table

high resolution monitor and accelerated graphics • Large memory • Greater processing speed • Suitable to perform sophisticated tasks. advanced architectural design.Work station • Powerful microprocessor • Large. engineers and animators . animation. video editing • Used by scientists.

Workstation .

5 by 11 inch Less weight – less than 8 pounds Can operate on AC power or batteries Portable – mobile computers .Notebook computers • • • • • Laptop computers Small size – 8.

Tablet PC • Similar to notebook PC but lighter and accept input from special pen (stylus or digital pen) • Portable • Special software and microphone – accept input user from user’s voice • Fold out keyboard – transformed to note book PC • Specialized versions of standard programs – connect to network .

Tablet PC .

displaying telephone numbers and addresses. keeping track of dates or agendas • Can be connected to larger computer to exchange data .Handheld PC • Fit into your hand Ex: Personal digital assistant (PDA) • Used for special applications – taking notes.


often with PC-like functionality • Advanced features – web. music players with miniature keyboard . e-mail access • Personal organizers.Smart phones • Is a mobile phone offering advanced capabilities. digital cameras.

Smart phones .

business organizations. offices • Classification Network servers Minicomputers Mainframe computers Super computers .Computers for organizations • Many users at a time • More powerful • Used by schools. colleges.

Network servers • Powerful PC with special software and equipment that enable it to function as the primary computer in the network which connects a group of PC .

Mainframe computers • Large powerful systems • Handle the processing needs of thousands of users • Handle specific set of tasks • Used in large organizations – frequent use of same data by large numbers of users. insurance companies • Mainframe’s resource accessed through terminal . Ex: banks.

no storage • Resources can also be accessed through PC .Mainframe computers • Two types of terminals Dumb – no processing or storing of data – simple input /output device Intelligent – some processing operations .

Mainframe computers .

Mainframe computers .

Minicomputers • Small size • Capabilities – between a mainframe and PC • Also known as midrange computers • Handle more input and output • Can serve inputs and outputs of hundreds of users at a time .

Minicomputers .

. mapping of human genome. modeling complex processes like nuclear-fission.Super computers • Largest and most powerful • Process huge amount of data – trillion calculations per second • Can house thousands of processors • Suitable for handling large and highly complex problems requiring extreme calculations – Ex : weather forecasting.

Super computer .

for creating new info • Home – communication. books etc. • Education – part of the curriculum • Business • Industry • Government .population. official work.Applications • Important – tools for working with info. military . taxes.

Information processing cycle • Parts of computer – convert data into useful info – performing various actions Ex: a mathematical operation on two numbers .

Information processing cycle the various activities that are followed by the computer to – – – – Receive the data Process the data based on instructions Display the data Store the data is called information processing cycle. .

Information processing cycle • The pictorial representation is as follows: .

Information processing cycle  4 parts • Input • Processing • Output • storage .

Input • Accepts data • Source – user. program .

Processing • Perform actions on the data • Based on the instructions from the user or a program .

Output • Displays the results • May appear as text. numbers or graphics optional step .

Storage • Stores the results of its processing on a disk. • Stored result can be accessed later . tape or any other storage medium.

program. • Two major categories of s/w are: a) system software b) application software .SOFTWARE BRINGS MACHINE TO LIFE • A set of instruction .drive a computer to perform specific tasks . • When a computer uses particular program it is said to be running or executing that program.

• Three basic types of system software are – Operating system – Network operating system – Utility .System software • Any program that controls the computers’ hardware • Any program that can be used to maintain the computer .runs more efficiently.

application program and the user • Its purpose is to provide an environment in which a user can execute programs in a convenient manner • Ex: Windows. LINUX.Operating system • Tells the computer how to use its own components. • Acts as an intermediary between the hardware. Solaris .

.Network operating system • Allows communication and sharing of data across a network • Controls the network operations and overseeing the network security.

Utility • Is a program that makes the computer system easier to use • Performs highly specialized functions. troubleshoot hardware problem • Perform other tasks which operating system cannot do. disk checkers. disk cleaners Anti-virus utilities . • Manage disks. • Ex: disk storage utilities – disk defragmenters.

Application software • Tells computer how to accomplish specific task. such as word processing or drawing. • Thousands of applications available for different purposes • Major categories:  Word processor  Spread sheets  Database management software  Presentations programs  Graphics programs  Multimedia software  Web design tools and web browsers  Games .

creation and presentation of slides .Application software  Word processor – creation of documents  Spread sheets – creation of numeric based documents  Database management software building and manipulating large sets of data  Presentations programs .

video.Application software  Graphics programs – designing and manipulation of photographs. movies or animation  Multimedia software – building of digital movies – incorporates audio. animation and interactive features  Web design tools and web browsers  Games .

Stored program concept • Earlier computers – specific task was accomplished – giving the instructions manually by connecting wires between various functional units. • Tedious and time consuming • More prone to error • Overcome by Stored program concept introduces by Von Newmann • Followed in all computers .

• Such machines are also known as stored program computer .Stored program concept • The set of instructions on how to perform the computation and the data required or generated by the computation are stored in a single storage structure .

• Essential features of stored program concept: • Computer has 4 functional units: input.Stored program concept • Both program and data are stored in RAM. memory and CPU consisting of CU and ALU . output. • CPU fetches the instructions from memory and executes them one after another.

Stored program concept • The program in memory – can automatically execute without manual intervention • CU performs the following operations to ensure sequential execution of series of instructions : – Fetch .Obtain the next instructions to be executed from memory – Decode .identify the action to be taken. translate to series of commands .

issue the proper command to the ALU to perform the desired operation – Store .Stored program concept – Execute .the results obtained after executing the program are stored in the memory All these activities are continuously performed – till the last instruction of the program .

Stored program concept Store memory Fetch Control unit Decode ALU Execute .

Computer languages • Different types: .Machine languages .High level language .Assembly language .

• Expressed in terms of binary digits( 0’s and 1’s) • Instruction prepared in any machine language consists of 2 parts • The first part is the command or opcode or operation code .Machine language • Early computers were programmed in machine lang • Lowest level of computer language recognized and used by the CPU.

• A short sample of machine language to perform addition of two numbers 1001011 0110 10111101110011001010 Opcode for add reg which has one number addr of mem locn containing another number .Machine language • The second part of the instruction is the operand/s or data and it tells the processor where to find or store the data or other instructions that are manipulated.

Machine language • Machine language programmers must also be familiar with the internal organization of the computer and binary code for each operation • A machine language programmer must also keep track of all the addresses of main memory locations that are referred to in the program • writing machine language program is difficult for the humans. .

.Assembly language • Low level lang • Uses abbreviations or mnemonic codes for operation codes and symbolic addresses • Machine dependent • mnemonics substitution for operation codes • symbolic addressing • Assigning and keeping track of instruction addresses – handled by computer.

Assembler. Assembly language Assembler Machine language .Translation • The mnemonics are converted into binaries .

A MOV C.Assembly language Ex: • Consider an assembly language program MOV B.A HLT • Machine language equivalent for the above assembly language is 0111001110 0111110000 1011100000 .

• Assembly language programs are not portable .Assembly language • Relatively easy • Programmer should know details of the architecture of the machine.

COBOL. BASIC. C++ etc.Higher level languages • Instructions which are written using English like language • Closer to natural language • Ex: FORTRAN. C. • Programmer – need not know the h/w details . PASCAL. PROLOG.

Higher level languages • Highly portable – machine independent • Programming – easier and flexible • the source program is translated into binary form . • C language uses a compiler as its translator to translate or compile the complete C program.compiler or interpreter. . .

• System software • Convert the program instructions from human understandable form to the machine understandable form - object code. • Entire program of the high level language -machine language. • Every programming language requires its own compiler to translate the program.


High level language


Machine language

• Convert the source program to machine language instruction line by line • The translation of the source program takes place for every run and is slower than the compiled code. • An interpreter must accompany the object code to run a program. • Programming languages BASIC and LISP use interpreters

Editor • System software – enter text into a file and do manipulation on the text • Ex: notepad • It is also used to type the source program and store program in disk. • C language uses Borland’s a IDE (Integrated Development Environment) editor in MS-DOS system and in Vi editor in UNIX system. .