This section deals with how the computer software is structured and works. The computer software is the set of all programs (or data in general) contained in a computer that characterize the computer behavior with the external world represented by the user (people, machines, other computers). A fundamental purpose of computer science is precisely that of studying the interaction between the user and the computer in such a way as to make this interaction as simple and efficient as possible for the user. The software consists of three components: the operating system, application programs and data created with the application programs. The operating system is the program (or set of programs) which deals with the interaction between the user and the computer and will be discussed here. The application programs (will be discussed later) are tools made available by user in order to solve his various specific problems (that is, to work) and will be discussed later. Although physically the software is composed of the three components mentioned above, from a functional perspective (i. e., the perspective given by the functionality that the software plays in the binomial user-computer) the third component (i. e., the data) is implied and merged with the second (i. e., application programs). This is because the functionality of the data created by the application programs is nothing more than that of representing the question of the user, given as input to the various application programs, and the relative answers obtained as output. In a sense, data is information carried by the wires of an electric circuit and the application programs are the electric circuits (consisting of wires and transistors) that manipulate the information.

1. The operating system

One fundamental purpose of Computer Science is to study the user computer interaction in order to make the computer use easy and efficient for us; that is, user friendly. The operating system is the set of programs that aims to this user friendliness or usability. The computer (machine aimed to help us in solving problems) consists of three resources: the hardware (consisting of the CPU, memories, peripherals), the operating system and the application programs (programs that are used to perform specific jobs. Examples of application programs are: text processors such as MS Word, spreadsheets as MS Excel, video games, scientific programs, compilers, programs developed by the user to solve some of its particular specific problems, etc.). On the other hand, the user is an entity that tries to solve various problems (i. e., carrying out various tasks) thanks to several application programs created by him/her self or by others.

1.1 What is an operating system and its purpose

In the user-computer binomial, the operating system is a program (or set of programs) which acts as an intermediary between the user (with his/her application programs) and the hardware in way to govern (or at least help the user to govern) the three resources mentioned above that make up a computer system. The purpose of an operating system is to provide an environment in which the user can execute his programs (that is, work) in a simple, convenient (that is, user friendly) and efficient (that is, fast) way. All this, controlling and coordinating the use of hardware among the various user application programs (or users). The function of an operating system and others components of the user-computer binomial is shown in Figure 1 below. An operating system should be user friendly, and so, for example:

  1. must clearly show to the user the data contained in the mass memory;
  2. must take care of the marginal things that do not interest the user, such as: I/O with the various peripheral devices (via the device drivers). It should not be the user to instruct the computer on how to write input and/or output data. Also, the operating system must load programs from mass storage to volatile memory, etc.;
  3. must allow simple data passing between one program to another;
  4. must ensure that switching between running programs is simple;
  5. must monitor program execution and if something goes wrong then it must pop up the issue;
  6. must prevent the misuse of any component of the system;
  7. and so on.

An operating system should also be efficient, and so, for example:

  1. must efficiently and fairly allocate the various hardware resources (CPU, memory, printers, etc.) among the various application programs. It must ensure that all the resources are always busy doing useful work (i. e., are not idle) and that all programs are evenly served by the resources;
  2. must look after its own survival;
  3. and so on.


Figure 1: functionality of the various components in the binomial user-computer.

1.2 How an operating system works

Now that we have seen what they are and what they are for, let us see how operating systems work. They are interrupt based systems . In other words, they are programs which are always in execution (and therefore always resident in the RAM) and listen. When interrupted by the user or by the user programs, they do what they were interrupted for by calling an interrupt handler which satisfies the reason fo the interrupt. In this way, the operating systems create on interactive environment.

1.3 The organization of data in an operating system: volumes, directories (or folders), applications and documents

