Alignment of trees — An alternative to tree edit

  • Tao Jiang
  • Lusheng Wang
  • Kaizhong Zhang
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 807)


In this paper, we propose the alignment of trees as a measure of the similarity between two labeled trees. Both ordered and unordered trees are considered. An algorithm is designed for ordered trees. The time complexity of this algorithm is OT1¦· s¦T2· (deg(T1) + deg(T2))2), where ¦Ti¦ is the number of nodes in T i and deg(T i ) is the degree of T i , i=1,2. The algorithm is faster than the best known algorithm for tree edit when deg(T1) and deg(T2) are smaller than the depths of T1 and T2. For unordered trees, we show that the alignment problem can be solved in polynomial time if the trees have a bounded degree and becomes NP-hard if one of the trees is allowed to have an arbitrary degree. In contrast, the edit problem for unordered trees is NP-hard even if both trees have a bounded degree [17]. Finally, multiple alignment of trees is discussed.


Lower Segment Optimal Alignment Edit Operation Label Tree Arbitrary Degree 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    M. R. Garey and D. S. Johnson, Computers and Intractability: A Guide to the Theory of NP-Completeness, W. H. Freeman, 1979.Google Scholar
  2. 2.
    D. Gusfield, Efficient methods for multiple sequence alignment with guaranteed error bounds, Bulletin of Mathematical Biology 55, pp. 141–154, 1993.Google Scholar
  3. 3.
    P. Kilpelainen and H. Mannila, Ordered and unordered tree inclusion, Report A-1991-4, Dept. of Comp. Science, University of Helsinki, August. 1991; to appear in SIAM J. on Computing.Google Scholar
  4. 4.
    S.-Y. Le, J. Owens, R. Nussinov, J.-H. Chen B. Shapiro and J. V. Maizel, RNA secondary structures: comparison and determination of frequently recurring substructures by consensus, Comp. Appl. Biosci. 5, 205–210, 1989.Google Scholar
  5. 5.
    S.-Y. Le, R. Nussinov, and J.V. Maizel, Tree graphs of RNA secondary structures and their comparisons, Computers and Biomedical Research, 22, 461–473, 1989.Google Scholar
  6. 6.
    S.Y. Lu, A tree-tree distance and its application to cluster analysis, IEEE Trans. Pattern Anal. Mach. Intelligence 1, 219–224, 1979.Google Scholar
  7. 7.
    D. Sankoff and J. Kruskal (Eds), Time Warps, String Edits, and Macromolecules: the Theory and Practice of Sequence Comparison, Addison Wesley, Reading Mass., 1983.Google Scholar
  8. 8.
    B. Shapiro, An algorithm for comparing multiple RNA secondary structures, Comput. Appl. Biosci. 387–393, 1988.Google Scholar
  9. 9.
    F.Y. Shih, Object representation and recognition using mathematical morphology model, J. System Integration, vol. 1, pp.235–256, 1991.Google Scholar
  10. 10.
    F.Y. Shih and O.R. Mitchell, Threshold decomposition of grayscale morphology into binary morphology, IEEE Trans. Pattern Anal. Mach. Intell., vol. PAMI-11, pp.31–42, 1989.Google Scholar
  11. 11.
    B. Shapiro and K. Zhang, Comparing multiple RNA secondary structures using tree comparisons, Comput. Appl. Biosci. vol. 6, no. 4, pp.309–318, 1990.Google Scholar
  12. 12.
    Y. Takahashi, Y. Satoh, H. Suzuki and S. Sasaki, Recognition of largest common structural fragment among a variety of chemical structures, Analytical Science, vol. 3, pp23–28, 1987.Google Scholar
  13. 13.
    K.C. Tai, The tree-to-tree correction problem, J. ACM, 26, 422–433, 1979.Google Scholar
  14. 14.
    L. Wang and T. Jiang, On the complexity of multiple sequence alignment, 1993, to appear in Journal of Computational Biology.Google Scholar
  15. 15.
    K. Zhang and T. Jiang, Some MAX SNP-hard results concerning unordered labeled trees, 1993, To appear in Information Processing Letters.Google Scholar
  16. 16.
    K. Zhang and D. Shasha, Simple fast algorithms for the editing distance between trees and related problems, SIAM J. Comput. 18, 1245–1262, 1989.Google Scholar
  17. 17.
    K. Zhang, R. Statman, and D. Shasha, On the editing distance between unordered labeled trees, Information Processing Letters, 42, 133–139, 1992.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1994

Authors and Affiliations

  • Tao Jiang
    • 1
  • Lusheng Wang
    • 2
  • Kaizhong Zhang
    • 3
  1. 1.Department of Computer ScienceMcMaster UniversityHamiltonCanada
  2. 2.Department of Electrical and Computer EngineeringMcMaster UniversityHamiltonCanada
  3. 3.Department of Computer ScienceUniversity of Western OntarioLondonCanada

Personalised recommendations