ACB (Associative Coder of Buyanovsky)
Main features
- context compression method
- one-pass compression method
- adaptive compression method
- symetric compression method
- very efficient (better than RAR), fit to compression of text
- relatively slow
- precise details still not known
Description
Description of algorithm
- Current context is compared with items in dictionary (with their context part) (comparison from right to left).
- Actual content is compared with contents in dictionary (comparison from left to right).
- The triplet (d, count, ch) goes to the output.
- d - distance between the best context and the best content.
- count - number of matched symbols.
- ch - first unmatched symbol in look-ahead buffer.
- The dictionary is updated (new phrases are inserted, contents are updated).
- Look-ahead buffer is shifted for count + 1 positions to the right.
Structure of dictionary
- It consists of items made up of context and content.
- It keeps sorted history of all contexts and contents of source text.
- New entries are inserted to the position according to their lexographical order (comparison from right to left).
State of dictonary
- It is the same for compression and decompression.
- Directory is organized as a list of pointers to the text.
Characteristics of method
- Maximal length of context.
- Maxaximal length of content.
Coding output
- We can encode triplet (d, count, ch) for example by Huffman coding.
Pseudo-code
1: begin
2: initialize look-ahead buffer
3: while (!EOF) do
4: begin
5: int i = position of the best matching context in dictionary
6: int j = position of the best matching content in dictionary
7: int count = count of first matched chars in found content
8: char ch = first mismatching character
9: output(j-i, count, ch)
10: update of dictionary (insert new phrases, update contents)
11: shift look-ahead buffer by count + 1 positions to the right;
12: end
13: end
References
- D. Salomon: Data Compression - Springer, New York, 1997.
- G. Buyanovsky: Asociative coding - Monitor, 8:10-19, 1994.
- Josef Troch: ACB Algorithm.