CASTEP

Guidance last updated: 20 October 2026

CASTEP is a leading code for calculating the properties of materials from first principles.

Using density functional theory, it can simulate a wide range of material properties including energetics, structure at the atomic level, vibrational properties, electronic response properties etc.

In particular it has a wide range of spectroscopic features that link directly to experiment, such as infra-red and Raman spectroscopies, NMR, and core level spectra.

Documentation: https://castep-docs.github.io/castep-docs/

Licensing

CASTEP is available under a free-of-charge academic licence.

Interactive Usage

After connecting to Stanage (see Establishing a SSH connection), start an interactive session:

salloc

CASTEP can be made available by running:

module load CASTEP/25.1.2-foss-2024a

With the module loaded, list the available executables using:

ls "$EBROOTCASTEP/bin"

Run calculations with srun within an interactive session or a batch job.

Batch Submission - Parallel

The parallel executable is castep.mpi. The following example batch submission script uses four MPI tasks on one node. Run it from a directory containing graphite.cell and graphite.param, prepared following the CASTEP band structure tutorial. Enable write_orbitals: true in the parameter file for orbitals2bands.

#!/bin/bash
#SBATCH --job-name=castep_graphite
#SBATCH --nodes=1
#SBATCH --ntasks=4
#SBATCH --cpus-per-task=1
#SBATCH --mem-per-cpu=2000
#SBATCH --time=00:30:00
#Email notifications to me@somedomain.com
#SBATCH --mail-user=me@somedomain.com
#Email notifications about the job
#SBATCH --mail-type=ALL

module load CASTEP/25.1.2-foss-2024a
export OMP_NUM_THREADS=1

srun --export=ALL castep.mpi graphite
cp graphite.bands graphite.bands.orig
srun --export=ALL --ntasks=1 orbitals2bands graphite

Checkpointing and restarting

Section guidance last updated: 30 October 2026

CASTEP can save intermediate calculation states in .check files and continue an interrupted run using continuation in the .param file. Checkpoint output must be enabled before the original run; the available restart points depend on the calculation type. See CASTEP’s checkpoint and restart guide.

Installation notes

CASTEP was installed using Easybuild, build details can be found in $EBROOTCASTEP/easybuild with a given module loaded.

Direct dependencies for latest version of CASTEP