Entropic Forces Demo

Entropy isn't a real force but an emergent phenomenon. But what if we treated it as a real force? Could particles diffuse faster if they repeled from areas of higher concentration?

We will look at the rate of diffusion with and without introducing entropic forces to see if we can speed up simulations for finding equilibrium.

Click start on the first demo to view what happens with two sets of non-charged particles.

We can then plot the % of cyan and black particles on the left and right sides. We would expect them to all converge to 50% (with some bouncing due to inertia)


Well that was boring. Without any electrostatics it takes time for particles to diffuse. But what if they had opposite charges?

Despite overshooting, it's better.

Now let's look at a combined case. Upper and lower particles will have opposite charges. But left and right particles will be identical to each other. Would we expect the vertical axis to diffuse faster than the horizontal?


Sure enough the horizontal axis takes a long time to diffuse. But what if we added an entropic force to our first example again? This time particles repel from all identical particles using the same 1/r^2 factor as electrostatics.


It worked! Now even without a charge the particles reach their equilibrium more quicky. What would you expect in the final demo below if we redo our 4-way example with electrostatics and entropic forces?


Surprisingly the left/right particles still diffused slowly. Looking carefully this is still faster than our first combined case (Graph 3). This is because a repulsion force becomes more useful as the number of particles increases. In our combined case there were only 100 of each particle rather than 200 in the side by side cases.

However, it does show modeling entropy as a force can speed up simulations towards an equilibrium. For next steps perhaps a r^-1.9 instead of r^-2 drop off could help make the entropic force disperse particles more quickly.

It's important to know a lot of research has gone into n-body simulations like these. An important next step would be to use a higher degree integrator such as verlet integration. There is also a technique called Barnes-Hut which uses O(n log n) instead of O(n^2) comparisons using quadtrees. These would improve accuracy and performance respectively.