In a computer (machine to manipulate data using programs), the data is contained in files and stored in a mass memory. By definition, a (computer) file is a sequence of 0 and 1 to which it has been given a name. There are two types of files: files containing application programs that are called applications, and files containing data created by the applications (or more properly, by application programs) that are called documents. Logically, the arrangement of the files is organized as follow:

  • The files are contained in folders (or directories) or volumes.
  • The folders are stored in other folders or volumes.
  • The volumes are not included in any logical structure and they usually represent a physical memory unit (hard disk, floppy disk, CD, DVD, etc.). All this can be represented by a tree structure such as the one represented in Figure 2. In the figure, "Hard Disk" is a volume and is therefore the root of the tree. "Cartella Sistema Operativo", "Applicazioni", "Temporanea", "Luca", "MS Word" are folders. "Temporanea" is an empty folder (hence, it is a leave of the tree). "Firefox.exe" is an application (hence, it is a leave of the tree). While "Readme.txt", "InformaticaI.doc" are documents (hence, it are leaves of the tree).


Figure 2: Example of the logic file system structure of a volume.

1.4 The main features of an operating system

In this section we want to clarify some fundamental features of an operating system. An operating system is multiprogramming if it is able to have multiple programs in the process of being in execution at any given time. In a multiprogramming system, the CPU jumps (= changes the execution) from one job (= an instance of a computer program that is being executed) to another at convenience (for example, in ancient computers, the system automatically jumped from one job to another if the first had to wait for the printer to finish his work to move on. Today, the CPU can jump from one job to another with a mouse click decided by the user. This is allowed by the fact that the systems are interactive). A multiprogramming system is a particular feature of being multi-tasking, where the machine can execute multiple tasks, jobs or processes (= program in execution) concurrently at any given time.

An operating system is time-sharing if it is multi-tasking and the CPU is able to jump quickly from one process to another, and then another again so that, eventually, all running programs (composed by many processes) are effectively carried out and completed. In a time-sharing system the jumping from one program to another (changing the program executed by the CPU) it is done so quickly as to create the illusion that the system is carrying out various tasks simultaneously, in parallel. We note that time sharing is the key feature that allows the interactivity of today's operating systems.

An operating system is multi-user if it can make the computer look like only one personal computers: one for each user (more than one). Users communicate with the computer via many terminals. A mainframe is a typical computer designed to have a multi-user operating system.

1.5 The main operating systems

In this section we will go through the main operating systems existing today.

Unix. The oldest. Developed in the US academic world to be used by mainframes and super computers. It is a fully multiprogramming, time-sharing and multi-user system. It does not include a Graphical User Interface or GUI (a GUI is a set of programs that defines a graphical environment in which the user can work with the machine).

Linux. It is essentially the Unix system for the PC. Developed over the past 30 years, it has became very popular essentially because the of computational power between the pc and mainframes has almost vanished.

MS-DOS. The first https://en.wikipedia.org/wiki/Personal_computer PC operating system. It is similar to the Unix system without multiprogramming, time-sharing, multi-user.

Macintosh OS 9.x. The first PC operating system with a built-in GUI. It is multiprogramming and partially time-sharing. The Macintosh invented the windows, the use of the mouse and the concept of GUI.

Macintosh OS 10.x. Today the Macintosh operating system. It is a Unix/Linux with a GUI called Aqua.

Windows. Born as the Microsoft GUI for MS-DOS. It developed as an operating system with the same characteristics of a Unix/GUI system (from Windows NT and so on). Find out the last updated version Windwos 10 with all the new features included.

X11. It is a sort of GUI for Unix.

Solaris. SUN Microsystems GUI for Unix.

KDE. GUI for Linux.

iOS. It is an operating system developed by Apple for iPhone, iPod touch and iPad. Last updated version: iOS x available for other devices as Apple Watch.

Android. It is a mobile operating system (OS) currently developed by Google, based on the Linux kernel and designed primarily for touchscreen mobile devices such as smartphones and tablets. Find out the last version called Android 6.0 Marshmallow.