random image generator
a website trying to generate an image on the fly!
- Site:
• http://diaf.co.uk/
- Example:

- What it does
Building on the infinite monkey theorem this site is attempting to create an image on the fly using a random number generator to choose the pixel values.
The chances of it generating anything at all are pretty slim, but it would be nice if it did!
- How it works
Each time the website is viewed a random image is generated, this is done using a Perl script which creates a pnm file which is then converted to a jpeg. The Perl script is passed a number with which to seed the random number generator, this number is generated using the index of a mysql table. The reason for this is to make sure that the images generated are never the same.
Once the random number generator is seeded the Perl script goes over each pixel and generates a number between 0 and 16. This 16 bit image with dimensions of 100 x 100 pixels leads to the number of possible outputs being around 1.2 x 10^12000. The actual number can be seen on the website in the 'how it works' section.