47:49Coding Challenge #53: Random Walker with Vectors and Lévy Flight
From the creator
In this coding challenge, I simulate a "random walk" with vectors in p5.js, varying the distance of each step size. This is known as a "Lévy Flight" (named after french mathematician Paul Lévy.) Code: https://thecodingtrain.com/challenges/53-random-walker-with-vectors-and-levy-flight 🕹️ p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/sketches/L24X90MBH 🎥 Previous video: https://youtu.be/l__fEY1xanY?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH 🎥 Next video: https://youtu.be/sJ6pMLp_IaI?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH 🎥 All videos: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH References: 🏛 Lévy Flight on Wikipedia: https://en.wikipedia.org/wiki/L%C3%A9vy_flight 5️⃣ createVector p5.js Reference: https://p5js.org/reference/#/p5/createVector 5️⃣ p5.Vector p5.js Reference: https://p5js.org/reference/#/p5/p5.Vector 📕 My NOC class on Kadenze: https://www.kadenze.com/courses/the-nature-of-code/info 📕 The Nature of Code GitHub (Spring 2017): https://github.com/nature-of-code/NOC-S17-1-Physics-Animation Videos: 📽 My Videos on Vectors: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZwSmtE13iJBcoI-r4y7iEc 🔴 Live Stream Archive #74: https://youtu.be/mrAeK43YDgw Related Coding Challenges: 🚂 #52 Random Walker: https://youtu.be/l__fEY1xanY 🚂 #162 Self Avoiding Walk: https://youtu.be/m6-cm6GZ1iw Timestamps: 0:00 Introduction to the Coding Challenge - vectors and Lévy Flight 2:05 Whiteboard - vectors 4:40 Into the code...create the pos variab
Published 2017-01-31 · Watch on YouTube ↗
Availability and playback restrictions are controlled by the original channel.





