Module I
Module I
Dimple Bohra
Contents
● The Turing Machine Architecture
● Von Neumann architecture
● Number system
● Introduction to operating system components
● System and application software
● Basic constructs of Algorithm and flowchart: Sequence, Decision
(Selection) and Repetition
● Compilation process: Syntax and semantic errors, ASCII.
The Turing Machine
● Turing Machine was invented by Alan Turing in 1936 and it is used to
accept Recursive Enumerable Languages.
● A Turing machine is an abstract machine that obeys a set of rules laid
down for it. The more practical form of the same is called as a
mathematical model. The Turing model forms the basis of software
development. It shows the behavior expected from the system to be
designed.
● Using a Turing model, one can design and develop the step expected in the
procedural oriented programming. h
The Turing Machine Architecture
● The number system that we use in our • For example, the decimal number 1234 consists of
day-to-day life is the decimal number system. the digit 4 in the units position, 3 in the tens
position, 2 in the hundreds position, and 1 in the
● Decimal number system has base 10 as it uses 10
thousands position. Its value can be written as
digits from 0 to 9.
● Each position represents a specific power of the
base (10).
Binary Number System
• Characteristics of the binary number system are as follows −
Uses two digits, 0 and 1
Also called as base 2 number system
• Each position in a binary number represents a 0 power, of the base
(2).
• Example 20
• Last position in a binary number represents a x power of the base (2).
Example 2x where x represents the last position - 1.
Binary to Decimal Conversion
Octal Number System
• Characteristics of the octal number system are as follows −
Uses eight digits, 0,1,2,3,4,5,6,7
Also called as base 8 number system
• Each position in an octal number represents a 0 power of the base (8).
Example 80
• Last position in an octal number represents a x power of the base (8).
Example 8x where x represents the last position - 1
Octal to Decimal Conversion
Hexadecimal Number System
● Characteristics of hexadecimal number system are as follows −
Uses 10 digits and 6 letters, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F
Letters represent the numbers starting from 10.
A = 10. B = 11, C = 12, D = 13, E = 14, F = 15
Also called as base 16 number system
● Each position in a hexadecimal number represents a 0 power of the base (16).
Example, 160
● Last position in a hexadecimal number represents a x power of the base (16).
Example 16x where x represents the last position - 1
Hexadecimal to Decimal Conversion
Computer Systems
● Computer is system made of two major components: Hardware and
Software.Computer hardware is physical equipment.
● The software is collections of programs that allow hardware to do its job.
Computer Software
● Computer software is divided into two broad categories: system software and
application software.
● System software manages the computer resources. It provides the interface
between the hardware and the users but does nothing to directly serve the users’
needs. Application software, on the other hand, is directly responsible for helping
users solve their problems.
System Software
● System software consists of programs that manage the hardware resources
of a computer and perform required information processing tasks.
● These programs are divided into three classes: the operating system,
system support, and system development.
● The operating system provides services such as a user interface, file and
database access, and interfaces to communication systems such as Internet
protocols. The primary purpose of this software is to keep the system
operating in an efficient manner while allowing the users access to the
system.
System Software
● System support software provides system utilities and other operating
services. Examples of system utilities are sort programs and disk format
programs. Operating services consist of programs that provide
performance statistics for the operational staff and security monitors to
protect the system and data.
● System development software, includes the language translators that
convert programs into machine language for execution, debugging tools
to ensure that the programs are error free.
Application Software
● Application software is broken into two classes: general-purpose software and
application-specific software.
● General-purpose software is purchased from a software developer and can be
used for more than one application. Examples of general-purpose software
include word processors, database management systems, and computer-aided
design systems.
● Application-specific software can be used only for its intended purpose. A
general ledger system used by accountants and a material requirements
planning system used by a manufacturing organization are examples of
application-specific software. They can he used only for the task for which
they were designed; they cannot he used for other generalized tasks.
Relationship between Application and System Software
● Each circle represents an interface point.
● The inner core is the hardware.
● The user is represented by the outer layer.
● To work with the system, the typical user
uses some form of application software.
● The application software in turn interacts
with the operating system, which is a part
of the system software layer.
● The system software provides the direct
interaction with the hardware.
● Opening at the bottom represents path
followed by user who directly interacts
with OS when needed
Operating System
● An Operating System (OS) is an interface between a computer user and
computer hardware.
● An operating system is a software which performs all the basic tasks like
file management, memory management, process management, handling
input and output, and controlling peripheral devices such as disk drives
and printers.
Operating System Architecture
Operating System Components
The main components of an operating system (OS) are the kernel, shell, and
hardware:
● Kernel: The main part of the OS that controls most of its tasks, such as
memory and process management, and how installed software interacts
with the hardware.
● Shell: Allows users to interact with the OS through programming
languages, lines of commands, or visual ways to give orders.
● Hardware: The physical parts that make up a computer.
Operating System Components
Compilation Process
● The compilation is a process of
converting the source code into
object code. It is done with the help
of the compiler. The compiler
checks the source code for the
syntactical or structural errors, and
if the source code is error-free, then
it generates the object code.
Preprocessor
● It refers to the rules and regulations for writing any statement in a programming language
like C
● It does not have to do anything with the meaning of the statement.
● A statement is syntactically valid if it follows all the rules.
● It is related to the grammar and structure of the language.
● Syntax errors are handled at compile time.
● Example: missing semicolon/parenthesis, undefined variables etc.
Semantics: