knowt logo

Understanding Computer Science (WJEC)

This unit teaches you fundamental principles and concepts related to computer science. These include topics such as such as hardware, logical operations, communication, data representation, operating systems, programming principles, software engineering, and more.

Hardware

There are many hardware components that you need to learn about during this class. Here are the important ones and their functions:

  • Central Processing Unit (CPU)

    • The main part of the PC that runs it

    • Can process hundreds of millions of instructions each second

    • Stores data in binary (0s and 1s)

    • CPU components

      • Controller: Manages instruction execution

      • Arithmetic and Logic Unit (ALU): Performs calculations and data comparisons

      • Registers: Fast, temporary storage (e.g., Accumulator, Program Counter)

      • Internal Memory: Level 1 cache for fast data access

  • Buses: Buses allow data to be transferred to different parts of the computer

    • Address Bus: Transfers storage addresses

    • Data Bus: Moves data between components

    • Control Bus: Sends control signals

  • Cores

    • Cores are multi-core processors that compute multiple instructions

    • different devices mean different number of cores

    • the more the power instructions they can compute simultaneously

  • Input and Output Devices

    • Input Devices - devices that take in information from the user

      • Examples: Mouse, keyboard, microphone, digital camera, scanners, touch screens

    • Output Devices - devices that relay out info to the user

      • Examples: Monitor, speakers, printer, projector

  • Storage

    • Primary Storage: Refers to memory directly accessible by the CPU, like RAM, used for temporary data storage during processing.

    • Secondary Storage: Includes devices like hard drives, used for long-term data storage and retrieval.

  • Data Capacity

    • Data capacity refers to the amount of data that can be stored, transmitted, or processed by a computer system.

    • Units: Bit, byte, kilobyte (kB), megabyte (MB), gigabyte (GB), terabyte (TB)

  • Additional Hardware Components

    • Motherboard: Main circuit board with CPU, RAM, and other components

    • Graphics Processing Unit (GPU): Handles graphic calculations, can be integrated or dedicated

    • Sound Cards: Enable audio output and input, converting analog to digital and vice versa

  • Embedded Systems

    • a combination of software and hardware that performs a specific task

Logical Operations

Logical operations in computer science are fundamental operations that manipulate boolean values.

  • Propositional Logic

    • Boolean algebra evaluates statements to true or false

    • Propositional logic manipulates statements to simplify or derive logical statements

  • In computer science, truth tables are used to represent the outputs of logical expressions for all possible input combinations, aiding in understanding and designing logic circuits or algorithms.

  • Logical Operaions also include a lot of laws that you need to know that make solving easier. Similar to laws in math

    • Identity Law: A+0=AA + 0 = AA+0=A

    • Associative Laws: Order of operation doesn't matter with same type operators

    • Commutative Laws: Order of operands doesn't matter

    • Distributive Law: X.(Y+Z)=X.Y+X.ZX . (Y + Z) = X . Y + X . ZX.(Y+Z)=X.Y+X.Z

    • Annulment Law: A+1=1A + 1 = 1A+1=1

    • Idempotent Law: A+A=AA + A = AA+A=A

    • Inverse Law: A+Aˉ=1A + Ā = 1A+Aˉ=1

    • Annulment Law (AND): A.0=0A . 0 = 0A.0=0

    • Identity Law (AND): A.1=AA . 1 = AA.1=A

    • Idempotent Law (AND): A.A=AA . A = AA.A=A

    • Complement Law: A.Aˉ=0A . Ā = 0A.Aˉ=0

    • Double Complement Law: AˉAˉ=AĀĀ = AAˉAˉ=A

    • Absorptive Law: A+(A.B)=AA + (A . B) = AA+(A.B)=A

    • Absorptive Law: A.(A+B)=AA . (A + B) = AA.(A+B)=A

