Docsity
Docsity

Prepara i tuoi esami
Prepara i tuoi esami

Studia grazie alle numerose risorse presenti su Docsity


Ottieni i punti per scaricare
Ottieni i punti per scaricare

Guadagna punti aiutando altri studenti oppure acquistali con un piano Premium


Guide e consigli
Guide e consigli


Appunti Digital Content Processing, Appunti di Sistemi Digitali

Based on prof. Avola, Marini and Cascio's lessons

Tipologia: Appunti

2020/2021

Caricato il 20/05/2021

arianna_renzi
arianna_renzi 🇮🇹

4.5

(48)

10 documenti

1 / 54

Toggle sidebar

Questa pagina non è visibile nell’anteprima

Non perderti parti importanti!

bg1
We use computers to manage, create and modify content through BINARY
CODE. We can define BC as a language, a dictionary or a vocabulary using a
two-symbol system. The two-symbol system used is "0" and "1" from the binary
number system. In decimal form we have space for ten possibilities (from 0 to
9), in binary we have only ONE space.
BC allows us to identify a specific object inside the computer through
sequences. The representation of the information with binary code requires at
least 8 bits for representing anything. The first bits represent the operation
code or opcode and the second set of four bits specified an address or
register.
I can store or retrieve later information taking sequences of bits and putting
them away. A file (but also data, folder, etc.) can be only a combination of bits
because the computer can’t speak to us with our language. If I want to define a
sequence of BIT (ex. 10010), it is important to consider the CLOCK which is a
frequency (or voltage)* one over a certain time (and we use it to define the
speed of our computer). Time is not a variable (independent).
*Voltage is an element by which we can define if the electricity is high or low in
a certain time interval. The speed of the computer doesn't depend only by how
many bits it can compute. We also have to consider the window of time
(seconds).
In computers, most central processing units (CPU) are labeled in terms of their
clock rate expressed in megahertz (106 Hz) or gigahertz (109 Hz)*
*
Hertz i
s the frequency - how many time per second it can do something
This specification refers to the frequency of the CPU's master clock signal. This
signal is a square wave, which is an electrical voltage that switches between
low and high logic values at regular intervals.
As the hertz has become the primary unit of measurement accepted by the
general populace to determine the performance of a CPU, many experts have
criticized this approach, which they claim is an easily manipulable benchmark.
Even though today's processors are tremendously fast, their performance can
be affected by a number of factors:
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36

Anteprima parziale del testo

Scarica Appunti Digital Content Processing e più Appunti in PDF di Sistemi Digitali solo su Docsity!

We use computers to manage, create and modify content through BINARY CODE. We can define BC as a language, a dictionary or a vocabulary using a two-symbol system. The two-symbol system used is "0" and "1" from the binary number system. In decimal form we have space for ten possibilities (from 0 to 9), in binary we have only ONE space.

BC allows us to identify a specific object inside the computer through sequences. The representation of the information with binary code requires at least 8 bits for representing anything. The first bits represent the operation code or opcode and the second set of four bits specified an address or register.

I can store or retrieve later information taking sequences of bits and putting them away. A file (but also data, folder, etc.) can be only a combination of bits because the computer can’t speak to us with our language. If I want to define a sequence of BIT (ex. 10010), it is important to consider the CLOCK which is a frequency (or voltage)* one over a certain time (and we use it to define the speed of our computer). Time is not a variable (independent).

*Voltage is an element by which we can define if the electricity is high or low in a certain time interval. The speed of the computer doesn't depend only by how many bits it can compute. We also have to consider the window of time (seconds).

In computers, most central processing units (CPU) are labeled in terms of their clock rate expressed in megahertz (10^6 Hz) or gigahertz (10^9 Hz)*

* Hertz i s the frequency - how many time per second it can do something

This specification refers to the frequency of the CPU's master clock signal. This signal is a square wave, which is an electrical voltage that switches between low and high logic values at regular intervals.

As the hertz has become the primary unit of measurement accepted by the general populace to determine the performance of a CPU , many experts have criticized this approach, which they claim is an easily manipulable benchmark. Even though today's processors are tremendously fast, their performance can be affected by a number of factors:

  1. Clock speed: Clock speed is the number of pulses the central processing unit's (CPU) clock generates per second and it is measured in hertz
  2. Cache size: The bigger its cache, the less time a processor has to wait for instructions to be fetched.
  3. Number of cores: The more cores a CPU has, the greater the number of instructions it can process in a given space of time. Many modern CPUs are dual (two) or quad (four) core processors.
  1. Arithmetic operations preserve sign bit , whereas Logical shift can not preserve sign bit.
  2. Arithmetic shifts perform summing and subtraction operation , whereas shifts operations perform only multiplication and division operation.

