Abstract

In the setting of dynamic complexity, the goal of a dynamic program is to maintain the result of a fixed query for an input database that is subject to changes, possibly using additional auxiliary relations. In other words, a dynamic program updates a materialized view whenever a base relation is changed. The update of query result and auxiliary relations is specified using first-order logic or, equivalently, relational algebra. The original framework by Patnaik and Immerman only considers changes to the database that insert or delete single tuples. This article extends the setting to definable changes , also specified by first-order queries on the database, and generalizes previous maintenance results to these more expressive change operations. More specifically, it is shown that the undirected reachability query is first-order maintainable under single-tuple changes and first-order defined insertions, likewise the directed reachability query for directed acyclic graphs is first-order maintainable under insertions defined by quantifier-free first-order queries. These results rely on bounded bridge properties , which basically say that, after an insertion of a defined set of edges, for each connected pair of nodes there is some path with a bounded number of new edges. While this bound can be huge, in general, it is shown to be small for insertion queries defined by unions of conjunctive queries. To illustrate that the results for this restricted setting could be practically relevant, they are complemented by an experimental study that compares the performance of dynamic programs with complex changes, dynamic programs with single changes, and with recomputation from scratch. The positive results are complemented by several inexpressibility results. For example, it is shown that—unlike for single-tuple insertions—dynamic programs that maintain the reachability query under definable, quantifier-free changes strictly need update formulas with quantifiers. Finally, further positive results unrelated to reachability are presented: it is shown that for changes definable by parameter-free first-order formulas, all LOGSPACE-definable (and even AC 1 -definable) queries can be maintained by first-order dynamic programs.

Highlights

  • In the setting of Dynamic Complexity, a database D is being changed and an update program P tries to answer a standing query q after each change

  • The program usually consists of logical formulas which can make use of additional, auxiliary relations which in turn need to be updated after each change

  • We show how to construct from P a first-order formula φ that expresses the reachability query qReach for simple paths with unary help relations B1, . . . , Bk, C0, C1, C2, contradicting Lemma 11

Read more

Summary

Introduction

In the setting of Dynamic Complexity, a database D is being changed and an update program P tries to answer a standing query q after each change. The program usually consists of logical formulas which can make use of additional, auxiliary relations which in turn need to be updated after each change. Dynamic Complexity can be seen as a logic-based counterpart of Dynamic Algorithms, where algorithms use auxiliary data structures to keep track of properties of structures like graphs under change operations. In Dynamic Complexity, one usually allows first-order logic formulas as update mechanism for the auxiliary relations. This is in line with the database-oriented framework, since firstorder logic correspond to database languages like relational algebra. The class of queries maintainable in this fashion is called DynFO This line of research has seen recent progress, particular with respect to the question whether the reachability query can be maintained in DynFO for directed graphs [2, 3]

Objectives
Results
Conclusion
Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call