Thread: Max. Compression that you have hard of?

  1. #1
    Registered User
    Join Date
    Apr 2005
    Posts
    1

    Lightbulb Max. Compression that you have hard of?

    I was just doing some research and wondering what would be the max. compression that you have heard of. Just more curios then anything else.

    codeflash

  2. #2
    Senior Member joshdick's Avatar
    Join Date
    Nov 2002
    Location
    Phildelphia, PA
    Posts
    1,146
    http://en.wikipedia.org/wiki/Data_compression

    There are a dozen or two different compression algorithms. Are you looking for lossless or lossy? What is it you're going to be encoding?

  3. #3
    Code Goddess Prelude's Avatar
    Join Date
    Sep 2001
    Posts
    9,897
    >what would be the max. compression that you have heard of
    100% compression:
    Code:
    #include <cstdio>
    #include <cstdlib>
    #include <iostream>
    #include <fstream>
    
    using namespace std;
    
    int main ( int argc, char *argv[] )
    {
      if ( argc < 2 ) {
        cerr<<"usage: compress <filename>"<<endl;
        return EXIT_FAILURE;
      }
    
      if ( remove ( argv[1] ) != 0 )
        return EXIT_FAILURE;
    
      return EXIT_SUCCESS;
    }
    My best code is written with the delete key.

  4. #4
    S Sang-drax's Avatar
    Join Date
    May 2002
    Location
    Göteborg, Sweden
    Posts
    2,072
    There are two kinds of compressions, lossy and lossless. If you compress using lossy compression there is no limit to how much you can compress your data (Prelude's example just throws the data away, which is 100% compression).
    If you want to be able to recreate the exact data (lossless) the maximum compression depends entirely on the type of data. 100 GB of only zeroes can be compressed to a few bytes, but purely random data cannot be compressed at all.
    Last edited by Sang-drax : Tomorrow at 02:21 AM. Reason: Time travelling

  5. #5
    Slave MadCow257's Avatar
    Join Date
    Jan 2005
    Posts
    735
    http://maximumcompression.com/

    EDIT
    I was just doing some research and wondering what would be the max. compression that you have heard of. Just more curios then anything else.
    On a less practical level, the maximum compression capable will converge on 100% for some data. Consider a run length encoder compressing a file containing a continous stream of millions of 'A' s
    Last edited by MadCow257; 04-07-2005 at 04:16 PM.

  6. #6
    Registered User
    Join Date
    Mar 2002
    Location
    South Africa
    Posts
    35
    I hesitate to post this, because I have nothing to substantiate it. I heard about a researcher that "folded" the data through "multiple dimensions" or somesuch. (Not sure how the hell thats supposed to work )

    Apparrantly he got VERY good results (so good that the telecommunications companies squashed the research - they were afraid of being put out of business by this technique).

    This, of course, is just hearsay. But interesting, nonetheless!
    I code.
    I think.
    Ergo, I think in code.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Find max profit among input salary
    By hlam in forum C Programming
    Replies: 8
    Last Post: 11-16-2008, 10:30 AM
  2. Max Min Problem
    By smithc2005 in forum C Programming
    Replies: 7
    Last Post: 10-22-2008, 10:38 AM
  3. Overwriting all in array, why?
    By guesst in forum C Programming
    Replies: 7
    Last Post: 10-09-2008, 05:56 PM
  4. hard disk serial number
    By vijayaroli in forum Windows Programming
    Replies: 1
    Last Post: 08-31-2006, 03:00 AM
  5. which hard drive to buy ? UATA or SATA
    By gemini_shooter in forum Tech Board
    Replies: 10
    Last Post: 08-24-2005, 08:16 PM