This project uses the logistic map dynamic system. You set a starting condition (x_0) and a parameter (a). My (rough) knowledge of the logistic map: The next number in the sequence will be: x_1=a*x_0*(1-x_0), x_2=a*x_1*(1-x_1) and so on. When a is positive and below 3, the sequence behaves very normally, but when you get higher between 3, the sequence starts to alternate between certain numbers. When you get a little higher it alternates between more, and when you get around 3.57-3.58, it turns into complete chaos.
https://scratch.mit.edu/projects/1172946252/ Thanks to @AO-85757 Tags: lapadonic logistic map chaos sequence mathematics