Phonopy code is developped to calculate the phonon and thermal properties plus some other functionalities.
To install the code click on the following link:
How to install Phonopy Code to calculate Phonon and Thermal properties
There are 2 ways to do phonon calculations which are:
1- Supercell method based upon finite differences technique
2- DFPT method based upon Density Functional Perturbative Theory
For more information check the following links:
https://www.vasp.at/wiki/index.php/Phonons:_Theory#Finite_differences
https://www.vasp.at/wiki/index.php/Phonons_from_finite_differences
http://cmt.dur.ac.uk/sjc/thesis_prt/node39.html
We will use the supercell method and calculate the DOS and Band structure of NiS2.
We need some input files and some scripts.
POSCAR
Si O 1.00000000000000 4.2266540199664249 0.0000000000000000 0.0000000000000000 0.0000000000000000 4.2266540199664249 0.0000000000000000 0.0000000000000000 0.0000000000000000 2.6888359272289208 2 4 Direct 0.0000000000000000 0.0000000000000000 0.0000000000000000 0.5000000000000000 0.5000000000000000 0.5000000000000000 0.3067891334429594 0.3067891334429594 0.0000000000000000 0.6932108665570406 0.6932108665570406 0.0000000000000000 0.1932108665570406 0.8067891334429594 0.5000000000000000 0.8067891334429594 0.1932108665570406 0.5000000000000000
INCAR
PREC = Accurate IBRION = -1 ENCUT = 500 EDIFF = 1.0e-08 ISMEAR = 0; SIGMA = 0.01 IALGO = 38 LREAL = .FALSE. LWAVE = .FALSE. LCHARG = .FALSE.
KPOINT
KPOINTS
0
Gamma
18 18 6
0 0 0
Creation of POTCAR of SiO2 using POTCAR-Si and POTCAR-O
cat POTCAR-Si POTCAR-O > POTCAR
POTCAR-Si
POTCAR-O
Script phon.sh for phonon calculations
#!/bin/bash
# Command to run vasp in current directory
RUN_VASP="vasp_std"
N=$(ls POSCAR-* | wc -l)
echo $N
for s in $(eval echo "{001..$N}")
do
d=${s%%.POSCAR}
mkdir disp-$d
(
cd disp-$d
cp ../INCAR INCAR
cp ../POTCAR POTCAR
cp ../KPOINT KPOINT
cp ../POSCAR-$d POSCAR
$RUN_VASP
cd ..
)
done
Calculation
1- Creation of displacement POSCARs
% conda activate phonopy
(phonopy) % phonopy -d --dim="2 2 3"
You should find the files, SPOSCAR
, phonopy_disp.yaml
, and
POSCAR-{number}
as follows:
% ls
INCAR KPOINT phonopy_disp.yaml POSCAR POSCAR-001 POSCAR-002 POSCAR-003 SPOSCAR
SPOSCAR
is the perfect supercell structure, phonopy_disp.yaml
contains the information on displacements, and POSCAR-{number}
are
the supercells with atomic displacements. POSCAR-{number}
corresponds to the different atomic displacements written in
phonopy_disp.yaml
.
2- Phonon calculations
chmod +x phon.sh
./phon.sh
3- Calculation of sets of forces
% phonopy -f disp-001/vasprun.xml disp-002/vasprun.xml disp-003/vasprun.xml
or
% phonopy -f disp-{001..003}/vasprun.xml
Post-process
In the post-process,
Force constants are calculated from the sets of forces
A part of dynamical matrix is built from the force constants
Phonon frequencies and eigenvectors are calculated from the dynamical matrices with the specified q-points.
For mesh sampling calculation, prepare the following setting file
named, e.g., mesh.conf
:
ATOM_NAME = Si O
DIM = 2 2 3
MP = 8 8 8
The density of states (DOS) is plotted by:
% phonopy -p mesh.conf
Thermal properties are calculated with the sampling mesh by:
% phonopy -t mesh.conf
You should check the convergence with respect to the mesh numbers. Thermal properties can be plotted by:
% phonopy -t -p mesh.conf
Projected DOS is calculated by the following setting file named, e.g.,
pdos.conf
:
ATOM_NAME = Si O
DIM = 2 2 3
MP = 8 8 8
PDOS = 1 2, 3 4 5 6
and plotted by:
% phonopy -p pdos.conf
Band structure is calculated with the following setting file named, e.g., band.conf by:
ATOM_NAME = Si O
DIM = 2 2 3
BAND = 0.5 0.5 0.5 0.0 0.0 0.0 0.5 0.5 0.0 0.0 0.5 0.0
The band structure is plotted by:
% phonopy -p band.conf
In either case, by setting the -s
option, the plot is going to be
saved in the PDF format. If you don’t need to plot DOS, the (partial)
DOS is just calculated using the --dos
option.
0 Comments