Introduction to Computer Science 2025/2026 PDF

Document Details

ThriftySanAntonio5052

Uploaded by ThriftySanAntonio5052

Tanta University

2026

Dr. Osama Ghoneim

Tags

computer science introduction to computer science computer systems fundamentals of computer science

Summary

This document details an introduction to computer science course offered by the Faculty of Computers and Informatics at Tanta University. The course, fundamentals of computer science (CS111), is for level 1, first semester 2025/2026. It aims to familiarise students with computer systems, software, hardware and development concepts.

Full Transcript

Faculty of Computers and Informatics Tanta University ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Introduction to computer science 2024/2025 2024/2025 2024/2...

Faculty of Computers and Informatics Tanta University ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Introduction to computer science 2024/2025 2024/2025 2024/2025 24 Dr. Osama Ghoneim Level 1 Semester1 Course Title Fundamentals of Computer Science Course Code CS111 Academic Year 2025 / 2026 Coordinator Dr. Osama Ghoneim Instructor(s) Semester First Pre-Requisite Credit 3 Hours Course Delivery Lecture 2H Lectures Practical 1H Exercises ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Parent Department Computer Science Date of Approval 1. Course Aims The aims of this course are to: The main objective of the course is to make the student familiar to the computer system (hardware and software). 2024/2025 The course aims to develop skilled 2024/2025 2024/2025 computer users with the technical background, knowledge, and adaptability to develop well-designed, robust, computer-based solutions to a range of problems. The course introduces students to basic concepts of computer system and their applications and gives an overview for each branch of computer science: computer programming, graphics, networks, system analysis and design 2. Intended Learning outcomes (ILOs) A. Knowledge and understanding: By the end of this course students should be able to: A1. Understand programming concepts for various branches of computer sciences. A2. Demonstrate strong knowledge of fundamentals of programming and the construction of data structures and algorithms. A3. Recognize how the hardware and software are integrated to create computer systems and distinguish between selected forms of computer hardware architecture, and operating system technology. A4. Deploy appropriate theory, practices, and tools for the specification, analysis, design, implementation, and evaluation of a computer-based system. A5. Know how to solve problems by programming and using simulation models. B. Intellectual skills: By the end of this course, the students should be able to: B1. Apply appropriate programming techniques to the development of software ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ solutions. B2. Develop computer algorithms to solve different problems. B3. Design software solutions to real world problems. C. Professional and practical skills: By the end of this course, the students 2024/2025 2024/2025 should be able to:2024/2025 C1. Choose the appropriate Programming Language or Operating system. C2. Deploy Communication Skills in team working or leading. C3. Design and Develop computer-based systems. C4. Use Logical inference in problem solving. D. General and transferable skills: By the end of this course, the students should be able to: D1. Practice Communication and Management skills. D2. Practice Independent Learning techniques. D3. Develop the act of getting people together. D4. Follow Analytical and Creative Thinking. 3. Course Content Part1: Lectures Week Topics 1 Overview of a computer system: 2 * hardware, software and people * Computer system diagram * Input devices * Output devices * secondary storages 3 The central processing unit (CPU): 4 * what goes inside the computer * The central Processing unit ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ * the control unit CU * memory (RAM – ROM) 5 Input and output: 6 input : getting data form the user to computer output: information for the user 7 Communication : computer connections & networks 8 9 Operating system 10 2024/2025 2024/2025 2024/2025 11 Programming language 12 13 System analysis and design 14 Part2: Applied exercises distributed overall 14 weeks. 4. Teaching and Learning Methods 4.1.Lecture 4.2.Discussion (Brain Storming) 4.3.Self-learning 4.4.Exercise 4.5. Web searching 5. Student Assessment Assessment Method Assessment Length Schedule Proportion Written Final Examination 2 Hour Examination The 16th Week 60% Oral Assessment Assessment Session Term Final 10% Mid-Term Exam 1 Hour Examination The 7th Week 20% Semester work: distributed 10% HomeWorks Continuous overall 14 5% Quizzes Assessment weeks 5% 6. List of references S Item Type KONGRESİ, P. FULL TEXT BOOK 2024 TAM METİN KİTABI 2024.‫‏‬ 1 Books 7. Facilities required for teaching and learning: ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬  Projectors: Video, Overhead and Slide.  Computer Presentations and Writing Boards.  Library. Course Coordinator Program coordinator: Name Dr.Osama Ghoneim Name 2024/2025 ‫أسامة غنيم‬2024/2025.‫د‬ 2024/2025 (Arabic) Signature Date Content: Chapter 1: Introduction to computer and information systems Chapter 2: Types of Computers Chapter 3: Computer hardware and software components Chapter 4: Data Representation and Number systems ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Chapter 5: Introduction to internet Chapter 6: Algorithm and Flow Chart Chapter 7: Stepwise Refinement Chapter 8: Introduction to networking 2024/2025 2024/2025 2024/2025 Chapter 1 Introduction to computer and information systems 1.0 Computer: The term computer is derived from the Latin word compute, which means to calculate. A computer is an electronic machine, devised for performing calculations and controlling operations that can be expressed either in logical or numerical terms. In simple terms, a computer is an electronic device that performs diverse ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ operations with the help of instructions to process the information in order to achieve the desired results. Computer application extends to cover huge area including education, industries, government,medicine, scientific research etc. A computer is one of the most influential forces available in modern times. Due to its memory, high speed and perfection, its application can be extended to almost infinite levels. Millions of complex calculations can be done in mere fraction of time. Difficult decisions can be made with accuracy for comparatively little cost. Computers are 2024/2025 2024/2025 2024/2025 widely seen as instruments for future progress and as tools to achieve substantiality by way of improved access to information by means of video conferencing and e-mail. Indeed computers have left such on impression on modern civilization that we call this era as the information age. 1.1 CHARACTER STICS OF COMPUTERS The main characteristics of computers are: Speed Storage Accuracy Versatility Automation Diligence Relbility 1.1.1 SPEED Computers are capable of carrying out the task with enormous speed. Today’s computers, according to their class, can perform from 4 MIPS (Millions of instructions per second) to 100 MIPS. What may take days for manual calculations may take only a few hours for computers to perform. Inside the computer the information signal travels at incredible electronic speed. 1.1.2 STORAGE Computers can store enormous quantity of information. Which is expressed in terms of Kilobytes (or) Mega Bytes (MB) or Gega Bytes (GB). It is achieved through its ‘Main memory’ or ‘Primary storage’ and through ‘auxiliary storage’ or ‘Secondary storage’. The Hard disks Floppy disk, Compact Disc(CD) and Magnetic Tape storage are examples of secondary storages. These large volumes of storage occupy much lesser space compared to paper documents and this ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ aspect of computers makes them more powerful. 1.1.3 ACCURACY The accuracy of a Computer is consistently high. In fact, this quality of the computers make them indispensable in various fields such as Scientific Research, Space Research, Weather Predictions and many other areas where precision of a high order is required. The accuracy of the computer is best achieved by programming them in the most efficient manner. When it comes to very complex mathematical or scientific 2024/2025 problem the computer’s2024/2025 2024/2025 accuracy has no substitute. 1.1.4 VERSATILITY Computers are versatile in that they can perform almost any task, provided they are given the appropriate logical steps. For example, they are capable of performing wide ranging tasks such as construction of a payroll, inventory management in a factory, hotel billing, hospital management, banking applications and any imaginable task in every walk of life. 1.1.5 AUTOMATION The biggest advantage of computers is that it is automatic in its operation. Once a programming logic is initiated the computer performs repeated operations without human interventions until program completion 1.1.6 DILIGENCE Computers are machines and that do not get tired or ‘lose concentration’ like human beings. If a large number of calculations say million calculations are to be performed the resultant output will remain exactly the same even if operations are repeated any number of times. But when a human being is asked to do the same job this consistency cannot be achieved. Thus for those who want consistent and continuous standard output, computer’s ‘diligence’ is of great help. 1.1.7 RELIABILITY The computers give very accurate results with predetermined values. They correct and modify the parameters automatically, giving suitable signals. They give formatted results with high degree of precisions. 1.2 HISTORY OF COMPUTERS In the early days of mankind, man used to count the head of cattle by putting lines on trees. Slowly these lines changed to numbers. To do calculation on numbers he started inventing machines. 1.2.1 ABACUS ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Abacus was probably the earliest of counting devices. It consists of rectangular wooden frame with two compartments and beads sliding along the steel wires for counting. Multiplication and divisions are done using repeated additions and subtractions. Even today in which cross strings are fixed. Beads are inserted on to the strings. There are a number of rows of beads. 2024/2025 2024/2025 2024/2025 Fig 1.1 1.2.2 NAPIER’S LOGS AND BONES John Napier, a Scottish mathematician invented logarithms. The use of logarithms enabled him to transform multiplications and division problems of addition and subtractions. In the beginning he called logarithms as artificial numbers. But later he named them logarithms. Napier also invented a computing device consisting of sticks with numbers carved on them. These sticks are called bones as they were made of bones. These bones helped a lot in multiplication involving large numbers. Fig : 1.2 1.2.3 SLIDE RULE As the name indicates, the slide rule has one scale sliding within the other. Suppose you want to add two numbers 3 and 5, set 3 on the fixed scale and slide the moving scale. So that its “0’ coincides with”5” of sliding scale. This is the sum of 3 and 5. The process of reading could be quick if you are trained in the use of slide rule. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Fig : 1.3 1.2.4 CALCULATING MACHINES AND PASCAL’S CALCULATOR A French mathematician, Blaise Pascal invented a machine based on gear wheels. He was the son of tax collector who had to do lot of calculations as part of his job. Blaise Pascal wanted to make his job easier by inventing a calculator. You might be familiar with gear wheels 2024/2025 in use in your bicycle which 2024/2025 meshes with 2024/2025 a driving chain. He used similar gear wheels with ten teeth for each digit position. He fixed them together so that one wheel drives the other. When the wheel corresponding to units position rotated by ten teeth, it drove the wheel corresponding to the next higher position by one tooth. Thus one could make calculations. Pascal provided dials, which indicated numbers stored on each wheel. He also used suitable “dialing system” to operate the gear wheels. Other people also made a number of such calculators. Computer scientists honoured Pascal by naming a programming language Pascal after him. Fig : 1.4 1.2.5 BABBAGE DIFFERENCE AND ANALYTICAL ENGINES Babbage, a British National and the son of a wealthy banker wanted to correct the errors in the logarithm tables being used during his time. In 1822, he made a machine which calculated the successive difference of expressions (X2 + ax + b is an example of an expression) and prepared table which helped him in his calculations. The royal Astronomical society awarded a gold medal to him for his invention and granted a large sum of money to carry out further work. He wanted to make an accurate calculating machine called “Babbage’s Analytical Engine”. The analytical Engine was supposed to be very accurate. So it needed lot of parts made with precision. Babbage could not make such parts. He conceived that his machine would use input devices, would have a processing part called “mill” where you can perform calculations, would also incorporate It consists of rectangular frame in which cross strings are fixed. Beads are inserted on to the strings. There are a number of rows of beads.Since he was about 100 years ahead in his ideas, he could not get parts needed for his machine. This is because there were no tools to make such precision parts. He did lot of work related to making precision parts and spend all the grants (and ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ lot of his money too) but failed in his attempt to make a machine. He ultimately died as a frustrated man. 2024/2025 2024/2025 2024/2025 Fig : 1.5 Fig : 1.6 1.2.6 LADY ADA LOVELACE Lovelace is the daughter of the famous English poet Lord Byron. She was a mathematician. She studied the works of Babbage and wrote about them. From her account only, we can see the close resemblance of the modern day computers and Babbage’s work. Lady Ada Lovelace’s contributions are very important. Since she predicted that computers can be programmed, a language, Ada used widely in America’s Department of Defence Computers was named after her. 1.2.7 HERMAN HOLLERITH’S MACHINE Governments all over the world collect details about the number of people living in their countries. This information helps the Government in planning for the future, Sometimes you find enumerators (people taking such details) coming to your house with forms to collect such details. This operation is called “census” which is normally done once in 10 years. In the United States a census was carried out in 1880 and the U S Government was processing the census data. Even as this was going on, the next census was due in 1890. To process the census of 1890 fast, the Government announced a competition. Fig : 1.7 Dr.Herman Hollerith Produced cards out of special paper pulp, designed punching machines to punch holes in the card to count census figures and invented sorting machines to read such punched card and collect data. He could ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ complete the job within three years, achieving a speedup of about three times. 1.2.8 ABC COMPUTER In 1937, Dr. John Atanstoff with the help of his assistant Berry designed the Atanstoff Berry Computer (ABC). The machine laid the foundation for the development of electronic digital computer. 2024/2025 2024/2025 2024/2025 Fig : 1.8 1.2.9 ENIAC- ELECTRONIC NUMERICAL INTEGRATOR AND CALCULATOR In 1947 john Mauchly and Eckart completed the first large scale Electronic Digital Computer, ENIAC. In this computer, each time a program was changed, the wiring had to be completely rearranged. It weighed 30 tons, contained 18,000 vacuum tubes and occupied a space of 30 50 feet. Fig : 1.9 1.2.10 EDSAC-ELECTRONIC DELAY STORAGE AUTOMATIC CALCULATOR Maurice V.Wilkes of Cambridge University completed EDSAC in 1949. EDSAC was the first computer to operate on the stored program concept. Fig : 1.10 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 1.2.11 UNIVAC-I – UNIVERSAL AUTOMATIC COMPUTERS In 1947, after ENIAC became operational Mauchly and Eckart formed their own Company- The Eckart-Mauchly Computer Corporation”. Immediately after this they started the design of UNIVAC-I. This was purchased by US bureau of Census. UNIVAC was the first computer dedicated to business applications 2024/2025 2024/2025 2024/2025 Fig : 1.11 1.3 COMPUTER SYSTEM A computer system is a combination of various components. It performs the system functions such as input, processing, output, storage and control. A computer system consists of the following components: Hardware Software Human ware Firmware Bridge ware 1.3.1 HARDWARE The physical components of the computer, such as electrical, electronics and mechanical unit are known as the hardware of the computer. That is, the input units, output units and CPU are called hardware. Thus hardware is the equipment involved in the function of a computer. It consists of the components that can be physically handled. The function of these components is typically divided into three main categories: input, output, and storage. Components in these categories connect to microprocessors, output and storage. Components in these categories connect to microprocessors, specifically, the computer's central processing unit (CPU), the electronic circuitry that provides the computational ability and control of the computer, via wires or circuitry called a bus. 1.3.2 SOFTWARE The computer performs operations like addition, subtraction, multiplication and division only when the user instructs it to do so. The user issues instructions and the CPU acts in accordance with the instructions. The sets of instructions, which control the sequence of operations, are known as programs, and ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ collectively programs are called software. The software can be broadly classified into two types. They are: System Software Application software 1.3.3 HUMAN WARE The man-machine interface is called a human ware. The people who work with the computer 2024/2025 are collectively called the human ware or livewire. 2024/2025 2024/2025 1.3.4 FIRMWARE The computer programs permanently stored in ROM or PROM are called firmware. These programs are provided by hardware manufacturer along with the computers. Generally these are booting programs which help in the starting of a computer. Such programs cannot be erased or overwritten. 1.3.5 BRIDGE WARE The computer components and programs used to translate instructions and information written for one type of computer into a format that another type of computer can understand is called bridge ware. This is necessary because different computers are made by different manufacturers. 1.4 IMPORTANCE OF COMPUTERS IN BUSINESS Computer plays an important role in business environment as every organisation adopts it in some form or the other to perform the tasks in effective manner. In the past few years’ rapid development in IT, particularly in communications, electronic service networks, and multimedia have opened up new opportunities for corporates. All these are contributing towards new and effective ways of processing business transactions, integrating business processes, transferring payments and delivering services electronically. It has affected the business in the following ways: Office Automation Computers have helped automation of many industrial and business systems. They are used extensively in manufacturing and processing industries, power distribution systems, airline reservation systems, transportation systems, banking systems, and so on. Computer aided design (CAP) and computer-aided manufacture (CAM) are becoming popular among the large industrial establishment. Stores large amount of date and information Business and commercial organizations need to store and maintain voluminous records and use them for various purposes such as inventory control, sales analysis, payroll accounting, resources scheduling and generation of management reports. Computers can store and maintain files and can sort, merge or update as and when necessary. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Improves Productivity With the introduction of word processing software, Computers have recently been applied to the automation of office tasks and procedures. This is aimed at improving the productivity of both clerical & managerial staff. Sharing of data and information Due to networking of computers, where a number of computers are connected together to share the data and information, use of e-mail and internet has changed the ways of business operations. 2024/2025 2024/2025 2024/2025 Competitiveness Computers offer a reliable and cost-effective means of doing business electronically. Routine tasks can be automated. The customers can be provided support round the clock, which is 24 hours a day. With advancement in IT sector, corporates are spreading business around the world thus, increasing their presence and entering new markets. Security To provide security to data and important computer programs, almost every organization has some security programs to avoid the illegal access of the company’s information by unauthorized persons. The three fundamental attributor of a security program are confidentially, integrity and availability which allow access to only authorized persons in an organization. Cost Benefits The extensive availability of internet based information means that companies have a wider choice of suppliers which leads to a more competitive pricing. Due to the presence of internet the role of the middleman becomes less important as companies can sell their product or services directly to the customer. Marketing Corporate engaged in e-business can take help of their respective websites to create brand awareness of their products, thus, creating new avenues of promotion of their products. In addition, companies’ websites can also provide better services such as after sales service to the customer. Chapter 2 Types of Computers 2.1 Computer: Definition A computer is an electronic device, operating under the control of instructions stored in its own memory that can accept data (input), process the data according to specified rules, produce information (output), and store the information for future use. Its principal characteristics are: It responds to a specific set of instructions in a well-defined manner. It can execute a prerecorded list of instructions (a program). ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ It can quickly store and retrieve large amounts of data. Therefore computers can perform complex and repetitive procedures quickly, precisely and reliably. Modern computers are electronic and digital. The actual machinery (wires, transistors, and circuits) is called hardware; the instructions and data are called software. All general-purpose computers require the following hardware components: Central processing unit (CPU): The heart of the computer, this is the component that actually executes instructions organized in programs 2024/2025 ("software") which tell the2024/2025 2024/2025 computer what to do. Memory (fast, expensive, short-term memory): Enables a computer to store, at least temporarily, data, programs, and intermediate results. Mass storage device (slower, cheaper, long-term memory): Allows a computer to permanently retain large amounts of data and programs between jobs. Common mass storage devices include disk drives and tape drives. Input device: Usually a keyboard and mouse, the input device is the conduit through which data and instructions enter a computer. Output device: A display screen, printer, or other device that lets you see what the computer has accomplished. In addition to these components, many others make it possible for the basic components to work together efficiently. For example, every computer requires a bus that transmits data from one part of the computer to another. 2.2 Functionalities of a computer Any digital computer carries out five functions in gross terms: 2.3 Computer Components Any kind of computers consists of HARDWARE AND SOFTWARE. 2.4 Computer sizes and power Personal Computers Workstations Minicomputer Mainframes Supercomputers ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Least powerful Most powerful Computers can be generally classified by size and power as follows, though there is considerable overlap: Personal computer: A small, single-user computer based on a microprocessor. Workstation: A powerful, single-user computer. A workstation is like a personal computer, 2024/2025 2024/2025 2024/2025 but it has a more powerful microprocessor and, in general, a higher-quality monitor. Minicomputer: A multi-user computer capable of supporting up to hundreds of users simultaneously. Mainframe: A powerful multi-user computer capable of supporting many hundreds or thousands of users simultaneously. Supercomputer: An extremely fast computer that can perform hundreds of millions of instructions per second Supercomputer and Mainframe Supercomputer is a broad term for one of the fastest computers currently available. Supercomputers are very expensive and are employed for specialized applications that require immense amounts of mathematical calculations (number crunching). For example, weather forecasting requires a supercomputer. Other uses of supercomputers scientific simulations, (animated) graphics, fluid dynamic calculations, nuclear energy research, electronic design, and analysis of geological data (e.g. in petrochemical prospecting). Perhaps the best known supercomputer manufacturer is Cray Research. Mainframe was a term originally referring to the cabinet containing the central processor unit or "main frame" of a room-filling Stone Age batch machine. After the emergence of smaller "minicomputer" designs in the early 1970s, the traditional big iron machines were described as "mainframe computers" and eventually just as mainframes. Nowadays a Mainframe is a very large and expensive computer capable of supporting hundreds, or even thousands, of users simultaneously. The chief difference between a supercomputer and a mainframe is that a supercomputer channels all its power into executing a few programs as fast as possible, whereas a mainframe uses its power to execute many programs concurrently. In some ways, mainframes are more powerful than supercomputers because they support more simultaneous programs. But supercomputers can execute a single program faster than a mainframe. The distinction between small mainframes and minicomputers is vague, depending really on how the manufacturer wants to market its machines. Minicomputer It is a midsize computer. In the past decade, the distinction between large minicomputers and small mainframes has blurred, however, as has the distinction between small minicomputers and workstations. But in general, a minicomputer is a multiprocessing system capable of supporting from up to 200 users simultaneously. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Workstation It is a type of computer used for engineering applications (CAD/CAM), desktop publishing, software development, and other types of applications that require a moderate amount of computing power and relatively high quality graphics capabilities. Workstations generally come with a large, high-resolution graphics screen, at large amount of RAM, built-in network support, and a graphical user interface. Most workstations also have a mass storage device such as a disk drive, but a special type of workstation, called a diskless workstation, comes without a disk drive. The most common operating systems for workstations 2024/2025 2024/2025 are UNIX and Windows NT. Like personal 2024/2025 computers, most workstations are single-user computers. However, workstations are typically linked together to form a local-area network, although they can also be used as stand-alone systems. N.B.: In networking, workstation refers to any computer connected to a local-area network. It could be a workstation or a personal computer. Personal computer: It can be defined as a small, relatively inexpensive computer designed for an individual user. In price, personal computers range anywhere from a few hundred pounds to over five thousand pounds. All are based on the microprocessor technology that enables manufacturers to put an entire CPU on one chip. Businesses use personal computers for word processing, accounting, desktop publishing, and for running spreadsheet and database management applications. At home, the most popular use for personal computers is for playing games and recently for surfing the Internet. Personal computers first appeared in the late 1970s. One of the first and most popular personal computers was the Apple II, introduced in 1977 by Apple Computer. During the late 1970s and early 1980s, new models and competing operating systems seemed to appear daily. Then, in 1981, IBM entered the fray with its first personal computer, known as the IBM PC. The IBM PC quickly became the personal computer of choice, and most other personal computer manufacturers fell by the wayside. P.C. is short for personal computer or IBM PC. One of the few companies to survive IBM's onslaught was Apple Computer, which remains a major player in the personal computer marketplace. Other companies adjusted to IBM's dominance by building IBM clones, computers that were internally almost the same as the IBM PC, but that cost less. Because IBM clones used the same microprocessors as IBM PCs, they were capable of running the same software. Over the years, IBM has lost much of its influence in directing the evolution of PCs. Therefore after the release of the first PC by IBM the term PC increasingly came to mean IBM or IBM- compatible personal computers, to the exclusion of other types of personal computers, such as Macintoshes. In recent years, the term PC has become more and more difficult to pin down. In general, though, it applies to any personal computer based on an Intel microprocessor, or on an Intel-compatible microprocessor. For nearly every other component, including the operating system, there are several options, all of which fall under the rubric of PC Today, the world of personal computers is basically divided between Apple Macintoshes and PCs. The principal characteristics of personal computers are that they are single-user systems and are based on microprocessors. However, although personal computers are designed as single-user systems, it is common to link them together to form a network. In terms of power, there is great ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ variety. At the high end, the distinction between personal computers and workstations has faded. High-end models of the Macintosh and PC offer the same computing power and graphics capability as low-end workstations by Sun Microsystems, Hewlett-Packard, and DEC. 2.5 Personal Computer Types Actual personal computers can be generally classified by size and chassis / case. The chassis or case is the metal frame that serves as the structural support for electronic components. Every computer 2024/2025 system requires at least one chassis2024/2025 to house the circuit boards and2024/2025 wiring. The chassis also contains slots for expansion boards. If you want to insert more boards than there are slots, you will need an expansion chassis, which provides additional slots. There are two basic flavors of chassis designs–desktop models and tower models– but there are many variations on these two basic types. Then come the portable computers that are computers small enough to carry. Portable computers include notebook and subnotebook computers, hand-held computers, palmtops, and PDAs. Tower model The term refers to a computer in which the power supply, motherboard, and mass storage devices are stacked on top of each other in a cabinet. This is in contrast to desktop models, in which these components are housed in a more compact box. The main advantage of tower models is that there are fewer space constraints, which makes installation of additional storage devices easier. Desktop model A computer designed to fit comfortably on top of a desk, typically with the monitor sitting on top of the computer. Desktop model computers are broad and low, whereas tower model computers are narrow and tall. Because of their shape, desktop model computers are generally limited to three internal mass storage devices. Desktop models designed to be very small are sometimes referred to as slimline models. Notebook computer An extremely lightweight personal computer. Notebook computers typically weigh less than 6 pounds and are small enough to fit easily in a briefcase. Aside from size, the principal difference between a notebook computer and a personal computer is the display screen. Notebook computers use a variety of techniques, known as flat-panel technologies, to produce a lightweight and non-bulky display screen. The quality of notebook display screens varies considerably. In terms of computing power, modern notebook computers are nearly equivalent to personal computers. They have the same CPUs, memory capacity, and disk drives. However, all this power in a small package is expensive. Notebook computers cost about twice as much as equivalent regular-sized computers. Notebook computers come with battery packs that enable you to run them without plugging them in. However, the batteries need to be recharged every few hours. Laptop computer A small, portable computer -- small enough that it can sit on your lap. Nowadays, laptop computers are more frequently called notebook computers. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Subnotebook computer A portable computer that is slightly lighter and smaller than a full-sized notebook computer. Typically, subnotebook computers have a smaller keyboard and screen, but are otherwise equivalent to notebook computers. Hand-held 2024/2025 computer 2024/2025 2024/2025 A portable computer that is small enough to be held in one’s hand. Although extremely convenient to carry, handheld computers have not replaced notebook computers because of their small keyboards and screens. The most popular hand-held computers are those that are specifically designed to provide PIM (personal information manager) functions, such as a calendar and address book. Some manufacturers are trying to solve the small keyboard problem by replacing the keyboard with an electronic pen. However, these pen- based devices rely on handwriting recognition technologies, which are still in their infancy. Hand-held computers are also called PDAs, palmtops and pocket computers. Palmtop A small computer that literally fits in your palm. Compared to full-size computers, palmtops are severely limited, but they are practical for certain functions such as phone books and calendars. Palmtops that use a pen rather than a keyboard for input are often called hand-held computers or PDAs. Because of their small size, most palmtop computers do not include disk drives. However, many contain PCMCIA slots in which you can insert disk drives, modems, memory, and other devices. Palmtops are also called PDAs, hand-held computers and pocket computers. PDA Short for personal digital assistant, a handheld device that combines computing, telephone/fax, and networking features. A typical PDA can function as a cellular phone, fax sender, and personal organizer. Unlike portable computers, most PDAs are pen-based, using a stylus rather than a keyboard for input. This means that they also incorporate handwriting recognition features. Some PDAs can also react to voice input by using voice recognition technologies. The field of PDA was pioneered by Apple Computer, which introduced the Newton MessagePad in 1993. Shortly thereafter, several other manufacturers offered similar products. To date, PDAs have had only modest success in the marketplace, due to their high price tags and limited applications. However, many experts believe that PDAs will eventually become common gadgets. PDAs are also called palmtops, hand-held computers and pocket computers. 2.6 Data, Information and Knowledge Data: Facts and figures which relay something specific, but which are not organized in any way and which provide no further information regarding patterns, context, etc. So data means "unstructured facts and figures that have the least impact on the typical manager." ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Information: For data to become information, it must be contextualized, categorized, calculated and condensed. Information thus paints a bigger picture; it is data with relevance and purpose. It may convey a trend in the environment, or perhaps indicate a pattern of sales for a given period of time. Essentially information is found "in answers to questions that begin with such words as who, what, where, when, and how many". Knowledge: Knowledge is closely linked to doing and implies know-how and understanding. The knowledge 2024/2025 possessed by each individual is a product 2024/2025 of his experience, and encompasses 2024/2025 the norms by which he evaluates new inputs from his surroundings. The content of the human mind can be classified into four categories: 1. Data: symbols 2. Information: data that are processed to be useful; provides answers to "who", "what", "where", and "when" questions 3. Knowledge: application of data and information; answers "how" questions 4. Wisdom: evaluated understanding. We need to understand that processing data produced Information and process Information produces Knowledge and so on 2.7 Characteristics of Computer Speed, accuracy, diligence, storage capability and versatility are some of the key characteristics of a computer. A brief overview of these characteristics are Speed: The computer can process data very fast, at the rate of millions of instructions per second. Some calculations that would have taken hours and days to complete otherwise, can be completed in a few seconds using the computer. For example, calculation and generation of salary slips of thousands of employees of an organization, weather forecasting that requires analysis of a large amount of data related to temperature, pressure and humidity of various places, etc. Accuracy: Computer provides a high degree of accuracy. For example, the computer can accurately give the result of division of any two numbers up to 10 decimal places. Diligence: When used for a longer period of time, the computer does not get tired or fatigued. It can perform long and complex calculations with the same speed and accuracy from the start till the end. Storage Capability: Large volumes of data and information can be stored in the computer and also retrieved whenever required. A limited amount of data can be stored, temporarily, in the primary memory. Secondary storage devices like floppy disk and compact disk can store a large amount of data permanently Versatility: Computer is versatile in nature. It can perform different types of tasks with the same ease. At one moment you can use the computer to prepare a letter document and in the next moment you may play music or print a document. Computers have several limitations too. Computer can only perform tasks that it has been programmed to do. Computer cannot do any work without instructions from the user. It executes instructions as specified by the user and does not take its own decisions. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 2.8 Computer Viruses Viruses: A virus is a small piece of software that piggybacks on real programs. For example, a virus might attach itself to a program such as a spreadsheet program. Each time the spreadsheet program runs, the virus runs, too, and it has the chance to reproduce (by attaching to other programs) or wreak havoc. E-mail viruses: An e-mail virus travels as an attachment to e-mail messages, and usually replicates itself by automatically mailing itself to dozens of people in the victim's e-mail address book. Some e-mail viruses don't 2024/2025 even require a double-click --2024/2025 2024/2025 they launch when you view the infected message in the preview pane of your e-mail software [source: Johnson]. Trojan horses: A Trojan horse is simply a computer program. The program claims to do one thing (it may claim to be a game) but instead does damage when you run it (it may erase your hard disk). Trojan horses have no way to replicate automatically. Worms: A worm is a small piece of software that uses computer networks and security holes to replicate itself. A copy of the worm scans the network for another machine that has a specific security hole. It copies itself to the new machine using the security hole, and then starts replicating from there, as well. What are some tips to avoid viruses and less their impact? Install anti-virus software from a reputable vendor. Update it and use it regularly. In addition to scanning for viruses on a regular basis, install an "on access" scanner (included in most anti-virus software packages) and configure it to start each time you start up your computer. This will protect your system by checking for viruses each time you run an executable file. Use a virus scan before you open any new programs or files that may contain executable code. This includes packaged software that you buy from the store as well as any program you might download from the Internet. If you are a member of an online community or chat room, be very careful about accepting files or clicking links that you find or that people send you within the community. Make sure you back up your data (documents, bookmark files, important email messages, etc.) on disc so that in the event of a virus infection, you do not lose valuable wo Chapter 3 Computer hardware and software components The Computer A computer is made up of many parts HARDWARE AND SOFTWARE: 3.1 Hardware: Computer hardware is the collection of physical elements that constitutes a computer system. Computer hardware refers to the physical parts or components of a computer such as the monitor, mouse, keyboard, computer data storage, hard drive disk (HDD), system unit (graphic cards, sound ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ cards, memory, motherboard and chips), etc. all of which are physical objects that can be touched. 3.1.1 Input/Output (I/O) devices – These allow you to send information to the computer or get information from the computer. Input Devices Input device is any peripheral (piece of computer 2024/2025 hardware equipment to provide 2024/2025 data and 2024/2025 control signals to an information processing system such as a computer or other information appliance. Input device Translate data from form that humans understand to one that the computer can work with. Most common are keyboard and mouse Example of Input Devices:- 1. Keyboard 2. Mouse (pointing device) 3. Microphone 4. Touch screen 5. Scanner 6. Webcam 7. Touchpads 8. MIDI keyboard 9. Electronic Whiteboard 10.Graphics Tablets 11.Cameras 12.Pen Input 13.Video Capture Hardware 14.Microphone 15.Trackballs 16.Barcode reader 17.Digital camera 18.Joystick 19.Gamepad Note: The most common use keyboard is the QWERTY keyboard. Generally standard Keyboard has 104 keys. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Output devices An output device is any piece of computer hardware equipment used to communicate the results of data processing carried out by an information processing system (such as a computer) which converts the electronically generated information into human- readable form. 2024/2025 2024/2025 2024/2025 Example on Output Devices: 1. Monitor 2. LCD Projection Panels 3. Printers (all types) 4. Computer Output Microfilm (COM) 5. Plotters 6. Speaker(s) 7. Projector Note Basic types of monitors are a. Cathode Ray Tube (CRT). b. Liquid Crystal Displays (LCD). c. light-emitting diode (LED). Printer types: 1- Laser Printer. 2- Ink Jet Printer. 3- Dot Matrix Printer 3.1.2 Central Processing Unit – CPU or Processor for short. The brain of a computer. Approximately 1.5 in X 1.5 in. Does all the computation/work for the computer. Central Processing Unit (CPU) A CPU is brain of a computer. It is responsible for all functions and processes. Regarding computing power, the CPU is the most important element of a computer system. The CPU is comprised of three main parts: Arithmetic Logic Unit (ALU): Executes all arithmetic and logical operations. Arithmetic calculations like as addition, subtraction, multiplication and division. Logical operation like compare numbers, letters, or special characters Control Unit (CU): controls and co-ordinates computer components. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 1. Read the code for the next instruction to be executed. 2. Increment the program counter so it points to the next instruction. 3. Read whatever data the instruction requires from cells in memory. 4. Provide the necessary data to an ALU or register. 5. If the instruction requires an ALU or specialized hardware to complete, instruct the hardware to perform the requested operation. 2024/2025 Registers: Stores the data that is 2024/2025 to be executed next, "very fast storage 2024/2025area". 3.1.3 Memory – Although memory is technically any form of electronic storage, it is used most often to identify fast, temporary forms of storage. Accessing the hard drive for information takes time. When the information is kept in memory, the CPU can access it much more quickly. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Random Access Memory – RAM. Where information is stored temporarily when a program is run. Information is automatically pulled into memory, we cannot control 2024/2025 this. RAM is cleared automatically2024/2025 when the computer is shutdown or rebooted. RAM 2024/2025 is volatile (non-permanent). Read Only Memory – ROM. More permanent than RAM. Data stored in these chips is nonvolatile -- it is not lost when power is removed. Data stored in these chips is either unchangeable or requires a special operation to change. The BIOS is stored in the CMOS, read- only memory. Hard Drive – Where you store information permanently most frequently. This is also nonvolatile. Optical Disk – an optical disc drive (ODD) is a disk drive that uses laser light as part of ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ the process of reading or writing data to or from optical discs. Some drives can only read from discs, but recent drives are commonly both readers and recorders, also called burners or writers. Compact discs, DVDs, and Blu-ray discs are common types of optical media which can be read and recorded by such drives. Optical drive is the generic name; drives are usually described as "CD" "DVD", or "Bluray", followed by "drive", "writer", etc. There are three main types of optical media: CD, DVD, and Blu- ray disc. CDs can store up to 700 megabytes (MB) of data and DVDs can store up to 8.4 GB of data. Blu-ray discs, which are the newest type of optical media, can store up to 2024/2025 50 GB of data. This storage capacity is a clear advantage over the floppy 2024/2025 disk storage 2024/2025 media (a magnetic media), which only has a capacity of 1.44 MB. Flash Disk – a storage module made of flash memory chips. A Flash disks have no mechanical platters or access arms, but the term "disk" is used because the data are accessed as if they were on a hard drive. The disk storage structure is emulated. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 3.1.4 Motherboard – A circuit board that allows the CPU to interact with other parts of the computer 3.1.5 Ports – Means of connecting peripheral devices to your computer. Serial Port – Often used to connect a older mice, older external modems, older digital cameras, etc to the computer. The serial port has been replaced by USB in most cases. 9-pin connector. Small and short, often gray in color. Transmits data at 19 Kb/s. 2024/2025 2024/2025 2024/2025 Monitor Ports – Used to connect a monitor to the computer. PCs usually use a VGA (Video Graphics Array) analog connector (also known as a D-Sub connector) that has 15 pins in three rows. Typically blue in color. Because a VGA (analog) connector does not support the use of digital monitors, the Digital Video Interface (DVI) standard was developed. LCD monitors work in a digital mode and support the DVI format. At one time, a digital signal offered better image quality compared to analog technology. However, analog signal processing technology has improved over the years and the difference in quality is now minimal. Parallel Port – Most often used to connect a printer to the computer. 25-pin connector. Long and skinny, often pink in color. Transmits data at 50-100 Kb/s. USB Port – Universal Serial Bus. Now used to connect almost all peripheral devices to the computer. USB 1.1 transmits data at 1.5 Mb/s at low speed, 12 Mb/s at full speed. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ USB 2.0 transmits data at 480 Mb/s. 2024/2025 2024/2025 2024/2025 Firewire/ IEEE 1394 Port – Often found on Apple Computers. Often used with digital camcorders. Firewire transmits data at 400 Mb/s. Firewire 1394B (the new firewire) transmits data at 3.2 Gb/s. PS/2 Port - sometimes called a mouse port, was developed by IBM. It is used to connect a computer mouse or keyboard. Most computers come with two PS/2 ports. Ethernet Port – This port is used for networking and fast internet connections. Data moves through them at speeds of either 10 megabits or 100 megabits or 1 gigabit (1,000 megabits) depending on what speed the network card in the computer supports. Little monitor lights on these devices flicker when in use. 3.1.6 Power Supply – Gives your computer power by converting alternating current (AC) supplied by the wall connection to direct current (DC). ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 3.1.7 Expansion Cards – Used to add/improve 2024/2025 functionality to the computer. 2024/2025 2024/2025 Sound Card – Used to input and output sound under program control. Sound cards provide better sound quality than the built in sound control provided with most computers. Graphics Card – Used to convert the logical representation of an image to a signal that can be used as input for a monitor. Network Card – Used to provide a computer connection over a network. Transmit data at 10/100/1000 Mb/s. 3.1.8 CD ROM – A device used to read CD-ROMs. If capable of writing to the CD-ROM, then they are usually referred to as a ‘burner’ or CD-RW. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 3.1.9 DVD ROM – A device that is used to read DVDs/CDs. If capable of writing to the DVD, then it is often referred to as a DVD-burner 2024/2025 or a DVD-RW. 2024/2025 2024/2025 3.1.10 Floppy Drive – A device that is used to read/write to floppy diskettes. 3.1.11 Fan – Keeps your computer cool. If the inside of your computer becomes too hot, then the computer can overheat and damage parts. 3.1.12 Heatsink – Used to disperse the heat that is produced inside the computer by the CPU and other parts by increasing surface area. 3.1.13 The little parts – Capacitors – store energy, Resistors – allows a current through, Transistors – a valve which allows currents to be turned on or off. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 3.1.14 Case –(Tower if standing upright.) What your motherboard, CPU, etc is contained in. 2024/2025 2024/2025 2024/2025 The three main components of a computer: 1. CPU – Central Processing Unit, coordinates all actions that occur in the system, executes program instructions. 2. Memory – Used to store information. 3. I/O Devices – input/output devices, which allow you to obtain or display data. 3.2 Software Software is a generic term for organized collections of computer data and instructions, often broken into two major categories: system software that provides the basic non- task-specific functions of the computer, and application software which is used by users to accomplish specific tasks. Software Types A. System software is responsible for controlling, integrating, and managing the individual hardware components of a computer system so that other software and the users of the system see it as a functional unit without having to be concerned with the low-level details such as transferring data from memory to disk, or rendering text onto a display. Generally, system software consists of an operating system and some fundamental utilities such as disk formatters, file managers, display managers, text editors, user authentication (login) and management tools, and networking and device control software. B. Application software is used to accomplish specific tasks other than just running the computer system. Application software may consist of a single program, such as an image viewer; a small collection of programs (often called a software package) that work closely together to accomplish a task, such as a spreadsheet or text processing system; a larger collection (often called a software suite) of related but independent programs and packages that have a common user interface or shared data format, such as Microsoft Office, which consists of closely integrated word processor, spreadsheet, database, etc.; or a software system, such as a database management system, which is a collection of fundamental programs that may provide some service to a variety of other independent applications. ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Comparison Application Software and System Software System Software Application Software Computer software, or just software is a general term primarily used for digitally Application software, also known as an 2024/2025 stored data such as computer programs 2024/2025 2024/2025 application or an "app", is computer and other kinds of information read and software designed to help the user to written by perform specific tasks. computers. App comes under computer software though it has a wide scope now. Example: 1) Microsoft Windows 1) Opera (Web Browser) 2) Linux 2) Microsoft Word (Word Processing) 3) Unix 3) Microsoft Excel (Spreadsheet software) 4) Mac OSX 4) MySQL (Database Software) 5) DOS 5) Microsoft PowerPoint (Presentation Software) 6) Adobe Photoshop (Graphics Software) Interaction: Generally, users do not interact with Users always interact with application system software as it works in the software while doing different activities. background. Dependency: System software can run independently of Application software cannot run without the the presence of the system software. application software. Unit of Measurements Storage measurements: The basic unit used in computer data storage is called a bit (binary digit). Computers use these little bits, which are composed of ones and zeros, to do things and talk to other computers. All your files, for instance, are kept in the computer as binary files and translated into words and pictures by the software (which is also ones and zeros). This two number system, is called a “binary number system” since it has only two numbers in it. The decimal number system in contrast has ten unique digits, zero through nine. Computer Storage units Bit BIT 0 or 1 Kilobyte KB 1024 bytes ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Megabyte MB 1024 kilobytes Gigabyte GB 1024 megabytes Terabyte TB 1024 gigabytes Size example 1 bit - answer to an yes/no question 1 byte - a number from 0 to 255. 2024/2025 2024/2025 2024/2025 90 bytes: enough to store a typical line of text from a book. 4 KB: about one page of text. 120 KB: the text of a typical pocket book. 3 MB - a three minute song (128k bitrate) 650-900 MB - an CD-ROM 1 GB -114 minutes of uncompressed CD-quality audio at 1.4 Mbit/s 8-16 GB - size of a normal flash drive Speed measurement: The speed of Central Processing Unit (CPU) is measured by Hertz (Hz), which represent a CPU cycle. The speed of CPU is known as Computer Speed. CPU SPEED MEASURES 1 hertz or Hz 1 cycle per second 1 MHz 1 million cycles per second or 1000 Hz 1 GHz 1 billion cycles per second or 1000 MHz Chapter 4 Data Representation and Number systems 4.1 Number systems are the technique to represent numbers in the computersystem architecture, every value that you are saving or getting into/from computer memory has a defined number system. Computer architecture supports following number systems. Binary number system ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Octal number system Decimal number system Hexadecimal (hex) number system 2024/2025 2024/2025 2024/2025 1) Binary Number System A Binary number system has only two digits that are 0 and 1. Every number(value) represents with 0 and 1 in this number system. The base of binary number system is 2, because it has only two digits. 2) Octal number system Octal number system has only eight (8) digits from 0 to 7. Every number (value) represents with 0,1,2,3,4,5,6 and 7 in this number system. The base ofoctal number system is 8, because it has only 8 digits. 3) Decimal number system Decimal number system has only ten (10) digits from 0 to 9. Every number (value) represents with 0,1,2,3,4,5,6, 7,8 and 9 in this number system. The baseof decimal number system is 10, because it has only 10 digits. 4) Hexadecimal number system A Hexadecimal number system has sixteen (16) alphanumeric values from 0 to 9 and A to F. Every number (value) represents with 0,1,2,3,4,5,6, 7,8,9,A,B,C,D,E and F in this number system. The base of hexadecimal numbersystem is 16, because it has 16 alphanumeric values. Here A is 10, B is 11, C is12, D is 13, E is 14 and F is 15. Table of the Numbers Systems with Base, Used Digits, Representation, ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Number system Base Used digits Example Binary 2 0,1 (11110000)2 Octal 8 0,1,2,3,4,5,6,7 (360)8 2024/2025 2024/2025 2024/2025 Decimal 10 0,1,2,3,4,5,6,7,8,9 (240)10 Hexadecimal 16 0,1,2,3,4,5,6,7,8,9, A, B, C, D, (F0)16 E, F 4.3 NUMBER CONVERSIONS: To convert Number system from Decimal Number System to Any OtherBase is quite easy; you have to follow just two steps: 1. Divide the Number (Decimal Number) by the base of target base system (inwhich you want to convert the number: Binary (2), octal (8) and Hexadecimal (16)). 2. Write the remainder from step 1 as a Least Signification Bit (LSB) to Steplast as a Most Significant Bit (MSB). Decimal Number is Binary Number is : (12345)10 (11000000111001)2 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ Decimal to Octal Conversion Result 2024/2025 2024/2025 2024/2025 Decimal Number is : (12345)10 Octal Numberis (30071)8 Decimal to Hexadecimal Conversion Result Example 1 HexadecimalNumber is Decimal Number is : (12345)10 (3039)16 For example: a. (149)10 2 149 1 2 74 0 2 37 1 2 18 0 2 9 1 2 4 0 2 2 0 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 2 1 1 0 Therefore, (149)10 = (10010101)2 b. 2024/2025 2024/2025 2024/2025 Here, (804)10 8 804 4 8 100 4 8 12 4 8 1 1 0 Therefore, (804)10 = (1444)8 c. Here, (1600)10 16 1600 0 16 100 4 16 6 6 0 Therefore, (1600)10 = (640)16 d. Here, (100100)2 = 25 x 1 + 24 x 0 + 23 x 0 + 22 x 1 + 21 x 0 + 20 x 0 = 32 + 0 + 0 + 4 + 0 + 0 = (36)10 e. Here, (2040)8 = 83 x 2 + 82 x 0 + 81 x 4 + 80 x 0 = 1024 + 32 = (1056)10 f. Here, (1E0D)16 = 163 x 1 + 162 x E + 161 x 0 + 160 x D = 4096 + 256 x 14 + 0 + 1 x 13 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ = 4096 + 3584 + 13 = (7693)10 g. Here, (110111101)2 110 111 101 6 7 5 2024/2025 2024/2025 2024/2025 Therefore, (110111101)2 = (675)8 h. Here, (1001110111)2 0010 0111 0111 2 7 7 Therefore, (1001110111)2 = (277)16 i. Here, (375)8 3 7 5 011 111 101 Therefore, (375)8 = (11111101)2 j. Here, (ABC)16 A B C 1010 1011 1100 Therefore, (ABC)16 = (101010111100)2 k. Here, (555)8 5 5 5 101 101 101 = (101101101)2 0001 0110 1101 1 6 D Therefore, (555)8 = (16D)16 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ l. Here, (BCA)16 B C A 1011 1100 1010 = (101111001010)16 101 111 001 010 2024/2025 2024/2025 2024/2025 5 7 1 2 Therefore, (BCA)16 = (5712)8 TO CONVERT DECIMAL PART: a. Here, (0.55)10 0.55 x 2 = 1.1 1 0.1 x 2 = 0.2 0 0.2 x 2 = 0.4 0 0.4 x 2 = 0.8 0 0.8 x 2 = 1.6 1 0.6 x 2 = 1.2 1 Therefore, (0.55)10 = (0.100011)2 b. Here, (234.997)10 8 234 2 8 29 5 8 3 3 0 Also 0.997 x 8 = 7.976 7 0.976 x 8 = 7.808 7 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 0.808 x 8 = 6.464 6 0.464 x 8 = 3.712 3 0.712 x 8 = 5.696 5 0.696 x 8 = 5.568 5 Therefore, 2024/2025 (234.997)10 = (352.776355)2 2024/2025 2024/2025 c. Here, (689.336)10 16 689 1 16 43 11 =B 16 2 2 0 Also 0.336 x 16 = 5.376 5 0.376 x 16 = 6.016 6 0.016 x 16 = 0.256 0 0.256 x 16 = 4.096 4 0.096 x 16 = 1.536 1 0.536 x 16 = 8.576 8 Therefore, (689.336)10 = (2B1.560418)16 d. Here, (101.1101)2 = 22 x 1 + 21 x 0 + 20 x 1 + 2-1 x 1 + 2-2 x 1 + 2-3 x 0 + 2-4 x 1 = 4 + 0 + 1 + 0.5 + 0.25 + 0 + 0.0625 = (5.8125)10 e. Here, (0.1042)8 = 8-1 x 1 + 8-2 x 0 + 8-3 x 4 + 8-4 x 2 = 0.125 + 0 + 0.0078125 + 0.00048828125 = (0.1333)10 f. Here, (FA.AEF)16 = 161 x 15 + 160 x 10 + 16-1 x 10 + 16-2 x 14 + 16-3 x 15 = 240 + 10 + 0.625 + 0.0546875 + 0.00366211 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ = (250.68335)10 g. Here, (101010.110111)2 101 010 110 111 5 2 6 7 Therefore, 2024/2025 (101010.110111) = (52.67) 2 8 2024/2025 2024/2025 h. Here, (10101.11011)2 0001 0101 1101 1000 1 5 D 8 Therefore, (10101.11011)2 = (15.D8)16 i. Here, (77.226)8 7 7 2 2 6 111 111 010 010 110 Therefore, (77.226)8 = (111111.010010110)2 j. Here, (0.376)8 3 7 6 011 111 110 = (011111110)2 0111 1111 7 F Therefore, (0.376)8 = (0.7F)16 k. Here, (0.5AB)16 5 A B 0101 1010 1011 Therefore, (0.5AB)16 = (0.010110101011)2 ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ l. Here, (0.226)16 2 2 6 0010 0010 0110 = (0.001000100110)2 001 000 100 110 2024/2025 2024/2025 2024/2025 1 0 4 6 Therefore, (0.226)16 = (0.1046)8 4.4 Signed Integer Representation By convention, a “1” in the high-order bit indicate a negative number. 4.5 Signed Magnitude A signed-magnitude number has a sign as its left-most bit (also referred to as the high- order bit or the most significant bit) while the remaining bits represent the magnitude (or absolute value) of the numeric value. N bits can represent –(2n-1 - 1) to 2n-1 -1 EXAMPLE 4.1 Add 010011112 to 001000112 using signed-magnitude arithmetic. 010011112 (79) + 001000112 (35) = 011100102 (114) There is no overflow in this example EXAMPLE 4.2 Add 010011112 to 011000112 using signed-magnitude arithmetic. An overflow condition and the carry is discarded, resulting in an incorrect sum. We obtain the erroneous result of 010011112 (79) + 011000112 (99) = 01100102 (50) EXAMPLE 4.3 Subtract 010011112 from 011000112 using signed-magnitude arithmetic. We find 0110000112 (99) - 010011112 (79) = 000101002 (20) in signed-magnitude representation. The signed magnitude has two representations for zero, 10000000 and 00000000 (and mathematically speaking, the simple shouldn’t happen!). ‫ﻧﻬﺎﻝ ﻃﺎﺭﻕ ﺍﺣﻤﺪ ﻏﻴﻂ‬ 4.6 Complement Systems One’s Complement o This sort of bit-flipping is very simple to implement in computer hardware. o EXAMPLE 4.4 Express 2310 and -910 in 8-bit binary one’s complement form. 2310 = + (000101112) = 000101112

Use Quizgecko on...
Browser
Browser