GRASP
|
The General Relativistic Atomic Structure Package (GRASP) is a set of Fortran 90 programs for performing fully-relativistic electron structure calculations of atoms.
Please note: The installation instructions here are for the development version on the
master
branch.To install the latest published release (2018-12-03), go to the "Releases" page, download the tarball from there and refer to the instructions in the README in the tarball.
To compile and install GRASP, first clone this Git repository:
There are two ways to build GRASP: either via CMake or via the Makefile
s in the source tree. Either works and you end up with the GRASP binaries in the bin/
directory.
CMake is the recommended way to build GRASP. The Makefile
-based workflow is still there to make smoother to transition from Makefile
s to a modern build system.
The first step with CMake is to create a separate out-of-source build directory. The configure.sh
script can do that for you:
This will create a build/
directory with the default Release build configuration. However, configure.sh
is just a simple wrapper around a cmake
call and if you need more control over the build, you can always invoke cmake
yourself (see CMake documentation for more information).
To then compile GRASP, you need to go into the out-of-source build directory and simply call make
:
Remarks:
Running make install
instructs CMake to actually install the resulting binaries into the conventional bin/
directory at the root of the repository.
When you run just make
, the resulting binaries will end up under the build/
directory (specifically in build/bin/
). This is useful when developing and debugging, as it allows you to compile many versions of the binaries from the same source tree with different compilation options (e.g. build with debug symbols enabled) by using several out of source build directories.
-j
option to make
(e.g. make -j4 install
to build with four processes).ctest
in the build/
directory. The configuration and source files for the tests are under test/
/Makefile
-based buildThe legacy Makefile
-based build can be performed by simply calling the make
in the top level directory:
In this case, the compilation of each of the libraries and programs happens in their respective directory under src/
and the build artifacts are stored in the source tree. The resulting binaries and libraries will directly get installed under the bin/
and lib/
directories.
To build a specific library or binary you can pass the path to the source directory as the Make target:
Note that any necessary library dependencies will also get built automatically.
WARNING: the Makefile
s do not know about the dependencies between the source files, so parallel builds (i.e. calling make
with the -j
option) does not work.
By default the Makefile
is designed to use gfortran
. The variables affecting GRASP builds are defined and documented at the beginning of the Makefile
.
For the user it should never be necessary to modify the Makefile
itself. Rather, a Make.user
file can be create next to the main Makefile
where the build variables can be overridden. E.g. to use the Intel Fortran compiler instead, you may want to create the following Make.user
file:
where -mkl=sequential
should be set depending on what version of ifort you have access to.
Alternatively, to customize the GNU gfortran build to e.g. use a specific version of the compiler, you can create a Make.user
file such as
To set up a linker search path for the BLAS or LAPACK libraries you can set FC_LD
as follows:
The repository also contains the Make.user.gfortran
and Make.user.ifort
files, which can be used as templates for your own Make.user
file.
This version of GRASP is a major revision of the previous GRASP2K package by [P. Jonsson, G. Gaigalas, J. Bieron, C. Froese Fischer, and I.P. Grant Computer Physics Communication, 184, 2197 - 2203 (2013)]grasp2k-2013 written in FORTRAN 77 style with COMMON and using Cray pointers for memory management. The present version is a FORTRAN95 translation using standard FORTRAN for memory management. In addition, COMMONS have been replaced with MODULES, with some COMMONS merged. Some algorithms have been changed to improve performance for large cases and efficiently.
The previous package, was an extension and modification of GRASP92 by [Farid Parpia, Charlotte Froese Fischer, and Ian Grant. Computer Physics Communication, 94, 249-271 (1996)]grasp92-1996.
This version of GRASP has been published in:
C. Froese Fischer, G. Gaigalas, P. Jönsson, J. Bieroń, "GRASP2018 — a Fortran 95 version of the General Relativistic Atomic Structure Package", Computer Physics Communications, 237, 184-187 (2018), https://doi.org/10.1016/j.cpc.2018.10.032
Development of this package was performed largely by:
Charlotte Froese Fischer | cff@c s.ub c.ca |
Gediminas Gaigalas | Gedim inas .Gaig alas @tfai .vu. lt |
Per Jönsson | per.j onss on@ma u.se |
Jacek Bieron | jacek .bie ron@u j.ed u.pl |
Supporters include:
Jörgen Ekman | jorge n.ek man@m ah.s e |
Ian Grant | ian.g rant @math s.ox .ac.u k |
The GitHub repository is maintained by:
Jon Grumer | jon.g rume r@phy sics .uu.s e |
Please contact the repository manager should you have any questions with regards to bugs or the general development procedure. Contact the leading developer for specific questions related to a certain code.
The package has the structure shown below where executables, after successful compilation, reside in the bin
directory. Compiled libraries are in the lib
directory. Scripts for example runs and case studies are in folders under grasptest
. Source code is in the src
directory and divided into applications in the appl
directory, libraries in the lib
directory and tools in the tool
directory.
The software is distributed with a practical guide to GRASP2018 in PDF-format (click here to download). The guide, which is under Creative Commons Attribution 4.0 International (CC BY 4.0) license, contains full information on how to compile and install the package.
This work was supported by the Chemical Sciences, Geosciences and Biosciences Division, Office of Basic Energy Sciences, Office of Science, U.S. Department of Energy who made the Pacific Sierra translator available and the National Institute of Standards and Technology. Computer resources were made available by Compute Canada. CFF had research support from the Canadian NSERC Discovery Grant 2017-03851. JB acknowledges financial support of the European Regional Development Fund in the framework of the Polish Innovation Economy Operational Program (Contract No. POIG.02.01.00-12-023/08).
The code in this repository is distributed under the [MIT license](LICENSE). The accompanying guide "A practical guide to GRASP2018" is licensed separately under the CC-BY-4.0 (Creative Commons Attribution 4.0 International) license.