pkdgrav3 September 24, 2018 http://www.pkdgrav.org/ Douglas Potter <email@example.com> Joachim Stadel <firstname.lastname@example.org>
mkdir build cd build cmake .. make
This will build a single executable “pkdgrav3” and other utility programs.
CMake - cmake build system
Most modern systems already have cmake installed. Pkdgrav3 requires version 3.1 or newer of cmake. You can check with “cmake –version”:
pkdgrav3:~> cmake --version cmake version 3.5.2
This library is usually available on HPC systems, but if not it must be downloaded and compiled, and can be found at this URL.
pkdgrav3 will locate the GSL installation by invoking gsl-config, so make sure that it is in your PATH. Alternatively, you can tell CMake where to find it by defining GSL_ROOT_ROOT:
If FFTW is available then two advanced features are enabled in pkdgrav3.
If is is not available on your system it can be obtained from:
If CMake does not automatically find FFTW then you can define FFTW_ROOT:
If your system has a CUDA capable GPU then pkdgrav3 can use it. The necessary toolkits can be downloaded from nVidia.
This option saves memory and provides sufficient accuracy for cosmological simulations. Only periodic boxes are supported. Enable by setting INTEGER_POSITION when running cmake.
cmake -DINTEGER_POSITION=True ...
The potential for each particle can be output for the lightcone. Enable by setting POTENTIAL_IN_LIGHTCONE when running cmake.
cmake -DPOTENTIAL_IN_LIGHTCONE=True ... Build
Once CMake has been run to produce a Makefile and associated files, the “make” command is used to build the program, as in:
The build can be done in parallel so if you are on, for example, a 16 core machine, the build process can be sped up with:
make -j 16 Running pkdgrav3
This version is run using the MPI system on the cluster in question. Normally this involves a special command (often “mpirun” or “mpiexec”), for example:
mpiexec pkdgrav3 simfile.par
Consult your cluster documentation on how to run MPI programs.