Gaussian on Hyak
- Prepare Gaussian 16 input file
- The Route section (# line) of the input specifies the calculation type.
- sp or no keyword: single point energy;
- opt: geometry optimization;
- freq: frequency and thermochemical analysis;
- td: excited state calculation.
- If the input is in XYZ format, edit the route or other keywords in “~/gaussian/xyz2gjf.py” and run
- Either
~/gaussian/xyz2gjf.py input.xyz
if the original input name is “input.xyz”; - Or
for i in *.xyz; do ~/gaussian/xyz2gjf.py $i; done
to convert all files ending with “.xyz” to Gaussian input format.
- Either
- If the input is already in Gaussian input format, the only thing that need to be changed might be the route card. For example, to change “opt b3lyp/6-31g(d,p)” on the 4th line of all gjf files to “td(Nstates=20) um062x/6-31+g(d,p)”, type
for i in *.gjf; do sed -i "4s#opt b3lyp/6-31g(d,p)#td(Nstates=20) um062x/6-31+g(d,p)#g" $i; done
. You can check if it is changed correctly by typinghead *gjf
.
- The Route section (# line) of the input specifies the calculation type.
- Generate slurm file using
~/gaussian/gaussian-klone.py input-file-name partition number-of-node time-in-hour
.- For example, to create a task to run “input.gjf” on stf partition for 2h 30min on 1 node: type
~/gaussian/gaussian-klone.py input.gjf stf 1 2.5
. Then “input.sh” will be created. - To create multiple tasks for all files ending with “.gjf”:
for i in *.gjf; do ~/gaussian/gaussian-klone.py $i stf 1 2.5; done
.
- For example, to create a task to run “input.gjf” on stf partition for 2h 30min on 1 node: type
- Submit the task:
sbatch file-name-of-sh
- To submit multiple sh files:
for i in *.sh; do sbatch $i; done
.
- To submit multiple sh files: