What Do Shannon-type Inequalities, Submodular Width, and Disjunctive Datalog Have to Do with One Another?

Recent works on bounding the output size of a conjunctive query with functional dependencies and degree bounds have shown a deep connection between fundamental questions in information theory and database theory. We prove analogous output bounds for disjunctive datalog rules, and answer several open questions regarding the tightness and looseness of these bounds along the way. The bounds are intimately related to Shannon-type information inequalities. We devise the notion of a "proof sequence" of a specific class of Shannon-type information inequalities called "Shannon flow inequalities". We then show how a proof sequence can be used as symbolic instructions to guide an algorithm called PANDA, which answers disjunctive datalog rules within the size bound predicted. We show that PANDA can be used as a black-box to devise algorithms matching precisely the fractional hypertree width and the submodular width runtimes for aggregate and conjunctive queries with functional dependencies and degree bounds. Our results improve upon known results in three ways. First, our bounds and algorithms are for the much more general class of disjunctive datalog rules, of which conjunctive queries are a special case. Second, the runtime of PANDA matches precisely the submodular width bound, while the previous algorithm by Marx has a runtime that is polynomial in this bound. Third, our bounds and algorithms work for queries with input cardinality bounds, functional dependencies, and degree bounds. Overall, our results showed a deep connection between three seemingly unrelated lines of research; and, our results on proof sequences for Shannon flow inequalities might be of independent interest.

[1]  Proceedings of the 35th ACM SIGMOD-SIGACT-SIGAI Symposium on Principles of Database Systems , 2016, PODS.

[2]  Béla Bollobás,et al.  Projections, entropy and sumsets , 2007, Comb..

[3]  Georg Gottlob,et al.  Hypertree Decompositions: Questions and Answers , 2016, PODS.

[4]  Ronald L. Rivest,et al.  Introduction to Algorithms, third edition , 2009 .

[5]  Mihalis Yannakakis,et al.  Algorithms for Acyclic Database Schemes , 1981, VLDB.

[6]  Alexander Schrijver,et al.  Theory of linear and integer programming , 1986, Wiley-Interscience series in discrete mathematics and optimization.

[7]  Arnaud Durand,et al.  On Acyclic Conjunctive Queries and Constant Delay Enumeration , 2007, CSL.

[8]  Dániel Marx,et al.  Tractable Hypergraph Properties for Constraint Satisfaction and Conjunctive Queries , 2009, JACM.

[9]  Zhen Zhang,et al.  On Characterization of Entropy Function via Information Inequalities , 1998, IEEE Trans. Inf. Theory.

[10]  H. P. Williams THEORY OF LINEAR AND INTEGER PROGRAMMING (Wiley-Interscience Series in Discrete Mathematics and Optimization) , 1989 .

[11]  Jakub Závodný,et al.  Aggregation and Ordering in Factorised Databases , 2013, Proc. VLDB Endow..

[12]  P. Pardalos,et al.  Minimax and applications , 1995 .

[13]  Raymond W. Yeung,et al.  On a relation between information inequalities and group theory , 2002, IEEE Trans. Inf. Theory.

[14]  Georg Gottlob,et al.  Disjunctive datalog , 1997, TODS.

[15]  Ronald Fagin,et al.  Degrees of acyclicity for hypergraphs and relational database schemes , 1983, JACM.

[16]  Georg Gottlob,et al.  Size and treewidth bounds for conjunctive queries , 2009, JACM.

[17]  Rina Dechter,et al.  Bucket Elimination: A Unifying Framework for Reasoning , 1999, Artif. Intell..

[18]  Mario Alviano,et al.  The Disjunctive Datalog System DLV , 2010, Datalog.

[19]  David A. Patterson,et al.  SCADS: Scale-Independent Storage for Social Computing Applications , 2009, CIDR.

[20]  M. A. Perles ON THE NUMBER OF SUBGRAPHS OF PRESCRIBED TYPE OF GRAPHS WITH A GIVEN NUMBER OF EDGES* , 2007 .

[21]  Terence Chan,et al.  Group characterizable entropy functions , 2007, 2007 IEEE International Symposium on Information Theory.

