skip to main content
10.1145/1265530.1265554acmconferencesArticle/Chapter ViewAbstractPublication PagesmodConference Proceedingsconference-collections
Article

Monadic datalog over finite structures with bounded treewidth

Published:11 June 2007Publication History

ABSTRACT

Bounded treewidth and Monadic Second Order (MSO) logic have proved to be key concepts in establishing fixed-para-meter tractability results. Indeed, by Courcelle's Theorem we know: Any property of finite structures, which is expressible by an MSO sentence, can be decided in linear time (data complexity) if the structures have bounded treewidth.

In principle, Courcelle's Theorem can be applied directly to construct concrete algorithms by transforming the MSO evaluation problem into a tree language recognition problem. The latter can then be solved via a finite tree automaton (FTA). However, this approach has turned out to be problematical, since even relatively simple MSO formulae may lead to a "state explosion" of the FTA.

In this work we propose monadic datalog (i.e., data log where all intentional predicate symbols are unary) as an alternative method to tackle this class of fixed-parameter tractable problems. We show that if some property of finite structures is expressible in MSO then this property can also be expressed by means of a monadic datalog program over the structure plus the treedecomposition. Moreover, we show that the resulting fragment of datalogcan be evaluated in linear time (both w.r.t. the program size and w.r.t. the data size). This new approach is put to work by devising a new algorithm for the PRIMALITY problem (i.e., testing if some attribute in a relational schema is part of a key). We also report on experimental results with a prototype implementation.

References

  1. S. Abiteboul, R. Hull, and V. Vianu. Foundations of databases. Addison-Wesley, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. S. Arnborg, J. Lagergren, and D. Seese. Easy Problems for Tree-Decomposable Graphs. J. Algorithms, 12(2):308--340, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. H. L. Bodlaender. A Linear-Time Algorithm for Finding Tree-Decompositions of Small Treewidth. SIAM J. Comput., 25(6):1305--1317, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. S. Ceri, G. Gottlob, and L. Tanca. Logic Programming and Databases. Springer, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. B. Courcelle. Graph Rewriting: An Algebraic and Logic Approach. In Handbook of Theoretical Computer Science, Volume B, pages 193--242. Elsevier Science Publishers, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. J. Doner. Tree acceptors and some of their applications. J. Comput. Syst. Sci., 4(5):406--451, 1970.Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. W. F. Dowling and J. H. Gallier. Linear-Time Algorithms for Testing the Satisfiability of Propositional Horn Formulae. J. Log. Program., 1(3):267--284, 1984.Google ScholarGoogle ScholarCross RefCross Ref
  8. R. G. Downey and M. R. Fellows. Parameterized Complexity. Springer, New York, 1999.Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. H. -D. Ebbinghaus and J. Flum. Finite Model Theory, 2nd edition. Springer Monographs in Mathematics. Springer, 1999.Google ScholarGoogle Scholar
  10. T. Eiter and G. Gottlob. The Complexity of Logic-Based Abduction. J. ACM, 42(1):3--42, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. T. Eiter, G. Gottlob, and H. Veith. Generalized quantifiers in logic programs. In ESSLLI'97 Workshop, volume 1754 of LNCS, pages 72--98. Springer, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. T. Eiter, G. Gottlob, and H. Veith. Modular logic programming and generalized quantifiers. In Proc. LPNMR'97, volume 1265 of LNCS, pages 290--309, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. J. Flum, M. Frick, and M. Grohe. Query evaluation via tree-decompositions. J. ACM, 49(6):716--752, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. J. Flum and M. Grohe. Parameterized Complexity Theory. Texts in Theoretical Computer Science. Springer, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. G. Gottlob and C. Koch. Monadic datalog and the expressive power of languages for Web information extraction. J. ACM, 51(1):74--113, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. G. Gottlob, R. Pichler, and F. Wei. Bounded Treewidth as a Key to Tractability of Knowledge Representation and Reasoning. In Proc. AAAI 2006, pages 250--256. AAAI Press, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. G. Gottlob, R. Pichler, and F. Wei. Tractable database design through bounded treewidth. In Proceedings of the Twenty-Fifth ACM SIGACT-SIGMOD-SIGART Symposium on Principles of Database Systems (PODS 2006), pages 124--133. ACM, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. M. Grohe. Descriptive and Parameterized Complexity. In Proc. CSL'99, volume 1683 of LNCS, pages 14--31. Springer, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. N. Klarlund, A. Møller, and M. I. Schwartzbach. MONA Implementation Secrets. International Journal of Foundations of Computer Science, 13(4):571--586, 2002. World Scientific Publishing Company. Earlier version in Proc. CIAA'00, LNCS vol. 2088. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. L. Libkin. Elements of Finite Model Theory. Texts in Theoretical Computer Science. Springer, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. H. Mannila and K. -J. Räihä. The design of relational databases. Addison-Wesley, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. H. Maryns. On the Implementation of Tree Automata: Limitations of the Naive Approach. In Proc. 5th Int. Treebanks and Linguistic Theories Conference (TLT 2006), pages 235--246, 2006.Google ScholarGoogle Scholar
  23. M. Minoux. LTUR: A Simplified Linear-Time Unit Resolution Algorithm for Horn Formulae and Computer Implementation. Inf. Process. Lett., 29(1):1--12, 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. F. Neven and T. Schwentick. Query automata over finite trees. Theoretical Computer Science, 275(1-2):633--674, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. J. W. Thatcher and J. B. Wright. Generalized Finite Automata Theory with an Application to a Decision Problem of Second-Order Logic. Mathematical Systems Theory, 2(1):57--81, 1968.Google ScholarGoogle ScholarCross RefCross Ref
  26. J. D. Ullman. Principles of Database and Knowledge-Base Systems, Vol. 1. Computer Science Press, 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. M. Y. Vardi. The complexity of relational query languages (extended abstract). In Proc. STOC'82, pages 137--146. ACM, 1982. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Monadic datalog over finite structures with bounded treewidth

          Recommendations

          Comments

          Login options

          Check if you have access through your login credentials or your institution to get full access on this article.

          Sign in

          PDF Format

          View or Download as a PDF file.

          PDF

          eReader

          View online with eReader.

          eReader
          About Cookies On This Site

          We use cookies to ensure that we give you the best experience on our website.

          Learn more

          Got it!