The difficulty of protein structure alignment under the RMSD
 Shuai Cheng Li^{1}Email author
DOI: 10.1186/1748718881
© Li; licensee BioMed Central Ltd. 2013
Received: 8 December 2011
Accepted: 17 December 2012
Published: 4 January 2013
Abstract
Background
Protein structure alignment is often modeled as the largest common point set (LCP) problem based on the Root Mean Square Deviation (RMSD), a measure commonly used to evaluate structural similarity. In the problem, each residue is represented by the coordinate of the Cα atom, and a structure is modeled as a sequence of 3D points. Out of two such sequences, one is to find two equalsized subsequences of the maximum length, and a bijection between the points of the subsequences which gives an RMSD within a given threshold. The problem is considered to be difficult in terms of time complexity, but the reasons for its difficulty is not wellunderstood. Improving this time complexity is considered important in protein structure prediction and structural comparison, where the task of comparing very numerous structures is commonly encountered.
Results
To study why the LCP problem is difficult, we define a natural variant of the problem, called the minimum aligned distance (MAD). In the MAD problem, the length of the subsequences to obtain is specified in the input; and instead of fulfilling a threshold, the RMSD between the points of the two subsequences is to be minimized. Our results show that the difficulty of the two problems does not lie solely in the combinatorial complexity of finding the optimal subsequences, or in the task of superimposing the structures. By placing a limit on the distance between consecutive points, and assuming that the points are specified as integral values, we show that both problems are equally difficult, in the sense that they are reducible to each other. In this case, both problems can be exactly solved in polynomial time, although the time complexity remains high.
Conclusions
We showed insights and techniques which we hope will lead to practical algorithms for the LCP problem for protein structures. The study identified two important factors in the problem’s complexity: (1) The lack of a limit in the distance between the consecutive points of a structure; (2) The arbitrariness of the precision allowed in the input values. Both issues are of little practical concern for the purpose of protein structure alignment. When these factors are removed, the LCP problem is as hard as that of minimizing the RMSD (MAD problem), and can be solved exactly in polynomial time.
Keywords
Protein Structure Alignment RMSD LCPBackground
A common approach to understand the properties of a protein is to compare it to other proteins. Proteins that are similar, in terms of either their amino acid sequences or 3dimensional structures, often share similar functions, or are related evolutionarily. The latter, structural comparison, is particularly interesting since protein structures are known to be more evolutionarily conserved than the biological sequences which encode them. Furthermore, proteins of similar structures may have similar functionality, even when their sequences differ [1].
 1.
the number of residues (points) or percentage of total residues (points) matched in the alignment.
 2.
the root mean square deviation (RMSD) of the matched residues (points).
In general, the RMSD need not be minimized. It suffices that it is within a reasonable threshold. Hence, a good alignment is customarily taken to be one which maximizes the number of residue matches, within a given RMSD threshold. Many structural alignment methods are based on this principle. The computational complexity of finding an optimal solution to the problem is not well understood. Shibuya et al. formulated a restricted version of the problem, and showed the problem to NPhard when the dimensionality is arbitrary. It is open whether their problem is NPhard in 3dimension [5]. Other problems related to structural comparison based on the RMSD have been found to be difficult. For example, the problem of finding a substructure from multiple 3dimensional structures which minimizes the total RMSD, is NPhard [6].
For the variants of the alignment problem that are not based on the RMSD, we have the following results. When the objective is to maximize the number of point matches which are no more than a threshold distance apart, the problem is solvable in O(n^{32.5}) time, where n is the number of points [7]. The contact map overlap problem, where a graph is created out of each structure, and the problem is one of comparing the two graphs, is NPhard [8], and remains NPhard even when we require points that are matchable to be within a threshold distance [9]. These results, together with an early result which shows a related problem called threading to be NPhard [10], have traditionally led molecular biologists to believe that the structural alignment problem is difficult in general (e.g. [11–13]), even though a PTAS exists for the problem under a broad class of distance measures [14]. Heuristic algorithms have also been proposed for many variants of structural alignment problem [15–23]. While these methods perform reasonably well in general, they provide no guarantee on the quality of their results.
As noted by Shibuya et al., relatively few theoretical results have been obtained on problems defined over the RMSD, and the general problem of structural alignment under the RMSD remains open [5]. At present, whether the problem is intractable or not is not only of theoretical interests but also of practical concerns, due to advances in protein structure prediction which requires the comparison of very numerous structures. In this paper we show mathematical insights and techniques which we hope will lead to practical algorithms for the problem.