[22]  Dan Suciu,et al.  Computing Join Queries with Functional Dependencies , 2016, PODS.

[23]  Atri Rudra,et al.  Skew strikes back: new developments in the theory of join algorithms , 2013, SGMD.

[24]  Moshe Y. Vardi The complexity of relational query languages (Extended Abstract) , 1982, STOC '82.

[25]  Dániel Marx,et al.  Size Bounds and Query Plans for Relational Joins , 2008, 2008 49th Annual IEEE Symposium on Foundations of Computer Science.

[26]  Michael Benedikt,et al.  Querying with Access Patterns and Integrity Constraints , 2015, Proc. VLDB Endow..

[27]  Noga Alon,et al.  Finding and counting given length cycles , 1997, Algorithmica.

[28]  Frantisek Matús,et al.  Infinitely Many Information Inequalities , 2007, 2007 IEEE International Symposium on Information Theory.

[29]  Robert J. McEliece,et al.  The generalized distributive law , 2000, IEEE Trans. Inf. Theory.

[30]  Richard M. Karp,et al.  Theoretical Improvements in Algorithmic Efficiency for Network Flow Problems , 1972, Combinatorial Optimization.

[31]  Luc Segoufin,et al.  Enumerating with constant delay the answers to a query , 2013, ICDT '13.

[32]  Eugene C. Freuder Complexity of K-Tree Structured Constraint Satisfaction Problems , 1990, AAAI.

[33]  Todd L. Veldhuizen,et al.  Leapfrog Triejoin: A Simple, Worst-Case Optimal Join Algorithm , 2012, 1210.0481.

[34]  Atri Rudra,et al.  FAQ: Questions Asked Frequently , 2015, PODS.

[35]  Fan Chung Graham,et al.  Some intersection theorems for ordered sets and graphs , 1986, J. Comb. Theory, Ser. A.

[36]  Jörg Flum,et al.  Query evaluation via tree-decompositions , 2001, JACM.

[37]  Dániel Marx Tractable Structures for Constraint Satisfaction with Truth Tables , 2009, Theory of Computing Systems.

[38]  Dániel Marx,et al.  Constraint solving via fractional edge covers , 2006, SODA '06.

[39]  Raymond W. Yeung,et al.  Information Theory and Network Coding , 2008 .

[40]  Georg Gottlob,et al.  General and Fractional Hypertree Decompositions: Hard and Easy Cases , 2016, AMW.

[41]  Michael Benedikt,et al.  Generating Plans from Proofs , 2016, TODS.

[42]  Nic Wilson,et al.  Semiring induced valuation algebras: Exact and approximate local computation algorithms , 2008, Artif. Intell..

[43]  Christoph Koch,et al.  Incremental query evaluation in a ring of databases , 2010, PODS.

[44]  Georg Gottlob,et al.  Hypertree decompositions and tractable queries , 1998, J. Comput. Syst. Sci..

[45]  Tianyu Wo,et al.  Bounded Conjunctive Queries , 2014, Proc. VLDB Endow..

[46]  Szymon Torunczyk,et al.  Entropy Bounds for Conjunctive Queries with Functional Dependencies , 2015, ICDT.

[47]  J. Kahn,et al.  On the number of copies of one hypergraph in another , 1998 .

[48]  Anand Rajaraman,et al.  Conjunctive query containment revisited , 2000, Theor. Comput. Sci..

[49]  Robert E. Tarjan,et al.  Simple Linear-Time Algorithms to Test Chordality of Graphs, Test Acyclicity of Hypergraphs, and Selectively Reduce Acyclic Hypergraphs , 1984, SIAM J. Comput..

[50]  Tim Kraska,et al.  PIQL: Success-Tolerant Query Processing in the Cloud , 2011, Proc. VLDB Endow..

[51]  Tim Kraska,et al.  Generalized scale independence through incremental precomputation , 2013, SIGMOD '13.

[52]  Martin Grohe The complexity of homomorphism and constraint satisfaction problems seen from the other side , 2007, JACM.