In the beginning I didn't think it was possible without cheating something but finally found a way to "build everything perfectly"
Due to the inifinite recursion, each level is aperiodic for both space and time, and you'll never see the same pattern no matter how much you scroll
At a certain draw distance (probably/hopefully depending on framerate and other specs), the platform replaces the individual cells with the OTCA metapixel, effectively giving the illusion that it is GoL all the way down.
The other trick is that the simulation speed scales with draw distance, such that once you've zoomed out a full cycle the simulation has gotten exactly 35328x faster, which is the period of the OTCA metapixel.
There's some lovely "engineering diagrams" of the OTCA metapixel on this (sparse) blog: http://otcametapixel.blogspot.com/2006/05/how-does-it-work.h.... It's fun to zoom in on the posted site and identify all the features, like the rule table near the bottom left.
For context, the OTCA metapixel is a large pattern (2048x2048) which is capable of simulating Conway's Game of Life rules (or, indeed, any rule set consisting of neighbour-counting birth/death conditions); it does this by having adjacent pixels coordinate sharing of state (whether they're on or off) and then looking up what to do via a (programmable) lookup table. Based on the current state (on or off), a series of "glider guns" will be conditionally activated, which creates the appearance of a filled center (filled with moving gliders).
It also appears to retain the current state of arbitrarily higher recursive instances, not that they move much when you're zoomed in. Makes me wonder, how do you code for the current 'position' in the whole stack in a way that remains consistent? Conceptually the space is very big. If you zoom/recurse in to a random metapixel 13 times in a row, you're almost certainly looking at a pixel that no other human has or ever will see, and you have scaled from the width of the observable universe to the width of a proton.
Yeah, this part is very clever and quite well-done IMHO. I suspect the trick is to only store the state for any levels you've actually seen.
As you go higher, they can just arbitrarily select a location in the simulation a few levels up from where you are that is consistent with the metapixels you've seen; once you go up a few levels, there's no chance of you having seen beyond a very small window of the simulation, so it's a matter of just finding a matching pattern.
As you go lower, the time step cannot be set be zero, so they can simply initialize the simulation a few levels down to an arbitrary state since the lower levels will tick exponentially faster.
The only problem is that you do have to store state for levels between the highest level you've seen and the current level as you zoom in. I suppose this means that if you zoom out a lot (just spam the scroll) and then zoom in a lot, there might be substantial memory usage. I've tested it and they do seem to consistently remember the exact state of the simulation at least a few levels up - it's easy to check by looking at the length of the clock train on the left of the metapixel in each level.
Need they do any simulation? I would need paper and some time, but can’t you store 16 animations of a cell and then just have the state as a zoom level, position in x y space (wrapping) and a time (in a loop). The rest should be calculatable assuming this is a true fractal which I think it is. 0 zoom is probably the starting position. Zooming in actually switches to maximally zoomed out with each cell following the prerecorded animation from a layer up based on the x y position. What state are you imaging?
Yes, you’re right on the state: the state for each level can just be OTCA timestep and x,y within the parent level. However, I think you need to store somewhat more than 2^4 animations: there are 35328 cycles per OTCA tick, and a cell’s animation depends on all of its neighbors, for something like 2^9 * 35328 distinct states. The vast majority of cells are quite predictable (and have short animation periods) but some of the logic elements will change in somewhat unpredictable ways. There is likely to be some fancy compression that can be done if the states need to be computed ahead-of-time.
Some of the more subtle bits do depend on the neighbor cells in the parent level, so I think there still does need to be some simulation done to ensure that these subtle bits are correct when viewing lower levels. But that only needs it be done in a small neighborhood.
Interesting, I guess I forgot that the game of life includes edge neighbors and had no idea of the cycle time. Why isn’t it 2^8 neighbors though?. Maybe just running 2^8 simulations is the way to go? Or that’s 9 megabytes * frame size per so maybe that ends up being small enough with compression
Edit: the author has said that it’s non periodic apparently which seems like it would make this whole thing a lot harder and probably require more state
Eight neighbors plus the cell itself. With a period of 35,328 and a size of 2048 x 2048 cells for the OTCA metapixel you end up with 75,866,302,316,544 bit without any compression.
Wow! At the speed of around 0.15 you can see all the relevant computations:
Every few seconds three glider triples get sent out, obviously directly representing the 9 neighboring cells. These interact with some lane shifting and 90 degree reflections. In the process these "byte" may lose a glider or two, representing the result of the game of life computation. Then you can see a fuse burn down, then a single glider makes a round and suddenly the whole cell switches state by an army of gliders gently touching the producing border.
Cool - Game Of Life on my phone. Some pretty cool patterns. Recursion? Don't see it. But look - I can zoom out. Wow, that's a pretty large pattern. Oh shit!
I've not delved into the code. But I am assuming that this is a static model and not actually doing the GOL calculations. Is that correct?
First off, this is one of the coolest things I've ever seen.
Second, judging from the author's github [0], I'm guessing this was made in Haxe [1], which is a language often used to make games. I'd looked at Haxe before, but I hadn't realized that it has a lot of Ocaml-like features. I think I need to give it a try on my next prototype project!
I did not realize that. If you are not auto-zooming it seems to just control the simulation speed but while auto-zooming it effects the speed of the zoom. That probably makes sense at a deep level because as you zoom in and out the simulation speed has to be adjusted to make the new level run at the same speed as the old one.
I can wrap my head around zooming in - conceptually you run any life simulation you want, i.e. a base level game of life, and then recursively decompose each cell into the 2²² cells of a OTCA metapixel.
Zooming out I find much harder to make sense of. What does it look like if you zoom out infinitely often? Is there some limit? If you take an empty universe with all cells dead there seems to be nothing at first, but at closer inspection there is of course still a lot of stuff going on in all the dead metapixels making up the empty universe. After zooming in a couple of times it would be hard to tell that zooming out a bit would leave you with an empty universe. And it would not have to be an empty universe, it could be anything.
I am really enjoying this full screen with auto-zoom-out at the slowest speed setting. If the controls faded like media player controls do in full screen, I would be perfectly satisfied.
This inspired a bit of awe in me, especially after I learned from another comment here that each game is unique.
edit: Oh wow, of course it's last month's Bubbles creator.
I don't think you need to reach infinity to realize it's OTCA metapixels all the way down and OTCA metapixels all the way up. In a way, it just loops forever.
That is the question I am asking. Zooming out finitely often gives you metapixels but what happens in the limit at infinity? Just like increasing x by any finite amount will always leave you with a small positive number for 1/x but in the limit you get 0.
And if you want to explore continuous-state automata ('reaction diffusion') there's Golly's cousin-app Ready, too! (Next version of Ready's Houdini plugin (py3/H19.5) hopefully coming soon!)
I'm never going to stare at TV static and see deeper meaning in random noise, and while this is almost the opposite of that, I'm surprised by how I felt watching this.
Awe and mild discomfort aren't the usual feelings I get watching information being processed.
It need not do any simulation at all. Representing this as an animation should be very doable. Probably 2^4 animations (1 for each potential state of a cell) then you just need to tile the animations and replace sub pixels as needed. So you start out showing a zoomed in view of the animation. As you zoom out you tile based on the animation shown one layer up. The exact tiling is probably tough, but easier than actually simulating and keeping tons of state
The OTCA metapixel has 2048x2048 cells and a period of 35328. That's a total of 18.5 GB. And that's not counting the different states depending on neighbors and on-off-transitioning state.
While an interesting effect, this recursive nature of this game can not be seen unless one has a mouse scroll wheel. I think it would be good to allow zoom in/zoom out to be done a different way (such as page up/page down or +/-). Not everyone has a mouse scroll wheel.
While this may not work for tablets (?), the vast majority of laptops have a setting called two-finger scrolling that lets you use two fingers on a trackpad to give scroll wheel inputs.
It looks quite different on mobile here (both Chrome and Firefox) than on desktop. It's way better on desktop, on mobile quite chaotic and doesn't seem to follow the actual Game of Life rules.
Yeah, on mobile even if I turn the speed way down, it skips over many steps making everything unrecognizable. It lowers the FPS but still skips just as much between rendered frames. Seems like a programming error.
That's what's really awesome about it. In essence there's nothing but the rules of the game of life.
I wonder if it's the same for reality. Everytime we've been looking at some particles we deemed fundamental they appear to be made of even smaller ones.
> Everytime we've been looking at some particles we deemed fundamental they appear to be made of even smaller ones.
Not everytime. There is a list of particles that we currently deem fundamental, because no one has found any structure in them. But maybe we haven't looked closely enough yet. Some entertain the idea that they consist of vibrating strings instead of structurless, pointlike particles, but then those would be fundamental.
There are cells, but they are not atomic but decomposeable.
Each cell in level N is the stable pattern of gliders arranged into a square shape in the lower level N-1. If you think about it, this is how "objects" in the real world exist - not as an essence of the object, but as a pattern of simpler elements arranged in space-time that we recognize as an object.
That is so cool! This person really is a freak, in good way. They also created their own physics engine, which was featured here a while ago: https://github.com/saharan/OimoPhysics
But it would be cool if we could change the GoL parameters and see how that affects the infinite fractal recursion!
Wow, this is something I never considered... go down the rabbit hole on this site ("guns", "glider guns", etc). I had no idea people actually tried to "game" or discover useful patterns in game of life:
If you zoom in, you get lower and lower level OTCA metapixels forever, very straightforward.
But if you zoom out, at any time it could be possible for them to compute a different pattern. But it's OTCA metapixel all the way up. What is being computed, other than more OTCA metapixels? What is being computed after infinite zoom out steps?
It is interesting to observe that the perception of time changes with zooming in/out. I know the actual speed of the gliders remains the same, but it seems to my eye that they speed up if you zoom out and slow down if you zoom in.
I wonder if this perception has an analogue in the physical world that has relativity as a consequence.
This is really great. I would like to use it as a visual backdrop on a big screen when playing DJ sets. I see that it enters a permanently zooming out mode when I zoom out fast, would be awesome if the zoom control disappears when it enters that mode so that it just displays the game of life itself and no UI elements.
Mesmerizing, I am interested for the code and how is this built.
When I said build the entire fractal concept is it emergent or deliberate?
Who did author envisioned this>
I wonder what the smallest molecules/things are that could be used to make a real game of life? Could you do it with bacteria? Surely not viruses or amino acids?
The longest-running evolution experiment uses bacteria and it has been running for more than 30 years. There's a Veritasium video about it: https://www.youtube.com/watch?v=w4sLAQvEH-M
As you zoom out, the simulation of the underlying cells is swapped for a higher level simulation of the cells at the next higher level. Watch how the simulation of the cells from the level down speeds up as you transition to the next level.