A Gaussian random walk is defined as one in which the step size (how far the object moves in a given direction) is generated with a normal distribution. Implement this variation of our random walk.
I’ve expanded the exercise a little: I’ve created an array of Gaussian Walkers and additionally the color range of each Walker has also been calculated using a mean, a standard deviation and a nextGaussian(), And I’ve obviously used different sizes for the ellipses in each image.
Thanks to this amazing blog about processing I found a very interesting book called “The Nature of Code” by Daniel Shiffman. I just finished Introduction, but even in it you can find many tasty things for beginners like me ;-)
That chapter introduces the reader to the basics of random values. The most interesting part is about Perlin noise which can be very useful in many projects.
What I would like to add: if you working on your own GIF and if you want to make a perfect loop, you may encounter a problem: Perlin noise is hard to loop sometimes. To solve this problem you have to add one extra dimension as showing at GIF above. Sun beams was drawn by Perlin noise in one-dimension. To make it smooth without jumps I had to use two-dimensional Perlin noise. That’s it, we just get values from circle located in noise space to build
periodic one-dimensional noise. That noise space, for clarity, shown inside as a filling.
Source in Python (processing.py) for those people who wants to dive deeper is here.