[Cuis-dev] Ideal gas and real gas simulation
Hilaire Fernandes
hfern at free.fr
Sun Dec 7 02:01:17 PST 2025
Hi,
When discussing with Physics teacher at my school, its appears gas
simulation is something desired. There are some simulation out there,
but they keep mentioning me it is a nice tool to have. So I gave a shoot
and start the implementation of a DKM[1] for the Dybo project.
A first iteration was a very naive, kind of billiard:
https://mamot.fr/@drgeo/115577138308536197
Then hack some energy transfer from the wall:
https://mamot.fr/@drgeo/115598616477391933
https://mamot.fr/@drgeo/115600731271105530
However this implementation was not correct from the thermodynamic
perspective, so I implement a real diffuse energy transfer model:
https://mamot.fr/@drgeo/115623761342500850
This gave a more or less realistic simulation of ideal gas.
The next challenge was to have inter-atomic potential to be considered:
atom can be attracted or repulsed from each other. The Lennard-Jones law
was used. The tricky part was really the scale and simulation step time:
Atom can get crazy unrealistic velocity
https://mamot.fr/@drgeo/115669231450451191 because of not small enough
simulation time.
With a fined tuned simulation time and Morph step time of 100Hz, the
result are quite interesting: https://mamot.fr/@drgeo/115669511921472246
The final model has both diffuse energy transfer from the wall and
inter-atomic potential calculus.
Again, the Cuis environment proved to be extremely helpful to fine tune
the algorithm.
Of course this DKM can be used from a Dybo document, as seen there with
another DKM: https://mamot.fr/@drgeo/115400315017925601
The aims is develop hundreds of such modules.
Hilaire
[1]
https://github.com/Dynamic-Book/doc/tree/main/4-Explanations/200-Dynamic-Knowledge-Models
--
http://mamot.fr/@drgeo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20251207/d918fe7f/attachment.htm>
More information about the Cuis-dev
mailing list