Abstract
Tree pattern matching is a fundamental problem that has a wide range of applications in Web data management, XML processing, and selective data dissemination. In this paper we develop efficient algorithms for the tree homeomorphism problem, i.e., the problem of matching a tree pattern with exclusively transitive (descendant) edges. We first prove that deciding whether there is a tree homeomorphism is LOGSPACE-complete, improving on the current LOGCFL upper bound. As our main result we develop a practical algorithm for the tree homeomorphism decision problem that is both space- and time efficient. The algorithm is in LOGCFL and space consumption is strongly bounded, while the running time is linear in the size of the data tree. This algorithm immediately generalizes to the problem of matching the tree pattern against all subtrees of the data tree, preserving the mentioned efficiency properties.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Altinel, M., Franklin, M.: Efficient filtering of XML documents for selective dissemination of information. In: Proc. VLDB, pp. 53–64 (2000)
Bar-Yossef, Z., Fontoura, M., Josifovski, V.: On the memory requirements of XPath evaluation over XML streams. In: Proc. PODS, pp. 177–188 (2004)
Bar-Yossef, Z., Fontoura, M., Josifovski, V.: Buffering in query evaluation over XML streams. In: Proc. PODS (2005)
Bruno, N., Srivastava, D., Koudas, N.: Holistic twig joins: Optimal XML pattern matching. In: Proc. SIGMOD, pp. 310–321 (2002)
Chan, C.Y., Fan, W., Felber, P., Garofalakis, M.N., Rastogi, R.: Tree pattern aggregation for scalable XML data dissemination. In: Bressan, S., Chaudhri, A.B., Lee, M.L., Yu, J.X., Lacroix, Z. (eds.) CAiSE 2002 and VLDB 2002. LNCS, vol. 2590, pp. 826–837. Springer, Heidelberg (2003)
Chan, C.Y., Felber, P., Garofalakis, M.N., Rastogi, R.: Efficient filtering of XML documents with XPath expressions. In: Proc. ICDE, pp. 235–244 (2000)
Clark, J., DeRose, S.: XML Path Language (XPath). Technical report, World Wide Web Consortium (November 1999), http://www.w3.org/TR/xpath
Cook, S.A., McKenzie, P.: Problems complete for deterministic logarithmic space. J. Algorithms 8, 385–394 (1987)
Diao, Y., Altinel, M., Franklin, M.J., Zhang, H., Fischer, P.: Path sharing and predicate evaluation for high-performance XML filtering. ACM Trans. Database Syst. 28(4), 467–516 (2003)
Gottlob, G., Koch, C., Pichler, R.: Efficient algorithms for processing XPath queries. ACM Trans. Database Syst. 30(2), 444–491 (2005)
Gottlob, G., Koch, C., Pichler, R., Segoufin, L.: The complexity of XPath query evaluation and XML typing. J. ACM 52(2), 284–335 (2005)
Gottlob, G., Leone, N., Scarcello, F.: The complexity of acyclic conjunctive queries. J. ACM 48(1), 431–498 (2001)
Green, T.J., Gupta, A., Miklau, G., Onizuka, M., Suciu, D.: Processing XML streams with deterministic automata and stream indexes. ACM Trans. Database Syst. 29(4), 752–788 (2004)
Grohe, M., Koch, C., Schweikardt, N.: Tight lower bounds for query processing on streaming and external memory data. In: Caires, L., Italiano, G.F., Monteiro, L., Palamidessi, C., Yung, M. (eds.) ICALP 2005. LNCS, vol. 3580, Springer, Heidelberg (2005)
Gupta, A., Suciu, D.: Stream processing of XPath queries with predicates. In: Proc. SIGMOD, pp. 419–430 (2003)
Olteanu, D., Furche, T., Bry, F.: An evaluation of regular path expressions with qualifiers against XML streams. In: Williams, H., MacKinnon, L.M. (eds.) Key Technologies for Data Management. LNCS, vol. 3112, pp. 31–44. Springer, Heidelberg (2004)
Ramanan, P.: Evaluating an XPath query on a streaming XML document. In: Proc. COMAD 2005, pp. 41–52 (2005)
Sudborough, I.H.: Time and tape bounded auxiliary pushdown automata. In: Gruska, J. (ed.) Mathematical Foundations of Computer Science 1977. LNCS, vol. 53, pp. 493–503. Springer, Heidelberg (1977)
Yannakakis, M.: Algorithms for acyclic database schemes. In: Proc. VLDB, pp. 82–94 (1981)
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 2007 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Götz, M., Koch, C., Martens, W. (2007). Efficient Algorithms for the Tree Homeomorphism Problem. In: Arenas, M., Schwartzbach, M.I. (eds) Database Programming Languages. DBPL 2007. Lecture Notes in Computer Science, vol 4797. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-75987-4_2
Download citation
DOI: https://doi.org/10.1007/978-3-540-75987-4_2
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-75986-7
Online ISBN: 978-3-540-75987-4
eBook Packages: Computer ScienceComputer Science (R0)