CUBY logo
back to Interfaces

Restraints interface

Difference between revisions from 2012/04/25 11:40 and 2012/04/25 11:15.
This interface serves as a [modifier|Interfaces#Modifiers] for other calculations. It allows to add harmonic restraints in internal coordinates. The restraints can be applied not only to single atoms, but also to groups of atoms, acting on centers of mass of the groups.

Input for this interface uses only one keyword, restraints, that contains the list of restraints as an [array|YAML]. Each entry is a semicolo-separated list:
{{distance|angle|torsion|distance difference; value; force_constant; atom_selection1; atom_selection2; ...}}
{{distance|angle|torsion|distance_difference; value; force_constant; atom_selection1; atom_selection2; ...}}

First is specification of the type of internal coordinate, then its value in energy minimum (distance in Angstroms, angles in degrees), force constant (kcal/angstrom, kcal/radian) and then [selections|Atom selection expressions] of the atoms or groups.

The distance_difference coordinate is calculated as a difference between two interatomic distances: x = distance(1,2) - distance (3,4). Therefore, it requires four atom selections.

!Keywords
* restraints

!Example
In this example, we use the restraints interface itself (not as modifier) to define simple forcefield for a hydrogen peroxide molecule. To define the optimum geometry, we use all three types of restraints available.

An very bad guess of the geometry
{{4

H  1.0 0.0 0.0
O  0.0 1.0 0.0
O  0.0 0.0 5.0
H  1.0 0.0 8.0
}}

can be optimized using the following input file:
{{interface: restraints
restraints:
- distance; 0.95; 10; 1; 2
- distance; 1.47; 10; 2; 3
- distance; 0.95; 10; 3; 4
- angle; 94.8; 10; 1; 2; 3
- angle; 94.8; 10; 2; 3; 4
- torsion; 111.5; 10; 1;2;3;4
}}