SHIFT = is a movement of bits in a specific direction like using a sliding window. The most significant bit is on the left, and least significant is on the right. When you move on shift position using a left shift you are doing a MULTIPLICATION, if you are using a right shift you are doing a DIVISION.

A logical operation is a special symbol or word that connects two or more phrases of information. It is most often used to test whether a certain relationship between the phrases is true or false. In computing, logical operations are necessary because they model the way that information flows through electrical circuits, such as those inside a CPU. These types of operations are called boolean operations.

**1. Or / and / not operations

  1. NAND :** The NAND logic operation (which stands for "NOT AND") returns true if its inputs are false, and false if either of its inputs is true.

Arithmetic operations Summing + Subtraction

Shift operations or truncation Multiplication + Divisions

Logical Operations Or/and/not/nand/nor

  1. CU: The Control unit - is one of the parts designed for calculating and controlling and it supervises each activity. Is able to keep the information of the operations that are done and the location of the next operations. It provides control signals in accordance with some timings which in turn controls the execution process.

The Sub-models of the CU are:

  • PC: the Program Counter: Points to the next instructions that is currently being executed
  • IR: the Instruction Register : Hold the instructions that is currently being executed

The main function of the Control Unit.

  • it fetches , decodes and executes instructions
  • it issues control signals that control hardware
  • it moves data around the system
  1. CACHE: Cache memory is a supplementary memory system that temporarily stores frequently used instructions and data for quicker processing by the central processor of a computer. The cache augments, and is an extension of, a computer’s main memory.
  2. REGISTERS: are small amounts of high-speed memory contained within the CPU. They are used by the processor to store small amounts of data that are needed during processing.
  • Different processors have different numbers of registers for different purposes, but most have some, or all, of the following: - Program counter (PC); holds the memory address of the next instruction to be fetched from main memory. - Memory address register (MAR): holds the address of the current instruction that is to be fetched from memory, or the address in memory to which data is to be transferred. - Memory data register (MDR): holds the contents found at the address held in the MAR, or data which is to be transferred to main memory. It is also referred to as the memory data register (MDR).

- Current instruction register (CIR): holds the instruction that is currently being decoded and executed. - Accumulator (ACC): holds the data being processed and the results of processing

  1. BUS STRUCTURE: The CPU and memory are normally connected by three groups of connections, each called a BUS. It’s a group of wires which carries information from CPU to peripherals or vice-versa. Here: - Data Bus: Group of wires which carries data information bit from processor to peripherals and vice-versa - Address Bus: Group of wires which carries address information bits from processor to peripherals - Control Bus: Group of wires which carres control signals from processor to peripherals and vice-versa
  2. CLOCK: The CPU contains a clock which is used to coordinate all of the computer's components. The clock sends out a regular electrical pulse which synchronises (keeps in time) all the components. The frequency of the pulses is known as the clock speed. Clock speed is measured in hertz. The higher the frequency, the more instructions can be performed in any given moment of time

The Memory unit - Primary memory The memory is something that is temporary, and not permanent. Also called RAM (Random Access Memory) - when you keep programs opened without a crash of the computer - bigger is the RAM, more the programs you can keep open. A greed that contains information like a cell (small dimension string of bits that can be filled with whatever).

THE VON NEUMANN MODEL INSTRUCTION CYCLE DETAILS - THE FETCH-DECODE-EXECUTE CYCLE

Each computer's CPU can have different cycles, but will be similar to the following cycle:

  1. Fetch Stage : The next instruction is fetched from the memory address that is currently stored in the program counter and stored

- Output : Converts the binary format data to a format that a common man can understand (Screen, speakers, Printer, LEDs) ↳ Some devices also provide both input and output, such as: disk, network, and so on.

DRIVER In computing, a device driver is a computer program that operates or controls a particular type of device that is attached to a computer. A driver provides a software interface to hardware devices , enabling operating systems and other computer programs to access hardware functions without needing to know precise details about the hardware being used

4TH LAYER OF A DEVICE: THE FIRMWARE

Firmware is a specific class of computer software that provides the low-level control for a device's specific hardware, and in short words is a combination of persistent memory, program code, and the data stored in it. Typical examples of devices containing Firmware are embedded systems such as traffic lights, consumer appliances, digital watches, computers, computer perip herals, mobile phones, and digital cameras.

