RMSD

This is part of the colvar module |

Calculate the RMSD with respect to a reference structure.

The aim with this colvar it to calculate something like:

\[ d(X,X') = \vert X-X' \vert \]

where \( X \) is the instantaneous position of all the atoms in the system and \( X' \) is the positions of the atoms in some reference structure provided as input. \( d(X,X') \) thus measures the distance all the atoms have moved away from this reference configuration. Oftentimes, it is only the internal motions of the structure - i.e. not the translations of the center of mass or the rotations of the reference frame - that are interesting. Hence, when calculating the the root-mean-square deviation between the atoms in two configurations you must first superimpose the two structures in some way. At present PLUMED provides two distinct ways of performing this superposition. The first method is applied when you use TYPE=SIMPLE in the input line. This instruction tells PLUMED that the root mean square deviation is to be calculated after the positions of the geometric centers in the reference and instantaneous configurations are aligned. In other words \(d(X,x')\) is to be calculated using:

\[ d(X,X') = \sqrt{ \sum_i \sum_\alpha^{x,y,z} \frac{w_i}{\sum_j w_j}( X_{i,\alpha}-com_\alpha(X)-{X'}_{i,\alpha}+com_\alpha(X') )^2 } \]

with

\[ com_\alpha(X)= \sum_i \frac{w'_{i}}{\sum_j w'_j}X_{i,\alpha} \]

and

\[ com_\alpha(X')= \sum_i \frac{w'_{i}}{\sum_j w'_j}X'_{i,\alpha} \]

Obviously, \( com_\alpha(X) \) and \( com_\alpha(X') \) represent the positions of the center of mass in the reference and instantaneous configurations if the weights $w'$ are set equal to the atomic masses. If the weights are all set equal to one, however, \(com_\alpha(X) \) and \( com_\alpha(X') \) are the positions of the geometric centers. Notice that there are sets of weights: \( w' \) and \( w \). The first is used to calculate the position of the center of mass (so it determines how the atoms are *aligned*). Meanwhile, the second is used when calculating how far the atoms have actually been *displaced*. These weights are assigned in the reference configuration that you provide as input (i.e. the appear in the input file to this action that you set using REFERENCE=whatever.pdb). This input reference configuration consists of a simple pdb file containing the set of atoms for which you want to calculate the RMSD displacement and their positions in the reference configuration. It is important to note that the indices in this pdb need to be set correctly. The indices in this file determine the indices of the instantaneous atomic positions that are used by PLUMED when calculating this colvar. As such if you want to calculate the RMSD distance moved by the first, fourth, sixth and twenty eighth atoms in the MD codes input file then the indices of the corresponding reference positions in this pdb file should be set equal to 1, 4, 6 and 28.

The pdb input file should also contain the values of \(w\) and \(w'\). In particular, the OCCUPANCY column (the first column after the coordinates) is used provides the values of \( w'\) that are used to calculate the position of the center of mass. The BETA column (the second column after the Cartesian coordinates) is used to provide the \( w \) values which are used in the the calculation of the displacement. Please note that it is possible to use fractional values for beta and for the occupancy. However, we recommend you only do this when you really know what you are doing however as the results can be rather strange.

In PDB files the atomic coordinates and box lengths should be in Angstroms unless you are working with natural units. If you are working with natural units then the coordinates should be in your natural length unit. For more details on the PDB file format visit http://www.wwpdb.org/docs.html. Make sure your PDB file is correctly formatted as explained in this page.

A different method is used to calculate the RMSD distance when you use TYPE=OPTIMAL on the input line. In this case the root mean square deviation is calculated after the positions of geometric centers in the reference and instantaneous configurations are aligned AND after an optimal alignment of the two frames is performed so that motion due to rotation of the reference frame between the two structures is removed. The equation for \(d(X,X')\) in this case reads:

\[ d(X,X') = \sqrt{ \sum_i \sum_\alpha^{x,y,z} \frac{w_i}{\sum_j w_j}[ X_{i,\alpha}-com_\alpha(X)- \sum_\beta M(X,X',w')_{\alpha,\beta}({X'}_{i,\beta}-com_\beta(X')) ]^2 } \]

where \( M(X,X',w') \) is the optimal alignment matrix which is calculated using the Kearsley [67] algorithm. Again different sets of weights are used for the alignment ( \(w'\)) and for the displacement calculations ( \(w\)). This gives a great deal of flexibility as it allows you to use a different sets of atoms (which may or may not overlap) for the alignment and displacement parts of the calculation. This may be very useful when you want to calculate how a ligand moves about in a protein cavity as you can use the protein as a reference system and do no alignment of the ligand.

(Note: when this form of RMSD is used to calculate the secondary structure variables (ALPHARMSD, ANTIBETARMSD and PARABETARMSD all the atoms in the segment are assumed to be part of both the alignment and displacement sets and all weights are set equal to one)

Please note that there are a number of other methods for calculating the distance between the instantaneous configuration and a reference configuration that are available in plumed. More information on these various methods can be found in the section of the manual on Distances from reference configurations.

When running with periodic boundary conditions, the atoms should be in the proper periodic image. This is done automatically since PLUMED 2.5, by considering the ordered list of atoms and rebuilding molecules using a procedure that is equivalent to that done in WHOLEMOLECULES . Notice that rebuilding is local to this action. This is different from WHOLEMOLECULES which actually modifies the coordinates stored in PLUMED.

In case you want to recover the old behavior you should use the NOPBC flag. In that case you need to take care that atoms are in the correct periodic image.

- Examples

The following tells plumed to calculate the RMSD distance between the positions of the atoms in the reference file and their instantaneous position. The Kearsley algorithm is used so this is done optimally.

Click on the labels of the actions for more information on what each action computes

RMSDREFERENCE=file.pdbcompulsory keyworda file in pdb format containing the reference structure and the atoms involved in the CV.TYPE=OPTIMALcompulsory keyword ( default=SIMPLE )the manner in which RMSD alignment is performed.

The reference configuration is specified in a pdb file that will have a format similar to the one shown below:

ATOM 1 CL ALA 1 -3.171 0.295 2.045 1.00 1.00 ATOM 5 CLP ALA 1 -1.819 -0.143 1.679 1.00 1.00 ATOM 6 OL ALA 1 -1.177 -0.889 2.401 1.00 1.00 ATOM 7 NL ALA 1 -1.313 0.341 0.529 1.00 1.00 ATOM 8 HL ALA 1 -1.845 0.961 -0.011 1.00 1.00 END

...

- Glossary of keywords and components

- Compulsory keywords

REFERENCE | a file in pdb format containing the reference structure and the atoms involved in the CV. |

TYPE | ( default=SIMPLE ) the manner in which RMSD alignment is performed. Should be OPTIMAL or SIMPLE. |

- Options

NUMERICAL_DERIVATIVES | ( default=off ) calculate the derivatives for these quantities numerically |

NOPBC | ( default=off ) ignore the periodic boundary conditions when calculating distances |

SQUARED | ( default=off ) This should be set if you want mean squared displacement instead of RMSD |