The Grey Labyrinth is a collection of puzzles, riddles, mind games, paradoxes and other intellectually challenging diversions. Related topics: puzzle games, logic puzzles, lateral thinking puzzles, philosophy, mind benders, brain teasers, word problems, conundrums, 3d puzzles, spatial reasoning, intelligence tests, mathematical diversions, paradoxes, physics problems, reasoning, math, science.

   
The Grey Labyrinth Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups    RegisterRegister  
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Cellular Automata in Excel

 
Reply to topic    The Grey Labyrinth Forum Index -> Visitor Submitted Puzzles
View previous topic :: View next topic  
Author Message
Lepton
1:41+ Arse Scratcher



PostPosted: Fri May 29, 2009 11:07 am    Post subject: 1 Reply with quote

I was stuck in a meeting today with a new notebook, so I decided to see if I could create the cellular automata that are introduced in Wolfram's "A New Kind of Science". I used functions in each cell to display either a 1 or a 0 (if you actually do this, set up your spreadsheet so that 0s aren't displayed) depending on the values of the three cells directly and diagonally above. The simplest example would be:
Code:
=mod((abs(A1+B1+C1),2)

Using the modular algebra available -- addition and subtraction, mod 2 -- can you create Wolfram's interesting Rule 30 or Rule 110 automatons?

Quick overview of cellular automata:
Imagine a big grid of squares that can be either black or white. In the middle of the first row is a single black square. Below that row, each square is colored according to a particular set of rules that take as input the values of the cell directly above, the cell diagonally above left, and the cell diagonally above right.
Back to top
View user's profile Send private message Send e-mail AIM Address
ralphmerridew
Daedalian Member



PostPosted: Fri May 29, 2009 3:59 pm    Post subject: 2 Reply with quote

With just addition and subtraction, mod 2, there are only 8 rules you can create. I'm not sure whether adding abs improves that any.

It's fairly easy to create any binary rule with addition and multiplication, mod 2, though.
Back to top
View user's profile Send private message AIM Address Yahoo Messenger
ChickenMarengo
Daedalian Member



PostPosted: Sat May 30, 2009 10:52 am    Post subject: 3 Reply with quote

Can't you create 16 rules, as you can also optionally add 1 to invert a rule?

Allowing multiplication, I get:

Rule 30: =mod(A1+B1+C1+B1*C1,2)

Rule 110: =mod(A1*B1*C1+B1*C1+B1+C1,2)

To get these, start with rules that will only match one pattern from the previous generation. e.g. A*(B+1)*(C+1) mod 2 will only give you a 1 when the previous generation is 100.

Add up these rules for all the patterns that you want to give a 1, then multiply out and simplify by removing pairs of duplicate terms.
Back to top
View user's profile Send private message Send e-mail
lostdummy
Daedalian Member



PostPosted: Mon Jun 15, 2009 2:31 pm    Post subject: 4 Reply with quote

Well, it seems like it is possible to do it even without multiplication, if what is given in example is allowed.

In fact, if ABS could be used, then I can make it even without "mod 2" .

I will show example with defining "functions" to shorten up writing, but in excel cells those functions can be expanded to be entire formula instead:

sgn(n)= abs(n+0.5)-abs(n-0.5)
as(n)= abs( sgn(n) )
is0(n)= 1-as(n)

sumN= A1+A1+A1+A1+B1+B1+C1

cell= is0(sumN-1) + is0(sumN-2) + is0(sumN-3) + is0(sumN-4)

This will put in "cell" value needed for Rule 30. One expanded cell in real excel sheet at position I2 would look like:

Code:

=(1-ABS(ABS((H1+H1+H1+H1+I1+I1+J1-1)+0.5)-ABS((H1+H1+H1+H1+I1+I1+J1-1)-0.5)))+
(1-ABS(ABS((H1+H1+H1+H1+I1+I1+J1-2)+0.5)-ABS((H1+H1+H1+H1+I1+I1+J1-2)-0.5)))+
(1-ABS(ABS((H1+H1+H1+H1+I1+I1+J1-3)+0.5)-ABS((H1+H1+H1+H1+I1+I1+J1-3)-0.5)))+
(1-ABS(ABS((H1+H1+H1+H1+I1+I1+J1-4)+0.5)-ABS((H1+H1+H1+H1+I1+I1+J1-4)-0.5)))


where H1=0, I1=1, J1=0, and I2 is first cell under initial cell. All other cells can be just copy from this one.
Back to top
View user's profile Send private message
Display posts from previous: by   
Reply to topic    The Grey Labyrinth Forum Index -> Visitor Submitted Puzzles All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Site Design by Wx3