Working on a flip-flop...

For general discussion about Conway's Game of Life.
Post Reply
AlanZucconi
Posts: 2
Joined: June 22nd, 2020, 8:56 am

Working on a flip-flop...

Post by AlanZucconi » June 22nd, 2020, 9:55 am

Hi everyone!

I recently started producing small documentaries and video essays which are somewhat related to artificial intelligence, artificial life and game development. The first one, incidentally, will premiere later today and is about the AI of Creatures.

The new video I'm working on is about (GUESS!) Life. I've been a pretty huge fan of Conway's Game of Life since I was a kid, so I'm pretty excited to work on it! I hope it'll nicely pay respect to all of the folks who have worked so hard on this for so many years!

The idea of the video is to somewhat recreate a computer in Life. Or at least, to get as close as I can in 30-ish minutes. The first step is to recreate logic gates with streams of gliders. That is working very well as you can see!

Code: Select all

x = 171, y = 76, rule = B3/S23
9$138bo$30bo41bo41bo21bobo$30bobo39bobo39bobo11b2o4b2o18b2o$13b2o18b2o
4b2o14b2o18b2o4b2o14b2o18b2o4b2o3b2o4b2o17bo3bo$11bo3bo17b2o4b2o12bo3b
o17b2o4b2o12bo3bo17b2o4b2o9b2o16bo5bo3b2o$5b2o3bo5bo16b2o12b2o3bo5bo
16b2o12b2o3bo5bo16b2o17bobo4bo8bo3bob2o2b2o$5b2o2b2obo3bo8bo4bobo14b2o
2b2obo3bo8bo4bobo14b2o2b2obo3bo8bo4bobo21bo3bo9bo5bo$10bo5bo9bo3bo21bo
5bo9bo3bo21bo5bo9bo3bo27b3o2bo5bo3bo$11bo3bo5bo2b3o26bo3bo5bo2b3o26bo
3bo5bo2b3o43b2o$13b2o40b2o40b2o2$112b2o$112bo$113b3o$115bo38$112b2o$
112bobo$114bo$114b2o!
I am using Gosper guns aligned at the top, and glider eaters to stop them from propagating where they shouldn't. I can get this to work fairly well even with more complex boolean expressions. Below, the boolean expression that turns on and off segment #5 of a 7-segment display:

Code: Select all

x = 324, y = 176, rule = B3/S23
7$95bo77bo77bo41bo$29bo41bo21bobo53bo21bobo53bo21bobo39bobo$29bobo39bo
bo11b2o4b2o18b2o36bobo11b2o4b2o18b2o36bobo11b2o4b2o18b2o14b2o4b2o18b2o
$12b2o18b2o4b2o14b2o18b2o4b2o3b2o4b2o17bo3bo17b2o18b2o4b2o3b2o4b2o17bo
3bo17b2o18b2o4b2o3b2o4b2o17bo3bo12b2o4b2o17bo3bo$10bo3bo17b2o4b2o12bo
3bo17b2o4b2o9b2o16bo5bo3b2o9bo3bo17b2o4b2o9b2o16bo5bo3b2o9bo3bo17b2o4b
2o9b2o16bo5bo3b2o12b2o16bo5bo3b2o$4b2o3bo5bo16b2o12b2o3bo5bo16b2o17bob
o4bo8bo3bob2o2b2o3b2o3bo5bo16b2o17bobo4bo8bo3bob2o2b2o3b2o3bo5bo16b2o
17bobo4bo8bo3bob2o2b2o14bobo4bo8bo3bob2o2b2o$4b2o2b2obo3bo8bo4bobo14b
2o2b2obo3bo8bo4bobo21bo3bo9bo5bo8b2o2b2obo3bo8bo4bobo21bo3bo9bo5bo8b2o
2b2obo3bo8bo4bobo21bo3bo9bo5bo21bo3bo9bo5bo$9bo5bo9bo3bo21bo5bo9bo3bo
27b3o2bo5bo3bo14bo5bo9bo3bo27b3o2bo5bo3bo14bo5bo9bo3bo27b3o2bo5bo3bo
26b3o2bo5bo3bo$10bo3bo5bo2b3o26bo3bo5bo2b3o43b2o17bo3bo5bo2b3o43b2o17b
o3bo5bo2b3o43b2o40b2o$12b2o40b2o76b2o76b2o61$128b2o$128bobo$130bo$130b
2o77$154b2o$153bobo$153bo$152b2o!
Functional completeness is cool, but I want "proper" Turing completeness! 8)
So the plan is to build a flip-flip, to serve as a 1-bit register. I started working on a SR NAND latch, and I already have the NAND block working without any issues.

I'm aware there are better ways to build memories in Life, and I know this is an overkill compared to the sliding block memory. But my aim is to recreate a flip-flip with logic gates, not to find a simpler patter that does the same.

