This Python script, get_VDOS.py
, is designed to calculate the Vibrational Density of States (VDOS)
from molecular dynamics trajectory files by computing the Fourier transform of the velocity
autocorrelation function. It supports different file formats and offers flexibility in terms of
data processing and analysis.
- Supports XYZ and NETCDF file formats.
- Option to choose between full and bond-specific modes.
- Various windowing functions for Fourier Transform: Gaussian, Blackman-Harris, Hamming, Hann.
- Option for numerical or file-based velocity calculations.
- Autocorrelation Function (ACF) calculation and FFT for VDOS computation.
- Python 3
- Libraries: NumPy, SciPy, ASE (for XYZ files)
- A trajectory file in either XYZ or NETCDF format.
Clone this repository or download get_VDOS.py
directly. Ensure you have the required Python version and libraries installed.
git clone https://github.com/JonathanSemelak/VDOS.git
cd VDOS
Run the script from the command line with the required arguments.
python get_VDOS.py -i [input file] -o [output file] -dt [delta time] [other optional arguments]
-i
,--input
: Input file name (required).-o
,--output
: Output file name (required).-m
,--mode
: Mode of operation ('full' or 'bond', default: 'full').-dt
,--delta_t
: Delta time in femtoseconds (required).-b
,--bond
: Bond indices (two integers, required if mode is 'bond').-w
,--window_kind
: Window kind for FFT (default: 'Gaussian').-f
,--force_numerical
: Force numerical calculation of velocities (default: False).-n
,--use_normalized_vectors
: Use the norm of the coordinates (or velocities) instead of individual coordinates (default: False).
python get_VDOS.py -i trajectory.xyz -o vdos_output.txt -dt 0.5
The script outputs the VDOS data in the specified output file, including wavenumbers and intensity values.
Contributions, issues, and feature requests are welcome. Feel free to check issues page if you want to contribute.
This project incorporates modified functions from Velocity-ACF by HUAN WANG. We thank the author for their valuable work which formed a foundation for some of the features in this project.