Firmware is held in non-volatile memory devices such as ROM, EPROM, or EEPROM (including NOR flash memory).

  • The main purpose of the firmware is to “initialize/start ” the component itself and to allow it the interaction with the other components of the device. In other words, the firmware provides, to the component, a set of communication interfaces and protocols by which to share a common language (i.e., syntax and semantic).

The BIOS is the basic and essential portion of the Motherboard Firmware and is in charge of checking and booting the hardware attached to the device

THE BIOS (Basic Input/Output System and also known as the System BIOS, ROM

BIOS or PC BIOS) is firmware used to perform hardware initialization during the booting process (power-on startup), and to provide runtime services for operating systems and programs. It is like “An interpreter to recognize which device is running”. It is loading information from a permanent memory (non volatile), it is not deleted. ↳ The permanent memory is called FLASH or EEPROM, used for storing information about the BIOS that is running each time we are turning on the computer.

Some of the MAJOR FUNCTIONS OF BIOS are:

  1. POST – The first and foremost task of BIOS is to ensure the proper functioning of the computer hardwar e, and there is no hardware problem. Power-On Self-Check (POST) does this task efficiently. If the POST test fails, the computer produces different forms of beeps to show the error type. If the POST test is passed then it continues to boot.
  2. BOOT– Upon successfully running POST, the BIOS locates and recognizes the operating system. The BIOS then transfers access to the Operating System when it detects one. This is called Booting.
  3. BIOS DRIVERS – BIOS drivers are a set of programs that are stored in the erasable memory chips which are non-volatile. The BIOS Drivers supplies basic computer hardware information.
  4. BIOS SETUP – Configuration software that allows you to configure hardware settings including the d evice settings, computer passwords, time and date.

UEFI (The Unified Extensible Firmware Interface) is an improvement of the BIOS with a better graphical interface, easier to manage the configuration and has a lot of more information making it more powerful. For example, the BIOS is checking each component one by one, in sequence, ( CPU + RAM + GRAPHIC INTERFACE + HARD DRIVES…). With UEFI all the devices that are perfierals are checking all at once, in one shot. It not only manages the Master Boot Record as Bios did but also the GPT- guid partition table , that is more powerful (higher security for the data and biggest dimension for files) - vastly used in gaming computers.

operating system does not interact with the computer directly. The user loads both programs and data, only when the device ends the processing a result (i.e. output) is provided

  • The INTERACTIVE TIME SHARING : in this kind of Operating Systems, the device runs several programs together and shares the hardware resources (i.e. CPU me, memory…) among them. The user can interact with the programs during their execution to provide input and to receive output during all the processing. The time interval required to process and respond to inputs is very small. This time interval is called response time.
  • The REAL-TIME Operating Systems: in this kind of Operating Systems, the execution of a program must be performed in real-me (or a 0xed me interval) without delays, latencies or deterioration of performance. Real-time systems are used when there are time requirements that are very strict like missile systems, air traffic control systems, robots etc.
  • The EMBEDDED Operating Systems: the Operating Systems and the devices are integrated inside a dedicated hardware (i.e. OS of a car or of an airplane). This type of operating system is typically designed to be resource-efficient and reliable. Resource efficiency comes at the cost of losing some functionality or granularity that larger computer operating systems provide, including functions which may not be used by the specialized applications they run
  • The HYPERVISOR Operating System: A hypervisor (or virtual machine monitor , VMM , virtualizer ) is computer software, firmware or hardware that creates and runs virtual machines. A computer on which a hypervisor runs one or more virtual machines is called a host machine , and each virtual machine is called a guest machine. The hypervisor presents the guest operating systems with a virtual operating platform and manages the execution of the guest operating systems.

A second classification (based n the processing features)

  • The mono-task Operating Systems : A single-tasking system can only run one program at a time. Another program (i.e. another task) can be executed only when the previous one is completed
  • The multi-task Operating Systems: the parallel execution of different programs is allowed. These Operating Systems share the hardware resources (e.g. CPU me, memory and so on) among the different programs
  • The Multi-Threading Operating Systems : Multithreading is the ability of an operating system process to manage its use by more than one user at a time and to even manage multiple requests by the same user without having to have multiple copies of the programming running in the computer.
  • Mono-user Operating Systems: the Operating Systems can interact and execute programs of a single user at a time and have no facilities to distinguish users, but may allow multiple programs to run in tandem
  • Multi-user Operating Systems: Operating Systems can interact and execute programs of more users at the same time

