A fluid engine written entirely from scratch, in JavaScript.
This was a experiment/research project to try see if global fluid behavior generally described by complex differential equations like the Navier-Stokes' can emerge from local rules of c…
A fluid engine written entirely from scratch, in JavaScript.
This was a experiment/research project to try see if global fluid behavior generally described by complex differential equations like the Navier-Stokes’ can emerge from local rules of collisions.
The rules of collisions was also written by scratch, and should be a project in itself.
In the simulations, the faster moving particles are colored red, and the slower moving ones are colored blue. Just by analyzing these, one can draw out the effects of pressure, temperature, velocity fields, energy distributions and EVEN FLUID VORTICES. It is a very important aspect of this project, that you note none of these properties were programmed, and no physics formulas were used to calculate them; all these properties have directly emerged from local vector math for particle collisions.
So did the experiment work? Go see for yourself!