This shows the number 99 in binary. A one is 'on' or 'used' and a 0 is 'off' or 'not used'
The numbers that are on in this example are: 64 + 32 + 2 + 1 = 99
Real Numbers
Real numbers allow the computer to store decimal values.
The Mantissa dictates the precision of numbers and the Exponent dictates the range
Mantissa
The number of bits allocated to the Mantissa dictates the precision of a real number.
More bits to the Mantissa leads to greater precision. Less bit leads to less precision.
Exponent
The number of bits allocated to the Exponent dictates the range of a real number.
More bits to the Exponent leads to greater range. Less bit leads to less range.
(Extended) ASCII
Extended ASCII is one way to represent a character set. Extended ASCII code uses 8 bits to represent a character meaning that you can represent up to 256 different characters.
Printable Characters(ASCII)
Printable characters are those that you will be able to see on screen. They have an 8 bit ASCII code. Examples are:
A, s, !, @
Control Characters (ASCII)
Control Characters are those that do not appear on screen but that carry out a task. They have an 8 bit ASCII code.
Examples are:
Shift, Delete, Backspace, F2, Ctrl
Bit Mapped Graphics
Bit Mapped graphics are made up of a 2D array of pixels. Every single pixel is saved. JPEG, PNG and GIF are bit mapped graphic formats.
Bit Depth(Colour Depth for Graphics)
Every pixel is stored as a binary code. Bit depth is the number of bits used to store each pixel. A bit depth of 8 bits allows the pixel to be one of 256 colours, a bit depth of 16 bits allows for 65,536 colours and a bit depth of 24bits allows for 16, 777, 216 colours. The higher the bit depth the larger the file size but the more colour available.
Resolution
Resolution is the total number of pixels in an image.
E.g. A resolution of 800 x 600 would create 480,000 pixels
Vector Graphics
Vector graphics are NOT stored as individual pixels. Instead a description of attributes is used to create an object/shape. E.g. for a circle the attributes might be: cx (centre x), cy (centre y), rx (radius x), ry (radius y), fill, line. The computer uses the attributes to create shapes.
Vector graphics usually have smaller file sizes than bit mapped graphics as you don't need to store every pixel.
Bit Mapped v Vector
Scaling - Bit Mapped could be pixelated, vector would retain quality
Editing - Every pixel can be edited for fine detail in bit mapped graphics, in vector, fine detail is harder to edit as you can only change individual attributes
Layering - Bit maps don't let you layer shapes, whereas vectors do
File Size - bit mapped usually larger as every pixel is stored, whereas only attributes are stored in vector graphics
Vector - Rectangles
Rectangle is a type of polygon but given the frequency of its use, most vector graphic file formats support a specific rectangle object. Squares could be created using either the rectangle or polygon objects.
Attributes: x, y, fill, line, height, length. x and y define the top left corner position
Vector - Ellipse
Ellipse objects are like circles, but you can alter the radius of the X co-ordinate so that it is a different value to that of the Y co-ordinate. This allows for the creation of oval shapes rather than circles.
Attributes: cx and cy define the centre, rx and ry the radius. Fill and line.
Vector - Line
The line object allows for the creation of lines. More complex lines with different points can be created using an object called a polyline.
Attributes: x1 and y1 define the start of the line, x2 and y2 define the end of the line. Line is used for the colour of the line. Fill IS NOT NEEDED for lines.
Vector - Polygon
The polygon object can be any shape that has at least three sides and allows for a wide variety of common shapes to be stored in vector form.
At every angle, x and y coordinates are needed, so a shape with five angles would have:
Part of the processor/CPU that handles all arithmetic, logic and calculations. Stands for Arithmetic and Logic Unit.
Floating point (mantissa and exponent) calculations and decisions involving AND, OR, NOT are made on the ALU.
Registers
Temporary Storage Location on the processor. Data, instructions and addresses can be held in registers.
Have the fastest access time as they are on the processor unlike RAM or backing storage.
Control Unit
Part of the processor/cpu. Different lines have different roles. The main line is the clock line, which dictates the speed of fetching data from RAM.
Clock, Read, Write, Reset and Interrupt are the different lines.
Data Bus
A bi-directional bus (two way) that can carry data to and from RAM and the processor/CPU.
Goes to the address that is on the address bus and takes the data back to the processor OR takes the data from the processor to the address on the address bus.
Address Bus
A uni-directional (one way) bus. Holds the address in RAM that the processor wants to access.
Memory Locations (RAM Addresses)
Each location in RAM has its own binary address. The address bus holds the address of the location being read from or written to.
Interpreter
Used to translate high level language code (programming code) into binary. Will translate a line, then execute it. Stops if it finds an error and lets programmer know where error is located. Must be present in RAM during every translation/every time you run the program using an interpreter.
Compiler
Used to translate high level language code (programming code) into binary. Will translate each line in order and then create a new binary file called object code. Only in RAM once, and not needed again as the object code runs on its own. Does not identify errors and should be used when a program is totally error free and complete.
Machine Code
Machine Code is another name for binary, and is what programming code (high level languages) is turned into once it is translated using interpreters or compilers.
Operating systems include power down settings to let users:
Power down the monitor, laptop or desktop after a period of inactivity
Control individual components e.g. turn hard disk off until needed, set processor state (high or low), alter wifi power settings
Standby/Sleep Mode
RAM is still powered, and data held in RAM will still be stored until the user wakes the system. Power to all other components is significantly reduced or turned off.
Hibernate Mode
Contents of RAM are moved to space on the Hard Disk or other backing storage, where they are saved permanently. RAM and all components have power cut or lowered to the lowest possible level. When the user wakes the system, the contents move from the hard disk/ backing storage back to RAM
Firewalls
Data is split up and sent in packets when moving between networks. The firewall checks incoming and outgoing packets to make sure that they are sent/received from known IP addresses. Firewalls set rules about the IP addresses and ports that can be used to send and receive packets.
Encryption
Encryption is designed to prevent intercepted data from being understood. A simple key encrypts data. Data is further encrypted using the public key of the receiving profile (computer). When it arrives, the receivers private key can unlock the public key and the simple key is used to decrypt data. Only the private key that matches the public key is able to give access to the simple key.
Analysis Phase
A systems analyst creates a software specification. The specification includes the purpose and functional requirements (inputs, processes, outputs)
Purpose of software
The purpose of software is usually defined in a few short paragraphs, providing a written statement of what the software should do.
Functional Requirements (Programs)
The functional requirements of a program are defined as inputs, processes and outputs. A list of inputs that will come from the user, a sensor or a file are included. The processes focus on tasks the program will need to perform, such as validating input, or calculating an average. The outputs are a list of what the program will output, usually on screen but possibly to a file.
Design (Programming)
When designing a program, it is possible to use:
Pseudocode
Structure Diagrams
Flowcharts
Pseudocode
Pseudocode is a written list of steps used to design a program. Main steps are listed e.g. 1, 2, 3. Each main step is then refined e.g. 1.1, 1.2, 1.3, 1.4 etc.
One line of pseudocode usually results in one line of code when implementing (creating the program).
42
User Interface Design
The functional and end user requirements are taken into consideration when designing the user interface. The user interface is the part of the program the user sees. A wireframe showing input and output areas as well as the location of media is often created when designing a program.
Data Types
Data types identify the type of data held by a variable:
• Character
• String
• Integer
• Real
• Boolean
Character
A character is a single letter, number or symbol. Examples:
A
!
7
The character data type is used to store one single character only.