0% found this document useful (0 votes)
211 views

Taleem Spot - 9th Class Computer Science

The document outlines the contributions of various authors and committee members involved in the creation of a textbook published by the Punjab Curriculum and Textbook Board, Lahore. It provides a detailed table of contents covering topics such as systems theory, number systems, digital systems, software systems, and emerging technologies in computer science. The text emphasizes the importance of understanding systems, their components, and interactions in both natural and artificial contexts.

Uploaded by

carehouse6616
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
211 views

Taleem Spot - 9th Class Computer Science

The document outlines the contributions of various authors and committee members involved in the creation of a textbook published by the Punjab Curriculum and Textbook Board, Lahore. It provides a detailed table of contents covering topics such as systems theory, number systems, digital systems, software systems, and emerging technologies in computer science. The text emphasizes the importance of understanding systems, their components, and interactions in both natural and artificial contexts.

Uploaded by

carehouse6616
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 151
Authors * Prof. Dr. Muhammad Atif (PhO Computer Science) Professor of Computer Science, Lahore Gartson Univers. * Prof, Dr. Syed Wager ul Qounain Jaffry (PhD Computer Science) Chairman Dept of 7, University of The Puniaty Allama label Campus (Old Campus) Shahroh-e-Quai-e-Azam, Lahore. External Review Committee © Dr. Arshad Ali e Dr. Mudasser Naseer (PFO Computer Sderce and Telcormnuniation) (PhD Computer Sclence) Associate Professor, Department Associate Professor(CS, Head (Cyber Security Department of CS ae, Lahore Garson Univer. Univesity of Lahore Defense Ros Lahore * Mrs. Tabinda Mugaddas * Prof. Dr. Asif Shahzad Assistant Professor, Head of Department (CS), (PhO Computer Scenes) Govt Associate College for Women, Chairmen Department of Gulshan Ravi, Lahore. Computer Science, University of Engineering and Technology ahore * Dr. Nadeem Iqbal ‘* Dr. Abdul Sattar {PHD Computer Sconce) (Pho Computer Science) Associate Assistant Professor (C5), Department of CS & 7. Lahore Garrison University University of Lahore Defense Road, Lahore * Dr. Adee! Nisar © Mr. Fahad Asif (Pho Computer Science) ETI, ‘Assistant Professor), Govt. Lab Higher Secondary School University of The Punjab, Alama gba Campus QAED Kasur, (ld Campus), Shabrah-e-Cund-e-Azar, Lahore Derecter: ‘By. Director (Graptiics) Mr. Jaharzaib Khan Ms. Rehana Farhat IMs. Aisha Sadiq S$ Compute Ser Director (Design & Layout iwstraton Mr. intiaz Hussain Mr. Aleem Ur Rehman Mr Ayet Ullah Published by: Punjab Curriculum and Textbook Board, Lahore, Printed by: NEWISH PRINTERS, LAHORE. imme | roms |e [rom [ mene | itn | [ort ews] ay (eev[ores [oe [oe [oe | se [ee [oo [io | ones C Alll rights are reserved with No part: > the Punjab Curriculum and Textbook Board, Lahore. ofthis textbook can be copied, translated, reproduced or used for preparation of test papers, guidebooks, keynotes and helping books. Contents Unit Topic Page 1 _| Introduction to Systems t 2 | Number Systems. 24 3 | Digital Systems and Logic Design 49 4 | System Troubleshooting 69 5 | Software System 87 6 | Introduction to Computer Networks 99 7 _| Computational Thinking 123 8 _| Web Development with HTML, CSS and JavaScript 151 9 _| Data Science and Data Gathering 179 10 | Emerging Technologies in Computer Science 211 11_| Ethical, Social, and Legal Concerns in Computer Usage | 295 12_| Entrepreneurship in Digital Age 243 13__| Answers 261 cies Hap (in the Name of Allah, the Most Compassionate, the Most Merciful) ___ Based on Revised National Curriculum of Pakistan 2023 a fo PUNJAB CURRICULUM AND TEXTBOOK BOARD, LAHORE ° ° ° ° Se Peet fee eee Gs ge, mcr ae ee Introduction to Systems Define and describe general system theory, Its types, objectives, components, and Explainthe concept of system, including objectives, components, and communication, minors of oe stfeches scores ates ch the importance of system objectives and common as Seed esac acerca mehr ‘Understand the roleandimportance of system components and thelr interactions. Explain the significance ofinteractions among various systems, Differentiate between natural andartifcal ystems. Categorize and describe various types of natural and artificial systems, their objectives, SSerpies of poiealejinre, hod phn cher biological and Provide ‘ature Including lL a Prove sales and felons of aca! Sptes,icung knowledge Provide examples of systems, systems, engineeringsystems, and socal systems. Analyze systems to ident ther objectives, components, and interactions. Compare and contrast diferent types of systems, highlighting variations In objectives, components, Conduct research onspecticsystem types and present findings effectively. Create diagrams or models to visually represent the structure and interactions of ystems. ‘Assess the role and importance of system objectivesin real-world applications. Demonstrate understanding of how systems apply to diferent fields and serve specific ‘components, and interactions. Understand the primary objcties of computing system including processing dat, Recognize the ole and importance of computer system components andtherintracions, Identify necessary and auxiliary components ofa computer system ‘dentify different types of computing systems, such as computers, software, computer networks, andthe internet. Understand the Von Neumann architecture and ts core components: CP, motherboard, ‘memory, storage devices input/output ports, and devices. Explain the relationship between the CPU, memory, and storage, and how data flows within asystem, Describe how components within a computer system interact to execute tasks, such as how the CPU fetches, decodes, and executes Differentiate between the roles of hardware and softwareina computer system. Define and describe Computing system and its types including Computer, Software, ‘Networkandthe internet. Describe the main functions of system software, such as operating systems, and application software. SS This chapter provides an overview of the theory of systems, introducing fundamental concepts and exploring various types of systems. It begins by defining what a system is, discussing its basic components, objectives, environment, and methods of communication. The chapter then differentiates between natural and artificial systems, explaining how they function and their Purposes. The relationship between systems and different branches of science is also explored, peta natural science, design science, and computer science, The chapter then shifts back to discussing computers as systems, explaining their goals, parts, and how these parts connect with each other and their Surroundings. It provides a detailed look at the Von Neumann computer architecture, exploring its components, how it works, its unique features, as well as its strengths and weaknesses. The chapter also covers different types of computing systems, such as computers, software, networks, and the Internet, Clearly explaining their roles and purposes. At the end of this chapter, the reader will be in a better position to understudy systems, their classification, and relevance in natural and man-made systems to aid future learning and utilization, 1.1 Theory of Systems The idea of a system is useful to explain both the external reality as well as the internal one. An Information System is simply an organized set of components that are coordinated to perform a designated function. All the components of the system are in some way related to each other and the functioning of the other ‘components enhances the operation of the system. Let us consider a simple example, such as a car, depicted in Figure 1. 1: it is made Up of an engine, wheels, brakes, and other related items. Every part plays @ unique task, but collectively they are responsible for making the car move. Likewise, every computer, organism, machine, or device has components that work together to achieve an outcome. ey) ie A branch ofa science that deals with complicated structures in living organisms, that relate the human with society and the science is known as Systems Theory. It Gives a way of interpreting the existing world with different varied perspectives, how the different systems and sub-systems operate, how they are integrated, how they grow and how they change with time, Systems can be observed at all levels of existence, starting with the levels of nature, and going all the way up to levels of systems designed by humans. These can be physical objects-such as a car; processes, such as the university's admission process; or abstract objects such as a mathematical formula. Thinking about how systems operate helps us better understand how they need to be developed and nurtured across different discipline like computing, biology, engineering, and social science. In this section, basic concepts will be introduced to emphasize fundamental concepts and principles. 1.1.1 Basic Concepts of A system is described by its objectives components, communication among components and environment in which it works. The components of a system communicate with each other to achieve the system's objective in an environment. Systems can be simple, like a thermostat, or complex, like the human body ora computer network. 1.1.1.1 Objective Every system has a purpose or goal that it wishes to fulfil. Analyzing a system's operation requires Understanding its aim. This insight improves the efficiency and efficacy of the present system. A transport system aims to transfer people and products securely and effectively between locations. A computer system's principal goal is to process data and provide useful information to users. of Systems can have different objectives depending on their nature and purpose. Common objectives include: 1, Information processing: Collecting, storing, processing, and distributing information, for example © Acomputersystem processes user data to produce meaningful outputs. © The human brain processes information received by the human senses to perceive the environment. 2, Supporting other systems: Providing a platform or infrastructure for other systems to work, for example: © Acell phone provides a platform to run different applications. oThesun provides energy to all species on Earth to live. 3. Achieving specific goals: Completing tasks or processes, for example: © Athermostat system maintains a set temperature in an environment. © A car engine system aims to convert fuel into mechanical energy efficiently. a feon =I Brain: Information processing Cell Phone: Supporting Thermostat: Achieving other systems specific goals Fig. 1.2 Types of System Objectives ‘Human Brain System 1. Your brain is an incredible example of a communication network. Neurons send signals to each other, allowing you to think, move, and nce emotions. This complex communication is what makes our brains so powerful. 2. The brain produces around 20 watts of electrical energy, sufficient to Operate a low-wattage LED light bulb. Presented here is the brain's remarkable efficacy as an electrical system. 3. The information traveling through your brain moves at about 268 miles per hour, which is faster than a Formula 1 race car. 4. Your brain, as a biological system, has around 86 billion neurons. If each neuron was a person, it is like the population of about ten Earth all interacting simultaneously! 5. The human brain can perform about 10"* (10 quadrillion) operations per second, making it one of the most powerful and efficient biological systems in existence. 1.1.1.2 Components Components are the building blocks of any system, Each component plays a specific role and contributes to the overall functionality of the system. Understanding the role of each component of the system is essential to understand how the entire system works. This helps in identifying problems, improving performance, and refining system design. Smooth and proper working of these components together ensures the system meets its objectives. GBD, F912 components of Compute: ‘Human Body and its DNA System | 1. Consider your body as a very sophisticated and effective itis a remarkable system comprising subsystems such as the circulatory system, neurological system, and digestive system. The cardiovascular system circulates blood. The respiratory system supplies oxygen, and the cerebral system processes information. Individually, each has a distinct function yet collaborates to ensure our survival and well-being. DNA is like a blueprint for life. It's a system that contains all the instructions for an organism to grow, a luce, Passed down from generation to generation, Each cell in our body. 1.1.1.3 Environment environment of a system includes cure external to the system that interacts with it. It consists of all external factors that affect the system's operation. Understanding the environment of a system is important as it influences the system's performance and behavior by providing inputs and receiving outputs. Intelligent systems adjust to changes in their environment to. continue their functionality. There are several properties of a system's environment that affect system design and its functionality. Two of these properties are described as follows: tic vs. mic: + Static: The environment remains unchanged unless the system provides an output. There are no changes occurring in the environment while the systemis working internally. + Dynamic: The environment can change independently of the system's output. The system must account for changes that occur over time in the environment. Deterministic vs. Non-deterministic: + Deterministic: A deterministic system is characterized by its fully known and certain impact of its output on the environment. + Non-deterministic: The impact of the system's output on the environment is characterized by inherent uncertainty, randomness, or probability. 1.1.1.4 Communication + Communication and interaction among system components is key to the functioning of a system. It ensures that components work together in an organized and smooth manner to achieve the system's objectives. For example, in a computing system the CPU communicates with memory to fetch and store data, and in a biological system brain sends signals to muscles to initiate movement. System's Interaction with the Environment Systems constantly interact with their environment through inputs and outputs. For example, a weather monitoring system receives data from environment sensors and provides the current status of the weather and future forecasts to users. In a computing system, computers the interact and communicate with peripheral devices like printers and scanners, and in a biological system animals interact with plants and other animals, forming a food chain. Students " Perea that Warciae a tice, hot tartie trae _ where students will work in groups to identify and list the systems they interact with daily. They will then create a system map on poster boards, “labeling the components and their interactions. Finally, during a galery walk, _ each group will present their system map, followed by a feedback session _ where the teacher provides feedback and answers questions, | Output: Each group will produce a system map poster illustrating their | chosen system, and students will enhance their presentation and explanation _ skills. Activity: Design a Simple System Objective: To apply the principles of system design and understand the process of creating a functional system. Required Material: Computers or tablets with diagramming software (eg, Lucidchart), paper, pencils, markers. Activity Type: Pair ‘Activity Tasks Detail: Begin with an introduction where the teacher presents an ‘example of a simple system. Students will then work in pairs to define the ‘objective of their chosen system, list its components, describe their interactions, to create a system prototype or diagram. Finally, they will present their designs to the classin a review and feedback session. Each pair will produce a system prototype or diagram and receive feedback to refine their design ideas. 1.2 Types of Systems Systems can be broadly categorized into two types, namely natural and artificial systems. Understanding the differences and similarities between these types helps us apply system th¥ory across various fields. Natural systems are naturally built and occur in nature without human intervention. While artificial systems are created by humans to fulfil specific needs or purposes. Galaxy @ Natural System ‘Screw gouge an Artificial System 1.2.1. Natural Systems "2 1 fxamples of Systems Natural systems are those that exist in nature and operate independently of human involvement. They are governed by natural laws and processes. Natural systems are of various forms and sizes, from very tiny objects like atoms and cells in our body to. very huge like forests, oceans and the cosmos. Following are ‘examples of some natural systems that exists in nature. . 1.2.1.1 Physical Systems Physical systems are composed of physical components and governed by the laws of physics. They include things ranging from sub atomic particles, atoms, to planets, stars, galaxies, and cosmos. Physical systems, like any kind of matter, emerge from the interactions of electrons, protons, neutrons and sub-atomic particles which are governed by electric and atomic forces. For example hydrogen gas (H) is formed when an electron, proton, and neutron combine, following the rules of physics and natural forces. 1.2.1.2 Chemical ston Chemical systems involve substances and their interactions, transformations, and reactions. They are governed by the laws of chemistry. Chemical systems emerge from physical systems when atoms and molecules interact and bond according to chemical principles, forming new substances. For example, a eatited ‘system like water (H20) is formed when hydrogen atoms bond with ;genatoms, following chemical rules and reactions. a3 Biological Systems Biological systems consist of living organisms and their interactions. They are governed by biological processes such as growth, reproduction, and metabolism. Biological systems emerge from chemical systems when molecules aT interact in complex ways to form living cells, which then organize into tissues, organs, and organisms. Tata a Systems Psychological systems involve the mind and behavior. They include thoughts, emotions, and mental processes, governed by the principles of Psychology, Psychological systems emerge from biological systems when the brain's physical and chemical processes give rise to thoughts, emotions, and behaviors, wi are influenced by an individual's experiences and environment. 1.2.2 Artificial Systems Artificial systems are created and developed by people so that they may fulfill certain functions or address certain issues. These systems can be as small as a wheel or as large as the United Nations. Each system is designed very deliberately to perform the task, improve the efficiency of the processes, and provide solutions to various issues in different sectors. Artificial systems are a vital part of the contemporary society because they reinforce productivity, solve complex problems, and improve people's well- being. These are systems such as knowledge management systems, engineering achievement systems and indeed social systems which are the framework of ‘success of human civilization. There are different types of artificial systems, some cof which are described below: 1.22.1 e A knowledge system is unique because it is developed to capture, process, facilitate, store, retrieve and manage information. Such systems facilitate in and utilizing the resources of knowledge effectively for the purpose of decision-making, learning and problem-solving; cece (SO Ree 1. Mathematics: Mathematics is a field of knowledge, which is studied to focus problems connected to numbers, their amounts, forms, structures, and patterns, 2. Logic: Logic is a theoretical model consisting of concepts and strategies on identifying and assessing rationale. That is why it is a basis of all logical thinking processes and practice of critical analysis. 3. Databases: A database system can best be described as software for managing data, particularly to enable easy retrieval, management, and updating of data. Some of the examples are relational database management system like MySQL while others are NoSQL database management system like MongoDB. 4. Information Management Systems: These are specific applications developed with the purpose of capturing, archiving, organizing, and disseminating data, 1.2.2.2 Systems Products developed by engineers are complex frameworks or devices that apply engineering concepts to perform certain tasks or solve technical challenges. These are some examples of how engineers of various types develop systems according to their own special knowledge and perspective, given to them through their original visions and approaches. 1. Civil Engineering Systems: Concentration on developments such as constructing houses, roads, bridges and even maintaining these structures, For instance, a structure used to provide.a passage over water, valleys or roadsis termeda bridge. 2. Mechanical Engineering Systems: Engage in planning and creating devices that make utilization of forces from outside to accomplish work. For instance, a robotic arm applied in assembly line for packaging of products in factories. 3. Chemical Engineering Systems: Focuses on converting raw materials into useful products through chemical processes, considering internal molecular interactions. For example, a water treatment plant that purifies water using chemical processes like coagulation and filtration. Electrical Engineering Systems: Involves the study and application of electricity, electronics, and electromagnetism to develop electrical systems. For example a home automation system that controls lighting, heating, and security using a smartphone app. This system uses electric signals and power to operate various home appliances and systems remotely. 5. Software Engineering Systems: is the process of designing, developing, and maintaining software to perform certain tasks eradicating errors. For instance, an online tool assisting a library in tracking books, users as well as stocksin their possession. ae, Artificial Engineering System * The Metro Train System in Lahore is an artificial system created for efficient ‘transportation. The railway system consists of tracks, trains, stations, and control systems that transport people between locations. ~The first electric traffic lights were built in Cleveland, Ohio, in 1914, Modern traffic systems use smart sensors and Al to enhance safety and flow. Al systems, such as Siri and Alexa, can recognize and respond to human speech. These examples demonstrate how computer systems may interact with humans naturally through complicated algorithms and data processing. Virtual Reality (VR): Immersive digital worlds enable exploration and interaction as if you were physically present. This technology has several applications, including gaming, teaching, and astronaut training. 1.2.2.3 Social Social systems refer to structured frameworks established by individuals to effectively handle social interactions, organizational governance, and communal endeavors. The basic goal of these systems is to maintain order, provide services, and facilitate social connections. 1. Academic institutions: are entities that provide educational services to students, Schools, colleges, and universities are examples of educational institutions that provide instruction via the use of administrative, teaching, and support staff. 2. Governments: Organizational institutions that wield authority and control ‘over a community or country, Examples include democratic systems, where representatives are elected and authoritarian regimes, where power is centralized. 3. Organizations: are entities formed to achieve specific goals and are often structured hierarchically with well-defined roles and responsibilities, Examples include corporations like Apple and non-profit organizations such as the Edhi Foundation. Matheniatics a Knowledge tock Bridge an Engineering Punjab University a Social system a ‘System Fig. 1.5 Types of Artificial Systems a, nee 1.3 System and Science Knowledge is our understanding of various systems in the universe around and within us, Sciences a systematic way to validate this understanding. Science can be divided into two main types: natural science and design science. Both natural and design sciences study systems, but they approach them differently. In natural science, scientists study existing natural systems to understand their workings. While in design science, scientists create new systems (artifacts) to solve problems or achieve specific goals. Each type of science addresses different systemsand questions, and therefore follows different scientific methods. 1.3.1 Natural Science Natural science is meant to uncover the ‘objectivity and functionality of natural systems in the natural world. Its nature is descriptive, meaning that the scientists seeks to understand and describe natural phenomena. To achieve this, natural scientists follow the empirical cycle of natural science , as shown in Figure 1.6. Saad 1.32 Design Science + Design Science is focused on designing and creating artifacts (tools, systems, methods) to achieve specific goals. The nature of design science is prescriptive, meaning that it aims to prescribe and create artificial systems. To achieve this design science researchers follow the regulative cycle. Examples + Natural Science: Studying the ecosystem of a forest to understand how different species interact (descriptive). + Design Science: Developing a new software system to manage forest data and improve conservation efforts (prescriptive). oe retin : eo Investigation/Identification Solution Solution Design Implementation Fig. 1.7 Regulative Cycle of Design Science 1,3.3 Com ‘Science Computer science is the study of how computers work, including at what they can do and their limitations. To understand computer science, we use methods of both design science and natural science. 1.3.3.1 Natural Science of ‘Science Natural science of computer science focuses on finding the basic rules that control how computer systems work. This involve the study of various algorithms and their characteristics. + Study of Algorithms: Researchers analyze existing algorithms to understand their efficiency and limitations. For example, studying different sorting algorithms and their characteristics which arrange given data in an ‘order, like QuickSort or MergeSort. To understand their speed and how they perform with different kinds of data. 1,3.3.2 Design Science of Computer Science Design science of computers focuses on creating and improving computer tools and systems to make them work better. + Development of New Software Tools: Researchers create new tools or applications to solve specific problems. For example: Designing a new programming language that makes it easier for developers to write secure computer programs. * Improvement of Computer Systems: Researchers work on enhancing existing systems to perform better. For example, creating a more efficient database management system that can handle larger amounts of data faster and with fewer errors. 1.4Computerasa System A computer is a complex system designed to process data and perform tasks according toa set of instructions. 144 The main objective of a computer is to perform computations, process data, and execute different tasks efficiently. For example, a personal computer's objective is to run software applications such as word processors, web browsers, and cual various computational processes. 42 A computer composed of many essential components that operate in conjunction. These components include: Interface Components: Interface components refer to the fundamental parts of a computer system, including input devices such as the keyboard, and mouse, which allow users to interact with the computer. Computer output devices, such as monitors ahd printers, are used to present or generate results from the computer's operations. essing Components: + The processing components of a computer consist of the CPU, which acts as the Central Processing Unit responsible for computations and executing command. * Random Access Memory (RAM) is a transient storage that stores data and instructions for the CPU, whereas Storage (Hard Drive or SSD) is a permanent storage for data and software needed for future processing. + The operating system is responsible for receiving information from interface components and determining the appropriate actions to take. + Application software refers to programs that are executed by the operating system when required to perform one or more specified tasks. Communication Com E ‘Communication components in a computer refer to the physical elements that provide communication between different components of the computer. * Ina computer, the motherboard serves as the primary circuit board that interconnects all components by using cables and circuits. * A:system bus is a collection of electrically conductive cables that transmit data between the CPU and all other interconnected components. There are three distinct types of buses: data bus, address bus, and control bus. These buses provide the flow of data, the address of data or instructions, and control signals from the CPU to other components concurrently, Fig. 1.8 Computer System and its comps 1.4.3 Interactions among Components The components of a computer interact with each other to perform tasks. For example when you open a file using your mouse or keyboard, several components of your computer interact seamlessly to make this action happen. Here's a step-by-step explanation of the process: 1. User Action or Input. You double-click on a file icon using your mouse or ress a key combination to open a file. For example you double-click on a document named "report.docx" on your desktop, 2. Input Device. The mouse or keyboard sends a signal to the computer indicating that you want to open the file. For example, the mouse sends Sensory input to the computer's operating system through the USB connection. ‘Activity: The Journey of Data Objectives: Students will discover how computer components work together to process and display data. Required Material: Markers, index cards, and a flowchart template are required. Pair based activity: Tasks Begin with an introduction to data processing in }. Computers. Students will work in pairs to create a flowchart illustrating the data | Stream from input to output. Each pair will present their flowcharts and Participate in a class discussion to highlight key points. Output: Improved presentation and debating skills, as well as ‘thorough flowcharts depicting the data path. 1.4.4. Environment ? The computer system environment includes any external devices that interact with the computer. For example: ; + Power Supply: Provides electrical power toallow the computer to work. + Network: Connects the computer to other systems and the Internet. + Peripherals: include printers, scanners, and external discs that expand the computer's capabilities. 1.4.5 Interaction with the Environment Acomputer interacts with its environment to perform its functions. For examples: + User Input: A user types on the keyboard, and the computer processes the input to display text on the screen. + Network Communication: The computer sends and receives data over the internetto browse websites or download files. + Power Supply: The computer relies on a stable power supply to function 1.5 The Architecture of von Neumann Com The Von Neumann architecture is a computer paradigm that delineates a system in which the hardware of the computer has four primary components: the memory, the Central Processing Unit (CPU), input mechanisms, and ‘output mechanisms. This model is called the John von Neumann model, the Neumann model named in honor of the mathematician and physicist who contributed to its development during the 1940s. 15.1 5 Now we will look at brief overview of the key parts that constitute the architecture of the von Neumann computer. ee ® Contains both input data and the instructions (program) required for CPU processing. For instance, consider the RAM of your computer: when a program starts itis loaded into RAM to enable faster execution compared to when itruns from the hard disk. . Central Processing Unit (CPU): Performs addition and subtraction, and executes commands provided by the memory. The system has two main components: the Arithmetic Logic Unit (ALU) and the Control Unit (CU). The Arithmetic Logic Unit (ALU) performs mathematical computations and logical operations. A Control Unit (CU) isa peripheral that governs the activities of the CPU by instructing the ALU and memory to execute tasks according to the program instructions. It ensures the proper and timely execution of duties by all the other components. ‘When doing the calculation 2 + 2 on a calculator application, the Arithmetic Logic Unit (ALU) handles the numerical values while the control Unit (CU) supervises the whole procedure. . Input Devices: Enable users to input data and instructions into the computer system. Illustrative examples include keyboard, mouse, and microphone, Entering text on the keyboard transmits data to the CPU for subsequent Processing. it Devices: Present or communicate the outcomes of the tasks executed by the computer. Consider, for instance, a monitor and printer. Upon completion of data processing, the CPU transmits the outcome to the monitor for visual display. A so bus is a communication mechanism that facilitates the Movement of data between components inside a computational system. It comprises: Data Bus: Transports data. Address Bus: Maintains data destination information. Control Bus: Transports control electrical signals. Fig. 1.9 Von Neumann computer Architecture 1 The Von Neumann architecture encompasses three essential stages fora CPU to Carry out instructions, namely retrieval, interpretation, execution, and storage. To demonstrate this procedure, we will use the example two-digit addition with & basiccalculator application. + Fetching: Description: The central processing unit retrieves an instruction from the computer's memory. This instruction specifies the operation to be executed by the CPU. Hardware Components: Memory, CPU (Program Counter (PO), Instruction Register (IR)). Specification: The Program Counter (PC) stores the memory address of the subsequent instruction. Once the address is stored in memory, the instruction located at that location is retrieved and placed into the Instruction Register (IR). Z eae inorder ‘6 determine the necessary action, the Control Unit (CU) decodes the instruction. Comprising Components: Control Unit (CU). Detail: The control unit (CU) decodes the opcode (operation code) of the instruction and determines the required procedures and data, + Execution: Description: The CPU processes the instruction. When the instruction involves a computation, it is executed by the Arithmetic Logic Unit (ALU). Any task that requires transferring data between several locations is managed by the CU. Involved Components: ALU, CU. Detail: The Arithmetic and Logic Unit (ALU) carries out mathematical and logical calculations, while the Control Unit (CU) handles data transmission activities, * Storing: Description: The outcome of the computation is either returned to memory or sent to an output device. Involved Components: Memory and Output Device. Specification: The outcome is either stored in a designated memory location or sent to an output device, such as a display. 1.5. Following are the key characteristics of the Von Neumann computer architecture 1. Single Memory Store: Both program instructions and data are stored in the same memory space. For example in a computer game, both the game's code and the data (like scores and player positions) are stored in the same RAM, 2. Sequential Execution: Instructions are processed one after another in a Sequence For example, when your computer runs a program, it follows the steps one by one in the order they are written, Stored Program Concept: Programs are stored in memory and can be changed by the computer. For example, when you Updete a software Program, the new instructions replace the old ones in memory. 1.5.4 . Advantages and The advantages and disadvantages of Von Neumann ‘computer architecture are discussed here. ep * Simplified Design: By combining instructions and data into a single memory area, architecture is simplified. * Flexibility: Programs can be easily changed by changing memory content * The Von Neumann bottleneck occurs when a single memory area limits the EU's ability to retrieve instructions and data quickly. 7 Security Risks: Having data and instructions stored in the same area posesa problem where one program can alter another's instructions inamanheraa Feeguty risk, The Von Neumann architecture is a key important aspect of technology, despite its limitation, 1.6 Computing Systems A computer system is a structured set of hardware and software components specifically designed for data processing and the performance of various + and manage data to achieve objectives such as problem solving, process control and communication aid. Hardware, software, and electric porer re he three basic requisites that are needed to run a computing system and cenne described in the following simple terms, * Hardware of a computer system refers to the tangible components of the Ryarem™. These include the Central Processing Unit (CPU), Random Access Memory (RAM), storage devices, and input and output devices *__ Software refers to a collection of instructions that dictate the " fequirements and actions that hardware must do. There exist two primary categories. System software and application software. System Software encompasses the Operating System (OS) and utility applications responsible for managing the computer's resources, such as. Windows, macOS, and Linux distributions. Application software refers to software applications that are specifically developed to carry out certain functions for the user, such as word processors, web browsers, and games. orton sue reene TS + Electricity: Electricity is the power source that enables the hardware components to function. Without electricity, the hardware components cannot function, and the computing system will not operate. 16.1 ‘of Computing Systems Computing systems come in various types, some of these include the followings: J. Computer, 2. Software Systems,3. Computer Networks, and the 4.Internet Computers as a system has been discussed in previous sections, while the remaining two computin: systems are described in this section. 1.6.2 ‘Computer Networlvas A computer network connects multiple computers and devices, enabling the efficient exchange of resources and information. 1.6.2.1 Objectives * ._ Resource Sharing: Allow multiple users to share resources lke files, printers, and internet access within an office or other settings. : * Communication: Enable efficient communication between devices and users. + _ Data Management: Facilitate easy data management and collaboration. 1.6.2.2 Components * Networking Hardware: Routers: Routers are devices that transmit data packets between their networks. ‘Switches: Switches connect devices in a network and facilitate | communication. Network Cables: A physical medium for data transfer. + Network Software: Protocols: Rules and conventions for data: exchange such as TCP/IP. Network Operating Systems: Software that manages network resources, suchas Windows Server. 1.6.2.3 Environment ‘A computer network operates in various environments, such as office buildings, data centers, or across the globe via the Internet. The environment influences network design, security, and iperformance, 6.2.4 of Computer letworks * Local Network (LAN): Connects computers in a specific area, such as a single building or school. For example, an office network that connects everyone. Employee PCs and printers, Wide Area Network (WAN): connects computers across larger geographic regions, such as cities, nations, and even continents. For example, consider the Internet which links computers worldwide. * In summary, a computer network is an important system that enables resource sharing and communication among connected devices, using hardware and software components that work together seamlessly to perform various tasks. 1.6.3 Internet as.a System The Internet is a vast and complex system designed to connect multiple Retworks worldwide, including private, public, academic, business, end jovernment networks. Its.primary objective is to facilitate communication and lata exchange between computers and users. globally. 1.6.3.1 Internet Protocols + TCP/IP (Transmission Control Protocol/Internet Protocol): The core protocols that govern data transmission over the Internet. + _ User Datagram Protocol (UDP): Faster but less reliable. {File Transfer Protocol (FTP): Used for Transforming files between computers. +, Postoffice Protocol (POP): Used for retrieving emails from server/netwrok, 1.6.3.2 Interaction among The components of the Internet interact with each other to pa example when a user requests a web page through a web browser, several components of the Internet work together to display its contents on the user's screen, y 1.6.3.3 Environment {he Internet operates in a diverse and dynamic environment, connecting various types of networks across different locations, including homes, offices, data enters, and mobile networks. This environment influences the design, security, and performance of the Internet. La Summary Asystem is a collection of parts that work together to achieve a common goal. A system is described by its objective, components, communication among components and environmentin which it works, Components are the building blocks of any system. Each component Plays @ specific role and contributes to the overall functionality of the system, The environment of a system includes everything external to the system that interacts with it. It consists of all external factors that affect system's Operation. Systems can be broadly categorized into two types, namely natural and artificial systems. Natural systems are those that exist in nature'and operate independently of human involvement. Artificial systems are designed and constructed by humans. Social systems are organized structures created by humans to manage social relationships, governance, and community activities, Computer science is the study of how computers work, It looks at what Computers can do and what limitations they have. Acomputer is a complex system designed to process data and perform tasks according to a set of instructions. ‘The Von Neumann architecture involves several key steps for a CPU to execute instructions, including fetching, decoding, executing, and storing. System software is the basic software that helps a computer run and ‘manage its hardware and software resources. Application software is the’ software designed to help users perform specific tasks or activities. Multiple Choice Questios Whatisthe primary function ofa system? a) Toworkindependently b) —_Toachieveacommon goal ©) _Tocreatenewsystems d) — Toprovideentertainment Whatis one of the fundamental concepts of any system? a) __Itssize b) Itsobjective «) Itsage d) Itsprice ‘Whatis an example of asimple system? a) Ahumanbody b) Acomputernetwork ©) Athermostat regulating temperature d) The Internet What type of. environment remains unchanged unless the system. provides an output? a) Dynamic b) Static ©) Deterministic @) —_Non-deterministic What are the basic components of a system? a) Users, hardware, software b) Objectives, components, environment, communication ©) _Inputs, outputs, processes d) Sensors, actuators, controllers What concept does the theory of systems aim to understand? a) Hardware design b) _Systeminteractions and development over time ©) Software applications d) Network security What role does the Operating System (OS) play ina computer? a) _Itperforms calculations and executes instructions b) _Ittemporarily stores data and instructions for the CPU ©) _Itreceives input from interface components and decides what to dowith it d) _Itprovides long-term storage of data and software Which of the following describes the Von Neumann architecture's main characteristic? a) Separate memory for data and instructions b) Parallel execution of instructions ° Single memory store for both program instructions and data d) — Multiple CPUs for different tasks Whats a disadvantage of the Von Neumann architecture? a) — Complexdesign due to separate memory spaces b) Difficult to modify programs stored in memory ©) _ Bottleneck due to single memory space for instructions and data d) Lack of flexibility in executing instructions fe ae 10. Which of the following transports data inside a computer among different components? a) Control Unit b) SystemBus ©). Memory 4) Processor Short Questions: 1. Define a system. What are its basic components? Differentiate between natural and artificial systems. 1. Describe the main components of a. computer system, List and describe the ‘types of computing systems, What are the main components of the Von Neumann architecture? Whatis the Von Neumann computer architecture? List its key components. - What are the four main steps in the Von Neumann architecture's instruction cle? Whatis ‘the Von Neumann bottleneck? .._ Whats a key advantage of the Von Neumann architecture? Whatare the three main requirements for a computing system to function? ‘Questions =o PMawny BOP Nomar + Define and describe the concept of a_system. Explain the fundamental components, objectives, environment, and methods of communication within a system, 2. Differentiate between natural and artificial systems. Discuss their characteristics, functions, and purposes with relevant examples, 3. Examine the relationship between systems and different branches of science, including natural science, design science, and computer science, How dé these branches utilize system theory to understand and improve their peshective fields? Provide specific examples to support your analysis, 4 Explore the different types of computing systems such as computers, re systems, computer networks, and the internet, 5. Describe the main characteristics of a computer as a system, including its objectives, components, and interactions among these components, ©. Explain the Von Neumann architecture of acomputer. Include a discussion on the main components, their functions, and the step-by-step process of how the architecture operates, 4 7 Provide a detailed explanation of how a computer interacts with its environment. Include examples of user input, network communication, and power supply, 8. Describe the process of rétrieving and displaying a file using a computer, based on the interactions among different components. Provide s step-by- step explanation of how inputis processed, data is trarisferred, and results are displayed on the screen, —_—_—_—_= ~ “a ~~ I 7" eB Number Systems ‘Understand Number System: are vat mambering systems, including decimal, binary, hexadecimal and octal and theirrespective base values and digits. Why computers primar use the binary number system for data representation. 1 eco representation of dat, including how datas stored and processed within ‘the computer's architecture. + The representation of whole and real numbers in a computer juding binary encoding methods for both. Lett or erthmetic operations, such as addition, subtraction, multiplication, and ‘dision, are performed on binary representations of numbers? «Fei aigt of common text encoding schemes, such as ASCIL and Unicode, and How they represent characters. + How digital data Tepresentations work for various forms of multimedia, such as images, ‘audios, videos, and other multimedia resources. «Different file formats and their variations for specificapplications, : Ofer Te se extensions and their significance In Identifying fle types and applications. «Key terms related to data representation, including ASCII, Unicode, binary, signed and sca eas bits, bytes, hexadecimal number systems, negatives in binary, two's complement, binary arithmetic, overflow, and underfiow. +e eercent of Boolean functions, to represent logic operations and relationships between binary variables. Howto construct Boolean Common Boolean identities and a ot of ualtyinBoolean algebra, where OR becomes AND, and becores © The of digital logic which involves using binary digits (0 and 1) to process andstore information. ar oe Metveen analog and digital signals and understanding their key diferone=s Se Orne gates (AND, OR NOT, NAND, XOR) and ther funcionsin processing Pnany data, «The purpose and construction of truth tables for evaluating the output of logic expressions based on input combinatior : co sr of switches and their ole in digital systems, often used to represent binary input. . «Kamaugh mapsasa visualtool for simplifying Boolean expressions a a ea Boolean expression, circuit diagram of Half-adder and Full-adder |p eeder and Fulledder as digital systems with specific objectives, components and interaction among those components - os ame Introduction _ Understanding number systems is fundamental in computer science and digital electronics. This chapter will delve into various numbering systems, their applications, and how they are used in computers. We will cover the following topics: |. Different numbering systems: decimal, binary, hexadecimal, and octal. . Binary numbersystem in computers. 3 . Machine-level data representation. Representation of whole and real numbers. .. Binaryarithmetic operations, .. Common text encoding schemes: ASCII and Unicode. File formats and extensions. }. Key terms in data representation, 1. Binary data manipulation and conversion. 10. Encoding schemes. 11. Differences between file formats. 12. Storing images, audio, and video in computers. 2.1 Numbering Systems Numbering systems are essential in computing because they form the basis for fepresenting, storing, and processing data. Different numbering systems help computers perform tasks like calculations, data storage, and data transfer. These systems allow computers to represent various kinds of information, such as text, colors, and memory locations. Here is a description of a few numbering systems: 2.1.1 Decimal The decimal number system is a base-10 number system that consists of digit from 0 to 9 and we use it in everyday life. That's why each digit of the number represents a power of 10. In the decimal system the place values starting from the rightmost digits are 10°, 10’, 10°, and so on. For example, the decimal number 523 means: 5x10" +2x10' + 3x10 =500+20+3=523 2.1.2 Binary System In binary, the place values are arranged from the right to left, starting with 2°, and ending at 2",where each position represents a power of 2. For example, the binary number 1011 can be converted to decimal as follows: 1 x2'40x2?+ 1x2! + 1x2°=84+042+1= 110 Computers work in binary system especially because this method fits well with electronics. Digital circuits have two states: They can be either on or off. These states are easily represented by the binary digits: 1 represent ON, and 0 represnets OFF. When typing on the keyboard, the computer translates every PEnNonAwNS number, text, images, and sound are all, at their lowestlevel, reduced to binary. We shall discuss this is details later in this ‘chapter. When you type a letter on your keyboard, the computer converts it into a binary code. Similarly, all types of data, including numbers, text, images, and sounds are ultimately broken down into binary code. We will explore it further later in this chapter. 2.1.2.1 Conversion from Decimal to Binary The following algorithm translate a decimal number to binary. 3. To convert decimal number to binary form, divide the decimal number by 2. 2. Record the remainder. 3. Divide the number by 2 until the quotient which is left after division is 0. 4. Meaning itis represented by the remaindersand it's read from the bottom to the top ofthe binary number. Example: Convert 83 to binary 83 /2 = 41 remainder 1 4i/ 0 remainder 1 20 /2 = 10 remainder 0 10/2 = 5 remainder 0 5/. remainder 1 remainder 0 remainder 1 The above steps are graphically shown in Figure 2.1. If the remainders are read from bottom to top then it gives the required result in binary, which is 1010011, Figure 2.1 Decimal to Binary conversion NOT FoR LE PeSRe 2.1.3 Octal System Octal is a positional numeral system with base eight, whic! implies that a digit to be used ranges from 0 to 7. The last digit is a single digit power of 8 while the other digits are the coefficients. In the decimal system, the place values starting from the 8", 8', 8 and so on. For example, the octal number 157 means, 1x8+5x 81+ 7x8°=64+40+7= 1110. : Each octal digit represents three binary digits (bits) because the octal system is base-8, and the binary system is base-2. This relationship arises from the fact that Bis a power of 2 (8 = 2’), So, each octal digit can be precisely represented by three binary digits (bits) This means that any value from 0 to 7 in octal can be converted into a 3-bit binary number. This relationship makes conversion between binary and octal straight forward. Table 2.1 shows the correspondence between octal and binary digits: Example: Consider the 9-bit binary number 110101011. This number can be divided into groups of three Bits rom rightto left: Sagal ~ Each group of three bits corresponds to a single octal digit: 110=6 101=5 O11 =3 Octal | Binary] 0 000 1 001 2 010 3 O11 4 100 5 101 6 110 Z 11 Table 2.1: Correspondence between Octal and Binary Digits So, the binary number 110101011 is equalto 653 in octal. Note that the octal number system isn't actually used in modern computers to do their work. Therefore, we can say that the binary number 110101011 is equal to 653 in octal. Whenever you have a binary number that cannot be divided into groups of a three, you'll have to add zero up to the left end of it to make it appropriate. 2.1.3.1 Conversion from Decimal to Octal The algorithm below translates a decimal number into an octal. 1. To convert the decimal number to an equivalent octal number, divide the number by 8, 8| 33 2. Write down the remainder. 3. Afterthat divide the obtained quotient by 8, 8/10" —|3 4. Continue the divisions until one of the numbers gla — 2 results in0. ; \ 5. Octal isa base eight number and the octal number «= [9 —= 4 from is the remainder read from the bottom up to the top. Figure 2.2: Conversion Example: Convert 83 to octal Decimal to Octal. + 83/8= 10remainder3 + 10/8=1 remainder 2 + 1/8=Oremainder1 The above steps are graphically shown in Figure 2.2. Going up from bottom, the remainder reading will give the desired result, that is 123 in the octal system. The octal system was used in early computing systems li PDP-8. It was used because it is easier to convert between ‘octal and binary than between decim: anébinay. ‘When converting between number systems, seers and sums to ensure accuracy. Practice with different nu more comfortable with the conversion process. 2.1.4 Hexadecimal System The hexadecimal is a base 16 number system with digit number from 0 to 9 and alphabets from A to F; each digit represents 16 to the power of the position of the digit. The letter A to F stand for the numeric value of 10 to 15, The digits in hexadecimal move from right to left in place value that are 16%, 16, 16... anothers. For example, the hexadecimal number 1A3 can be represented in decimal as: 1x 16*+ Ax 16! +3x 16° = 1x256 +10x16 + 3x1 = 256 +160+3=419,, The hexadecimal number system is not directly used by computers either. However, it provides an even more compact representation than octal. This makes iteasier forus toread and write large binary numbers. This is because the hexadecimal system is base-16 and the binary system is base- 2, therefore every single hexadecimal digit equals four binary bits. This relationship stems from the fact that 16 is a power of 2 (16= 2‘), This means that any hexadecimal number between 0 and 15 then it can be converted into 4-bit binary number. Table 2. 2 illustrates conversion of hexadecimal to binary digits. Each group of four bits corresponds toa single hexadecimal digit. Example: Therefore, the binary number 1101011010110010 equals to the hexadecimal number D6B2. In case a binary number cannot be grouped as four bits add zero(s) to the left of the number to make it fit. 1101 0110 1011 0010

You might also like