A comprehensive array of educational simulations based on Java of different physical systems such as a kinetic thermal gas, Einstein's brownian movement, chaos mapping, a basic optical system (not shown here), Lagrangian mechanics among others. These apps were developed by making use of the libraries provided by opensourcephysics.org.

These apps MAY REQUIRE the installation of the Java JDK or JRE 1.8.0.131. I tried to bundle it within the apps in both the Windows and macOS version but if by any means you encounter Java Runtime Error issues, try to install a recent version of the JDK or JRE (in macOS, JRE seemed to be insufficient to run the apps).

These apps were developed by myself and Renato Fonseca under the guidance of Professor Luís Oliveira e Silva within the course of Computational Physics at the Instituto Superior Técnico, Lisboa, Portugal over 10 years ago. After some debugging, and adjustments over the Java 3D libraries (which were deprecated in the meantime several years ago), they aged quite well and still make me proud.

Warning: The applications interface in macOS is a bit choppy. The apps should run fine on the Mac but the Java Swing is different in macOS and I hadn't the time to make specific GUIs for the Mac.

Kinetic Gas

A presentation for this app may be viewed over here.

This simulation allows the study of the study of a kinetic gas inside the box. The simulated gas consists of hard spheres who collide with each other as described by classical mechanics. The simulation allows for the compression or expansion of the box containing the gas or the inclusion of a thermal source in one of the walls. The simulation allows then the measurement of macroscopic thermodynamic properties derived from the microscopic properties of each particle of the system.

The app was developed in Java and is available for download for Windows, macOS or as a .jar file.

In order to simulate this system, every single collision which happens in the universe of the gas needs to be accounted for. The choice of JVM to create this simulation makes it a bit heavy, but the application runs smoothly up to about 1000 particles, and with about 500 particles, the system behaves well enough to allow its usage for educational purposes.

The next images show the Temperature vs Volume (upper left), average kinetic energy (upper right), entropy (down left) and the speed distribution of particles (down right). Two situations are shown, a series of fast compressions or if you click each image it will show the same data for a slow compression.

As we can see in the series of fast compressions and expansions,  for the same value, the temperature increases as it is shown in the graphics of the average kinetic energy of the particles. Entropy also rises as it is expected.

As we proceed to a slow compression, the system is changed in a quasi-equilibrium state which results in minor changes to the temperature but increases entropy for each volume as it should be. In both cases, the Maxwell-Boltzmann distribution of speeds is clearly visible in the graphics. 

Kicked Rotator

The following simulation allows the study of a chaotic system. The app implements the kicked rotator allowing parameter changes. A 2D animation is available and more impressively, a way to generate the Chirikov-Taylor standard map in a very fast way. The map is generated in a Java native object being very fast to compute. The app allows export as a .png file of a high resolution standard map.

The app was developed in Java and is available for download for Windows, macOS or as a .jar file.

The map provides a good measure of stochastic behavior and by changing the parameters of the problem, we can easily see how to 'increase' or 'decrease' the chaotic behavior. Again, a great application to use in classroom or during a lecture.

kr_2d.PNG
kr_map.PNG

Brownian Motion

The Brownian motion application provides a random walk implementation for one and two dimensions and the implementation of the more complete Langevin equation for the three dimensional approach. The program shows the cloud of particles for every case (in one dimension, it's just a 'gradient' animated bar), the trajectories of some particles, their distribution for several radius and some real time data.

The app was developed in Java and is available for download for Windows, macOS or as a .jar file.

This is a great way to show Brownian motion in a classroom environment. 

bm_2d.PNG
bm_langevin.PNG

Rotating Parabolic Wired Bead

The final application I show here, animates a Lagrangian mechanics problem - the rotating bead in a parabolic wire. The adjustment of the parameters allows to visualize the behavior of the bead following the parabolic plane in rotation, the evolution of the radius over time and even draws the phase space in real time as long as the simulation continues.

The app was developed in Java and is available for download for Windows, macOS or as a .jar file.

Despite not being so useful as the previous ones, this app is really nice and allows to play along with the 3D animation and visualize the problem from several perspectives.

pb_gui.PNG