[Edu-sig] text compression as a learning tool

Daniel Yoo dyoo@hkn.eecs.berkeley.edu
Mon, 28 May 2001 18:20:32 -0700 (PDT)


On Mon, 28 May 2001, Timothy Wilson wrote:

> I'm trying to come up with some more comprehensive projects to supplement my
> Python class for next fall. I'm definitely going to do a little "clubhouse
> crypto" (thanks Kirby and Neal Stephenson for picquing my interest).
> 
> Before undertaking my own study of text/data compression, I'd like to get
> the opinions of the list members here about whether you think this could be
> an appropriate subject for beginning to intermediate Python programmers.

This sounds like a really fun subject!  Yes, it sounds very appropriate.

I've written a small module to implement the Sandorf cypher, which is
pretty fun to play with.  The Sandorf cypher description is here:

    http://acm.uva.es/p/v7/795.html

and this code:

    http://www.lowerstandard.com/python/sandorf.py

implements the encryption and decryption routines.



> Any particular references to compression algorithms or other background
> materials?


You may find this page useful:

    http://www.cs.sfu.ca/cs/CC/365/li/squeeze/

This page gives tutorials on lossless compression, including stuff on
huffman encoding and lzw.  Another fun project might be to implement
run-length encoding on black and white icons.