Kernel is the central component of an operating system that manages operations of computer and hardware. It basically manages operations of memory and CPU time. It is the core component of an operating system. Kernel acts as a bridge between applications and data processing performed at hardware level using inter-process communication and system calls.

Objectives of Kernel :

  • To establish communication between user level application and hardware.
  • To decide the state of incoming processes.
  • To control disk management.
  • To control memory management.
  • To control task management.

TYPES OF KERNEL :

  1. Monolithic Kernel Operating Systems: A monolithic kernel is an operating system architecture where the entire operating system is working in kernel space. The monolithic model differs from other operating system architectures in that it alone defines a high-level virtual

A solid-state drive ( SSD ) is a solid-state storage device that uses integrated circuit assemblies to store data persistently, typically using flash memory, and functioning as secondary storage in the hierarchy of computer storage. It is also sometimes called a solid-state device or a solid-state disk , because it has no moving parts, physical spinning disks and movable read–write heads used in hard disk drives (HDDs) and floppy disks.

THE 2ND LAYER OF THE DEVICE - APPLICATIONS

An application , or application program, is a software program that runs on your computer. Web browsers, email programs, word processors, games, and utilities are all applications. The word "application" is used because each program has a specific application for the user.

A PROCESS is a running instance of an application (or program):

  • Inside a Computer (or Device) with a multi-task Operating System (OS), a large number of processes can be executed together (of different applications or of the same application). A process can perform calls to the system functions to obtain services from the OS related to the management of the process itself, in particular: ● Execution of other processes (exec);

The SSDs last longer: common hard-disks are composed by moving parts (e.g. arms, heads) which are vulnerable and can be easily damaged. The SSDs do not contain mechanical parts , thus making them resistant to shocks

The SSD are faster: have faster access to the data and are up to 100 times faster than the common hard-disks.

The SSDs are more reliable: the percentage of SDDs memory failures is extremely lower than common hard-disks

The SSDs need lesse power: in any kind of device

The SSDs are more lighter

The SSDs are extremely silent

● Replication of a running process (fork); ● Sending signals between two (or more) processes (wait/signal); ● Termination of a process (kill/terminate).

Each process, during its “life cycle”, can be in one of the following states:

  1. Init : initial load state of the process in memory. That is, the program is set in an “execution state” inside the Computer, the linked main process is created, and the required memory (RAM) is allocated.
  2. Ready : the process is set in a “ready to run state”.
  3. Running : the process is running by the CPU.
  4. Waiting : the process is suspended pending an event (e.g., feedback from a device).
  5. Swapped : the process, awaiting some event, has been placed inside the Virtual Memory (i.e., Hard Drive) pending recovery, in primary memory, to be executed.
  6. Zombie : the process has completed its execution, but it is still present inside the memory (i.e., it has a PID), waiting for its father to release it permanently.
  7. Terminated : the process is terminated and the OS deallocate the previously assigned memory (RAM)

Operating Systems functionality The components of an operating system all exist in order to make the different parts of a computer work together. All user software needs to go through the operating system in order to use any of the hardware, whether it be as simple as a mouse or keyboard or as complex as an Internet component.

  • Memory management : a functionality of an OS which handles or manages primary memory and moves processes back and forth between main memory and disk during execution. Memory management keeps track of each and every memory location, regardless of either it is allocated to some process or it is free.
  • Applications Management : The OS provides a set of features to allow applications to build user interaction tools. Application management (AM) is the process of managing the operation, maintenance, versioning and upgrading of an application throughout its lifecycle.
  1. User control and freedom. Users often perform actions by mistake. They need a clearly marked "emergency exit" to leave the unwanted action without having to go through an extended process
  2. Consistency and standards. Users should not have to wonder whether different words, situations, or actions mean the same thing. Follow platform and industry conventions.
  3. Error prevention. Good error messages are important, but the best designs carefully prevent problems from occurring in the first place.
  4. Recognition rather than recall. Minimize the user's memory load by making elements, actions, and options visible. The user should not have to remember information from one part of the interface to another.
  5. Flexibility and efficiency of use. Shortcuts — hidden from novice users — may speed up the interaction for the expert user such that the design can cater to both inexperienced and experienced users. Allow users to tailor frequent actions.
  6. Aesthetic and minimalist design. Interfaces should not contain information which is irrelevant or rarely needed. Every extra unit of information in an interface competes with the relevant units of information and diminishes their relative visibility. 9. Help users recognise, diagnose, and recover from errors. Error messages should be expressed in plain language (no error codes), precisely indicate the problem, and constructively suggest a solution.
  7. Help and documentation. It’s best if the system doesn’t need any additional explanation. However, it may be necessary to provide documentation to help users understand how to complete their tasks.

