Aho-Corasick like multiple subtree matching by pushdown automata
Tomáš Flouri, Bořivoj Melichar, Jan Janoušek · 2010
A simple yet efficient algorithm to find all occurrences of a set of subtrees in a subject tree is described. The presented algorithm is similar to the well-known Aho-Corasick string matching method -- instead of a deterministic finite automaton a deterministic pushdown automaton is used as the computation model for reading the subject tree in prefix notation.