The Chase Applet
Last modified: "April 13, 1999 15:22:10 by matt"
The first line of the input data file to the java application should consist of a single
integer, n, between 1 and 6, equal to the number of lions in the simulation. (I
provided a bit more capcity than you'll use, as your maximum number of lions is
6.) All subsequent lines are of the form:
Xg Yg Tg X1 Y1 T1 X2 Y2 T2 ... Xn Yn Tn
Where all the elements of each line are floating point numbers. Xg Yg Tg are
the coordinates and
heading of the gazelle, X1 Y1 T1 are the coordinates and heading of the 1st
lion, etc.
Here is the jar file, Gazelle.jar, containing the classes of the
Java application. You will need to have installed JDK1.1 (or higher) to run
the application. Here are the
instructions for installing jdk1.2.1 on a Windows machine.
Make sure the Gazelle.jar file is an element
of the CLASSPATH variable.
- In Windows You should append ".\Gazelle.jar" to the
end of your CLASSPATH shell variable. Then make sure "Gazelle.jar" is in your
working directory when you run java. (Here is more
on setting your CLASSPATH variable.) On my Windows machine, I installed JDK
at C:\jdk1.2, so my CLASSPATH is
C:\jdk1.2\src.jar;C:jdk1.2\lib\tools.jar;.\gazelle.jar
- In Unix I do the same thing, this time setting CLASSPATH via the
commands:
CLASSPATH='/usr/local/java1.2/src.jar:/usr/local/java1.2/lib/tools.jar:.:./Gazelle.jar'
export CLASSPATH
You might want to place those lines in your ~/.profile file.
When all is set, run the application
via the command: java Gazelle.