Introduction

I recently had the opportunity to look into compression for a project. I had to implement the Lempel-Ziv-Welch (LZW) algorithm for mobile phones in J2ME but before that, I implemented it in Java for testing purposes.

I wish to thank Mark Nelson for pointing out that the Unisys patent on this algorithm has expired, so there are fewer headaches in the use of this algorithm.

Description

This implementation is actually based on the C version of the implementation by Mark Nelson at http://marknelson.us/1989/10/01/lzw-data-compression/. Please refer to this website for further details about the algorithm. The Java adaptation is designed to work for ASCII encoded text files.

I've a final project of my college about implementing DMC (Dynamic Markov Compression) algorithm using Java (JSDk) and java J2me.

I've found the source of this algorithm (DMC), but it write using C version :
ftp://ftp.sac.sk/pub/sac/pack/dmc.zip --> I've using this, but it's more complex But when I'm trying it, it run well and give the good result.
ftp://ftp.sac.sk/pub/sac/pack/dmcsrc.zip --> I haven't try it. It contain only C file and I don't know how to do that...

And, I'm try to "translate" DMC of C version (according example of ftp://ftp.sac.sk/pub/sac/pack/dmc.zip), but it only run well at compression. It failed when decompression

But, I thinks, both of compression and decompression (of my script- DMC Java version-) is wrong. I judge that because when I'm compare the ouptput text file of DMC (C version) and dmc (java version), each of output text file contain the different character (Theory said that if it same algorithm, it must be the same output and also the same character in it)

If you want to know my source 9and also help me to solve this problem), the URL is :
http://www.2shared.com/file/5426100/bc28341d/all_DMC_file.html