View Single Post
  #41   Spotlight this post!  
Unread 08-09-2004, 18:06
ThomasTuttle ThomasTuttle is offline
2004 Beantown Blitz Scorekeeper 1
#0125 (NU-TRONS)
Team Role: Student
 
Join Date: Jan 2003
Location: Boston, MA
Posts: 19
ThomasTuttle is an unknown quantity at this point
Send a message via AIM to ThomasTuttle Send a message via MSN to ThomasTuttle Send a message via Yahoo to ThomasTuttle
Re: New compression method

You said it can eventually compress any file to 508-515 bytes? Okay, let's assume you can do 512 for simplicity (it really doesn't matter). This can't hold true for every file, since with 512 bytes there are only so many files you can make. (1044388881413152506691752710716624382579964249047 3837803842334832839\
53907971557456848826811934997558340890106714439262 837987573438185793\
60726323608785136527794595697654370999834036159013 438371831442807001\
18559462263763188393977127456723346843445866174968 079087058037040712\
84048740118609114467977783598029006686938976881787 785946905630190260\
94059957945343282346930302669644305902501597239986 771421554169383555\
98852914863182379144344967340878118726394964751001 890413490084170616\
75093668333850551032972088269550769983616369411933 015213796825837188\
09183365675122131849284636812555022599830041234478 486259567449219461\
70238065059132456108257318353800876086221028342701 976982023131690176\
78006675195485079921636419370285375124784014907159 135459982790513399\
61155179427110683113409058427288427979155484978295 432353451706522326\
90613949059876930021229633956877828789484406160074 129456749198230505\
71642377154816321380631045902916136926708342856440 730447899971901781\
46576347322385026725305989979599609079946920177462 481771844986745565\
92501783290704731194331655508075682218465717463732 968849128195203174\
57002440926616910874148385078411929804522981857338 977648103126085903\
00130241346718972667321649151113160292078173803343 609024380470834040\
3154190336, in fact.)
So if you create a directory with every 513-byte file in existance (that's the above number times 8 files), it cannot be able to compress all of them to 512 bytes or less.
Furthermore, compressing random data is not feasible. Sure, you could try, and it might work sometimes, but, overall, any single string of bits will eventually appear, so you can't take advantage of a limited vocabulary in the file. Like if you tried to compress 2 bytes into one, it wouldn't work, since you would eventually have 65536 choices, which is back to the original 2 bytes.
In fact, I gave both gzip and bzip2 a chance, and so far, up to files of 64k, neither has averaged even one byte less than the original--in fact they are all larger!
But if you want me to test it, I would be glad to (I won't give away your program, don't worry...) I would really find it interesting if you can prove me and others wrong...