> analyse > objets > collatz-sequence-and-self-similarity-inigo-quilez

Collatz and Self Similarity

Inigo Quilez - 2016-09-14

Visualizing the dynamics of the Collatz Conjecture though fractal self-similarity.
Support this channel: https://www.patreon.com/inigoquilez

Tutorials on maths and computer graphics: http://iquilezles.org
Code for this video: https://www.shadertoy.com/view/llcGDS

Donate: http://paypal.me/inigoquilez
Subscribe: https://www.youtube.com/c/inigoquilez
Support: https://www.patreon.com/inigoquilez
Twitter: https://twitter.com/iquilezles
Facebook: https://www.facebook.com/inigo.quilez

carykh - 2020-11-12

:O Those fractals are so beautiful, and the fact that the number of edges on each level of fingers describes the path 3 takes through the Collatz procedure? That's crazy!

Ben's Fractals - 2021-01-18

oh hey, carykh, nice seeing u here!

Felix Faire - 2016-09-14

These videos are so beautiful and insightful. Please keep making more of them!

Inigo Quilez - 2016-09-14

Thanks!

Harry Andruschak - 2017-05-21

I've always wanted to display this in LEGO, but do not have the funds or room. 38 LEGO studs = one foot, so showing numbers up to 38 would require at least three feet.

Enrico Altavilla - 2016-09-14

Awesome study of the collatz conjecture. You should contact Numberphile and ask them if they are interested in producing a video about your visualization.

Harry Wilson - 2017-12-13

Really good video, I wasn't expecting the relationship between the number of fingers and the orbits of natural numbers!

Inigo Quilez - 2018-01-05

Yeah, me neither at first. The joys of discovering these things is immense!

aa - 2019-12-06

Seeing the imaginary unit i being called "j" by engineers makes me cringe like a big fat hairy truck driver named Elizabeth.

kleb bonk - 2016-11-06

Amazing job eliminating the usual "dryness" that comes with these kinds of abstract sequences

RadioactivePretzels - 2016-09-14

Wow, that was a fun visualizion.. both the original number line loops as well as the fractal complex extension. Knowing you, you probably wrote both visualizations with procedural shaders? Whether you did it or not I would love to see another video of the same length just describing the tools you made and/or used to make this video!

Inigo Quilez - 2016-09-14

It is a procedural shader, I made the video in Shadertoy and added the static slides as textures to the shader. Pretty much.

Stu - 2017-04-19

You are pretty humble. I found that you are co-creator of Shadertoy.

ganondorfchampin - 2018-11-04

What exactly does Shadertoy do?

Gillian Thaels - 2019-05-24

@ganondorfchampin it's a web based programing tools and social media about shader language especially fragments shader go check even we don't understand it's beautiful and amazing things on it ;) shadertoy.com

Graeme Lastname - 2017-03-28

Informative and beautiful. A rare combination.

CRoumbas - 2018-02-13

Very nice. What does the black area represent if not convergence?

Germain Cassé - 2019-02-25

It basically means "almost-divergent or divergent". Let me explain :
To render this image, we have to check the convergence of every point. But we face some ussues here : first, we want to render a lot of points. Secondly, we can't interate a point infinitely. So for these two reasons, we are setting an arbitrary limit : we assume that when an iteration of a point hits n (1 000 or 1 000 000 for instance), it will diverge. This saves the calculation time of the machine, but it has this drawback of showing the almost-convergent zones as black.

The reason why they used this method is simply because this software was originally made for Julia and Mandelbrot fractals i think, in which it has been proven that if an iteration of a point goes higher than 2 in term of modulus, it is always a divergent point (for the Mandelbrot fractal at least). But it's not the case in this fractal, because a point can always go to 10 trillion but go back to the 1-4-2 cycle

English is not my native language, ask me if i haven't been clear enough :)

Patrick O'Sullivan - 2019-03-04

@Germain Cassé So is it not possible that these areas will eventually recede away leaving only the integer points as convergent as you increase the calculation limit? Or has it been demonstrated that certain non-integer points converge (like the pre-images of 0)?

Germain Cassé - 2019-04-30

@Patrick O'Sullivan with a higher calculation limit, these black areas would be smaller and smaller

Driss CHOUKRI - 2018-05-06

brilliant. congratulations.
very clear

Manolo Padron Martinez - 2016-09-14

Awesome! Can't wait until the next video. Regards from Canary Islands

Fam SKiller - 2018-11-11

This video made me like you instantly. I am amazed how you visualized the numbers. I am fascinated by this conjecture and glad to have found your video. Keep it up

Jonathan Potter - 2016-09-16