if either a mapping that contains the optimal mapping is known (Theorem 3), or

if the optimal superposition is known (Lemma 1),
Our study shows that the difficulty of the LCP problem is also very much due to the two factors: (1) the problem allows the input coordinates to be of any arbitrary precision, and (2) it assumes no limit on the distance between two consecutive Cα atoms.

Given a polynomial time algorithm for finding a largest alignment of RMSD below a threshold d, one can efficiently compute an alignment of a given size ℓ which minimizes the RMSD (Theorem 7). (Since the other direction is easy, this shows that the two problems are of similar difficulty.)

The structural alignment problem under the RMSD is solvable exactly in polynomial time (Theorem 10).
Preliminary
Notations and definitions
A protein structure for alignment purpose is modeled as a finite, ordered sequence of three dimensional (3D) points. Hence, a structure of n residues is written as (p_{1},p_{2},...,p_{ n }), where each point${p}_{i}\phantom{\rule{0.3em}{0ex}}\in \phantom{\rule{0.3em}{0ex}}{\mathbb{R}}^{3}.$In the ‘Results assuming integral coordinates and restricting distance between points’ section, we will further assume each p_{ i } to be integral. We write P^{′} ⊆ P iff P^{′} is a subsequence of P, and write f:P ↦ Q iff f is a mapping which maps points in the sequence P to points in the sequence Q.
Problem statements
Largest Common Point (LCP) set problem definition under RMSD
LCP problem by the RMSD measure  

Input:  sequences P = (p_{1},…,p_{ n }), Q = (q_{1},…,q_{ m }) and distance 
threshold $\theta \in \mathbb{R}$. Without loss of generality assume m ≥ n.  
Output:  (i) subsequences P^{′} ⊆ P, Q^{′} ⊆ Q, P^{′} = Q^{′}, and 
(ii) bijection f:P^{′} ↦ Q^{′}, fulfilling the following conditions:  
(A) RMSD(P^{′},f(P^{′})) ≤ θ,  
(B) the score l = P^{′} is maximized. 
where t is a rigid transformation. The RMSD, with its corresponding transformation t, can be computed in linear time [26].
Minimum Aligned Distance (MAD) problem definition under RMSD
MAD problem by the RMSD measure  