Communication

  • Networks: A network connects multiple computer systems together

    • Pros of Networks in Computer Science:

      • Communication between devices and users

      • Resource sharing (files, printers, internet)

      • Collaboration among users in different locations

      • Scalability to accommodate more devices

      • Centralized management of resources and security

      • Cost-effective for organizations

      • Flexibility in accessing resources

    • Cons of Networks in Computer Science:

      • Security risks (breaches, cyber attacks)

      • Complexity in setup and maintenance

      • Downtime leading to disruptions

      • Bandwidth limitations affecting performance

      • Dependency on network for operations

      • Privacy concerns with data transmission

      • Compatibility challenges among devices and protocols

    • Types of networks include Local Area Network and Wide Area Network

      • only difference is how far the computer systems are within the network and their reach to other systems.

  • Connectivity

    • Network Interface Card (NIC): Connects a computer to a network

    • Connection Methods: Wired (copper, fiber-optic) or wireless (Wi-Fi)

    • Typical Speeds:

      • Wired: 100 Mbps to 10 Gbps

      • Wireless: 54–108 Mbps, affected by distance and conditions

  • Packets: contain data for a computer system

    • can share data between the network and to other computer systems

  • IP Addresses:

    • unique id assigned to every device,

      • people have this too in their respective countries.

    • Assigned by DHCP server or manually

    • types of IP addresses

      • IPv4: 32-bit address, e.g., 192.168.1.1

      • IPv6: 128-bit address, e.g., 2001:0db8:85a3:0000:0000:8a2e:0370:7334

  • Protocols

    • Ethernet Protocol: defines rules for data transmission network (LAN)

    • Wifi Protocol: checks wifi security for user safety and data safety

    • Email protocol: various protocols that save data in servers and transfer it to computer systems to keep data safe and encrypted

Organization and structure of data

  • The Nature of Data

    • Data: Raw facts and figures (e.g., text, numbers, pictures, sounds, videos).

    • Information: Data that has been processed to be meaningful.

  • Counting Systems

  • Image Representation

    • an image is made of pixels, the more in pixel in the image, the better the resolution is

    • Each pixel is a binary number representing color.

    • Black and white use 1 (black) and 0 (white).

    • Color images use more bits for RGB values.

  • Character Representation

    • Stored as binary numbers.

    • Character sets map characters to binary numbers.

    • ASCII is a character encoding standard used in computers and communication equipment to represent text and control characters

  • Data Types

    • Integer: Whole numbers (e.g., 42, -11).

    • Real: Decimal numbers (e.g., 12.9, -17.5).

    • Boolean: True or False (e.g., 1, 0).

    • Character: Single symbol (e.g., 'A', '7').

    • String: Sequence of characters (e.g., "Hello").

Operating systems

Operating systems in computer science involve managing a computer system and the resources within a system.

  • Management

    • RAM Management: Prevents programs and data from corrupting each other.

    • Process Management: Ensures efficient CPU usage without interference between processes.

    • Security Management: Manages user accounts and passwords.

  • Providing User Interface

    • Copying, deleting, moving, sorting, and searching files or folders.

    • Accessing system settings.

    • Providing command line and graphical user interfaces (GUIs).

    • Allowing multiple windows open at once.

    • Customizing the interface (e.g., desktop background).

    • Switching between tasks

  • HCI VS GUI

    • Human-Computer Interaction (HCI) focuses on users interacting with computers, emphasizing usability and user experience.

    • Graphical User Interface (GUI) uses graphical icons for user-friendly interaction, contrasting with command-line interfaces.

    • HCI studies user behaviors to design easy-to-use interfaces.

    • GUIs visually represent functions for navigation ease.

    • Both HCI and GUI enhance user experience and system efficiency.
      Operating systems

  • Disk Organization.

    • File transfer: moving files into different locations

    • formatting: prepares a disk like a USB or sd card for use with a different device or system

    • compression: reduces file sizes

Principles of Programming

  • High-Level Languages

    • Programming languages are similar to human languages.

    • Easier to understand and learn.

    • Commands are powerful and perform complex tasks.

    • Python, Java, JavaScript, C++, Ruby, and PHP

  • Low-Level Languages

    • Requires knowledge of the CPU's internal structure.

    • Uses mnemonics, converted to machine code with an assembler.

    • Specific to a type of CPU and not portable.

    • Very efficient, resulting in faster programs.

    • Example: C, Assembly, and Fortran.

  • Machine Code

    • Opposite of high-level languages.

    • Made of bit patterns (instructions or data).

    • Directly executed by the CPU.

    • High-level languages need conversion to machine code for execution.

