Manuscript Offprint
arXiv:2610.06796Approximating Random Walks in Space for -Conditioned Graphs
Approximating Random Walks in Space for -Conditioned Graphs
Junzhao Yang
Carnegie Mellon University
Abstract
For , a directed graph is -conditioned if it is -mixing and its stationary distribution is approximated by the uniform distribution within a factor of . We present a deterministic algorithm that approximates the stationary distribution of a -conditioned graph to inverse polynomial relative error in space. In the regime for any , our result improves the best-known space bound for approximating -step random walks in general directed graphs by [Hoza, RANDOM 2021].
We release this preliminary version due to recent rumors of LLM-based progress on related problems and uncertainty about when those results may appear. Further implementation details will be provided in a subsequent version.
We study stationary distributions and walk probabilities for -conditioned directed graphs as an intermediate problem towards proving .
Definition 1.1 ( -conditioned graph). A column-stochastic random walk matrix is -conditioned if it satisfies the following conditions:
• The stationary distribution satisfies for every .
• for all .
Our main result approximates the stationary distribution to relative error.
Theorem 1.1. For every fixed constant , there is a deterministic algorithm that, given , an integer , and adjacency-list access to an -vertex constant-degree out-regular directed graph whose walk matrix is -conditioned, outputs satisfying
using
bits of work space.
In particular, the space bound is when . Combining the stationary approximation with the Eulerian walk-estimation algorithm of Ahmadinejad et al. [AKM 20] gives the following consequence.
Corollary 1.2. For every fixed constant , there is a deterministic algorithm that, given a graph and parameters satisfying the assumptions of Theorem 1.1, vertices , and an integer , outputs satisfying
using bits of work space.
The main construction combines derandomized squaring with a trimming process. Error accumulates in the plain derandomized squaring, and it fails due to the blow-up of the in-degrees or row sums of the walk matrix power. Our trimming process rebalances the in-degrees and make the derandomized squaring work, but requires squared logarithmic space due to multiple rounds of trimming. We address this issue by defining a trimming step that performs trimming partially, and carefully coordinating the squaring and trimming steps in a synchronized manner, reducing the overall space complexity. Finally, a Reingold-style implementation uses a shared vertex register and short local indices and evaluates the recursion in small space.
1.1 Related work
General directed walks. Saks and Zhou [SZ99] gave a deterministic simulation of randomized space-bounded computation, yielding the classical space bound for estimating polynomial-length walk probabilities to inverse-polynomial additive error. Hoza [Hoz21] subsequently obtained the bound using weighted pseudorandom generators within the Saks–Zhou framework. These algorithms apply to general directed graphs, without assumptions on mixing or the stationary distribution.
For shorter walks, their dependence on the walk length is also relevant: the Saks–Zhou bound for steps and inverse-polynomial additive error is . For example, when for a fixed , this bound for -step walks is , whereas the bound in Theorem 1.1 is
Our theorem improves the bound of the general setting, but uses both a mixing assumption and a bound on the range of stationary probabilities.
Recycling state randomness. Raz and Reingold [RR99] derandomize branching programs by recycling the randomness in their states. Their unconditional result gives statistical error for width and length , using space, where for a constant , given -factor estimates of intermediate state probabilities.
In graph terms, the estimates approximate the probability of reaching each vertex at each time, including before the walk mixes. For a uniform starting distribution, the -conditioning assumption supplies -factor estimates using the uniform distribution. For -step walks with -factor estimates, their construction, combined with the space-efficient extractors of Raz, Reingold, and Vadhan and Hartman and Raz [RRV02, HR03], approximates walk probabilities to additive error in space
for an absolute constant . Our result achieves space for inverse-polynomial additive error, while requiring the additional mixing-time bound in the -conditioning assumption.
Known stationary distributions and Eulerian graphs. Chung, Reingold, and Vadhan [CRV11] solve directed connectivity in logarithmic space given a stationary distribution and polynomial mixing time from the source. For Eulerian graphs, whose stationary probabilities are determined by the degrees, Ahmadinejad et al. [AKM 20] estimate polynomial-length walk probabilities to inverse-polynomial additive error in space. Our result computes the stationary distribution under the -conditioned assumptions.
2 Preliminaries
2.1 Notations
Let be a vertex set of size . All logarithms are to base two unless a base is displayed. We assume an integer with . The vector denotes the all-ones vector in the relevant dimension, and denotes the indicator of a set . For nonnegative vectors, means coordinatewise comparison within a factor when , and within a factor when .
Let be the nonnegative column-stochastic transition matrix of a constant-degree out-regular directed graph on . Thus is the transition probability from to . Write for its positive stationary probability vector and . We recall the -conditioning assumptions from Definition 1.1:
• , equivalently for every .
• for all .
2.2 Norms and Approximation
We use and for the Euclidean and spectral norms, respectively. The vector norm is the sum of absolute coordinates and is their maximum. For matrices, and denote the maximum absolute column sum and row sum, respectively. For a positive definite matrix , define the weighted vector norm by
and the induced operator norm by
The stationary norm is obtained by taking . These stationary weights are used only in the analysis and are not supplied to the algorithm.
We also compare matrices using approximation with respect to error matrices from , together with a one-sided variant.
Definition 2.1. Let , let and be positive semidefinite error matrices, and let . We say that is an -approximation of with respect to , written wrt , if
We say that A is a one-sided -approximation of B with respect to , written wrt , if
The two-sided notion is equivalently characterized by
2.3 Label Space, Lifting and Compression
Derandomized squaring enlarges the state space by adding label coordinates. We introduce the averaging, lifting, and compression operators used to compare matrices on these spaces of different sizes.
For a finite nonempty set , define its uniform averaging matrix by . Write and . Tensor products of matrices are denoted by .
Let denote the number of levels. For positive integers to be specified by the construction, let and for . The corresponding state space at level is .
Definition 2.2 (Uniform lifting and compression). For , define the lifting matrix from to by
For a matrix A on and a matrix B on , define the uniform lift and compression by
The uniform lift satisfies
Since , compression inverts the uniform lift:
2.4 Expanders
We use undirected regular spectral expanders, allowing parallel edges and self-loops.
Definition 2.3 ( -spectral expander). An undirected regular multigraph H on D vertices is an -spectral expander if its random walk matrix satisfies
The following form of the small-bias construction of Alon, Goldreich, Håstad, and Peralta [AGHP92] gives an expander with power-of-two size and degree, together with a low-space neighbor operation. We use the following low-space construction for the expander graphs in our derandomized squaring procedure.
Lemma 2.4. For every power of two and every , there is an undirected d-regular -spectral expander on , where d is a power of two satisfying
The adjacency list of each vertex can be enumerated using bits of work space.
Proof. The standard Cayley-graph interpretation of Construction 3 and Proposition 3 in [AGHP92] gives the claimed degree and spectral bound. In that construction, each generator bit is computed by arithmetic over a binary field whose elements use bits. This arithmetic, including finding a defining irreducible polynomial by exhaustive search, uses space linear in that bit length. Together with the bits needed to store a vertex, this gives the claimed work-space bound.
3 One-Dimensional Chain
In this section, we define the one-dimensional matrix chain that characterizes the stable matrix chain in the two-dimensional case. This gives the approximation and trimming guarantees for the final stable matrices.
Starting from , each level consists of the following three steps:
(Definition 3.3)
(1)
(Definition 3.5)
(2)
Equation (1) defines the raw square by applying derandomized squaring (Definition 3.3) to the previous matrix , where is the level-t expander on the label space . Equation (2) defines the deletion matrix through the trimming process (Definition 3.5), with row budget and column budget . Equation (3) forms by removing this mass and returning each column's deleted mass to its diagonal entry, preserving column stochasticity. Under the assumptions and parameter choices in Section 3.4, Lemma 3.7 shows that the resulting chain satisfies the target stable matrix chain conditions in Definition 3.2.
3.1 Definitions and Invariants
At level t, derandomized squaring lifts the previous state space by adding the level-t label space . We first define the lifted state space and the ideal lifted walk matrix as follows.
Definition 3.1 (The lifted state space and the ideal lifted walk matrix). The lifted state space at level t > 0 is defined as
where denotes the singleton set and . The ideal lifted walk matrix at level is defined as
Let denote the stationary distribution of , i.e., a tensor product of with the uniform distribution. Let .
Definition 3.2 (The target stable matrix chain). A matrix chain is called the target stable matrix chain with parameters if is a nonnegative square column-stochastic matrix defined on and satisfies the following invariants:
• Full operator error:
• Bounded row-mass:
• One-sided error:
We will pick the parameters for the target stable matrix chain as follows:
where will be picked sufficiently small that
The full operator error is the final error bound required by the Richardson iteration. The one-sided error controls the trimming stage used to keep the in-degree mass bounded, which we use to address the following main difficulty: Even though has the same stationary distribution and satisfies , the -approximation does not control row sums. Derandomized squaring does not work if the row sums (i.e., in-degree mass) blow up too much. We therefore use trimming to bound .
3.2 Derandomized Squaring
In this section, we describe the derandomized squaring used to construct the target stable matrix chain Definition 3.2. This derandomized squaring operation is also used in the construction of the two-dimensional matrix chain.
Definition 3.3 (Derandomized squaring at level t). Let Q be a nonnegative column-stochastic matrix at level t-1, i.e., defined on . Let H denote an -spectral expander graph defined on level-t label space . The derandomized squaring of Q with expander H plugged in, denoted by
is defined as follows: Let be the random walk matrix of , and set . Fix an arbitrary nonnegative column-stochastic transition lift matrix on satisfying
and we obtain
This definition specifies the matrix operation. Its sparse low-space realization is discussed in Section 6. We define the derandomized square matrix chain by
for all t. Consequently, is nonnegative and column-stochastic and satisfies the following properties.
Lemma 3.4. Let , and suppose satisfies the level- invariants of Definition 3.2 with parameters . Assume and . Assume that its transition lift satisfies
for and the expander is an -spectral expander with . Then is nonnegative and column-stochastic, and satisfies the following bounds:
• Increased bounded row-mass:
• One-sided error:
• Full operator error:
Proof. Write , , , and . By , we have
Column stochasticity and the row-mass bound give . Replacing the three expander factors by one at a time, using and the fact that both factors have spectral norm one, gives
Translating -norm into the stationary norm loses at most a factor of , so
Also, by the property of the stationary distribution, and hence . Uniform lifting preserves stationary operator bounds and one-sided approximation: in stationary coordinates it tensors the matrices with , a nonnegative orthogonal projection. Moreover, .
• Row mass. All factors are nonnegative and column-stochastic, and . Applying the row-mass bound to the two occurrences of gives .
• One-sided error. For , expand and apply the input one-sided bound twice:
For nonnegative vectors on , uniform lifting preserves this one-sided bound. Thus, by Cauchy–Schwarz and Equation (5),
• Full operator error. The same expansion gives
Since and uniform lifting preserves the stationary operator norm, the triangle inequality and Equation (5) give
☐
3.3 Trimming for the One-Dimensional Chain
In this section, we define the trimming process for the one-dimensional chain. This process is used only in the analysis. In the two-dimensional chain, it is implemented through multiple trimming steps.
Definition 3.5 (Trimming process). Let be a nonnegative square column-stochastic matrix. The trimming of with row budget and column budget , denoted by
returns a deletion matrix Z satisfying
whenever such a matrix exists.
The deletion matrix records the mass removed by trimming. Returning this mass to the diagonal preserves column sums. The following lemma bounds the resulting row mass and approximation error.
Lemma 3.6. Let be a nonnegative column-stochastic matrix on with . Let and define
Then Q is nonnegative and column-stochastic, and satisfies:
• Bounded row-mass:
• One-sided error:
• Full operator error:
Proof. Write , so .
• Row mass. Since , the matrix Q is nonnegative. Diagonal compensation preserves every column sum, and
• One-sided error. For , nonnegativity of Z and Cauchy–Schwarz give
• Full operator error. The column budget and give
Converting to the stationary norm costs at most a factor of . Since is diagonal, its stationary operator norm is at most . Therefore,
3.4 Assembling the One-Dimensional Chain
We now combine the squaring and trimming bounds to establish the invariants of Definition 3.2. Here we assume that the required deletion matrices exist. Their existence and construction are addressed in Section 4.
Parameter choices. For , set
Suppose the transition lifts and expanders satisfy the row-mass and expander error conditions of Lemma 3.4 with a common . We use trimming threshold and choose and so that and, for every ,
For the choice used in Section 4, the square-root term is a fixed polynomial factor times . Thus we can satisfy these conditions by first choosing sufficiently large and then sufficiently small.
Lemma 3.7. The chain defined by Equations (1)–(3) with parameters defined as above is a target stable matrix chain (Definition 3.2) with parameters .
Proof. We prove the invariants by induction on . At level zero, and . This row bound follows from and the coordinate bounds on . For the induction step, apply Lemma 3.4 to and Lemma 3.6 to . The latter gives nonnegativity and column stochasticity of .
• Row mass. The budget conditions give , and hence
• One-sided error. Adding the two one-sided bounds gives
where .
• Full operator error. By the triangle inequality,
☐
4 The Trimming Step
Recall in Definition 3.5, we defined the trimming process that decomposes the derandomized square matrix P into
such that
This removes at most mass from each column and reduces the row sums to at most . The final construction uses a partial version of the trimming process, called the trimming step, that resolves most of the heavy rows instead of all heavy rows. This allows a simple construction which can be implemented in low space.
4.1 Existence of a Trimming
We first characterize the existence of the trimming solution using a bipartite flow problem. For a matrix P, a row subset I, and a column subset J, write
The following lemma gives an analogue of Hall's theorem for the trimming problem. We refer to this criterion as the Hall condition.
Lemma 4.1. Let P be a nonnegative matrix and . There exists a matrix Z satisfying
if and only if
for every row subset I and column subset J.
Proof. Necessity. For any row subset I and column subset J, the row and column budgets give
Sufficiency. Construct a flow network with a source, one vertex per row, one vertex per column, and a sink. Give the edge from the source to row capacity , the edge from row to column capacity , and the edges from each row and column to the sink capacities and , respectively. Write . A cut whose source side contains rows and columns has capacity
The max-flow/min-cut theorem therefore gives a flow of value , saturating every edge out of the source. Let be the flow from row to column . Edge capacities give . Flow conservation shows that the retained row mass flows directly to the sink and that each column's deleted mass flows through its sink edge. These masses are at most and , respectively.
The one-sided approximation bound implies the Hall condition as follows.
Lemma 4.2. Let P be a nonnegative matrix on satisfying
for some . Then, for all ,
Proof. Set , , and . The coordinate bounds on the lifted stationary distribution give
Also, since ,
Applying the one-sided bound yields
The last inequality follows by expanding .
4.2 A Single Trimming Step
We define a single trimming step and then bound the number of failed rows.
Definition 4.3 (A single trimming step). Let P be a nonnegative matrix, I a subset of its rows, and the row and column budgets. The trimming step
is defined as follows. First define the column ratio
with when the denominator is zero. We propose to delete mass from the -th entry for each . We accept the proposal for a row if the remaining row mass is at most , and set
The trimming step tries to delete mass from the rows in I while respecting the column budget , so it remains to bound the number of failed rows. The failure set is defined as
The following lemma gives the guarantees of a single trimming step.
Lemma 4.4 (Trimming step guarantees). Let Suppose and satisfy the Hall condition
.
If , then:
• Deletion and row budgets. We have , , and
• Failed rows.
Proof. Deletion and row budgets. Since , we have . For each column,
Every accepted row satisfies
Failed rows. Define the set of congested columns
Its size satisfies
Outside , we have . The definition of the failure set and the Hall condition give
Since , it follows that
☐
4.3 Parameters for the Trimming Step
For the raw square , Lemma 3.4 gives one-sided error and row-mass bound . Applying Lemma 4.2 gives Hall budgets
For our final algorithm, pick I to be the set of heavy rows and choose
By Lemma 4.4, the failure set satisfies
These bounds also apply to any nonnegative residual matrix bounded entrywise by . Since and , a sufficiently large constant in the per-step column budget
ensures this reduction by a factor of .
The total column budget is accounted for in Section 5.
5 The Two-Dimensional Chain
If we apply derandomized squaring and trimming alternately and complete each level before proceeding to the next, a level may require trimming steps. These costs accumulate over levels, increasing the recursion depth and the space required to evaluate the chain.
In this section, we define the 2D chain, which performs one trimming step per level in each synchronized round. Our goal is to bound the number of rounds until the chain stabilizes by . The parameter choices are given in Section 5.3. Starting from for every , the chain at each level and round is defined by
Equation (6) applies derandomized squaring (Definition 3.3) to the preceding level at the current round, where is the level-t expander. Equation (7) reuses deletion information from the previous round and applies a single trimming step to the remaining heavy rows, as specified in Definition 5.1. Equation (8) deletes unresolved heavy rows to bound the row mass, as specified in Definition 5.2. It restores each column sum to one by adding mass to its diagonal entry.
Section 5.1 defines the trimming and assemble steps. Section 5.2 bounds the number of rounds until stabilization. Section 5.3 collects the parameter choices and proves that the final chain satisfies the target invariants.
5.1 The Trimming and Assemble Steps
In this section, we define the trimming and assemble steps for the two-dimensional chain. We refer to as the raw matrix, as the deletion matrix, and as the trimmed matrix.
The trimming step uses the previous raw matrix and deletion matrix as reference. It keeps the deletion information if the raw row has not changed compared to the previous round.
Definition 5.1 (Two-dimensional trimming step). At level t, fix row budget and column budget . For round , define the filtered deletion matrix by
At round zero, set . Define the active set of heavy rows by
The two-dimensional trimming step returns
using the one-step routine from Definition 4.3.
The assemble step then deletes the unresolved heavy rows. It restores each column sum to one by adding mass to its diagonal entry.
Definition 5.2 (Assemble step). Given the raw matrix and deletion matrix , define
The assemble step returns
5.2 Analysis of the Synchronized Process
In this section, we give the core round analysis of the two-dimensional chain. We first define the following stabilization round.
Definition 5.3 (Stabilization round). The stabilization round is the smallest nonnegative integer such that, for every level and every ,
If no such round exists, set .
The assemble step gives up on the set of unresolved heavy rows, so it is important to let the chain stabilize to obtain the final approximation guarantee. We will show that when the two-dimensional chain stabilizes, the final stable matrix chain satisfies the properties of the target stable matrix chain in Definition 3.2.
Lemma 5.4 (Stabilization bound). The two-dimensional chain (defined by Eq (6)-Eq (8)) has the stabilization round
We prove Lemma 5.4 by bounding the number of unstable rows.
Definition 5.5 (Unstable rows). At a fixed level , a row of or is stable at round r if that row remains unchanged at every later round. The row is called unstable otherwise. Define
At level zero, set and for every round.
It suffices to find a round such that at every level. Then all raw and deletion matrices remain unchanged at every later round, so the assemble step also produces the same trimmed matrices. Therefore, .
We first prove that the chain stabilizes after finitely many rounds. This allows us to compare the intermediate matrices with the final stable matrices when deriving the sharper bound.
Lemma 5.6 (Conservative stabilization bound). With the parameter choices in Section 5.3,
Proof. We induct on the level, proving that all levels up to t stabilize within rounds with valid trimmings and the target invariants. First, a retained nonzero deletion row already has residual mass at most , so it is excluded from the active set. Retained and newly accepted deletion rows therefore have disjoint supports. Induction on rounds using Definitions 4.3 and 5.1 gives
The base case is for every round. Suppose the preceding levels have stabilized with the target invariants. The raw matrix at level is then fixed, and Lemmas 3.4 and 4.2 give its row-mass bound and Hall condition. With the stated parameter choices, Lemma 4.4 reduces the number of heavy rows by a factor of per round. Successful deletion rows remain valid because the raw matrix no longer changes. Starting with at most heavy rows, another rounds reduce their number below one. No heavy rows remain, so the deletion matrix and the assembled matrix also remain fixed thereafter.
This level finishes within rounds. The column bound above and the choice of the total budget give
at completion, and every residual row has mass at most . Thus the final deletion matrix is a valid trimming, and the assemble step has the one-dimensional form. The inductive argument in Lemma 3.7 gives the target invariants at this level, completing the induction. Since , we conclude that
To obtain the sharper bound, we establish the following recurrence for and :
The initial condition is
We bound by considering whether row i of is fully stable, as defined below. Row i of is fully stable if both of the following conditions hold:
-
Row i of is stable.
-
For every column j with and every row w, one of the following holds:
(a) , and row w of is stable.
(b) , and for every .
Case 1: Row i of is not fully stable. We prove the bound for this case by
The first inequality follows from the definition of fully stable rows and the fact that every row and every column in the 2D chain has at most nonzeros. The second inequality uses the locality of derandomized squaring and the bound on the degree of expanders. For the last inequality, each index in can affect its own row of and, through diagonal compensation, the rows indexed by columns touched by its row of at some future round . Thus the last inequality follows if each row touches at most distinct columns over these rounds.
Case 2: Row i of is fully stable. It remains to bound the indices for which row i of is fully stable, so row i of must be unstable. We bound this case using the one-step trimming guarantee. The challenge is that the guarantee does not apply to intermediate matrices, because the one-sided error invariant is available only for the final raw matrix .
Recall that is produced by the one-step trimming process
where denotes the active set used at level and round . For the same active set , a fully stable raw row has identical trimming proposals in the current and final raw matrices, since that row and every column it touches are unchanged. If its deletion row is unstable, it must be active and fail the current step, since an inactive or successfully trimmed row would remain unchanged. The proof of Lemma 5.6 supplies the row-mass bound and Hall condition for the final raw matrix. The Hall condition holds for every row subset, including the current active set. Applying the one-step trimming guarantee to with the same active set , we conclude that at most rows whose rows in are fully stable remain unresolved after this trimming step. Moreover, . Otherwise, an active row whose raw and deletion rows were already stable would remain heavy in the final matrix, contrary to the successful completion established by Lemma 5.6. Therefore,
Combining the two cases gives Equation (9). The guarantees of the final stable chain are collected in Section 5.3.
Proof of Lemma 5.4 from the recurrence. Choose to bound the coefficient in Equation (9) and satisfy for every level. Starting from and , induction on and then on gives
since the two terms of the recurrence contribute factors and , whose sum is at most one for . This bound is less than one at every level when
The counts are nonnegative integers, so all rows are stable by this round. Using , we obtain
5.3 Guarantees of the Final Stable Chain
We collect the parameter choices and prove that the final chain satisfies Definition 3.2. The conservative completion argument in Lemma 5.6 supplies the valid final trimmings needed for the one-dimensional chain analysis.
Parameter choices. Choose with , and use power-of-two label-space sizes , so that . Fix the transition lifts and expanders at each level, with the lift row-mass bound in Lemma 3.4 for a common . Set for and choose each level-t expander using Lemma 2.4, with error
As in Section 4.3, choose
Here is the per-step column budget at level t, fixed across rounds. Choose the total column budget
with a sufficiently large constant to cover all rounds in Lemma 5.6, including round zero. Choose and as in Section 3.4, so that
for every .
Lemma 5.7 (Final stable chain). With the parameter choices above, the final chain
is a target stable matrix chain with parameters in the sense of Definition 3.2.
Proof. The level-by-level argument in Lemma 5.6 shows that every level stabilizes with a valid deletion matrix satisfying
No unresolved heavy rows remain, so the assemble step gives
Together with the squaring relation, this is a one-dimensional chain with valid trimmings, and Lemma 3.7 gives the claim.
6 Low-Space Implementation
Let bound the length of a local label for one level. We aim to establish the following entry-query bound for a finite-precision implementation of the 2D chain: Given a level , a round , and two lifted vertex indices , the -th entry of , , or can be computed using workspace. In particular, a query at round uses space.
We aim for a Reingold-style implementation based on deterministic enumeration of labeled walks, maintaining the current vertex address as we follow each walk.
6.1 Uniform Weighted Implementation of Trimming
We replace weighted edges with parallel copies of equal mass, using a short copy index to distinguish copies of the same edge. Unequal transition weights are encoded by different numbers of copies. We round the weights using bits of precision. Each trimming step rounds the remaining weight of each edge downward and retains the corresponding number of copies. The copies accounting for deleted mass and the additional rounding loss are redirected to self-loops at the source, including the mass removed from unresolved rows in the assemble step. Thus every source has the same total number of outgoing copies, and the resulting transition matrix has column sums exactly one. The copies are represented implicitly, with their counts computed as needed rather than stored explicitly. Each parallel edge is identified by its original edge label and copy index, using bits in total, the same order as for derandomized squaring. The copy index is stored separately from the vertex address. The rounding-error analysis is deferred to the full proof.
6.2 Recursive Evaluation
We evaluate the 2D chain recursively by enumerating edge labels and, for parallel edges, their copy indices, recomputing multiplicities and trimming decisions as needed. The key is to share the full vertex address across recursive calls. A lifted vertex consists of an original vertex and the label coordinates introduced by derandomized squaring, requiring bits in total where we recall that is the number of levels. We use the following shared register:
- addr is a mutable register of bits holding the current lifted vertex address. All recursive calls share addr instead of storing a separate full address at each recursive depth.
We distinguish two types of recursive calls:
-
Query calls compute a value, such as a row sum or a trimming decision. They may modify addr temporarily, but restore it to its value on entry before returning.
-
Navigation calls use a short edge label, including a copy index for parallel edges, to move addr to a neighboring vertex and return a short reverse label. They leave addr at the destination, and the reverse label identifies the same edge copy and allows the caller to return to the original vertex.
A query can therefore navigate to a neighbor, make a recursive query there, and navigate back using the saved reverse label. For example, to compute the active-set column load , we start with addr at vertex j and enumerate its outgoing labels one at a time. For each label, we navigate to its target i, query whether , and return to j using the saved reverse label. We add the edge's weight to the load if the target is active. Thus, the recursive frame retains only a constant number of short labels, the loop position, and the partial sum used to compute the query result.
6.3 Space Accounting
We account for the target space bound in terms of the workspace required by the recursive operations. Squaring uses the preceding level , while retained trimming information comes from the preceding round . The required bound is that each recursive frame at level uses only bits in addition to the shared vertex address. Query calls restore this address before returning, and navigation calls return a short reverse label. The frame stores only a constant number of edge labels and copy indices, loop counters, and partial sums. The intended workspace bounds for the individual operations are as follows:
- Derandomized squaring. We use the standard derandomized squaring routine. Navigation composes a constant number of expander steps and navigation calls at the preceding level. We keep only the short labels needed for the reverse step.
• Trimming. We scan the incident edges one at a time, computing deletion amounts and copy counts as needed. The scan reuses storage between edges, so each recursive frame keeps only short labels, copy indices, and partial sums, using bits.
• Comparing rows between rounds. To check whether a row of differs from its row in , we scan incoming edges in both rounds and compare the total weight from each source. Since we cannot store the whole address in the frame, we compare them bit by bit so the frame keeps only short navigation labels, a bit position, and a comparison bit for these address comparisons.
• Arithmetic. On a common precision of bits, summing contributions requires only bits for the accumulator. Loop counters, copy indices, and acceptance times also fit in this bound.
The following lemma states the space bound under these workspace and recursion requirements.
Lemma 6.1 (Space accounting). Suppose an entry query at level t and round r has a recursive evaluation in which each recursive subquery decreases , with only a constant number of intervening helper frames. Assume that all calls share an -bit vertex address, each suspended frame uses additional bits, and leaf routines use workspace. Then the query uses
bits of work space.
Proof. Along any recursive call path, the sum of the level and round decreases at each recursive subquery. There are therefore active frames, using bits in total. The shared address and the workspace of the current leaf are counted once. Since and , the total space is
Under these assumptions, using Lemma 5.4, the resulting space bound is
7 Wrapping Up: Proofs of the Main Results
We apply Richardson iteration to approximate the stationary distribution, using the final target stable matrix chain to construct a preconditioner. The preconditioner makes the iteration contract toward the stationary vector. We then obtain the walk-probability guarantee by reducing to the Eulerian case.
7.1 Approximating Stationary Distribution by Richardson
Choose the number of levels so that and take small enough that, in addition to the preceding budget conditions,
Compress the final matrices to the original vertex set by defining
with . Uniform compression preserves column stochasticity and does not increase the operator error in the corresponding stationary norms. Thus Lemma 5.7 gives
Define the preconditioner and the iteration matrix by
The product is ordered by increasing level from left to right. The preconditioned Richardson iteration is
Using the original residual I - W keeps the true stationary vector fixed.
Lemma 7.1 (Richardson iteration). The matrix satisfies , , and . For every integer ,
Proof. The exact product is the short-walk sum
Normalize each product factor by two and telescope the difference of the ordered products. Since and , this gives
The mixing assumption and the stationary probability bounds imply
The same bound holds with replaced by , since multiplication by a power of is a contraction in the stationary norm. Using , we obtain
Consequently, for every vector x with ,
Since and , the iteration preserves total mass and fixes . The stationary vector is orthogonal to the zero-sum subspace in the stationary norm, so the contraction above also gives .
Finally,
Coordinatewise conversion and contraction give
Proof of Theorem 1.1. By Lemma 7.1, a power of two Richardson steps gives relative error at most . Evaluate each coordinate of to additive error , contributing at most another relative error.
Use balanced matrix multiplication for and for the product of normalized factors defining . Entries of are obtained from
The two recursions have total depth . Every exact normalized interval product has stationary norm at most two, and every power of has norm at most one. Thus each multiplication amplifies inherited norm error by only a constant factor, while scalar rounding contributes at most for rounding unit . Including the final scaling by , choosing therefore gives the required accuracy. Intermediate values and partial sums have polynomial magnitude. The two recursions consequently use workspace.
Under the entry-query requirements of Section 6, a compressed entry is computed by summing lifted entries and dividing by . The entry routine and the bits for compression counters and accumulators are needed only at the leaves, so their workspace is added once. The total space is
7.2 Approximating Random-Walk Probabilities
We balance the edge weights obtained from the approximate stationary vector and apply the Eulerian walk-estimation algorithm of Ahmadinejad et al. [AKM 20].
Proof of Corollary 1.2. Fix the walk length and requested error . Use Theorem 1.1 with sufficiently high accuracy to obtain a positive vector on a common binary grid satisfying
Define the imbalance vector and its positive and negative parts by
Since is column stochastic, . Write for this common sum and define the weighted adjacency matrix
where the second term is zero when . The correction makes the row sums and column sums coincide:
Thus F is Eulerian, with transition matrix
Nonnegativity of W and stationarity of give
Comparing the original and added mass in each column gives
Telescoping the powers of the two column-stochastic matrices now gives
The common binary grid for and the constant out-degree of give a common polynomial-size denominator for . Scaling by this denominator yields a polynomial-size Eulerian multigraph, whose adjacency lists are generated by recomputing stationary estimates with additional workspace. Apply the Eulerian walk-estimation algorithm of Ahmadinejad et al. [AKM 20] to estimate to additive error in space. The perturbation bound gives the remaining half of the error budget. The stationary routine’s workspace is added once for adjacency queries, so the total space remains
□
Acknowledgements
The author would like to thank Richard Peng for extensive discussions and valuable feedback on the draft.
LLM usage statement. On September 7, the author prompted GPT-6 Astra with the main theorem statement and initial proof ideas. These arose from the author's work on another project on dynamic algorithms. The model provided the key algorithmic ideas, including the trimming process and the synchronized analysis.
The author developed the manuscript based on his own interpretation of the resulting algorithm, with assistance from GPT Codex and Devin.AI in checking and reformatting. GPT Codex also assisted with drafting and revising portions of the exposition and proofs.
The author takes full responsibility for the results and their presentation.
References
[AGHP92] Noga Alon, Oded Goldreich, Johan Håstad, and René Peralta. Simple constructions of almost k-wise independent random variables. Random Structures & Algorithms, 3(3):289–304, 1992. 4, 5
[AKM 20] AmirMahdi Ahmadinejad, Jonathan Kelner, Jack Murtagh, John Peebles, Aaron Sidford, and Salil Vadhan. High-precision estimation of random walks in small space. In Proceedings of the 61st IEEE Annual Symposium on Foundations of Computer Science (FOCS), pages 1295–1306, 2020. 1, 2, 3, 23, 24
[APP 23] AmirMahdi Ahmadinejad, John Peebles, Edward Pyne, Aaron Sidford, and Salil Vadhan. Singular value approximation and sparsifying random walks on directed graphs. In Proceedings of the 64th IEEE Annual Symposium on Foundations of Computer Science (FOCS), pages 846–854, 2023. arXiv:2301.13541. 3
[CRV11] Kai-Min Chung, Omer Reingold, and Salil Vadhan. S-T connectivity on digraphs with a known stationary distribution. ACM Transactions on Algorithms, 7(3):30:1–30:21, 2011. 3
[Hoz21] William M. Hoza. Better pseudodistributions and derandomization for space-bounded computation. In Approximation, Randomization, and Combinatorial Optimization. Algorithms and Techniques (APPROX/RANDOM), volume 207 of LIPIcs, pages 28:1–28:23, 2021. 2
[HR03] Tzvika Hartman and Ran Raz. On the distribution of the number of roots of polynomials and explicit weak designs. Random Structures & Algorithms, 23(3):235–263, 2003. 3
[Rei08] Omer Reingold. Undirected connectivity in log-space. Journal of the ACM, 55(4):17:1–17:24, 2008. 1
[RR99] Ran Raz and Omer Reingold. On recycling the randomness of states in space bounded computation. In Proceedings of the 31st Annual ACM Symposium on Theory of Computing (STOC), pages 159–168, 1999. 2
[RRV02] Ran Raz, Omer Reingold, and Salil Vadhan. Extracting all the randomness and reducing the error in Trevisan's extractors. Journal of Computer and System Sciences, 65(1):97–128, 2002. 3
[SZ99] Michael Saks and Shiyu Zhou. . Journal of Computer and System Sciences, 58(2):376–403, 1999. 1, 2