Patent attributes
Exponents, mantissas and signs of floating-point numbers are compressed in encoding groups. Differences between maximum exponents of encoding groups are encoded by exponent tokens selected from a code table. Each mantissa of an encoding group is encoded to a mantissa token having a length based on the maximum exponent. Signs are encoded directly or are compressed to produce sign tokens. Exponent tokens, mantissa tokens and sign tokens are packed in a compressed data packet. For decompression, the exponent tokens are decoded using the code table. The decoded exponent difference is added to a previous reconstructed maximum exponent to produce the reconstructed maximum exponent for the encoding group. The reconstructed maximum exponent is used to determine the length of the mantissa tokens that are decoded to produce the reconstructed mantissas for the encoding group. The reconstructed sign, reconstructed exponent and reconstructed mantissa are combined to form a reconstructed floating-point number.