CASTEP

Description

CASTEP is a software package which uses density functional theory to provide a good atomic-level description of all manner of materials and molecules. CASTEP can give information about total energies, forces and stresses on an atomic system, as well as calculating optimum geometries, band structures, optical spectra, phonon spectra and much more. It can also perform molecular dynamics simulations.

User instructions

CASTEP is installed as a module. Run:

$ module load castep/17.21

to add CASTEP 17.21 and assorted utilities to your PATH, and similarly for other versions.

See the documentation and tutorials available on the CASTEP website for details on running CASTEP.

Note

The CASTEP binary is now called castep.mpi rather than castep.

License

CASTEP is a commercial code marketed by Accelrys. UK academics qualify for a free license. Mike Finnis and Adrian Sutton signed the license agreements so that the entirety of TYC and CMTH would be covered. (Many other group members have connections to the project.)

Admin notes

It is worth scanning README.INSTALL and the top-level makefile, both of which are clear and easy to read.

Later versions set a default optimisation flags as -xHost, which causes problems as not all workstations have AVX instructions. Rather than disabling the (helpful) AVX instructions for all processors, I instead set OPT_CPU to -axSSE2,SSE4.1,SSE4.2,AVX in obj/platforms/linux_x86_64_ifort17.mk. I also needed to modify occurrences of include 'mpif.h' to use mpi (above Implicit none) in several routines in the source code or we hit an error in compilation that seems particular to the combination of Intel 2017 and openmpi.

I then ran:

$ module load intel/2017.4.196 mkl/2017.4.196 openmpi/2.1.1
$ make COMMS_ARCH=mpi FFT=mkl MATHLIBS=mkl10 BUILD=fast
$ make COMMS_ARCH=mpi FFT=mkl MATHLIBS=mkl10 BUILD=fast install install-tools

Note that the first make asks for paths to the MKL library. These can be left blank as the search paths are already set in the MKL module file. The install command places executable files (and tools) into bin/linux_x86_64_ifort17. I copied these by hand to /common/debian/9.1/MPI/intel/2017.4/openmpi/2.1/castep/castep-17.21/bin.