I am sure all of you have downloaded a zip file? If you have done that, you have enjoyed the benefits of file compression. A lot of the files you download from the internet are zipped. Before you are able to extract the files from the folder to make them usable, you have to unzip the folder. Sometimes, the program does that for you automatically. The purpose of file compression is obvious…space or rather how much it saves for you? What zipping does is reduce the amount of bits and bytes in the containing folder.
Most computer files have the same information listed over and over and over again. Computer files are fairly redundant in that sense… File compression simply makes them more efficient by removing the redundancies. Rather than list the same exact piece of information over and over again, the file compression program lists that information only once, and then just refers back to it whenever it appears again in the original file. In this way, you can make your original file smaller, email it to your client, and then have it turn into an exact copy of the original on the other end.
File compression software works off a ‘library’ that contains ‘dictionaries’. Each piece of information in the file is assigned a specific number and the program then replaces all of the mentions of that piece of information with the corresponding entry in its ‘dictionary’. That way, it simply writes down that short number instead of the whole piece of information, which could be very long. Basically, it codes your data.
You could actually recreate the compressed file on your own (not that you would ever have the time) if you knew which ‘dictionary’ was used to compress the message, much like using a decoder ring when you were a kid to spell out your top secret message.
File compression software also looks for patterns that get repeated. If a pattern is found and it is big enough or common enough, then that pattern will also be assigned number from the ‘dictionary’, allowing larger amounts of information to be represented by a single value.
How small your file can compress to depends on the file type, file size and the compression entered. Most text files are easily compressible. On the other hand, files like mp3s do not contain as many redundancies (If you ask me, some songs should just compressed into nothing.) and therefore, cannot be compressed as much. Either way, you and I would be pretty stuck without this handy invention.
Over and out