A simulation of path finding using genetic algorithms.
Inspired by SmartRockets http://www.blprnt.com/smartrockets/
To run the code copy contents of sketch file into a p5js editor.
Initial population is generated with random direction vectors . Then fitness is calculated and based on that mating pool is filled. For every new generation crossover happens between parents picked randomly from mating pool. Then genes of child is mutated.
Click mouse anywhere on screen to change position of obstacle.