File: tipnp_equil.rst

package info (click to toggle)
python-ase 3.26.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 15,484 kB
  • sloc: python: 148,112; xml: 2,728; makefile: 110; javascript: 47
file content (47 lines) | stat: -rw-r--r-- 1,507 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
.. _tipnp water box equilibration:

Equilibrating a TIPnP Water Box
===============================

This tutorial shows how to use the TIP3P and TIP4P force fields in
ASE.


Since the TIPnP type water interpotentials are for rigid
molecules, there are no intramolecular force terms, and we need to
constrain all internal degrees of freedom. For this, we're
using the RATTLE-type constraints of the :ref:`FixBondLengths` class to
constrain all internal atomic distances (O-H1, O-H2, and H1-H2) for
each molecule.

The box is equillibrated with the Langevin thermostat.


For efficiency, we first equillibrate a smaller box, and then repeat that
once more for the final equillibration. However, the potentials are not
parallelized, and are mainly included for testing and for use with QM/MM
tasks, so expect to let it run for some time.


The following is for TIP3P:

.. literalinclude:: tip3p_equil.py

.. note::

  The temperature calculated by ASE is assuming all degrees of freedom
  are available to the system. Since the constraints have removed the 3
  vibrational modes from each water, the shown temperature will be 2/3
  of the actual value.

The procedure for the TIP4P force field is the same, with the following
exception: the atomic sequence **must** be OHH, OHH, ... .

So to perform the same task using TIP4P, you simply have to import
that calculator instead:

::

    from ase.calculators.tip4p import TIP4P, rOH, angleHOH

More info about the TIP4P potential: :mod:`ase.calculators.tip4p`