Show HN: Game of Life on non-square topologies with 2^32 update rules (github.com)
Hi HN, when learning Golang (and topology), I ported a simple GOL in C (https://github.com/Jeadie/GoL) into Go. I then added a bunch of features
- Playing on other fundamental polygons (https://en.wikipedia.org/wiki/Fundamental_polygon#Examples_o...)
- Considering all possible update rules (of which, there are many).
Looking to get back to this project soon. Would love some feedback + ideas.
28 comments
[ 3.4 ms ] story [ 69.7 ms ] thread(from https://www.destinypedia.com/Garden)
Here's my version : https://github.com/chewxy/ll/blob/main/main.go#L176
I also live coded this in a series of 3 videos:
1. https://youtu.be/5JArQO8YeRo 2. https://youtu.be/ZLUVAWb_31M 3. https://youtu.be/BIypQF7M9c8
My approach differs from yours in that mine is entirely matrix driven.
In an 3x3 neighborhood there are 2^9, not 2^5 states. So we should get 2^512 possible update rules, not 2^32.
I think something similar is described in https://conwaylife.com/wiki/Rule_integer.
I'm not sure that all of those rules are valid. We must have translational invariance. One way to do that is to only update the state of the central cell in each considered neighborhood. In that case 2^9 rules are enough. Are there other ways to define consistent rules for a CA?
I think they're looking at alternative update rules. The one you question ignores diagonals.
You say it can be played on a variety of manifolds, but if the topology of a manifold "locally resembles Euclidean space near each point", considering that the game of life rules are always super local, then how does that change anything compared to a plane
For instance, periodic patterns may appear due to translations which do not in the square.
For this, the difference similarly only shows up over longer distances. That means more iterations. Spaceships will return where they left off.
Also, the specific topology matters: if a spaceship makes a tour around the world, it may appear to have flipped over on a Klein bottle.
I really don't understand the diagrams, and how they relate to the shape that each diagram is labeled as.
[1]: https://github.com/breandan/galoisenne/blob/8f0f1e9e4e02062c...
https://aperocky.com/cellular-automata/
This allows for more "block state" too in addition to just the black and white for GOL. Also allows some time based rules (i.e. change based off block age that it stayed unchanged).
I've gravitated to essentially a file description (and the corresponding parser) to set up the rules - this makes making and adding rules easier.