You might want to look over at Bruce Schneier's web site
[1] for more information about the algorithm such as how to do it by hand with a deck of cards. Also on that site is his implementaion of the algorithm in Perl
[2] that they released (interestingly, they have the following - 'Note: only the Perl implementation has been tested by Counterpane.').
If you have not read Neal Stephenson's Cryptonomicon that this was developed for, I strongly recommend it as a good read.
[1]
http://www.counterpane.com/solitaire.html
[2]
http://www.counterpane.com/sol.pl