Compression and Encryption Flashcards
(19 cards)
What is Lossy Compression?
- A type of compression algorithm
- Involves removing unnecessary data (e.g.: background noise) from a digital file in order to reduce its size
- This data is then permanently lost
What is Lossless Compression?
- A type of compression algorithm
- Reduces file sizes without sacrificing any significant information in the process
- No data is lost
- Can be RLE or Dictionary
What is Ciphertext?
- Text that has gone through a cipher to make it harder to read.
- Opposite of plain text
What is a Vernam Cipher?
- The Vernam cipher is an example of a one -time pad cipher.
- This means that each key should only ever be used once. * Additionally, itrequires the key to be random and at least as long as the plaintext that is to be encrypted.
What is a One Time Pad?
- An encryption technique that cannot be cracked but requires the use of a single-use pre-shared key that is larger than or equal to the size of the message being sent.
Aims of Compression?
Reduce the size of files
Reduce download times
Reduce storage requirements
Make best use of bandwidth
What does compression do?
Reduces the size of a file
Makes files quicker to transfer
Files take up less space in storage
What does Lossy Compression Do?
Some data is lost when the files is compressed
Reduces quality but also reduces file size
Suitable for images, audio and video
What do Lossless Compression do?
None of the original data is lost
The original file can be recreated when it is uncompressed
Suitable for executable files and documents.
Methods of Lossless Compression?
Dictionary Coding
Run-Length (RLE) Encoding
What is Dictionary Coding more suited for?
Ideal for compression of text-based documents
What is RLE more suited for?
Compression of Images, specifically Bitmap
What is Dictionary Coding?
Works by building an index visualized as a table
Every data item or entry is recorded alongside indexed reference
What is Run-Length Encoding
replaces repeating sequences of characters with a single character and a count of its occurrences.
For example an image with a colour depth of 1 (Black and White) may have a row of black pixels 5 black pixels followed by four white ones. This could be represented as 5B, 4W
This data is stored in frequency data pairs
What does a compressed file using Dictionary Coding consists of?
The Dictionary Index
The sequence of occurrences needed to recreate the original file.