Patent ID: 7663512

Claim:
A decoder for decoding a message using an arbitrary-side growing (ASG) Huffman tree comprising a plurality of codewords and symbols, the decoder comprising: a database configured for storing a plurality of parameters corresponding to the ASG Huffman tree, wherein the ASG Huffman tree is divided into several sub-trees according to a Hashemian cut (HC) operation and a bits-pattern-Xor (BPX) operation, wherein the plurality of parameters comprises a bit pattern of a sub-tree divided according to the BPX operation and a code length of the bit pattern, wherein the bit pattern represents a path traversing the sub-tree; a processing module configured for receiving a bit stream corresponding to the ASG Huffman tree from an encoder; and a bit pattern matching module configured for selecting bits from the bit stream according to the code length of the bit pattern and decoding the selected bits into a symbol in the ASG Huffman tree by comparing the selected bits with the bit pattern.