Click here to Skip to main content
11,932,681 members (55,763 online)
Click here to Skip to main content
Add your own
alternative version

Tagged as


10 bookmarked

LZW Compression Algorithm Implemented in Java

, 13 Aug 2006 CPOL
Rate this:
Please Sign up or sign in to vote.
This article provides an implementation of the LZW compression algorithm in Java


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.


This implementation is actually based on the C version of the implementation by Mark Nelson at Please refer to this website for further details about the algorithm. The Java adaptation is designed to work for ASCII encoded text files.


  • 13th August, 2006: Initial post


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Web Developer
Singapore Singapore
No Biography provided

You may also be interested in...

Comments and Discussions

GeneralJ2ME for LZW Pin
fur12820-Mar-07 5:32
memberfur12820-Mar-07 5:32 
GeneralRe: J2ME for LZW Pin
ed welch3-Jun-07 8:47
membered welch3-Jun-07 8:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.151126.1 | Last Updated 13 Aug 2006
Article Copyright 2006 by fahadkhowaja
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid