Notes, summaries, assignments, exams, and problems for Computer science

Spreadsheet Software Functions and Disk Partitioning Concepts

Computer science3.8 KB

Software Applications and Data Handling

Spreadsheet Applications

Leaf is a software application that allows mathematical operations, working with numerical data, making complex calculations with formulas and functions, and generating graphs. In this unit, we will use the spreadsheet applications Excel and Calc.

Spreadsheet Errors

Spreadsheet errors do not tell us whether we made an error in an entry or operation. In Calc, error messages are available as codes. In Excel, the error messages are:

  • #####: The cell width cannot display content, or you have used a negative date or time.
  • #VALUE!: You have used an incorrect argument type or operation.
  • #NAME?: The text of the formula is not recognized.
  • #REF!: The cell reference is invalid.
  • #N/A: Not available
...
Continue reading "Spreadsheet Software Functions and Disk Partitioning Concepts" »

Evolution of Operating Systems: Generations & Concepts

Computer science2.71 KB

Historical Operating Systems: A Timeline

This document provides a brief history of operating systems, covering their evolution across different generations.

1st Generation (1945-1955)

Characterized by vacuum valves and machine language. These systems were large, consumed high energy, were very slow, and performed simple mathematical calculations.

2nd Generation (1955-1965)

Transitioned to transistors and batch processing. Systems became smaller and consumed less power.

3rd Generation (1965-1980)

Integrated circuits were introduced, making systems cheaper and enabling multiple processors to run concurrently.

4th Generation (1980-Present)

Marked by the advent of personal computers.

Memory Management

The memory manager is a crucial part of the OS. It is...

Continue reading "Evolution of Operating Systems: Generations & Concepts" »

Duplicate Nodes Multiple of 5 in C Singly Linked List

Computer science4.29 KB

Duplicate Nodes Multiple of 5 in a Singly Linked List

Given a singly linked list whose nodes are defined as follows:
struct node {
int data;
struct node *next;
};
Perform a doubling-to-top: duplicate all nodes whose data are multiples of 5 and place those copies at the front of the list.
Example:
If the original list:
| -> | 2 | -> | 5 | -> | 3 | -> | 6 | -> | 10 | -> | 1 | -> | 5 | -> | X |
then the final list becomes:
| -> | 5 | -> | 10 | -> | 5 | -> | 2 | -> | 5 | -> | 3 | -> | 6 | -> | 10 | -> | 1 | -> | 5 | -> | X |

Fixed C implementation

The corrected and polished C implementation below initializes a list of N_NODOS nodes, prints the list, duplicates nodes whose values are multiples...

Continue reading "Duplicate Nodes Multiple of 5 in C Singly Linked List" »

Database Management System Concepts and Functions

Computer science2.49 KB

Database Terminology and Structure

Tip: A set of characters with some meaning can be numeric, alphanumeric, or alphabetical.

Information: Ordered set of data that are managed according to user needs.

Field: It is the smallest unit to which we refer to in a program.

Record: Collection of equal fields or different types.

File: Collection of records stored homogeneously following a structure.

Database: Collection of interrelated files that typically contain information about a particular company.

DBMS: A computer-based system (software) that manages a database or a collection of databases or files.

Uses and Functions of a DBMS

  • Allow users to access and manipulate the database.
  • Provide administrators with the tools to perform maintenance and data management.
...
Continue reading "Database Management System Concepts and Functions" »

Core Concepts of Virtual Memory Management and Allocation Strategies

Computer science3.47 KB

Virtual Memory Management Fundamentals

What is Memory Management?

Memory Management is responsible for the efficient use of main memory in a multiprogramming environment where processes compete for memory resources.

Types of Address Space

  • Actual Addresses: Refer to the physical main memory (RAM) of the machine.
  • Logical or Virtual Addresses: The memory space perceived or known by the process. Each process maintains its own independent logical or virtual address space.

The central idea of virtual memory is to utilize the memory hierarchy: storing the most frequently accessed data in faster, lower-capacity storage tiers (RAM) and less frequently accessed data on less expensive, higher-capacity devices (disk).

Evolution of Memory Management Systems

  • Fixed
