Nanopond: A Very Tiny Artificial Life VM

What is it?

Nanopond is a "corewar style" evolvable instruction set based virtual machine written in C. It is similar in design to Tierra and Avida but considerably smaller and simpler. Version 1.0 weighs in at only 840 lines of C code, the majority of which are comments! It is very highly optimized and supports simple color visualization using the SDL (Simple Directmedia Layer) library.

Despite it's small size, Nanopond exhibits some striking evolutionary behaviors. Run it for a while and take a look, or take a look at a movie of it running for about eight hours on a very fast machine.

Nanopond was written by Adam Ierymenko and is released under the GNU GPL.

Source Code and Binaries

Version 1.9

Version 1.9 fixes a subtile bug in version 1.7 in the handling of LOOP/REP instructions that was found by user Sotek. It also adds a bunch of enhancements suggested by Christoph Groth such as: a better color coding algorithm, multiple color coding algorithms (right click to change), left click to save genome under cursor (although this doesn't work all that well unless you are quick), and some speed optimizations. Cells with generations less than 2 are also no longer shown, which removes a lot of background noise from the visualization and permits the emergence of order to be seen more clearly.

Version 1.7

Version 1.7 adds many improvements including the Mersenne Twister random number generator (which is much faster and has a much longer period), more statistics, probabilistic permission behavior, and a slightly different instruction set. This instruction set implements the SHARE instruction developed by Christoph Groth and documented in this blog entry. It also implements KILL, which is a variation of the old EAT instruction. So, in a sense, it is a hybrid between Christoph Groth's SHARE contribution and the original EAT mechanism. This permits both symbiotic behavior and predation. Version 1.7 exhibits even more striking behaviors than version 1.0. Read the source for even more changes and more details.

Version 1.0

Version 1.0 is the original version and is the smallest and simplest. It is kept here for historical reasons.

  • nanopond.c - C source code (you may have to right click and "Save As" to save it to disk)
  • nanopond.c colorized HTML - Colorized human-readable HTML version of version 1.0 source code.
  • nanopond.exe - Win32 binary compiled with default options, generously contributed by Mike Bolaris (thanks!)