Improved algorithm for counting spanning trees by ℓ1-regularized resistance
Rong-Hua Li, Yichun Yang
RONG-HUA LI AND YICHUN YANG
ABSTRACT. We study the basic problem of approximating the number of spanning trees of a graph. We propose an algorithm that approximates the number of spanning trees in O(m+n7/4ε−3/2) time on a graph with n vertices and m edges. Our algorithm improves upon the previously best known O(m+n15/8ε−7/4) time algorithm by Chu, Gao, Peng, Sachdeva, Sawlani, and Wang [FOCS 2018] and the O(m1.5ε−1) time algorithm by Liu, Peng and Yang [FOCS 2026] when m⩾n7/6. Notably, our algorithm is based on the novel concept of ℓ1-regularized resistance. We propose simple and efficient algorithms for computing ℓ1-regularized resistance and we show that they can be used to approximate the number of spanning trees by combining with the determinant sparsifier framework of Durfee, Peebles, Peng, and Rao [FOCS 2017].
1. INTRODUCTION
Counting the number of spanning trees is a fundamental problem in theoretical computer science and graph theory. For a weighted undirected graph G=(V,E,w) with n vertices and m edges, let
T(G)=TspanningtreeofG∑e∈T∏we
be its total spanning-tree weight. The classical Kirchhoff’s matrix-tree theorem [Kir47] identifies T(G) with any cofactor of the graph Laplacian. Exact evaluation of T(G) therefore reduces to computing the Laplacian determinant, which takes nω arithmetic operations, where ω≈2.371 is the matrix-multiplication exponent [ADVW +25]. The related approximate counting problem is also studied in previous researches. Durfee, Peebles, Peng, and Rao firstly introduced determinant-preserving sparsification and a recursive Schur-complement algorithm for this problem [DPPR20]. They proposed a O(n2ε−2)1 time algorithm for ε-approximating the number of spanning trees.
The main difficulty of their algorithm is that computing determinant sparsifiers need to compute the effective resistance between many pairs of vertices under high precision. Therefore, an improved effective resistance estimation algorithm would implies a faster algorithm for approximate counting spanning trees. Later, Chu, Gao, Peng, Sachdeva, Sawlani, and Wang use short-cycle decompositions to improve the effective resistance estimation and obtained m1+o(1)+n15/8+o(1)ε−7/4 runtime for approximate counting spanning trees [CGP +18]. Recently, Liu, Peng, and Yang proposed a different O(m3/2ε−1) algorithm based on identifying uncorrelated edge sets [LPY25]. On expander graphs, Li and Sachdeva achieved O(m+n3/2ε−1) runtime via random walk-based local resistance representations [LS22]. Determinant sparsifiers require Ω(n3/2) edges in the worst case and can be constructed with O(n3/2poly(1/ε)) edges [DPPR20]; thus, for constant ε, the O(m+n3/2) bound is optimal under the determinant-sparsifier framework. Their approach, however, relies on constant spectral expansion so that random walks mix in O(1) steps, and does not extend to general graphs, since the random walk-based resistance estimation relies on the spectral gap of Laplacian matrix.
(Rong-Hua Li) SCHOOL OF COMPUTER SCIENCE, BEIJING INSTITUTE OF TECHNOLOGY, BEIJING, CHINA (Yichun Yang) SCHOOL OF COMPUTER SCIENCE, BEIJING INSTITUTE OF TECHNOLOGY, BEIJING, CHINA
1In this paper, we use O(⋅) to hide the logarithmic factors in terms of n, m, ε.
1.1. Main result. Our main result is a improved algorithm for counting the number of spanning trees on general graphs. For constant ε, our runtime bound is O(m+n7/4). It improves the O(m+n15/8) term by [CGP+18]. It is also faster than the recent O(m3/2) algorithm by [LPY25] whenever m⩾n7/6.
Theorem 1. Let G be a connected undirected graph with n vertices, m edges, and positive edge weights satisfying wmax/wmin⩽nO(1). For n−O(1)⩽ε⩽1/2, there is a randomized algorithm that returns T(G) such that (1−ε)T(G)⩽T(G)⩽(1+ε)T(G) with probability 2/3. The expected running time is
O(m+n7/4ε−3/2).
Next we explain the proof sketch of Theorem 1 and several key ingredients of our proof.
1.2. Estimating the resistance. We note that the main bottleneck of approximate spanning-tree counting in prior work is effective-resistance computation [DPPR20, CGP +18, LS22]. The speedup of our algorithm comes from an improved approach to resistance estimation. Unlike previous algorithms, which estimate resistances directly, we introduce the novel notion of ℓ1-regularized resistance and obtain an efficient algorithm by estimating these ℓ1-regularized resistances. We believe that the study of ℓ1-regularized resistances will also be of independent interest.
Definition 2. Given graph G with Laplacian LG and its pseudo-inverse LG†, let bs,t=es−et, the effective resistance between two vertices s and t is defined as
Rs,t=bs,tTLG†bs,t
Next we formally define the ℓ1-regularized resistance.
Definition 3. For a source s and a ℓ1-regularized parameter λ∈(1/n,1/2), consider the following optimization problem:
zs∗=argz⩾0min{21z⊤LGz−es⊤z+λ1⊤z}
with the residual qs∗=es−LGzs∗. We define zs∗ as the ℓ1-regularized potential, and
Rs,tλ=bs,tT(zs∗−zt∗)
as the ℓ1-regularized resistance between s and t.
We propose efficient algorithm for estimating the ℓ1-regularized resistance. By simple computation, the Karush–Kuhn–Tucker (KKT) conditions imply
0⩽qs∗⩽λ1,1Tqs∗=1,∣suppzs∗∣⩽λ−1.
Thus the ℓ1-regularized potential is local on every graph, its support size is independent on the number of vertices n. This property enables us to estimate the ℓ1-regularized potential zs∗ locally and efficiently. Inspired by the recent progress in ℓ1-regularized PageRank [WY26, MRWP23], we propose efficient algorithm for estimating ℓ1-regularized resistance in high accuracy.
Theorem 4. Given a graph G, accuracy parameter ξ, there is a randomized algorithm that takes O(m+nλ−3) preprocessing time to create a data structure of space O(nλ−1), from which one can query the ℓ1-regularized resistance R^u,vλ for any vertex pair (u,v) in O(1) time such that ∣R^u,vλ−Ru,vλ∣⩽ξ, with probability 1−n−O(1).
We then propose efficient sampler of effective resistance using the ℓ1-regularized resistance. We note that the ℓ1-regularized resistance Rs,tλ may not be a good estimator of the effective resistance Rs,t in general. However, combing with the classical result by Spielman and Srivastava [SS11], we show that the aggregate Pearson error of the resistance estimator can be bounded, which is already enough for computing the determinant sparsifier and approximate counting spanning trees (see Section 4).
Theorem 5. Given a graph G=(V,E,w), we can compute the approximate resistance Rs,t for every e=(s,t)∈E in O(m+nλ−3) time such that 41Rs,t⩽Rs,t⩽Rs,t, and
e=(s,t)∈E∑weRs,t(weRs,t−weRs,t)2⩽O(λn).
1.3. Constructing the determinant sparsifiers. We combine the resistance estimator by Theorem 4 and the determinant sparsifier framework by Durfee et. al [DPPR20]. The original result of [DPPR20] needs to compute the effective resistance between many pairs of vertices under high precision. So we strengthen the variance analysis of [DPPR20] and show that the resistance estimator by Theorem 4 is already enough to construct the determinant sparsifier and approximate the number of spanning trees.
Definition 6. Given a graph G=(V,E,w), a ε-determinant sparsifier of G is a (sparse) graph H such that (1−ε)TG⩽TH⩽(1+ε)TG.
Theorem 7. Given any graph G=(V,E,w), we can compute the ε-determinant sparsifier with high probability in O(m+nλ−3+λn2ε−2+n3/2ε−1) time.
By extending the determinant sparsifier to the Schur complement, we can approximate the number of spanning trees in the same asymptotic time as constructing the determinant sparsifier. Balancing the runtime by setting λ=n−1/4ε1/2, we obtain the O(m+n7/4ε−3/2) time algorithm for approximate counting spanning trees, which is the result of Theorem 1.
1.4. AI disclaimer. The high-level ideas and the overall proof structure of this paper were designed by the authors. The detailed proofs are generated by GPT-5.6 Sol. All proofs were verified by the authors.
2. PRELIMINARIES
We work with a connected undirected weighted graph G=(V,E,w), where n=∣V∣, m=∣E∣, and all edge weights are positive. Parallel edges may be aggregated and self-loops are discarded. For an edge e=(u,v), let be=eu−ev. We write the Laplacian matrix L=LG=∑e∈Ewebebe⊤, the effective resistance Ru,v=bu⊤L†bu,v. Let dv=∑(u,v)∈Ewuv, dmax=maxvdv, and let wmin be the minimum nonzero edge weight. The leverage score of e is ℓe=weRu,v. We record two classical identities.
Lemma 8 (Foster’s theorem [Fos49]). For every edge e∈E, 0<ℓe⩽1, and
e∈E∑ℓe=n−1.
Lemma 9 (Kirchhoff’s matrix-tree theorem [Kir47]). For every root r∈V,
T(G)=detL[V∖{r},V∖{r}].
Let V=F⊔T be a partition of the vertices such that the principal submatrix LFF is invertible. The Schur complement of L onto T is Sc(L,T):=LTT−LTFLFF−1LFT. Block factorization of the Laplacian gives
Since q=es−Lz=λ1−g, they give q⩽λ1 and qv=λ on v∈supp(z). If v∈/supp(z) and v=s, then qv=∑uwuvzu⩾0. The source s∈supp(z), since otherwise qs=1+∑uwsuzu⩾1>λ. In addition, we have 1⊤q=1⊤(es−Lz)=1⊤es=1. Consequently, 1=∑vqv⩾λ∣supp(z)∣. Finally, the existence and uniqueness of zs∗ are standard for this convex quadratic program [BV04, Sec. 4.2.5, 10.1].
The following theorem is the high-accuracy ℓ1-regularized potential estimation. The logarithmic factors in the accuracy and failure probability are included in O(⋅).
Theorem 13. After O(m) preprocessing of G, for any source s, accuracy η>0, one can compute a vector zs in O(λ−3) time such that, with probability 1−n−O(1),
Moreover, qs=es−Lzs satisfies 0⩽qs⩽2λ1 and 1⊤qs=1.
We first use Theorem 13 to prove Theorem 4, and then prove Theorem 13.
Proof of Theorem 4. Run Theorem 13 for every s∈V with η=ξ/4 and failure probability n−O(1), and store every sparse column {zs}s∈V in a static hash table. The total preprocessing time is O(m+nλ−3) and output space is O(nλ−1). For a query (u,v) return
A union bound for the failure probability over the n source computations proves Theorem 4.
Next we prove Theorem 13. Inspired by the recent progress in ℓ1-regularized PageRank [WY26, MRWP23], we design Algorithm 1 for computing the ℓ1-regularized potential in high accuracy. Intuitively, the algorithm starts with the active set A={s} and then repeat searching ∂A to enlarge A until A=suppzs∗. For a set A⊆V containing s, define the exact restricted solution, extended by zero outside A, by
xAA=LAA−1(es∣A−λ1A),xV∖AA=0,qA=es−LxA.
However, we note that the active set A can have a very large boundary ∂A. We therefore do not enumerate ∂A for the active set process. Instead, we use the following oracle.
Lemma 14. After O(m) static preprocessing, the following operations are available. Let A⊊V, let x⩾0 be supported on A. Put q=es−Lx, and assume qA⩾0. For any threshold θ⩾λ, an implicit boundary oracle returns
Heavy(A,x,θ)={v∈V∖A:qv>θ}
exactly, with probability 1−n−O(1), in O(∣A∣2+∣A∣λ−1) time. Moreover, after additional O(∣A∣2) setup using the same data structure, one can draw an exact sample from the residual q=es−Lx in O(1) time.
Proof. First we describe the preprocessed data structure that enables us to sample v∈N(u)∖A proportional to wu,v in O(1) time. In the static preprocessing, sort every weighted adjacency list by vertex label, store its prefix sums, and build a hash table mapping every neighbor label to its edge weight and position in the sorted list. For a fixed u∈A, deleting the at most ∣A∣ labels in A partitions N(u)∖A into at most ∣A∣+1 contiguous ranges of the sorted adjacency list. Prefix sums give the weight of every range. In O(∣A∣) time we can therefore build an alias table over these ranges. After choosing a range, a prefix-sum search samples an edge in that range proportional to its weight. Doing this for every u∈A costs O(∣A∣2) time and space. As a result, we can sample v∈N(u)∖A proportional to wu,v. Write
dV∖A(u)=v∈/A∑wuv,B=u∈A∑xudV∖A(u).
For v∈/A, nonnegativity and the support of x give
qv=u∈A∑wuvxu,B=v∈/A∑qv⩽1,
where the last inequality uses qA⩾0 and 1⊤q=1. If B>0, first sample u∈A with probability xudV∖A(u)/B, and then sample v∈N(u)∖A proportional to wuv. The output distribution is exactly
Pr[v]=B1u∈A∑xuwuv=Bqv.
Take R=O(λ−1log(n)) independent samples from this distribution and let CA be the set of distinct sampled vertices. If qv>θ⩾λ, then v belongs to CA with probability at least 1−n−O(1) by Chernoff's inequality. For every v∈CA, evaluate qv=∑u∈Awuvxu using ∣A∣ hash-table queries and retain v if and only if qv>θ. Exact verification creates no false positives and costs O(∣A∣λ−1) in total.
We next construct the residual sampler. Using the hash tables, compute qA explicitly by
qv=(es)v−u∈A∑wvuxu
Algorithm 1: high accuracy ℓ1-regularized Potential (s,λ,κ,τ,η)
Input: source s∈V, parameter λ>0, activation gap κ>0, accuracy τ,η>0, failure probability δ>0
Output: approximate obstacle potential zs⩾0 and residual qs=es−Lzs
1 A←{s}, where A is the active set;
2 while true do
3 invoke the SDD solver of Lemma 10 on LAAxA=es∣A−λ1A with accuracy τ, obtaining xA;
4 T←Heavy(A,x,λ+κ/2) using Lemma 14;
5 if T=∅ then
6 extend xA to zs∈RV by setting zs,v∖A←0;
7 return zs and qs←es−Lzs
8 A←A∪T;
for v∈A in O(∣A∣2) time, and store the active masses (i.e. qv with v∈A). The inactive mass is B=∑v∈/Aqv=1−1A⊤qA. To sample a node v from q: With probability B, we sample u∈A with probability xudV∖A(u)/B, and then sample v∈N(u)∖A proportional to wuv. With probability 1−B, we sample v from qA. The output distribution is exactly q. Each sample takes O(1) time.
To analyze the complexity and accuracy of Algorithm 1, we first show that when assuming the solution is exact (i.e., set τ=0 in Algorithm 1), then xA in each epoch is monotonely increasing.
Lemma 15 (Monotone active sets). The exact restricted solutions satisfy the following.
(i) If A⊆As∗:=suppzs∗, then xA⩽zs∗ coordinatewise.
(ii) If B⊆V∖A and qvA>λ for every v∈B, then A∪B⊆As∗ and xA∪B⩾xA coordinatewise. Every newly inserted coordinate satisfies
xvA∪B⩾dvqvA−λ(v∈B).
(iii) For A={s}, we have xA>0. Consequently, if A is obtained from {s} by repeatedly inserting every vertex with qvA>λ, then xA⩾0.
Proof. Let C=As∗∖A. To prove (i), we consider the KKT condition: (Lzs∗)v=(es)v−λ for v∈As∗. We restrict the optimality equation on As∗ to A and have
xAA=zs,A∗+LAA−1LACzs,C∗⩽zs,A∗.
This is because LAA−1⩾0 and LAC⩽0 elementwise. So we prove (i).
Thus every vertex with qvA>λ lies in As∗. So if every v∈B satisfies qvA>λ, then A∪B⊆As∗. Put A′=A∪B and extend xA by zero on B. Subtracting the two restricted linear systems gives
LA′A′(xA′−xA)=(0AqBA−λ1B)⩾0.
The inverse of a nonsingular SDDM matrix is nonnegative, so xA′⩾xA. Moreover (LA′A′−1)vv⩾1/dv, so xvA∪B⩾(qvA−λ)/dv for every v∈B∖A.
For (iii), the initial solution xs{s}=(1−λ)/ds>0 since λ<1/2. Now we consider the vertex set A is obtained from {s} by repeatedly inserting every vertex with qvA>λ. If xA≥0 and B is inserted because qvA>λ on B, then by (ii), we have xA∪B≥xA≥0 and every v∈B satisfies xvA∪B≥(qvA−λ)/dv>0. Induction on the number of insertions proves the claim.
By Lemma 15, starting with A={s} and repeatedly inserting every vertex with qvA>λ therefore reaches zs∗ in at most ∣As∗∣⩽λ−1 rounds. However, solving the linear system LA,AxA=es∣A−λ1A exactly in each round is expensive. So in Algorithm 1 we make this process robust to approximate solves using nearly linear time Laplacian solver.
We use the following error conversions. If M=LA,A, b=es∣A−λ1A, x=M−1b, and ∥x−x∥M⩽τ, then energy Cauchy-Schwarz gives ∣eu⊤M(x−x)∣⩽duτ for u∈A and ∣LvA(x−x)∣⩽dvτ for v∈/A; extending x−x by zero and using λmin(LA,A)⩾wmin/n2 also yields ∥x−x∥∞⩽nτ/wmin. Although Lemma 10 is stated with relative energy error, we invoke it with internal relative tolerance at most τwmin/n3/2. Indeed, ∥M−1b∥M2=b⊤M−1b⩽n3/wmin, so this choice gives the absolute energy error τ used above and adds only logarithmic factors.
Proof of Theorem 13. Set B0=4n3/wmin, ζ=wminn2/(4n2), and set κ, τ sufficiently small:
κ=min{100λ,100B0ζ},τ=32ndmaxκwmin.
So κ,τ=n−Θ(1). Give every invocation of the implicit boundary oracle failure probability δbd=n−c0−3, where the constant c0 is chosen as large as needed. Since there are at most n+1 epochs, a union bound makes all boundary-oracle calls correct with probability 1−n−c0−2. We condition on this event and on the success of the SDD solves below. We prove by induction on the epoch number that Algorithm 1 is well defined, that A⊆As∗, and that x⩾0. We also maintain the stronger exact-solution bounds
xsA⩾2dmax1,xuA⩾16dmax7κ(u∈A∖{s}).
Base case. Initially A={s}. The exact restricted solution is xs{s}=(1−λ)/ds⩾1/(2dmax), and {s}⊆As∗. The first solve returns x with x−x{s}∞⩽nτ/wmin<λ/(2dmax), so xs>0.
Inductive step. Suppose the inductive claim holds at the start of an epoch with active set A. Let xA be the exact restricted solution on A, let x be the approximate solve in this epoch, and put q=es−Lx. The error bound gives ∣qu−λ∣⩽duτ⩽κ/16 for every u∈A.
By Lemma 14, the set returned by the successful oracle call is exactly Γ={w∈∂A:qw>λ+κ/2}. Now take any v∈Γ. Since xA vanishes outside A, we have qvA=∑u∈AwvuxuA, and therefore qvA⩾qv−∣LvA(x−xA)∣⩾(λ+κ/2)−dvτ⩾λ+7κ/16. In particular qvA>λ, so v∈As∗ by Lemma 15 (ii), and hence A∪Γ⊆As∗.
Let A′=A∪T and let xA′ be the exact restricted solution on A′. Lemma 15 (ii) gives xA′⩾xA⩾0 coordinatewise and, for every newly inserted v∈T, xvA′⩾(qvA−λ)/dv⩾7κ/(16dmax). The monotonicity xA′⩾xA preserves the displayed lower bounds for the old coordinates, and the preceding inequality establishes the required bound for every new coordinate. After the next solve on A′, the returned vector x′ satisfies x′−xA′∞⩽nτ/wmin⩽κ/(32dmax). Thus the source coordinate remains positive, while every other active coordinate is at least 7κ/(16dmax)−κ/(32dmax)>0. This proves x′⩾0 and closes the induction. If T=∅, the algorithm returns the current x, which is already nonnegative.
Next we prove 0⩽q⩽2λ1. For v∈/A, we have qv=∑u∈Awuvxu⩾0 because x⩾0. Since 1⊤q=1, the vector q is a probability distribution. When the algorithm stops, Γ=∅, so every v∈∂A satisfies qv⩽λ+κ/2, while every v not adjacent to A has qv=0. Thus at termination we have ∣λ−qv∣=∣qv−qv∣⩽dvτ⩽κ/16 for v∈A and 0⩽qv⩽λ+κ/2 for v∈/A. In particular, 0⩽q⩽2λ1.
Next, we prove the ℓ∞ accuracy ∥zs−zs∗∥∞⩽η. The Dirichlet eigenvalue bound above implies ∥χA∥1⩽n3/wmin for every restricted linear system, and enlarging the constant gives ∥zs∗∥1⩽B0 and ∥zs∥1⩽B0. Let g=Lzs−es+λ1=λ1−qs and h=zs−zs∗. Since zs∗ minimizes Φs over z⩾0 and zs⩾0, we have Φs(zs)−Φs(zs∗)⩾0. Expanding Φs at zs gives the exact identity
Φs(zs)−Φs(zs∗)=g⊤h−21∥h∥L2⩽g⊤h.
At termination, ∣gv∣⩽κ/16 for v∈A, while gv=λ−qv⩾−κ/2 for v∈/A. In addition, zs vanishes outside A and ∥zs∥1, ∥zs∗∥1⩽B0. Therefore
where the last step uses κ⩽ζ/(100B0). Combining these bounds,
0⩽Φs(zs)−Φs(zs∗)⩽ζ.
On the other hand, if g∗=Lzs∗−es+λ1, then g∗⩾0 and (g∗)⊤zs∗=0, so Φs(zs)−Φs(zs∗)=(g∗)⊤zs+21∥zs−zs∗∥L2⩾21∥zs−zs∗∥L2. Both vectors vanish outside As∗. By ∥zs−zs∗∥L2⩽2ζ, we have that ∥zs−zs∗∥∞⩽n2ζ/wmin⩽η.
Finally let k=∣As∗∣⩽λ−1. There are at most k+1 restricted solves, and each restricted matrix has O(k2) nonzeros, so it takes O(k2) time for solving the restricted linear system by Lemma 10. Their total cost is O(k3). At an epoch with a=∣A∣⩽k, the implicit boundary oracle costs O(a2+aλ−1)⩽O(k2); over at most k+1 epochs its total cost is O(k3). In particular, the algorithm never enumerates a possibly dense boundary. The one-time static adjacency preprocessing costs O(m). We prove the claimed O(λ−3) runtime bound.
3.2. Approximating effective resistance under aggregate error. We now prove Theorem 5. The first lemma gives the aggregate error of the exact ℓ1-regularized resistance on the original graph.
Lemma 16. For e=(u,v), define the leverage scores ℓe and the regularized leverage scores he as follows:
he=weRu,vλ=webu,vT(zu∗−zv∗),ℓe=weRu,v.
Then for every e∈E
0⩽he⩽ℓe,e∈E∑(ℓe−he)=λn−1.
Proof. Let gs=Lzs∗−es+λ1. The KKT conditions give gs⩾0 and gs⊤zs∗=0. For r=zu∗−zv∗ and b=eu−ev,
∥r∥L2−bTr=(gu−gv)Tr=−guTzv∗−gvTzu∗⩽0.
Therefore 0⩽∥r∥L2⩽b⊤r. Cauchy-Schwarz inequality gives b⊤r⩽b⊤L†b∥r∥L. Combining the two inequalities yields
0⩽bT(zu∗−zv∗)⩽bTL†b,
and hence 0⩽he⩽ℓe.
Let Z=[zs∗]s∈V and Q=[qs∗]s∈V. By Lemma 12, TrQ=λn, while LZ=I−Q. For each source s, the Laplacian identity Lzs∗=es−qs∗ gives
Because ℓe=weRu,v and ae=weRu,v, this is exactly the bound stated in Theorem 5. The runtime of computing ℓ1-regularized potential and the constant-factor sketch is bounded by O(m+nλ−3). This completes the proof.
4. CONSTRUCTING THE DETERMINANT SPARSIFIERS
In this section, we use the approximate resistances of Theorem 5 to construct determinant sparsifiers, and thereby prove Theorem 7. We then extend the same construction to implicit Schur complements, and combine it with the determinant-preserving recursion of [DPPR20] to obtain an algorithm for approximate spanning-tree counting, in the same asymptotic time as building the sparsifier.
4.1. Determinant sparsification from resistance estimation. In this subsection we prove Theorem 7. Let S=n−1 be the number of edges in a spanning tree; Foster's identity gives ∑e∈Eℓe=S for the true leverage scores ℓe=weRe. By Theorem 5, we may assume the approximate leverage scores ae=weRe, so that
E0:=e∈E∑ae(ℓe−ae)2=O(λn).
The determinant sampling framework of [DPPR20] samples edges from a distribution with total mass S, matching the normalization of the true leverage scores. In general ∑eae need not equal S, so we set A=∑eae and renormalize to the sampling masses re:=Sae/A, for which ∑ere=S. The deviation of this distribution from the true leverage scores is measured by the Pearson error
Ξ(r∥ℓ):=e∈E∑re(re−ℓe)2,
which controls the second-moment bound below. The next lemma bounds this Pearson error after renormalization.
Lemma 17. Let A=∑e∈Eae, S=n−1 and re=Sae/A. If ∑e∈E(ℓe−ae)2/ae⩽E0 and ae⩾ℓe/4 for every edge e, then A=Θ(S), re⩾ℓe/C for an absolute constant C, and Ξ(r∥ℓ)=O(E0).
Proof. Since ae⩾ℓe/4 and ∑eℓe=S, we have A⩾S/4. Foster's identity and Cauchy-Schwarz give
Using ae⩾ℓe/4 in the second factor yields ∣A−S∣⩽2SE0. Together with E0=O(S), this proves A=Θ(S) and hence re=Sae/A⩾ℓe/C for some absolute constant C.
Put c=S/A. Since re−ℓe=c(ae−ℓe)+(c−1)ℓe,
Ξ(r∥ℓ)⩽2ce∑ae(ae−ℓe)2+2(c−1)2c−1e∑aeℓe2.
The first term is O(E0). For the second, ∑eℓe2/ae⩽4S, c−1=Θ(1) and (c−1)2=(A−S)2/A2=O(E0/S), so the second term is also O(E0).
We next provide the variance analysis of determinant sparsification. Our proof strengthens the result in [DPPR20] from pointwise leverage-score approximation to an aggregate Pearson-error guarantee.
Lemma 18 (Aggregate-error determinant sampling). Let re>0 satisfy ∑ere=S and re⩾ℓe/C. Independently draw t⩾4S edges with probabilities pe=re/S. Give every sampled copy of e weight we′=(weS/re)(1/(t)S)1/S, where (t)S=t(t−1)⋯(t−S+1). If H is the resulting weighted multigraph, then the expectation and second moment satisfy
Proof. We first prove E[T(H)]=T(G). Let Xe be the number of copies of e among the t samples. Each copy of e has weight we′, so the total weight of e in H is Xewe′. Therefore
T(H)=Tspanning∑e∈T∏(Xewe′),
where the sum ranges over all spanning trees of G. By linearity of expectation,
E[T(H)]=Tspanning∑(e∈T∏we′)E[e∈T∏Xe].
Fix a spanning tree T. Expanding ∏e∈TXe amounts to choosing, for each edge of T, one of the t sample positions. Only choices with S pairwise distinct positions contribute, so there are (t)S such ordered choices. Each choice has probability contribution ∏e∈Tpe, so
Summing over all spanning trees T yields E[T(H)]=T(G).
For the second moment, let μ be the weighted spanning-tree probability measure of G, so μ(T)∝∏e∈Twe and μ(F⊆T):=∑T:F⊆Tμ(T). Squaring the display above and dividing by T(G)2 gives
Fix an ordered pair of spanning trees (T1,T2). On every edge e∈T1∩T2 we have a factor Xe2, which we expand as Xe2=(Xe)2+(Xe)1, where (Xe)1=Xe is linear term and (Xe)2=Xe(Xe−1) is quadratic term, counting the number of ordered pairs of distinct sample positions among the t draws that both land on e. Choosing the linear term on a subset F⊆T1∩T2 and the quadratic term on the remaining common edges yields a sum over such F. Edges in exactly one of T1, T2 contribute a single factor (Xe)1. Inserting this expansion into the previous equation gives
Thus each term in the expansion is a product of falling factorials (Xe)je with je∈{1,2}. The multinomial identity
E[e∏(Xe)je]=(t)∑ejee∏peje
applies to every such term. For a fixed F, the total exponent is ∑eje=2S−∣F∣, because the two trees contribute 2S linear slots and each edge of F replaces a quadratic slot by a linear one. The sampled-copy weights contribute a factor (t)S−2 from the two trees, so the sampling expectation carries the prefactor (t)2S−∣F∣/(t)S2. Moreover, every e∈F leaves one extra factor pe−1 after the weight normalization, whereas the tree weights over (T1,T2) sum to μ(F⊆T)2. Collecting these contributions over all pairs (T1,T2) and all subsets F⊆T1∩T2 gives
Weighted spanning trees are negatively associated [BP93, DPPR20], so μ(F⊆T)⩽∏e∈Fℓe. Substituting into the collision expansion and grouping by k=∣F∣ gives
Proof of Theorem 7. By Lemma 17, the renormalized masses re=Sae/A satisfy A=Θ(S), re⩾ℓe/C, and Ξ(r∥ℓ)=O(λn). Take t=O(λn2ε−2+n3/2ε−1) and apply Lemma 18. The exponent in the second-moment bound is O(ε2), so Var(T(H))/T(G)2=O(ε2). Chebyshev's inequality shows that H is an ε-determinant sparsifier with constant probability. Computing the scores and their normalizer takes O(m+nλ−3) time, while alias-table construction and sampling take O(m+t) time.
4.2. Schur complements and recursive tree counting. To approximate T(G), we follow the determinant sparcification framework of [DPPR20] (see also [CGP +18, LS22]): at each node of size N, we eliminate a constant fraction of the vertices and recurse on two smaller children, as illustrated in Figure 1. Concretely, one finds a diagonally dominant set F⊆V with F=Θ(N), puts T=V∖F, and splits the current Laplacian into two subgraphs. In the first child, the vertices of F are completed to a Laplacian by adjoining a single auxiliary vertex that absorbs all edges from F into T; this child encodes det(LFF). In the second child, one forms the Schur complement K=Sc(L,T) on the terminal set T. Block elimination and Kirchhoff's theorem then give the identity
T(G)=det(LFF)T(K),
so it suffices to approximate the tree counts of the two children separately. The completion child is an explicit graph and can be handled by recursion. The Schur child K, however, is generally dense and expensive to compute. We therefore replace K by a determinant sparsifier, without forming K explicitly. Because our resistance estimates satisfy only an aggregate Pearson bound rather than a pointwise guarantee, we need to strengthen several intermediate results of [DPPR20] to prove the sparsification on Schur complement. Consider an explicit graph G with Laplacian L, N vertices, and M edges. We use the following Lemma to partition G into two parts.
Lemma 19. [KLP +16] Let G=(V,E,w) be a connected weighted graph with N vertices, M edges, and Laplacian L. In O(M) expected time one can find a 1.1-diagonally dominant set F⊆V with N/16⩽∣F∣⩽N/8.
FIGURE 1. Two layers of the determinant-preserving recursion of [DPPR20]. At each internal node, the Laplacian splits into a Schur-sparsification child on the terminal set T (replacing the Schur complement K by a sparse random graph H) and a completion child on the eliminated set F (completing LFF to a Laplacian on F∪{r}).
Given F output by Lemma 19, put T = V \ F, K = Sc(L, T) = L_{TT} - L_{TF} L_{FF}^{-1} L_{FT}, and S_T = |T| - 1. Then T(G)=det(LFF)T(K). Instead of computing the Schur complement K directly, we can compute the determinant sparcification of K without explicitly constructing K. Our goal is to prove the following Lemma, which states the determinant sparcification on Schur complement.
Lemma 20 (Aggregate-error Schur sparsification). For every 0<α<1/10, there is a procedure that outputs a random graph H on T with O(N3/2α−1/2+λN2α−1) edges. Its expected running time is O(M+Nλ−3+N3/2α−1/2+λN2α−1), and
e−αT(K)⩽E[T(H)]⩽eαT(K),(E[T(H)])2E[T(H)2]⩽eα.
Lemma 20 is the key step to prove Theorem 1. There are several steps to prove Lemma 20. First, we provide the following random walk representation of the Schur complement.
Lemma 21. [DPPR20, Section 5] Write LFF=DFF−AFF. Let PT,F contain one labelled undirected path p=(u0,u1,…,uk) for every finite walk whose distinct endpoints u0,uk lie in T and whose internal vertices lie in F. Give p weight defined as
wp=∏i=1k−1dui∏i=0k−1wuiui+1.
Then the Schur complement is the Laplacian of this labelled multigraph:
K=p∈PT,F∑wpbu0,ukbu0,ukT.
Consequently, a labelled edge of K may be viewed as a path that starts in T, travels only through F, and returns to T. Its leverage score is ℓp=wpRK(u0,uk), and ∑p∈PT,Fℓp=∣T∣−1.
We show that the ℓ1-regularized potential and ℓ1-regularized resistance can be computed on Schur complement from parent graph.
Lemma 22. For every s∈T, let zs∗ be the ℓ1-regularized potential on the parent graph and let qs∗=es−Lzs∗. Define P=−LFF−1LFT and qˉs,T=qs,T∗+PTqs,F∗. Then qˉs,T is a probability vector and
Kzs,T∗=es−qˉs,T.
If Qˉ=[qˉs,τ]s∈T, then TrQˉ⩽λN. Moreover, for every labelled path p∈PT,F with endpoints u,v, define
hp=wpbu,vT(zu∗−zv∗),ℓp=wpRK(u,v).
Then
0⩽hp⩽ℓp,p∈PT,F∑(ℓp−hp)=TrQˉ−1⩽λN−1.
Proof. The principal submatrix LFF is a nonsingular M-matrix, so LFF−1⩾0 entrywise and hence P⩾0. The identity L1=0 also gives LFF1F=−LFT1T, and therefore P1T=1F. It follows from qs∗⩾0 that qˉs,T⩾0, while
1TTqˉs,T=1TTqs,T∗+1FTqs,F∗=1.
Thus qˉs,τ is a probability vector. The F block of the equation qs∗=es−Lzs∗ gives LFFzs,F+LFTzs,T=−qs,F and therefore zs,F=Pzs,T−LFF−1qs,F. The T block equation gives LTFzs,F+LTTzs,T=es−qs,T∗. Substituting zs,F gives LTF(Pzs,T−LFF−1qs,F)+LTTzs,T=es−qs,T. By the definition of K, we have that Kzs,T=es−qs,T−PTqs,F=es−qˉs,T.
The property qs∗⩽λ1 and the row-sum identity for P give
The proof of Lemma 16 applies to every pair of vertices, we have 0⩽bu,vT(zu∗−zv∗)⩽RG(u,v). Schur complementation preserves effective resistance between terminals, so RG(u,v)=RK(u,v) and therefore 0⩽hp⩽ℓp.
Finally, let ZT=[zs,T]s∈T. By Lemma 21,
p∑hp=Tr(KZT)=Tr(I−Qˉ)=∣T∣−TrQˉ.
Foster’s identity gives ∑pℓp=∣T∣−1. Subtracting the preceding identity proves ∑p(ℓp−hp)=TrQˉ−1, and the trace bound completes the proof.
Lemma 23. In O(M+Nλ−3) preprocessing time, one can construct an implicit nonnegative score ap for every labelled path p∈PT,F. Given a sampled path p and its weight wp, the score ap can be evaluated in O(1) time. Moreover, let A=∑pap and define rp=(∣T∣−1)ap/A be the normalized estimator. Then
p∑rp=(∣T∣−1),rp⩾ℓp/C,p∑rp(rp−ℓp)2=O(λN)
for an absolute constant C.
Proof. For every s∈T, run Theorem 13 on the parent graph to coordinate accuracy γ/(4dmax), where γ=λ/32, and store the resulting sparse vector zs. Since RG(u,v)=RK(u,v)⩾1/dmax, the score hp=wpbu,v⊤(zu−zv) satisfies ∣hp−hp∣⩽γℓp. A constant-factor resistance sketch of the parent graph by Lemma 11 supplies a value cp∈[ℓp/4,ℓp] for the endpoints of p. Define
ap=max{cp,max{0,hp}}.
Both endpoint-potential queries and the resistance-sketch query take O(1) time once p and wp are given. Computing all terminal potentials and the resistance sketch takes O(M+Nλ−3) time.
Finally we analyze the error. The aggregate error between hp and ℓp is guaranteed by Lemma 22. By the same argument as the proof of Theorem 5, we can prove that ∑pap(ℓp−ap)2=O(λN). By the same argument as the proof of Lemma 17, we can prove that A=Θ(∣T∣−1) and that the normalized leverage scores rp=(∣T∣−1)ap/A have Pearson error ∑prp(rp−ℓp)2=O(λN).
We next show how to sample a schur path from the distribution of normalized leverage scores rp. The following lemma records the Schur-path proposal of [DPPR20, Lemma 5.5], which samples a labelled edge of the implicit Schur complement without constructing K.
Lemma 24 ([DPPR20], Lemma 5.5). Let F be a 1.1-diagonally dominant set, T = V \ F, K = Sc(L, T). Given constant-factor estimates of all parent-edge leverage scores, there is a sampler that returns a labelled Schur path p=(u0,u1,…,uk)∈PT,F together with its proposal probability pp0, such that
ℓp:=wpRK(u0,uk)⩽ρ(∣T∣−1)pp0
for some absolute constant ρ=O(1). The expected path length and sampling time are O(1).
Then the schur path sampled from the distribution of rp can then be derived by rejection sampling.
Lemma 25. After the preprocessing of Lemma 23, a labelled path p can be sampled exactly with probability
Pr[p]=∣T∣−1rp=Aap
in O(1) expected time.
Proof. By Lemma 24, a proposal path p and its probability pp0 can be generated in constant expected time, with ℓp⩽ρ⋅(∣T∣−1)pp0 for some absolute constant ρ=O(1). The construction in Lemma 23 gives ap⩽(1+γ)ℓp for small γ<1/2. We accept the proposed path with probability
(1+γ)ρ(∣T∣−1)pp0ap.
The probability of proposing and accepting a particular p is ap/(1+γ)ρ(∣T∣−1). Thus, conditioned on acceptance, the output law is ap/A=rp/(∣T∣−1). The total acceptance probability is
p∑(1+γ)ρ(∣T∣−1)ap=((1+γ)ρ(∣T∣−1))A=Θ(1),
proving the expected-time claim.
Next, we need to assign the weight to each sampled path p. The sampled edge weights require the normalizer A. However, enumerating all the Schur paths to compute A is expensive. The following lemma shows that A can be estimated efficiently.
Lemma 26. For every 0<α<1/10, after the preprocessing of Lemma 23, in O(λN2α−1+Nα−1/2) additional expected time, one can construct an estimate A⩾(∣T∣−1)/8 such that for Z=(A/A)∣T∣−1,
e−α⩽E[Z]⩽eα,(E[Z])2E[Z2]⩽eα.
Proof. For s∈T, put qs=es−Lzs. As in Lemma 22, define the swept residual qˉs,⊤=qs,⊤+P⊤qs,F and let Qˉ=[qˉs,⊤]s∈T. Define
The same block elimination as in Lemma 22, applied to Lzs=es−qs, gives Kzs,T=es−qˉs,T. In matrix form, KZT=I−Qˉ, where ZT=[zs,T]s∈T. Hence the Schur-path representation gives ∑php=Tr(KZT)=∣T∣−Θ. Using the equation max{x,y}=y+(x−y)+ and max{0,x}=x+(−x)+ we have
A=p∑ap=p∑max{cp,max{0,hp}}=∣T∣−Θ+C0+R0.
We next construct unbiased estimators for the three terms Θ, C0, R0 using Bernoulli coins.
(i) Estimating Θ. The residual sampler needed here can be included in the preprocessing at no additional asymptotic cost. For each terminal source s, after computing zs, apply Lemma 14 with A=suppzs and x=zs. This builds an implicit sampler for the possibly dense residual qs in O(λ−2) time and space per source, hence O(Nλ−2) total preprocessing time, which is dominated by the existing O(Nλ−3) potential-computation cost. A node can then be sampled from qs in O(1) time without explicitly materializing the residual. Now choose s∈T uniformly and draw x∼qs. If x∈T, set Y=x; if x∈F, run the weighted random walk from x until its first hit in T and call the hit vertex Y. The distribution of Y is precisely the swept residual qˉs,T. Hence the Bernoulli coin 1{Y=s} has expectation Θ/∣T∣. Since F is 1.1-diagonally dominant, the expected length of the random walk is O(1). In addition, 0⩽qs⩽2λ1 and P1T=1F imply the upper bound Θ⩽2λ∣T∣+2λ∑x∈F∑s∈TPx,s=2λN.
(ii) Estimating C0. Draw p from the proposal distribution p0 of Lemma 24. Since hp≥0 and ∣hp−hp∣≤γℓp, it holds that (−hp)+≤γℓp≤γρ(∣T∣−1)pp0. We may therefore return a Bernoulli coin with conditional success probability γρ(∣T∣−1)pp0(−hp)+. Its expectation is C0/(γρ(∣T∣−1)), and Foster's identity gives the upper bound C0≤γ∑pℓp=γ(∣T∣−1).
(iii) Estimating R0. Again draw p∼p0. Pointwise, (cp−max{0,hp})+⩽cp⩽ℓp⩽ρSTpp0, so we draw a Bernoulli coin has conditional success probability ρSTpp0(cp−max{0,hp})+. Its expectation is R0/(ρ(∣T∣−1)). Moreover, max{0,hp}⩾hp−γℓp and cp⩽ℓp give (cp−max{0,hp})+⩽(ℓp−hp)+γℓp. Consequently, Lemma 22 and Foster's identity imply R0⩽λN−1+γST=O(λN).
Applying the Bernstein moment bound [BLM13] to the three Bernoulli estimators of Θ, C0, and R0, with the respective mass bounds Θ=O(λN), C0⩽γ(∣T∣−1), and R0=O(λN) above, we can use O(λN2α−1+Nα−1/2) independent Bernoulli trials to produce independent unbiased estimates Θ, C0, and R0 whose centered moment generating functions satisfy
Eexp(θ(B−B))⩽exp(O(θ2α))for∣θ∣=O(1),
for each B∈{Θ,C0,R0} and B∈{Θ,C0,R0}. Every Bernoulli trial takes O(1) expected time. Set
A=∣T∣−Θ+C0+R0.
Then EA=A, and writing Δ=A−A, we have
EeθΔ⩽eO(θ2α),∣θ∣=O(1).
It remains to pass from A to Z=(A/A)∣T∣−1. From cp⩾ℓp/4, hp⩽ℓp, and ∣hp−hp∣⩽γℓp, we have 4∣T∣−1⩽A⩽(1+γ)(∣T∣−1). Set A=max{(∣T∣−1)/8,A}. Bernstein's lower-tail bound give
Pr[A<(∣T∣−1)/8]⩽O(α).
For j∈{1,2}, on the event A⩾(∣T∣−1)/8, the inequality logx⩽x−1 gives
(AA)j(∣T∣−1)⩽exp(Aj(∣T∣−1)Δ).
The coefficient j(∣T∣−1)/A is O(1), so the moment bound above applies. On the complementary event A<(∣T∣−1)/8, we have (A/A)j(∣T∣−1)⩽2−j(∣T∣−1). It follows that
E[Zj]⩽exp(O(α))+2−j(∣T∣−1)⋅O(α)⩽exp(O(α))
for j = 1, 2. On the other hand, A⩾A implies EA⩾A. Therefore EZ⩾1. Absorbing absolute constants into α, we therefore obtain
e−α⩽EZ⩽eα,(EZ)2E[Z2]⩽E[Z2]⩽eα.
Together with the trial complexity O(λN2α−1+Nα−1/2), this proves the lemma.
We put things together to prove Lemma 20.
Proof of Lemma 20. Apply Lemma 23 to obtain normalized path scores with Pearson error O(λN). Invoke Lemma 25 to sample from rp/ST, and independently invoke Lemma 26 to estimate the normalizer. Take t=O(N3/2α−1/2+λN2α−1) accepted paths and give them the determinant-sampling weights using A.
With the exact normalizer A, Lemma 18 applied to the path multigraph gives multiplicative bias eO(α) and relative second moment eO(α). Replacing A by the independent estimate A multiplies every tree weight by Z=(A/A)∣T∣−1. The two moment bounds in Lemma 26 therefore preserve the same bias and relative-second-moment guarantees.
Next we analyze the runtime. The ℓ1-rsistance preprocessing costs O(M+Nλ−3), the normalizer A estimation and the path sample costs O(λN2α−1+N3/2α−1/2). This finishes the proof.
Finally, following the strategy by [DPPR20], we can approximately count the spanning trees by the sparcification on Schur complement.
Proof of Theorem 1. We use the recursion of [DPPR20, Section 6], with our Lemma 20 in place of its Schur sparsifier. At a node v, let Lv be the current Laplacian, let Nv be its number of vertices, and put rv=Nv−1. Choose the constant-diagonally dominant set Fv from Lemma 19, set Tv=Vv∖Fv, and write Kv=Sc(Lv,Tv). One child is the random Laplacian Hv returned by Lemma 20; the other is obtained by completing Lv[Fv,Fv] to a Laplacian with one additional vertex. Kirchhoff's theorem and block elimination give
It is easy to see that the recursion depth is D=O(logn). We next verify the accumulation of the random error. Let δ0=ε2/D, and give a non-leaf node v the local moment budget αv=δ0rv/(n−1). By the variance analysis as in [DPPR20, Section 6] together with Lemma 20, the total variance produced by D level recursion is exp(Dδ0)=exp(ε2). So we ε-approximates T(G) with probability 2/3.
It remains to check that the local accuracy assignment preserves the claimed running time. On any frontier, Nv⩽2rv and ∑vNv=O(n). Substituting αv=δ0rv/r0 into Lemma 20 and summing over that frontier gives
There are O(logn) frontiers. Since δ0−1/2=O(ε−1) and δ0−1=O(ε−2), the total expected time is O(m+nλ−3+n3/2ε−1+λn2ε−2). This proves the Theorem by setting λ=n−1/4ε1/2.
REFERENCES
[ADVW +25] Josh Alman, Ran Duan, Virginia Vassilevska Williams, Yinzhan Xu, Zixuan Xu, and Renfei Zhou. More asymmetry yields faster matrix multiplication. In SODA, pages 2005–2039. SIAM, 2025. 1
[BLM13] Stéphane Boucheron, Gábor Lugosi, and Pascal Massart. Concentration Inequalities: A Nonasymptotic Theory of Independence. Oxford University Press, 2013. 16
[BP93] Robert Burton and Robin Pemantle. Local characteristics, entropy and limit theorems for spanning trees and domino tilings via transfer-impedances. The Annals of Probability, 21(3):1329–1371, 1993. 11
[BV04] Stephen Boyd and Lieven Vandenberghe. Convex Optimization. Cambridge University Press, Cambridge, 2004. 4
[CGP +18] Tengyu Chu, Yu Gao, Richard Peng, Sushant Sachdeva, Shanghua Sawlani, and Junxing Wang. Graph sparsification, spectral sketches, and faster resistance computation, via short cycle decompositions. In FOCS, pages 361–372, 2018. 1, 2, 12
[DPPR20] David Durfee, John Peebles, Richard Peng, and Anup B. Rao. Determinant-preserving sparsification of SDDM matrices with applications to counting and sampling spanning trees. SIAM Journal on Computing, 49(4), 2020. 1, 2, 3, 9, 10, 11, 12, 13, 15, 17
[Fos49] Ronald M. Foster. The average impedance of an electrical network. Contributions to Applied Mechanics (Reissner Anniversary Volume), pages 333–340, 1949. 3
[Kir47] Gustav Kirchhoff. Über die auflösung der gleichungen, auf welche man bei der untersuchung der linearen vertheilung galvanischer ströme geführt wird. Annalen der Physik und Chemie, 148(12):497–508, 1847. 1, 3
[KLP +16] Rasmus Kyng, Yin Tat Lee, Richard Peng, Sushant Sachdeva, and Daniel A. Spielman. Sparsified Cholesky and multigrid solvers for connection laplacians. In STOC, pages 842–850, 2016. 12
[KMP11] Ioannis Koutis, Gary L. Miller, and Richard Peng. A nearly-m log n time solver for SDD linear systems. In FOCS, pages 590–598, 2011. 4
[LPY25] Yang P. Liu, Richard Peng, and Junxing Yang. Approximate spanning tree counting from uncorrelated edge sets. arXiv preprint arXiv:2505.14666, 2025. 1, 2
[LS22] Li Li and Sushant Sachdeva. A new approach to estimating effective resistances and counting spanning trees in expander graphs. arXiv preprint arXiv:2211.01468, 2022. 1, 2, 12
[MRWP23] David Martínez-Rubio, Elias Wirth, and Sebastian Pokutta. Accelerated and sparse algorithms for approximate personalized pagerank and beyond. In The Thirty Sixth Annual Conference on Learning Theory, pages 2852–2876. PMLR, 2023. 2, 5
[SS11] Daniel A. Spielman and Nikhil Srivastava. Graph sparsification by effective resistances. SIAM Journal on Computing, 40(6):1913–1926, 2011. 2, 4
[ST04] Daniel A. Spielman and Shang-Hua Teng. Nearly-linear time algorithms for graph partitioning, graph sparsification, and solving linear systems. In STOC, pages 81–90, 2004. 4
[WY26] Zhe Wei and Ming Yang. A simple active-set method for PageRank-based local graph clustering. arXiv preprint arXiv:2608.16339, 2026. 2, 5