Questions tagged [lempel-ziv]

9 questions
7
votes
1 answer

LZ-type compression with a limited recursion depth

I would like to begin by apologizing. I am not a computer scientist, so my use of terminology will be off. I came across an interesting problem, which I believe to be pretty hard and would love to get references or any other advice to know what to…
introspec
  • 213
  • 1
  • 6
6
votes
2 answers

Behavior of iterative application of LZ77

I have been experimenting with LZ77 (naively $O(n^2)$ runtime, infinite window). Applying it to the 7th Fibonacci word $abaababaabaab$ yields the correct LZ factorization: $\qquad a,b,a,aba,baaba,ab$. My question is about the behavior of LZ77 if we…
5
votes
2 answers

Huffman Coding vs LZW Algorithm

I'm trying to understand comparisons between the two. Is there ever a case where is it better to use Huffman Coding over LZW? Could the compression ratio for Huffman ever surpass that of LZW? Thanks!
Sheila
  • 59
  • 1
  • 1
  • 2
2
votes
2 answers

How optimal is Lempel-Ziv at reaching the Shannon limit?

I find this a bit difficult to describe, but I am interested in the following idea : The LZ algorithm factors (verb) an input stream into adjacent factors, these are by definition the maximal prefixes of the piece of text that occur in the previous…
2
votes
1 answer

LZW decoding process

I'm trying to understand how LZW decodes a string. For example suppose that we have a dictionary where: a=0 b=1 and we have to encode the string "aabbabaabb", so the output of the encoding process (if I have not made mistakes) produces the string…
abc
  • 1,675
  • 2
  • 12
  • 22
1
vote
1 answer

Lempel-Zilv-Welch Algorithm Decoding Question

Hello i am studying about LZW algorithm by watching this video: https://www.youtube.com/watch?v=j2HSd3HCpDs&t=481s I couldnt fully understand decoding process. At current 258,how does 116 come at add to dictionary part ? At current 256,how does 101…
1
vote
1 answer

Number of phrases of LZ compression

It is known that for the number $c(n)$ of phrases / tupel of the LZ compression for binary words of length $n$ the following relation holds: $$c(n)\leq\frac{n}{(1-\epsilon_n)\log_2 n}$$ With $\epsilon_n\to 0$ for $n\to\infty$. The proof is made in…
Danny
  • 1,004
  • 5
  • 10
1
vote
2 answers

LZW with dictionary clearing

How does LZW decompress data with dictionary clearing/flushing? I understand that a space is reserved in the dictionary that represents a clear code (usually 256), but how is this code actually used when compressing and decompressing data? My…
0
votes
0 answers

How to compress highly correlated arrays?

I want to write a compression algorithm for a specific use case that I have. I have many arrays which are for the most part, very similar. Each value in the array is an integer and is related to the corresponding value in the previous array. These…