Article ID Journal Published Year Pages File Type
430877 Journal of Discrete Algorithms 2014 15 Pages PDF
Abstract

The edit distance problem for rooted unordered trees is known to be NP-hard. Based on this fact, this paper studies exponential-time algorithms for the problem. For a general case, an O(min(1.26n1+n2,2b1+b2⋅poly(n1,n2)))O(min(1.26n1+n2,2b1+b2⋅poly(n1,n2))) time algorithm is presented, where n1n1 and n2n2 are the numbers of nodes and b1b1 and b2b2 are the numbers of branching nodes in two input trees. This algorithm is obtained by a combination of dynamic programming, exhaustive search, and maximum weighted bipartite matching. For bounded degree trees over a fixed alphabet, it is shown that the problem can be solved in O((1+ϵ)n1+n2)O((1+ϵ)n1+n2) time for any fixed ϵ>0ϵ>0. This result is achieved by avoiding duplicate calculations for identical subsets of small subtrees.

Related Topics
Physical Sciences and Engineering Computer Science Computational Theory and Mathematics
Authors
, , , ,