Source coding Flashcards

1
Q

What is source coding?

A

Converting any type of data into a binary form.

e.g. Images, sound, text

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the equation to calculate the number of bits required for a source code?

A

2^L = M

M = Number of distinct characters
L = Number of bits
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is ASCII? What does it stand for?

A

American Standard Code for Information Interchange.

A stand source code for alphanumerical data exchange

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How can a protocol be synchronised?

A

We need to send code that that identifies the start and the end of a message

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is a fix length code?

A

The number of bits used for all symbols/data in a source code is the same.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a variable length code? What is the benefit?

A

The symbols/data that appears more often have fewer number of bits than symbols/data that appear less often. This can save data but requires a carefully designed source code specific to the overall data being sent.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is required to make a variable length source code?

A

The data needs to uniquely decodable. This can be achieved with prefix free code.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What does uniquely decodable mean?

A

When the variable length code data is put in series, you are able to decode it and identify each letter individually.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What does prefix free mean?

A

This means that when data is put in series you are able to decode it and identify each letter individually. This is required because there is no definition where the data for a single character/data begins and ends.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What algorithm can be used to make prefix free code? and how does it work?

A

The Huffman algorithm:

  1. List all the different bits of data with the frequency that they came up and put them in order from least frequent to most frequent. They all form nodes with a value given by their frequency.
  2. Combine the two top nodes to produce a new node with a new combined value. Re-insert this new node into the list of nodes still in order.
  3. Repeat combining nodes until a single node is left.
  4. This should form a tree diagram which can be followed to create a prefix free code.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How are binary values read from a Huffman algorithm?

A

Follow the tree diagram until you reach the data required.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is non-singular code?

A

This is when each character has a unique code assigned to it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are the two key factors that contribute to encoding-decoding overhead?

A

Synchronisation and exchange of encoding table

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Why use variable length codes?

A

To save data (compression)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly