English

Approximately Counting Subgraphs in Data Streams

Data Structures and Algorithms 2022-03-29 v1

Abstract

Estimating the number of subgraphs in data streams is a fundamental problem that has received great attention in the past decade. In this paper, we give improved streaming algorithms for approximately counting the number of occurrences of an arbitrary subgraph HH, denoted #H\# H, when the input graph GG is represented as a stream of mm edges. To obtain our algorithms, we provide a generic transformation that converts constant-round sublinear-time graph algorithms in the query access model to constant-pass sublinear-space graph streaming algorithms. Using this transformation, we obtain the following results. 1. We give a 33-pass turnstile streaming algorithm for (1±ϵ)(1\pm \epsilon)-approximating #H\# H in O~(mρ(H)ϵ2#H)\tilde{O}(\frac{m^{\rho(H)}}{\epsilon^2\cdot \# H}) space, where ρ(H)\rho(H) is the fractional edge-cover of HH. This improves upon and generalizes a result of McGregor et al. [PODS 2016], who gave a 33-pass insertion-only streaming algorithm for (1±ϵ)(1\pm \epsilon)-approximating the number #T\# T of triangles in O~(m3/2ϵ2#T)\tilde{O}(\frac{m^{3/2}}{\epsilon^2\cdot \# T}) space if the algorithm is given additional oracle access to the degrees. 2. We provide a constant-pass streaming algorithm for (1±ϵ)(1\pm \epsilon)-approximating #Kr\# K_r in O~(mλr2ϵ2#Kr)\tilde{O}(\frac{m\lambda^{r-2}}{\epsilon^2\cdot \# K_r}) space for any r3r\geq 3, in a graph GG with degeneracy λ\lambda, where KrK_r is a clique on rr vertices. This resolves a conjecture by Bera and Seshadhri [PODS 2020]. More generally, our reduction relates the adaptivity of a query algorithm to the pass complexity of a corresponding streaming algorithm, and it is applicable to all algorithms in standard sublinear-time graph query models, e.g., the (augmented) general model.

Keywords

Cite

@article{arxiv.2203.14225,
  title  = {Approximately Counting Subgraphs in Data Streams},
  author = {Hendrik Fichtenberger and Pan Peng},
  journal= {arXiv preprint arXiv:2203.14225},
  year   = {2022}
}
R2 v1 2026-06-24T10:27:14.154Z