Cellular Automata

  Рет қаралды 62,522

Snake256

Snake256

Күн бұрын

Пікірлер: 121
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Source Code: github.com/Snake256/Cellular-Automata
@yoshidude64595
@yoshidude64595 3 жыл бұрын
This is the exact kind of content I’ve been seeking for a long time. I love it when simple mathematical rules lead to beautiful art
@troenxer4139
@troenxer4139 3 жыл бұрын
00:01 Minecraft's 2020 April fool's snapshot added an ant block which moved in the Langton's ant highway pattern
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
This is the type of easter egg I like to see
@adityasingh3963
@adityasingh3963 3 жыл бұрын
And I made Langton's ant in Minecraft with command blocks
@JetFalcon710
@JetFalcon710 Ай бұрын
Honestly love the oscillator that forms in the top left corner of the Game of Life simulation at around 2:36
@SUPERSEDFRZ2025
@SUPERSEDFRZ2025 23 күн бұрын
Ya' like pulsars?
@xw591
@xw591 3 жыл бұрын
Ok the fibonacci spiral is absolutely the coolest
@Zeppelin.
@Zeppelin. 3 жыл бұрын
It’s a Jojo reference!
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
What part?
@Zeppelin.
@Zeppelin. 3 жыл бұрын
@snake256 Steel Ball Run
@thunderheadset624
@thunderheadset624 3 жыл бұрын
0:55 its like the toothpick growth patterns where the toothpicks grow from the corners exept its cells
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Thanks for mentioning this. I didn't know about this pattern. Maybe they are somehow related.
@jacksonhall206
@jacksonhall206 3 жыл бұрын
1:55 drunk Minecraft load screen
@xcreeperbombx61
@xcreeperbombx61 4 жыл бұрын
LRRRRRLLR looks like the world loading screen in Minecraft
@NovaAge
@NovaAge 3 жыл бұрын
saw this while waiting for my autosmelter
@RubyPiec
@RubyPiec 3 жыл бұрын
Wdym
@novagasser9337
@novagasser9337 3 жыл бұрын
I'm watching this video as its what a race in destiny is based on
@THExRISER
@THExRISER 4 жыл бұрын
Beautiful!
@SteveAcomb
@SteveAcomb Жыл бұрын
Amazing! my man even shared the sauce ❤
@codingidiot6754
@codingidiot6754 3 жыл бұрын
I don't understand anything that's going on, but it seems cool nonetheless
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
The rules for cellular automata are surprisingly simple most of the time but the behaviour is really complex
@KittyGamingtheBestYoutuber
@KittyGamingtheBestYoutuber 3 жыл бұрын
same
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
The first automaton is called Langtons Ant because it has an "ant" which moves over the cells which manipulates them. It uses the Rule "LR" which stands for "Left Right". Whenever the ant steps on a white cell it turns Left and on red cells it turns to the Right. Additionally the ant changes the color of the cells. Red cells will be turned white and white cells will be turned red.
@codingidiot6754
@codingidiot6754 3 жыл бұрын
@@Snake-km8qc what about the other 20
@Neuroszima
@Neuroszima 3 жыл бұрын
@@codingidiot6754 "Rule 90" one, describes how adjacency impact future population of cells, it determines wether the cell will be left empty, in the line at the bottom, or will it get populated, depending on wether our neighbours exist, on which sides, wether the cell in the middle is populated and so on. In particular, in that cellular automata there are 256 different rulesets can be fed into the algorithm - each consisting of cases of 8 rules, that are marked as 1 or 0 (you can think of it as though it has a "binary representation"). We define, for each case of (left neighbour, central cell, right neighbour) 3 cells, a desired outcome. for example we might decide that, when there is a cell filled in the middle and has also filled both of the neighbours, a cell "dies due to overpopulation" in next step of the algorithm. so, in "world of numbers" -> 111 leads to 0 in the middle. The operations are then grouped in simillar fashion to binary code and are represented as, lets say, "10010110" (which is binary representation of "rule 150"), where each bit represents different case, and 0 or 1 - an outcome of such case. Very compact way of describing what is happening, but not understandable at surface. Finally, rule 90 has 4 cases where offspring is generated: 110 -> 1 100 -> 1 011 -> 1 001 -> 1 This pattern can generate Sierpinski-like triangle fractal, when array is properly initialized. Simillar one is generated with Rule 126
@alexandermorozov8593
@alexandermorozov8593 Жыл бұрын
Fasaneytin'
6 ай бұрын
Wow
@jerrygreenest
@jerrygreenest 3 жыл бұрын
Came for the image, stayed for the music
@squashedoranges7949
@squashedoranges7949 3 жыл бұрын
Most definitely an excellent coding excercise!
@NovaAge
@NovaAge 3 жыл бұрын
4:12 they REALLY took the time to name this one...
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I'm not really sure if all the names are official. I just saw somebody else call this one by that name. xd
@yeetyeet5079
@yeetyeet5079 3 жыл бұрын
5:25 looks like a fleet of spaceships
@Phiwipuss
@Phiwipuss 4 жыл бұрын
Amazing!
@lucastrahlendorff
@lucastrahlendorff 4 жыл бұрын
Awesome!
@magnusarsmagna5896
@magnusarsmagna5896 3 жыл бұрын
Turmites use the Spin to kill Valentine.
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Who is valentine? xd
@Valetravelgames
@Valetravelgames 3 жыл бұрын
Steel Ball Run Villan
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Oh nice, I'm reading part 6 currently
@Zuzezno
@Zuzezno 3 жыл бұрын
The "spiral thingy" looks like bismuth
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
True, that also makes for a better name. I changed it in the description. Thanks a lot!
@TheLittleViridianFighter
@TheLittleViridianFighter 3 жыл бұрын
The last turmite shown in this video actually gets stuck in a 28-step cycle after about 4.3 million steps.
@TheLittleViridianFighter
@TheLittleViridianFighter 3 жыл бұрын
Now that I think about it, it might have just been an error in my code. Can someone verify if this is correct?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I'm currently rewriting the source code for release because a lot of people are finding my video right now. If I find out I will let you know.
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Sorry for the late reply. By now you propably found the solution yourself but on my code the turmite gets stuck in a cycle as well after about 4.3 million steps. I uploaded my code to GitHub if you want to compare: github.com/Snake256/Cellular-Automata.
@МихаилКадомцев-н6м
@МихаилКадомцев-н6м Жыл бұрын
Очень интересно, про некоторые автоматы хотелось бы отдельные даже видео посмотреть, которые бы подробно объясняли правила, покадрово бы показывали, как там всё происходит и почему получается то, что получается
@iiextraheat3786
@iiextraheat3786 3 жыл бұрын
Let. Them. Fight.
@xw591
@xw591 3 жыл бұрын
Good music choice i think
@Mr-Raptor
@Mr-Raptor 3 жыл бұрын
Spiral thingy What an interesting name
@inconspicuoususername
@inconspicuoususername 4 жыл бұрын
Great video! But for the turmites, where did you find the actual rulesets? The Wikipedia page for them shows the same visual examples as this video but doesn't actually describe the rulesets for any particular one. Did you just randomly/sequentially create rulesets for machines until you got the same results, or can they be found elsewhere?
@Snake-km8qc
@Snake-km8qc 4 жыл бұрын
Thanks! On the wikipedia page if you click on the visual example it will open the image. If you then scroll down a text at the bottom appears which contains the ruleset. Additionally I found a github page which contains a lot of rulesets. Here's the link: github.com/rm-hull/turmites/blob/master/src/turmites/client/core.cljs
@byronhill8520
@byronhill8520 3 жыл бұрын
love this
@alphaanar2651
@alphaanar2651 3 жыл бұрын
niceee
@user-nb6gc9es6h
@user-nb6gc9es6h 3 жыл бұрын
cool
@RetrOHeaD5805
@RetrOHeaD5805 3 жыл бұрын
1:22 Please tell me i am not the only one who thinks it's synced here with the percussions
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Yes, I thought so too. Most of the animations just synced up naturally to the song without me even really trying. I like 2:15 as well. I definitely chose the perfect song for this video.
@RetrOHeaD5805
@RetrOHeaD5805 3 жыл бұрын
@@Snake-km8qc It's a cool song from Geoplex one of the best :D !
@unknownerror9551
@unknownerror9551 3 жыл бұрын
Do you have any ideas when you will next upload
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Hopefully soon. I had the source code for my next project done a couple of months ago already but usually when I finished a project I wasn't happy with the quality of the code. So I took some time off making projects and read up on how to write better source code. I will finish rewriting the source code for this video and then I will rewrite the source code for my next video which will be about raycasting and maze generation. I don't want to give a release date because I don't want to rush my videos but I'll try to release something soon.
@huhneat1076
@huhneat1076 3 жыл бұрын
Brian has a pretty weird brain
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Big Brain Brian
@가시
@가시 3 жыл бұрын
Spiral one is really interesting
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
It's my personal favourite!
@maurolionelmipianoyyo11
@maurolionelmipianoyyo11 3 жыл бұрын
So as texture ball
@aya-hl5bk
@aya-hl5bk 3 жыл бұрын
This is epic Like super epic as in some of the best That I have ever seen in ever Seriously this is epic
@osterlaich6395
@osterlaich6395 3 жыл бұрын
The information density is pretty high in this one. 😊 Conways game is brilliant, isn't it?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Yes you can do so many amazing things with it because it's turing complete. R.I.P. John Horton Conway
@osterlaich6395
@osterlaich6395 3 жыл бұрын
@@Snake-km8qc True although I think it might be one of the lucky finds. That further an deeper understanding of how the universe works. Did you play around in an 3 space. Just marvelous. 😊
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
@@osterlaich6395 No I haven't tried it in 3D if that is what you mean but I'll look into it.
@osterlaich6395
@osterlaich6395 3 жыл бұрын
@@Snake-km8qc think you will have fun with it. Would be 4d tho since you have time steps, dunno at least in my head it's 4d in 3space. 😊 It's just how I call an space with 3 spatial orientations. Is it not the correct word?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
Yes that works. Thanks for bringing it to my attention it sounds really interesting!
@Spherey
@Spherey 3 жыл бұрын
3:25 sierpinskis triangle
@plasmapig1356
@plasmapig1356 4 жыл бұрын
What is the automata at 5:41 called? It is making the fibonacci sequence!
@Snake-km8qc
@Snake-km8qc 4 жыл бұрын
This one is a Turmite which is similar to Langton's Ant but it additionally has an internal state. The behaviour depends on which rule is used. I got the rule for it from Wikipedia (en.wikipedia.org/wiki/Langton%27s_ant). In the section "Extension to multiple states" if you click on the picture there's a description with the rule. In this case the rule is { {{1, 8, 1}, {1, 8, 1}}, {{1, 2, 1}, {0, 1, 0}} }. The rows are for the possible colors the Turmite can encounter and the columns are for the internal state. The elements in the table are called triples. The first number is the new colour of the encountered cell. The second number is the direction the Turmite has to turn (1=noturn, 2=right, 4=u-turn, 8=left). The third number is the new internal state of the Turmite.
@plasmapig1356
@plasmapig1356 4 жыл бұрын
Hyperflux Very cool. Strange how this makes the fibonacci sequence!
@ninjanonja2251
@ninjanonja2251 3 жыл бұрын
@@Snake-km8qc i guess its more like "Golden Ratio"
@itsmespiazzy9704
@itsmespiazzy9704 3 жыл бұрын
Hey mind u ask, but u build these simulations with what programming language? I'm guessing C or C++, And one more question if its possible to build all this simulations with python? Thank you!
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I used the Processing IDE for this project which uses Java. I like C and C++ as well but I only have a surface-level understanding of both languages. Essentially the cellular automata shown in this video work with a 2D array of cells in the background. The cells in the array just change from one time step to the next according to the rules of the cellular automaton. So yes, it's possible to create all the simulations using python as well. I'm currently recreating my source code for release. If you are interested how I implemented the automata I can let you know when I'm done.
@itsmespiazzy9704
@itsmespiazzy9704 3 жыл бұрын
@@Snake-km8qc That would be awesome! I will have a hard time understanding java code, but I think what it really matters is important is the logic, right? thanks
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
@@itsmespiazzy9704 Yes, definitely. If you are having a hard time with the java code however you can still look if there are some tutorials on cellular automata using python. In general there are a lot of tutorials out there on the popular automata so I'm sure you'll find something useful.
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I apologize for taking so long to get back to you. I finally uploaded the repository: github.com/Snake256/Cellular-Automata. If you run into any problems with the source code please let me know.
@itsmespiazzy9704
@itsmespiazzy9704 3 жыл бұрын
@@Snake-km8qc That's so kind of you, thank you! I'll check soon
@rinomonkey1859
@rinomonkey1859 3 жыл бұрын
What's up with the colorful ones? Do they have different rules or what do they mean
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
The only ones where the color really matters are the Langtons Ants and the Turmites (see timestamps description). Those two need rules which determine the exact behaviour. Basically those two have an "ant" which moves across the cells. Each color is assigned a direction change (for example the color red could mean that the ant has to turn left). Additionally the ant changes the color to the next color from the color palette.
@rinomonkey1859
@rinomonkey1859 3 жыл бұрын
@@Snake-km8qc thanks :D
@Andrew90046zero
@Andrew90046zero 3 жыл бұрын
What libraries did you use for this? I know some people use SFML. But what about you?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I made this using the Processing IDE which uses Java. Processing provides a lot of simple methods for rendering stuff on the screen.
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
If you need the source code I just uploaded it to GitHub: github.com/Snake256/Cellular-Automata.
@RMRRafa
@RMRRafa 3 жыл бұрын
nnnice
@eilandihis4696
@eilandihis4696 3 жыл бұрын
what if the same rules are applied in a 3 dimentionnal grid?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I think the rules would have to be adjusted for them to work in 3D. For example langton's ant can only turn to the left or to the right. You would have to add the ability for the ant to move "inward". I think game of life could work in 3D as well but I haven't looked too much into it. The youtube channel "Softology" has a lot of videos on 3D cellular automata.
@flameofthephoenix8395
@flameofthephoenix8395 Жыл бұрын
@@Snake-km8qc
@flameofthephoenix8395
@flameofthephoenix8395 Жыл бұрын
@@Snake-km8qc Indeed, Conway's game of life is commonly transferred to 3d, however it isn't really designed to do that and may not work as intended.
@flameofthephoenix8395
@flameofthephoenix8395 Жыл бұрын
@@Snake-km8qc Ah, and here is Langton's ant in 3d! kzbin.info/www/bejne/ZprcdYSuls6pnpI
@eransasson20
@eransasson20 3 жыл бұрын
What software / language did you use for the animation?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I wrote the source code using the Processing IDE which works with Java
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
If you need the source code I just uploaded it to GitHub: github.com/Snake256/Cellular-Automata.
@raconvid6521
@raconvid6521 2 жыл бұрын
Ant
@aiexzs
@aiexzs 3 жыл бұрын
a cool fractal rule is /123
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
The fractal rules are the best
@aiexzs
@aiexzs 3 жыл бұрын
@@Snake-km8qc yeah lol
@Danidanijr
@Danidanijr 3 жыл бұрын
What program?
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I wrote it myself. I'm currently rewriting it because I'm not really satisfied with my code. Maybe I'll release it when I'm done.
@Danidanijr
@Danidanijr 3 жыл бұрын
@@Snake-km8qc oh ok
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
@@Danidanijr I apologize for taking so long to get back to you. If you are still interested in the program I uploaded the source code to GitHub: github.com/Snake256/Cellular-Automata.
@Danidanijr
@Danidanijr 3 жыл бұрын
@@Snake-km8qc cool
@rymerdaveedjec6164
@rymerdaveedjec6164 3 жыл бұрын
What am I watching
@KeeleyChaos-official
@KeeleyChaos-official 3 жыл бұрын
The first one is in minecraft
@ThomasChen-ur2gt
@ThomasChen-ur2gt 3 жыл бұрын
looking forward to the source code
@Snake-km8qc
@Snake-km8qc 3 жыл бұрын
I apologize for taking so long to get back to you. I finally uploaded the repository: github.com/Snake256/Cellular-Automata. If you run into any problems with the source code please let me know.
@NoraMadigan
@NoraMadigan 3 жыл бұрын
do star
@눈꽃Snowflake
@눈꽃Snowflake 3 жыл бұрын
Awesome!
Cellular Automata: Complexity From Simplicity
13:03
Acerola
Рет қаралды 108 М.
Langton's Loops: The cellular automaton that copies itself
12:01
davbrdavbr
Рет қаралды 524 М.
My scorpion was taken away from me 😢
00:55
TyphoonFast 5
Рет қаралды 2,7 МЛН
Cat mode and a glass of water #family #humor #fun
00:22
Kotiki_Z
Рет қаралды 42 МЛН
UFC 310 : Рахмонов VS Мачадо Гэрри
05:00
Setanta Sports UFC
Рет қаралды 1,2 МЛН
Tuna 🍣 ​⁠@patrickzeinali ​⁠@ChefRush
00:48
albert_cancook
Рет қаралды 148 МЛН
3D Accretor Cellular Automata
6:22
Softology
Рет қаралды 8 М.
I Made The Ultimate Cheating Device
9:39
ChromaLock
Рет қаралды 1,9 МЛН
Langton's Ant
6:30
Aldo Cavini (aldoaldoz)
Рет қаралды 982 М.
Organic neural cellular automata
9:05
Emergent Garden
Рет қаралды 49 М.
Ellipse-billiard simulation
2:41
Alexander Gustafsson
Рет қаралды 2,8 МЛН
Cellular Automata: Life from Simple Rules
7:00
argonaut
Рет қаралды 8 М.
【Extension of Langton's ant】Geoglyphs
2:39
えむしーじじょう
Рет қаралды 90 М.
Langton's ant
3:32
Ryan Wick
Рет қаралды 42 М.
༄ GRAVITY BASINS ࿐
6:15
2swap
Рет қаралды 398 М.
My scorpion was taken away from me 😢
00:55
TyphoonFast 5
Рет қаралды 2,7 МЛН