On 7/6/2010 3:28 PM, Charles Mills wrote:
Can't the "lengthens" case be limited in theory to "lengthens by one bit" because we can simply add a flag bit for compressed/not compressed. (Practically speaking, it would probably be one byte, allowing for additional information such as compression method or options.)
In the case of Wylbur (my first brush with routine compression) the original version compressed only blanks, and for the occasional card image wound up with a longer record (up to 6 bytes for a card image). Later versions added an uncompressed bit, but it didn't take extra space, as there already was a flag byte.
BTW, I think your "50%" was perhaps meant as a theoretical example, not the real life case. I think most compression methods, when applied to appropriate (photos for JPEG, run-length for character data, etc.) files (other than those chosen as special cases) will do a lot better than shorten 50% of the files.
I consider the 50% to be a practical lower limit; any less, and the method would not be considered? But it reminds me of an interesting article I read in the eighties - the author announced a new algorithm for PCs that compressed any file into eleven characters, allowing the file to be stored as its file name. Unfortunately it was in the April (1) edition of PC magazine <g>
Gerhard Postpischil Bradford, VT ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html

