💻

Computer Science Topics Overview

Jul 21, 2025

Overview

This lecture covers key A-level computer science topics: processor architectures (RISC/CISC), pipelining, parallel computing, virtual machines, Boolean algebra, truth tables, Karnaugh maps, and logic circuits (adders and flip-flops), with accompanying examples and practice questions.

Processor Architectures: RISC vs CISC

  • Processor architecture defines how a CPU is designed and affects instruction complexity and speed.
  • CISC (Complex Instruction Set Computer): large set of complex instructions, found in desktops/laptops, can execute complex operations in fewer instructions, often uses direct RAM access.
  • RISC (Reduced Instruction Set Computer): small, simple instruction set, typical in mobile/embedded systems, each instruction usually takes one clock cycle, uses registers for data storage.
  • RISC generally allows faster execution of simple instructions; CISC can handle more complex operations per instruction.

Pipelining & Registers

  • Pipelining: overlapping different stages of instruction processing (fetch, decode, execute, write-back) to increase CPU efficiency.
  • In pipelining, multiple instructions are at different stages simultaneously, reducing total clock cycles needed.
  • Registers (in RISC) provide fast temporary storage, enabling efficient pipelining compared to memory-based (CISC) processing.

Parallel Computing & Architectures

  • Parallel computing: multiple processors/computers work together on a single task, as opposed to serial (one after another) processing.
  • Four main architectures:
    • SISD: Single instruction, single data.
    • SIMD: Single instruction, multiple data (e.g., graphics processing).
    • MISD: Multiple instructions, single data (rarely used).
    • MIMD: Multiple instructions, multiple data (common in multi-core systems).

Virtual Machines

  • A virtual machine emulates a computer system (hardware and OS) on another host system.
  • Allows running multiple operating systems, testing software for different architectures, isolating risky tasks, and running legacy programs.
  • Trade-offs: uses more system resources, performance is limited by the host, may not emulate all hardware, and can be expensive to implement.

Boolean Algebra & Logic Gates

  • Boolean algebra: mathematical system for binary variables (true/false, 1/0) using operators (AND, OR, NOT).
  • Key gate representations:
    • NOT: 𝑎̅
    • AND: AB or A·B
    • OR: A+B
    • NAND: (AB)̅
    • NOR: (A+B)̅

Boolean Algebra Laws & Simplification

  • Common laws: De Morgan’s, commutative, associative, distributive, absorption, identity, null, idempotent.
  • De Morgan’s Theorem:
    • (AB)̅ = 𝑎̅+𝑏̅
    • (A+B)̅ = 𝑎̅·𝑏̅
  • Simplification uses these laws to reduce circuit complexity and logic expressions.

Truth Tables & Sum of Products

  • Truth tables list all input combinations and corresponding outputs.
  • Sum of products: outputs as a logical OR of all combinations that produce a true (1) result.

Karnaugh Maps (K-Maps)

  • K-Maps visually simplify Boolean expressions by grouping 1’s in powers of two (2, 4, 8).
  • Groups are made as large as possible for simplest expressions.
  • Each group translates to a simplified term in the final logic expression.

Logic Circuits: Adders

  • Half Adder: adds two 1-bit binary numbers; outputs sum and carry.
  • Full Adder: adds three 1-bit numbers; outputs sum and carry.
  • Truth tables and logic expressions can be derived for both.

Flip-Flop Circuits

  • SR Flip-Flop: stores a single binary digit; has Set (S) and Reset (R) inputs.
  • JK Flip-Flop: similar to SR but eliminates invalid (undefined) states by toggling output when both inputs are high.
  • Flip-flops are basic storage elements in registers and sequential circuits.

Key Terms & Definitions

  • RISC: Reduced Instruction Set Computer, simple instructions, fast execution.
  • CISC: Complex Instruction Set Computer, many complex instructions.
  • Pipelining: Overlapping instruction stages for efficiency.
  • Register: Fast, small memory location within a CPU.
  • Parallel Computing: Multiple processors/computers working concurrently.
  • Virtual Machine: Software emulation of a computer system.
  • Boolean Algebra: Mathematical logic for binary variables.
  • Karnaugh Map (K-Map): Tool for simplifying Boolean expressions.
  • Half Adder: Circuit adding two 1-bit numbers.
  • Full Adder: Circuit adding three 1-bit numbers.
  • Flip-Flop: Circuit element storing one bit.

Action Items / Next Steps

  • Review Boolean algebra laws, De Morgan’s theorem, and K-Map grouping rules.
  • Practice drawing and interpreting truth tables, logic gates, adders, and flip-flop circuits.
  • Complete assigned textbook or exam practice questions on these topics.