The Ejs Hard Disk Gas model displays a two-dimensional gas made out of hard disks. Particles are initialized with a speed v=1 in a random direction and move with constant velocity until a collision occurs. You can modify this simulation if you have Ejs installed by right-clicking within the plot and selecting "Open Ejs Model" from the pop-up menu item.
Ejs Hard Disk Gas model was created using the Easy Java Simulations (Ejs) modeling tool. It is distributed as a ready-to-run (compiled) Java archive. Double clicking the ejs_newton_HardDiskGas.jar file will run the program if Java is installed. Ejs is a part of the Open Source Physics Project and is designed to make it easier to access, modify, and generate computer models. Additional Ejs models for statistical mechanics are available. They can be found by searching ComPADRE for Open Source Physics, OSP, or Ejs.
Please note that this resource requires
at least version 1.5 of
%0 Computer Program %A Christian, Wolfgang %D July 1, 2008 %T Ejs Hard Disk Gas Model %7 1.0 %8 July 1, 2008 %U http://www.compadre.org/Repository/document/ServeFile.cfm?ID=7573&DocID=593
Disclaimer: ComPADRE offers citation styles as a guide only. We cannot offer interpretations about citations as this is an automated procedure. Please refer to the style manuals in the Citation Source Information area for clarifications.
made changes to the model so that i can learn more about it and the changes are:
1. made n selectable by defining nmax and insert as the n maximum limit 2. made v0 selectable by changing the codes 3. made arrows array to be drawn to understand where the particles are heading 4. made text array to allow eye balling what each particle is doing 5 change some minor values to make cellSize selectable as well. 6 added e coefficient of restitution but the codes does not work well when e = 0 probably due to the collision detection codes, goes to a deep loop when too much particles are near each other.