Self Modifying 2D Turing Automata
Overview
2D turing machines with 4 possible symbols per space were made. Their state tables were stored in the 'tape' that was used to run the programs, thus allowing self modification. Several of these machines were laid out in the same grid representing the 'tape', and allowed to travel anywhere, modifying themselves or others.
Algorithm
The algorithm is simple. A machine is represented by a 16x16 state table. The columns correspond to the symbols, which also have a direction(More on that later):
- α(0) -- Displayed as Red, moves Up
- β(1) -- Displayed as Green, moves Down
- γ(2) -- Displayed as Blue, moves Left
- δ(3) -- Displayed as White, moves Right
Also since there are 4 symbols we can use each one to represent which direction to move on the 'tape'. We end up with each row in the table as:
| State | (α) Direction | (α) New Symbol | (α) New State(m) | (α) New State(n) | (β) Direction | ... | (δ) New State(m) | (δ) New State(n) |
A lookup based on the current state and symbol underneath is then easily performed. For the actual implementation the state tables and the grid were seeded with random numbers.
Pictures
Start state for one of the runs (They all look similar starting out, since it's random):
A few end state pictures:


Videos
Click images below for timelapsed video:


Code
turingAutomata.pde -- You can set the number of individuals (Must be square) and the grid display size up top, but don't have to.Conclusion
These turned out pretty interesting. They always seem to end up in a steady state of repeated behaviour, usually 'trains' moving around the screen. I've seen a few interesting things happen, such as piston motions, , and really close timing ( moving horizontal chains with small breaks, having diaganol chains going through multiple at once).
Also weird is that it almost always (Roughly 90% of the time) tends towards 2 colors at the end. Also, there is always a dominant color, which makes some sense...I guess. I have alot of other stuff I want to try with them, but I first needed to make sure the basic design worked out.
Comments(0)
2009-12-20 05:05:24
Add your comment:
Hardware
Software
- TAIM (Alpha Version): GHCI integration with vim
- CheaTorrent -- An evil BitTorrent client
- Self Modifying 2D Turing Automata
- Competing Conway Life Automata
- X11 Timelapse Desktop Video
- Colored Wolfram Automata With Sound Input
- Pseudo Video Feedback in Processing
- Haskell Cipher Saber
- Illegal FIlenames -- Windows and *nix
- Simple Perl SDL Music Keyboard (Updated)
- Image to Spectrogram
- Pastebin Hell
- OMGWTFRNG (OWR)
- OTP Enhancement : Failure Report
- Java Network File Transfer Tool
- AES Encrypted Filesystem Speeds
- Dual Message Encryption
- PHP Website
- Mp3 Splitting Script
- Random Obfuscation Tool
- Filesystem Speed Comparisons
- Java Based Web Server GUI