Gibbs free energy calculation with VASP outputs

868 views
Skip to first unread message

leila salimi

unread,
Jul 11, 2017, 5:55:45 AM7/11/17
to TAMkin
Hi,

As I am new on using TAMkin, I got the error at the first try. I want to calculate the gibbs free energy of H2O by vasp calculation. I tried to use this script and I got this error:

# Import the tamkin libarary.
from tamkin import *
# Load the gaussian data.
molecule = load_molecule_vasp("contcar", "outcar_freq", outcar_energy=None, energy=None, multiplicity=1, is_periodic=True)

# Perform the normal mode analysis
nma = NMA(molecule)
# Construct a partition function object with the typical gas phase contributions.
pf = PartFun(nma,ExtTrans())# [ExtTrans(), ExtRot()])

# Write some general information about the molecule and the partition function
# to a file.
pf.write_to_file("partfun.txt")

# Write an extensive overview of the thermodynamic properties to a file:
ta = ThermoAnalysis(pf, [300,400,500,600])
ta.write_to_file("thermo.csv")




Traceback (most recent call last):
  File "./thermo.py", line 41, in <module>
    molecule = load_molecule_vasp("contcar", "outcar_freq", outcar_energy=None, energy=None, multiplicity=1, is_periodic=True)
  File "/home/lsalimi/.local/lib/python2.7/site-packages/tamkin/io/vasp.py", line 100, in load_molecule_vasp
    symbol_counts = [int(w) for w in f.next().split()]
ValueError: invalid literal for int() with base 10: 'Selective'


Please let me know what is the error ?  The output from vasp is "contacr" and "outcar_freq".  I am getting confused because in some scripts I saw outcar_energy !
If you share me the same script for Gibbs free energy calculation, I can get more familiar with the code.

Thanks in advance and Regards,
Leila
contcar
outcar_freq
thermo.py

Toon Verstraelen

unread,
Jul 11, 2017, 6:57:35 AM7/11/17
to tam...@googlegroups.com
Dear Leila,

I noticed that you are using an old version of VASP (4.6), which we do not
support. The files are not compatible with the newer version (5.3).

Other than that, some changes are needed for a molecular calculations:

- is_periodic=False
- ExtRot() has to be included.

Can you switch to the latest version of VASP?

Kind Regards,

Toon
> --
> You received this message because you are subscribed to the Google Groups "TAMkin"
> group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
> tamkin+un...@googlegroups.com <mailto:tamkin+un...@googlegroups.com>.
> To post to this group, send email to tam...@googlegroups.com
> <mailto:tam...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/tamkin/a4c10e50-9792-4b2f-908e-e29584f70438%40googlegroups.com
> <https://groups.google.com/d/msgid/tamkin/a4c10e50-9792-4b2f-908e-e29584f70438%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.


--
Prof. Dr. ir. Toon Verstraelen
Center for Molecular Modeling
Ghent University
Technologiepark 903,
B9052 Zwijnaarde
Belgium
Tel: +32 9 264 65 56
GSM: +32 471 66 68 83
E-mail: Toon.Ver...@UGent.be
http://molmod.UGent.be/
http://molmod.UGent.be/software/

Toon Verstraelen

unread,
Jul 11, 2017, 6:58:11 AM7/11/17
to tam...@googlegroups.com
Dear Leila,

I noticed that you are using an old version of VASP (4.6), which we do not
support. The files are not compatible with the newer version (5.3).

Other than that, some changes are needed for a molecular calculations:

- is_periodic=False
- ExtRot() has to be included.

Can you switch to the latest version of VASP?

Kind Regards,

Toon

P.S. It is better to read a CONTCAR file because it has a more standardized structure.


On 07/11/2017 11:55 AM, leila salimi wrote:

leila salimi

unread,
Jul 11, 2017, 7:40:06 AM7/11/17
to tam...@googlegroups.com
Dear Toon,

Thanks for your fast reply. I will try to switch to the newer version (5.3).

Regards,
Leila

To unsubscribe from this group and stop receiving emails from it, send an email to tamkin+unsubscribe@googlegroups.com <mailto:tamkin+unsubscribe@googlegroups.com>.


--
Prof. Dr. ir. Toon Verstraelen
Center for Molecular Modeling
Ghent University
Technologiepark 903,
B9052 Zwijnaarde
Belgium
Tel: +32 9 264 65 56
GSM: +32 471 66 68 83
E-mail: Toon.Ver...@UGent.be
http://molmod.UGent.be/
http://molmod.UGent.be/software/

--
You received this message because you are subscribed to a topic in the Google Groups "TAMkin" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tamkin/YOtDZKq5ILQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tamkin+unsubscribe@googlegroups.com.
To post to this group, send email to tam...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tamkin/ca1fe49b-7d39-366e-96e0-cbe423430b69%40UGent.be.

leila salimi

unread,
Jul 20, 2017, 12:02:20 PM7/20/17
to tam...@googlegroups.com
Dear Toon,

