|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.rit.clu.antimatter.AntiprotonClu3
public class AntiprotonClu3
Class AntiprotonClu3 is a cluster parallel program that calculates the positions of the antiprotons as a function of time. Each antiproton experiences a net repulsive force from all the other antiprotons. Each antiproton also experiences a force due to a magnetic field perpendicular to the plane in which the antiprotons move.
Usage: java -Dpj.np=K edu.rit.clu.antimatter.AntiprotonClu3 seed R dt steps snaps N outfile
The program runs in K parallel processes. Each process writes its own output file. If outfile is specified as "out.dat", for example, then process 0 writes file "out_0.dat", process 1 writes file "out_1.dat", and so on.
The program:
The computation is performed in parallel in multiple processors. The program measures the computation's running time.
Each process holds one slice of the position array, one slice of the velocity array, and one slice of the acceleration array. At each time step, each process calculates its own slice of the acceleration array; the slices of the position array are passed from process to process in a pipelined fashion; the communication is overlapped with the computation of the acceleration array. After all position array slices have passed through all processes, each process uses its slice of the acceleration array to update its slices of the velocity and position arrays. Each process writes snapshots of its own slice of the position array into the process's own output file.
| Method Summary | |
|---|---|
static void |
main(String[] args)
Main program. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static void main(String[] args)
throws Exception
Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||