In this project, we generate graphics in a new way - not by programming explicit instructions of what to draw - but instead by specifying properties we'd like the drawings to have.

For example - suppose you'd like to create a texture which has an even 37% distribution of black pixels. While this property is easily described and easily tested for, it is by no means clear how to write a program to create it.

Instead we create a function, an objective function, which measures how well a prospective texture performs. We then try to find a texture which maximizes this function. Of course such a search is an expensive endeavor - we'll try to speed things along using a genetic algorithm. It's a trick we've learned from mother nature - she's been using it for millions of years.

Your first task is to invent new and interesting objective functions. When scoring a texture - remember to give as much "partial credit" as possible; this will help the GA find maximal solutions. Also remember to try mixing objectives - even conflicting objectives.

Secondly, you'll need to create an animation of the evolution of your favorite texture. This can be an animating GIF or MPEG, whichever you prefer. You may not want to generate frames for generations which don't change - or maybe you do.

Bundle up all your work into a neat little web page and send me the URL. Good luck. Here's the tarfile.

fade_objective() gives high scores to textures which have a high pixel density at the bottom of the texture, and a light density at the top.
strings_objective() prefers that a black pixel have no more than two black neighbors, and especially dislikes diagonal neighbors.
fadestrings_objective() returns strings_objective() * fade_objective(). Because fade tests global properties while strings tests local properties, they interact nicely.

(As an aside - notice that not only can textures be created in this way - so can complete computer programs. I like to call this technique programming by specification. Current computing power makes such techniques nearly useless today - but as Moore's law advances, and especially as quauntum computers are developed - I predict programming by specification will become the norm.)