Hey iq, I have been playing with the same effect. Rather than just using e^iθ, i used two angles, one positive, one negative. This allows me to show the normal collatz fractal. By controlling the angle of rotation it is possible to display a wedge similar to the the fractal you have in your video. In addition, I allow control of one of the constants (it's the first one I tried and I have been too busy to add more). Sweeping these values has some very interesting results. You can try it here: https://jonathan-potter.github.io/webgl-shaders/ look in the menu for 'modified collatz'

LydianLights - 2020-07-04

Very cool demo!

Math-OS - 2018-02-24

What a brilliant idea to extend the map into the complex field. Hopefully someone will one day use this new point of view to crack the collatz conjecture !

Terrence Zimmermann - 2016-09-14

Very well done, impressive!

mueez adam - 2019-07-18

So grateful I was able to rediscover this video, it’s a classic for me.

hapt1x - 2016-09-14

Amazing and wonderfully explained. Thank you.

Dani Vicario - Generative Artist & Speaker - 2020-04-15

This is so beautiful and interesting! It makes you want to understand and know much more Maths, thanks a lot!

Camilo Gallardo - 2016-10-05

great work. this is pretty imaginative. i didnt quite get that last property of the fractal though

ganondorfchampin - 2018-11-04

2:36

The formula is written wrong. K is acting a multiplier to 5n + 2, it's not taking 5n + 2 as input. So it should be written as k(n)(5n + 2). I was so confused until I figured that out.

chase marangu - 2020-01-10

i wonder if he did it on purpose to see if anyone would notice, hes clearly good at math, and thats kind of a dumb mistake for someone who probably speaks math and code as their second languages

Ricardo Garcia - 2020-05-03

chase marangu chill

Non-inertial Observer - 2020-06-01

@chase marangu ok boomer

chase marangu - 2020-06-01

@Non-inertial Observer I am not a boomer I am a Millenial.(2000) Or maybe I am a Gen-Z.

Qermaq - 2020-08-18

@chase marangu You're a loony.

David O'Gwynn - 2017-03-15

Thank you so much for this. Thank you for demonstrating the beauty, complexity and difficulty of this problem.

Michael Wise - 2019-12-03

Sorry I’m late, but these are some awesome insights! Thank you!

Pharoah Jardin - 2017-01-20

I did enjoy the video ! Thank you for this nice video. :)

yuval hirsch - 2016-10-17

i never knew you had a YouTube channel and this video happened to appear in my subscription box by chance

Maciej Kozłowski - 2017-03-30

Amazing...

Swinki Trzy - 2016-09-14

Awesome. Very interesting. Thank you.
I wonder how much surprises are hidden in that seemingly simple formula.

COIN COLLECTING FUN - 2017-11-23

VERY nice!! Such amazing information. It's amazing how math and art merge, creating this amazing beautiful images. Thanks for sharing!!

Michael Lubin - 2017-06-15

6:08 This is what you get - when static electricity gets in your hair.

EM - 2017-11-11

thank you for this video :)
very nice fractal

Phil - 2016-11-18

Brilliant. Thank you.

scantronbeats - 2016-10-04

Very interesting and this visualization is new to me. Thank you very much for this!

CptObliviouz - 2018-07-13

Great visualization! made me think i took a wrong turn and ended up in a cyriak video for a second

technoway - 2019-03-24

Wow! Great video, and great discoveries. I also had never seen the Collatz Conjecture expressed that way. Thank you for this great video!

Robert Perez - 2019-07-03

I'll have a solution (or not) to this by the end of the year.
I have some insight on the problem, this bothers me so much that I will consult it with a math professor. I need to understand whether I'm right or wrong.

Michael Wise - 2019-12-03

Any good news?

Magic Gonads - 2017-04-16

This is beautiful.

Sidicus Maximus - 2016-09-21

Great video and visuals!

theb1rd - 2017-01-09

Wow!

Rob Bowman - 2019-02-26

Beautiful work - thank you

SafetySkull - 2017-01-05

Wait how did you colorize that second image?

Bruno Bandeira - 2019-01-09

This is truly amazing. So amazing I feel like you made all this up.

Inigo Quilez - 2019-01-09

I wish I was able to make something like this up.

SuperMaDBrothers - 2019-02-01

Coolest video I saw in my life

Miguel Angel Quinteiro Piñero - 2017-06-04

Excellent!

Cian Curran - 2017-04-02

fantastic. well done.

Ben's Fractals - 2021-01-18

the collatz fractal seems like a close up of an infinitely powered mandelbrot.

Aaron Hollander - 2018-05-28

Awesome! Brilliant explanation and insight.

Custersword - 2018-07-13

Great video and summarized explanation!

Lag Duck - 2017-04-17

Wow that's so insightful! I'm numberphile's (and maths', and fractals') fan, and I am totally amazed how that enigmatic Collatz conjecture turns out to be a beautiful fractal when expanded to complex numbers. Great work!

logoliv - 2018-08-12

Inigo, could you please publish the first part of this video (with the cos function and the beautiful blue to brown color palette) to Shadertoy ? There's a lot of examples with the exp function but just one with the cos function on the site, and its color palette is not so good... plus the method seems to be different as yours, there's some artifacts in the example...

coolfunmario - 2016-09-14

The genius, also known as the Shader magician, strikes back again !

marinepower - 2016-09-15

absolutely incredible. wow.