Copy files/programs from paper ?!

Hi experts, I want to address you a very interesting idea and question at the same time ! :

Can it be possible to encode any file, then get that long code, print it up and then next time when you will want that file on your computer or other computer, make a program that will decode that text and clone it there ?

- the one and only problem is that the generated code of the encoded file is very very long, so even with the smallest text fond, a code of 1MB file won't fit on a A4 paper.

Anyone knows how to compress the text or any other trick ? Thankyou !
- even the QR codes can't compress data more than they are :(
Who is Participating?

Improve company productivity with a Business Account.Sign Up

d-glitchConnect With a Mentor Commented:
Using paper as a data storage medium is not a new idea:

But it is limited, and the limits are well understood.  From the Wikipedia article above...
   The limits of data storage depend on the technology to write and read such data.
   For example, an 8"x10" 300dpi 8-bit greyscale image map contains 7.2 megabytes of
   data—assuming a scanner can accurately reproduce the printed image to that
   resolution and color depth, and a program can accurately interpret such an image.

Anyone who want to use new types of storage media will need to invest in appropriate readers.  That has been true for punch cards, paper tape, floppy drives, and microfiche.

If you would prefer to limit the new media to commonly available scanners, you will have to live with significant performance penalties.
If you can print clearly at 120 dots per cm, you can put enough information on a A4 pape to reproduce a 1MB file
Don ThomsonCommented:
Not sure what it is that you are trying to do?

If you encode a file and print it out, you may run into a situation where the printer characters from the encoded binary file may use non-printable characters.

If this is the case, then nothing you do to reconstruct the file will work unless you trick it into printing only printable ASCII characters. This would involve writing a program that parsed through the original binary code and verified that each byte was a printable character.  The first pass would have to identify all non-printable characters and then do a substitution  of the non-printable character to a two byte sequence that would identify it as a substituted character and have some type of sequence at the beginning or end that would allow you to reconstruct it.

What is the purpose of printing it out? You would have to scan it back in and do a optical character read on each page in order to get it back into machine readable code

Much easier to simply Zip it up with password control
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

AlexMertAuthor Commented:
@ozo, :), I gave 1MB file as a small example, small at dimension, because Im thinking at 40MB + to fit half a A4 page. That would be reliable !

@DTHConsulting, as far as I know Hex or Base64 encoding creates printable ASCII characters, so even a human can type them from the paper, this won't be a problem, like the length of the code !

And is useless if you give me other 'off-topic' solutions, because I could very easily send a file or text over the internet, the main idea is if it is possible and how to do what I described in the OP, since is a very intersting and I think,not-yet-done concept .

Don ThomsonCommented:
Once it's on paper - what method would you be looking at to get it back into the PC? If you are thinking of Scanning or OCR - the size of the font would have to be large enough to be recognized.

Can you give an example of what you are looking at accomplishing by this exercise?
AlexMertAuthor Commented:
@DTHConsulting yes you are right and because I need to print the code, I need to scan the text with an OCR program, thus the text needs to fit on paper, be small but STILL recognisable. => thats why I need to encode into a smaller one to fit and be visible on page !

Many can be accomplished with this, but I really need this
The best typist in the world would have difficulty maintaining 12 characters per second for long periods, especially with random, apparently meaningless characters.
At 12 characters per second, 40MB would take the better part of a year to type, at 40 hours per week non-stop.
It may be difficult to find anyone willing to do this, so it may be more practical to use optical scanning..
You'd need 740dpc resolution to get 40MB of information onto one side of a A4 page.
While 40000dpc printers exist, they don't print on paper, and even at 4000 or 740, you'd need special paper to keep the dots from bleeding into each other.
You may be able to do a little better using colours, and if it's read by a machine rather than by a human, then you need not be limited to 3 primary colours.
AlexMertAuthor Commented:
@ozo, if I can find an algorithm to shrink any text that contains 0-9  and a-f ( like hex encoding generates ) then will be a small text at the end, then take that back and do the same and so on after remains a little text that can be typed by humans. But I need to find that algorithm that will know from a little text what will generate exactly
- it seems that we would need a genius mind for this I think...
QR codes (or something similar) are your best idea. ASCII characters are a terrible idea because you waste a lot of space limiting yourself even to 256 characters in the same space.

Compression isn't going to be able to magically keep making things smaller and smaller. Compress the file as well as you can using gzip or something (if it's audio or video then it's already compressed about as much as it can be). Even if it's just text, you probably won't do any better than 75% reduction.

The best solution would be to print it in binary (black is 0, white is 1) like a QR code at the highest resolution possible. (or use color if you can as Ozo mentioned) but it's still going to be fairly large for a 1 MB file. There's no way around that. That's probably why no one uses that kind of thing.
mccarlIT Business Systems Analyst / Software DeveloperCommented:
- it seems that we would need a genius mind for this I think...
No, in fact I think you are needing someone who can manipulate the laws of physics, laws of the universe, etc
Think about compression like this.
If you have 10 characters from a-z, then there are 26^10 possible combinations of what they could be.
If you want to be able to compress that, you need 26^10 different codes. If you are just using a-z for the codes, then you need 10 characters. You can't compress it at all.

That is always the case.

Unless you can use more characters in the code then you have in the original or if you know something about what to expect then you can't compress it any more.
All you have to do is count the bits.

40 megabytes is 40x8 ==> 320 megabits
A4 paper is 21*30 ==> 630 cm²

So you need 320/630  ==> 500 kilobits per square centimeter.

That gives a dot pitch of 700 dpc.   The same number that ozo suggested earlier.

The best you could hope to do, is use a Zip program to compress your original file and encode the binary result as dots.  This might not work on paper, but it could work on good old-fashioned microfilm.  You would also probably have to include some sort of error correction.
AlexMertAuthor Commented:
@mccarl, I think you're pretty right :( in the real life you can't make from something less, something more.

@TommySzlapski, I was thinking about that too ! For example take the first 2 characters and assign a unique symbol to it ( put all those symbols in a table corresponding to each char and nr combination lol ). Then the text will be half shorter, but this have a big - . This depends by a pretty big symbol database that should be downloaded and I don't want this. An algorithm would 'resolve itself' what characters will result, but I don't think this is possible ...

@d-glitch, I want and other people to be able to do this thing so I don't think all the people will have microfilms in their home :/ Or for example I want to transfer files this way on my phone , so it can't see all the minuscule dots, but if it were an algo, even a little database that would need would be oke.
This depends by a pretty big symbol database that should be downloaded and I don't want this.

Or you could use a simple database that has all the characters possible (by using binary like a QR code). Which is what we've been suggesting. All people would need to have or download would be the software that can read the black and white dots and translate it to binary (fairly simple).

But still, it would not be very efficient and you would have a high risk of data corruption especially if you tried to use a high resolution.
AlexMertAuthor Commented:
@TommySzalapski, yes right they must download the progr that will decode the text any way, and if the progr would depend by a 10MB database would be ok, but that database won't help too much if the file it needs to encode is too big, the code will be very long and that symbol db won't have any effect when shrinking the code in half, because still long will remain :(

And do you mean that big QR pics can corrupt or have broken data in them?
A bigger character set doesn't help if it requires more pixels to be readable,
A bigger character set also makes typing slower.  You'd be better off with a small character set that can be rendered in a smaller font.
You'd also want to add error correction coding to catch the inevitable mistakes that any human would produce given such a mind numbingly tedious task.
Even with optical scanning, error correction would be a good idea for printing and registration glitches.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.