Kabsch algorithm
≈ 3 min read
Names in other languages
No names in other languages are held for this entry yet.
Article bodies are English and are not machine-translated. A name in another language is not a translation of the article.
The Kabsch algorithm, also known as the Kabsch-Umeyama algorithm, named after Wolfgang Kabsch and Shinji Umeyama, is a method for calculating the optimal rotation matrix that minimizes the RMSD (root mean squared deviation) between two paired sets of points. It is useful for point-set registration in computer graphics, and in cheminformatics and bioinformatics to compare molecular and protein structures (in particular, see root-mean-square deviation (bioinformatics)). The algorithm only computes the rotation matrix, but it also requires the computation of a translation vector. When both the translation and rotation are actually performed, the algorithm is sometimes called partial Procrustes superimposition (see also orthogonal Procrustes problem).
The Kabsch algorithm, also known as the Kabsch-Umeyama algorithm, named after Wolfgang Kabsch and Shinji Umeyama, is a method for calculating the optimal rotation matrix that minimizes the RMSD (root mean squared deviation) between two paired sets of points. It is useful for point-set registration in computer graphics, and in cheminformatics and bioinformatics to compare molecular and protein structures (in particular, see root-mean-square deviation (bioinformatics)). The algorithm only computes the rotation matrix, but it also requires the computation of a translation vector. When both the translation and rotation are actually performed, the algorithm is sometimes called partial Procrustes superimposition (see also orthogonal Procrustes problem). Let and be two sets, each containing points in \mathbb{R}^n . We want to find the transformation from to . For simplicity, we will consider the three-dimensional case ( n = 3 ). The sets and can each be represented by matrices with the first row containing the coordinates of the first point, the second row containing the coordinates of the second point, and so on, as shown in this matrix: \begin{pmatrix} x_1 & y_1 & z_1 \\ x_2 & y_2 & z_2 \\ \vdots & \vdots & \vdots \\ x_N & y_N & z_N \end{pmatrix} The algorithm works in three steps: a translation, the computation of a covariance matrix, and the computation of the optimal rotation matrix. H = P^\mathsf{T}Q \, or, using summation notation, H_{ij} = \sum_{k = 1}^N P_{ki} Q_{kj}, which is a cross-covariance matrix when and are seen as data matrices. R = \left(H^\mathsf{T} H\right)^\frac12 H^{-1}, but implementing a numerical solution to this formula becomes complicated when all special cases are accounted for (for example, the case of not having an inverse). If singular value decomposition (SVD) routines are available the optimal rotation, , can be calculated using the following algorithm. First, calculate the SVD of the covariance matrix , H = U \Sigma V^\mathsf{T} where and are orthogonal and \Sigma is diagonal. Next, record if the orthogonal matrices contain a reflection, d = \det\left(U V^\mathsf{T}\right) = \det(U) \det(V). Finally, calculate our optimal rotation matrix as R = U \begin{pmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & d \end{pmatrix} V^\mathsf{T}. This minimizes \sum_{k = 1}^N\|R q_k - p_k\|_2^2 , where q_k and p_k are rows in and respectively. Alternatively, optimal rotation matrix can also be directly evaluated as quaternion. This alternative description has been used in the development of a rigorous method for removing rigid-body motions from molecular dynamics trajectories of flexible molecules. In 2002 a generalization for the application to probability distributions (continuous or not) was also proposed.
Text derived from https://en.wikipedia.org/w/index.php?oldid=1374741346 under CC BY-SA 4.0; modifications have been made.