USABILITY Refers to the ways and techniques to make the Operating system usable for the humans, making the interface of an OS as easy as possible. Usability is the degree to which a software can be used by specified consumers to achieve quantified objectives with effectiveness , efficiency , and satisfaction in a quantified context of use.

Seven Norman's Principles Each principle can be applied as a special design strategy to make products efficient and effective to use:

  1. Knowledge - Use both knowledge in the world and knowledge in the head;
  1. Simplification - Simplify the structure of tasks;
  2. Visibility - Make things visible: bridge gulfs between Execution and Evaluation;
  3. Mapping - Get the mappings right;
  4. Constraints - Exploit the power of constraints;
  5. Errors – Design for errors;
  6. Standard - When all else fails, standardize.

DATA AND DATABASE

A database is a virtual “place” that allows you to organize information and

collection of data but with a criteria, is not simply like a box with a mess of

elements inside.

  1. Data is something that you can catch from everything and it’s raw.
  2. The unorganized facts/DETAILS need to be processed and treated to become an information.

“GB, MB, KB” represents the scale of measurement that will allow us to define

the dimension of something. If we talk about computers we have to use tera, but

there are even more and more information to store so we can also use peta, exa

(quintillion of infos), zetta, yotta, brontobyte.

You need to load your data warehouse regularly so that it can serve its purpose

of facilitating business analysis. To do this, data from one or more operational

systems needs to be extracted and copied into the data warehouse. The

challenge in data warehouse environments is to integrate, rearrange and

consolidate large volumes of data over many systems, thereby providing a new

unified information base for business intelligence.

DATA =/= INFORMATION

A DATABASE STORES BOTH.

2. Graphical

A graph database uses graph structure to store data. There’s no schema as

there is with relational databases.

  • You can store complex structures of data in a graph database, which would be hard or impossible in a relational database; the points could be data about people, businesses, accounts, or any other item.collection of notes and arcs, a logical map which I can connect objects between them with arcs.
  • Relational databases do well when there’s only one or two levels of relationships; graph databases handle far greater depths. There are undirected graphs (arcs with no directions, so no orientation, can be bidirectional) and directed graphs.
  • The limit is that it is difficult to understand , a little bit messy and complex to manage. if you delete an element you lose connections (and is difficult also to modify a connection). 3. Relational

When you see the word “database,” it almost always means a relational

database, in which data i s stored in tables with relations between tables.

  • The advantages of relational over other types of databases include the use of SQL, ease of changing the structure of tables, greater consistency in data, and handling of many-to-many relationships.
  • However, relational databases are slower than hierarchical and NoSQL, and joins between tables can become very slow if the tables are large.

Relational Database and Set theory

DBMS - Database Management System is a software system that enables users

to define, create, maintain and control access to the database. Examples of

DBMS include MySQL, PostgreSQL, MSSQL, Oracle Database, and Microsoft

Access.

The functionality provided by a DBMS can vary enormously. The core

functionality is the storage, retrieval and update of data.

The major features allows to manage informations:

  • Persistence : it’s like an assurance that the data will be always available in the process, not modified or destroyed.
  • Concurrency control: is the process of managing simultaneous operations on the database without having them interfere with each other (without crashes, or conflicts).
  • Integrity : assure not accidental damage to the database, by ensuring that authorized changes do not result in a loss of the usability of data.
  • Security : protects the database against unwanted effects, accidental or deliberate
  • Data independence: The capacity to change data storage structures and operations without having to change the DBMS access programs. It stores information about the database itself. - Logical Data independence : the ability to change the structure without having to change the physical storage and their application programs. - Physical Data independence : Ability to change the physical storage without having to change the structure and constraints for the whole database.

It manages the Data dictionary - languages behind DBMS itself that allows

people to put information. Metadata describes the object with multiple

sentences, descriptions, name, id, date, etc.

Relational Database

Is built upon the mathematical theory of sets and helps to have the basic

concepts straight like a “scheme” and match the relations/connections

between two objects. A Relational Database is a database constituting a set of

relations (usually erroneously referred to as "tables"). A relation is a set of