Software Development Principles

  • Integrated Development Environments (IDEs) are ways to program for users and run code.

    • Most popular is VS Code

    • Provide tools for creating computer programs.

  • Common IDE Tools

    • Editor: Enter, format, and edit source code.

    • Compiler: Converts source code into machine code for later execution.

    • Interpreter: Converts and executes source code line by line.

    • Linker: Connects compiled code from libraries.

    • Loader: Loads compiled code into memory for execution.

    • Debugger: Identifies and fixes errors in programs.

    • Trace: Displays executed lines and variable values during runtime.

    • Break Point: Pauses program at a specific line for debugging.

    • Variable Watch: Shows current variable values and can interrupt program.

    • Memory Inspector: Displays memory contents.

    • Error Diagnostics: Shows error messages for debugging.

    • Libraries: Contains commonly used functions and subprograms.

Program construction

Program construction refers to the process of designing, coding, testing, and debugging a computer program to ensure it meets the specified requirements and functions correctly.

  • Assemblers

    • Converts assembly language into machine code.

    • Example:

      • Assembly Code: AND A

      • Assembler Conversion: Opcode: 0010, Operand: 0001

  • Interpreters

    • Converts high-level programming code into machine code one line at a time

    • Executes instantly

  • Analyses

    • Lexical Analysis removes comments and spaces, replaces keywords with tokens, and creates a symbol table.

    • Syntax Analysis checks token spelling and grammar, producing error messages for syntax errors.

    • Semantic Analysis validates variable declarations, data types, and legal operations.

  • Translators

    • Changes a program from one language to another language

    • Translating PASCAL code into C code.

  • Types of Errors in Coding

    • Syntax Errors: Occur when commands don't follow expected syntax.

    • Runtime/Execution Errors: Happen during program execution.

    • Logical Errors: Cause incorrect output without crashing.

    • Linking Errors: Occur when correct library isn't linked.

    • Rounding Errors: Approximating numbers to nearest value.

    • Truncation Errors: Approximating numbers closer to zero.


A

Understanding Computer Science (WJEC)

This unit teaches you fundamental principles and concepts related to computer science. These include topics such as such as hardware, logical operations, communication, data representation, operating systems, programming principles, software engineering, and more.

Hardware

There are many hardware components that you need to learn about during this class. Here are the important ones and their functions:

  • Central Processing Unit (CPU)

    • The main part of the PC that runs it

    • Can process hundreds of millions of instructions each second

    • Stores data in binary (0s and 1s)

    • CPU components

      • Controller: Manages instruction execution

      • Arithmetic and Logic Unit (ALU): Performs calculations and data comparisons

      • Registers: Fast, temporary storage (e.g., Accumulator, Program Counter)

      • Internal Memory: Level 1 cache for fast data access

  • Buses: Buses allow data to be transferred to different parts of the computer

    • Address Bus: Transfers storage addresses

    • Data Bus: Moves data between components

    • Control Bus: Sends control signals

  • Cores

    • Cores are multi-core processors that compute multiple instructions

    • different devices mean different number of cores

    • the more the power instructions they can compute simultaneously

  • Input and Output Devices

    • Input Devices - devices that take in information from the user

      • Examples: Mouse, keyboard, microphone, digital camera, scanners, touch screens

    • Output Devices - devices that relay out info to the user

      • Examples: Monitor, speakers, printer, projector

  • Storage

    • Primary Storage: Refers to memory directly accessible by the CPU, like RAM, used for temporary data storage during processing.

    • Secondary Storage: Includes devices like hard drives, used for long-term data storage and retrieval.

  • Data Capacity

    • Data capacity refers to the amount of data that can be stored, transmitted, or processed by a computer system.

    • Units: Bit, byte, kilobyte (kB), megabyte (MB), gigabyte (GB), terabyte (TB)

  • Additional Hardware Components

    • Motherboard: Main circuit board with CPU, RAM, and other components

    • Graphics Processing Unit (GPU): Handles graphic calculations, can be integrated or dedicated

    • Sound Cards: Enable audio output and input, converting analog to digital and vice versa

  • Embedded Systems

    • a combination of software and hardware that performs a specific task

