SearcharxivSearch

arXiv subjects

Surya Mathialagan

Publications and source records attributed to Surya Mathialagan.

6 recordsLinked to original sources

Preprocessed 3SUM for Unknown Universes with Subquadratic Space

We consider the classic 3SUM problem: given sets of integers $A, B, C $, determine whether there is a tuple $(a, b, c) \in A \times B \times C$ satisfying $a + b + c = 0$. The 3SUM Hypothesis, central in fine-grained complexity, states that there does not exist a truly subquadratic time 3SUM algorithm. Given this long-standing barrier, recent work over the past decade has explored 3SUM from a data structural perspective. Specifically, in the 3SUM in preprocessed universes regime, we are tasked with preprocessing sets $A, B$ of size $n$, to create a space-efficient data structure that can quickly answer queries, each of which is a 3SUM problem of the form $A', B', C'$, where $A' \subseteq A$ and $B' \subseteq B$. A series of results have achieved $\tilde{O}(n^2)$ preprocessing time, $\tilde{O}(n^2)$ space, and query time improving progressively from $\tilde{O}(n^{1.9})$ [CL15] to $\tilde{O}(n^{11/6})$ [CVX23] to $\tilde{O}(n^{1.5})$ [KPS25]. Given these series of works improving query time, a natural open question has emerged: can one achieve both truly subquadratic space and truly subquadratic query time for 3SUM in preprocessed universes? We resolve this question affirmatively, presenting a tradeoff curve between query and space complexity. Specifically, we present a simple randomized algorithm achieving $\tilde{O}(n^{1.5 + \varepsilon})$ query time and $\tilde{O}(n^{2 - 2\varepsilon/3})$ space complexity. Furthermore, our algorithm has $\tilde{O}(n^2)$ preprocessing time, matching past work. Notably, quadratic preprocessing is likely necessary for our tradeoff as either the preprocessing or the query time must be at least $n^{2-o(1)}$ under the 3SUM Hypothesis.

cs.DS

A Note on the Conditional Optimality of Chiba and Nishizeki's Algorithms

In a seminal work, Chiba and Nishizeki [SIAM J. Comput. `85] developed subgraph listing algorithms for triangles, 4-cycle and $k$-cliques, where $k \geq 3.$ The runtimes of their algorithms are parameterized by the number of edges $m$ and the arboricity $\alpha$ of a graph. The arboricity $\alpha$ of a graph is the minimum number of spanning forests required to cover it. Their work introduces: * A triangle listing algorithm that runs in $O(m\alpha)$ time. * An output-sensitive 4-Cycle-Listing algorithm that lists all 4-cycles in $O(m\alpha + t)$ time, where $t$ is the number of 4-cycles in the graph. * A k-Clique-Listing algorithm that runs in $O(m\alpha^{k-2})$ time, for $k \geq 4.$ Despite the widespread use of these algorithms in practice, no improvements have been made over them in the past few decades. Therefore, recent work has gone into studying lower bounds for subgraph listing problems. The works of Kopelowitz, Pettie and Porat [SODA `16] and Vassilevska W. and Xu [FOCS `20] showed that the triangle-listing algorithm of Chiba and Nishizeki is optimal under the $\mathsf{3SUM}$ and $\mathsf{APSP}$ hypotheses respectively. However, it remained open whether the remaining algorithms were optimal. In this note, we show that in fact all the above algorithms are optimal under popular hardness conjectures. First, we show that the $\mathsf{4}\text{-}\mathsf{Cycle}\text{-}\mathsf{Listing}$ algorithm is tight under the $\mathsf{3SUM}$ hypothesis following the techniques of Jin and Xu [STOC `23], and Abboud, Bringmann and Fishcher [STOC `23] . Additionally, we show that the $k\text{-}\mathsf{Clique}\text{-}\mathsf{Listing}$ algorithm is essentially tight under the exact $k$-clique hypothesis by following the techniques of Dalirooyfard, Mathialagan, Vassilevska W. and Xu [STOC `24]. These hardness results hold even when the number of 4-cycles or $k$-cliques in the graph is small.

cs.DS

Towards Optimal Output-Sensitive Clique Listing or: Listing Cliques from Smaller Cliques