Input:  sequences P = (p_{1},…,p_{ n }), Q = (q_{1},…,q_{ m }) and $\ell \in \mathbb{I}$. 
Without loss of generality assume m ≥ n.  
Output:  (i) subsequences P^{′} ⊆ P, Q^{′} ⊆ Q, P^{′} = Q^{′}, and 
(ii) bijection f:P^{′} ↦ Q^{′}, fulfilling the following conditions:  
(A) P^{′} = ℓ,  
(B) d = RMSD(P^{′},f(p^{′})) is minimized. 
Clearly, if the MAD problem is solvable in polynomial time, then the LCP problem is solvable in polynomial time. However, the other direction is unclear. Theorem 7 will show that for P and Q of integral coordinates, if the LCP problem is solvable in polynomial time, then the MAD problem is solvable in polynomial time.
We let $\widehat{\mathbf{P}}$, $\widehat{\mathbf{Q}}$, $\widehat{\mathbf{f}}$, ℓ and d_{ opt } denote an optimal P^{′}, Q^{′}, f, l and d, respectively. The optimal rigid transformation for superimposing $\widehat{\mathbf{P}}$ and $\widehat{\mathbf{Q}}$ is denoted $\mathcal{T}$, and can be computed from $\widehat{\mathbf{P}}$, $\widehat{\mathbf{Q}}$ and $\widehat{\mathbf{f}}$. The symbol ${c}_{P}^{\mathit{\text{max}}}$ denotes the largest value in the coordinates of P, ${c}_{Q}^{\mathit{\text{max}}}$ the largest value in the coordinates of Q, and ${c}_{\mathit{\text{max}}}=\text{max}\{{c}_{P}^{\mathit{\text{max}}},{c}_{Q}^{\mathit{\text{max}}}\}$, and we know that c_{ max } = O(n) for protein structures.
Results for general LCP and MAD
Complexity of the LCP and MAD when the optimal superposition is known
Since two point sequences with a known mapping can be superimposed optimally under the RMSD in linear time [26], it is natural to ask if the difficulty in LCP or MAD lies solely in the combinatorial complexity of finding the optimal subsets, i.e. $\widehat{\mathbf{P}}$ and $\widehat{\mathbf{Q}}$. Our results show the contrary: if the optimal superposition $\mathcal{T}$ is known, both problems can be solved in polynomial time.
The base case of the recursion is obvious. Dynamic programming can be employed to fill up the respective M[i,j;k] values. After all the values are filled, one can find the maximum k, such that the squared sum is no more than k θ^{2} for the LCP problem. The MAD problem can be solved similarly.
The nonsequential case can be similarly solved using the maximumflow minimumcost problem [27]. The following lemma states these results.
Lemma 1
If an optimal transformation $\mathcal{T}$ is known, both the LCP problem and the MAD problem can be solved in O(mnℓ) time.
Complexity of the LCP and MAD when the matching between the point sets is known
We next ask if the difficulty in the LCP and MAD could be due to the task of superimposing P and Q in an optimal manner to identify the subsets $\widehat{\mathbf{P}}$ and $\widehat{\mathbf{Q}}$. To examine this possibility, we remove the combinatorial task of examining each of the possible mapping between the points, by assuming a bijection F which contains the optimal mapping. (Note that this results in the problem known as model superposition in structural biology.) Again, our results show the resultant LCP and MAD problems to be solvable exactly in polynomial time.
Assume that F is a bijection that maps points in P to points in Q. Let ${P}^{\prime}=({p}_{1}^{\prime},\dots ,{p}_{l}^{\prime})$ be the domain of F and ${Q}^{\prime}=({q}_{1}^{\prime},\dots ,{q}_{l}^{\prime})$ be the range of F. Without loss of generality assume that F is sequential, and hence $F\left({p}_{i}^{\prime}\right)={q}_{i}^{\prime}$.
One can exhaustively evaluate all the subsequences of P^{′} for one with the least RMSD. However, since the number of such subsequences is exponential in l, this does not immediately give us a polynomial time solution.
If a rigid transformation T for Q^{′} is given, and all the pairs $({p}_{i}^{\prime},{q}_{i}^{\prime})$, 1 ≤ i ≤ l are sorted according to the value $\left\rightT\left({p}_{i}^{\prime}\right){q}_{i}^{\prime}\left\right$, the MAD problem is then to choose the first ℓ pairs from $({p}_{i}^{\prime},{q}_{i}^{\prime})$, 1 ≤ i ≤ l, and the LCP problem is to choose the first ℓ pairs, such that $\mathit{\text{RMSD}}\left(\right({p}_{1}^{\prime},\mathrm{...},{p}_{\ell}^{\prime}),({q}_{1}^{\prime},\mathrm{...},{q}_{\ell}^{\prime}\left)\right)\le \theta $ and ℓ = l or $\mathit{RMSD}\left(\right({p}_{1}^{\prime},\mathrm{...},{p}_{\ell}^{\prime},{p}_{\ell +1}^{\prime}),({q}_{1}^{\prime},\mathrm{...},{q}_{\ell}^{\prime},{q}_{\ell +1}^{\prime}\left)\right)>\theta $. This gives us an incentive to obtain a total ordering of $\left\rightT\left({p}_{i}^{\prime}\right){q}_{i}^{\prime}\left\right$, which will allow us to solve the MAD problem by selecting the first ℓ pairs in the ordering. The set of transformations which produce the same total according to $\left\rightT\left({p}_{i}^{\prime}\right){q}_{i}^{\prime}\left\right$, yield the same result for the MAD problem, and therefore these transformations are equivalent. This enables us to design a discrete version of the problem.
For clarity, we first present an algorithm with only translation.
With translations only
Consider the space of all translation vectors in ${\mathbb{R}}^{3}$, and consider each vector as a point in this space (not the space that P and Q are in). The values that the variable t in Equation 4 may take form a plane in this translation space. The plane partitions the translation space into two types of translations, T_{1} and T_{2} say, where $\left\right{T}_{1}\left({q}_{i}^{\prime}\right){p}_{i}^{\prime}\left\right>\left\right{T}_{1}\left({p}_{j}^{\prime}\right){q}_{j}^{\prime}\left\right$ and $\left\right{T}_{2}\left({q}_{i}^{\prime}\right){p}_{i}^{\prime}\left\right\left\right{T}_{2}\left({p}_{j}^{\prime}\right){q}_{j}^{\prime}\left\right$. Since there are l pairs, there are O(l) planes, which partition the space into O(l^{3}) cells.
The translations in each cell result in the same ordering of the pairs with respect to $\left\rightT\left({p}_{i}^{\prime}\right){q}_{i}^{\prime}\left\right$. For each cell, this total order can be obtained in O(l) time from any given total order of its neighbor cells, since the change is O(1). Therefore, the MAD solution can be obtained in amortized time O(l) for each cell, and the LCP solutions thus can be obtained in time O(l^{2}). Hence the total runtime is of O(ℓ^{4}) for the MAD problem, and O(ℓ^{5}) for the LCP problem of translations, with the given mapping F.
With rigid transformations
The rigid transformations which separate the two relations $\left\right{T}_{1}\left({q}_{i}^{\prime}\right){p}_{i}^{\prime}\left\right>\left\right{T}_{1}\left({p}_{j}^{\prime}\right){q}_{j}^{\prime}\left\right$ and $\left\right{T}_{2}\left({q}_{i}^{\prime}\right){p}_{i}^{\prime}\left\right\left\right{T}_{2}\left({p}_{j}^{\prime}\right){q}_{j}^{\prime}\left\right$ are as in Equation 3.
A rotation matrix contains three variables, which is specified using three angles, say α_{1}, α_{2}, α_{3}, each from Π to Π. Let r_{ i } = cos α_{ i }, s_{ i } = cos α_{ i }, then Equation 5 can be considered as a polynomial of nine variables in degree six. The nine variables are r_{ i }, s_{ i } and the three variables for translation. In total, there are O(l) such polynomials.
We know the following theorem from the literature.
Theorem 2
[7, 28]Given a set of k polynomials,$\mathcal{P}=\{{f}_{1},\mathrm{...},{f}_{k}\}$, where each polynomial has a maximum degree of s, contains at most r variables, and in addition all the coefficients are rational, then all the sign conditions can be determined by O(k(k/r)^{ r }s^{O(r)}) arithmetic operations. A sign condition V is the vector of signs for some point$u\in {\mathbb{R}}^{k}$; that is, V = (sign(f_{1}(u)),...,sign(f_{ k }(u))). Two points$u,{u}^{\prime}\in {\mathbb{R}}^{k}$are equivalent if their sign condition vectors are the same.
Each sign vector represents the transformations of the cell it belongs to, and it determines a total order of the pairs. Similar as in the case of translation, with Theorem 2, we have
Theorem 3
Given a bijection F:P^{′} → Q^{′}, where P^{′} = l, then the MAD problem can be solved in O(l^{10}) time and the LCP problem can be solved in O(l^{11}) time.
Results assuming integral coordinates and restricting distance between points
One possible contributing factor to the difficulty of the LCP problem could be its flexibility in allowing input coordinates of any arbitrary precision. This is because intuitively, this arbitrariness in the precision introduces the burden of examining the solution space in an unbounded manner. However, such an exhaustive search is not necessary for the purpose of protein structure comparison, since coordinates of protein structures are specified only to three decimal places in the commonly used PDB format.
In this section, we restrict the precision in which the input coordinates may be specified. Without loss of generality, we assume that the input coordinates are given in integers, since numbers of any fixed precision can be trivially scaled up to integral values. This assumption is used to obtain Lemma 5 and Theorem 7.
We also place an upper bound on the distance between consecutive points according to the structure of proteins. As a result, c_{ max } is bounded by n, as follows.

