An Optimal Decomposition Algorithm for Tree Edit Distance

  • Erik D. Demaine
  • Shay Mozes
  • Benjamin Rossman
  • Oren Weimann
Conference paper

DOI: 10.1007/978-3-540-73420-8_15

Part of the Lecture Notes in Computer Science book series (LNCS, volume 4596)
Cite this paper as:
Demaine E.D., Mozes S., Rossman B., Weimann O. (2007) An Optimal Decomposition Algorithm for Tree Edit Distance. In: Arge L., Cachin C., Jurdziński T., Tarlecki A. (eds) Automata, Languages and Programming. ICALP 2007. Lecture Notes in Computer Science, vol 4596. Springer, Berlin, Heidelberg

Abstract

The edit distance between two ordered rooted trees with vertex labels is the minimum cost of transforming one tree into the other by a sequence of elementary operations consisting of deleting and relabeling existing nodes, as well as inserting new nodes. In this paper, we present a worst-case O(n3)-time algorithm for this problem, improving the previous best O(n3logn)-time algorithm [7]. Our result requires a novel adaptive strategy for deciding how a dynamic program divides into subproblems, together with a deeper understanding of the previous algorithms for the problem. We prove the optimality of our algorithm among the family of decomposition strategy algorithms—which also includes the previous fastest algorithms—by tightening the known lower bound of Ω(n2log2n) [4] to Ω(n3), matching our algorithm’s running time. Furthermore, we obtain matching upper and lower bounds of \(\Theta(n m^2 (1 + \log \frac{n}{m}))\) when the two trees have sizes m and n where m < n.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Springer-Verlag Berlin Heidelberg 2007

Authors and Affiliations

  • Erik D. Demaine
    • 1
  • Shay Mozes
    • 1
  • Benjamin Rossman
    • 1
  • Oren Weimann
    • 1
  1. 1.MIT Computer Science and Artificial Intelligence Laboratory, 32 Vassar Street, Cambridge, MA 02139USA

Personalised recommendations