Semantic Tree-Width and Path-Width of Conjunctive Regular Path Queries

📅 2022-12-03
📈 Citations: 2
Influential: 0
📄 PDF
🤖 AI Summary
This work addresses the decidability of semantic treewidth and pathwidth for UC2RPQs (Union of Conjunctive 2-Way Regular Path Queries). Specifically, it resolves the long-standing open problem of deciding whether a given UC2RPQ is equivalent to some query of treewidth ≤ k, proving decidability for all k ≥ 1 (2ExpSpace-complete; Π₂^P-complete under bounded alternation). We present the first algorithm to construct a maximal treewidth-k approximation of a UC2RPQ—guaranteeing both semantic optimality and uniqueness. Our approach integrates formal language theory, semantic analysis of regular path queries, automata construction, and query containment checking, uniformly handling both UCRPQs and UC2RPQs under one-way and two-way navigation. The framework establishes a unified semantic analysis methodology across treewidth and pathwidth dimensions, enabling rigorous equivalence verification and approximation optimization for complex graph pattern queries.
📝 Abstract
We show that the problem of whether a query is equivalent to a query of tree-width $k$ is decidable, for the class of Unions of Conjunctive Regular Path Queries with two-way navigation (UC2RPQs). A previous result by Barcel'o, Romero, and Vardi [SIAM Journal on Computing, 2016] has shown decidability for the case $k=1$, and here we extend this result showing that decidability in fact holds for any arbitrary $kgeq 1$. The algorithm is in 2ExpSpace, but for the restricted but practically relevant case where all regular expressions of the query are of the form $a^*$ or $(a_1 + dotsb + a_n)$ we show that the complexity of the problem drops to $Pi^P_2$. We also investigate the related problem of approximating a UC2RPQ by queries of small tree-width. We exhibit an algorithm which, for any fixed number $k$, builds the maximal under-approximation of tree-width $k$ of a UC2RPQ. The maximal under-approximation of tree-width $k$ of a query $q$ is a query $q'$ of tree-width $k$ which is contained in $q$ in a maximal and unique way, that is, such that for every query $q''$ of tree-width $k$, if $q''$ is contained in $q$ then $q''$ is also contained in $q'$. Our approach is shown to be robust, in the sense that it allows also to test equivalence with queries of a given path-width, it also covers the previously known result for $k=1$, and it allows to test for equivalence of whether a (one-way) UCRPQ is equivalent to a UCRPQ of a given tree-width (or path-width).
Problem

Research questions and friction points this paper is trying to address.

Query Equivalence
Tree Width
Approximation
Innovation

Methods, ideas, or system contributions that make the work stand out.

Query Complexity
Tree Width Approximation
Unidirectional UCRPQ Equivalence
🔎 Similar Papers
No similar papers found.