For a connected structure, the points are at most O(n) distance apart. That is, c _{ max } is of O(n).

For a globular structure, the points are at most O(n ^{1/3}) distance apart [14]. That is, c _{ max } is of O(n ^{1/3}).
 1.
the LCP problem is of similar difficulty as the MAD problem, and
 2.
both problems can be solved exactly in polynomial time.
Properties of protein structures
Upper and lower bounds of RMSD
We first establish some bounds to the RMSD. The minimum RMSD is zero if $\mathcal{T}$ brings $\widehat{\mathbf{Q}}$ to coincide exactly with $\widehat{\mathbf{P}}$. This case is referred to as the exact matching, which can be easily solved by the method in [29]. However, if we assume the RMSD to be nonzero, then a lower bound and an upper bound for it can be computed.
Let Π be a permutation of {1,...,ℓ}. For the sequence X = (x_{1},…,x_{ n }), let ${d}_{i,j}^{X}$1 ≤ i,j ≤ n, denote the Euclidean distance between x_{ i } and x_{ j }. The following results, which are proven in the Appendix, can be obtained.
Lemma 4
Lemma 5 (Lower bound)
If RMSD$(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})\ne 0$, then RMSD$(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})\ge \frac{\sqrt{12{c}_{\mathit{\text{max}}}^{2}}\sqrt{12{c}_{\mathit{\text{max}}}^{2}1}}{\sqrt{2\ell}}$.
Lemma 6 (Upper bound)
RMSD$(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})\le 4\sqrt{3}{c}_{\mathit{\text{max}}}$.
Using an algorithm for the LCP to solve the MAD problem
Employing an algorithm for the LCP problem to solve the MAD problem
Input:  sequences P = (p_{1},…,p_{ n }), Q = (q_{1},…,q_{ m }) and $\ell \in \mathbb{I}$. 
Without loss of generality assume m ≥ n.  
Output:  (i) subsequences P^{′} ⊆ P, Q^{′} ⊆ Q, P^{′} = Q^{′}, and 
(ii) mapping f:P^{′} ↦ Q^{′}, fulfilling the following conditions:  
(A) P^{′} = ℓ,  
(B) d = RMSD(P^{′},f(p^{′})) is minimized.  
1.  l ← 0, u ← ℓ c_{ max } 
2.  m ← 1/2(l + u) 
3.  Call LCP to solve the instance (P,Q,m). 
4.  If the LCP solution has size no less than ℓ 
u ← m  
else  
l ← m  
5.  If $ul\le \frac{\sqrt{12{c}_{\mathit{\text{max}}}^{2}}\sqrt{12{c}_{\mathit{\text{max}}}^{2}1}}{\sqrt{2\ell}}$, 
Output the most recent LCP solution of size no less than ℓ.  
Otherwise, repeat Steps 25. 
Theorem 7
Solving the MAD problem is equivalent to solving O(logℓ c_{ max }) instances of the LCP problem.
Since the reduction from the LCP problem to the MAD problem is obvious, we conclude that the two problems are of similar difficulty.
Polynomial time algorithm
We now show that under the two conditions, the LCP and MAD problem can be solved in polynomial time.
As shown in the ‘Complexity of the LCP and MAD when the optimal superposition is known’ section, when the optimal superposition is known, there are polynomial time algorithms for LCP and MAD. We consider an enumeration of all the possible superpositions. Under the two conditions, we claim that there are at most polynomially many such superpositions.
 1.