Logical Operations

Logical operations in computer science are fundamental operations that manipulate boolean values.

  • Propositional Logic

    • Boolean algebra evaluates statements to true or false

    • Propositional logic manipulates statements to simplify or derive logical statements

  • In computer science, truth tables are used to represent the outputs of logical expressions for all possible input combinations, aiding in understanding and designing logic circuits or algorithms.

  • Logical Operaions also include a lot of laws that you need to know that make solving easier. Similar to laws in math

    • Identity Law: A+0=AA + 0 = AA+0=A

    • Associative Laws: Order of operation doesn't matter with same type operators

    • Commutative Laws: Order of operands doesn't matter

    • Distributive Law: X.(Y+Z)=X.Y+X.ZX . (Y + Z) = X . Y + X . ZX.(Y+Z)=X.Y+X.Z

    • Annulment Law: A+1=1A + 1 = 1A+1=1

    • Idempotent Law: A+A=AA + A = AA+A=A

    • Inverse Law: A+Aˉ=1A + Ā = 1A+Aˉ=1

    • Annulment Law (AND): A.0=0A . 0 = 0A.0=0

    • Identity Law (AND): A.1=AA . 1 = AA.1=A

    • Idempotent Law (AND): A.A=AA . A = AA.A=A

    • Complement Law: A.Aˉ=0A . Ā = 0A.Aˉ=0

    • Double Complement Law: AˉAˉ=AĀĀ = AAˉAˉ=A

    • Absorptive Law: A+(A.B)=AA + (A . B) = AA+(A.B)=A

    • Absorptive Law: A.(A+B)=AA . (A + B) = AA.(A+B)=A

Communication

  • Networks: A network connects multiple computer systems together

    • Pros of Networks in Computer Science:

      • Communication between devices and users

      • Resource sharing (files, printers, internet)

      • Collaboration among users in different locations

      • Scalability to accommodate more devices

      • Centralized management of resources and security

      • Cost-effective for organizations

      • Flexibility in accessing resources

    • Cons of Networks in Computer Science:

      • Security risks (breaches, cyber attacks)

      • Complexity in setup and maintenance

      • Downtime leading to disruptions

      • Bandwidth limitations affecting performance

      • Dependency on network for operations

      • Privacy concerns with data transmission

      • Compatibility challenges among devices and protocols

    • Types of networks include Local Area Network and Wide Area Network

      • only difference is how far the computer systems are within the network and their reach to other systems.

  • Connectivity

    • Network Interface Card (NIC): Connects a computer to a network

    • Connection Methods: Wired (copper, fiber-optic) or wireless (Wi-Fi)

    • Typical Speeds:

      • Wired: 100 Mbps to 10 Gbps

      • Wireless: 54–108 Mbps, affected by distance and conditions

  • Packets: contain data for a computer system

    • can share data between the network and to other computer systems

  • IP Addresses:

    • unique id assigned to every device,

      • people have this too in their respective countries.

    • Assigned by DHCP server or manually

    • types of IP addresses

      • IPv4: 32-bit address, e.g., 192.168.1.1

      • IPv6: 128-bit address, e.g., 2001:0db8:85a3:0000:0000:8a2e:0370:7334

  • Protocols

    • Ethernet Protocol: defines rules for data transmission network (LAN)

    • Wifi Protocol: checks wifi security for user safety and data safety

    • Email protocol: various protocols that save data in servers and transfer it to computer systems to keep data safe and encrypted

Organization and structure of data

  • The Nature of Data

    • Data: Raw facts and figures (e.g., text, numbers, pictures, sounds, videos).

    • Information: Data that has been processed to be meaningful.

  • Counting Systems

  • Image Representation

    • an image is made of pixels, the more in pixel in the image, the better the resolution is

    • Each pixel is a binary number representing color.

    • Black and white use 1 (black) and 0 (white).

    • Color images use more bits for RGB values.

  • Character Representation

    • Stored as binary numbers.

    • Character sets map characters to binary numbers.

    • ASCII is a character encoding standard used in computers and communication equipment to represent text and control characters

  • Data Types

    • Integer: Whole numbers (e.g., 42, -11).

    • Real: Decimal numbers (e.g., 12.9, -17.5).

    • Boolean: True or False (e.g., 1, 0).

    • Character: Single symbol (e.g., 'A', '7').

    • String: Sequence of characters (e.g., "Hello").

