DIRAC
In this section:
Description
According to the page of DIRAC, the DIRAC program calculates molecular properties using relativistic quantum chemical methods. It is named after P.A.M. Dirac, the father of relativistic electronic structure theory.
Available Versions
dirac/12.3-mpi (default)
dirac/12.3-serial
dirac/12.3-smp
Serial Job Submission
submit_dirac_serial.sh
#!/bin/bash
#SBATCH -J dirac_serial
#SBATCH -N 1
#SBATCH -n 1
#SBATCH -t 05:00:00
#SBATCH --mem=8G
export INPUT="methanol.xyz hf.inp"
export OUTPUT="*.out *..."
module load dirac/12.3-serial
job-nanny pam --dirac=$DIRAC_EXEC --scratch=/tmp \
--mol=methanol.xyz --inp=hf.inp
SMP (OpenMP) Job Submission
submit_dirac_smp.sh
#!/bin/bash
#SBATCH -J dirac_smp
#SBATCH -N 1
#SBATCH -c 4
#SBATCH -t 08:00:00
#SBATCH --mem=16G
export INPUT="methanol.xyz hf.inp"
export OUTPUT="*.out *..."
export OMP_NUM_THREADS=$SLURM_CPUS_PER_TASK
module load dirac/12.3-smp
job-nanny pam --dirac=$DIRAC_EXEC_SMP --scratch=/tmp \
--mol=methanol.xyz --inp=hf.inp
MPI Job Submission
submit_dirac_mpi.sh
#!/bin/bash
#SBATCH -J dirac_mpi
#SBATCH -N 2
#SBATCH --ntasks-per-node=28
#SBATCH -t 24:00:00
#SBATCH --mem-per-cpu=2G
export INPUT="methanol.xyz hf.inp"
export OUTPUT="*.out *..."
module load dirac/12.3-mpi
job-nanny mpirun -np $SLURM_NTASKS pam --dirac=$DIRAC_EXEC_MPI \
--scratch=/store --mol=methanol.xyz --inp=hf.inp
Important
For MPI jobs, use --scratch=/store to have shared space between nodes.
Example Input File
hf.inp
**DIRAC
.TITLE
Methanol HF calculation
.WAVE FUNCTIONS
**WAVE FUNCTIONS
.SCF
*SCF
.CLOSED SHELL
9
**HAMILTONIAN
.DEFAULT
**INTEGRALS
*READIN
.DEFAULT
**MOLECULE
*BASIS
.DEFAULT
cc-pVDZ
*READIN
.DEFAULT
**END OF
Coordinates File (XYZ)
methanol.xyz
6
Methanol molecule
C 0.0000 0.0000 0.0000
O 0.0000 0.0000 1.4280
H 0.9860 0.0000 -0.4960
H -0.4390 -0.8510 -0.4960
H -0.4390 0.8510 -0.4960
H 0.8510 0.0000 1.8860
Job Array for Multiple Molecules
submit_dirac_array.sh
#!/bin/bash
#SBATCH -J dirac_array
#SBATCH --array=1-5
#SBATCH -N 1
#SBATCH -c 4
#SBATCH -t 12:00:00
#SBATCH --mem=16G
MOLECULES=(
"methanol"
"ethanol"
"water"
"ammonia"
"benzene"
)
MOL=${MOLECULES[$SLURM_ARRAY_TASK_ID-1]}
export INPUT="${MOL}.xyz ${MOL}.inp"
export OUTPUT="${MOL}_results/"
export OMP_NUM_THREADS=$SLURM_CPUS_PER_TASK
module load dirac/12.3-smp
mkdir -p ${MOL}_results
cd ${MOL}_results
cp ../${MOL}.xyz .
cp ../${MOL}.inp .
job-nanny pam --dirac=$DIRAC_EXEC_SMP --scratch=/tmp \
--mol=${MOL}.xyz --inp=${MOL}.inp
References
Documentation: http://www.diracprogram.org/doc/release-17/
Tutorials: http://www.diracprogram.org/doc/release-17/tutorials/
See also
GAMESS - Alternative for quantum chemistry
Gaussian - Alternative for quantum chemistry
Running Simulations - How to submit jobs