Driven Diffusive System

One of Fowler's Physics Applets

This applet shows a toy model of nonequilibrium charges moving on a torus (periodic boundary conditions). The model says that all particles move equally likely left and right but half prefer to move up and half prefer to move down. This is a model by Beate Schmittmann and Royce Zia of Virginia Tech Physics. Some references are listed here. I won't attempt to explain it further here. There will be an explanation at Virgnia Tech's site.

There are three versions of this applet, all of which are in the same jar archive.

No Sliders - PlayApplet.class
This shows the lattice of charges with a start and stop button. The parameters, (total charge, total mass, driving force, etc.) are set within the HTML file. This version is most useful to illustrate web text where a reader should see the system run for a particular set of parameters.

Two Sliders and a Graph - IntroApplet.class
This adds to the previous version another panel in which we see two sliders to allow you to choose the driving force and mass and a graph showing which drive and mass were chosen. Every ten seconds, the applet calculates the total order parameter of the running configuration. If the order parameter has risen enough, the current parameter set is marked with a red dot. If not, it gets a blue dot. It should be enough to give you a sense of the phase regions of the system. It is not precise, however. Java is too slow for a more precise version.

Whole Mess of Sliders - FullApplet.class
This adds to PlayApplet.class a slider to adjust every parameter available. There are more than two, so the graph idea above would not help.
If you want to run the applets on a local machine, they can be run either under the appletviewer or as standalone java applications with "java FullApplet" or "java IntroApplet" or "java PlayApplet".

These applets are written to be easily extended to other Monte Carlo routines on the lattice. For instance, it would take only a minute to implement the game of Life (but why?). If you want to play with the Java Native Interface, a C++ implementation of the Monte Carlo is included in the zip file as is the compiled dynamic link library for a Win32 machine.

Author:Drew Dolgert
Date:14 October 1999
Version:1.0
Distribution:Gnu Public License, How to link to the applet
Language:Java 1.1

Run applet

This applet is in Java 1.1. Earlier browsers, even early versions of Java 1.1, may not display this applet.

Other languages

There are no other languages for this applet right now. If you can translate the properties file, you can have it in another language.

Download this Applet

Parameters

language - the two-letter language code
EN for English, FR for French, etc. This is the first specifier of a Locale. While some languages like Russian aren't official Default Locales, we can certainly add them if someone supplies an appropriate properties file. If you do not specify a language, the applet should use the default language specified by your browser's Java Virtual Machine.

country - the two-letter country code
CN for China, IT for Italy. This further specifies a locale if, for instance, you want to differentiate French in France, "FR", from French in Canada, "FR_CA".

threadsleep - integer, defaults to 40
The number of milliseconds the lattice thread should pause after it shows the next frame of a shot. Set higher for smooth animation on slow machines, lower for even smoother animation on fast machines.

boardsizex - integer, defaults to 40
The width of the lattice the charges live on.

boardsizey - integer, defaults to 40
The height of the lattice the charges live on.

mass - double, defaults to 0.5
Percentage of lattice filled with charge.

drive - double between 0 and 1, defaults to 0.1
This measures the strength of the driving field. If field strength is E, then the drive is exp(-E), so .1 is a strong drive and .9 is weak.

exchange - double between 0 and 1.0, defaults to 0.001
Rate with which two charges exchange places. 0.1 is large.

charge - double between -1 and 1, defaults to 0.0
The percentage charge of the system. This controls whether more move up or down.

upcolor, downcolor, and backgroundcolor - default to red, blue, and white.
Choose colors from the java palette: black, blue, cyan, darkGray, gray, green, lightGray, magenta, orange, pink, red, white, or yellow. You need to have the correct case in the parameter in order for it to work.

To Do

Related Applets

from major repositories

None that I know of.