Last active
October 6, 2015 02:48
-
-
Save jarvist/2923213 to your computer and use it in GitHub Desktop.
Vague notes written on upload - scripts to calculate Reorganisation Energies with Gaussian
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This follows the roughly nomenclature and working of JKP's thesis. | |
'we follow the method of Sakanou' - JKP Thesis 2.2 Reorganisation Energy | |
1) Run 'polaron_reorg_optimisation_jobs_from_chk.sh' on a checkpoint for an arb molecule | |
--> generates two geometry opt jobs (neutral + charged) | |
2) Once complete, run 'polaron_reorg_energy_jobs_from_geom_chks.sh' on the two checkpoints returned. | |
--> generates 4 energy jobs "*_ion_E.chk" / "_neutral_E.chk" | |
3) Once everything's returned, run 'calc_reorg_energy.sh' on the root of the file names to calculate your energy in eV. | |
Nb: you can of course use your first calculation for the Neutral-struct-neutral-energy value, and also avoid doing 2 redundant energy calculations in part 2. Just copy the files rather than run more jobs. | |
However, this also allows you to do energy calculations at higher level of theory / basis than the geom optimisation (for which b3lyp/6-31g* should be fine). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Forgot about this gist, and made a full blown GitHub repo separately:- https://github.com/jarvist/polaron-lambda | |
Slight edits to allow more easy Method for the E calculations, a version to work from .log files rather than checkpoints, and a better description (perhaps). | |
Consider this Gist obsolete. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for i | |
do | |
N_ion=` grep "SCF Done" "${i}"*neutral_opt_ion_E.log | awk '{print $5}' ` | |
N_neu=` grep "SCF Done" "${i}"*neutral_opt_neutral_E.log | awk '{print $5}' ` | |
I_ion=` grep "SCF Done" "${i}"*ion_opt_ion_E.log | awk '{print $5}' ` | |
I_neu=` grep "SCF Done" "${i}"*ion_opt_neutral_E.log | awk '{print $5}' ` | |
echo "N_ion: " $N_ion "N_neu: " $N_neu "I_ion: " $I_ion "I_neu: " $I_neu | |
# 'we follow the method of Sakanou' - JKP Thesis 2.2 Reorganisation Energy | |
echo "(($I_neu - $N_neu) + ($N_ion - $I_ion) ) * 27.211 " | bc -l | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Jarv ~ 26-4-12 | |
#Generate .com files from a base .chk file for the necessary jobs to calc polaron reorg energy | |
echo "WARNING: Be careful, don't run these jobs till you actually have the checkpoints returned!" | |
CHARGE="-1" #holes... | |
METHOD="b3lyp/6-31g*" | |
for i | |
do | |
#OK; Need: Geom opts in the neutral and charged state | |
#SP energy calcs for each of these in n + c state | |
cp "${i}" "${i%.*}_ion_E.chk" | |
cp "${i}" "${i%.*}_neutral_E.chk" | |
cat > "${i%.*}_ion_E.com" << EOF | |
%chk=${i%.*}_ion_E.chk | |
%Mem=8Gb | |
%nproc=8 | |
#p geom=check guess=read sp ${METHOD} | |
B3lyp auto opt job - neutral state | |
${CHARGE} 2 | |
EOF | |
cat > "${i%.*}_neutral_E.com" << EOF | |
%chk=${i%.*}_neutral_E.chk | |
%Mem=8Gb | |
%nproc=8 | |
#p geom=check guess=read sp ${METHOD} | |
B3lyp auto opt job - neutral state | |
0 1 | |
EOF | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Jarv ~ 26-4-12 | |
#Generate .com files from a base .chk file for the necessary jobs to calc polaron reorg energy | |
CHARGE="-1" #holes... | |
for i | |
do | |
#OK; Need: Geom opts in the neutral and charged state | |
#SP energy calcs for each of these in n + c state | |
cp "${i}" "${i%.*}_ion_opt.chk" | |
cp "${i}" "${i%.*}_neutral_opt.chk" | |
cat > "${i%.*}_ion_opt.com" << EOF | |
%chk=${i%.*}_ion_opt.chk | |
%Mem=8Gb | |
%nproc=8 | |
#p geom=check guess=read opt b3lyp/6-31g* | |
B3lyp auto opt job - neutral state | |
${CHARGE} 2 | |
EOF | |
cat > "${i%.*}_neutral_opt.com" << EOF | |
%chk=${i%.*}_neutral_opt.chk | |
%Mem=8Gb | |
%nproc=8 | |
#p geom=check guess=read opt b3lyp/6-31g* | |
B3lyp auto opt job - neutral state | |
0 1 | |
EOF | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment