Micro and Nano Mechanics Group
Revision as of 22:04, 30 November 2007 by Caiwei (Talk)

Contents

What is ParaDiS and how to obtain a copy

ParaDiS is a free large scale dislocation dynamics simulation code to study the fundamental mechanisms of plasticity. It was originally developed at the Lawrence Livermore National Laboratory. It is written in C (with a little C++) and uses the MPI library for communication between processors. It runs routinely on 100-1000 processors and scalability on 132,000 processors of BlueGene/L has been demonstrated.

You can go to http://paradis.stanford.edu to obtain a free copy of the source code of ParaDiS. You will need to requestion an account by submitting a username, a password and a brief description of yourself and your research interests. Once your account request is approved, you will receive a confirmation email and you can download the ParaDiS source code. The same web site also contains the documentation of the ParaDiS code, including tutorials and reference manuals.

The source file you obtain should look something like pub-dd3d.v2.0.tar.gz. It is recommended that you create a ~/Codes directory and extract the source code there.

 cd ~/Codes
 tar zxvf pub-dd3d.v2.0.tar.gz
 cd dd3dv2.0

This should create a ~/Codes/dd3dv2.0 directory. We will refer to it as $ParaDiS in the following. Check that you have the following directories within your $ParaDiS directory: Inputs, Tests, Tools, Utilities.

How to compile ParaDiS

Go to the $ParaDiS directory. You may need to edit the makefile.setup file. The most important variables are SYS and MODE. SYS specifies the type of your computer and MODE can be either SERIAL or PARALLEL. For example, suppose you want to compile ParaDiS on a Linux/Intel workstation with 1 processor. You want to set SYS = i386 and MODE = SERIAL in the makefile.setup file. Then, you can just type

 make dd3d

If the compilation is successful, this creates the main executable dd3d in your $ParaDiS directory. If you type

 make

instead, then in addition to dd3d, a few useful executables will be created in the $ParaDiS/Utilities directory.

If there are some problems during compilation, you should then look into the makefile.setup file, and check whether the lines CC_SERIAL.i386, CPP_SERIAL.i386, CCFLAG_SERIAL.i386, CPPFLAG_SERIAL.i386 correctly specify the C/C++ compilers on your computer.

You can compile ParaDiS on Windows if [cygwin] installed. Set SYS = cygwin in makefile.setup.

How to run a single-CPU ParaDiS simulation

Using the dd3d executable compiled as described above, we can run a few test cases in the Tests directory. Each ParaDiS run is described in two input files: a .cn file (specifying simulation control parameters) and a .data<tt> with the same name (specifying the dislocation structure). For example, we can run

 ./dd3d Tests/frank_read_src.cn

In this run, ParaDiS will automatically look for file <tt>Tests/fread_read_src.data to read the dislocation (nodal) structure. The output for this run should look something like:

***********************************************************
**** 
**** Time of run:     Fri Nov 30 20:37:40 2007
**** Executable name: dd3d
**** Executable path: .
**** Working dir:     ....
**** Execution host:  .... i686
**** User name:       Wei Cai
**** Number of tasks: 1
**** Command line:    Tests/frank_read_src.cn 
**** 
***********************************************************
Initialize: Parsing control file Tests/frank_read_src.cn
Initialize: Control file parsing complete
ReadNodeDataFile: dataFile = Tests/frank_read_src.data
node count: 3

...

chdir successful on all tasks.
DD3dInit finished
cycle=1         realdt=5.953988e-10  timeNow=1.511247e-06  Fri Nov 30 20:37:43 2007
cycle=2         realdt=7.144786e-10  timeNow=1.511962e-06  Fri Nov 30 20:37:43 2007
cycle=3         realdt=8.573743e-10  timeNow=1.512819e-06  Fri Nov 30 20:37:43 2007

...

After DD3dInit finishes, ParaDiS prints one line every simulation step (cycle), which includes the cycle number, physical time step (realdt), physical time (timeNow), and computer wall time. Notice that the physical time advance for each time step is not a constant during the simulation.

By default, a window will open spontaneously, which displays the evolution of the dislocations. The setting for this window is specified in the win.script file. In particular, the window will be disabled if enable_window = 0. By default enable_window = 1 is set in this file. You can rotate the 3-dimensional dislocation structure by dragging your mouse in the display window. You can also zoom in and out, as well as save a snapshot into file. Press F1 in the window, and a list of short-keys will be printed in your terminal. For example, the F9 key saves the current window into a .gif file and the F10 saves a .ps file.


A few ParaDiS control parameters

The content of ParaDiS control files, e.g. Tests/frank_read_src.cn look something like this:

### DD3d configuration file (use -*-shell-script-*- format)
#
#  Sample control file to be used in conjunction with
#  the frank_read_src.data file.
#
dirname = "Tests/frank_read_src_results"
Rijmfile = "Inputs/Rijm.cube.out"
RijmPBCfile = "Inputs/RijmPBC.cube.out"
numXdoms = 1
numYdoms = 1
numZdoms = 1

...

Anything following the pound sign # is a comment. The values of the parameters are specified by the syntax var_name = value. A list of all ParaDiS input variables is available [here]. Here we describe a few of the most important ones.

For single CPU runs, numXdoms, numYdoms and numZdoms should all be set to 1. For parallel runs, the total number of CPUs must match numXdoms * numYdoms * numZdoms. maxstep specifies the total number of time steps (cycles) for the simulation. Simulation output styles are specified by groups of variables. For example, gnuplot, gnuplot_freq, gnuplot_counter, gnuplot_dt, gnuplot_timie together specify whether and how ParaDiS will output snapshots of dislocation structures in the [gnuplot] format.

How to run a parallel ParaDiS simulation

ParaDiS input parameters

ParaDiS outputs