Automatically generates visualizations of vibrational modes computed from the density functional theory (DFT) code VASP, like this acoustic mode of ZrIN:
Petrashih modified
- such that it can read the OUTCAR of normal mode calculation in Parallelization rather than the original OUTCAR
- use math module instead of pylab
- create a data folder for output files
in Apr.18 2019
The file modes_to_vesta.py quickly converts the modes calculated in
a VASP density functional perturbation theory (DFPT) calculation (IBRION=7 or 8) to
the Visualization for Electronic and STructural Analysis VESTA file format. The final result is a VESTA file that allows you to visualize each vibrational mode computed from DFPT.
In a single folder, include the following 4 files:
POSCAR, which gives the atomic positions and unit cell used as input to the DFPT calculationOUTCAR, which should hold the results of an IBRION=7 or 8 calculationposcar.vesta. This file is the direct result of opening thePOSCARfile directly in VESTA and saving the file with the filenameposcarand extension.vesta(note that poscar is lower-case). No modes/displacement vectors should be visible in VESTA prior to saving.modes_to_vesta.py, which comes from this repo.
To run, do the following:
$ python modes_to_vest.py <optional-vesta-filename>
Only the first two arguments are needed; the third argument is optional and can be used to specify an alternative VESTA filename (i.e., a name different from poscar.vesta)
The result is a set of 3N files where N is the number of atoms in the unit cell. Each file has the format mode_<freq>.vesta, where is the mode frequency in cm-1.
Some parts of modes_to_vesta.py have been adapted from vasp_raman.py and Phonopy
