Convergence and the Spectral Gap
What convergence means, why it matters, and how the collective focus theorem guarantees that the cybergraph reaches a stable, unique, verifiable equilibrium.
What Convergence Means
The tri-kernel runs continuously over the cybergraph, computing a probability distribution over all particles. Convergence means this process settles: no matter where you start, you arrive at the same answer.
That answer is $\phi^*$ -- the collective focus distribution. It is the unique fixed point of the tri-kernel operator. It assigns every particle a number between 0 and 1, with all numbers summing to 1. $\phi^*$ encodes what the network collectively considers relevant.
Without convergence, different validators could compute different answers. Consensus would be impossible. Convergence is the mathematical property that makes the cybergraph a shared memory rather than a collection of disagreeing views.
The Spectral Gap
The spectral gap $\lambda$ is the single number that controls how fast the system reaches equilibrium:
$$\lambda = 1 - |\lambda_2|$$
where $\lambda_2$ is the second-largest eigenvalue of the transition matrix $P$.
$\lambda = 0$ means the system never mixes. $\lambda = 1$ means instant convergence. Everything in between is governed by exponential decay:
$$\|\phi^{(t)} - \phi^*\| \leq C \cdot (1-\lambda)^t$$
The spectral gap is the heartbeat of the cybergraph. It determines:
Finality Speed
Expected time to finality in foculus is $O(\log(1/\varepsilon)/\lambda)$ iterations. Larger gap means faster consensus. A graph that mixes quickly reaches agreement quickly.
Convergence Rate
The composite contraction coefficient $\kappa < 1$ depends directly on the spectral gap of each tri-kernel operator. The gap of the composite is a blend of the gaps of diffusion, springs, and heat.
Learning Incentives
Spectral gap improvement $\lambda_2^t - \lambda_2^{t+1}$ is a candidate reward function. Linking that tightens the gap accelerates the entire system -- a structural contribution that benefits everyone.
Emergence Thresholds
Phase transitions in collective intelligence depend on $\lambda$ crossing critical values. Sparse graphs have small gaps (slow mixing). Dense, well-connected cybergraphs have large gaps (fast convergence).
Bootstrapping
A cold network has few cyberlinks and small spectral gap. Finality may be slow until the cybergraph reaches sufficient density. The early phase of network growth is the period of slowest convergence.
Partition Recovery
When two halves reconnect after a partition, $\lambda$ determines how quickly $\phi^*$ reconverges. The spectral gap bounds how long "disagreement" persists after reconnection.
What Makes the Gap Large
High connectivity -- more edges means more paths for probability to flow, faster mixing.
Small diameter -- short distances between any two particles.
Low degree variance -- balanced graphs mix faster than hub-dominated ones.
Teleport -- the damping factor $\alpha$ in diffusion guarantees a minimum gap of $(1-\alpha)$, even for poorly connected graphs. This is the safety net.
What Shrinks the Gap
Bottlenecks -- a narrow cut between two dense clusters forces probability through a chokepoint.
Partitions -- disconnected components have $\lambda = 0$.
Star topology -- a single hub creates slow mixing (all paths go through one node).
Cold start -- few cyberlinks means sparse graph means tiny gap.
The Collective Focus Theorem
The collective focus theorem establishes convergence in two parts.
Part I -- Diffusion Alone
Consider a cybergraph where every edge has positive weight and every particle has positive token value. Define transition probabilities proportional to edge weight times token value. If the graph is strongly connected and aperiodic, then by the Perron-Frobenius theorem, a unique stationary distribution $\phi^*$ exists. Any initialization converges to it.
This is the special case: diffusion only, no springs, no heat. The proof is classical -- it follows directly from the theory of ergodic Markov chains. The stationary distribution $\phi^*$ is the simplest Schelling point the network can agree on: the stable consensus of observation probabilities.
Small perturbations to edge weights or token values do not destabilize the equilibrium. Clusters of strongly connected particles naturally emerge as modules.
Part II -- The Full Tri-Kernel
Part I covers diffusion alone. Part II extends to the full composite.
The tri-kernel blends three operators: $\mathcal{R} = \lambda_d D + \lambda_s S + \lambda_h H_\tau$, with $\lambda_d + \lambda_s + \lambda_h = 1$. Each operator contracts:
- Diffusion contracts with coefficient $\alpha$ (the teleport parameter)
- Springs contract with coefficient $\|L\|/(\|L\|+\mu)$ (the screening ratio)
- Heat contracts with coefficient $e^{-\tau\lambda_2}$ (exponential damping by the Fiedler eigenvalue)
The composite contraction coefficient:
$$\kappa = \lambda_d \alpha + \lambda_s \frac{\|L\|}{\|L\|+\mu} + \lambda_h e^{-\tau\lambda_2} < 1$$
Each term is less than 1, and $\kappa$ is their convex combination. By Banach's fixed-point theorem, iteration converges to a unique fixed point $\phi^*$ at linear rate.
The fixed point $\phi^*$ minimizes a free energy functional with three terms: elastic structure (springs), heat-smoothed context (heat kernel), and diffusion alignment (KL divergence). When $\lambda_s = \lambda_h = 0$, the general case reduces to Part I.
Locality -- Why Local Changes Have Bounded Effects
One of the most important consequences of convergence is locality: a change to the graph affects only a bounded neighborhood.
For an edit batch $e_\Delta$ (a set of new cyberlinks), there exists $h = O(\log(1/\varepsilon))$ such that recomputing $\phi$ only on the $h$-hop neighborhood of the edit achieves global error $\leq \varepsilon$. Nodes outside this neighborhood change by at most $\varepsilon$.
This locality comes from three independent decay mechanisms:
- Diffusion: the teleport parameter $\alpha$ ensures geometric decay -- after $h$ hops, the probability of a random walk still being influenced by the edit decreases exponentially
- Springs: the screening parameter $\mu$ creates exponential decay in the Green's function -- structural influence falls off exponentially with graph distance
- Heat: the kernel $H_\tau = \exp(-\tau L)$ has Gaussian tail decay -- heat dissipates rapidly beyond a scale determined by $\tau$
All three operators localize. A new cyberlink in one corner of the graph does not require recomputing $\phi^*$ for the entire graph. Only the local neighborhood needs updating. This is what makes planetary-scale computation feasible: $10^{15}$ particles, but any single edit touches only $O(\log(1/\varepsilon))$ hops.
Mixing Time
The mixing time -- how many iterations until the system is within $\varepsilon$ of equilibrium -- is:
$$t_{\text{mix}}(\varepsilon) = O\left(\frac{\log(n/\varepsilon)}{\lambda}\right)$$
where $n$ is the number of particles and $\lambda$ is the spectral gap. This gives concrete performance guarantees: given the current spectral gap, you can compute exactly how many iterations consensus requires.
The spectral gap is the entropy production rate bound: $dH/dt \leq -\lambda \cdot H$. Entropy decreases at least as fast as the gap dictates.
Two Gaps, One Symbol
$\lambda_2$ names two different numbers on this page and in the code, and they are not interchangeable.
- The Fiedler value: the smallest nonzero eigenvalue of the weighted Laplacian $L = D - A_{\text{sym}}$. This is the $\lambda_2$ inside the composite $\kappa$ -- the heat term contracts at $e^{-\tau\lambda_2}$. focusing computes it by power iteration on $\lambda_{\max} I - L$ over $\mathbf{1}^\perp$ (
rs/focusing/spectral.rs). - The diffusion gap: $1 - |\mu_2|$, where $\mu_2$ is the second eigenvalue of the normalized adjacency $D^{-1/2}A_{\text{sym}}D^{-1/2}$ -- equivalently of the transition matrix. This is the gap of the sections above, the one that sets PageRank's contraction $\kappa = \alpha(1-\lambda_2)$ and the layer count $L^*$ of ct0. Pass 3 computes it by deflated power iteration (
rs/pass/arch.rs).
Both are computed before the iteration runs. That order is a design invariant, not an implementation detail: the step count $T(\varepsilon) = \lceil \log(1/\varepsilon)/\log(1/\kappa) \rceil$ is fixed from $\kappa$ in advance (arithmetic), which is what makes $\phi^*$ bit-identical on every machine and the zheng trace a constant length.
Observing the Gap
The gap also shows up on its own, for free, wherever the iteration runs. Every converging system has a convergence rate, and that rate is the gap.
PageRank always converges (Perron-Frobenius theorem), at the rate
$$\|\phi^{(t)} - \phi^*\|_1 \leq C \cdot \kappa^t, \qquad \kappa = \alpha(1-\lambda_2).$$
Track the $\ell_1$ distance between successive iterates, $d_t = \|\phi^{(t)} - \phi^{(t-1)}\|_1$. Past the initial transient the ratio of successive differences converges to the contraction:
$$r_t = \frac{d_t}{d_{t-1}} \to \kappa.$$
Take the median of the last few ratios -- robust to early noise, and to the oscillation a complex $\mu_2$ produces on a directed graph -- then invert:
$$\hat\kappa = \operatorname{median}(r_{T-4}, \ldots, r_T), \qquad \hat\lambda_2 = 1 - \frac{\hat\kappa}{\alpha}.$$
The marginal cost is zero. The loop already computes $d_t$ for its convergence check -- rs/pass/arch.rs computes exactly this drift every PageRank step -- and keeping five ratios is $O(1)$.
What the observation is for, given the invariant above:
- verification -- an independent check on the a-priori $\lambda_2$, from behavior rather than from the matrix. Shift-invert Lanczos on a Laplacian with one zero eigenvalue per component can fail outright at scale; the observed ratio cannot, because the iteration it reads is the one that runs anyway. On bostrom it caught a two-orders-of-magnitude error in a sampled estimate: eval/spectral-gap-bostrom.md.
- telemetry -- the spectral gap estimate tri-kernel §6.3 asks focusing to emit each epoch, and a live vital sign of the network: foculus validators can watch $\hat\kappa$ per block, and a densification policy that targets $\lambda_2$ can read its own effect without an eigensolver.
What it is not: a way to skip computing $\kappa$ up front. The observed value arrives after the run and depends on the data; $T(\varepsilon)$ must be known before it. The eigensolver sets the contract; the observation audits it.
The Complete Picture
The eigenvalues of the transition matrix satisfy $1 = \lambda_1 \geq |\lambda_2| \geq \ldots \geq |\lambda_n|$. The gap $\lambda = 1 - |\lambda_2|$ controls everything:
- Convergence rate: $(1-\lambda)^t$ per iteration
- Mixing time: $O(\lambda^{-1} \log(n/\varepsilon))$
- Locality radius: $O(\log(1/\varepsilon))$ hops
- Finality speed: proportional to $\lambda^{-1}$
The tri-kernel's composite gap blends contributions from all three operators. Each operator's gap is determined by its own parameter: $\alpha$ for diffusion, $\mu$ for springs, $\tau \lambda_2$ for heat. The composite gap $\kappa$ is a weighted average.
$\phi^*$ is a mathematical consequence of three properties: ergodicity (diffusion), screening (springs), bounded temperature (heat). Convergence follows from Banach's fixed-point theorem -- it is proven, not postulated. No selection principle is needed to pick the "right" state: the contraction mapping leaves exactly one.
See tri-kernel for the formal specification. See collective focus theorem for the full proofs. See foculus for consensus timing. See spectral gap for the mathematical details.
Related concepts: convergence, equilibrium, Laplacian, Perron-Frobenius theorem, entropy.
Literature:
- Fiedler (1973): algebraic connectivity $\lambda_2(L)$ as graph connectivity measure
- Levin, Peres & Wilmer (2009): Markov chains and mixing times
- Spielman: spectral graph theory lecture notes
- Chung (2007): heat kernel as PageRank -- spectral gap connects diffusion and heat