문제

I have a file of 100 MB and it was compressed by huffman coding 20 times.

I want to draw a diagram for the changes of the size of the file while compressing it, so the x axis will have the number of compression times, and the y axis is the size of the file?

how it will be ?

도움이 되었습니까?

해결책

Your question seems unclear. Do you mean what would it roughly look like? Repeated compression on files has very steep diminishing returns. That is to say, the first compression will shrink it significantly, the second a little to none at all, and the subsequent tries will really not compress it at all, or possibly even get bigger. Compression is predicated on a lack of randomness, patterns, and being able to make those patterns represented with fewer bytes. After compression, files look more like random noise, so they are more difficult to compress.

Read through some of this for more information: http://mattmahoney.net/dc/dce.html#Section_11

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top