Inherent complexity of recursive queries

We give lower bou.nds on the complexity of evaluating Datalog queries; our results delimit the possibility of optimizing such queries by compile-time techniques. The main technical tool is a new class of linear firstorder formulas, whose quantifier depth (respectively, number of variables) measures the sequential (respectively, parallel) complexity of Datalog programs. We define a combinatorial game, and use it to prove nonexpressibility of certain Datalog queries by linear formulas; we thus obtain lower bounds for sequential and for parallel complexity. We prove tight versions of our results, for queries of restricted form, by exploiting uniformity and invariance properties of Datalog programs.

[1]  Foto N. Afrati,et al.  Expressiveness of restricted recursive queries , 1989, STOC '89.

[2]  Phokion G. Kolaitis,et al.  On the Expressive Power of Datalog: Tools and a Case Study , 1995, J. Comput. Syst. Sci..

[3]  Jeffrey D. Ullman,et al.  Parallel complexity of logical query programs , 1986, 27th Annual Symposium on Foundations of Computer Science (sfcs 1986).

[4]  Catriel Beeri,et al.  On the power of magic , 1987, J. Log. Program..

[5]  Neil Immerman,et al.  Number of Quantifiers is Better Than Number of Tape Cells , 1981, J. Comput. Syst. Sci..

[6]  A. Ehrenfeucht An application of games to the completeness problem for formalized theories , 1961 .

[7]  Yuri Gurevich,et al.  Datalog vs. first-order logic , 1989, 30th Annual Symposium on Foundations of Computer Science.

[8]  David S. Johnson,et al.  Computers and Intractability: A Guide to the Theory of NP-Completeness , 1978 .

[9]  David Maier,et al.  Magic sets and other strange ways to implement logic programs (extended abstract) , 1985, PODS '86.

[10]  Neil Immerman,et al.  Tree Canonization and Transitive Closure , 2000, Inf. Comput..

[11]  Christos H. Papadimitriou,et al.  The parallel complexity of simple logic programs , 1993, JACM.

[12]  H. Gaifman On Local and Non-Local Properties , 1982 .

[13]  Mihalis Yannakakis,et al.  On Datalog vs. Polynomial Time , 1995, J. Comput. Syst. Sci..

[14]  Catriel Beeri,et al.  Bounds on the propagation of selection into logic programs , 1987, J. Comput. Syst. Sci..

[15]  Laks V. S. Lakshmanan,et al.  Inductive pebble games and the expressive power of datalog , 1989, PODS '89.

[16]  Jeffrey D. Ullman,et al.  Principles of Database and Knowledge-Base Systems, Volume II , 1988, Principles of computer science series.

[17]  Neil Immerman,et al.  An optimal lower bound on the number of variables for graph identification , 1992, Comb..

[18]  Alfred V. Aho,et al.  Universality of data retrieval languages , 1979, POPL.

[19]  Carlo Zaniolo,et al.  The Generalized Counting Method for Recursive Logic Queries , 1986, ICDT.

[20]  Foto N. Afrati,et al.  Bounded Arity Datalog (not-)Queries on Graphs , 1997, J. Comput. Syst. Sci..