...
Continue reading "Core Concepts of Virtual Memory Management and Allocation Strategies" »

VHDL ALU Testbench Implementation and Simulation

Computer science2.33 KB

VHDL ALU Testbench Code

library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;
use std.textio.all;
use ieee.std_logic_textio.all;

entity alu_tb is
end alu_tb;

architecture sim of alu_tb is
    component alu
        generic (N : positive);
        port (
            a, b : in std_logic_vector (4*N-1 downto 0);
            opr : in std_logic;
            ovfw_sign : out std_logic;
            resultado : out std_logic_vector (4*N-1 downto 0)
        );
    end component;

    constant N : positive := 4;
    signal a_i, b_i : std_logic_vector (4*N-1 downto 0);
    signal opr_i : std_logic;
    signal ovfw_sign_i : std_logic;
    signal resultado_i : std_logic_vector (4*N-1 downto 0);

begin
    DUT: alu
    generic map (N =>
...
Continue reading "VHDL ALU Testbench Implementation and Simulation" »

Relational Database Model Principles and Evolution

Computer science3.48 KB

2

The Relational Model

Relational Model: Defines a database in terms of objects, properties, and operations. Objects with the same structure and behavior belong to the same class, and classes are organized into hierarchies. Relational models have extended their models to incorporate object-oriented concepts. In 1970, Edward F. Codd published an article in which he argued that data should be inter-linked by natural and logical relationships inherent to the data, rather than through physical pointers.

Codd proposed a simple data model in which all data are represented in tables consisting of rows and columns. Codd also proposed two languages to manipulate data in tables:

  • Relational algebra
  • Relational calculus

The logical manipulation of data also makes...

Continue reading "Relational Database Model Principles and Evolution" »

Turing's Thesis: Computability and Algorithms

Computer science2.5 KB

Turing's Thesis and the Problem of Computability

Thesis 1

"Every problem that can be solved algorithmically can be solved by a Turing machine."

Concepts Associated with Thesis 1

  • Algorithm: A set of rules that can be mechanically applied to solve a problem of a given class. Mainly used in mathematical contexts.
  • Calculation: Any transaction which is carried out by manipulation of symbols as a means of representation. The symbolic operations are atomic, that is, quite simple, and are held in a computer. The action of the computer will depend on the symbols that have the system and the internal state in which the computer is.

Thesis 2

"Every computable function can be computed by a Turing machine. Every problem that can be solved by algorithmic methods

...
Continue reading "Turing's Thesis: Computability and Algorithms" »

Understanding Automata Theory and Formal Languages

Computer science2.86 KB

Nondeterministic Finite-State Machine

It is a set of states and sets of transitions from state to state that occur on input symbols taken from an alphabet.

Language

A language is a set of words (strings) of finite length formed from a finite alphabet.

Regular Expression

A way of representing regular languages using alphabet characters on which the language is defined.

Networking

This seems to be a misunderstanding or mislabeling in the original text. Based on the examples, it describes Concatenation.

Concatenation is the combination of characters or strings. For example:

  • 'z' concatenated with '132' = "Z132"
  • '456' concatenated with 'AB' = "456AB"
  • 'z' concatenated with 'A' = "ZA"

Alphabet

An alphabet is an ordered set of symbols for a language. It is the...

Continue reading "Understanding Automata Theory and Formal Languages" »

Network Hardware, Cybersecurity Essentials and Graphics Software

Computer science2.91 KB

Modems and Routers: Connectivity Explained

A modem is a device that transforms digital signals from a computer into analog signals and vice versa, enabling connections via analog telephone lines. A router is used to interconnect computer networks. When connected to an ADSL line, it links the user to the internet, while a wireless system allows access through Wi-Fi devices.

Cybersecurity and Data Protection

Cryptography is used to protect information sent over the internet, ensuring it remains inaccessible to unauthorized users. Common methods include:

  • Browsing secure HTTPS pages.
  • Using digital certificates.
  • Email encryption.
  • Identifying users with electronic signatures.

Means of Prevention

To augment security during system operation, the following mechanisms...

Continue reading "Network Hardware, Cybersecurity Essentials and Graphics Software" »