Now I have access to the newer version of vasp and I got some output from Tamkin.
As you suggested that I have to add the rotational part and I defined the partition function like this:

pf = PartFun(nma, [ExtTrans(), ExtRot()])

I got this error:

Traceback (most recent call last):
  File "./thermo.py", line 46, in <module>
    pf = PartFun(nma, [ExtTrans(), ExtRot()])
  File "/home/lsalimi/.local/lib/python2.7/site-packages/tamkin/partf.py", line 1353, in __init__
    term.init_part_fun(nma, self)
  File "/home/lsalimi/.local/lib/python2.7/site-packages/tamkin/partf.py", line 1016, in init_part_fun
    self.symmetry_number = tmp_mol.compute_rotsym()
  File "/home/lsalimi/.local/lib/python2.7/site-packages/molmod/molecules.py", line 291, in compute_rotsym
    raise ValueError("The rotational symmetry number can only be computed when the graph is fully connected.")
ValueError: rotational: The rotational symmetry number can only be computed when the graph is fully connected.

Should I add some argument for Extrot() ?

Thanks in advance and Regards,
Leila
On Tue, Jul 11, 2017 at 12:58 PM, Toon Verstraelen <Toon.Ver...@ugent.be> wrote:
To unsubscribe from this group and stop receiving emails from it, send an email to tamkin+unsubscribe@googlegroups.com <mailto:tamkin+unsubscribe@googlegroups.com>.


--
Prof. Dr. ir. Toon Verstraelen
Center for Molecular Modeling
Ghent University
Technologiepark 903,
B9052 Zwijnaarde
Belgium
Tel: +32 9 264 65 56
GSM: +32 471 66 68 83
E-mail: Toon.Ver...@UGent.be
http://molmod.UGent.be/
http://molmod.UGent.be/software/

--
You received this message because you are subscribed to a topic in the Google Groups "TAMkin" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tamkin/YOtDZKq5ILQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tamkin+unsubscribe@googlegroups.com.
To post to this group, send email to tam...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tamkin/ca1fe49b-7d39-366e-96e0-cbe423430b69%40UGent.be.

Toon Verstraelen

unread,
Jul 20, 2017, 1:11:15 PM7/20/17
to tam...@googlegroups.com

Hi Leila,

The algorithm for the rotational symmetry is rather complicated and seems to break down for your case. The simplest solution is to bypass it by setting the rotational symmetry manually, e.g. with ExtRot(symmetry_number=2). However, the error you get could point to other issues that you may need to address. In principle, when you provide as input a small molecule in a large periodic box, TAMkin should be able to recognize bonded atoms using the simple distance criterion. That is the step that failed, so I guess the geometry is somewhat off, or there are two molecules in your input. Can you check that?

Best Regards,

Toon

To unsubscribe from this group and stop receiving emails from it, send an email to tamkin+un...@googlegroups.com.

To post to this group, send email to tam...@googlegroups.com.

leila salimi

unread,
Jul 21, 2017, 6:43:49 AM7/21/17
to tam...@googlegroups.com
Dear Toon,

Thanks for your reply. Actually I tried with one H2O molecule in a cubic box (gas phase) and calculated the vibrational frequencies. When I try without any symmetry number, in the output I got
"Rotational symmetry number: 1 "
And when I try with ExtRot(symmetry_number=2) , in the output is written "Rotational symmetry number: 2 "
The rest of the files are similar.
I am wondering if something is wrong here!!

I got 3 real wavenumbers :

 1589.4  3734.7  3845.0

Regards,
Leila

To unsubscribe from this group and stop receiving emails from it, send an email to tamkin+unsubscribe@googlegroups.com.

To post to this group, send email to tam...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "TAMkin" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tamkin/YOtDZKq5ILQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tamkin+unsubscribe@googlegroups.com.
To post to this group, send email to tam...@googlegroups.com.

Toon Verstraelen

unread,
Jul 22, 2017, 4:33:19 AM7/22/17
to tam...@googlegroups.com

Dear Leila,

The effect of the rotational symmetry number is relatively small, mostly giving a small contribution to the entropy. It should differ a little. Do you see a small change in the entropy? Can you also check if the moments of inertia are correct?

I'd like to test your files if you don't mind. It should work, even without manually specifying the rotational symmetry number.

Best Regards,

Toon

To unsubscribe from this group and stop receiving emails from it, send an email to tamkin+un...@googlegroups.com.

To post to this group, send email to tam...@googlegroups.com.

leila salimi

unread,
Jul 24, 2017, 9:12:45 AM7/24/17
to tam...@googlegroups.com
Dear Toon,

Thank you very much. you are right, there are small differences on S(rotational). I checked the moments of inertia, they are in good agreement with other references.
I will send you the files in another email.

Kind Regards,
Leila

To unsubscribe from this group and stop receiving emails from it, send an email to tamkin+unsubscribe@googlegroups.com.

To post to this group, send email to tam...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "TAMkin" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tamkin/YOtDZKq5ILQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tamkin+unsubscribe@googlegroups.com.
To post to this group, send email to tam...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages