Go back to Patchrawat Uthaisombut's page: www.cs.pitt.edu/~utp
Getting the Best Response for Your Erg
Downloads
Everything in one file
Piece by piece
Required software
a) User has to have JDK 1.4.2 or higher installed in order to compile Java code.
b) If the user has Mathematica version with JLink installed, the user can perform computations on new input instances. Otherwise, the user can only view the precomputed examples. Note version 4.2 and later versions of Mathematica come with JLink. For earlier versions JLink can be downloaded for free from Mathematica website.)
Installation instructions
a) Save DrawLowerEnvelope.m (the Mathematica piece of the program) into a directory where the MathKernel.exe is located. Most likely it will be in a directory similar to:
C:\Program Files\Wolfram Research\Mathematica\4.1\DrawLowerEnvelope.m
b) Change the directory in the file Slippery.java to match the directory where MathKernel.exe is installed on your pc:
ml = MathLinkFactory.createKernelLink( "-linkmode launch -linkname 'C:\\Program Files\\Wolfram Research\\Mathematica\\4.1\\MathKernel.exe' ");
c) Compile Java code with a line similar to this. Make sure that you specify directory for Jink.jar on your machine:
javac -classpath "C:\Program Files\WolframResearch\Mathematica\4.1\AddOns\Applications\JLink\JLink.jar;C:\j2sdk1.4.2\bin;." Slippery.java
d) Run java program with a line similar to this. Make sure that you specify directory for Jink.jar on your machine:
java -classpath "C:\Program Files\Wolfram Research\Mathematica\4.1\AddOns\Applications\JLink\JLink.jar;C:\j2sdk1.4.2\bin;." Slippery
If all the steps are completed properly, following window will show up:

After all parameters are entered properly, click on "Start Mathematica Calculations" button. Wait until calculations are done. User can move slider to adjust energy and animate changes in jobs' properties. User can save the data calculated into a file by entering filename and pressing “Save” button. Following screen will show up after slider has been moved:

Additional feature of the program is that data can be read from a file without doing Mathematica calculations beforehand. User can save the data calculated into a file by entering filename and pressing “Save” button. Files will be stored in current java directory:
1) inputNNNN.txt - stores
all the input parameters
2) outputNNNN.txt - stores
all the output data needed to perform the animation
3) graphicsNNNN.jpeg –
stores graph image
User can enter the name of the file (only the NNNN part) inside of the textbox like on the following image, and press "Load" button to read from the file directly:
Go back to Patchrawat Uthaisombut's page: www.cs.pitt.edu/~utp