1/52
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
binary is
Base-2 number system using 0 and 1.
denary is
Base-10 system using 0-9
1 byte can represent
2^8
2^ 8 (bits)
can represent numbers between 0 & 255 = 256 no, in total
Hexadecimal is
Base-16 system.
0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
What is hexadecimal used for?
- address memory locations in computers
- easier to identify and locate data in memory
Advantages of hexadecimal
simpler to remember, quicker to write, easy to convert between hex & binary
Binary addition rules
0 + 0 = 0
0 + 1 = 1
1 + 1 = 0 (carry 1)
1 + 1 + 1 = 1 (carry 1)
ASCII
encodes 128 characters into 7-bit binary codes
A - Z: 065 - 090
a - z: 097 - 122
0 - 9: 048 - 057
space: 032
Extended ASCII
256 characters encoded.
8-bit character code
Disadvantages of ASCII
- Can' do arithmetic with characters
- if character represents a no., it must be converted to an integer before any arithmetic can be carried out
Unicode
- represents characters of all languages of the world.
- 2^16 and 2^32
- uses same codes as ASCII up to 127
Types of image file formats:
Bitmap image file format, vector image file format
types of bitmap image file formats
BMP, JPG, GIF, PNG, TIFF
types of vector image file formats
SVG
bitmap images
made up of pixels.
each pixel is a single colour and given a binary value which represents that colour
Image resolution
resolution is the concentration of pixels within a specific area.
area defined by image width and height in pixels.
Creating an image
1 = black
0 = white
Increasing the number of colours
more bits per pixel = more colour combinations
Higher bit depth
ex = 2^8
higher bit depth gives a greater range of colour and better quality of images
Higher colour depth
higher colour depth affects number of colours it can display
How does the number of colours affect the file size?
An increase in the number of colours that are used in an image (bit depth) will increase the file size.
How does the size of image affect the file size?
Increased no. of pixels in image, increases file size.
What are pbm monochrome images?
Portable bitmap images, use 0 for white, 1 for black. Monochrome image can be represents in binary as a bit pattern
Calculating image size in bits
width x height x colour depth
Calculating image size in bytes
width x height x colour depth/ 8
Calculating image size in MB
width x height x colour depth /8000,000
Sample resolution is
no. of bits used to store each sample.
Less accurately represented with 2-bit sample resolution, better in 4-bit sample resolution
2^2 = 4 -1 = 3
2^4 = 16 -1 = 15 colours
Number of bits used per sample
enables height of the wave to be more accurately measured but increases file size.
Sample rate
frequency/sample rate per second affects level of detail in digital representation. Greater the frequency, greater the accuracy & file size.
What are hertz?
Unit of frequency. Sample rate measured in Hz.
Calculating sound files sizes
file size (bits) = sampling rate x resolution x duration (s)
Recording quality of sound
recording quality improves more frequently we sample the sound, the more accurately we record the wave height.
How can we improve recording quality?
increasing sample rate/frequency, recording more data points. Increasing bit rate improves accuracy of each data point
What is bit rate?
storage of the resulting files and how large those files are.
What is image metadata?
information about data, includes colour depth in bits per pixel, resolution, date created, author.
What are sound waves?
Analogue; continuously changing. Has to be stored as a series of binary numbers. Sound digitalised by repeatedly measuring & recording sound waves.
How are Analogue sound waves converted into Digital
- analogue sound wave received by microphone.
- Converted into electrical analogue signal
- Signal amplitude measured at regular intervals
- Values rounded to a level
- Values stored as series of binary numbers
What is a sound sample?
a measurement of amplitude of a sound wave at a given time.
Sound is sampled using a sample resolution (bit depth) and sampling rate.
Lossy compression in sounds
removes sound we can't easily hear, leaves out some data from original; negatively affects sound quality
Lossless compression in sounds
able to reduce file size when compressed but does not lose any information.
Compression definition
algorithm which reduces file sizes
Decompression definition
process where compressed data is restored to it's original format.
Lossy compression in images
results in small mistakes known as digital artefacts. Blocks as a result from lossy compression.
Lossless compression in images
doesn't lose original data. Finds groups of repeating data & records it along with the no. of repetitions.
ex - run length encoding
Run length encoding
lossless compression. Uses frequency/data pairs to encode each run length of the same coloured pixels.
Lossless text compression
repeated patterns in original text. Encodes each pattern in a dictionary.
Dictionary compression example
'An eye for an eye, a tooth for a tooth.'
each word has its own binary value.
38 characters including spaces= 38 bytes.
using the "table" with binary values, there are 48 bits
48 bits= 6 bytes
6/38 x 100 = 15.7% of original size
Huffman trees
analyses frequency with characters in a body of text are used. DO A PRACTISE QUESTION ON THIS.
Example of a huffman tree
'She sells sea shells'
each letter has its own assigned binary value.
Using the bits (the binary value of the entire thing) = 49 bits.
20 characters including spaces.
7-bit ASCII code = 7 x 20 = 140 bits
49/140 x 100 = 35% of original size
Benefits of compression
Smaller files, faster transmission time. reduces download times of video/bandwidth, sound and image files. reduces space of disk/servers.
Buffering
download speed is slower than the playback speed
Types of lossy compression file formats
JPEG; photos , MP4; videos , MP3; music
Types of lossless compression file formats
PNG; images , ZIP; documents , GIF; images/animation , FLAC/ALAC; music