We study finding and listing $k$-cliques in a graph, for constant $k\geq 3$, a fundamental problem of both theoretical and practical importance. Our main contribution is a new output-sensitive algorithm for listing $k$-cliques in graphs, for arbitrary $k\geq 3$, coupled with lower bounds based on standard fine-grained assumptions, showing that our algorithm's running time is tight. Previously, the only known conditionally optimal output-sensitive algorithms were for the case of $3$-cliques by Bj\"{o}rklund, Pagh, Vassilevska W. and Zwick [ICALP'14]. Typical inputs to subgraph isomorphism or listing problems are measured by the number of nodes $n$ or the number of edges $m$. Our framework is very general in that it gives $k$-clique listing algorithms whose running times are measured in terms of the number of $\ell$-cliques $\Delta_\ell$ in the graph for any $1\leq \ell<k$. This generalizes the typical parameterization in terms of $n$ (the number of $1$-cliques) and $m$ (the number of $2$-cliques). If the matrix multiplication exponent $\omega$ is $2$, and if the size of the output, $\Delta_k$, is sufficiently large, then for every $\ell<k$, the running time of our algorithm for listing $k$-cliques is $$\tilde{O}\left(\Delta_\ell^{\frac{2}{\ell (k - \ell)}}\Delta_k^{1-\frac{2}{k(k-\ell)}}\right).$$ For sufficiently large $\Delta_k$, we prove that this runtime is in fact {\em optimal} for all $1 \leq \ell < k$ under the Exact $k$-Clique hypothesis. In the special cases of $k = 4$ and $5$, our algorithm in terms of $n$ is conditionally optimal for all values of $\Delta_k$ if $\omega = 2$. Moreover, our framework is powerful enough to provide an improvement upon the 19-year old runtimes for $4$ and $5$-clique detection in $m$-edge graphs, as a function of $m$ [Eisenbrand and Grandoni, TCS'04].

cs.DS

Listing, Verifying and Counting Lowest Common Ancestors in DAGs: Algorithms and Fine-Grained Lower Bounds

The AP-LCA problem asks, given an $n$-node directed acyclic graph (DAG), to compute for every pair of vertices $u$ and $v$ in the DAG a lowest common ancestor (LCA) of $u$ and $v$ if one exists. In this paper we study several interesting variants of AP-LCA, providing both algorithms and fine-grained lower bounds for them. The lower bounds we obtain are the first conditional lower bounds for LCA problems higher than $n^{\omega-o(1)}$, where $\omega$ is the matrix multiplication exponent. Some of our results include: - In any DAG, we can detect all vertex pairs that have at most two LCAs and list all of their LCAs in $O(n^\omega)$ time. This algorithm extends a result of [Kowaluk and Lingas ESA'07] which showed an $\tilde{O}(n^\omega)$ time algorithm that detects all pairs with a unique LCA in a DAG and outputs their corresponding LCAs. - Listing $7$ LCAs per vertex pair in DAGs requires $n^{3-o(1)}$ time under the popular assumption that 3-uniform 5-hyperclique detection requires $n^{5-o(1)}$ time. This is surprising since essentially cubic time is sufficient to list all LCAs (if $\omega=2$). - Counting the number of LCAs for every vertex pair in a DAG requires $n^{3-o(1)}$ time under the Strong Exponential Time Hypothesis, and $n^{\omega(1,2,1)-o(1)}$ time under the $4$-Clique hypothesis. This shows that the algorithm of [Echkardt, M\"{u}hling and Nowak ESA'07] for listing all LCAs for every pair of vertices is likely optimal. - Given a DAG and a vertex $w_{u,v}$ for every vertex pair $u,v$, verifying whether all $w_{u,v}$ are valid LCAs requires $n^{2.5-o(1)}$ time assuming 3-uniform 4-hyperclique requires $n^{4 - o(1)}$ time. This defies the common intuition that verification is easier than computation since returning some LCA per vertex pair can be solved in $O(n^{2.447})$ time [Grandoni et al. SODA'21].

cs.DS

Distinct distances on non-ruled surfaces and between circles

We improve the current best bound for distinct distances on non-ruled algebraic surfaces in ${\mathbb R}^3$. In particular, we show that $n$ points on such a surface span $\Omega\left(n^{32/39-\varepsilon}\right)$ distinct distances, for any $\varepsilon>0$. Our proof adapts the proof of Sz\'ekely for the planar case, which is based on the crossing lemma. As part of our proof for distinct distances on surfaces, we also obtain new results for distinct distances between circles in ${\mathbb R}^3$. Consider point sets ${\mathcal P}_1$ and ${\mathcal P}_2$ of respective sizes $m$ and $n$, such that each set lies on a distinct circle in ${\mathbb R}^3$. We characterize the cases when the number of distinct distances between the two sets can be $O(m+n)$. This includes a new configuration with a small number of distances. In any other case, we prove that the number of distinct distances is $\Omega\left(\min\left\{m^{2/3}n^{2/3},m^2,n^2\right\}\right)$.

math.CO

On Bipartite Distinct Distances in the Plane

Given sets $\mathcal{P}, \mathcal{Q} \subseteq \mathbb{R}^2$ of sizes $m$ and $n$ respectively, we are interested in the number of distinct distances spanned by $\mathcal{P} \times \mathcal{Q}$. Let $D(m, n)$ denote the minimum number of distances determined by sets in $\mathbb{R}^2$ of sizes $m$ and $n$ respectively, where $m \leq n$. Elekes \cite{CircleGrids} showed that $D(m, n) = O(\sqrt{mn})$ when $m \leq n^{1/3}$. For $m \geq n^{1/3}$, we have the upper bound $D(m, n) = O(n/\sqrt{\log n})$ as in the classical distinct distances problem. In this work, we show that Elekes' construction is tight by deriving the lower bound of $D(m, n) = \Omega(\sqrt{mn})$ when $m \leq n^{1/3}$. This is done by adapting Sz\'{e}kely's crossing number argument. We also extend the Guth and Katz analysis for the classical distinct distances problem to show a lower bound of $D(m, n) = \Omega(\sqrt{mn}/\log n)$ when $m \geq n^{1/3}$.

math.CO