Coding Challenge #21: Mandelbrot Set with p5.js

Subscribers:
1,740,000
Published on ● Video Link: https://www.youtube.com/watch?v=6z7GQewK-Ks



Duration: 25:28
362,580 views
7,770


In this coding challenge, I program from scratch the Mandelbrot set with p5.js Code: https://thecodingtrain.com/challenges/21-mandelbrot-set-with-p5js

πŸ•ΉοΈ p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/sketches/KsV1wWLqd

πŸŽ₯ Previous video: https://youtu.be/jrk_lOg_pVA?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
πŸŽ₯ Next video: https://youtu.be/fAsaSkmbF5s?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
πŸŽ₯ All videos: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH

References:
πŸ—„ Wikipedia on Mandelbrot Set: https://en.wikipedia.org/wiki/Mandelbrot_set
πŸ’Ύ Mandelbrot Set Explorer: https://meiamso.me/old/mandelbrot/mandelbrot.php

Related Coding Challenges:
πŸš‚ #22 Julia Set in Processing: https://youtu.be/fAsaSkmbF5s
πŸš‚ #140 Leibniz Formula for Pi: https://youtu.be/uH4trBNn540
πŸš‚ #168 The Mandelbulb: https://youtu.be/NJCiUVGiNyA

Timestamps:
0:00 Introducing today's coding challenge: the Mandelbrot set
1:22 What is a complex number?
6:06 Multiplying two complex numbers
7:51 The Mandelbrot set is all of the complex numbers that stay bounded
8:40 The initial sketch sets every pixel to gray
12:00 Calculate the real and complex components for the next generation
13:03 What does it mean to be bounded?
14:58 Set the brightness based on number of iterations
16:46 Store the original values of a and b
20:05 Set the brightness by maping to maxIterations
21:50 Add sliders to add ability to zoom in on the Mandelbrot set
24:58 Conclusion and suggestions for variations

Editing by Mathieu Blanchette
Animations by Jason Heglund
Music from Epidemic Sound

πŸš‚ Website: http://thecodingtrain.com/
πŸ‘Ύ Share Your Creation! https://thecodingtrain.com/guides/passenger-showcase-guide
🚩 Suggest Topics: https://github.com/CodingTrain/Suggestion-Box
πŸ’‘ GitHub: https://github.com/CodingTrain
πŸ’¬ Discord: https://discord.gg/hPuGy2g
πŸ’– Membership: http://youtube.com/thecodingtrain/join
πŸ›’ Store: https://standard.tv/codingtrain
πŸ–‹οΈ Twitter: https://twitter.com/thecodingtrain
πŸ“Έ Instagram: https://www.instagram.com/the.coding.train/

πŸŽ₯ Coding Challenges: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
πŸŽ₯ Intro to Programming: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6Zy51Q-x9tMWIv9cueOFTFA

πŸ”— p5.js: https://p5js.org
πŸ”— p5.js Web Editor: https://editor.p5js.org/
πŸ”— Processing: https://processing.org

πŸ“„ Code of Conduct: https://github.com/CodingTrain/Code-of-Conduct

This description was auto-generated. If you see a problem, please open an issue: https://github.com/CodingTrain/thecodingtrain.com/issues/new

#mandelbrot #fractal #complexnumber #imaginarynumber #p5js #javascript







Tags:
challenge
coding
mandelbrot
set
tutorial
creative coding
daniel shiffman
nature of code
coding challenge
programming challenge
p5.js
fractals
fractal
programming
p5.js tutorial
algorithms
processing tutorial
javascript
javascript (programming language)
p5js
p5 js
mandelbrot javascript
mandelbrot tutorial
mandelbrot source code
mandelbrot fractal
fractal tutorial
complex number
imaginary number
complex numbers explained
mandelbrot set