Jump to content

data compression

Recommended Posts

maybe, it would be possible, to create a codec that will take fragments of the file, calculate them and divide them by some number with flag control and multiple them back at the client so for example, instead of sending a 11101010 (234) it will send a 11010 (234/9=26).

by creating a matrix at the host, each number will have it own reference by a 8bit to 5bit attribution (exp.) then, it would multiple it back by this matrix at the client attaching it back to the file.

if the data is already at it's base (i.e 26), the host will attach a cancel flag to it.

all the work will be made by the processor and will create up to 30% compression.

Link to comment
Share on other sites

that's bullshit!!

x>128 than -128 gives u 7 bits instead of 8 at maximum x<128 than -64 etc.

or else it is counted by bytes and then it's not usefull counting the flags.

u need it to catch 2 bytes instead of 4 & byte instead of 2.

lets take even numbers, 32b - 4294967296 divide it by 2 etc. add flag for number of devides,

until 32 times,

it can go till it's 2 and with 5bits reserved for flags that can save us 3 bytes of data!!

take odd numbers and devide them by 3, add the 5 bits & 1 bit for odd/even determination..

Link to comment
Share on other sites

about prime numbers, when u get to such problem, one can minus one them and then divide, adding a -1 flag at the second byte.

but it won't work anyhow,

after rethinking it,

if we'll take some number - 4,152,405,300 / 2 ->

2,076,302,650/2 -> 1,038,151,325.

there is no way afterwards.

for some conclusion -

a bit algorithm, is probably inefficient, as bits are compressed anyway, it might seem obvious for some who are femiliar with the subject, but not for all..

the most compressed scheme for 256 options, is 8 bits,

65536 for 16 and so on.

the algorithm, might work, but it will be limited only for X exponented numbers,

which is good, for only 32-8=24*X posibilities eventually!

the only compression algorithms possible, is probably at the ASCI level,

such as the lz77&78 improvements and on.

it is nice testing things,

seeing where it is possible to go ;).

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...