The bit where I'm struggling is bringing the NAND outputs up again. I am using a Buckaroo reflector and it works very well with a glider stream from Gosper gun. My original plan was to use three of them to loop the stream back into the NAND. I figure out that every collision shifts the glider stream by 15 generations in time, and I accounted for that. Now the real problem is that no matter how I place them, I can't seem to find a way to put the gliders in the right position and time. The Reflector page on the Wiki talks about Glider timing adjustment, but is a bit too ...rushed! :(

This is what I'm talking about: a NAND with two missing inputs, which produces a glider stream that hits 4 reflectors. I can't get the timing and position of the stream right. :cry:

Code: Select all

x = 286, y = 232, rule = B3/S23
12$61b2o$62bo$62bobo6bo$63b2o4bobo$68bobo11b2o$67bo2bo11b2o$68bobo$69b
obo$71bo22$7b2o$7b2o4$8bo$7bobo$6bo3bo$7b3o183bo59bo$5b2o3b2o179bobo
57bobo$183b2o4b2o18b2o32b2o4b2o18b2o$183b2o4b2o17bo3bo30b2o4b2o17bo3bo
$189b2o16bo5bo3b2o30b2o16bo5bo3b2o$191bobo4bo8bo3bob2o2b2o32bobo4bo8bo
3bob2o2b2o$193bo3bo9bo5bo39bo3bo9bo5bo$197b3o2bo5bo3bo44b3o2bo5bo3bo$
209b2o58b2o3$5b2o$6bo$3b3o$3bo55$134b2o$133bobo$133bo$132b2o15$106b2o$
106b2o11$103b2o3b2o$105b3o$104bo3bo$105bobo$106bo3$108b2o$108bo$109b3o
$111bo13$67b2o$67b2o4$68bo$67bobo$66bo3bo$67b3o$65b2o3b2o10$65b2o$66bo
$63b3o$63bo22$91bo$91bobo$92bobo$79b2o11bo2bo$79b2o11bobo$91bobo4b2o$
91bo6bobo$100bo$100b2o!
(in the code above I used three reflector at the bottom because I was trying to replicate the "adaptors" used in "Building a computer in Conway's game of life". But without success!)

I made a quick diagram with colours to show you all of the components. The red "?" is there the glider stream does not synch-up properly.
Uhe0nf9.png
Uhe0nf9.png (4.21 KiB) Viewed 79 times
I'm sure this is such a common problem that must have been solved already. But despite looking, I couldn't find any proper answer/guide/tutorial. I know similar issues have been discussed in a few other posts, but some of the answers were a bit too obscure. :?

So yeah, any help or direction on how to properly synchronise glider streams from Gosper guns with buckaroos would be really appreciated!
Thank you!

User avatar
triller
Posts: 114
Joined: September 3rd, 2009, 2:41 pm

Re: Working on a flip-flop...

Post by triller » June 30th, 2020, 3:27 pm

A worthy and well documented mechanism is Paul Rendell's Turing Machine. The documentation is broken down module by module and has yielded numerous components which resulted in great avail to my mechanisms.
Why reinvent the wheel unless some overriding factor exists (i.e. space limitation, traffic lane conflict, etc.)?
As to your lane adjustment concerns, there are at least six 90 degree reflectors that are viable at p30, not to mention 15 inverter based reflectors.
Then there are pullers and pushers and fanouts, OH MY. There's almost always a way to cleanly resolve glider collisions, if functionality is your prime concern.
As to building a computer, good luck with that. I've been working on it 30 years and can just see a glimpse of light at the end of the tunnel. It'll be a loose replica of the venerable 6502 processor (a soft spot from my Commodore 64 days). I've managed to retain all of the original tech specs, though sadly the machine itself has long passed.
Keep experimenting. Components build modules, and modules mechanisms, which combined can create about anything you can imagine.
And, study that Turing Machine. It's very well optimized, simply explained, and has proven inspirational to me.

triller
The most exciting phrase to hear in science, the one that heralds new
discoveries, is not "Eureka!" (I found it!) but "That's funny ..."
-- Isaac Asimov

User avatar
gameoflifemaniac
Posts: 1242
Joined: January 22nd, 2017, 11:17 am
Location: There too

Re: Working on a flip-flop...

Post by gameoflifemaniac » July 9th, 2020, 4:48 pm

AlanZucconi wrote:
June 22nd, 2020, 9:55 am
stuff
Coban has made an 8-bit programmable computer. It's quite decent.
I was so socially awkward in the past and it will haunt me for the rest of my life.

Code: Select all

b4o25bo$o29bo$b3o3b3o2bob2o2bob2o2bo3bobo$4bobo3bob2o2bob2o2bobo3bobo$
4bobo3bobo5bo5bo3bobo$o3bobo3bobo5bo6b4o$b3o3b3o2bo5bo9bobo$24b4o!

Post Reply