PDA

View Full Version : Is this idea even feasible?



Peegee
09-11-2004, 08:31 AM
As I understand it, a file is basically a huge string of binary digits. If you take the sum of these digits you get a number. Here's my possibly illogical/irrational/nonsensical idea: take the huge 'number' and somehow convert it into an equation or something. Then have (any) computer calculate said equation, and write out the output in binary form, on the disk drive.

If anything I said even made sense, it should 'copy' the original file into other computers. If this could potentially work, a problem I came up with is that variable size isn't really that big (is it long or float or something else that's the longest? And it's only like 2^32 bits?).

Could this even work? I've been thinking about this without research for a while, and it's bugging me. Just a 'PG I'm stealing your idea' or 'PG you're stupid' (a bit more verbose actually) would suffice.

crono_logical
09-11-2004, 10:37 AM
You'll have to do something more complicated than just summing the bytes in a file, otherwise for any given number, you don't know the file length, plus there will be many possible resulting files that will sum to make your given number, e.g. a file consisting of a single byte of value 80 will give the same sum as a file of two bytes where both bytes are 40 :p Essentially though, you're just talking about a manner of file compression :p

Dr Unne
09-11-2004, 04:34 PM
Darn that pesky commutative property of addition. Treating a file as a huge number and doing math on it IS used for some things though. That's how file integrity is checked using hashes like MD5. But they do more than just addition.