Operating systems

Operating systems in computer science involve managing a computer system and the resources within a system.

  • Management

    • RAM Management: Prevents programs and data from corrupting each other.

    • Process Management: Ensures efficient CPU usage without interference between processes.

    • Security Management: Manages user accounts and passwords.

  • Providing User Interface

    • Copying, deleting, moving, sorting, and searching files or folders.

    • Accessing system settings.

    • Providing command line and graphical user interfaces (GUIs).

    • Allowing multiple windows open at once.

    • Customizing the interface (e.g., desktop background).

    • Switching between tasks

  • HCI VS GUI

    • Human-Computer Interaction (HCI) focuses on users interacting with computers, emphasizing usability and user experience.

    • Graphical User Interface (GUI) uses graphical icons for user-friendly interaction, contrasting with command-line interfaces.

    • HCI studies user behaviors to design easy-to-use interfaces.

    • GUIs visually represent functions for navigation ease.

    • Both HCI and GUI enhance user experience and system efficiency.
      Operating systems

  • Disk Organization.

    • File transfer: moving files into different locations

    • formatting: prepares a disk like a USB or sd card for use with a different device or system

    • compression: reduces file sizes

Principles of Programming

  • High-Level Languages

    • Programming languages are similar to human languages.

    • Easier to understand and learn.

    • Commands are powerful and perform complex tasks.

    • Python, Java, JavaScript, C++, Ruby, and PHP

  • Low-Level Languages

    • Requires knowledge of the CPU's internal structure.

    • Uses mnemonics, converted to machine code with an assembler.

    • Specific to a type of CPU and not portable.

    • Very efficient, resulting in faster programs.

    • Example: C, Assembly, and Fortran.

  • Machine Code

    • Opposite of high-level languages.

    • Made of bit patterns (instructions or data).

    • Directly executed by the CPU.

    • High-level languages need conversion to machine code for execution.

Software Development Principles

  • Integrated Development Environments (IDEs) are ways to program for users and run code.

    • Most popular is VS Code

    • Provide tools for creating computer programs.

  • Common IDE Tools

    • Editor: Enter, format, and edit source code.

    • Compiler: Converts source code into machine code for later execution.

    • Interpreter: Converts and executes source code line by line.

    • Linker: Connects compiled code from libraries.

    • Loader: Loads compiled code into memory for execution.

    • Debugger: Identifies and fixes errors in programs.

    • Trace: Displays executed lines and variable values during runtime.

    • Break Point: Pauses program at a specific line for debugging.

    • Variable Watch: Shows current variable values and can interrupt program.

    • Memory Inspector: Displays memory contents.

    • Error Diagnostics: Shows error messages for debugging.

    • Libraries: Contains commonly used functions and subprograms.

Program construction

Program construction refers to the process of designing, coding, testing, and debugging a computer program to ensure it meets the specified requirements and functions correctly.

  • Assemblers

    • Converts assembly language into machine code.

    • Example:

      • Assembly Code: AND A

      • Assembler Conversion: Opcode: 0010, Operand: 0001

  • Interpreters

    • Converts high-level programming code into machine code one line at a time

    • Executes instantly

  • Analyses

    • Lexical Analysis removes comments and spaces, replaces keywords with tokens, and creates a symbol table.

    • Syntax Analysis checks token spelling and grammar, producing error messages for syntax errors.

    • Semantic Analysis validates variable declarations, data types, and legal operations.

  • Translators

    • Changes a program from one language to another language

    • Translating PASCAL code into C code.

  • Types of Errors in Coding

    • Syntax Errors: Occur when commands don't follow expected syntax.

    • Runtime/Execution Errors: Happen during program execution.

    • Logical Errors: Cause incorrect output without crashing.

    • Linking Errors: Occur when correct library isn't linked.

    • Rounding Errors: Approximating numbers to nearest value.

    • Truncation Errors: Approximating numbers closer to zero.


robot