
How can we capture the unpredictable evolutionary and emergent properties of nature in software? How can understanding the mathematical principles behind our physical world help us to create digital worlds? This book focuses on a range of programming strategies and techniques behind computer simulations of natural systems, from elementary concepts in mathematics and physics to more advanced algorithms that enable sophisticated visual results. Readers will progress from building a basic physics engine to creating intelligent moving objects and complex systems, setting the foundation for further experiments in generative design. Subjects covered include forces, trigonometry, fractals, cellular automata, self-organization, and genetic algorithms. The book's examples are written in Processing, an open-source language and development environment built on top of the Java programming language. On the book's website (http: //www.natureofcode.com), the examples run in the browser via Processing's JavaScript mode.
If you're interested in this sort of stuff, the book Nature Of Code is great for exploring this topic by creating simulations. There's a Javascript version and Java based version (using the Processing framework). It isn't actually all that difficult, and I found it very satisfying to work through.
Some sources
> Math & motion: – The Nature of Code https://natureofcode.com/ – Coding Math https://www.youtube.com/user/codingmath
> Shaders / math-based rendering: – The Book of Shaders https://thebookofshaders.com/ – Inigo Quilez https://iquilezles.org/
> Interactive explanations: – Red Blob Games https://www.redblobgames.com/
You can also find some insight into his work process here: https://x.com/BCiechanowski/status/1387827101294686210?s=20
Most people doing this level of work built their own tools over time, learned a bit here and there, and kept refining things throughout their career.