algorithm - Match multiple binary trees in another big binary tree -


I was thinking that any efficient algorithm for finding matches for any set S = {t_1, t_2, ... Is T_n} small binary-tree in large binary-tree t? Binary trees are ordered and labeled, that is, each node has a label and the left / right child can not be swapped.

TII's "match" in T means that a subtitle T is similar to T.

Simple method is scanning on every node of T and t_1, t_2, ..., are trying to match one by one. I was wondering if there is something like the ego-cosmical string matching algorithm, which determines a set of small strings in the long text through the complexity of linear time (the length of all the patterns Length wire and text.)

Any indication for advance thanks references, etc. will also be appreciated!

Representing subtitles and a large tree in terms of in-word and postorder (or preorder) traversal Strings If you find that both types of posters (or prerenders) strings are inside the poster of the big tree, then there is a match (you can check whether this is an object or the complexity of the linear time Is not using KPP)


Comments

Popular posts from this blog

sqlite3 - UPDATE a table from the SELECT of another one -

c# - Showing a SelectedItem's Property -

javascript - Render HTML after each iteration in loop -