Uploaded by Quesy

zyVkd1kcA127fkMfHqlcWMT4a

advertisement
National 5 Computing Science
SUMMARY NOTES – Computer Systems
Not to be used as your sole revision resource! Please check www.sqa.org.uk/sqa/56923.html for the up-to-date course spec.
COMPUTER SYSTEMS – Data representation
Binary
Denary
Floating point
representation
Extended ASCII
A base 2 number system.
Uses only 1 and 0.
Place values are powers of 2.
A base 10 number system.
Uses only 0, 1, 2, 3, 4, 5, 6, 7, 8, 9.
Place values are powers of 10.
Real numbers are stored, using floating point representation, as a mantissa and an
exponent.
For example, in the number 0.333894 x 1036 the mantissa is 333894 and the
exponent is 36.
8-bit code used to convert text into binary. Each character is represented by 8 bits.
It includes 32 control characters such as null, escape, carriage return, etc.
The rest are printable characters such as A, %, 8, etc.
Vector graphics
Stores attributes of individual objects.
Resolution independent, small file size, can be manipulated at object level.
SVG
(Scalable Vector Graphics)
A coding language used to define vector graphics.
SVG objects
SVG attributes
Bitmap graphics
 <rect>
 <ellipse>
 <line>
 <polygon>
 Fill
 Stroke
 Coordinates – x, y, cx, cy, x1, y1, x2, y2, points
 Size – width, height, rx, ry
Image is represented as a grid of pixels.
The colour of every pixel is stored as a binary number.
More appropriate than vector for real-life images, can be manipulated at pixel
level.
COMPUTER SYSTEMS – Security precautions
Firewall
Software which filters incoming and outgoing data packets and blocks any
unwanted data.
Encryption
Scrambling data (using a public key) so it cannot be understood (without the
correct private key).
COMPUTER SYSTEMS – Computer structure
CPU
(Central Processing Unit)
The main processor in a computer.
Responsible for executing program instructions.
Different processors can be compared using benchmark tests.
ALU
(Arithmetic and Logic Unit)
Carries out arithmetical operations (*, -, +, -, ^) and logical comparisons (<, >, =,
AND, OR, NOT).
Control Unit
Manages processor, ensures program instructions are executed in the correct
sequence.
Registers
Temporary, fast-to-access storage locations on the CPU.
Main memory
Used to store data for programs which are currently running.
Organised into individual memory locations each with a unique address.
Connected to CPU by data and address buses.
Data bus
Carries data to and from memory.
Bi-directional.
Address bus
Carries addresses to memory.
Uni-directional.
Low-level language
Instructions relate to specific registers, memory locations, etc.
Hard to learn and understand and difficult to debug but instructions can be
executed quickly.
Lowest level language is machine code (which just looks like binary).
High-level language
Instructions use English words and are easier to understand than low-level
languages.
One high-level instruction may equate to many low-level instructions.
Makes coding and debugging programs easier but instructions must be translated
into machine code before they can be executed.
Translator
Software which translates a high-level program into machine code.


Interpreter




Compiler





A type of translator which translates then executes one line after the other.
Program will run quite slowly (since every line needs to be translated before
execution).
Does not store the translated code.
Helpful when testing since errors can be identified as they are encountered.
Would typically be used while the program is being developed.
A type of translator which translates the entire high-level program and saves it
as a machine code version.
Process of compiling may take some time.
Compiled, machine code version of the program will run quickly.
The original high-level program is called the source code.
The machine code translation is called the object code.
Would typically be used once the program is ready for distribution.
COMPUTER SYSTEMS – Environmental impact
The amount of energy a computer system uses can be reduced by:
 Leaving computers on standby or switching off when not in use.
 Adjusting monitor settings, lowering brightness for example.
 Adjusting Operating System power settings so computer waits less time before
sleeping/hibernating.
Energy use
WEB DEVELOPMENT – Standard file formats and factors affecting file size
Compression
Reducing the size of a file so that it:
 takes up less storage space
 takes less time to transmit/upload/download from one computer to another.
Lossy compression
Compresses by removing data, so quality is lost.
Lossless compression
Compresses without removing data, quality is not affected.
Resolution
The number of pixels used to store an image.
High resolution = larger file size, better quality.
Colour depth
Number of bits used to store the colour of each pixel.
True colour = 24 bits.
High bit depth = larger file size, more colours available.
Audio sample
A measurement of an analogue sound signal.
Audio sample rate
The frequency with which samples are taken.
High sample rate = larger file size, better quality.
JPEG
GIF
PNG
Compression
Lossy - adjustable compression
Lossless (if used correctly)
level
Lossless
Colour depth
24 bit
(16 777 216 colours)
8 bit
(256 colours)
24 bit
(16 777 216 colours)
Transparency
None
Basic
(pixels can be transparent or
opaque)
8-bit transparency – 256
different levels of opacity
Animation
None
Yes!
None
MP3
WAV
Compression
Lossy - adjustable compression level
Uncompressed
Quality
Dependent on compression level - from
128Kbps downwards you’re likely to notice the High quality
difference in quality
File size
Small, hence its popularity
Large (because it hasn’t been compressed!)
Download