Fifty years have passed since CONWAY'S GAME OF LIFE firstly appeared on a column called "Mathematical Games" on @sciam.

While most Programmers & Computer Science enthusiasts are familiar with it, not many know that the game is actually TURING COMPLETE.

Let's see why. ⠠⠵

🧵👇
The quickest way to prove that a system is TURING COMPLETE is to show that it allows for the constructions of LOGIC GATES. 🖥️

So, let's see how the 𝗔𝗡𝗗, 𝗢𝗥 and 𝗡𝗢𝗧 gates can actually be constructed in Conway's Game of Life...
Firstly, we need to find a way to encode binary signals.

One very popular choice is to use a stream of GLIDERS. The so-called GOSPER GLIDER GUN can generated a new glider every 30 generations. 🔫

Hence, receiving a glider every 30 generations counts as a "1".
When two GLIDERS hit each other in just the right way, they both get destroyed. 💥

This means that a GLIDER GUN can stop an incoming glider stream!

We can exploit this mechanism to simulate a NOT gate:

⬇️ 𝗡𝗢𝗧 0 = 1 ⬇️ 𝗡𝗢𝗧 1 = 0
With the same principle, and AND gate can be also constructed by extending a NOT gate.

⬇️ 0 𝗔𝗡𝗗 1 = 0 ⬇️ 1 𝗔𝗡𝗗 0 = 0
For the glider stream to the right to survive an AND gate, the second input needs to cancel the stream coming from the glider gun to the right.

⬇️ 1 𝗔𝗡𝗗 1 = 1
Another small modification allows to construct an OR gate.

⬇️ 0 𝗢𝗥 0 = 0
⬇️ 0 𝗢𝗥 1 = 1 ⬇️ 1 𝗢𝗥 1 = 1
The AND, OR & NOT gates are said to be FUNCTIONALLY COMPLETE, as can be used to construct any logic expression.

This is one step away from TURING COMPLETENESS. ✨

What we need is a memory block! The pattern below works as a SET-RESET LATCH: a simple 1-bit memory register!
LOGIC GATES & LATCHES are everything needed to build an actual computer. 🖥️

If you are interested to learn more about this, this short documentary goes into great length to explain the process of building an actual computer in Conway's Game of Life. ⠠⠵

If you enjoyed this thread, follow me for more content like this! 😎

I tweet about Programming, Artificial Intelligence, Game Development & Shader Coding! 🤓

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Alan Zucconi

Alan Zucconi Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @AlanZucconi

9 Jan
If you are interested in learning AI and how it can be used in #gamedev, you should start with BEHAVIOUR TREES! 🌲🧠

As the cornerstone of game AI, BTs are used in:

• Halo 2 🪖
• Bioshock 💉
• GTA V 🚗
• Façade 🍈
• Alien: Isolation 👽

Let's see how they work! 👇

🧵 A screenshot of "owl-bt", an editor for Behaviour An example of Behaviour Trees in Unreal Engine.An example of Behaviour Trees in Unity, with an asset called
Many of you are familiar with FINITE STATE MACHINES: the most popular pattern for character controllers.

While FSMs are graphs, BTs are (unsurprisingly!) trees. 🌲Their leaves are the ACTIONS 🦾 and PERCEPTIONS 👁️ your agents can perform and sense.
Each node in a BT can be in any of the three following states:

• ✔️ SUCCESS: the node was executed successfully
• ❌ FAILURE: the node could not be completed
• ⏳ RUNNING: the node is still being executed
Read 11 tweets
8 Jan
Most #gamedev are familiar with A*, the most used pathfinding algorithm in games.

⚠️ But did you know that there's a very common scenario in which A* DOES NOT find the shortest path? 😱

Let's see why A* won't work in "Portal", and how we can fix it!

🧵
All pathfinding algorithms work by iteratively exploring nearby cells in the grid.

⬅️ Breadth First Search explores them in the order in which they are discovered.

➡️ Dijkstra's Algorithm, instead, keeps exploring the SHORTEST PATH FIRST.

(gif by @redblobgames)
That is also why Dijkstra's algorithm is sometimes referred to as the SHORTEST PATH FIRST algorithm.

Ultimately, it is that property that ensures its OPTIMALITY (= it will always find the shortest path between any two points).
Read 12 tweets
24 Nov 20
One of the best ways to improve your creativity is—paradoxically—to design with constraints.

Perhaps this is why the #pico8 community never failed to amaze me with their tiny creations.

So, here's a list of PICO-8 DEMAKES, starting with possibly the best one ever made...

/🧵👇
"FUZ", a #pico8 demake of @Polytron's "FEZ" by Henry Stadolnik (@Jusiv_).

jusiv.itch.io/fuz
"Low Mem Sky", a #pico8 demake of @hellogames's "No Man's Sky" by Paul Nicholas (@Liquidream).

liquidream.itch.io/low-mem-sky-ja…
Read 7 tweets
27 Sep 20
Turns out 2020 was—for many of us—one of the worst years on record.

If you are feeling stressed and need somewhere to escape for a little bit, this is a thread about some short, calming games that I hope will help you relax.

Starting with...

👇👇👇 🧵
"A Short Hike" is without any doubt the best indie title of the year. 🏔️🐦

@adamgryu has truly crafted something that can soothe your soul for a good few hours.

store.steampowered.com/app/1055540/A_…
"Kind Words" is a game like no other. 💌🤗

You can write about your own issues, and read anonymous replies from other players.

It's warming and empowering. @popcannibal created one of the few experiments on empathy that actually worked.

store.steampowered.com/app/1070710/Ki…
Read 10 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!