Translate $\widehat{\mathbf{P}}$ and $\widehat{\mathbf{Q}}$ such that their centroids are at the origin.
 2.
Then, rotate $\widehat{\mathbf{Q}}$ to find the superposition with the minimum distance [26].
Denote the translations to obtain the optimal solution for P and Q as t_{ P } and t_{ Q }, respectively, and denote the optimal rotation by $\widehat{\mathbf{R}}$.
We now show that one needs to examine only polynomially many translations and rotation combinations to discover the values for t_{ P }, t_{ Q }, and $\widehat{\mathbf{R}}$. These numbers can be effectively bounded by n when properties of protein structures are taken into account. We first describe these properties.
Number of translations
The centroid of $\widehat{\mathbf{P}}$ is $\frac{\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{p}^{\prime}}{\ell}$. To bring $\widehat{\mathbf{P}}$ to origin, the translation is $\frac{\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{p}^{\prime}}{\ell}$. Clearly, all the three coordinates of $\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{p}^{\prime}$ are integers since all the coordinates of the points in p ∈ P are integers. The value of xcoordinate of $\frac{\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{p}^{\prime}}{\ell}$ is bounded by $\frac{\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{x}_{{p}^{\prime}}}{\ell}\le \frac{\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{c}_{P}^{\mathit{\text{max}}}}{\ell}\le {c}_{\mathit{\text{max}}}$. Similarly, all the three coordinates of the translation $\frac{\sum _{{p}^{\prime}\in \widehat{\mathbf{P}}}{p}^{\prime}}{\ell}$ are bounded within the interval [c_{ max },c_{ max }]. To obtain an optimal MAD solution, the translation on $\widehat{\mathbf{P}}$ must be in the form of $\frac{I}{\ell}$, where I is an integer. Since it is possible to examine all the possible values for I, we have the following result.
Lemma 8
t_{ P },t_{ Q } ∈ {I/ℓ  ℓ c_{ max } ≤ I ≤ ℓ c_{ max }}^{3}.
Number of rotations
With the centroids of $\widehat{\mathbf{P}}$ and $\widehat{\mathbf{Q}}$ translated to the origin, we proceed to identify the rotation in our algorithm. Let X_{ P } denote the vector $\u3008{x}_{{p}_{1}},\mathrm{...},{x}_{{p}_{\ell}}\u3009$ for structure P. Similarly we define Y_{ P } and Z_{ P }.
Let ${\widehat{\mathbf{P}}}_{t}=({p}_{1}^{\prime}t,\mathrm{...},{p}_{\ell}^{\prime}t)$ and ${\widehat{\mathbf{Q}}}_{t}=({q}_{1}^{\prime}t,\mathrm{...},{q}_{\ell}^{\prime}t)$, ${p}_{i}^{\prime}\in \widehat{\mathbf{P}}$, ${q}_{i}^{\prime}\in \widehat{\mathbf{Q}}$.
Each above matrix is decomposed by the singular value decomposition, and a rotation matrix is produced hereafter.
Also, it is clear that ${U}_{{\widehat{\mathbf{P}}}_{{\mathit{\text{t}}}_{P}}}\bullet {V}_{{\widehat{\mathbf{Q}}}_{{\mathit{\text{t}}}_{Q}}}$ is in the form of I/ℓ^{2}, where I is an integer. The matrix in Equation 8 has nine elements; we denote e ∈ M if e is one of these elements. The following lemma follows.
Lemma 9
For each element e ∈ M in Equation 8, $e\in \{I/{\ell}^{2}4{\ell}^{3}{c}_{\mathit{\text{max}}}^{2}\le I\le 4{\ell}^{3}{c}_{\mathit{\text{max}}}^{2}\}$.
Polynomial time algorithm
A polynomial time algorithm for the MAD problem
Input:  sequences P = (p_{1},…,p_{ n }), Q = (q_{1},…,q_{ m }) and $\ell \in \mathbb{I}$. 
Without loss of generality assume m ≥ n.  
Output:  (i) subsets P^{′} ⊆ P, Q^{′} ⊆ Q, P^{′} = Q^{′}, and 
(ii) mapping f:P^{ ′ }↦Q^{′}, fulfilling the following conditions:  
(A) P^{′} = ℓ,  
(B) d = RMSD(P^{′},f(p^{′})) is minimized.  
1.  For each translation t ∈ {I/ℓ  ℓ c_{ max } ≤ I ≤ ℓ c_{ max }}^{3}, 
For each 3 × 3 matrix M, where ∀e ∈ M, e ∈ {I/ℓ^{2},  
$\phantom{\rule{2em}{0ex}}\{4{\ell}^{3}{c}_{\mathit{\text{max}}}^{2}\le I\le 4{\ell}^{3}{c}_{\mathit{\text{max}}}^{2}\}$  
Compute rotation matrix R from M.  
$Q\leftarrow \mathit{RQ}t$.  
Apply an algorithm for the case where the superposition  
is known to P and $Q$ (as discussed in the ‘Complexity Of  
The LCP And MAD When The Optimal Superposition Is  
Known’ section), and denote the solution MAD(P, $Q$).  
2.  Output the MAD(P, $Q$) of the smallest RMSD as the solution. 
According to Lemma 8, the optimal translation t_{ P } and t_{ Q } must be within {I/ℓ  ℓ c_{ max } ≤ I ≤ ℓ c_{ max }}^{3}. To find the optimal rotation matrix, it suffices that we try all the possible values for each entry in Equation 8. Since there are ${\ell}^{27}{c}_{\mathit{\text{max}}}^{18}$ matrices, the number of total transformations to examine is bounded by $O\left({\ell}^{33}{c}_{\mathit{\text{max}}}^{34}\right)$. It takes time O(mnℓ) to identify the MAD solution for each transformation. An LCP solution can be obtained by iterating ℓ from 1 to min{m,n} for the MAD problem.
The running time consists of the productions of three parts: the number of possible translations, the number of possible rotation matrix, and the running time for given a rotation matrix and a translation combination (that is, the running time when then transformation is known). These numbers are bounded by c_{ max }, which is bounded by m when we consider the properties of protein structures. Likewise, c_{ max } is polynomial with respect to the input size if coded in unary.
Theorem 10
The MAD problem can be solved in O(ℓ^{34}m^{25}n) time for protein structures, and in O(ℓ^{34}m^{9}n) time for globular protein structures. The LCP problem can be solved in O(ℓ^{35}m^{25}n) time for protein structures, and in O(ℓ^{35}m^{9}n) time for globular protein structures. Both the MAD and LCP problems are pseudopolynomially solvable for general point sets.
Conclusions
We studied the LCP problem under the RMSD in this paper. As it turns out, the difficulty of the problem does not lie in its combinatoric aspect or its structural superposition aspect alone. That is, if the problem is hard, then it must be a consequence of both aspects. Our results show that if one is allowed to compromise on one of the aspects, then the problem is solvable exactly in polynomial time. Regrettably, we do not see how the optimal solution can be obtained in both cases.
On the other hand, we showed an encouraging result: There is a polynomial time algorithm which solves the problem optimally, if one restricts the input coordinates in the problem to be integral, and places a limit on the distance between consecutive points. These requirements do not pose any restriction to typical uses in the analysis of protein structures, since protein structures are specified only to a fixed precision in practice, and there is an upper bound to the distance between protein residues.
One problem is that our proposed polynomial time algorithm remains high in time complexity. We hope that the present work will provide the foundation for future efforts to obtain algorithms with lower runtime complexities.
Appendix
In this Appendix, we include the proofs of the results in the paper which have been omitted to enhance readability.
Lemma 4
Proof
Without loss of generality, we just show that
$\frac{1}{\sqrt{2\ell}}\sqrt{\sum _{i=1}^{\u230a\ell /2\u230b}{d}_{i,i+\u230a\ell /2\u230b}^{\widehat{\mathbf{P}}}{d}_{i,i+\u230a\ell /2\u230b}^{\widehat{\mathbf{Q}}}{}^{2}}\le \mathit{RMSD}(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})$.
Let
${r}_{i}=\left\right\mathcal{T}\left({q}_{i}\right){p}_{i}{}^{2}+\left\mathcal{T}\right({q}_{i+\u230a\ell /2\u230b}){p}_{i+\u230a\ell /2\u230b}{}^{2}$,
u_{ i }=〈p_{ i },p_{i + ⌊ℓ/2⌋}〉, and
v_{ i }=〈q_{ i },q_{i + ⌊ℓ/2⌋}〉, where 1≤i≤⌊ℓ/2⌋.
Lemma 5
If RMSD$(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})\ne 0$, then RMSD$(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})\ge \frac{\sqrt{12{c}_{\mathit{\text{max}}}^{2}}\sqrt{12{c}_{\mathit{\text{max}}}^{2}1}}{\sqrt{2\ell}}$.
Proof
□
Lemma 6
RMSD$(\widehat{\mathbf{P}},\widehat{\mathbf{Q}})\le 4\sqrt{3}{c}_{\mathit{\text{max}}}$.
Proof
□
Abbreviations
 LCP:

Largest Common Point set
 RMSD:

Root Mean Square Deviation.
Declarations
Acknowledgements
This work is supported by the CityU SRG 7002731. The author thanks the useful discussions with Prof. Richard M. Karp
Authors’ Affiliations
References
 Perutz MF, Rossmann MG, Cullis AF, Muirhead H, Will G: North ACT: Structure of myoglobin: a threedimensional Fourier synthesis at 5.5 Angstrom resolution. Nature. 1960, 185: 416422.View ArticlePubMedGoogle Scholar
 R Kolodny PK, Levitt M: Comprehensive evaluation of protein structure alignment methods: scoring by geometric measures. J Comput Biol. 2005, 346 (4): 11731188.Google Scholar
 Sippl MJ: On distance and similarity in fold space. Bioinformatics. 2008, 24 (6): 872873.View ArticlePubMedGoogle Scholar
 , : Structural alignment of proteins by a novel TOPOFIT method, as a superimposition of common volumes at a topomax point. Protein Sci. 2004, 13 (7): 18651874.View ArticleGoogle Scholar
 Shibuya T, Jansso J, Sadakane K: Lineartime protein 3D structure searching with insertions and deletions. Algorithms Mol Biol. 2010, 5 (7): 18.Google Scholar
 Bu D, Li M, Li SC, Qian J, Xu J: Finding compact structural motifs. Theor Comput Sci. 2009, 410: 28342839. 10.1016/j.tcs.2009.03.023.View ArticleGoogle Scholar
 Ambühl C, Chakraborty S, Gärtner B: Computing Largest Common Point Sets under Approximate Congruence. ESA ’00: Proceedings of the 8th Annual European Symposium on Algorithms, Volume 1876 of Lecture Notes in Computer Science. 2000, 5263. Saarbrücken, Germany: SpringerVerlag,Google Scholar
 Goldman D, Papadimitriou CH, Istrail S: Algorithmic Aspects of Protein Structure Similarity. 1999, New York City, NY, USA: IEEE Computer Society,View ArticleGoogle Scholar
 Li SC, Ng YK: On protein structure alignment under distance constraint. 20th International Symposium on Algorithms and Computation, ISAAC 2009, Proceeedings, Volume 5878 of Lecture Notes in Computer Science. 2009, 6576. Honolulu, HI, USA: Springer,Google Scholar
 Lathrop RH: The Protein Threading Problem With Sequence Amino Acid Interaction Preferences Is NPComplete. Protein Eng. 1995, 7: 10591068.View ArticleGoogle Scholar
 Godzik A: The structural alignment between two proteins: is there a unique answer?. Protein Sci. 1996, 5 (7): 13251338.PubMed CentralView ArticlePubMedGoogle Scholar
 Eidhammer I, Jonassen I, Taylor WR: Structure Comparison and Structure Patterns. J Comput Biol. 2000, 7 (5): 685716.View ArticlePubMedGoogle Scholar
 Zhao Z, Fu B, Alanis FJ, Summa CM: Feedback algorithm and webserver for protein structure alignment. J Comput Biol. 2008, 15 (5): 505524.View ArticlePubMedGoogle Scholar
 Kolodny R, Linial N: Approximate Protein Structural Alignment in Polynomial Time. Proc Natl Acad Sci. 2004, 101: 1220112206.PubMed CentralView ArticlePubMedGoogle Scholar
 Akutsu T, Tashimo H: Protein structure comparison using representation by line segment sequences. Proc. Pacific Symposium on Biocomputing ’96. 1996, 2540. Hawaii, USA: World Scientific Press,sGoogle Scholar
 Alexandrov NN: SARFing the PDB. Protein Eng. 1996, 9 (9): 727732.View ArticlePubMedGoogle Scholar
 Caprara A, Lancia G: Structural alignment of largesize proteins via lagrangian relaxation. RECOMB ’02: Proceedings of The Sixth Annual International Conference on Computational Biology. 2002, 100108. New York, NY, USA: ACM,View ArticleGoogle Scholar
 Comin M, Guerra C, Zanotti G: PROuST: A Comparison Method of ThreeDimensional Structure of Proteins using Indexing Techniques. J Comp Biol. 2004, 11: 10611072. 10.1089/cmb.2004.11.1061.View ArticleGoogle Scholar
 Gerstein M, Levitt M: Using Iterative Dynamic Programming to Obtain Accurate Pairwise and Multiple Alignments of Protein Structures. Proceedings of the Fourth International Conference on Intelligent Systems for Molecular Biology. 1996, 5967. St. Louis, MO, USA: AAAI Press,Google Scholar
 Gibrat JF, Madej T, Bryant SH: Surprising similarities in structure comparison. Curr Opin Struct Biol. 1996, 6 (3): 377385.View ArticlePubMedGoogle Scholar
 Holm L, Sander C: Protein structure comparison by alignment of distance matrices. J Mol Biol. 1993, 233: 123138.View ArticlePubMedGoogle Scholar
 Lancia G, Carr R, Walenz B, Istrail S: 101 optimal PDB structure alignments: a branchandcut algorithm for the maximum contact map overlap problem. RECOMB ’01: Proceedings of The Fifth Annual International Conference on Computational Biology. New York, NY, USA: ACM 2001, 193202..View ArticleGoogle Scholar
 Singh AP, Brutlag DL: Hierarchical Protein Structure Superposition Using Both Secondary Structure and Atomic Representations. Proceedings of the 5th International Conference on Intelligent Systems for Molecular Biology. 1997, 284293. Halkidiki, Greece: AAAI Press,Google Scholar
 Berman HM, Westbrook J, Feng Z, Gilliland G, Bhat TN, Weissig H, Shindyalov IN, Bourne PE: The protein data bank. Nucl Acids Res. 2000, 28: 235242. [http://nar.oxfordjournals.org/cgi/content/abstract/28/1/235], []PubMed CentralView ArticlePubMedGoogle Scholar
 Papadimitriou C: The Euclidean Traveling Salesman Problem is NPComplete. Theoretial Compututer Sci. 1977, 4 (3): 237244. 10.1016/03043975(77)900123.View ArticleGoogle Scholar
 Arun KS, Huang TS, Blostein SD: Leastsquares fitting of two 3D point sets. IEEE Trans Pattern Anal Mach Intell. 1987, 9 (5): 698700.View ArticlePubMedGoogle Scholar
 Ahuja RK, Magnanti TL, Orlin JB: Network Flows: Theory, Algorithms, and Applications. 1993, Englewood Cliffs, NJ: Prentice Hall,Google Scholar
 A New Algorithm to Find a Point in Every Cell Defined by a Family of Polynomials. Edited by: Caviness B, Johnson J. Springer Vienna: SpringerVerlag 1998.Google Scholar
 de Rezende PJ, Lee DT: Point Set Pattern Matching in dDimensions. Algorithmica. 1995, 13 (4): 387404. 10.1007/BF01293487.View ArticleGoogle Scholar
Copyright
This article is published under license to BioMed Central Ltd. This is an Open Access article distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/by/2.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.