"Once a Darwinian process gets going in a world, it has an open-ended power to generate surprising consequences: us, for example"
Richard Dawkins, author of The Blind Watchmaker
This is a Javascript implementation of Richard Dawkins' famous Biomorphs. Dawkins first described Biomorphs in his book "The Blind Watchmaker" and this implementation is loosely based on his original description.
Each biomorph has of a genome of 11 integers with possible values in the interval [0,20]. Each Biomorph is drawn as a binary tree. The drawing algorithm is influenced by the genes of the individual Biomorph being drawn. For instance, the first gene affects the depth of the tree, three of the genes affect the color of each level, and other genes affect the length of the segments used to draw each level. Look at the code for more detail.
The Biomorphs are organized to allow easy surfing through Biomorph space. The Biomorph in the center is the parent and those surrounding it are its offspring: copies which have undergone minor mutations. Selecting one of these offspring by clicking on it will make it the parent of the next generation and its mutated offspring will be shown.
Biomorphs implement a simple model of evolution. In this model, the user selects the individual that survives to the next generation purely for aesthetic reasons. Fitness is the degree to which the Biomorph pleases the eye of the user.
The "Random Monster" button at the bottom will create a parent with a random genome and show its offspring.
Some biomorphs may resemble insects, microorganizms, and all kinds of interesting objects.
I wrote a Biomorphs implementation over a decade ago when I was in college. It was a Java applet, click here to see it. I get occasional email messages about that implementation and requests for source code. I'm embarrassed to admit that I lost the source code to that implementation long ago. I always wanted to improve on it and recently had a free afternoon so I rebuilt it using Javascript and the canvas element. This implementation came together a lot faster than the original... partly because Javascript makes it easy to build software like this and partly because I've had 12 years of practice since that afternoon in Cal Poly's lab when I built the first implementation.
Feel free to grab the source code. I'm distributing it using the MIT license. If you make it better please send me a copy of your changes and I'll post them here (hernan @ well . com).