A top down algorithm for constrained tree inclusion
نویسندگان
چکیده
An ordered labeled tree is a tree which nodes are labeled and in which the left-to-right order among siblings is significant. Given two ordered labeled trees P and T , the constrained tree inclusion problem is to determine whether it is possible to obtain P from T by deleting degree-one or degreetwo nodes. G. Valiente proposed a bottom up algorithm which solves the problem in O(|P ||T |) time and space. In this paper, a top down matching algorithm is presented, which solves the problem in O(|P ||T |) time and O(|P ||leaves(T )|) space.
منابع مشابه
Alternating Regular Tree Grammars in the Framework of Lattice-Valued Logic
In this paper, two different ways of introducing alternation for lattice-valued (referred to as {L}valued) regular tree grammars and {L}valued top-down tree automata are compared. One is the way which defines the alternating regular tree grammar, i.e., alternation is governed by the non-terminals of the grammar and the other is the way which combines state with alternation. The first way is ta...
متن کاملEfficient inclusion checking for deterministic tree automata and XML Schemas
We present algorithms for testing language inclusion L(A) ⊆ L(B) between tree automata in time O(|A| · |B|) where B is deterministic (bottom-up or top-down). We extend our algorithms for testing inclusion of automata for unranked trees A in deterministic DTDs or deterministic EDTDs with restrained competition D in time O(|A| · |Σ| · |D|). Previous algorithms were less efficient or less general.
متن کاملOn the Tree Inclusion and Query Evaluation in Document Databases
In this paper, a method to evaluate queries in document databases is proposed. The main idea of this method is a new top-down algorithm for tree-inclusion. In fact, a path-oriented query can be considered as a pattern tree while an XML document can be considered as a target tree. To evaluate a query S against a document T, we will check whether S is included in T. For a query S, our algorithm n...
متن کاملIntroducing Cuts into Top-down Search: A New Way to Check Tree Inclusion
The ordered tree inclusion is an interesting problem, by which we will check whether a pattern tree P can be included in a target tree T, where the order of siblings in both P and T is significant. In this paper, we propose an efficient algorithm for this problem. Its time complexity is bounded by O(|T|loghP) with O(|T| + |P|) space being used, where hP represents the height of P. Up to now th...
متن کاملAn Efficient Top-down Algorithm for Tree Inclusion
Let T and S be ordered, labeled trees. We say that S is included in T if there is a sequence of delete operations performed on T, which make T isomorphic to S. In this paper, we propose a top-down algorithm for this problem, which needs only O(|T|⋅|leaves(S)|) time and O(|T| + |S|) space.
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید
ثبت ناماگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید
ورودعنوان ژورنال:
- J. Discrete Algorithms
دوره 34 شماره
صفحات -
تاریخ انتشار 2015