Matter can be either in solid,liquid or gas state due to the change in temperature. This is an animation of particle model for such situation. Because we need to add enough particles and calculated all the interactions between any two particles. the animation is a slow motion to illustrate a real situation. You can change the gravity and Temperature of the system. You can also drag any one of the green box to change the volume of the container. The initial state is g=10.0 and T=250K. Wait for a few minutes, you will find something similar to the following image, similar to a solid state. Particles are located at nearly fixed locations. If you increase the temperature , you might found the system change to liquid state. The particles try to fill the lower part of the container. There are still attracted to each other and particle can moving around. If you increase to even higher temperature, you will find the system change to gas state. Particles try to fill the whole volume of the container.

Virtual Physics laboratory Original URL

Fu-Kwun Hwang, Dept. Of Physics, National Taiwan Normal University.