4. Representing Data Flashcards
How do you convert from denary to binary?
Keep subtracting number by biggest base 2 that goes into it. Base 2’s that go in are 1’s in binary column.
Eg. 12 - 8 = 4
4-4 = 0
1’s in 8 and 4 column
How do you add binary?
1+1 = 10 (carry the 1) 0+1 = 1 0+0 = 0
What is it called when result of addition exceeds available space?
Overflow
Why is hexadecimal used?
What does it look like
Represents 16 values instead of 2 of binary, so easier to remember for programmers
0-9 and then A to F
How do you convert between hexadecimal and denary?
Put each digit in base 16 columns
Multiply digit by the base 16
Eg. 27 = 216 + 71
How do you convert denary to hexadecimal?
Keep dividing by 16 and record remainders
Eg. 45/16 = 2 remainder 13
2/16 = 0 remainder 2
=2D (last to first)
How do you convert from binary to hexadecimal?
Split split into nibbles
Value of each nibble is one digit of hexadecimal
How do you convert from hexadecimal to binary?
Replace each hex digit with binary nibble
Work out denary then binary
What is difference between ASCII and Unicode character set?
ASCII 7 bit (128 characters) or extended 8 bit (252 char)
Unicode 16 bit (65 000 char) or 32 (4 billion)
Unicode can include specialist symbols and multiple languages, keep 128 characters of ASCII so ASCII is subset of Unicode
What is a character set?
List of codes that match characters
What happens if you sort the list ‘Gorilla’, ‘bear’, ‘Elephant’, ‘Cat’ and ‘dog’ in a program using ASCII (or Unicode) as character set?
Cat Elephant Gorilla bear dog (as A first and z last)
What is metadata?
Data about the data eg. Of image
How many colours can 1-16 bits represent
1 bit- two (2^1) 2 bits- four(2^2) 4 bits- sixteen (2^4)etc. 8 bits- 256 16 bits- 65 536
What is the colour depth? Units?
Names?
Number of bits in a pixel (bpp)
16 bpp = high colour
24 bpp = true colour
32 bpp = deep colour
What is the resolution? Units?
Number of pixels in a unit (dpi)
What does sound metadata store?
Audio codec and sample rate
How is sound interpreted by computer?
Sound analogue, digitally sampled by computer at the sample rate
What happens when sample rate is low?
Few samples taken
Poor match between original sound and sampled sound
Small file size required
What is the bit rate (for sound)
What does higher bit rate mean
Amount of space used for each sample
Higher bit rate:
More accurate sampling, better quality
More data, larger file size
What is the bit rate for MP3 and CD?
128 Kbits/s
1411.2 Kbits/s
What is instruction made up of?
Operator- instruction/function
Operand- data
How does computer tell between operator and Operand?
They are fetched at different times in fetch execute cycle
What is accumulator?
Special register in CPU, stores results of calculations
What is the order of bits/bytes etc.
4 bits - 1 nibble 8 bits- 1 byte 1024 bytes - 1 kilobyte 1024 kilobytes - 1 megabyte 1024 megabytes - 1 gigabyte 1024 gigabytes - 1 terabyte