Page 1 of 2

VASP-MD velocities and VACF

Posted: Mon Jun 20, 2011 4:06 pm
by santana
Dear all,
I want to evaluate the VACF and frequencies using MD from VASP. I found a post in the VASP forum where the xdat2vdat.pl was recommended to generate the velocities using the XDATCAR.
Is this script not longer available?

Re: VASP-MD velocities and VACF

Posted: Tue Jun 21, 2011 1:24 am
by graeme
This script may not have been updated for vasp5.2. Vasp has changed the format of the xdatcar, and I don't think anyone has used this script since then. I'll attach a copy of it here in case it is of use. But do check the output to make sure that it makes sense. It requires a massfile as well, with a simple list of the atom number and the mass, one per line. It may also be limited to orthogonal boxes, which is another reason we may have removed it from the tar file.

Re: VASP-MD velocities and VACF

Posted: Mon Feb 13, 2012 5:05 pm
by stauff
The xdat2vdat.pl script has been updated for vasp5.2-format XDATCAR files. It also requires the associated OUTCAR file. It can be found with the other vtstscripts.

Re: VASP-MD velocities and VACF

Posted: Thu Mar 22, 2012 9:28 am
by vimal
I am using this script to calculate the VACF.
I end up with the VDATCAR file which looks similar to
XDATCAR with the following additional lines for each poscar.

KINETIC ENERGY (eV): 9.591403906717447
TEMP EFF (K): 290.989883855749042

my question is how should i proceed from here to get the VACF.
Could you please help.

best regards,
vimal

Re: VASP-MD velocities and VACF

Posted: Thu Mar 22, 2012 3:48 pm
by graeme
We do not have a script to do this. Now that you have the velocities, taking a bunch of dot products to get the autocorrelation function is not too difficult. If you write such a script, we would be happy to include it in the set.

Re: VASP-MD velocities and VACF

Posted: Mon Apr 02, 2012 3:02 pm
by vimal
Dear Graeme,

I find that the KE and Temperature are listed in
the OUTCAR file already.

kinetic Energy EKIN = 10.100042 (temperature 305.22 K)
kinetic Energy EKIN = 10.307751 (temperature 311.50 K)
kinetic Energy EKIN = 10.466675 (temperature 316.30 K)

But it really differs from the one calculated from xdat2vdat script that
is attached on the VDATCAR.

Why this happens?
May be i am wrong. Please correct.

Best regards,
Vimal

Re: VASP-MD velocities and VACF

Posted: Mon Apr 02, 2012 3:23 pm
by graeme
Can you post your OUTCAR, POSCAR, XDATCAR, and VDATCAR so that we can look into this?

Re: VASP-MD velocities and VACF

Posted: Thu Feb 06, 2014 2:31 pm
by anoop
Dear all,

I had faced a similar problem mentioned in this post.
From OUTCAR
kinetic Energy EKIN = 3.786618 (temperature 305.15 K)
kinetic Energy EKIN = 3.913352 (temperature 315.36 K)

Where as after using the xdat2vdat script shows the lower values.
KINETIC ENERGY (eV): 1.310660628736558
TEMP EFF (K): 105.622127787439126

Could you please sugest, where It went wrong. Many thanks in advance.

Thanking you,

Regards,
Anoop

Re: VASP-MD velocities and VACF

Posted: Wed Feb 12, 2014 3:15 pm
by graeme
If you can post a .tar.gz file of the calculation, I'll take a look. This is not a widely used script and there may be some problem with it.

Re: VASP-MD velocities and VACF

Posted: Sat Apr 26, 2014 9:54 am
by tyuttian
VASP version for my compute is 4.6.3, i use the script (see attachment) and have a "outcar"," massfile ",''xdatcar'' in the same file.
but the vdatcr can not be produced completely(see attachment).

The formation of 'massfile': (for the example of CH4):

1 1 12.0
2 1 1.0
3 1 1.0
4 1 1.0
5 1 1.0

Re: VASP-MD velocities and VACF

Posted: Tue Apr 29, 2014 2:04 pm
by graeme
I would need all the input files to reproduce the issue and see what is wrong.
It is possible that the script only works for vasp.5.*

Re: VASP-MD velocities and VACF

Posted: Tue Apr 29, 2014 7:30 pm
by graeme
anoop, there does clearly seem to be a problem here. Two new students will be taking a look at this and hopefully make an update with a corrected script.

Re: VASP-MD velocities and VACF

Posted: Sun May 04, 2014 5:57 am
by tyuttian
graeme, thank you very much for replying and helping. These days are national holiday of my country, so my replay is late.

The script of "xdat2vdat.pl" have two versions: One for vasp.5.*, and another of vasp.4.*.(Right?). I selected the second one.

The input files are too large to upload. I delete some content, only save two steps of 5000.

Re: VASP-MD velocities and VACF

Posted: Thu May 22, 2014 8:41 pm
by wc5879
Hi Y'all
It turned out that the script
xdat2vdat.pl
cannot read mass properly from the OUTCAR
this has been corrected

It has been verified that the script calculates velocities and kinetic energies and effective temperatures correctly. The calculation is strictly based on XDATCAR therefore its result may deviate from VASP by a little bit. The deviation is most likely due to the induced velocity changes done by VASP, as a result of certain flags such as SMASS

So, the script should do exactly what it is meant for.
If there is any other problems, let me know!

Ray

Re: VASP-MD velocities and VACF

Posted: Thu Nov 12, 2020 6:27 pm
by keduemml
Hello,
Where can I find the most updated version of the script? And does anyone know if it is compatible with VASP 6?