Computer Science

Cards (198)

  • Purpose of the CPU
    Fetch-execute cycle:
    • Data and instructions FETCHED from main memory
    • They are then DECODED and EXECUTED
    • This is carried out in a continuous cycle
  • Common CPU components and their function
    • ALU (Arithmetic and Logic Unit)
    • CU (Control Unit)
    • Cache
    • Registers
  • Von Neumann Architecture
    • MAR (Memory Address Register)
    • MDR (Memory Data Register)
    • Program Counter
    • Accumulator
  • Fetch-execute cycle
    1. Fetch
    2. Decode
    3. Execute
  • ALU performs calculations and logic checks. It may take several F-E-Cycles for a calculation to be finished. Intermediate results are stored in the accumulator
  • Cache
    Very fast memory. Instructions that are carried out frequently are stored there so that they do not have to be FETCHED (saving time)
  • Registers
    Small amounts of high-speed memory contained within the CPU. Registers store data that is needed during the F-E-C
  • John Von Neumann was a Hungarian mathematician who developed the idea that a computer could be used for many purposes and not just one. This was called the stored program concept.
  • Von Neumann's architecture
    • Uses memory to store data and instructions and uses the fetch execute cycle to retrieve and process instructions
  • 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
  • MDR
    Holds the contents found at the address held in the MAR, or data which is to be transferred to primary memory
  • Program Counter
    Holds the memory address of the next instruction to be fetched from primary memory
  • Accumulator
    Holds data while it is being processed and while results are being stored
  • How common characteristics of CPUs affect their performance
    • Clock speed
    • Cache size
    • Number of cores
  • Embedded systems
    Small computer systems built inside larger devices or pieces of equipment. Designed to do one specific task (rather than range of task). Have a simple user interface. The software used to control or run the system is also very basic.
  • Embedded systems are not the same as systems that can do many tasks
  • The clock coordinates all the computer's components. It sends out a pulse that synchronises each component. The frequency of the pulses is known as the clock speed. The higher the frequency, the more instructions can be processed in a given time
  • Core
    Each processing unit inside a CPU. Each core can carry out the fetch execute cycle. The more cores a CPU has, the more instructions it can process in a given time (i.e. PARALLEL PROCESSING)
  • Cache is very fast (and expensive) memory that can store frequently used data or instructions
  • Primary storage is used to store programs and data currently used by the computer. When a user needs to run a program, it is loaded from disk to primary storage.
  • RAM (Random Access Memory)
    Another term for primary storage. Data can be stored anywhere within the available memory. RAM is volatile (i.e. any data stored in RAM is lost when the device is powered off)
  • ROM (Read Only Memory)

    Non-volatile (i.e. any data stored in RAM is not lost when the device is powered off) - it is stored permanently. Can be used to store the BIOS (i.e. the program that boots up and loads the Operating System when the computer turned on)
  • Virtual memory
    Used when the computer is short of RAM. This involves the hard disk being used as memory instead of RAM. This is not ideal as the speed of a hard disk is MUCH slower then RAM.
  • Common types of secondary storage
    • Optical
    • Magnetic
    • Solid state
  • Optical storage
    Includes CD, DVD and Blu-ray. Data is written to optical storage media using a laser. The capacity of this type of media ranges from 640 megabytes (CD) to 50 gigabytes (Blu-ray). Since it involves the use of moving parts, access/data transfer speeds are slower than for other types of media.
  • Solid state media
    Also known as electrical or flash storage. Has the fastest transfer speed out of all the three types of media, since it features no moving parts. This also makes it more robust than other forms of storage and in addition they consume less power. However this form of storage offers lower capacity than other forms of media and is still comparatively expensive.
  • Magnetic storage media
    Include hard drives and tape and can have a huge capacity (100's of terabytes). Involve the use of moving parts. This means that they have comparatively slow data read and write speeds and can be prone to damage.
  • Units of data storage
    • Bit
    • Nibble (4 bits)
    • Byte (8 bits)
    • Kilobyte (1,000 bytes or 1KB)
    • Megabyte (1,000 KB)
    • Gigabyte (1,000 MB)
    • Terabyte (1,000 GB)
    • Petabyte (1,000 TB)
  • Computers are electrical devices; their components are made up of millions of circuits. Each circuit contains switches which can be either 'on' or 'off'. These can be represented by the values 1 and 0. This is called binary.
  • All data is stored and processed in binary form - this includes text, images, sound and video.
  • Converting positive denary whole numbers to binary numbers (up to and including 8 bits) and vice-versa

    Start with the column nearest the number (i.e. 16 or 2^4)
    Put a one in that column
    Check each remaining column, adding either a 1 or 0 onto the end of the number
  • Adding two binary integers together (up to and including 8 bits) and explaining overflow errors which may occur

    Split the number into two groups of 4 bits
    Add the corresponding bits together, carrying 1s as necessary
    If there are insufficient bits to store the answer, this causes OVERFLOW
  • Converting positive denary whole numbers into 2-digit hexadecimal numbers and vice versa

    First convert the number to binary
    Then convert each group of 4 bits to HEX
    Join (don't add) both digits together
  • Converting binary integers to their hexadecimal equivalents and vice versa

    To convert decimal to hex: First convert the number to binary, then convert each group of 4 bits to HEX
    To convert hex to decimal: Work through the process backwards
  • Binary shifts
    Used to multiply or divide a binary number by 2:
    Left shift - multiply by 2
    Right shift - divide by 2
  • Character set
    The term used to describe the range of characters that can be represented by a given number of bits
  • ASCII
    A 7-bit character set that can represent letters, numbers and symbols
  • Unicode
    A 16-bit character set that can represent a much wider range of characters, including foreign languages
  • Pixels
    The individual elements that make up a digital image. Each pixel is represented in binary as a 1 (on) or a 0 (off). Colour images need additional binary code to store the colour.
  • Metadata
    Additional information stored when a file is saved, such as time/date of creation, file size, resolution, etc.