computer science

Subdecks (1)

Cards (94)

  • Number Systems:
    • Binary System:
    • Base 2 number system with values 0 and 1
    • 0 represents OFF, 1 represents ON
    • Most left bit is the MSB (Most Significant Bit)
    • Denary System:
    • Base 10 number system with values from 0 to 9
    • Hexadecimal (Hex) System:
    • Base 16 number system with values from 0 to 9 followed by A to F
    • A represents 10, B represents 11, and so on until F
  • Number Conversions:
    • Converting Binary to Denary:
    • Place binary value in columns of 2 raised to the power of the number of values from the right
    • Add values with 1 together for the final answer
    • Converting Denary to Binary:
    • Successively divide the value by 2 and note remainders to get the binary value
    • Converting Hexadecimal to Binary:
    • Separate each value, convert to denary, then to binary, and merge all binary values
    • Converting Binary to Hexadecimal:
    • Divide binary into groups of 4 from the right, find denary values, convert to hexadecimal, and merge all values
  • Binary Calculations:
    • Rules:
    • 0 + 0 = 0
    • 1 + 0 / 0 + 1 = 1
    • 1 + 1 = 0 (1 carry)
    • 1 + 1 + 1 = 1 (1 carry)
    • Overflow:
    • If the solution exceeds the limit of given values, the 9th bit is called overflow
    • Example:
    • Add 1 1 0 1 1 1 0 and 1 1 0 1 1 1 1 0 with carry and overflow considerations
  • Logical Shifts:
    • Moving a binary value left or right
    • The bit being emptied becomes 0
    • Example: Shifting 10101010 one place left
  • Two’s Complement (Binary Numbers):
    • Method to represent negative values in binary
    • MSB is replaced from 128 to -128
    • Range of values in two’s complement is -128 to 127
    • Converting to Two’s Complement:
    • Locate the first one from the right, switch values to the left of it
    • Converting Two’s Complement to Denary:
    • Convert binary to denary, replace 128 with -128
  • Use of the Hexadecimal System:
    • Examples:
    • Defining colors in HTML, MAC addresses, assembly languages, machine code, memory dumps, debugging, display error codes, IP addresses
    • Benefits:
    • Easier, faster, and less error-prone coding compared to binary
    • Used in developing software and tracing errors
  • Text:
    • ASCII:
    • 7-bit code for standard keyboard characters
    • Uppercase and lowercase characters have different ASCII values
    • Unicode:
    • Solves international language representation issues
    • Supports up to four bytes per character
    • Sound:
    • Sampled at regular intervals for digital conversion
    • Sampling resolution and rate affect accuracy and memory usage
  • Images:
    • Bitmap Images:
    • Made up of pixels stored as binary numbers
    • Colour Depth:
    • Number of bits representing each color
    • Image Resolution:
    • Refers to the number of pixels in an image
    • Higher resolution means more detail and less pixelation
  • When a bitmap image is 'blurry' or 'fuzzy' due to low pixel count or zooming, it is pixelated
  • High-resolution images have more pixels and detail compared to low-resolution images
  • In single-celled organisms, substances can easily enter the cell due to a short distance, while in multicellular organisms, the distance is larger due to a higher surface area to volume ratio
  • When a bitmap image is blurry or fuzzy due to a low amount of pixels, it is known as being pixelated
  • High-resolution images use high amounts of memory compared to low-resolution ones
  • Computer Architecture:
    • Processor contains the Arithmetic and Logic Unit (ALU)
    • Control Unit controls the operation of memory, processor, and input/output devices
    • Arithmetic Logic Unit carries out logic system calculations
    • System Clock produces timing signals on the control bus
    • Busses carry data through components: Address bus (unidirectional), Data Bus (bi-directional), Control Bus (unidirectional and bi-directional)
    • Immediate Access Store stores instructions to be processed, fetched by the CPU
  • Registers in the architecture:
    • CIR (Current Instruction Register): Increments the value of instructions by 1, fetches data and instructions
    • MAR (Memory Address Register): Stores the Address of the instruction, sends it to MDR
    • MDR (Memory Data Register): Stores Data from the address received from MAR, sends data to CIR
    • PC (Program Counter): Increments the value of instructions by 1, fetches data and instructions
    • ACC (Accumulator): Temporarily holds data during calculations
  • Fetch-Execute Cycle:
    1. PC contains the address of the next instruction
    2. Address copied to MAR via address bus
    3. Instruction of the address copied into MDR temporarily
    4. Instruction in MDR placed in CIR
    5. PC value incremented by 1
    6. Instruction decoded and executed
  • Stored Program Concept:
    • Instructions stored in main memory
    • Fetched, decoded, and executed by the processor
    • Programs can be moved to and from main memory
  • Memory Concept:
    • Computer memory divided into partitions with addresses and contents
    • Instruction Set: List of commands processed by CPU in machine code
  • System's Clock:
    • Defines clock cycle synchronizing all computer operations
    • Increasing clock speed increases processing speed, not necessarily performance
  • Overclocking:
    • Using a clock speed higher than designed for
    • Leads to issues like unsynchronized operations and overheating
  • Length of Data Buses:
    • Wider data buses improve computer performance
  • Cache:
    • Located within CPU for faster access
    • Stores frequently used instructions and data for improved CPU performance
    • Larger cache size enhances CPU performance
  • Cores:
    • More cores improve performance
    • Excessive cores can slow down system performance due to increased communication
  • Input Devices:
    • Two-dimensional Scanners: Convert hard-copy documents into electronic form stored in the computer
  • Three-dimensional Scanners:
    • Scan solid objects to produce a three-dimensional image
    • Used in Computer Aided Design (CAD) or 3D printing
  • Barcode Readers/Scanners:
    • Read barcodes using red laser or LED
    • Quick Response (QR) Codes: Matrix of dark squares on light background, store more data
  • Digital Cameras:
    • Controlled by microprocessor for image adjustments
    • Captures photos through light-sensitive cells called pixels
  • Keyboards:
    • Connected to computer via USB or wireless
    • Each character converted to digital signal
  • Pointing Devices:
    • Mouse/trackball: Traditional or modern with red LEDs for movement detection
  • Microphones:
    • Input sound to computer by converting vibrations into electric signals
  • Touchscreens:
    • Capacitive, Infra-red heat, Infra-red optical, Resistive types for touch input
  • Sensors:
    • Convert physical properties to digital values
    • Types include Acoustic, Accelerometer, Flow, Gas, Humidity, Infra-red, Level, Light, Magnetic Field, Moisture, pH, Pressure, Proximity, Temperature
  • Control of Street Lighting:
    • Light sensor sends data to ADC
    • Microprocessor samples data and activates street lamp if needed
  • Output Devices:
    • Inkjet Printers: Print pictures and documents by processing data and spraying ink on paper
  • Laser Printers:
    • Use dry powder ink (toner) and static electricity to produce text and images
    • Print the whole page in one go
    • Printing drum is given a positive charge; as the drum rotates, a laser beam is scanned across it, removing the positive charge leaves negatively charged areas which match the text/image
    • The drum is then coated with positively charged toner; it only sticks to negatively charged parts of the drum
    • A negatively charged sheet is rolled over the drum
    • The toner on the drum now sticks to the paper to produce a copy of the page
    • Paper finally goes through a fuser (set of heated rollers); heat melts the ink so it is permanent
    • The discharge lamp removes all electric charge from the drum, ready to print the next page
  • 3D Printers:
    • Used for models of cars
    • Produce solid objects that work
    • Built up layer by layer, using powdered resin, ceramic powder
    • A design is made using Computer-aided Design (CAD)
  • 2D and 3D Cutters:
    • 3D cutters can recognise objects in x, y, z direction
    • 3D laser cutters can cut glass, crystal, metal, wood
  • Actuators:
    • Convert electrical signals to mechanical processes
    • Used in many control applications involving sensors and devices (ADC and DAC)
  • Loudspeakers/Headphones:
    • Sound is produced by passing the digital data through a DAC then through an amplifier and then emerges from the loudspeaker
    • Produced by voltage differences vibrating a cone in the speaker at different frequencies
  • LCD and LED Monitors:
    • LCD monitors are backlit using Light Emitting Diode (LED)
    • LEDs reach their maximum brightness immediately
    • LEDs sharpen the image (higher resolution), and CCFL has a yellow tint
    • LEDs improve the color image
    • Monitors using LED are much thinner than CCFL
    • LEDs consume very little power
    • Before LEDs, LCD monitors were backlit using CCFL