Special

Introducing the “Welcome to Xojo” Bundle!

New to Xojo and looking for guidance? We've put together a terrific bundle to welcome you! Xojo Bundle

This bundle includes six back issues of the magazine -- all of year 15 in printed book and digital formats -- plus a one-year subscription so you'll be learning all about Xojo for the next year. It's the perfect way to get started programming with Xojo. And you save as much as $35 over the non-bundle price!

This offer is only available for a limited time as supplies are limited, so hurry today and order this special bundle before the offer goes away!

Article Preview


Buy Now

Issue 9.6

FEATURE

Using Simple to Make the Complex

Exploring Cellular Automata with Real Studio

Issue: 9.6 (September/October 2011)
Author: Johnathan Mercer
Author Bio: John Mercer is a predictive modeler working at World Vision, a Christian humanitarian organization dedicated to transforming the lives of the world's poorest children and families through community development, disaster relief and advocating as a voice for the poor.
Article Description: No description available.
Article Length (in bytes): 16,578
Starting Page Number: 33
Article Number: 9608
Resource File(s):

Download Icon 9608.zip Updated: 2011-09-02 00:15:35

Related Web Link(s):

http://mathworld.wolfram.com/CellularAutomaton.html
http://www.applelinks.com/rbu/026/

Excerpt of article text...

In this article we will feel some of the exhilaration the prodigy Stephen Wolfram must have felt when he realized that simple rules could produce complex phenomena. His conviction in the potential for this new approach to modeling nature compelled him through a decade of research that culminated in his book A New Kind of Science.

Stephen first became interested in complex systems when he was 12 years old, publishing his first scientific paper when he was 15, and obtaining a PhD in particle physics form Caltech by the time he was 20! Throughout his scientific research Wolfram developed software to conduct experiments and this became the foundation for what was to become Mathematica, the popular commercial scientific computing platform. Now, you could buy Mathematica for an "arm and leg" and relatively easily conduct the same investigation we will pursue in this article. But where's the fun in that?

I am going to show you that in just a few late nights hacking in REAL Studio you can build a framework for your own experiments—just like Wolfram did!

First, we will develop the building blocks and vocabulary for Cellular Automata (CA) by walking through an example. Next, we will translate these building blocks into classes, which we will use to model the aforementioned 'simple rules.' Then we're ready to tackle the heart of the program: modeling the emerging structure and displaying the patterns on a canvas control.

The study of CA is a rich field of research but we will only investigate one-dimensional, binary, nearest neighbor CAs. What does that mean? First we have to realize these ideas manifested to model physical systems. Immediately you will see this approach diverges from modern physics by viewing the systems as discrete; that is, they evolve in a step-by-step process whereas the modern calculus of physical systems on both large and small-scale are based on continuous evolution.

One-dimensional means we are dealing with a simple grid of perpendicular lines like you see on graph paper. Binary means that each of these cells on the grid can only take two different states, which will be black and white in our example. Nearest neighbor means that the rule that determines the state of successive cells are dependent upon the states of the previous nearest neighboring cells. Let's use the quintessential example to make these ideas more concrete. In Figure 1 you will see what our program displays as the result of what is called "Rule 30."

...End of Excerpt. Please purchase the magazine to read the full article.