Download presentation
Presentation is loading. Please wait.
Published byRebecca Okaka Modified over 6 years ago
1
1 FOUNDATIONS OF COMPUTER SYTEMS 1
2
Chapter 1 Introduction of computers 2
3
Definition of a computer A computer is an electronic device that processes data into information. A computer is an electronic device that accepts user input (data) and manipulates it under influence of sets of special instructions (Program) to produce desired output (Information). 3
4
Data They are raw facts that are meaningless to the user and cannot be used to make decision e.g. numbers, letters, characters, images, etc. Data can also be defined as raw facts that are not yet organized. 4
5
Processing Manipulated or transformation of data into meaning information e.g. addition, subtraction, division, multiplication, comparisons etc. 5
6
Information Processed data. 6
7
Functional Organization of a Computer 7 InputProcessingOutput Storage
8
Electrical Components of a Computer Input devices; devices used to enter data into the computer. Examples are, the keyboard, mouse, scanner, joystick, trackball, stylus e.t.c Processor; also known as the Central Processing Unit (CPU), carries out all processing activities in the computer; it transforms data into information 8
9
Electrical Components of a Computer Storage devices; devices used to keep or store information. Examples are, the hard disk, optical disk, magnetic disks e.t.c. Output devices; devices used to display or give out information from the computer. Examples are, the printer, monitor, speakers, plotter, computer output on microform, projectors e.t.c 9
10
Typical desktop personal computer Computers come in different sizes designs but the most common is a computer referred to as a Personal Computer (PC). Personal computers are mostly used in offices, schools, business premises and at home. 10
11
System unit – this part houses the major components of a computer. Peripheral devices – they are connected to system unit via ports using cables called data interface cables that carry data and information to and from the devices. Can be an input, output, storage or other devices that add other functionalities to the computer. Ports – are socket like connectors found at the back of the system unit. 11
12
Some of peripheral devices are Keyboard – enables the user to enter data and instructions in the computer by pressing keys. Mouse – enables user to issue instructions to computer by controlling the mouse pointer displayed on screen. Monitor – enables the user to see information (output). 12
13
Parts of a Computer Software; programs or step by step instructions that tells a computer what to do. Also known as the intangible parts of a computer. Hardware; physical parts of a computer that we can touch and feel. Also known as the tangible parts of a computer. 13
14
Characteristics of a Computer Have input device Have processor Have output device Have memory Use electricity Programmable 14
15
Advantages of Computers Fast in data processing Are diligent Have large storage capacities Are automatic Are accurate Are versatile in use 15
16
Disadvantages of Computers Expensive Use electricity Breakdown just like any other machine Not intelligent Not used by everybody 16
17
Development of computers Historical development of computers can be traced back to the time human beings were struggling to invent non electronic tools that would simplify arithmetic such as Abacus and Napier's bones. 17
18
Abacus An Abacus was Chinese counting instrument which dates back to 3000 BC. The Abacas has bead-like parts that move along rods. Each bead above the middle bar stands for five units. Each bead below stands for one unit. 18
19
Analytical engine The Analytical engine was designed by English mathematician, Charles Babbage in 1832. The engine is recognized as the first real computer and Babbage as the father of computing. The left picture depicts how the analytical engine would have looked like if it was constructed. 19
20
1 st generation computer (1940-1958) These computers were huge, expensive and often broke down. They were slow compared to today’s computers, their internal storage capacity was limited. Cards were used to enter data into the computer. They used vacuum tubes to control internal operations. They were used for payroll processing and bulling e.g. IBM 650 and UNIAC. 20
21
Advantages and disadvantages of 1 st generation Advantages Vacuum tubes technology made possible the advent of electronic digital computer. These computers were the fastest calculating device at their time. Disadvantages They were too bulky. They were unreliable. Had limited memory. They generated a lot of heat. Consumed a lot of power. 21
22
2 nd generation computer (1958-1964) They used transistors for internal operations and magnetic card as a primary storage medium. They had increased storage capacity compared to first generation. They had great reduction in size and heat generation, increased speed and reliability compared to first generation e.g. IBM 1401, Honey Wall 200, CDC 1604 etc. 22
23
Advantages and disadvantages of 2 nd generation Advantages They were smaller in size compared to first generation. They more reliable. They generated less heat. They were less prone to hardware failure. Disadvantages Require air conditioning to cool them down. Required frequent maintenance. Commercial production was difficult and costly. 23
24
3 rd generation computers (1964-1970) These computers used integrated circuits, increased storage capacity more flexibility with input/output smaller size and better performance of microcomputers. It also introduced software industry operating systems e.g. IBM System 360, Burroughs B5500 etc. 24
25
Advantages and disadvantages of 3 rd generation Advantages Smaller in size. More reliable. Emitted less heat. Maintenance cost was low because hardware failure were rare. Required less power. Disadvantages Highly sophisticated technology required for the manufacture of integrated circuit. They were costly 25
26
4 th generation computers (1970-1989) These computers use large scale integrated circuit (LSIC). They have large storage capacity and work at a high speed. Introduction of microprocessor, microcomputers and supercomputers were realized e.g. IBM 3033, Burroughs B7700. 26
27
Advantages and disadvantages of 4 th generation Advantages They are smaller in size because of high component density. Very reliable. Generate neglible heat. Much faster in computational. They are not prone to hardware failure. They are portable because of their small size. Disadvantage Highly sophisticated technology required for manufacturer of LSI chips. 27
28
5 th generation computers (1990-present) This is generation is characterized by the emerging of telecommunication with computer technology. Scientists are working on this generation to bring machines with genuine I.Q. the ability to reason logically and with real knowledge of the world. The anticipated computer will have the following characteristics. It is expected to do parallel processing. It will be based on logical inference operations. It’s expected to make use artificial intelligence. 28
29
Classification of computers Physical size Super computers Mainframe Mini computers Micro computers Functionality Analog computers Digital computers Hybrid computers Purpose General purpose Special purpose Dedicated 29
30
Super computers (Physical size) They are the fastest, largest, most expensive and powerful computers. Mainly used in scientific research, simulation, weapon, analysis etc. 30
31
Mainframe (Physical size) They are less powerful and less expensive than the super computers. It finds its application in government agencies, big companies e.g. bank, hospital etc. 31
32
Mini computers (Physical size) They are physically smaller and cheaper than mainframes. They are used in research institutions, scientific laboratories etc. 32
33
Micro computers (Physical size) The smallest, cheapest and least powerful type of computers. It’s called a microcomputer because its CPU is called a microprocessor. They are used mainly in learning institutions. Types of micro computers Desktop Laptop Palm top 33
34
Types of micro computer (Desktop computer) Desktop computer – this is not portable. It’s designed to be placed on top of an office desk. 34
35
Types of micro computer (Laptop computer) Laptop computer – this is portable briefcase. Designed to be used by placing it on the lap. 35
36
Types of micro computer (Palm top computer) This is small enough to fit in the pocket and can be held in the palm when being used. 36
37
Advantages They are portable. Ruggedness – laptop computers are designed to withstand most of the rigors of travel. Display – active color screen show sharper, clearer images which prevent eye strain. Power – laptop batteries serve as built in uninterruptible power supply. Disadvantages Performance – many laptops have slower clocks speed to conserve power and also have similar memory capacity. Expandility – laptops PCs limit your expansion options. Connecting laptops have few ports and no growth potential. Security – laptops PCs are easier to steal. Display – laptops screens are limited to VGA resolution. Advantages and disadvantages of laptops 37
38
Analog computers (Functionality) Analog computers – they perform arithmetic operations and logical comparisons by measuring changes in physical magnitude e.g. speed, temperature etc. 38
39
Digital and hybrid computers (Functionality) Digital computers – their operations are based on two states namely “on” and “off” or “I” and “O”. Hybrid computers – they are computers which are built with the characteristics of both analog and digital computers. 39
40
Purpose General purpose – they are designed to be able to perform a variety of tasks. Special purpose – they are designed to serve a specific purpose e.g. robots used in industries, mobile phone for communication only etc. Dedicated – they are general purpose computers that are committed to some processing task e.g. dedicated to word processor tasks only. 40
41
Computer laboratory A computer laboratory is a room that has been specially prepared to facilitate installation of computers and to provide a safe conducive environment for teaching and learning of computer studies. 41
42
Safety precautions and practices in a computer laboratory The computer lab, just like any other laboratory, should be setup with safety precautions in mind. Safely precautions and practices can be divided into measures that are meant to protect computer and those that are meant to protect the users. 42
43
Behaviour in the computer laboratory Avoid smoking or exposing computers to dust. Smoke and dust particles can damage computer components. Avoid carrying food and beverage to computer room. Food particles may damage computer components while liquids may cause rusting and electrical shocks. Avoid unnecessary movements because you may accidentally knock down peripherals devices. Follow the correct procedure for starting and shutting down the computer. Accidents which may occur should be reported immediately. If you are not sure of how to handle or operate any piece of equipment in the laboratory please ask for assistance. 43
44
Ventilation There must be good air circulation in the computer room to avoid suffocation and overheating. Proper ventilation enables the computer to cool hence avoid damage to electronic part. 44
45
Lighting Computer room should be well light to avoid eyestrain that leads to headaches, stress and fatigue. The user may adjust the brightness of the computer monitor until the eyes feel comfortable. Also radiation filter screens may be fitted. 45
46
Protection against fire Computer room should have gaseous fire extinguisher like those filled with CO 2. Water based or powder extinguishers should be avoided because they can damage computer components. 46
47
Dust and dump control The room should be fitted with special curtains to reduce entry of dust particles. Computers also should remain covered with dust covers when not in use. Humidity should be regulated in the computer room to remain an optimum of 50%. Humidity lower than this allows static electricity to build up and cause damage to computer components. High humidity of over 70% may cause rusting of metallic parts. 47
48
Furniture The table on which a computer is placed must be strong and wide enough to hold the weight and accommodate all peripheral devices. The user’s seat must be comfortable and have a straight back rest that allows someone to sit upright to avoid muscle pains and aches. 48
49
Burglar proofing To prevent unauthorized access to the computer room the following control should be implemented. Fit strong metallic grills and locks on doors, windows. Do not welcome strangers to computer room. Install security alarms at strategic access points to alert security personal incase of break in. 49
50
Stable power supply Computers require a stable source of power. Power from main supply is not always stable and may damage computer components. To protect the computer from damage due to power instabilities, avoid connecting it directly to mains supply. Instead connect it to a special device called Uninterruptible Power Supply (UPS) then connect the UPS to main supply. 50
51
Function of UPS It regulates power from an unstable power source to the required clean stable voltage. It temporarily provides power to computer incase of a sudden power failure. 51
52
Starting up (Booting) It’s the process by which a computer loads system files into the main memory. Types of booting Cold booting – the process of switching on a computer that has been off completely by pressing the power button. Warm booting – this happens when the computer, originally on, is forced to restart by pressing the restart button on the system unit. 52
53
Shutting down a computer It is important that the user follows that e correct procedure of shutting down a computer at all time. If the procedure is not followed, then loss of data, damage of programs and computer components may occur 1. On the “Start” menu 2. Click “Shut Down” or “Turn Off Computer”. (Shut down dialog box is displayed) 3. Select “Shut Down” or “Turn Off”. 53
54
Parts of keyboard Functions keys – F1 to F12. Alphanumeric (Tying) keys – labelled A – Z, Caps lock, Enter keys, Tab key, Spacebar, backspace etc. Cursor movement (Navigation) & Editing keys – arrow keys, Page up and Page down, Home and end keys, Edit keys, Insert key, Delete Special keys – Shift, Ctrl, Alt, Esc etc. Numeric keys – 0 to 9, +, “, /, - 54
55
Using typing tutor In order to increase your typing speed and accuracy, typing software offers the lessons you need to start from using one hand while typing to becoming a proficient user. 55
56
Mouse techniques Clicking – means pressing and releasing the left mouse button once. Double clicking – pressing the left button twice in quick succession. Right clicking – pressing the right hand side mouse button once. Drag and drop – the user drags an item from one location on the screen to another. Drag – press and hold down left button and the move the mouse to the new location Drop – release the button immediately after dragging the item to the new location. 56
57
Review questions 1 1. Define the term computer? 2. State different physical parts that make up a computer. 3. Differentiate the following types of computers: A) Supercomputer and mainframe; B) Minicomputer and a PC. 4. Differentiate between a digital and on analog computer. 5. Give two reasons why smaller computers like laptops tend to be more expensive than desktop computers. 6. Which one of the following is not true about the system unit? A) It houses the CPU. B) It houses the monitor. C) It connects to all peripheral devices using ports. D) It has the computers power switch. 57
58
Answer of review questions 1 1. A computer is an electronic device that accepts user input, also referred to as data, and transforms it under the influence of sets of special instructions called programs, to produce the desired output referred to as information. 2. Monitor, system unit, mouse, keyboard, etc. 3. A). A supercomputer is larger and has more processing power and memory than a mainframe. B). A minicomputer is lager in physical size and more powerful than a PC. PC was designed to be used by one person only. 4. A digital computer processes discrete data while an analog computer processes continuous data. 5. A). The technology of producing smaller devices is expensive. B). Convenience because of their portability. 6. B 58
59
Review questions 2 1. What is a mouse in relation to computing? A) A small destructive rodent. B) A round plastic container with a tail. C) A device that controls a pointer on the screen. D) A device used for typing. 2. Why is a screen also called monitor? A) It monitors the user. B) It helps the user to track computer operations. C) It monitors system performance. D) It is a television. 3. Pick the odd one out in the list below. A) Calculator. B) Mobile phone. C) Robot D) Laptop 4. Pick the odd one out in the list below. A) Mainframe. B) Microcomputer. C) Minicomputer. D) Digital computer. 59
60
Review questions 3 1. Which of the following will be most suitable for travellers. A) Supercomputer B) Mainframe computer. C) Palmnote computer. D) Minicomputer. 2. Why is a mobile phone regarded to be a computer? A) It is electronic has a screen, keypad, memory and is programmable. B) It looks like a palmnote. C) It is portable. D) It produces tones. 3. What is meant by the term analog data. A) Data that never stops. B) Discrete data. C) Large data. D) Continuous data. 4. Which one of the following is called a microprocessor? A) The CPU of a mainframe. B) The CPU of a minicomputer. C) The CPU of a microcomputer. D) The CPU of a supercomputer. 60
61
Answer of review questions 2&3 Questions 2 C B C D Questions 3 C A D C 61
62
Review questions 4 1. Match the following generations of computers with the technology used to develop them. 1. First generationA. VLIC 2. Second generationB. Vacuum tubes 3. Third generationC. Transistors 4. Fourth generationD. Integrated circuits 2. Identify and explain at least five areas where computers are used in day to day activities. 3. What were the characteristics of first generation computers? 4. Who developed the analytical engine? 5. What is artificial intelligence? 6. Write the following initials in full: A). ENIACB).VLSIC). IC 62
63
Answer of review questions 4 1. First – Vacuum tubes Second – Transistors Third – Integrated circuits Fourth – Large integrated circuits. 2. Supermarket, airport, hospitals, offices, banks, industries, etc. 3. A). Large in physical size B). Used vacuum tubes C). Produced a lot of heat. D). Consumed a lot of power. 4. Charles Babbage. 5. Programs that make computers to mimic human intelligence. 6. ENIAC – Electronic Numeric Integrator And Calculator. VLSI – Very Large Scale Integrated. IC – Integrated Circuit. 63
64
Review questions 5 1. Using an abacus represent 5780. 2. Match the following computer application areas with the role played by computers in each case. 1. SupermarketA. Matching fingerprints 2. HospitalB. Entertainment 3. BankC. Stock control 4. HotelD. Booking rooms 5. HomeE. Analysing academic data 6. SchoolF. Manufacturing process control 7. IndustryG. Life support machines 8. Police stationH. Processing cheques 64
65
Answer of review questions 5 1. Representation of 57800 with ABACUS. 2. Supermarket – Stock control Hospital – Life support machines Bank – Processing cheques Hotel – Booking rooms Home – Entertainment School – Analysing academic data Industry – Manufacturing process control Police station – Matching fingerprints 65
66
Review questions 6-1 1. What is the name given to alternative sources of power? A) Generators B) UPS C) Power backups D) The sun 2. Which of the following will not ensure proper ventilation in a room? A) Adequate windows and doors B) Overcrowding C) Installing fans D) Air conditioning system 3. All the following are dangerous to a computer except one. Which one is it? A) Water B) Smoke C) Proper ventilation D) Dust 66
67
Review questions 6-2 4.Why must foods and beverages be kept out of the computer room? A)Because computer users should not eat. B)Because spilling of beverages may clog and destroy computer components. C)Because the smell of food is not good for the computer lab. D)Because all foods affect computers. 5.Which one of the following statement is correct? A)Opening the system unit when it is sill on. B)Using magnets in the computer room. C)Covering the computers with dust covers after shutting them down. D)Stepping on power and data cables 67
68
Review questions 7-1 1. Why are powder fire extinguishers not allowed in the computer room? A) Powder particles settle on storage devices and may scratch them during read/write operation. B) Powder is poisonous. C) It fills the room with mist. D) Powder changes to liquid when sprayed on fire. 2. All the following are functions of the UPS except one. Which one is it? A) It prevents sudden power surges to destroy the computer. B) It supplies power to the computer during blackouts and brownouts. C) It provides stable power supply (clean power). D) It can be used as the main power source for computer. 68
69
Review questions 7-2 3. Which of the following reasons are likely to cause eye strain in the computer room. A) Poor lighting B) Bright monitor C) Poor ventilation D) Antiradiation screen 69
70
Review questions 8 1. All the following are proper sitting postures while using a computer except one. Which one is it? A) Straight posture on the seat back. B) Feet firmly on the floor. C) High enough seat allowing eyes to be level with top of the screen. D) Bending the back backwards on a relaxing chair. 2. What can be done to deter illegal access to a computer room by unauthorised person? A) Burglar proof the room by reinforcing doors and weak access points. B) Welcome strangers to the room. C) Leave the room open when nobody is using it. D) Switch off security alarm when leaving the room 70
71
Answer of review questions 6,7&8 Questions6 C B C B C Questions7 A D A and B Questions8 D A 71
72
Review questions 9 1. What is booting? 2. Differentiate between cold booting and warm booting. 3. What is the difference between function keys and special PC keys? 4. Explain the various categories of keys found on a standard keyboard. 5. What makes a mouse move a pointer on the screen? 6. Explain the correct procedure for shutting down one 7. Define the following terms: A). Clicking;B). Double Clicking; C). Drag and drop;D). Right clicking; E). Mouse pointer; 72
73
Answer of review questions 9-1 1. Booting refers to process whereby a computer goes through a process of self test and preparation for use. 2. Cold booting is starting up a computer while warm booting is restarting a computer. 3. Function keys are specifically used to perform certain program specific tasks. Special purpose keys are used to give certain commands. They are mostly used in combination with other keys. 4. Alphanumeric keys, function keys, cursor movement and editing keys, special purpose keys and numeric keypad keys. 5. Moving the mouse on any direction on a flat surface. 6. Click start, turn off computer then turn off. 73
74
Answer of review questions 9-2 7. A). Clicking – pressing and releasing the left mouse button once. B). Double clicking – pressing the left hand side button twice in quick succession. C). Right clicking – pressing the right mouse button once displays a list of commands from which the user can make a selection. D). Drag and drop – this is where the user drags an item from one location on the screen to another. E). Mouse pointer – is an arrow or an object in form of a picture that is used to point on the task to be performed on the application window. 74
75
Revision questions 1 1. Explain why smoke and dust particles are harmful to a computer. 2. Explain the emerging trends in microcomputer technology in relation to size. 3. Describe the ideal environment for a computer to work properly. 4. Explain the tem system unit and name some of components found in it. 5. What is booting? Explain what happens in the computer during the booting process. 6. State one reason why a computer needs to be connected to a stable power source. 7. Give two examples of special purpose computers. 75
76
Answer of revision questions 1 1. Dust and smoke settles on storage devices scratching them during read/write operation. 2. PCs are becoming small and portable e.g. Personal Digital Assistant (PDA). 3. Free from dust, water, magnets, well ventilated rooms, medium humidity, etc. 4. This is the casing that houses the CPU and storage devices. Components in the system unit includes CPU, motherboard and storage devices. 5. Starting up a computer. Internally it first checks whether all the components are in good working condition then loads the operating system. 6. To avoid damage and lose of data. 7. Mobile phones, calculators, robots etc. 76
77
Revision questions 2 1. Why would it not be good to install water based fire extinguishers in the computer room. 2. Explain the following terms: A) Clicking the mouse, B) Right clicking the mouse, C) Double clicking the mouse, 3. What precaution would you take in the computer room in case: A) The humidity falls below normal for prolonged periods due to weather change; B) Users complain of backaches after long periods of using the computer; 4. Classify the following keyboard characters: A). A,B,C,….ZB). 0,1,2,….9C). F1, F2,….F12 D). Del, InsertE). Home, End, Page up, arrow key F). Ctrl, Shift, Alt 77
78
Answer of review questions 2 1. Water causes rusting of metallic parts and short circuits if used. 2. A). Clicking – pressing and releasing the left mouse button once. B). Double clicking – pressing the left hand side button twice in quick. C). Right clicking – pressing the right mouse button once displays a list of commands from which the user can make a selection. This list of commands is called a shortcut menu or context sensitive menu. It is called a context sensitive menu because the commands on it apply to the right-clicked item. 3. A). Install humidifiers in the room. B). Improve furniture to avoid bending when using the computer. 4. A). Alphanumeric keys B). Numeric keypad keys C). Function keys D). Editing keys E). Cursor movement keys F). Special purpose keys. 78
79
Practical activity 1 Using a typing tutor program type the text appearing in italics. in our minds, in our memory, in our concentration. In our retaining power, in our intelligence. Right from the crow of our head to the very soles of our feet. God, keep us FREE today from evil, Sin, temptations, attacks and afflictions, Fear of men, sickness, disease, doubts, anger, All calamities and from all that is not of thy Kingdom. Fill us with the gifts of wisdom, knowledge, faith, understanding, And discernment. 79
80
Practical activity 2 1. Using one of the computers in the computer laboratory, identify the visible parts of a computer and write down the following details: A) The brand name of the computer. B) The type of computer – whether desktop, laptop etc; C) The number of buttons on the mouse; D) The number of keys on the keyboard; E) Draw a diagram of the keyboard layout; F) Identify the power button on the system unit and the monitor; G) Use the buttons on the monitor to adjust its brightness. 2. In group, carefully study the computer laboratory and its arrangement. Note down the following; A) The safety precautions in place to protect users and computers; B) Users complain of backaches after long periods of using the computer. 80
81
Computer systems 81
82
Introduction Computer system refers to a collection of components that are linked to process, store and manage information. 82
83
Functional organisation of the elements The computer system is organised into three elements. Hardware – consists of the mechanical, electrical and electronic part of a computer. Software – it is a set of computer programs that guides the computer in each and every activity that happens inside the computer during data processing. Live ware – refers to users who are computer knowledge and hence can properly utilize the computer hardware and software. 83
84
Input device These are devices which accept data and pass them into the computer. Keying devices – keyboard use to type data into the computer. Pointing devices Mouse Track ball Joy stick Light pen Scanning devices – they are devices that capture data into the computer directly. 84
85
Types of keying devices 1 Flexible keyboard – is a more portable keyboard that can be folded and packed in to bag. Ergonomic board – is specially designed to provide comfort and alleviate wrist strain. 85
86
Types of keying devices 2 Keypad – is a miniature keyboard used on portable devices such as PDAs, laptops and mobile phones. Braille keyboard – is a keyboard designed for use the blind. It consists of key identified by raised dots. 86
87
This is for enter data or instructions by controlling a pointer on the screen. Mouse (Pointing device) 87
88
Trackball (Pointing device) Trackball – It uses a sphere located on top that is rotated by hand to control cursor movement. 88
89
Joy stick (Pointing device) It looks like a car gear lever which can be moved sideways, upwards, downward to no space control the position of cursor. 89
90
Light pen (Pointing device) It is a hand held pen like device that has a light sensitive point. 90
91
Classification of scanners Optical scanners – they capture data using light. Optical Mark Recognition (OMR) Optical Bar Recognition Optical Character/Image Scanner (OCR) Magnetic scanners – they capture data using magnetic technology. Magnetic Ink Character Recognition (MICR) Magnetic Stripe Recognition 91
92
Optical Mark Recognition (OMR) (Optical scanner) This scanner uses mark – sensing to scan and translate the locations of a series of pen or pencil marks into computer understandable form used in marking K.C.S.E. multiple choice exam, questionnaire etc. Application of OMR Multiple choice exam. Market research questionnaires. Payroll data entry. Traffic surveys. 92
93
Advantages and disadvantages of OMR Advantages Has low error rates. Conspicuous errors are easily corrected. Data captured at source, hence minimising amount of manual work. Disadvantages Mark readers are relatively slow. Verification of marked data is difficult. Not widely used in business. 93
94
Optical Bar Recognition (OBR) (Optical scanner) They scan and translate a bar code into machine understandable mode. Used in supermarket, wholesale shops etc. Application of OBR On labels and on shelves for stocktaking. Printed on shop goods e.g. supermarkets. In libraries. 94
95
Advantages and disadvantages of OBR Advantages Bar codes can be printed by normal printing methods. The type of item or price does not have to be repeatedly written/typed. Disadvantages Bar codes can only be read machines. Only numbers can be coded in this way. They are relatively fixed, so they are unsuitable for recording prices which can frequently change. 95
96
Optical Character/Image Scanner (OCR) (Optical scanner) It is used to scan characters and images i.e. can be used to scan real objects. Application of OCR Used in billing 96
97
Advantages and disadvantages of OCR Advantages Data is captured at source hence errors are limited. It’s an easier method to use. Document design is less complicated. Characters can be read by people. Disadvantages Optical readers are expensive. OCR may require redesigning quite frequently. Only certain font is acceptable. 97
98
Magnetic Ink Character Recognition (MICR) (Magnetic scanner) This scanner is able to detect characters written in special magnetic ink. It is used in banks to read cheques, credit cards etc. Application of MICR Banking industry for cheques. 98
99
Advantages and disadvantages of MICR Advantages It’s fast, accurate and automatic. The code are both machine and human readable. Reduces forgery i.e. it’s difficult to forge. Disadvantages MICR system is limited to only 14 characters. MICR system is based on magnetism and can easily be damaged. 99
100
Magnetic Stripe Recognition (Magnetic scanner) A magnetic stripe is a thin magnetic tape, often found at the back of a plastic card e.g. ATM card. The magnetic stripe is used to recognise the data in such cards. Application of magnetic stripes On credit cards. On bank cards. As tags on clothes. As a phone card. 100
101
Advantages and disadvantages of magnetic stripes Advantages Simple to produce. Not easy damaged. Stores fairly large numbers of characters. Disadvantages Data can be changed or erased by magnetic fields. Advantages Simple to produce. Not easy damaged. Stores fairly large numbers of characters. Disadvantages Data can be changed or erased by magnetic fields. 101
102
Speech recognition devices This is a type of input method where microphone is used to enter data in form of spoken words into the computer. Application area of speech recognition Security and access control e.g. office security for room access, house/car security. Quality control and automatic in factories i.e. speech input used to order robots. Automated materials handling – in airports to direct luggage to appropriate conveyor belt. Voice activated toys and games. 102
103
Advantages and disadvantages of speech recognition Advantages No keyboards in necessary i.e. very fast. Useful in situations where hands or eyes are busy handling documents etc. People are moving around, since wireless microphone can be used. Can be used from remote locations via the telephone. Disadvantages Homophones – some words sound the same. Recognition is slow. Limited vocabularies. Background noise can disrupt the data entered. Speaker variability i.e. the speed, pitch, loudness, pronunciation of individuals. 103
104
Types of other digital devices (Touch screen and digital camera) Touch screen – this device recognises the location of a contact on the screen through a built-in grid of sensing lines and sensors. Digital camera – they are used to take electronic pictures of an object. 104
105
Types of other digital device (Digitizers) It has graphic tablet on which the user writes on using a device similar to a pen (stylus). The stylus moves on the tablet and the drawing is directly reflected on the screen. 105
106
Types of other digital devices (Interactive whiteboard) An interactive whiteboard also as a smartboard, is a large interactive display that connects to a computer. The computer display is projected onto the board’s surface, where users control the computer and write using a pen or finger. The board is typically mounted to a wall or on a floor stand. 106
107
Selecting an input device Factors to consider while selecting an input device Cost Volume Reliability Accuracy Mode of operation Appropriateness 107
108
Output device Output devices are peripheral devices that a computer uses to give out information produces after processing. Soft copy – refers to the intangible mainly displayed on the screen to through devices like speakers. Hard copy – refers to tangible output produced on papers e.g. by printers, potters etc. 108
109
Examples of soft copy devices Monitor (Visual Display Unit) VDU – it displays information on its screen thus helping the user monitor operations carried out by the computer. 109
110
Types of monitors Monochrome monitor – it displays image and text in only one colour mostly black and white. Colour monitor – it displays images and text in multiple colours. 110
111
Types of displays screen (CRT) Characteristics The screen of CRT is curved slightly outward. They are not portable. They consume a lot of power. They are cheap. NB; CRT means Cathode Ray Tubes 111
112
Types of display screen (flat panel displays) Characteristics The screen is flat. They are portable. Consume less power Occupy less space. Are expensive. Providers high quality output. 112
113
Example of flat panel displays 1 Liquid Crystal Display (LCD) – they have tiny liquid crystals that reflect light falling on them from environment. Thin Film Transistors (TFT) – it provides high quality output (text and graphics). 113
114
Example of flat panel displays 2 Electro Luminescent (EL) – they glow rise to an electroluminescent display, images are clearer than LCD. Gas plasma – they use gas that emits light when electric current is passed through them. 114
115
Graphic adapter/video card Graphic adapter it’s a piece of circuit board that connects a monitor to a computer and allows the computer to show images and text on its screen. 115
116
Examples of graphic adapters Monochrome Displays Adapter (MDA) – it displays text only in one colour. Hercules Graphic Card (HGC) – displays both text and images in one colour. Colour Graphic Adapter (CGA) – displays text and images using up to 16 colours. Enhanced Graphic Adapter (EGA) – displays text and images using 16 colours. Video Graphic Arrays (VGA) – offers 256 colours. Super Video Graphic Array (SVGA) – offers over 256 colours. 116
117
Advantages and disadvantages of VDU Advantages The display of output is almost instantaneous. Minimises paperwork. Disadvantages Can lure computer operator into not keeping hardcopy records. Screen might not allow the viewing of the full array of data. 117
118
Sound output Sound output is in form of spoken words. Speakers are used to output the sound form computers e.g. music, warnings, videos etc. Application of sound output Learning aids e.g. computer aided learning. Lifts – messages can be used in lifts to greet visitors and tell them the floor they are in. Emergency messages i.e. public address systems, in cars when running out of petrol, household e.g. vacuum ‘cleaners tub is overloaded’. Text to speech translation for blind. 118
119
Advantages of sound output Advantages No reading id necessary. Useful in situations where you can’t look or where you are busy. Fast, natural output. People grow fond of “computer speak”. Disadvantages Not suitable for noisy situations. Inappropriate for lengthy or permanent information. 119
120
Data projectors They are used to output from a computer onto a plain white screen like a wall or whiteboard. It is a creative way of presenting computer output to an audience. This technology is gradually replacing the traditional overhead projectors. 120
121
Light Emitting Diodes They are light emitting components that display light when an electric current is passed through them. It is used mainly for warnings e.g. the red and green light displayed by the system unit to help the user know whether it is ON or OFF. 121
122
Hardcopy output devices Hardcopy devices are devices that produce output on paper in form of text or graphics. 122
123
Example of hardcopy Printers – produce a hard copy of information on papers. Plotters – it’s a type of hard copy output. They are used mainly in the field of engineering and architecture for producing graphical output on paper. Computer output on microform – the com devices record computer output (image or text) on to photographic film which can be viewed later by special microfilm readers. 123
124
Classification of printers Printers are categorised as follows; How they produce characters on paper. Impact printers – they provide prints by printing head element coming into actual contact with the stationery through inked ribbon. Non-impact printers – they provide prints by the print head elements not coming into actual contact with the stationery, but other means e.g. thermal. The speed at which they print. Character printers – they produce one character at a time e.g. daisy wheel, dot matrix etc. Line printers – they produce one line at a time e.g. drum, chain etc. Page printers – they produce an entire page at once e.g. laser printer. 124
125
Differences between impact and non-impact ImpactNon-impact SlowFaster Use inked ribbonsUse thermal or electrostatic principles CheaperCostly NoisyQuiet Multiple copy production possible Multiple copy production almost impossible 125
126
Types of impact printers 1 Dot matrix printer – it’s an impact character printer that provides character prints in terms of dots. The printing head element is made up of a set of arranged needles, which are activated depending on the character to be formed for printing. 126
127
Types of impact printers 2 Daisy wheel printer – it has a wheel petals on which characters are mounted. When printing, the wheel rotates allowing petals to hit a ribbon with different character. Golf ball printer – the character images are incorporated on the surface of a gold ball like print head, which is either rotating or pivoted. 127
128
Types of impact printers 2 Drum printer – it provides one whole line print at a time. The characters are incorporated on circular bands that move round the surface of the drum surface. Chain printer – it’s an impact line printer that incorporates engraved characters printing slugs at high constant speed past printing positions. 128
129
Types of non-impact printers 1 Inkjet printer – this printer forms characters by spraying ink form tiny nozzles through an electrical field that arranges the charged ink particies into characters. 129
130
Types of non-impact printers 2 Thermal printer – it’s non-impact character printer that provides character prints using heat principles. Electrostatic printer – it’s a non-impact that uses electrostatic charges to form characters in a line on a special paper. 130
131
Types of non-impact printers 3 Laser printer – it prints by passing a laser beam back and forth over a rotating drum. Photo printer – are special purpose printers designed to print photos. 131
132
Selecting a printer Factors to consider when selecting a printer Initial cost and subsequent costs of maintenance. Volume of printing expected reports. Nature of reports to be generated. Range of capability for selected printers e.g. multiple copier, print styles etc. Interface with the computer system. Speed. Quality of prints. 132
133
Type of plotters Flat bed plotters Drum plotter 133
134
Computer output on microform (COM) The com devices record computer output (images or text) on to photographic film which can be viewed later by special microfilm readers. Applications of COM Libraries for book catalogues. Local authorities to retain town plans, maps, statistics etc. Companies to store personal and customers records. 134
135
Types of microform Microfilm - the output is usually on a roll of film. Microfiche – the output is on a page of film on which data images are arranged in a grid of patterns. 135
136
Advantages and disadvantages of COM Advantages Saves on stationery and space. Faster than printing. Non-bulky hence portable. Contents on COM are not easily read using naked eyes hence guaranteed security. Have got larger life span compared to paper output. Disadvantages Are expensive. Cause eye-strain. Additional equipments needed to read to contents. 136
137
Review questions 1-1 1. What is a computer system? 2. Differentiate between a computer and a computer system. 3. A scanner used at points of sale terminals in supermarkets is an example of a ( ) scanner. 4. The automated input technique where keying of input data is eliminated is sometimes referred to as ( ). 5. The type of scanner used to grade multiple choice examination is called ( ). 137
138
Review questions 1-2 6. Name three factors one would consider when selecting data entry method, and give a reason why each is important. 7. Describe three different optical and two magnetic scanning techniques used for input; give an example of the use of each. 8. Explain how banks use MICR scanners for cheque processing. 9. Describe two situations in which speech recognition devices may be useful as a method of data entry. 10. Optical scanning of the universal product code is now widely used as input method. Give an example of a place where it is used and explain how it is used. 138
139
Answer of review questions 1 1. A computer system refers to hardware, software and liveware that work together to process and manage information. 2. A computer is made up both hardware and software while a computer system integrates hardware, software and user. 3. Barcode reader. 4. Data capture. 5. Optical mark reader (OMR). 6. The user’s needs, Type of data to be input, Volume of data entry, Cost, availability, etc. 7. Optical – OMR, OBR and OCR. Magnetic – MICR and Magnetic strip. 8. Special magnetic characters are written on cheques that can only be detected by MICR reader. 9. For people with special needs (disabilities), In language translator programs, Voice tags for voice dialling. 10. Supermarket and superstores. To capture price of goods from bar codes. 139
140
Review questions 2 1. Differentiate between soft copy and hard copy. 2. What is the difference between a CRT monitor and a flat-panel display. 3. Give three examples of flat-panel monitors available in the market today. 4. Name four criteria used when selecting a printer. 5. Distinguish between impact and non-impact printers and give two examples of each. 6. State one advantage and one disadvantage of laser and inkjet printers respectively. 7. Give two advantages of sound output devices. 8. Karuri Road Construction Company (KRCC), intends to buy an output device they can use to produce road maps. Which device would one advice the company to buy and why? 140
141
Answer of review questions 2-1 1. Hardcopy is intangible information, e.g. printout on paper like letters, while softcopy is intangible information, e.g. screen display or music. 2. CRT monitor uses a cathode ray tube while a flat panel does not. CRT has protruding back while flat panel does not. 3. Liquid Crystal Display (LCD), Thin Film transistor (TFT), Gas plasma display and Electro luminescent (EL). 4. Cost, print quality, availability, speed, purpose and print technology. 5. Impact printer – print by striking mechanism and are noisy, e.g. dot matrix and daisy wheel. Non-impact printer – print by either laser, ink or thermal transfer mechanism, e.g. laser jet, inkjet and thermal printers. 141
142
Answer of review questions 2-2 6. Advantage of: Laser printers – cheap running cost, good print quality. Inkjet printers – cheap to purchase, cheaper multiple colours printing, high quality print. Disadvantage of: Leaser printers – expensive to purchase, expensive multi-colour printing. Inkjet printers – expensive to buy cartridges (run), water based print easily fades. 7. Enable reception of output even when a few meters away from computer, Makes computing interesting and entertaining, Suitable for the blind and people with poor sight. 8. A plotter – it draws lines and big charts. 142
143
Central Processing umit The Central Processing Unit (Processor) is that part of the computer that decodes and executes instructions. 143
144
Functional unites of CPU Arithmetic Logic Unite (ALU) – in this unit of CPU all the arithmetic and logical operational are carried out. Control unit – this unit coordinates all processing activities in the CPU as well as input, storage and output operations. Registers– this unit provides storage location for data and instructions accessed by the control unit. 144
145
Functions of ALU, Control unit and registers ALU Does all the mathematical computations in a computer. Does all of the logic comparisons of values. Control unit Directs the flow of information into the CPU memory and storage. Controls the instructions the CPU will perform next. Registers Holds data awaiting processing. Holds data that has been processed awaiting to be output. Holds data been processed. 145
146
Functional organisation of CPU The arithmetic logic unit, control unit and main memory are linked through electrical pathways called buses. A bus is an electrical path for signal to flow from one point to another in a circuit. 146
147
Computer Primary Memory 147 There are two types of primary memory; Read Only Memory (ROM) Random Access Memory (RAM)
148
Types of memory (ROM) Read Only Memory (ROM) – this memory is used to store programmed instructions and data permanently or semi permanently. Data and instructions stored in ROM are those required to remain unchanged for a long time. Characteristics Can only be read but cannot write on it. It’s non-volatile. Stores permanent instructions from manufacturer. 148
149
Types of memory (RAM) Random Access Memory (RAM) – it’s called Random Access Memory (RAM) because its content can be read directly regardless of the sequence in which it was stored. Characteristics Data can be read and written in it. It’s temporary, its contents disappears when the computer is switched off. It’s contents is user defined. 149
150
Types of ROM Mask Read Only Memory (MROM) – once contents are written on it by the manufacturer, it cannot be changed. Programmable Read Only Memory (PROM) – this allows the user to alter it only once after the content is written on it. Erasable Programmable Read Only Memory (EPROM) – the contents stored in this memory can be erased by exposing them to ultra violet light and then reprogrammed for another use. Electrically Erasable Programmable Read Only Memory (EAPROM) – this memory can be erased and reprogrammed using electricity. 150
151
Types of RAM Static RAM (SRAM) – it’s a very fast memory and holds its content as long as there is power. Dynamic RAM (DRAM) – it holds its contents for a short while even when the power is on. To maintain its content it must be refreshed severally per second. 151
152
Special purpose memories Buffer – it’s a special purpose memory used during input/output or processing to temporarily hold data or instructions between communicating elements. Cache memory – it’s a very high speed type of SRAM whose purpose is to allow the processor to access data instructions more faster. Register – they are temporarily storage locations within CPU that holds one piece of data at a time. 152
153
Examples of registers Accumulators – temporarily holds the results of the last processing step of ALU. Instruction registers – temporarily holds an instruction before it’s interpreted into a form that CPU can understand it. Address registers – temporarily holds next piece of data waiting to be processed. Storage registers – temporarily holds a piece of data that is on it’s way to and from the CPU and main memory. 153
154
Types of computer buses Control bus – this is a pathway for all timings and controlling functions sent by the control unit to other parts of the system. Address bus – this pathway is used to locate the storage position in memory of the data to be executed or an instruction to be decoded. Data bus – this is the pathway where the actual data transfer takes place. 154
155
Types of processors and their clock speed 155
156
Review questions 1 1. Define the term central processing unit? 2. Describe three functions performed by the CPU. 3. What is a microcomputer? 4. Explain the functions performed by: A) The control unit; B) The arithmetic and logic unit; C) The main memory; 5. Define the terms: volatile memory and non-volatile memory. 6. Define and explain the difference between Ram and ROM. 7. How many characters (bytes) of data are held in each of the following memories? 4KB, 640KB, 16MB and 20GB? 156
157
Answer of review questions 1 1. Central Processing Unit. 2. Processing data, System control, Provide temporary storage (RAM) and permanent storage (ROM). 3. It is a tiny processor, mainly a combination of he ALU and control unit on a single silicon chip. 4. A). Interpreting instruction, Issuing control instructions the O/S. B). Performing arithmetic calculation, Performing logical operations. C). Holding data just before and after processing, Holding instructions just before execution. 5. Volatile memory is temporary while non volatile is permanent. 6. RAM – temporary and rewritable memory ROM – permanent and read only memory. 7. 4KB – approximately 4000 characters. 640KB – approximately 640,000 characters. 16MB – approximately 16 million characters. 20GB – approximately 20 billion characters. 157
158
Review questions 2 1. Name three special purpose memories found either inside or outside the microproce3ssor, and explain what each does. 2. In reference to arithmetic and logic unit, explain the meaning of logic operations and give an example of this processing operation. 3. What is the meaning of BIOS, and what role does it play in a computer? 4. Explain the purpose of the system clock. 5. What is the meaning of BIOS, and what role does it play in a computer? 6. List three buses found in the CPU. 158
159
Answer of review questions 2 1. Cache memory – speeds up processing (fetch cycle). Buffer – acts as interface between very fast proce3ssor and slow I/O devices. Register – temporarily holds data/instructions just before and after processing. 2. Comparisons include: =,,and <>. 3. The CPU of a microcomputer is smaller and less powerful than that of mainframe. 4. Determines the processing speed of the CPU. 5. Basic Input Output System – holds hardware setup and configuration information. 6. Data bus, address bus and control bus. 159
160
Practical activity 1 With the help of the teacher, find out the following: 1. The type of processor in one of the computers in your computer laboratory. 2. The clock speeds of all the computers in the computer laboratory. 3. What is the size of RAM in MB of the computer you are currently using? 160
161
Secondary Memory (Secondary storage devices) These are storage devices that compliment the primary memory. They are used to store information for longer period. 161
162
Characteristics of secondary storage Non-volatile storage – data stored in this media is permanent unless erased by user Mass storage – stores large volume of data Reusability – stored data can be erased and the media reused to store fresh data and programs 162
163
Classification of secondary storage Removable storage devices – these devices are not housed inside the system unit hence can be used in another computer e.g. floppy, flash disk, CD. Fixed storage devices – these devices are housed inside the computer system unit e.g. hard disk. 163
164
Removable storage devices Magnetic desks Floppy disks Zip disk Jaz disk Magnetic tapes Optical disk – these disks use laser beam to record data on them. The laser ray burns tiny holes into a shiny surface to record data. 164
165
Floppy disk They are made of small flexible round disk coated with iron oxide. They are used to store information for later use in the same or different computer, and can be used to move information from one computer to another. 165
166
Zip disk Zip disk – they resemble floppy disk but have high storage capacity. They are slightly larger and thicker in size. Can hold at least 250MB. Mostly they come with a separate portable external zip disk. 166
167
Jaz disk Jaz disk – they are small portable of about 1GB – 2GB. They are used for storing data that require larger capacity. They have an external jaz drive. 167
168
Advantages and disadvantages of floppy disk Advantages They are very cheap. Small, lightweight and convenient. Exchangeable. Disadvantages Floppies are vulnerable i.e. short life. Time consuming if access is needed to many files over a short period. Easily damaged. Storage area is limited. 168
169
Magnetic tapes This is ribbon of Mylar (plastic – like) material coated with a thin layer of iron oxide. Magnetic tape resembles the music cassette. Tape is stored in blocks separated by inter – block gaps left for stopping purposes. Tapes are sequentially accessed. This implies that if information is at the end of the tape, the computer will have to read almost the entire tape which is time consuming. 169
170
Advantages and disadvantages of magnetic tapes Advantages They are portable. Cheap. Can be erased and re-used. Holds a lot of data in a compact space. Disadvantages Very slow in accessing of data. Easily damaged i.e. dust, heat, touching etc. The inter-block space is wastage of storage area. 170
171
Examples of optical storage disks LS-120 super disk – this is a diskette that resembles the floppy disk but uses optical technology instead of magnetic technology to read data. It has greater storage capacity and greater speed of data access than floppy disk. Digital Versatile Disks (DVD’s) – also known as digital video disk. They resemble compact disk but have higher storage capacity of up to 17GB. They are suitable for recording motion pictures e.g. video because they offer better sound and picture quality than CDs. Compact disk (CD) – they hold larger quantities of data and information. It holds as much as 700MB. Mostly used to store data and information that require a lot of space e.g. video clips, software etc. Optical card – it resembles the magnetic ink character reader card but uses an optical recordable stripe that stored using optical technology. Photo CD – this CD is used to process photographic film or negatives to produce and store high quality photographs on a CD-R. 171
172
Forms of compact disks CD-ROM (Compact Disk-Read Only Memory) – in this type of compact disks, when data is recorded on them, one can neither change them, nor add anything on. CD-R (Compact Disk-Recordable) – they are initially blank, the user can record data on it. However once the data has been written on it, one can only read but no changing it. CD-RW (Compact Disk Rewriteable) – with CD-RW the user can record, erase and rewrite new information. WORM (Write Once Read Many Times) – these are discs that allow the user to record data on them once but read them many times e.g. CD-ROMs and CD-Rs. 172
173
Advantages and disadvantages of CD-ROM Advantages It’s smaller, more portable and has lager storage compared to diskettes. More secure as it cannot be changed or attacked by viruses. Disadvantages Not possible to change data written on a CD-ROM. Are expensive than diskettes. Can’t erase the data stored. 173
174
Advantages and disadvantages of optical storage Advantages Have massive capacity. Stores data permanently. Accessing of data is fast. Secured i.e. it’s hard to copy. High quality pictures and sound. Portable. Disadvantages Expensive. Costly hardware and software for reading. Break easily (it’s fragile). Very sensitive to things like dust, water, heat, scratches which easily damage them. 174
175
Flash disk This is the most current storage device in the market. It has a massive storage area, more reliable and portable. It’s small in size and can store over 600MB of information. 175
176
Example of fixed storage devices Hard disk (Winchester) – they are made from metal and are coated with a thin film of magnetic oxide. The hard disk unit is made of shiny, rigid magnetic disks or platters that are arranged vertically on a common axis. They can hold thousand of programs and files. 176
177
Advantages and disadvantages of hard disk Advantages It’s cheap. Very reliable. Does not deteriorate as quickly as floppy. More storage capacity. Accessing of data is faster. Disadvantages They can suffer a head crash resulting to loss of data. They are sensitive to things like dust, humidity, magnets which can corrupt the data stored. They are inflexible i.e. cannot be changed. 177
178
Review questions 1 1. Distinguish between primary and secondary storage devices. 2. Distinguish between removable and fixed storage. 3. Compare three types of removable disks i.e. floppy, zip, and jaz disks in relation to size. 4. What is a hard disk? How does it differ from the floppy disk? 5. What are the advantage3s of the hard disk over the floppy disk? 6. Give four examples of optical disks and how they differ from each other in terms of storage capacity and mechanism. 178
179
Answer of review questions 1 1. Primary storage is accessed directly by CPU while secondary is not. 2. Removable are portable while fixed are mounted inside the system unit. 3. Floppy – physically small in size and capacity. Jaz&Zip are slightly large in size and have large storage capacity. 4. It is hard magnetic platter used to store data and is encased in a metallic housing (casing). It differs from a floppy because it is metallic, shinny and non flexible. 5. It is large in storage capacity, More reliable, Faster access to data and information. 6. CD-ROM, CD-R, CD-RW, LS-120, Super disk, DVD, optical card, optical tape. 179
180
Review questions 2 1. What are the advantages of a digital versatile disk over a typical compact disk. 2. Define the term multimedia and list down the components required to make a computer multimedia. 3. Why are CD-ROMs and CD-Rs referred to as WORM? 4. Describe the difference between magnetic and optical storage media. 5. Jets publishers is a company that specializes in production of newspapers. One of the editors wanted to transfer a 50MB document from the hard disk of one computer to another using a removable storage media. Give four examples of the devices he/she could use. 6. Describe three precautions you would take to avoid damaging the hard disk. 180
181
Answer of review questions 2 1. DVD has larger storage capacity than CD, Offers better data storage quality. 2. Multimedia is an integration of sound, video and text processing and output. Components – optical drive, speakers, sound adapter, VGA monitor. 3. Write Once Read Many (WORM) – recorded once but can be accessed many times without changing content. 4. Magnetic – data recorded using magnetism. optical – data recorded using a beam of light (laser). 5. Jaz, Zip, Flash disk, CD-R, CD-RW. 6. Do not drop the disk drive, Do not expose it to strong heat, Do not expose it to dust/smoke particles, Do not unprocedurally switch off the computer. 181
182
Practical activity 1 Using a floppy disk provided by the teacher: 1. Draw and label all the parts of a diskette. 2. Remove the protective plastic casing to expose the disk platter. a. How flexible is the platter? b. What is the texture and colour of the surface? Is it possible to see the tracks and sectors? c. Assuming the tracks and sectors are visible, draw a diagram to illustrate how they would look like. 182
183
Power and interface cable 183
184
Port It’s a socket on the system unit into which a cable from an external peripheral device (e.g. mouse keyboard etc) is plugged to facilitate transfer of information between the device and CPU. Power cable Serial cables and ports Parallel cables and ports Universal Serial Bus (USB) cables and ports Interface cable Small Computer System Interface (SCSI) 184
185
Power cable They are used to supply power to the motherboard and other internal devices of a computer. 185
186
Serial cables and ports They transmit data between devices and CPU one bit after another. They are slow but are reliable than parallel cables. Mainly used to connect mouse. 186
187
Parallel cables and ports They transmit information simultaneously using a set of many conductors. They are faster than serial. Used to connect devices such as printer. 187
188
Universal Serial Bus (USB) cables and ports They transmit only 1 bit of information at a time at a very high speed than parallel. Provides quality data transmission over long distance. It’s port support devices like digital cameras, scanners, mouse etc. 188
189
Interface cable / Small Computer System Interface (SCSI) Interface cable – All peripheral devices that make up a computer system are connected to the motherboard inside the system unit through the interface cables. Small Computer System Interface (SCSI) – they transmit data in parallel but are faster than parallel cables. It’s port allows connection of up 7 peripheral devices. 189
190
Personal system 2 (PS/2) interface Originally, most computers used the 5-pin DIN to connect a keyboard to the system unit but the smaller 6-pin mini- DIN also known as PS/2 interface has replaced this technology. 190
191
Types of ports 1 Infra-red – used for wireless communication between the CPU and device which is infrared – capable. Communication is over short distance, and there should be no obstruction between the two devices. D-type ports – these ports have the shape of capital letter D. They are two types namely the Nine-Pin (DB-9) and 25 pin-wide (DB- 25). The DB9 is a serial port into which cables such as mouse, modem, serial printer etc can be plugged. The DB-25 port can be used for both serial and parallel devices. When used to connect serial it’s labelled COM1 or COM2 and only 10 of its pins are used. For parallel it’s labeled LPT 1 or LPT 2. Centronic ports – this is a parallel port that uses metal clips mounted into cells in place of pins. Audio ports – used for inputting and outputting sound into and out of sound card. LAN ports – used for connecting the computer to local are network. Modem port – used for plugging an external modem into the computer. 191
192
Types of ports 2 (Video port) Video ports – used for connecting the monitor to the system unit. It can be 9-pin D or 15-pin D. 192
193
Ports on the backside of system unit 193
194
Standard symbols used to denote an interface SymbolPort Parallel Serial USB SCSI PS/2 for mouse PS/2 for keyboard 194
195
Basic computer set-up and cabling Having learnt about various devices and how they function, it is important to familiarise ourselves on how to set up a computer. Before carrying out the practical the following should be observed. Dismember all cables from the source of power to prevent electrical shock. Follow the teacher’s instructions strictly. 195
196
Tools and materials required Screw drivers Pliers Motherboard Manufacturers manual Required peripheral devices Dismantled system unit Power and interface cables 196
197
Steps of computer set-up and cabling 1 1. Connecting basic computer components. 2. Connecting devices to motherboard – indentifying connecting points on the motherboard. Carefully identify the points on the motherboard before you start connecting the computer ports. 197
198
3. Connecting the hard disk, floppy drive, CD- ROM a. Wear antistatic material to discharge any static change on the body. b. Check for a free drive bay to hold disk drive. c. Slide the disk into its bay and screw it. d. Connect the power supply cable to the device. e. Connect the cable both to the drive then to motherboard. f. If installation is complete replace the system unit cover. Steps of computer set-up and cabling 2 198
199
4. Connecting other peripheral devices. a. Identify its port and data cable or interface cable. b. Connect the data cables of all devices to their respective ports. c. Switch on the computer power source. d. Successful boot means the computer was properly setup. Steps of computer set-up and cabling 3 199
200
Review questions 1 1. Define the following terms: A). PortB). Interface cableC). Power cable 2. What is the function of the power supply unit found in the system unit. 3. Differentiate between parallel and serial interface cables. 4. Give two advantages of a USB interface cable. 5. Draw an illustration of: A). Parallel cableB). USB port 6. What would happen if you bend the pins of a monitor port as you try to connect the monitor interface cable to the system unit? 7. Draw illustrations of various ports found at the back of the system unit of the computer. 200
201
Answer of review questions 1 1. A). Special socket for connecting peripheral devices on the system unit. B). Cable for data transmission. C). Cable for power supply to devices. 2. To supply stable power to system unit internal devices and the mother board. 3. Parallel cables transmits several bits simultaneously while serial transmits one bit at a time. 4. It is light, Offers fast transmission, Its serial nature enable it to connect devices a longer distance away, The USB port can be used to connect different peripheral devices due to its common universal interface. 6. No display or some colours will fail to display. 201
202
Review questions 2 1. What are the safety precautions to be observed before one starts installing devices in the system unit? 2. In relation to cabling, give two reasons why a printer may not print work sent from the computer as expected? 3. Naliaka connected new multimedia speakers to her computer and tried to play her favorite music CD but no sound was heard. What might have been the problem? 202
203
Answer of review questions 2 1. A). Disconnect all devices from power source before attempting to work on them. B). Do not work on any peripheral device without the guidance of the teacher. C). Never work alone because you may need help in case of an emergency. D). Discharge any static electricity that might have built up on your hands by touching an earthed metallic object and then wearing an antistatic wrist member. 2. A). Loose printer interface cable. B). Printer still off. C). Printer not installed. 3. A). Volume control too low. B). Loose or improper connection to the sound card. C). Speakers not powered. D). Multimedia not supported. E) absence of analog cable connecting the optical drive to the motherboard or sound card. 203
204
Revision questions 1. Write the following abbreviations in full: A). CPUB). ALUC). CU D). ROME). RAM 2. Give examples of special purpose memories found in the CPU. 3. What do the following abbreviations in relation to storage capacity stand for: A). KBB). MBC). GB 4. Describe various display video cards used in computers. 5. Differentiate between MICR and OCR scanners. 6. What is the market name given to the most recent types of processors? 7. Explain the internal mechanism of the hard disk in reference to disk platters and the read/Write head. 8. Describe the structure of a hard disk in reference to cylinders, tracks and sectors. 9. What are pixels? What role do they play in screen display? 10. Explain the steps you would follow to set up a new computer. 204
205
Answer of revision questions 1 1. A). Central Processing Unit. B). Arithmetic Logic Unit. C). Control Unit. D). Read Only Memory. E). Random Access Memory. 2. Cache and registers. 3. A). Kilobyte. B). Megabyte C). Gigabyte. 4. MDA, HGA, EGA, VGA and SVGA. 4. MICR uses magnetic technology to read magnetic characters while OCR uses laser technology to read characters. 5. Pentium processors. 6. The drive is made up of several disk platters that are mounted on a common axis with read/write heads on both sides of the platters. The heads move in and out as they write/read data. The outer case is hard and metallic. 205
206
Answer of revision questions 2 8. The hard disk is divided into concentric circles called tracks. Parallel tracks on several platters are called cylinders. The tracks are further subdivided into sectors. Several sectors can be grouped to form clusters. 9. Pixels (picture elements) are dots on the screen that form characters and images. They determine the clarity of the image. 10. (a). Gently and carefully connect the interface cable of each device to the correct port and to the device. (b). Connect the computer to the power source and switch it on. (c). Observe boot up information on the screen to see whether Power On-Self Test (POST) displays any error message. A successful boot means that the computer was properly setup. 206
207
Practical activity 1 Using the universal symbols in table right, identify each port located on the system unit. 207
208
Computer software 208
209
Introduction Software are programs or set of instructions that enables a computer system to operate. 209
210
Classification of software 1 According to purpose. System software – it enables the user communicate with the computer and its various devices e.g. keyboard. Application software – application software are designed to help the user accomplish specific tasks. 210
211
Classification of software 2 According to method of acquisition. In-house developed program (Bespoke) – these programs are designed to serve a particular purpose for specific groups or people e.g. in banks for managing their operations, airlines for booking etc. Standard software (off the shelf packages) – these programs are developed by software engineers, packaged and made available for purchase through a vendor or directly from developer e.g. Microsoft office. 211
212
Program under system software 1 Firmware – it’s a combination of both hardware and software. It’s in form of a chip which may be used to store programs. Network software – it’s used to establish communication between two or more computers by linking them using a communication channel e.g. cables to create network, novel, Linux etc. 212
213
Program under system software 2 Operating system – it’s a set of programs that control and supervise the hardware resources of a computer during processing. Examples of operating system include Windows 95/98/2000/XP, Linux Macintosh, MS-DOS etc. Utility software – they are programs that perform commonly used services that make certain aspects of computing to go on more smoothly. 213
214
Types of utility software System level Application utility Program translator Setting editor Text editor Sort editor Etc. Calculator Time Backup utility Anti virus utility Diagnostic utility Calendar utility 214
215
Examples of application software Word processor – for typing documents e.g. MS-Word. Database – for keeping records and files e.g. MS-Excel. Spreadsheet – for calculations e.g. MS- Access. Desk top publishing – designing publications e.g. cards (Adobe PageMaker). Computer Aided Design – for technical drawing e.g. AutoCAD. Graphics software – for designing and manipulating graphics e.g. Photoshop 215
216
Advantages of standard software over in house software They can easily be installed and run Thoroughly test hence few errors Readily available Easily modified to meet specific user needs Less expensive 216
217
Disadvantages of standard software over in-house software May not meet special needs. They are not as efficient as user made programs. When changes occur extra costs is usually needed from user. Not all packages are compatible with all computer system. 217
218
Criteria for selecting computer system (Specification) Hardware considerations Processor speed Computer memory capacity Upgrading and compatibility User needs Cost Portability Warranty 218
219
Criteria for selecting computer system (Specification) Software considerations User needs Documentation Authencity User friendliness Cost Portability 219
220
Operating system (OS) Operating system is a set of programs that control and supervise the hardware resources of a computer and provide services to other system software. Examples of operating system includes; Microsoft Windows 95/98/2000/XP/Vista, Unix, Linux, MS-DOS, novel etc. 220
221
Functions of operating system (OS) 1 Resource control – the OS allocates computer resources such as CPU time, main memory, secondary storage and input/output for use by application program. 221
222
Functions of operating system (OS) 2 Job scheduling – the OS prepares, schedules, controls and monitors tasks submitted for execution to ensure the most efficient processing. Memory management – the OS ensures that each program and the data it requires are allocated adequate space in memory. 222
223
Functions of operating system (OS) 3 Error handling – OS provides the error correction routines to ensure smooth operations within CPU. Interrupt handling – OS determines the cause of the interrupt and transfer the control to the most appropriate programs. Input/output handling – the OS governs input/output of data and their location, storage and retrieval. 223
224
Functions of operating system (OS) 4 Communication control and management – the operating system is responsible for managing various communication devices and provide an environment within which communication protocol operate. The term protocol refers to the rules that governs system come with network management utilities that provide external communication by connecting to a communication systems using interface cable or through wireless interface. 224
225
Types of operating system Operating system can be classified according to; Number of users Number of tasks Interface 225
226
Number of users Single user-operating system – this OS allows only one user at a time to access a computer e.g. MS-DOS, MS-Windows 95/98/2000. Multi-user operating system – this OS allows two or more users to access a computer at the same time e.g. Windows 2000 server, Novel, Unix, Windows NT etc. 226
227
Number of tasks Single tasking operating system – this OS allows only one program to be executed at a time e.g. MS-DOS. Multi-tasking operating system (multithreading) – this OS allows a single CPU to execute more than one program at a time e.g. Windows Vista, XP etc. 227
228
Interface (Command line) Command line – the user interacts with a computer by typing a command at the prompt found on a command line e.g. MS-DOS. 228
229
Interface (Menu driven interface) Menu driven interface – this interface allows the user to select commands/options from a list or menu using keyboard or pointing device such as mouse. E.g. MS- DOS version called DOS editor). 229
230
Interface (Graphical User Interface) Graphical User Interface (GUI) – this interface represents commands as small pictures on the screen called icons e.g. Microsoft Windows 95/98/2000/XP/Vista, Linux etc 230
231
Selecting an operating system Factors to consider when choosing an O.S. Hardware configuration Basic design of the computer Applications intended for the computer User friendliness Cost Availability in market 231
232
How Windows organise information The OS organise information in terms of files, folders and drives. File – it’s a collection of related data or information stored in one location. Folder/directory – it’s a named storage are where the user can store related files to enable easy access. Storage media – when creating a folder or saving a file identify a storage location which is more reliable e.g. floppy disk, compact disk, hard disk etc. 232
233
Information organisation tree C:\> Folder 1Folder 2Folder 3 File 2 Subfolder 1Subfolder 2 Subfolder 3Subfolder 4File 3 File 1 233
234
Types of files 1 System files – these files contain information that is critical for the operation of the computer. Application files – these files hold programs or application files. 234
235
Function of files Storage of data. Organisation of information. 235
236
Folder/directory It’s a named storage area where the user can store related files to enable easy access. 236
237
Storage media When creating a folder or saving a file identify a storage location which is more reliable e.g. floppy disk, compact disk, hard disk etc. 237
238
Types of files 2 ExtensionFile typeDescription.docDataA Microsoft Word document file..txtDataA plain text created using note pad or DOS editor..tifDataA graphic file created using applications such as adobe photoshop..exeApplication fileThe file that launches a particular application, e.g. Windows.exe, PM701.exe, etc.batSystem filesFile containing a series of commands loaded during boot up..sysSystem filesSystem files that perform fundamental operations in a computer. 238
239
Drives Storage locationDriveRemarks Floppy driveA and BIf a computer has two floppy drives, one will be assigned letter A the other B. Hard diskC,D,E,FIf a computer has 4 hard drives, they will be assigned letters C-F. Optical drivesD,E,F,GIf a computer has one hard disk and three or more CD/DVD drives, they will take up any number between D and Z. Other removableD,E,…Z If a computer does not have and optical drive, any removable drive attached to the computer can take any letter between D and Z. Network driveLogical Network drives takes D-Z depending on the number of physical drives installed or attached. 239
240
Windows desktop feature Once you turn on the computer, Windows is loaded into the main memory and finally the desktop showing that the computer is ready for use appears. The three main features of the desktop are the background, icons and the taskbar. 240
241
Taskbar The taskbar enables the user to easily switch between different programs and tasks that are currently running. Whenever the user starts a program or opens a file, its button appears on the taskbar and stays there until the user exits the program. 241
242
Managing files/folders (Renaming) Refers to changing files from their original name to some other new names. 1. Using My Computer icon, display the Explorer window. 2. On the folder tree on the left pane, select the file or folder to be renamed. 3. On the “File” menu. 4. Click the “Rename”. 5. Type the new name. 6. Type the “Enter” key. 242
243
Managing files/folders (Sorting) Refers to organising files and folders in a particular way. 1. Open a folder or storage location. 2. On the “View” menu. 3. Point to “Arrange Icon By”. 4. Select one form list. “Name”,”Size”, “Type” or “Modified”. 243
244
Managing files/folders (Copying) Enables the computer user to duplicate files and folders to another location. 1. Using My Computer icon, display the Explorer window. 2. Select the file or folder to be copied. 3. On the “Edit” menu. 4. Click the “Copy”. 5. Select the drive or folder where you want the item to be copied. 6. On the “Edit” menu. 7. Click the “Paste”. 244
245
Managing files/folders (Moving) Refers to removing the files and folders completely from the storage location. 1. Using My Computer icon, display the Explorer window. 2. On the “Edit” menu. 3. Click the “Cut” 4. Select the drive or folder where you want the item moved. 5. On the “Edit” menu. 6. Click the “Paste” 245
246
Managing files/folders (Searching) Refers to looking for a certain file or folder. 1. Click the “Start” button. 2. Point to “Search” (Search dialog box is displayed). 3. Click the “For Files or Folders”. 4. Type all or part of the file name in the search box. 5. Select location of the file from arrow down list. 6. Click the “Search” button. 246
247
Windows explorer Windows explorer lets the user display the drives and folders in a hierarchy or tree structure. The computer tree is an upside down structure with the highest level in this case the desktop being the root. The explorer divides the window into two panes. The left pane displays a tree of drives and folders while the right pane displays a list of files and subfolders contained in a particular open drive or folder. 247
248
Using My Computer Double clicking on MY Computer icon, gives you a graphical view of what is inside the computer. This includes the drives, the control panels and other resources. 248
249
Creating a new folder There will be times when the user would want to create new folders. Say, for instance, when working on a detailed project that has multiple files. It is advisable that all related files be kept together in one folder. 1. Open the “My Computer” and display the Explorer window. 2. On the folder tree on the left pane, select the location in which you want to create a new folder. 3. On the “File” menu. 4. Point to “New”. 5. Click the “Folder”. (New folder is displayed) 6. Type a new name for the folder. 249
250
The application window To enter data in a new file created, one has to open it in its application programs. This is done by double clicking the file icon. A rectangular area called an application window appears on the screen. 250
251
Parts of a window (Title bar) This is a bar across the top of the window that displays the name of the current application programs. 251
252
Parts of a window (Menu bar) Provides a list of commands than can be used to manipulate a task. 252
253
Parts of a window (Tool bar) They are buttons arranged in a row that are shortcuts to menu commands. 253
254
Parts of a window (Work area) This is the area where you can create your document. 254
255
Parts of a window (Status bar) This displays information about the program currently running. 255
256
Parts of a window (Insertion point/Text cursor) Marks the place where text and graphics will appear when typing drawing is started. 256
257
Disk management using operating system (Formatting disk) The process of preparing a new disk for use by creating sectors and tracks on the surface of disk. 1. Insert the media disk into the floppy or USB port. 2. Open the “My Computer” 3. Right click on the drive icon. (Shortcut menu is displayed) 4. Click the “Format”. (Format dialog box is displayed) 5. Select the Format system from the arrow down list. “FAT”, “FAT32” or “NTFS”. 6. Click the “Start” button. 7. After format has finished, click the “Close” button. 257
258
Disk management using operating system (Disk defragmentation) Refers to arranging of scattered folders and files on a storage media for easy access of files and folders. 1. Open the “My Computer” 2. Right click on the drive icon. (Shortcut menu is displayed) 3. Click the “Properties”. (Properties dialog box is displayed) 4. Select the “Tool” tab. 5. Click the “Defragment Now” button. (Disk Defragmenter dialog box is displayed) 6. Select the drive to be defragment. 7. Click the “Defragment” button. 258
259
Disk management using operating system (Disk compression) This tool help in consolidating files and folders in smaller storage areas hence creating more space on the storage device. 1. Open the “My Computer” 2. Right click on the drive you want to compress. (shortcut menu is displayed) 3. Click the “Properties” (Properties dialog box is displayed). 4. Select the “General” tab. 5. Click the check box of “Compress drive to save disk space”. 6. Click the “Apply” button. 259
260
Disk management using operating system (File or folder compression) 1. Open the drive where the file or folder is located. 2. Right click on the file or folder icon. (shortcut menu is displayed) 3. Click the “Properties”. 4. Select the “General” tab. 5. Click the “Advanced” button. 6. Click the check box of “Compress contents to save disk space”. 7. Click the “OK” button of “Advanced Attributes” dialog box. 8. Click the “OK” button of “Properties” dialog box. (Confirm Attribute Changes dialog box is displayed) 9. Select zip the folder only or the entire content. 10. Click the “OK” button. 260
261
Disk management using operating system (Disk partitioning) The process of dividing the physical disk into two or more partitions called logical drives. 261
262
Disk management using operating system (Back up data) The tool enables the user to create copies of data and programs on separate storage areas to avoid losing of data and programs incase the storage device fails. 1. Open the “My Computer”. 2. Right click on the hard drive icon (shortcut menu is displayed). 3. Click the “Properties” (Properties dialog box is displayed). 4. Select the “Tool” tab. 5. Click the “Backup Now” button. (Backup or Restore Wizard dialog box is displayed). 6. Through the process step by step. 262
263
Disk management using operating system (Scanning storage device) The tool helps the user to check up and repair minor storage problems e.g. lost storage or damaged surface. 1. Open the “My Computer” 2. Right click on the drive icon. (Shortcut menu is displayed). 3. Click the “Properties” (Properties dialog box is displayed). 4. Select the “Tool” tab. 5. Click the “Check Now” button. (Check disk dialog box is displayed). 6. Select the “Check disk options”. 7. Click the “Start” button. 263
264
Disk management using operating system (Scanning for virus) Refers to checking your system for virus and removing them e.g. using Norton antivirus, MacAfee software to scan. 1. Open the “My Computer” 2. Right click on the hard drive icon. (shortcut menu is displayed). 3. Click the “Scan with. (Anti virus dialog box is displayed). 4. The scan process in initialized. 264
265
Partitioning a disk using FAT32 file system Microsoft Windows 98/Me startup disk has an FDISK utility that lets the user partition and format a disk using FAT or FAT32 file system. NB; FAT means File Allocation Table 265
266
Partitioning a disk during installation Partitioning a disk using NTFS format in Windows 2000, XP and vista is done during the installation process as shown in left figure. NB;NTFS means New Technology File System. 266
267
Installing Windows XP Installing Windows XP is quite different from that of Windows Me because it does not operate in real DOS mode. The two methods of installing XP are upgrading from a previous Windows version is relatively simple, we shall look at clean installation, done on a new computer that comes without a n operating system. 267
268
Trouble shooting windows related problems Trouble shooting refers to the process of diagnosing and trying to fix hardware or software related problems. 268
269
Some problems windows experience Failure to boot Computer hangs now and then Abnormal restarting 269
270
The problems may be as a result of There was a problem in the installation process e.g. missing files. Insufficient system memory. Problem with hard disk boot sector may be due to virus infection. Corrupted window registry system. Due to interrupt conflicts. 270
271
To troubleshoot you need to Study the trouble shooting guide Use the device manager to check the devices causing problems. Reinstall the operating system if the problems above persist. 271
272
Review questions 1 1. Differentiate between system software and application software giving an example of each. 2. What is the importance of an operating system? 3. Give five examples of application software and their respective uses. 4. What are the advantages of standard software over the in-house developed software? 5. What is the difference between single-purpose programs and integrated software? 6. Why do computers need network software? 7. Give three examples of operating system. 272
273
Answer of review questions 1-1 1. System software performs fundamental operations like initialising hardware during boot up while application software meets user specific needs. System software – operating system, firmware, utilities. Application software – word processor, spreadsheets etc. 2. Supervises all the hardware and software operations of the computer system. 3. Word processor – typing documents. Spreadsheets – calculations. Database management systems – record management. Desktop publishing – creating publications. Graphics software – creating and manipulating. 273
274
Answer of review questions 1-2 4. Standard software is thoroughly tested hence few errors, Readily available, Easily portable. 5. Single purpose software is developed for only one purpose while integrated software is a suit of more than one programs and can be used to carry out a variety of tasks. 6. To enable communication between computers over a channel (media). 7. UNIX, Windows, DOS, LINUX, Macintosh Operating system. 274
275
Review questions 2 1. Highlight hardware and software factors that you would consider when purchasing a computer. 2. Why is it important to carefully study a warranty before singing it? 3. Why do you have to window shop before buy a computer or computer accessories? 4. Using newspaper cuttings such as the one shown below, prepare a requisition form for ten up to date multimedia computers to be used in the computer room. 275
276
Answer of review questions 2 1. Hardware 1. Cost 2. Compatibility 3. Upgradability 4. Warranty 5. Memory capacity 6. Portability 7. User needs 8. Processor type and speed Software 1. Authenticity 2. Documentation 3. User friendliness 4. Cost 5. Compatibility 6. portability 2. In order to negotiate on sensitive items like duration, after sales service etc. 3. Yes, in order to compare quality and prices. 276
277
Review questions 3 1. Give examples of two multi-user and one single user operating system. 2. Describe four functions of the operating system. 3. What is an interrupt? 4. Name and explain three types of human computer interfaces. 5. What are the advantages of GUI based operating system over the command-line? 6. Differentiate between Multitasking and multi-user operating systems. 7. What is a deadlock in reference to the operating system? 8. Outline the factors you would consider if you were to by an operating system. 277
278
Answer of review questions 3-1 1. Multi user OS – UNIX, WindowsNT/200, Novell, Linux. Single user – MS-Dos, PC-DOS. 2. A). Resource control and allocation. B). Job scheduling/processing scheduling. C). Input/output handling. D). Memory management. E). Interrupt handling. F). Error handling. G). Job sequencing. 3. A). Command line –user types commands. B). Menu driven – user selects and option. C). Graphical user interface – use selects commands in form of icons with a pointing device. 4. A). User friendliness. B). Easy to learn. 278
279
Answer of review questions 3-2 6. Multitasking – can run more than one program simultaneously while multi user OS allows more than one user to make use of the CPU concurrently. 7. It is a situation in an O/S when a particular task holds a needed resource and refuses to release it for use by other tasks. 8. A). User friendliness. B). Cost. C). Availability. D). Portability. E). Hardware configuration/compatibility. F). User needs. 279
280
Review questions 4 1.Explain the following mouse concept: A). Click B). Double click C). Drag and drop 2.Define the following terms: A). Desktop B). Icon C). Sidekik menu D). Taskbar 3.List and explain the three parts of a task bar. 4.Why is it important to first shut down the computer before you turn it off? 5.Explain how you would move the taskbar to the top of the desktop. 6.With the help of the teacher and a computer running Windows, customise the taskbar such that: A)The start menu is displayed in small icons; B)The clock is not displayed; C)The taskbar is hidden; D)A program is added on or removed from the start menu. 280
281
Answer of review questions 4-1 1. A). Press and release left mouse button. B). Press left and mouse button twice in rapid succession. C). Move an item to another location using the mouse. 2. A). Is mostly an empty screen that appears when Windows starts and has some standard icons that show that the computer is ready for use. B). Is a graphical representation of a command, file, folder or storage location. C). A submenu that appears either on the right or left of a main menu. D). A long strip/icon that runs across the desktop and displays active tasks. 3. A). Start button – provides access to start menu. B). Task manager – displays buttons of currently running tasks. C). System tray – displays icons of applications that automatically start and run in the background. 281
282
Answer of review questions 4-2 4. A). To avoid damaging storage devices that may still be in use. B). To avoid damaging system and application files. C). To avoid loss of data and information. 5. Right click task bar then select properties. In the taskbar properties dialog, check the appropriate options then click Apply button then OK. 6. a). Right click on an empty part on the task manager then properties. b). Use the Task Manager properties. 282
283
Review questions 5-1 1. Define the following terms: A). File B). Folder C). Subfolder D). Folder tree 2. Distinguish between system files and application files. 3. Describe two functions of a file. 4. In reference to Windows operating systems, what does the term application window mean? 5. Explain each of the following commands as used to manage files and folders: A). RenameB). Sort filesC). Copy D). MoveD). Delete 283
284
Review questions 5-2 6. Of the five commands in Question 5, which two must be used with a lot of caution when manipulating files. 7. Why is it important to give descriptive names to a file or folder. 8. Draw a directory tree showing how files and folders are organised by an operating system. 9. Explain how you would: A) Minimise and maximise a window; B) Close and exit and application window; C) Move a window from one location to another; D) Access the folder/directory tree. 10. Briefly explain the importance of each part of a window. 284
285
Answer of review questions 5-1 1. A). A label that represents a logical or physical storage location. B). The rectangular area on the screen covered by a running program. C). Interactive strip at the bottom of an application window that acts as a communication link between the user and the application program. D). Is a row of buttons/icons that represent shortcut commands. E). Is the hierarchical arrangement of folders and storage locations from the root downwards. 2. System files store data/system information while application files hold programs data. 3. Organise data/information records. 285
286
Answer of review questions 5-2 4. It is a rectangular area that is opened in the application program when one wants to enter data in the new file. 5. A). Change name of file/folder. B). Arranges files/folder in particular order. C). Makes a duplicate of existing file/folder. D). Removes file/folder from storage. 6. Rename – renaming an application or system file may make the computer or program to fail. Delete – may lead to loss of data and programs. Move – moving a system folder or file may cause the computer fail. 7. For easy location or identification. 286
287
Answer of review questions 5-3 9. A). minimize – click minimize button. Maximize – click maximize button. B). Click the close button or Exit from “File” menu. C). Point to title bar and drag. D). Right click “My computer” icon then select “Explore” command 10. Title bar – displays title. Toolbars – display shortcut commands. Work area – allow user to enter data. Menu bar – provides a list of commands. Status bar – provides a communication interface between user and the application. 287
288
Review questions 6-1 1. Define the following terms as used in disk management: A). Formatting a disk;B). Disk partitioning; C). Disk compressing;D). Defragmentation; 2. Explain how you would format a used disk in Windows. 3. You have realised that your floppy disk is limited in storage space and you would wish to create more space. A) Which tool in Windows would you use; B) Write down the procedure of doing (a) above. 4. Explain how you would create backup using Windows backup utility. 288
289
Review questions 6-2 5. When you switch on your computer, and realise that it is not loading the operating system. This means that you have to boot up your computer using a startup disk. A) What is a startup disk. B) Using a new diskette, crate a Windows Startup disk and label it “Windows-System Disk” (The dashes represent the version of Windows you are using). 6. Why is hard disk partitioned? 7. Explain how you can partition a 30GB hard disk into 2GB partitions. 289
290
Answer of review questions 6 1. A). It is creation of tracks and sectors on a disk. B). Creating volumes by subdividing a large physical disk. C). Creating more space on a disk by squeezing files into a smaller. D). Consolidating related files into one location on the disk. 2. Right click its icon on the screen then select format command. 3. A). Compression agent or DriveSpace. B). The teacher to give appropriate answer depending on the version of Windows. 4. Right click “My computer” icon then properties. Click tools tab then click Backup now button. 5. A). A special disk that has bootup files. B). Teacher to help pupil to create a startup disk. 6. A). To install more than one operating systems. B). For the purpose of backup. 7. Boot in MS-DOS mode using a startup disk then at the prompt type FDISK and follow the on-screen instructions. 290
291
Revision questions 1. Explain how windows organises information in reference to files and folders. 2. Why must an operating system be installed in the computer before installing any other software. 3. Differentiate between compressing and defragmenting a disk. 4. Give one advantage of partitioning a disk. 5. Explain why a new disk must be formatted before using it. 6. Identify the various resources that are controlled by the operating system. 7. How would you identify the minimum system requirements for the version of Windows running on the computer you are using. 8. Differentiate between scheduling and sequencing of tasks by the operating system. 9. What is troubleshooting? 291
292
Answer of revision questions 1 1. It stores related data and information records into files and related files into folders and sub folders on a drive. 2. Because it does the basic functions of enabling other programs access the hardware resources. 3. Compressing squeezes files to create more space while defragmenting consolidates files and folders in a contiguous space or location on the disk. 4. When one partition fails, the other can still be used. 5. To create tracks and sectors that can be recognized by a particular operating system. 292
293
Answer of revision questions 2 6. (a). The processor. (b). Memory (c). Input/output devices and ports. (d). Communication devices and ports. (e). Secondary storage devices. 7. Read the Manufacturers manual or Readme.txt file form the Windows folder. 8. Scheduling determines which task will be processed first, while sequencing arranges the tasks and keeps a list of currently running tasks. 9. Diagnosing hardware and software related problems and trying to resolve the problems. 293
294
Practical activity 1 1. With the help of the teacher the pupil should identify the type(s) and versions of operating system(s) installed on the computers. 2. Study the start menu and identify the menu items that display other submenus when the mouse pointer points at them. 3. Right click “My computer” icon and list down the commands displayed on the shortcut menu. 4. Click the start button. Explain the importance of each of start menu items displayed. 294
295
Practical activity 2 Using the Explorer window: 1. Create three folders RICE, FRUITS and VEGETABLES in the root of your floppy drive A: 2. In the FRUITS folder, create two subfolders, ORANGE and MANGOES. 3. In fruits folder, create a WordPad file called SALES with the following details: During this season, fruit sales have gone down sue to the prevailing weather conditions. I hope the situation will improve, otherwise people are going to experience health problems since fruits are very important in providing body protection. 295
296
Practical activity 3 1. With the help of the teacher, find out the following from either the Microsoft manuals that come with an original copy of the operating system, or from a special file called Readme.txt found in the Windows folder on the hard disk. A) The minimum requirements for installing the operating system you are using. B) Install a copy of Windows on one of the computers that has no operating systems in he computer room. 2. Give a detailed account of the installation process. 296
297
297 Chapter 2 Data representation in a computer
298
Introduction In digital computers, the user inputs is converted and transmitted as electrical pulses that can be represented by two digits ‘1’ and ‘0’ before processing. These two digits are referred to as Binary digits.
299
Sending data via a telephone line When a digital signal is to be sent over analog telephone lines e.g. e-mail, it has to be converted to analog signal. This is done by connecting a device called a modem to the digital computer. This process of converting a digital signal to an analog signal is known as modulation. On the receiving end, the incoming analog signal is converted back to digital form in a process known as demodulation.
300
Concepts of data representation in digital computers Data and instructions cannot be entered and processed directly into computers using human language. Any type of data entered must first be converted into machine-readable form. (Binary form). Computer together with it’s peripheral devices handle data in it’s electronic circuits, magnetic media and in optical devices.
301
Data representation in electronic circuits Electronic components such as microprocessor are made up of millions of electronic circuits. Availability of a high voltage (ON) in these circuits is interpreted as ‘1’ while a low voltage (OFF) is interpreted as ‘0’.
302
Data representation on magnetic media The presence of a magnetic field in one direction on magnetic media is interpreted as ‘1’ while the absence of magnetic field is interpreted as ‘0’.
303
Data representation on optical media In optical devices, the presence of light is interpreted as ‘1’ while its absence is interpreted as ‘0’. BITS – this is a binary digit, which can either be 0 or 1. it’s the basic unit of data or information in digital computers. BYTE – a group of 8 bits. It is the basic unit of measuring memory size in computers. NIBBLE – it is a half a byte or a group of 4 bits. WORD – its consists of one or more bytes and is the largest amount of memory that the computer can handle. WORD LENGTH – is the number of bits in each word of computer.
304
Reading data on a CD-ROM
305
Types of data representation Number System Base conversion Negative Numbers Binary Addition
306
Types of number systems Decimal Number System Binary Number System Octal Notion Hexadecimal Number System
307
Decimal Number System This number system has ten digits ranging from 0-9. A decimal number should be written with a subscript 10. e.g. 132 10. Each digit of a given number in the base has a place value, which is influenced by base ten. E.g. number 1234 10
308
Binary Number System This number system uses two digits 1 and 0 to represent numbers. The place value of the digits of a base two number is influenced by two (the base/radix). e.g. the place values of the 1010 2 are illustrated below
309
Octal Notation The octal number system consists of eight digits running from 0-7. each digit of a number in base eight has its place value determined by eight. E.g. 2163 8 can be expressed as.
310
Hexadecimal Number System This number system consists of sixteen digits ranging from 0-9 and letters A-F where A is equivalent to 10, B to 11 up to F which is equivalent to 15, in base ten systems. Each digit of a number in base sixteen has its place value expressed in terms of sixteen. For example, the value 12A3 can be expressed as;
311
Base conversion Decimal to Binary Binary to Decimal Number Decimal to Octal From Octal to Decimal Converting Octal to Binary From Decimal to Hexadecimal Hexadecimal to Decimal Hexadecimal to Binary
312
Decimal to Binary 1 To convert a number from base 10 to base 2, the number in base 10 is repeatedly divided by 2 unit the divided is zero on each division the remainder is noted. The remainders are copied bottom up wise to give the binary equivalent of the decimal number.
313
Decimal to Binary 2 For fractional numbers the number is divided into two parts. The whole number part and the fraction part. The whole number is repeatedly divided by 2 while the fraction is repetitively multiplied by 2 until the fraction becomes zero or starts recurring. (Repeating it self)
314
Binary to Decimal Number 1 Steps 1. First write the place values starting from the right hand side. 2. Write each digit under its place value. 3. Multiply each digit by its corresponding place value. 4. Sum up the products.
315
Binary to Decimal Number 2 For fraction number, the whole number is converted to decimal as above. The fraction part digits are divided by multiples of two starting from the decimal point.
316
Decimal to octal 1 To convert a number from base 10 to base 8, the number in base 10 is repeatedly divided by 8, until the dividend is zero each division the remainder is noted.
317
Decimal to octal 2 To convert fractional decimal to octal the procedure is same as for fractional decimal to binary, but the multiplication is by 8 instead of 2.
318
Form Octal to Decimal The procedure is same as from binary to decimal, but the weights as assigned in terms of 8’s. The fractional number are converted to decimal using the same procedure as that of converting fractional binary to decimal, but divisions is by multiplies of eight.
319
Converting Octal to Binary Each digit is represented by 3 binary digits. E.g. 7 is represented as 111 2
320
From Decimal to Hexadecimal 1 The procedure is same as from decimal to binary though divisions are by 16
321
From Decimal to Hexadecimal 2 For the fractional numbers, the fraction part is multiplied by 16.
322
Hexadecimal to Decimal The same procedure as from Binary to Decimal is used with the weights assigned in terms of 16’s. For fractional hexadecimal values. The division is by 16 and the procedure is the same as the binary fraction to decimal.
323
Hexadecimal to Binary
324
Examples of hexadecimal to binary
325
Negative numbers Both positive and negative numbers can be represented in the computer memory during processing. various methods are used to represent negative numbers in the computer. These methods are: i. One’s compliment ii. Two’s compliment The negative numbers are used to carry out subtraction in the computer arithmetic operations.
326
One’s complement (1c method) In this method the binary bits representing the negative number are negated that is the 1’s in the number are changed to 0’s and 0’s to 1’s.
327
Two’s complement (2c method) In this method, the negative number is represented into binary, then complimented as in 1c method but a ‘1’ is added to the least significant digit of the complement value.
328
Signed magnitude In decimal numbers, signed number has a prefix “+” for a positive number e.g. +32 10 and “-” for a negative number e.g. -32 10. in binary, a negative number may be represented by prefixing a digit 1 to the number while a positive number may be represented by prefixing a digit 0. i.e. 17 10 ⇒ 10001 2 (unsigned) -17 10 ⇒ To indicate it’s a negative number we add an extra bit (1) 10001 2 +17 10 ⇒ To indicate it’s positive we add an extra bit (0) 10001 2
329
Advantages of two’s compliment There are no two ways of representing a zero as in one’s compliment and signed magnitude. Effective addition and subtraction can be done even with numbers that are represented with a sign bit.
330
Binary arithmetics Binary addition Binary subtraction Binary multiplication
331
Binary addition Binary addition rules A+B sum+carry 0+0 00 0+1 10 1+0 1 0 1+1 01 1+1+1 11
332
Binary subtraction Binary subtraction rule A-Bdifferenceborrow 0-000 0-111 1-011 1-100
333
Subtraction using ones complements
334
Subtraction using two’s compliment
335
Binary multiplication Multiplication ruleProduct A * B0 0 * 00 0 * 10 1 * 11
336
Examples of binary multiplication
337
Symbolic representation using coding system Binary Coded Decimal (BCD) Extended BCD code / standard BCD code Extended Binary Coded Decimal Interchange Code (EBCDIC) American Standard Code for Information Interchange (ASCII)
338
Binary Coded Decimal (BCD) BCD is a 4 bit code used to represent numeric data only. For example, a number like 3 can be represented using binary coded decimal as 0011 2. BCD is mostly used in simple electronics devices like calculators etc.
339
Extended BCD code / standard BCD code This standard binary coded decimal is an enhanced format of binary coded decimal (BDC) it’s a 7-bit representation scheme which can represent non numeric characters. This allows 64 characters to be represented. For example letter A is represented as 110001 2 using standard BCD code.
340
Extended Binary Coded Decimal Interchange Code (EBCDIC) EBCDIC is an 8-bit character coding scheme used primarily in IBM computers. A total of 256 (2 8 ) characters can be coded using this scheme. For example letter A is represented as 11000001 2 in EBCDIC code.
341
American Standard Code for Information Interchange (ASCII) ASCII is a 7-bit code, which means that only 128 characters can be represented. There is an 8 th bit to this coding scheme which can provide for 256 characters. The 8 th bit coding scheme is referred to as an 9-bit ASCII for example letter A is represented as 1000001 2 in ASCII code
342
Review questions 1 1. Differentiate between analog and digital data. 2. Define the following terms: a. Amplitude b. Frequency c. Periodic time 3. Explain the role of a modem in communication. 4. State the reasons for use of binary in digital technology. 5. Using illustration, explain how data is represented: a. In electronic circuits b. On magnetic media c. On CD-ROM 6. Distinguish between: a. A byte and a nibble b. Word and word length
343
Answer of review questions 1-1 1. Analog data is a type of data that is continuous in nature while digital data is in discrete form. 2. a). Amplitude is the maximum. b). Frequency is the number of cycles per second. c). Periodic time is the time taken by a signal to complete a cycle. 3. A modem converts (modulates) data to be transmitted over the telephone line from digital signal to analog form. At the receiving end, the modem attached to the receiving computer converts (demodulates) the analog signal to original digital form. 4. Devices designed using binary logic are simple, more reliable and consume less energy.
344
Answer of review questions 1-2 5. a). In electronic circuits – availability of high voltage ‘on’ is interpreted as a ‘1’ while low voltage ‘off’ is interpreted as a ‘0’. b). On magnetic media, arrangement of magnetic dipoles of iron oxide in one direction is interpreted as ‘1s” while those that face in the opposite direction are interpreted as ‘0s’. c). On the shiny surface of the CD are pits and lands. When a laser beam falls on the shinny surface, it is reflected and interpreted as a ‘1’. On the other hand, when the laser beam takes on the pit or bump, there is no reflection and this is interpreted as a ‘0’ bit. 6. a). A byte is made up of seven or eight bits while a nibble is made up of four bits i.e. it is half of a byte. b). A word consists of two or more bytes while a word length is used as a measure of the number of bits in each word.
345
Review questions 2 Convert the following base two numbers into denary (base 10) numbers. a. 0101 2 b. 1111 2 c. 10101101110 2 d. 10111111 2 e. 1011011 2 f. 111000111 2
346
Answer of review questions 2 a. 5 10 b. 15 10 c. 1390 10 d. 191 10 e. 89 10 f. 455 10
347
Review questions 3 Using the place value and log division methods convert each of the following base 10 numbers to their binary equivalents. a. 10 10 b. 43 10 c. 365 10 d. 512 10 e. 143 f. 954 10
348
Answer of review questions 3 a. 1010 2 b. 101011 2 c. 101101101 2 d. 1000000000 2 e. 10001111 2 f. 1110111010 2
349
Review questions 4 1. Convert the following binary numbers to their decimal equivalents. a. 0.10011 2 b. 0.0010 2 c. 0.10101 2 d. 11.0110 2 e. 101.11110 2 f. 100.110 2 2.Convert the following decimal numbers into their binary equivalents. a.0.635 10 b.0.450 10 c.2.500 10 d.5.1625 10 e.7.1875 10 f.0.350 10
350
Answer of review questions 4 1. Convert the binary numbers to their decimal equivalents. a. 0.59375 10 b. 0.125 10 c. 0.65625 10 d. 3.375 10 e. 5.9375 10 f. 4.75 10 2.Convert the decimal numbers into their binary equivalents. a. 0.101 2 b. 0.01110 2 c. 10.1000 2 d. 101.001010011 e. 111.0011 2 f. 110101.0101110 2
351
Review questions 5 Convert the following octal numbers to decimal numbers. a. 77 8 b. 64 8 c. 102 8 d. 1200 8 e. 1000 8 f. 173 8 g. 123 8 h. 777 8 i. 345 8 j. 166 8 k. 3458
352
Answer of review questions 5 a. 63 10 b. 52 10 c. 66 10 d. 640 10 e. 512 10 f. 123 10 g. 83 10 h. 511 10 i. 229 10 j. 118 10
353
Review questions 6 Convert the following octal numbers to their binary equivalents. a. 244 8 b. 247 8 c. 162 8 d. 565 8 e. 222 8 f. 3370 8 g. 1413 8 h. 1331 8 i. 6347 8 j. 46653 8
354
Answer of review questions 6 a. 10100100 2 b. 10100111 2 c. 1110010 2 d. 101110101 2 e. 10010010 2 f. 11011111000 2 g. 11000011011 2 h. 1011011001 2 i. 110011100111 2 j. 100110110101011 2
355
Review questions 7 Convert the following hexadecimal numbers into decimal numbers. a. 32 16 b. CCD 16 c. EFE 16 d. 119 16 e. 328 16 f. ABD 16 g. 10AFFD 16 h. DDFF34 16 i. 11ABDF 16 j. CDFF31 16
356
Answer of review questions 7 a. 50 10 b. 3277 10 c. 3838 10 d. 281 10 e. 808 10 f. 954 10 g. 1093629 10 h. 14548788 10 i. 1158111 10 j. 13500209 10
357
Review questions 8 Convert the following hexadecimal numbers into binary form a. 29416 b. 24716 c. EFD16 d. 90716 e. BAD16 f. CBDF16 g. 585C16 h. ABCD16 i. 55C3A16 j. 33111CF16 k. Convert 1111000110111 to its hexadecimal equivalent.
358
Answer of review questions 8 a. 1010010100 2 b. 1001000111 2 c. 1110111111101 2 d. 100100000111 2 e. 101110101101 2 f. 1100101111011111 2 g. 101100001011100 2 h. 1010101111001101 2 i. 1010101110000111 010 2 j. 1100110001000100 0111001111 2 k. IE37 16
359
Review questions 9
360
Answer of review questions 9 1. 10001 2 2. 10110 2 3. 11001 2 4. 110011 2 5. 1011001 2 6. 10101 2 7. 1000111 2 8. 111111 2 9. 1000000 2 10. 11001011 2 11. 1001011 2 12. 1111001 2
361
Review questions 10
362
Answer of review questions 10 1. 1111 2 2. 001 2 3. 10100 2 4. 1001 2 5. 110101 2 1. 11111 2 2. 10 2 3. 1010010 2 4. 11000110 2 5. 10001 2
363
Review questions 11 1. Convert the decimal number -7 to 8-bit binary using ones and twos complement. 2. Using 8-bits length, find the twos complement of the following decimal numbers. A) -31 10 B) -28 10 C) -5 10 3. Using ones and twos complement perform the following arithmetic operations. A) 14 10 – 7 10 B) 28 10 – 12 10 C) 34 10 – 33 10 D) 100 10 – 50 10 E) 102 10 – 64 10
364
Answer the review questions 11 1. 11111001 2 2. A). 11100001 2 B). 11100100 2 C). 11111011 2 3. A). 111 2 B). 10000 2 C). 1 2 D). 110010 2 E). 0100112 2
365
Revision questions 1 1. Explain the two types of data signals. 2. Differentiate between A) Octal and decimal number systems. B) Binary and hexadecimal number systems. 3. Convert the following binary numbers to their decimal equivalents. 1. 101110 2 2. 101011 2 3. 0110 2 4. 10101 2 4.Convert the following decimal numbers to their decimal binary equivalents. A)789 10 B)570 10 C)42 10 D)30 10 5.Find the sum of the following binary numbers. A)1110 2 + 1111 2 = B)001 2 + 100 2 = C)1101 2 + 1011 2 + 100 2 = D)1010 2 + 101 2 = E)111 2 + 11 2 =
366
Answer of revision questions 1 1. Analog and digital 2. A). Octal number system is a base 8 system while the decimal number system is a base 10 system. B). Binary number system is a base 2 system while hexadecimal number system is a base 16 system. 3. A). 46 10 B). 43 10 C). 6 10 D). 22 10 4. A). 1100010101 2 B). 1000111010 2 C). 101010 2 D). 11110 2
367
Revision questions 2 1. Work out the following binary subtraction using direct, ones and twos complement methods. A) 11001 – 1101 B) 1000 – 101 C) 100011 – 111 D) 10101110 – 1000110 E) 10001000110 – 101 2. Find the ones and twos complement of the following decimal number in binary form. A) -75 10 B) -80 10 C) -100 10 3.Determine the value of X in the equations: A)100110 2 – X 2 = 001010 2 B)X 2 + 1101 2 = 70 10 4.Work out the decimal equivalents of the following binary numbers. A)0.10010 2 B)101.11 2 C)11.101 2 D)0.001 2 5.Work out the decimal equivalents of the following binary numbers. A)0.35 10 B)2.50 10 C)0.20 10 D)7.125 10
368
Answer of revision questions 2 1. A). 10101 2 B). 101 2 C). 11100 2 D). 1111 2 E). 1010 2 2. A). 1100 2 B). 011 2 C). 11100 2 D). 1101000 2 E). 10001000001 2 3. A). 11100 2 B). 111001 2 1. A). 0.562510 B). 5.7510 C). 3.62510 D). 0.12510 2. A). 0.0101102 B). 10.12 C). 0.00112 D). 111.0012
369
Revision questions 3 1. Write down the character represented by the following codes: A) ASCII i. 0110000 ii. 0110111 iii. 1000011 iv. 1011001 B) EBCDIC 1. 11110000 2. 11110111 3. 11000001 4. 01011101
370
Answer of revision questions 3 ASCII Char acter EBCDIC Char acter A).01100000111100000 B).01101117111101117 C).1000011C11000001A D).1011001Y01011101) Num ber 1’s complement 2s complement A)-7501101000110101 B)-8001011110110000 C)-10000110110011100
371
371 Chapter 3 Data processing
372
Definition of Terms Data – this is a collection of raw facts (figures, letters, characters etc) that convey little meaning by themselves. Information – this refers to data that has undergone processing and is meaningful to the user when he/she need it, in the form he needs and at the time he/she need it. Data processing – refers to the process of transforming raw facts into meaningful output (information) Data processing cycle – refers to input process output stages that data goes through to be transformed into information.
373
Data processing cycle Data collection Data input Output Processing
374
Stages of data processing cycle 1. Data collection – this involves looking for or getting the data from its point of origin for processing purpose. 2. Data input – this is the process where the collected data is converted from human readable form to machine – readable form. 3. Processing – this is transformation of input data by the central processing unit to a more meaningful output. 4. Output – this is the final activity of data processing cycle which produces the desired output (information). The information is then distributed to the target groups.
375
Interview Questionnaire Observation Record inspection Methods of data collection
376
Stages of data collection Depending on the method of data collection used, the process of data collection may involve the following stages. Data creation Data transmission Data preparation Media conversion Input validation Sorting
377
Data creation This is the process of putting together facts in an organised format. This may be in form of manually prepared documents or captured from the source using data capture devices. E.g. scanners, digital camera etc.
378
Data transmission This refers to the transfer of data from the point of collection (source) of the point where processing is to be done. Transmission can be electronically through computer – to – computer, physically by the post office etc.
379
Data preparation This refers to conversion of data from source document to machine – readable form. Data collected using devices that capture data in digital form do not require transcription conversion.
380
Media conversion Data may need to be converted from one medium to another. E.g. from a compact disk to hard disk for faster input.
381
Input validation Data entered into the computer is subjected to validity and verification checks before processing. Verification – this involves checking that what is on input document is exactly the same as what is entered into the computer. Validation – this is identification and removal of errors by the computer through the control of the program.
382
Sorting The source documents are arranged in a particular order for easy and faster entry.
383
Description of errors in data processing The accuracy of the data entered in the computer determines the accuracy of the information given out.
384
Types of data processing errors Transcription errors – these errors occurs during data entry. These errors includes misreading errors and transposition errors. Computational errors – they occur when an arithmetic operation does not produce the expected results. They include overflow errors, truncation errors and rounding errors. Algorithm or logical errors – these errors occurs as a result of wrong algorithm design.
385
Misreading errors They are brought about by incorrect reading of source document by the user and hence entering wrong values. This may be caused by bad hand writing or confusion on source document. E.g. the number ‘5’ can be typed as s or letter 0 typed as Zero.
386
Transposition errors These errors occurs as a result of incorrect arrangement of characters. i.e. putting characters in the wrong order. E.g. the user may enter 542 instead of 542. transcription errors can be eliminated by use of data capture devices.
387
Overflow errors This errors occurs if the result from a calculation is too large to be stored in the allocated memory space. E.g. if the memory space can accommodate an 8-bit number and the results from arithmetic is 9-bit number.
388
Truncation errors This result from having real numbers that have a long fractional part which cannot fit in the allocated memory space. The computer cut off the extra characters from the fraction part. E.g. a number like 0.854692 can be truncated to four digits as 0.854.
389
Rounding errors This results from a raising or lowering a digit in a real number to the required rounded number. E.g. a number 3.59 can be rounded to 3.6.
390
Data integrity Data integrity refers to the accuracy and completeness of data entered in a computer or received from the information system.
391
Factors that determine data integrity Accuracy Timeliness Relevance Audibility
392
Accuracy This refers to whether information/data is accurate – true or untrue. As long as the correct instructions and data are entered, computers produce accurate results efficiently.
393
Timeliness This refers to whether the information is available when it is needed, and if its outdated when it is received or when it is used. If information is not available when needed or its outdated by the time its used then has little or no value in decision making.
394
Relevance The data entered must be pertinent to the proce3ssing needs at hand and must meet the requirements of the processing cycle.
395
Audibility Audit ability also refers to as verifiability. This is the ability of users to check the accuracy and completeness of information.
396
Threats to data integrity Threats to data integrity can be minimised through the following; Using error detection and correction software when transmitting data. Design user interfaces that minimizes chances of invalid data entry. Using devices that capture data directly from source e.g. scanners etc. Control access to data by enforcing security measures. Back up data preferably on external storage media.
397
Data processing methods Data can be processed using one of the following methods. Mechanically Manually Electronically
398
Manual data processing In this method staff in an organisation uses the laid down procedures and rules to collect data, process and distribute information to relevant departments for use. The tasks are done manually with a pen and a paper. No machines are used to process data instead they use simple tools like tables and rulers.
399
Mechanical data processing Mechanical systems are those where staff use various mechanical machines like calculators, typewriters, cash registers duplicating machines etc to perform operations.
400
Electronic data processing In this system, data is manipulated using electronic machines to produce information. This method is faster and more accurate than the manual and mechanical where large volumes of data are to be processed. This method involves the use of computers and other electronic machine like mobile phones, washing machines, modern digital TVs etc.
401
Factors determining the methods of data processing Size and type of business Timing aspects Link between application
402
Computer files A file is a collection of related records that give a complete set of information about a certain item or entity. A file can be stored manually in a file cabinet or electronically in a computer storage device.
403
Advantages of computerized filling system Information takes up less space than the manual system. Enhance data integrity and reduces duplication. Offers faster access and retrieval of data. It’s much easier to update or modify information.
404
Elements of a computer file A computer file is made up 3 elements. Characters – this is the smallest element in a computer file and refer to a letter, number, symbol that can be entered, stored and output by a computer. Field – a field is a single character or a collection of characters that represents a single piece of data. For example in employees record, the name of employee is a field. Records – is a collection of related fields that represents a single entity. For example in employees record, details of each employee in a row. E.g. Name, IDNO, sex, Department etc make up a record. Computer files can be viewed in two ways.
405
Logical file This is the way the user views the file in terms of its contents and the processing to be carried upon them.
406
Physical file This is the actual arrangement of the file contents into the storage media surface and how the processing operations are made possible.
407
Types of computer processing files Master file Transaction file (movement file) Reference file Sort file Back – up file Report file
408
Master file This is the main file that contains permanent records about a particular item or entries. The master file contains both static and dynamic fields. For example a payroll system might keep a master file containing employees personal details (name, address, date of birth, sex etc) which rarely change (static fields) and data describing the earnings and deductions which frequently change (dynamic fields).
409
Transaction file (movement file) This file includes input and output files for holding temporary incoming or outgoing data. It contains data about an organisation activities taking place for some period of time. This file is used to update dynamic data on master files.
410
Reference file They are permanent or semi permanent and are used for reference or look up purposes. They contain records that are fairly static. E.g. price, lists, Pay As You Earn etc.
411
Sort file These files are created from existing transaction or master files. They are used where data is to be processed sequentially. Data or records are first sorted in a particular format for example they are arranged in ascending or descending order of the key field and stored in the sort file.
412
Back – up file These files are duplicate copies of existing files. They are used to supplement the operational files in case of loss by any reason. They are created any time and update is carried out on the master file.
413
Report file They contain sets of records extracted from data in the master files. They are used to prepare reports that can be printed at a later date, for example, list of absentees, overtime etc.
414
File processing activities 1 Updating – refers to changing data in master file to reflect the current status. Referencing – happens when it is made to particular records to ascertain what is contained therein. The activity does not alter the contents of master file from a file. Sorting – this entails arranging of file contents into some pre – determined sequence of the key field, which occupy the same position on the records.
415
File processing activities 2 Merging – the process that combines the contents of two or more input files into one output files. Matching – the input files records are matched/compared to ensure that records exist in both the files. Summarizing – the records of interest from the file are accumulated to form a record in the output file. Searching – it entails looking for the record of interests from the file.
416
File updating 1 Hit rate – hit rate is used to describe the rate of processing of a master file in terms of its active records. For example, if 600 transactions are processed each day against a master file of 12,000 records, then the hit rate is said to be 5% i.e. 600/12000*100
417
File updating 2 Volatility – this is the frequency with which records are added to the file or deleted from it. If the frequency is high, then the file is said to be ‘volatile’ otherwise ‘static’. Size – refers to the amount of data stored in the file. Its expressed in terms of the total number of records in the file. Growth – files will always grow as new records are added to it.
418
File organisation methods File organisation is the arrangements of records within a particular file. There are four methods of storing files and retrieving them from secondary storage devices.
419
Sequential file organisation In this organisation records are stored and accessed in a particular order sorted using key field. The key field is used to search for a particular record. Searching commences at the beginning of the file and proceeds to the ‘tail’ of the file until the record is reached. Mainly used with magnetic tapes.
420
Advantages of sequential file Simple to understand the approach. Easy to organise, maintain and understand. Reading a record requires only the key field. Inexpensive input/output media and devices are used.
421
Disadvantages of sequential file Entire file must be accessed even when the activity rate is very low. Random enquires are impossible to handle. Data redundancy is typically high.
422
Random or direct file organisation In this organisation records are stored randomly but accessed directly. To access a file stored randomly, a record key is used to determine where a record is stored on the storage media. Used in magnetic and optical disks.
423
Advantages of random or direct file Records are quickly accessed. File update is easily achieved. They do not require the use of indexes.
424
Disadvantages of random or direct file Data may be accidentally erased or over written. Unless special precaution taken. Expensive hardware and software resources are required. Relative complexity of programming. System design around it is complex and costly.
425
Serial file organisation The records are laid out contiguously one after the other in no particular sequence. The records are stored one after the other in the same order they come into the file and there exists no relationship between contiguous records. Used with magnetic tapes.
426
Indexed sequential file organisation This method is similar to sequential method, only that an index is used to enable the computer to locate individual records on the storage media. Used with magnetic disk.
427
Advantages of indexed sequential file Records can be accessed sequentially or randomly. Records are not duplicated. Accessing of records can be fast if done randomly.
428
Disadvantages indexed sequential file Storage medium is rather expensive. Accessing records sequentially is time consuming. Processing records sequentially may introduce redundancy.
429
Electronic data processing modes On-line processing Time sharing processing Real time processing Multi-programming / multi-tasking Distributed processing Batch processing Multi-processing Interactive processing
430
On-line processing In this processing the result of data processing is available immediately. All the computer peripherals and equipments are under the direct control of the central processor. As soon as the input transactions are available, they are processed to produce the required information. The user can interact with the system at any time of processing using input/output facilities.
431
Application of on-line processing Banking Stock exchange Stock control Water/electricity billing
432
Advantages of on-line processing Files are maintained up to date. Information is readily available for current decisions. File enquiries possible through the terminals (work station)
433
Disadvantages of on-line processing System are complex to develop. Are costly in terms of hardware, software, storage media etc.
434
Time sharing processing In this mode the central processor serves two or more users with different processing requirements (tasks). The central computer is available to a variety of uses, connected to the central computer via communication links who may wish to process their data and receive information. The processor time is divided out appropriately among the user task is into time slices. Control is switched from one job to another, under the influence of the operating system. The time slice is equal for all jobs and it’s assigned to jobs waiting in a queue. In one turn, only one slice is allocated to the job. The jobs in the queue are assigned the time slice from the head of the queue towards the tail. Jobs that require more time slices are chained to the tail queue. New jobs into the queue are added at the tail of the queue. The wholly processed jobs output results. The incomplete jobs go back to the tail of the queue to await their next turn.
435
Application of time sharing processing Bureau Learning institutions. Companies.
436
Advantages of time sharing processing Better services to the users, for the information/output is fast. Files enquiries is possible since files are held on-line. User interaction is possible through terminals.
437
Disadvantages of time sharing processing User has no control over the central computer. Not reliable with regard to data security. Response time is slow where there are many tasks.
438
Real time processing In this mode, computer processes the incoming data as soon as it occurs, updates the transactions file and gives an immediate response that would affect the events as they happen. The main purpose of a real time processing is to provide accurate, up to date information hence better services based on a real situation.
439
Application of real time processing Air reservation Hotel reservation Chemical plant processing
440
Advantages of real time processing Information is readily available for instant decision. Provides immediate control / information. Its fast and reliable.
441
Disadvantages of real time processing Requires complex and expensive operating system. They are not easy to develop. Require Front End Processors (FEPS) to relieve the ventral processor.
442
Multi-programming / multi-tasking In this processing more than one program are executed apparently at the same time by a single central processing unit. The operating system allocated each program a time slice and decides what order they will be executed.
443
Advantages of multi-programming / multi-tasking Increases the productivity of the computer by reducing CPU idle time. Reduces the incidence of peripheral bound operations.
444
Disadvantages of multi-programming / multi-tasking Requires more expensive CPUs. Operating system is complex and more difficult to operate.
445
Distributed processing This processing refers to dividing (distributing) processing tasks to two or more computers that are located on physically separate sites but connected by data transmission media. For example, a distributed database will have different tables of the same database residing on separate computers and processed there as need arises.
446
Application of distributed processing Banks where customers can be served from different branches but information is updated at the head branch.
447
Advantages of distributed processing Less risk to system breakdown. In case of data loss, only a small portion of the data is lost. Reduction of the load on the host. computer hence faster processing.
448
Disadvantages of distributed processing Expensive due to extra communication costs. More sophisticated software required to maintain data integrity.
449
Batch processing This is processing mode where the transactions are accumulated over a period of time and then proce3ssed at a pre-specified time to produce a batch of output. The data to be processed e.g. daily, weekly, monthly etc then processed at once.
450
Application of batch processing Payroll processing.
451
Advantages of batch processing Simple to develop. Timing reports is not a necessity. The unit cost of processing is low.
452
Disadvantages of batch processing Time lag between origination of the transactions and the information availability. Late information is not suitable in situations where instant decisions are requires. Its difficult to provide the desired priority scheduling.
453
Multi-processing This refers to the processing of more one task at the same time on different processors of the same computer. In such systems, a computer may contain more than one independent central processing unit which works together in a coordinated way. At a given time the processor may execute instructions from two or more different programs or from different parts of one program simultaneously.
454
Interactive processing In this processing, there is continuous dialogue between the user and the computers. As the program executes, it keeps on prompting the user to provide input or respond to prompts displayed on the screen.
455
Factor to consider in selecting the data processing mode The need for direct information retrieval and/or file interrogation. The control over the resources e.g. files, input/output devices. The cost of acquiring the relevant hardware, software, media etc. The optimization of the processing time. The time factor of the information for decision making by mangers.
456
Review questions 1 1. Define the following terms: A) Data processing. B) Data processing style. 2. Using an illustration, describe the four primary stages of the data processing cycle. 3. Outline the stages of data collection. 4. You may have come across the term Garbage In Garbage Out (GIGO). What is its relevance to errors in data processing. 5. Explain the two types of transcription errors. 6. State three types of computational errors. 7. Define the term data integrity. 8. Give three factors that determine the integrity of data. 9. State at least five ways of minimising threats to data integrity.
457
Answer of review questions 1-1 1. A). Data processing refers to the transformation of raw data into meaningful output (information). B). Data processing cycle are the stages that data goes through during its transformation into information. The output may be used later as input to another processing task. 2. Data collection → data input → data processing → output. 3. A). Data creation. B). Data transmission. C). Data preparation. D). Media conversion. E). Input validation. F). Sorting.
458
Answer of review questions 1-2 4. The accuracy of data entry determines the accuracy of the output. 5. A). Wrong entry due to misreading the source data e.g. entering C instead of G (transcription error). B). Transposition – interchanging values e.g. 396 instead of 369. 6. Overflow and underflow. Truncation. Rounding. 7. A). Data integrity refers to accuracy and completeness of data. B). Accuracy, timeliness and relevance. C). Banking up, enforcing security, using input devices that capture data directly from the source etc.
459
Revision questions 1. Distinguish between data and information. 2. Describe types of data processing methods. 3. State at least four advantages of storing data in computer files over the manual filing system. 4. State elements that make up a computer file. 5. Differentiate between a logical file and physical file. 6. Explain at least six types of computer files. 7. Distinguish between A) Sequential and serial file organisation methods. B) Random and indexed-sequential file organisation methods. 8. Describe at least five types of electronic data processing modes.
460
Answer of revision questions 1 1. Data refers to raw facts that do not have much meaning while information refers to the meaningful output after processing. 2. Data processing methods: manual, mechanical and electronic. 3. A). Takes up less space. B). Easier to update or modify. C). Faster access and retrieval. D). Enhances integrity. 4. A). Characters. B). Field. C). Record. 5. A logical file is viewed in terms of what data items and processing operation may be performed on the data while a physical file is viewed in terms how data is stored and how it is to be processed. 6. A). Master file. B). Transaction file. C). Reference file. D). Backup file. E). Report file. F). Sort file.
461
Answer of revision questions 2 1. In sequential file organisation, records are stored in a sorted order using a key field while in serial file organisation, records are not sorted in any way. 2. In random file organisation, records are stored randomly but accessed directly. On the other hand, in indexed-sequential, records are stored sequentially but accessed directly using an index. 3. On-line distributed – the data being processed is accessed, processed and updated in real time. 4. Time-sharing-competing computers are allocated time slots to use computer resources. 5. Batch processing – all the available jobs are processed in bulk all at once. 6. Interactive processing – the computer presents the user with input screens / the user inputs data as processing continues. 7. Real time – data being processed is updated online and the results thereof affect current processing logic. 8. Multi-tasking – several computer programs / tasks run concurrently at the same time sharing resources in shifts. 9. Multiprocessing – several programs / tasks run concurrently on different processors.
462
462 Chapter 4 Elementary programming principles
463
Introduction Human beings have evolved from the stone age to a highly sophisticated and advanced society by inventing things like the wheel, fire, transistors and today’s ultra modern devices like computers. The idea of computers started way back in the nineteenth century. The first generation computers called Electronic Numeric Integrator And Calculator (ENIAC 1) were operated by plugging wires into a control panel that resembles the old telephone switchboards.
464
Computer programming A program – is an organised list of statements (instructions) that when executed, causes the computer to behave in a predetermined manner or carry out a defined task. Programming – refers to the process of developing computer (instructions) programs used to solve a particular task. A computer program – is designed using a particular programming language. Each language has a special sequence or order of writing characters usually referred to as syntax.
465
Terms used in programming Source program Object code Translator Assembler Interpreter Compiler
466
Source program This refers to the program code that the programmer enters in the program editor window that is not yet translated into machine-readable form.
467
Object code This refers to the program code that is in machine-readable. i.e. a source code that has been translated into machine language.
468
Translator These are programs that translates/convert the source program into object code. E.g. assemblers, compliers, interpreters etc.
469
Assembler An assembler translates a program written in assembly language into machine language,
470
Interpreter This translates the source program line- by-line, allowing the CPU to execute one line before translating the next. The translated line is not stored in the computer memory, hence every time the program is executed, it has to be translated.
471
Complier This translates the entire source program into object code. The compiler translates each high-level instruction into several machine code instructions in a process called COMPILATION and produces a complete independent program that can be run by the computer as often as required without the original source program being present.
472
Difference between the interpreters and compilers InterpretersCompilers Translates the source program one statement at a time. Translates the entire source code at once before execution. Translates the program each time it is run hence slower than compiling. Compiled program (object code) can be saved on a storage media and run as required, hence executes faster than interpreted programs. Interpreted object code takes less memory compared to compiled program. Compiled programs require more memory as the object file are larger.
473
Level of programming languages There are 2 major levels namely; Low-level languages. High-level languages.
474
Low-level languages These languages are classified as low because they can be easily understood by the computer directly or they require little effort to translate into computer understandable form. These languages are hardware oriented and therefore they are not portable. i.e. a program written for one computer cannot be installed and used on another.
475
High-level languages These languages are very close to the human language (English-like) and they can be read and understood even by people who are not experts in programming. These languages are machine independent. This means that a programmer concentrates on problem solving during a programming session rather than how a machine operates.
476
Types of low level languages Machine language (First generation languages). Assembly languages (Second generation languages)
477
Machine language (First generation languages) In this language, instructions are written using binary logic. Given that data and instructions are in binary form, many lines of codes are needed to accomplish even a simple task like adding two numbers i.e. a program written in this language look like this. 11100110 00000011 19999991 00001111 10001101 10001111 11111111 10000011 The program code is hard for human to understand but it’s easily understood by computers.
478
Assembly languages (Second generation languages) This language is close to the machines vocabulary rather than human beings vocabulary. It was developed in order to overcome the difficulties of understanding and using machine language. This language helps the programmers to write programs as a set of symbolic operation codes called Mnemonics. Mnemonics are basically shortened two or three letter words. A sample program written in Assembly language. MOVAX,15(move 15 to register Ax) SUBAX,10(Subtract 10 from the value Ax) Programs written in this language require an assembler to convert them into machine language.
479
Classes of high level languages Third generation languages (3GLS) Forth generation languages (5GLs) Fifth generation languages (5GL’s) Object Oriented Programming Language (OOP) Web scripting languages
480
Third generation languages (3GLS) This generation languages is also called structured or procedural languages. A procedural language makes it possible to break a program into components called modules. Each performing a particular task. Structured programming has advantages because its flexible, easier to read and modify.
481
Examples of third generation programming language Pascal – was developed to help in the teaching and learning of structured programming. Fotran – was developed for mathematics, scientists of programs with mathematical expressions. Cobol – was designed for developing programs that solve business problems. Basic – developed to enable students to easily learn programming. C – used for developing system software e.g. the operation systems. Its very powerful high level language because of its ability to provide programmer with powerful aspects/features of low level. Ada – this language is suitable for developing military, industrial and real – time systems.
482
Forth generation languages (4GLs) This generation make programming an even easier task than the third generation language because they present the programmer with more programming tools. Examples of such tools are command buttons, forms etc. the 4 GLs are easy to learn and understand because they are user based. The languages syntax (grammar) is natural, near English language and use menus to prompts to guide a non-specialist or retrieve data with ease.
483
Examples of 4GLs Visual Basic Delphi Pascal Visual Cobol C++
484
Fifth generation languages (5GL’s) These languages are designed around the concept of solving problems by enabling the computer to depict human like intelligence. These programs are designed to make the computer solve the problem for the programmer rather than programmer spending a lot of time to come up with the solution.
485
Examples of 5GL’s PROLOG MERCURY LISP OCCAM
486
Object Oriented Programming Language (OOP) The concept behind OOP languages is to look at a program as having various objects interacting to make up a whole. Each object has a specific data values that are unique to it (called state) and a set of the things it can accomplish called (functions or behaviour). This process of having data and functions that operate on the data within an object is called Encapsulation. Several objects can then be linked together to form a complete program. OOP has greatly contributed to development of Graphical user interface operation system and application programs.
487
Examples of OOP Java Simula Small talk
488
Web scripting languages These languages are used to develop or add functionalities on web pages. Web pages are hypertext documents created in a language called HyperText Markup Language (HTML). The languages consist of markup tags that tell the Internet browser that the file contains HTML-code information and is distinguished by a file extension of HTML. The markup tags define the various components of a World Wide Web document such as heading, tables, paragraphs, lists etc. HTML does not have the declaration part and control structures, hence it’s not considered as a true programming language. Due to its simplicity, it has many limitations and cannot be used alone when developing functional websites. Some special blocks of codes called Scripts may be inserted in HTML pages using scripting languages like JavaScript, VBScript etc in order to add functionality to HTML pages.
489
Examples of HTML tags and their meanings TagMeaning Marks the beginning and end of a HTML document. All other tags and text fall between these two tags. Marks the header part of the document. Gives title of te web page. Text between this tags appears in the title bar when the page is browsed. Marks the body part of the document. Centres text and objects on the web page. Bolds the text on the web page. Italicise the text. Sets size of text on the web page with H6 displaying the smallest and H1 the largest size.
490
Creating a script using Javascript 1 Javascript is a popular scripting language. Before writing your HTML program with a script inserted, make sure that you have the latest browser software installed on your computer. Older browsers may not have support for Javascript. If you are using Internet Explorer, it should be version 5.0 and above.
491
Creating a script using Javascript 2 Open Notepad and key in the following program. Do not write the numbers to the left of each line of code. 1. 2. 3. Scripting Example 4. 5. 6. we are the world 7. LANGUAGE=‘JavaScript’> 8. document.write(‘My name is strongman’); 9. alert(‘congratulations for succeeding to run this script’); 10. 11.
492
Creating a script using Javascript 3 After typing the entire program, save your file on the desktop as Example.html and then close the notepad. Notice that the icon to your file on the desktop look like that of the default web browser in your computer. To view the web page, double click the icon of the file Example.html on the desktop. Figure right shows as open webpage.
493
Explanations of JavaScript
494
Advantages of low-level languages The CPU understands machine language directly without translation. They are stable and hardly crash or breakdown once written. Running a program is fast, no compilation is needed. They are economical in terms of the amount of memory they use.
495
Disadvantages of low-level languages They are difficult and cumbersome to use and learn. Require highly trained experts to both develop and maintain programs. Debugging programs is difficult. They are machine dependent. The programs are long.
496
Advantages of high-level languages The programs are portable (not machine dependent). They are user friendly and easy to use and learn. They are more flexible. They are easy to debug. They provide better documentation. Require less time to code.
497
Disadvantages of high-level languages Program executed more slowly. Require larger CPU storage capacity for compilation. They have to be translated to machine readable form before
498
Program development There are six stages of program development. They include: Problem recognition Problem definition Program design Program coding Program testing Program implemetation Documentation
499
Problem recognition This refers to the understanding and interpretation of a particular problem. To understand a problem one has to look for key words such as compute, evaluate, compare etc. a programmer identifies problems in the environment and seeks to solve them by writing a computer program that would provide the solution.
500
Circumstances that can cause the programmer to identify a problem Opportunity to improve the current program. A new directive given by the management requiring a change in the status quo. Problems or undesirable situations that prevent an individual or organisation from achieving their purpose.
501
Problem definition At this stage the programmer tries to determine or define the likely input, processing and expected output using the keywords outlined at the problem recognition stage. The boundaries of the expected program are established and if several methods to solve the same problem are identified the best alternatives should be chosen. At the end of the stage requirement documentation for the new program is written.
502
Program design This is the actual development of the program’s processing or problem solving logic called algorithm. (A limited number of logical steps that a program follows in order to solve a problem). The programmer comes up with an algorithm after analysing the requirements specifications. Some of the programs are made up of one large block code. i.e. they are Monolithic while others are made of several units called modules which work together to from the whole program. In modular programming, each module performs a specific task. This approach makes a program flexible, easier to read and debug. This phase enable the programmer to come up with models of the expected program. The model show the flow of events and data throughout the entire program from input of a program.
503
Monolithic and modular program
504
Program coding This is the actual process of converting a design model into its equivalent program. This is done by creating the program using a particular programming language. The end result of this stage is a source program that can be translated into machine readable form for the computer to execute and solve the target problem.
505
Program in Pascal and C++ Program in PascalProgram in C++ Program AreaCircle (input, output); Const Pi = 22/7; Var Radius, Area: real; Begin WriteIn (‘Enter the radius’); ReadIn (radius); Area: = Pi *Radius *Radius; WriteIn (‘The area is’, Area) End. #include double radius, area; double pi = 22/7; main () { cout<<‘Enter the radius’; cin>>radius; area = pi *radius *radius cout<<‘The area is’, area; return 0; }
506
Explain the program codes 1 Pascal codeC++ codeExplanation Program Areacircle (input, output); #include The header of the programs. The statements in () and <> shows that the user inputs data via the keyboard and the program display information on the screen. Const Pi = 3.142;double pi = 3.142;A constant has been declared with a name pi and value 3.142. Var Radius, area:real double area, radius;Real variables with fractional part have been declared.
507
Explain the program codes 2 Pascal codeC++ codeExplanation Begin{Marks the beginning of the program body or executable statements. WtiteIncout<< ’ Enter radius ’ :Display on the screen the string between inverted commas. ReadIn (Radius)cin>>radius;Displays a blinking cursor that tells the user that an input is needed before the program can continue.
508
Explain the program codes 3 Pascal codeC++ codeExplanation Area: = Pi * Radius * Radius area = pi * radius * radius; Calculates the area. Notice the assignment statement in Pascal is : = while in C++ it is = WriteIn (‘The area is’, Area); cout<<”The area is’, Area<<” ∖ n”; Display the value stored in the variable Area. End.return 0; } Marks the end of the program
509
Program Testing and Debugging After coding the program has to be tested and the errors detected and corrected. Debugging refers to detection and correction of errors that may exist in the program. Program testing involves creating test data designed to produce predictable output. They are two types of errors (bugs) that can be encountered when testing.
510
Types of errors (bugs) Syntax errors – they occur as a result of improper use of language rules. E.g. grammar mistakes, punctuation, improper naming of variables etc. these errors are detectable by translator and must be corrected before the program runs. Logical errors – they are not detectable by the translator. The program rules but gives wrong out put or halts during execution.
511
Methods of errors detection Desk checking / dry – run. Using Debugging utilities. Using Test Data. Implementation and maintenance Implementation. Review and maintenance. Program documentation.
512
Desk checking / dry – run It involves going through the program while still on paper before entering it in the program editor.
513
Using Debugging utilities In the program editor, you can run the debugging utilities during translation to detect syntax errors.
514
Using Test Data The programmer carries out trial runs of the new program. At each run he enters various data variations and extremes including data with errors to test whether the system will grid to a halt. A good program should not crash due to incorrect data entry but should inform the user about the anomaly.
515
Implementation and maintenance implementation This is the actual delivery and installation of the new program ready for use, creating data files and train people to use the system. The new system will change the way things are done hence it should be reviewed and maintained.
516
Review and maintenance This stage is important because of the errors that may be encountered after implementation. A program may fail due to poor use, hence proper training and post implementation support of users will reduce chances of having them entering invalid data that crash the program.
517
Program documentation This is writing of support materials explaining how the program can be used by users, installed by operators or modified by other programmers. All stages of program development should be documented in order to help during future modification of the program.
518
Types of documentation User oriented documentation – these type enables the user to learn how to use the program as quickly as possible and with little help from programmer. Operator oriented documentation – meant for computer operators. E.g. Technician. It helps them to install and maintain the program. Programmer oriented documentation – written for skilled programmers. It provides necessary technician information to help in future modification of program.
519
Development of algorithms Algorithms – refers to a limited number of logical steps that a program follows in order to solve a problem. Pseudocode – refers to a set of statements written in a readable language (English – like) but expressing the processing logic of a program.
520
Guidelines for designing a good pseudocode The statements must be short, clear and readable. Pseudocode lines should be clearly outlined and indented clearly. It should show clearly the start and stop of executable statements and control structures. Statements must not have more than one meaning.
521
Examples of Pseudo code Solution START Print “Enter two numbers” Input x,y Sum – x + y Average = sum / 2 PRINT sum PRINT Average STOP Write of Pseudo code that can be used to prompt the user to enter two numbers, calculate the sum and average of the two numbers and then display the output on the screen
522
Program flowcharts A flowchart is a diagrammatic representation of a program in algorithms. It uses statements and symbols that have specific meaning. The symbols are of different standard shapes linked to show the order of processing. Each shape contains note stating what the operation is.
523
Most common program flowcharts Ellipse: denotes the beginning and end of the program algorithm. Parallelogram: used to denote an input or output operation. For example, READ A,B, PRINT SUM =A+B Rectangle: indicates that a processing or data transformation is taking place. For example SUM =A+B. Rhombus: used to specify a condition. A condition must evaluate to a boolean value (True or false) for the program to execute the next instructions. Connector: used as a connecting point or interface for arrows coming from different directions. Arrow: used to indicate the direction of flow of the program logic.
524
Guidelines for drawing a flowchart There should be only one entry and one exit point of a program algorithm. Use correct symbol at each stage in the flowchart. Avoid crossed flow lines. Be as neat and tidy in drawing as possible. General direction of flow in any flowchart is from top to bottom, left to right.
525
Examples of flowchart Solution Draw a flowchart for a program used to prompt the user to enter two numbers. The program should find the sum, and average then display the output. Sum = X + Y Average = Z + y/2
526
Types of flowchart System flowchart – it’s a chart that depicts the systems as a whole with only subsystems or major elements shown, Program flowchart – this chart shows the sequence of operations as carried out by a computer program.
527
Advantages of flowchart Gives programmer good visual reference of what the program will do. Serves as a program or system documentation. It’s easy to trace through from the start to find the action resulting from a set of condition. Allows programmers to test alternative solutions to a problem without over coding the program.
528
Disadvantages of flowchart There are so many different ways to draw them. it’s difficult to remain neat and uncluttered if the logic is complex. Constructing a flowchart is time consuming. They take up considerable space. They are difficult to amend without redrawing.
529
Comparison between a pseudocode and a flowchart
530
Program control structures They are blocks of statements that determine how statements are to be executed. There are three control structures namely. Sequence Selection decision Iteration (looping) repetition
531
Sequence In this control structure, the computer reads instructions from a program file starting from the first top line and proceeding downwards one by one to the end. Hence sequential program execution enables the computer to perform tasks that are arranged consecutively one after another in the code.
532
Example of how a sequential programs code execute The program file reader reads Begin {Procedure name} sequentially Action 1 statement Action 2 by Action n statements End {Procedure name} to the end of the file
533
Selection/decision This structure is used to branch, depending on whether the condition returns a value of True of False (Yes or No). For example IF Then Action 1 Else Action 2 Endif. There are 4 types of selection controls used in high-level programming. IF……….THEN IF……THEN……ELSE Nested IF CASE SELECTION
534
IF……….THEN General format IF Then Statement: EndIf If Mark > = 80 then Print “Reward” EndIf This is used if only one option is available. All other options are ignored. For example if a school wants to reward only the students who have mean mark of 80 and above, it will be reward only those students who have attained 80% and above and ignore the rest.
535
IF……….THEN……….ELSE General Format IF THEN Statements 1 ELSE Statements 2 EndIf The algorithem will be:- IF fault = Serious THEN Print “RED CARD” ELSE Print “yellow Card” EndIf Used when there are two available options. For example in a football match a player is given a RED CARD if he does a very serious mistake otherwise he is given a Yellow Card.
536
Nested IF This is used where two or more options have to be considered to make a selection. For example, to award grades according to the marks as follows a. 80 marksGrade A b. 60 marksGrade B c. 50 marksGrade C d. 40 marksGrade D
537
General format of Nested IF General Format IF Then Statement ELSE IF Then Statement ELSE IF Then Statement Endif End The pseudo code segment will be:- If Marks = 80 THEN Grade = “A” ELSE If Marks = 60 THEN Grade = “B” ELSE If marks = 50 THEN Grade = “D” Endif End
538
CASE SELECTION General format CASEx of Label 1 : Statement1 Label 2 : Statement2 Label n : Statement n-1 ELSE Statement n End case Example:- CASEaverage OF 80…100:Grade=“A” 70…79:Grade=“B” 60…69:Grade=“C” 40…49:Grade=“E” ELSE Grade=“F” End Case It’s an alternative to the nested IF. This selection is preferred to the Nested if in order to reduce the many line s of codes. Case selection can only be expressed using integers and alphabetic characters only. The Boolean expression should be CASE integer OF or CASW char OF
539
Iteration (looping) repetition This is designed to execute the same block of code again and again until a certain condition is fulfilled. Iteration is important in situations where the same operation has to be carried out on a set of data many times. There are three main looping controls. THE-WHILE-DO LOOP REPEAT……….UNTIL LOOP The FOR LOOP
540
The WHILE loop Used where a condition has to be met before the loop statements are executed. Example To withdraw money using an ATM a customer must have a balance in his/her account.
541
General format of THE WHILE LOOP Flowchart General format While Do Statement End while Pseudo code segment While balance >0 do Withdraw cash Update account End while Withdraw cash update account
542
REPEAT……….UNTIL LOOP Used where the loop statements are to be executed before a condition is met. Example Pseudo code segment. REPEAT Withdraw cash Update account UNTIL balance <0;
543
General format of REPEAT…………UNTIL LOOP Flow chart General format REPEAT Statement UNTIL Withdraw cash update account.
544
The FOR LOOP Used where the loop statements are to be executed repeatedly a predetermined number of times.
545
Pseudo code of the FOR LOOP Pseudo code FORcount = 1 to 10 DO writeln “Enter a number (N)” ReadlnN Sum = sum + N End FOR Display Sum The counter has to be set to a start value and sometimes to an end value.
546
General format of the FOR LOOP General format 1. format for the FOR LOOP that counts from lower limit. For loop variables = lower limit To upper limit Do Statements EndFor 2. Format for the ‘For’ loop that counts from upper limit down to lower limit For loop variable = Upper limit Down To Lower Limit Do Statements EndFor
547
Flowchart for a For Loop that counts upward Loop Variable = lower limit Lower limit = Loop variable + 1 Statement
548
Flowchart for a For Loop that counts downwards Loop Variable = Upper limit Upper limit = Loop variable - 1 Statement
549
Examples of complex pseudo codes 1 Ushirika Society pays 5% interest on shares exceeding Kshs 10,000 and 3% on shares that do not meet this target. However no interest is paid on deposits in the member’s bank account. Design a pseudo code for a program that would: a. Prompt the user for shares and deposit of a particular member. b. Calculate the interest and total savings. c. Display the interest and total savings on the screen for a particular member.
550
Pseudo code of examples 1 Pseudo code Start Input Name, share, Deposit If share > 10000 THEN Interest = 0.05*shares ELSE Interest=0.03*shares Endif Total savings = deposits + Interest + shares Print Name, Totalsaving, Interest Stop
551
Flowchart of example 1 Totalsavings = deposit + shares + interest Interest = 0.05 * shares Interest = 0.03 * shares
552
Examples of complex pseudo codes 2 Botswana has a population of 3,000,000 but this is falling by 4% each year. The island of Reunion has a population of 95,000 but this is increasing by 9% each year. a. Draw a flowchart that predicts the year in which the population of reunion will be greater than that of Botswana if the trend continues.
553
Solution of example 2
554
Pseudo code of example 2 Pseudo code Start Bts: = 3,000,000 1R: = 95,000 Year: = 0 REPEAT Bts = Bts - (Bts * (4 / 100)) 1R = 1R + (1R * (9 / 100)) Year = year + 1 UNTIL 1R > Bts Print year Stop
555
Examples of complex pseudo codes 3 Write a program that will allow the input of name of student marks obtained in 5 subjects (maths, English, Kiswahili, computer, biology). The program should calculate the total and average marks for each student and assign the grades depending on the average marks obtained as follows. 80 – 100A 70 – 79B 60 – 69C 50 – 59D Below 50E The program should then display each student’s name, total marks and average grade.
556
Pseudo code of example 3 Pseudo code START REPEAT Print “Enter name and subject marks” Input Name, maths, English, Kiswahili, Computer, Biology Sum = Maths + English + Kiswahili + Computer + Biology AVG = sum / 5 If (AVG>80) AND (AVG<100) THEN Grade = ‘A’ If (AVG>70) AND (AVG<79) THEN Grade = ‘B” If (AVG>60) AND (AVG<69) THEN Grade = ‘C’ If (AVG>50) AND (AVG<59) THEN Grade = ‘D’ ELSE Grade = ‘E” Endif Print Name, Sum, AVG, Grade Until count = Number of students Stop
557
Flowchart of example 3
558
Practical activity 1-1 1. Open a text editor program on your computer like NotePad or WordPad. 2. Type the following program exactly the way it is in the editor. This is my first a webpage Hello World 3. Save your work as webpage.html on the desktop. Make sure that the Save As Type box reads “All Files” before clicking the save button in order to avoid saving a text file with two extensions i.e. webpage.html.txt.
559
Practical activity 1-2 4. Close your text editor. Notice that your file on the desktop has the icon of the default web browser installed on your computer. Double click it to view the web page! Figure right shows a sample of the display expected when the file is loaded to the browser. If you have a colour monitor, it should look as below only that it will have black bold text on a red background! 5. Check your program and change your background to blue, save then click the refresh button. What happens?
560
Review questions 1 1. Define the term computer program. 2. What is programming? 3. State three advantages of high level languages over low level languages. 4. List four examples of languages and for each, state its most appropriate application area. 5. Why is an executable file unique when compared to any other file? 6. Differentiate between a compiler and an interpreter. Why did early computers work well with interpreters? 7. List the various examples of programming languages per generation. 8. State one advantage of machine language over the other languages. 9. Write the following in full A) HTML B) OOP 10. Distinguish between source program and object code in programming. 11. Define the term encapsulation as used in object oriented programming.
561
Answer of review questions 1-1 1. A computer program is a set of instructions that directs a computer on how to process a particular task. 2. Programming is the writing of computer programs. 3. A). Easier to learn and use. B). Portable. C). Flexible. D). Easier to correct errors. 4. A). FORTRAN – used for developing business oriented programs. B). COBOL – designed for developing business oriented programs. C). Pascal – mostly used as a teaching tool in structured programming. D). C – mostly used to create system software such as operating systems. E). Ada – suitable for developing real-time and industrial systems. 5. It is the main file that is used to start the program. 6. A complier translates the entire source program into machine readable form while an interpreter translates the source program to machine language line- by-line. Interpreters were used on early computers due to memory limitations.
562
Answer of review questions 1-2 7. A). First generation – machine languages. B). Second generation – assembly languages. C). Third generation – Pascal, C, COBOL, BASIC, FOTRAN, Ada etc. D). Fourth generation – Visual Basic, Delphi Pascal, Visual COBOL etc. E). Fifth generation languages – PROLOG, Mercury, LISP, OCCAM etc. 8. A). The processor executes them faster. B). They are more stable. 9. A). HTML – Hypertext Markup Language. B). OOP – Object Oriented Programming language 10. Source program refers to a program that is not yet translated while object code refers to the program code that is in machine readable form. 11. Encapsulation refers to the process of joining data and instruction together to form an object.
563
Review questions 2 1. Give one advantage of compiling a program rather than interpreting it. 2. Outline at least six stages of program development in their respective order. 3. Highlight two advantages of monolithic programs. 4. State two advantages of modular programming. 5. In what stage of the development does program documentation fall? Justify your answer. 6. Differentiate between a flowchart and pseudocode. 7. What is a program bug? 8. Explain why it is important to test a program before implementing it.
564
Answer of review questions 2-1 1. A). Interpreters translate the source program one statement at a time while compilers translate the entire source code at once before execution. B). Interpreters translate the program each time it runs hence slower than compiling. Compiled programs can be saved on a storage media. This means that it does not require any further transaction every time the program is run hence executes faster than interpreted programs. C). Interpreters translation takes less memory while compiled programs require more memory as the object code files are larger. 2. A). Problem recognition. B). Problem definition. C). Program design. D). Program coding. E). Program testing and debugging. F). Implementation.
565
Answer of review questions 2-1 3. A). They are difficult to test and debug. B). They are difficult to modify or upgrade. 4. A). They are easy to test and debug. B). They are easy to modify and upgrade. 5. Documentation is done at all stages of program development. 6. A flowchart is a graphical representation of step-by- step processing logic of a program while a pseudocode is a set of structured-English like statements that describe the step-by-step processing logic of a program. 7. Bugs refers to program errors. 8. To correct any syntax or logical errors.
566
Review questions 3 1. State the factors you would consider when A) Writing a pseudocode B) Drawing a flowchart 2. Using illustrations, explain at least six symbols used in flowchart design. 3. Give one advantage of pseudocodes over flowcharts. 4. Write a pseudocode for a program that would be used to solve the equation E = MC 2 5. Draw a flowchart that would be used to classify animals according to sex. If a letter M is input the program should display ‘Male’ otherwise it should display ‘Female’.
567
Answer of review questions 3-1 1. A). Pseudocode 1). Statements must be short and clear. 2). Statements should be unambiguous. 3). Should shoe start and stop. 4). Words used should be suggestive such as READ, PRINT, OUTPUT etc. B). Flowchart 1). A flowchart should have one entry and one exit point. 2). Use correct symbols. 3). The flow should be clearly indicated using arrows. 2. Decision – used to represent a decision construct. Connector – connects logic flows. Process – indicates a transformation of data. Input/output – shows program input/output. Ellipse – indicates start/stop of algorithm.
568
Answer of review questions 3-2 3. Pseudocodes are easier to write and understand. 4. Start Enter values form M and C E=M*C*C Display E Stop
569
Review questions 4 1. Define the term selection in relation to program control structures. 2. State three types of control structures used in programming. 3. Differentiate between looping and selection. 4. In what circumstance does looping depend on decision? 5. List four selection controls used in writing a program.
570
Answer of review questions 4 1. Selection refers to a situation where further program execution depend one making a decision from two more alternatives. 2. Sequence, decision and iteration. 3. Looping refers to a situation where the same block of code is executed repeatedly until a certain condition is fulfilled, while selection refers to a situation where further program execution depends on making a decision from two or more alternatives. 4. Looping may depend on decision if a condition has to be met before the looping terminates or continues. 5. A). IF…THEN B). IF….THEN…ELSE C). Nested IF D). Case
571
Revision questions 1 1. State three reasons why high level languages are better than low level languages. 2. Explain why HTML is not true programming language. 3. List three examples of forth generation programming languages. 4. Describe the term structured programming. 5. Define the term structured programming. 6. A). State two reasons for documenting all the stages of program development. B). Give three types of program documentation in reference to programming. 7. Write HTML code that would display a green background, with the words ‘Hello’ on the screen. 8. Draw a flowchart showing the general flow of the following: A) The nested IF selection. B) The FOR loop. C) REPEAT….UNTIL loop.
572
Answer of revision questions 1-1 1. A). They are portable B). They are user friendly C). They are more flexible D). They are easier to debug 2. HTML is not a true programming language because it does not have a true format of a programming language. For example, it does not have a declaration part and control structures. 3. A). Visual Basic B). Delphi Pascal C). Visual COBOL 4. Fifth generation programming languages are designed in a way that enables programmers design programs that emulate human intelligence. 5. In structured programming, a program is broken down into components called modules each performing a particular task.
573
Answer of revision questions 1-2 6. A). Reasons for documenting i. There may rise a need to revise or modify it. ii. Other people may think of ways of improving your program by studying at the documentation. B). Types of documentation i. User-oriented. ii. Operator-oriented. iii. Programmer-oriented. 7. Hello program Hello
574
Answer of revision questions 1-3
575
Answer of revision questions 1-4
576
Revision questions 2 1. Write a program algorithm that would enable the user to enter student marks. The program should then determine whether the mark entered is a pass or fail given that the pass mark is 50. 2. Draw a flowchart for a program that is to prompt for N numbers, accumulate the sum and then find the average. The output is the accumulated totals and the average. 3. Write a pseudocode that reads temperature for each day in a week, in degree Celsius, converts the Celsius into Fahrenheit's and then calculate the average weekly temperatures. The program should output the calculated average in degrees Fahrenheit's.
577
Answer of revision questions 2-1
578
Answer of revision questions 2-2 3.START Input temperature in ℃ et initial day to 0 WHILE initial day 6 DO Input temperature in ℃ F=32+(9C/5) Initial day=initial day + 1 Cummulative = cummulative + F END WHILE Average weekly temperature = cummulative/7 Print Average STOP
579
Revision questions 3 1. A lady deposits 2,000 shillings in a Microfinance company at an interest rate of 20% per annum. At the end of each year, the interest earned is added to the deposit and the new amount becomes the deposit for that year. Write an algorithm for a program that would track the growth of the deposits over a period of seven years. 2. Mukumu took a loan of Ksh 400,000 from a local bank at an interest rate of 10% payable in four years. Assuming you wish to develop a computer program that will keep track of monthly repayments: A) Identify the input, processing and output requirements for such a program. B) Design the algorithm for the program using a simple flowchart and pseudocode.
580
Answer of revision questions 3-1 1. START Input initial deposit Input interest rate Set deposit to initial deposit Set year to 0 WHILE year < 7 DO Interest = Deposit * interest rate Total = Deposit + interest Deposit = Total Year = Year + 1 END WHILE PRINT Deposit, Year STOP
581
Answer of revision questions 3-2 2. A). Inputs – initial amount borrowed - Interest rate - Number of years Processing – the equation to calculate monthly repayments. Output – monthly repayments calculated by the process
582
Answer of revision questions 3-3 2. B). START Input initial loan borrowed Input interest rate Input number of years Calculate yearly repayments Monthly repayments = yearly repayments/12 Display monthly repayments STOP
583
583 Chapter 5 Computer System development
584
A system Is a set of items linked together to carry out a given task in order to achieve one or more objectives. A system is described as being either soft or hard.
585
Soft systems and hard systems Soft systems – human activity are said to be soft systems. They are said to be soft because: Their boundaries may be fluid or keep on changing. Their goals and objectives conflict. It’s difficult to precisely define exact measures of performance for them. Hard systems – these are systems whose goals and objectives are clearly defined and the outcomes from the systems processes are predictable and can be modeled accurately.
586
System classification Deterministic system – these are systems whose output are known precisely by their inputs e.g. a computer system. Probabilistic system – these are systems whose output can only be predicted but not knows precisely e.g. business and economic system organisation. Cybernetic systems – these are self controlling systems which adapt to the environment and regulate their own behaviour by accessing the feedback. They access their output and adjust the input e.g. human beings, plants systems
587
Characteristic of systems 1. Holistic thinking 2. Sub systems 3. Processor 4. Objectives/purpose 5. Environment 6. Boundaries 7. Interdependence 8. Feedback 9. Control 10. Inputs and Outputs 11. System Entropy
588
Holistic thinking and sub systems Holistic thinking – in this, a system is considered as a whole. A combination of various components that makes up a system creates a complex whole whose overall goals are more sophisticated than those of the individual components. Sub systems – a system is made up of different components (subsystem). Therefore a system does not exist in solitude but it may be a component of a large system.
589
Processor and objectives/purpose Processor – this is an element of a system that does the actual transformation of input into output. Objectives/purpose – objectives of a system may be real or stated. An organization should state one objective and operate to achieve another user must know the major objective of a system.
590
Environment and boundaries Environment – the environment is the system within an organisation operates. Environment provides a reason for the existence of the system. Boundaries – system boundaries are the external element whose changes in attitudes, behaviour and property affect their state and are affected respectively i.e. it’s the limit of system.
591
Interdependence and feedback Interdependence – for a system to be effective and efficient, its components or subsystems must be coordinated and linked together. Feedback – a feedback is a check within a system to see whether predetermined goals are being met. The checks are conducted on a system to determine deviation.
592
Control and inputs and outputs Control – this is the process by which the system adapts to changes in the environment in order to give the expected level. Inputs and outputs – a system communicates with its environment by receiving inputs and giving outputs.
593
System Entropy Entropy means decay. System ‘decay’ naturally over time, hence it slowly becomes useless to the user either due to improvement in technology, new management or change in user requirements. Therefore it must be reviewed in order to improve it or develop a new one.
594
Open and closed system An open system receives input from and gives output to the environment while a closed system does not interact with the environment.
595
Information system This is a set of persons, procedures and technologies and other resources that collects, transforms and disseminates information in the system e.g. organisation.
596
Purpose of information system To provide the people within an organisation with information to assist in decision making process. To provide responsive service to meet user needs. To enable sharing of information. To facilitate interaction and dissemination of data throughout the various level of organisation.
597
Why develop new information system? New changes in organisation – management can introduce new changes, and they have to be implement to meet the needs of the organisation. Problems in the current system – the undesirable circumstances in the current system that prevent the organisation from meeting its goal. New opportunities – if an opportunity presents itself that can enable the organisations improve its services.
598
Theories of system development The most common theories include: Traditional Approach. Rapid Application Development (RAD). The Structured Approach.
599
Traditional Approach This approach relies mostly on the skills and experience of individual staff members carrying out of the project. In this approach, the manual system is replaced with a computerized one without change in overall structure of the former system. Hence the weakness of the former system are not addressed, they are forwarded to the new system.
600
Rapid Application Development (RAD) RAD model evolved from the theory that business today heavily rely on information technology, hence, development and implementation of information system needs to be quick enough for the organisation to maintain a competitive advantage in the market place.
601
Structured Approach In this approach a system development defines a set of stages that should be followed when developing a system.
602
Stage of system development Problem recognition and definition Information gathering Requirements specification System design System construction System implementation
603
Problem recognition and definition Problem recognition is the initial stage where the analyst decides if the project is really necessary to look into, and if its necessary to start a new project. In problem definition, the problem must be thoroughly defined. A through survey of the problem is undertaken by identifying the problem, understanding it, and finding out of there is a possibility of getting a solution. Before a new system is designed, a special study will be carried out to establish the costs and benefits of a new system. The study is called feasibility study. Feasibility study of a system is accessed in four ways. Operational feasibility Technical feasibility Economic feasibility Schedule feasibility
604
Operational feasibility and technical feasibility Operational feasibility – this establishes the extend to which the users are comfortable or happy with the proposed or new system. Technical feasibility – this establishes whether the technology available is sufficient or can be upgraded for the new system.
605
Economic feasibility and schedule feasibility Economic feasibility – it establishes whether the technology available is sufficient or can be upgraded for the new system. Schedule feasibility – it establishes whether the development of the proposed system will be accomplished within the available time.
606
Information gathering The system analyst gathers data about the current system and the users needs from both internal and external sources. Some of the methods used to collect or gather data include: Record inspection Interview Questionnaires
607
Record inspection and interview The documents maintained in connection to the system are referenced. This forms a good starting point for the analyst to gain an overall insight of the existing system. Interview – this is a face to face communication between the analysts as the interviewer and the affected personnel as interviewee. The questions are geared to getting the information needed by the analysts.
608
Advantages of interview The analysts is accessible to first class information. Make interviewee feel as part of the system. Give adequate opportunity for interviewee, an opportunity to put forward opinions.
609
Disadvantages of interview Make the interviewee feel they are being summoned by the analysts. Some interviewees give answers which are not actually proven facts but opinions. The interviewee may not fully open on some issues that may be personal. The interviewee may be suspicious of the intentions of the proposed system for fear of being displaced by new system.
610
Questionnaires A questionnaire is a document containing a number of standard questions set to be asked to a larger number of people in order to gather information from them. The analyst is able to collect information from several key people in the organisation who may be affected by the current proposed system.
611
When the use questionnaire When limited amount of information is required from a large number of people. There is a large number of people involved in the system project. The people you need to gather information from are vastly despersed.
612
Advantages of questionnaires Answers filled in less tense environment. Since they are filled and returned in privacy, more sincere responses are possible. Questionnaire provides many people with the opportunity to provide input and suggestion. Questionnaire saves time especially where respondents are geographically scattered.
613
Disadvantages of questionnaires It’s a slow way of facts gathering. Designing questionnaires requires expertise. Some questions can be easily misunderstood hence ambiguous replies will be received. Analysis of questionnaires requires a lot of time.
614
Observation This requires the observer to participate or watch closely as a person performs activities in order to learn about the system. This method gives the analysts first hand experience about the problems and expenses to the system requirements.
615
Advantages of observation Concepts that are too difficult for non- technical staff to explain can be observed. It helps the analysts become acquainted with operational personnel. It helps the analysts acquire ‘know how’ needed to assist in changes that have been recommended. Can correct ‘hazy’ understanding or erroneous impressions.
616
Disadvantages of observation It’s costly and time consuming. Staff members are not comfortable when they are being watched.
617
Automated method This is mostly used when actual data is required but difficult to get through interviews, observation or questionnaires. Such data is collected using devices that automatically capture data from the source. E.g. video, cameras, tape recorders etc.
618
Requirements specification The system analyst must come with the detailed requirements for the new system. The requirements specifications include: Output specification Input specification File/data stores Hardware and software requirements
619
Output specification The output specifications entails activities like generation of reports used to facilitate decision making. The output can be in the form of reports either in hardcopy or softcopy. The quality of those reports is important. Formality of reports is important so that good quality reports are produced for easy understanding.
620
Input specification The input to the system in necessary because the contents of the input are used to maintain the master files. The following should be considered in input specification. The contents and volume of input. The mode and devices of input selected. Layout and sequence of input.
621
File/data stores File requirement involves making an informed decision on file required to store data and information in the system. The analyst should identify the number of files that will be needed by the system and determine the structure of each file.
622
Hardware and software requirements System analyst should specify all hardware and software requirements for the new system. He/she should consider: Economic factors e.g. price Operational factors e.g. reliability User friendliness.
623
System design This involves detailing the physical design of the system, it’s the how of the process. Once the logical design is put lined during system analysis, the analyst determines the physical design, which describes the hardware, software and operating procedures required to make system operational. Several tools are used for designing an information system. Examples are flowchart, data flow diagram, requirements.
624
System construction This refers to coding, installation and testing of the modules and their components such as outputs, inputs and files. The purpose of the construction is to develop and test a functional system that fulfills the business and design requirements.
625
Testing the system The system is tested by entering some test data to find out whether its output are as expected. The system is tested using the requirements specifications and the design specification to find out whether it meets all requirements specified.
626
System implementation This involves installing the system in the user’s computers, testing the installed system, converting from old system to the new one and training the users. System implementation involves: File creation and conversion. Change over. Staff training
627
File creation and conversion This involves setting up of the master files that are to be used in the support of the new system. The setting can be either from scratch or just to convert the files that were employed in old system.
628
Training staff The training aim at: Convincing the staff of the user department on the effectiveness of the new system. Remove fear of change from them. Enabling the staff to cope with processing task of the new system.
629
Methods of training Demonstration Film show Manual reference Group discussion Visits
630
Changeover This is the process of changing over from old system to the new system. Type of changeover Direct changeover Parallel changeover Phase changeover
631
Direct changeover In this approach the new system commence live operation and immediately the old system is abandoned. Advantage of direct changeover It’s a cheap method Disadvantages of direct changeover Extremely risky Places an organization in a do or die situation.
632
Parallel changeover In this changeover the operation of the old system and the new system run alongside each other. Advantages of parallel changeover Provides a method of training in the new system. Personnel become familiar with the new system prior to actual changeover. Disadvantages of parallel changeover Costly to run two systems Cross checking is difficult Requires more staff hence more training required for additional staff
633
Phase changeover In this approach implementation is done only one part of the new system at one time or a step by step. Advantages of phase changeover Allow the system to be implemented quickly Less costly Failures of the system are limited Causes minimal disruption Disadvantage of phase changeover Problems on ensuring that the first phase is implemented and converted.
634
System review and maintenance System maintenance is the adjustment and enhancement or correction of errors after the system has been implemented. The reviewing involves going through the specification and testing the system after implementation to find out whether it still meets the original specification.
635
System documentation consists of Report of fact finding which outlines methods used to collect data, weakness of the current system and recommendation of the current system. Requirements specification which entails the output requirements, input, hardware and software required for the new system. System flowchart which shows the overall functionality of te proposed information system. Tables or file structures depending on the approach used in system construction. Sample test data to test whether the new computerized information system is working as expected. User manual which helps the user work with the new system with minimal guidance. The manual contains information like How to install, start the system The interface of the system How to carry out various tasks Error correction and how to get help
636
Review questions 1 1. Define the term information system. 2. Differentiate between soft systems and hard systems. 3. List five characteristics of a system. 4. What is system control? 5. Why do we need feedback in a system? 6. Explain the tem system boundary. 7. State and explain three purposes of information systems in organisations. 8. Define the term online analytical processing? 9. Draw a well labelled diagram that depicts a system that is controlled through feedback.
637
Answer of review questions 1-1 1. An information system is the arrangement of people, data, processes and information that work together to support and improve the day-to-day business operations. 2. In soft systems, goals are not clearly defined unlike in hard systems. 3. A). Holistic thinking B). Subsystems. C). Boundary and environment. D). Purpose. E). Process. F). System entropy. G). Inputs and outputs. H). Open and closed systems. I). Control 4. A system control is a method by which a system adapts to changes in the environment in order to give the expected output or perform at the expected level.
638
Answer of review questions 1-2 5. Feedback is needed in order to adjust controls for better performance of the system. 6. System boundary is the scope within which a system component operates. 7. A). Supports information processing tasks. B). Supports decision making. C). Supports sharing of information. 8. Online analytical processing is whereby a computer based information system is used to capture operational data, analyse and generate reports to be used for supporting decision making process in an organisation. 9..
639
Review questions 2 1. Explain three system development theories and methods. 2. State the main disadvantage of Rapid Application Development method. 3. Define the term system development lifecycle. 4. At what stage does the system change hands from the development stage to the users. 5. Highlight three circumstances that necessitate the development of new information systems. 6. Define the term feasibility study as used in system development. 7. State four methods that can be used to gather information during system development. 8. State two advantages of interview over questionnaires. 9. State two disadvantages of interview method when used for information gathering. 10. Give one example of automated information gathering technique.
640
Answer of review questions 2-1 1. A). Traditional approach. B). Rapid Application Development (RAD) C). Structure approach. 2. The main disadvantage of RAD is that the system may be weak due to quick development. 3. System development life cycle refers to the steps followed in developing a system for conception to review and maintenance. 4. At the implementation stage. 5. A). New opportunities. B). Problems C). Directives. 6. Feasibility study is a special study carried out to establish the costs and benefits of a new system. 7. A). Interviews B). Questionnaires C). Observation D). Study of available documents. E). Automated methods.
641
Answer of review questions 2-2 8. A). Non-verbal communication can be used or observed. B). Questions can be rephrased for clarity. 9. A). It is difficult to organise for an interview due to time constraint. B). The interviewee may not fully open up some sensitive issues due to security concern. 10. An example of automated information gathering technique is the use of a video camera to compare motion pictures.
642
Review questions 3 1. Outline the four areas that are considered during the requirements specification stage. 2. Explain at least three factors that should be put into consideration during output design. 3. State four factors that may be considered in order to design a good file. 4. Explain why it is important to consider file backup and recovery strategies during file design.
643
Answer of review questions 3 1. A). Output B). Input C). Files D). Hardware and software requirements. 2. A). Target i.e. the audience. B). Frequency of report generation C). Quality and format 3. A). Record key field B). Type of data C). Length of each field D). Backup and recovery strategies. 4. Back up and recovery strategy helps in making sure that if the current file gets corrupted, it is possible to reconstruct the original file.
644
Revision questions 1 1. Outline seven steps followed in structured system development. 2. Explain three tasks that are carried out during system implementation. 3. Outline three disadvantages of questionnaires. 4. Explain the concept of proxemics in interviews. 5. Give an advantages of straight changeover over parallel changeover. 6. Define the term file conversion. 7. Differentiate between a system flowchart and a program flowchart. 8. Draw four system flowchart symbols and explain their functions.
645
Answer of revision questions 1-1 1. A). Problem recognition and definition. B). Requirement specification. C). System design. D). System construction. E). System implementation. F). System review and maintenance. 2. A). File conversions. B). Staff training. C). Project management. D). Changeover 3. A). Good questionnaires are difficult to prepare. B). The respondent may not understand some questions. C). The respondent has the final say on when to fill and return the questionnaire. Most of them end up not being filled or returned hence it is disadvantageous to the researcher.
646
Answer of revision questions 1-2 4. Proxemics refer to issues related to physical contact such as sitting arrangement during an interview. 5. Straight changeover is cheaper to implement than parallel changeover. 6. File conversion refers to changing files from one format to another. 7. A system flowchart is for the entire system while a program flowchart is for a part or a module in the system. Therefore, several program flowcharts may be derived from a single system flowchart.
647
Revision questions 2 1. Define the term “attribute”. 2. Explain the importance of using automated methods in fact finding. 3. Why is observation sometimes disadvantageous when used in fact finding? 4. State one of the disadvantages of the traditional approach in system development. 5. Outline the factors that should be considered when sourcing for hardware and software resources required for a new system. 6. Outline some of the contents of a user manual that would help the user run the system with minimal guidance.
648
Answer of revision questions 2 1. Entity attributes refer to characteristics of a particular entity. 2. Automated methods of data collection can be used in areas which are not easily accessible. 3. A). The person being observed might alter his or her behaviour. B). It may be time consuming. 4. The weaknesses of the former system are not addressed. 5. A). Economic factors. B). Operational. C). Services from the vendor. 6. A). Installation procedures. B). User interface. C). How to carry out various tasks. D). Test data and expected output E). Troubleshooting guide
649
Practical exercise 1 Extract the book return module flowchart from the system flowchart depicted in figure right.
Similar presentations
© 2025 SlidePlayer.com Inc.
All rights reserved.