Matching in Random-Order Streams via Historical Deletion Bounds
Alireza Farhadi, Mohammadtaghi Hajiaghayi, Mohammad Mahdavi
cs.DS
Nov 12, 2026 · v1
TL;DR
The approximation guarantees, the historical deletion inequality, and an exact rational LP certificate are formally verified in Lean, with a public repository.
Abstract
We study maximum matching when the edges of a fixed graph arrive in a uniformly random order. For any fixed $\varepsilon>0$, we give a one-pass algorithm that achieves, with high probability over the arrival order, approximation ratios of $0.71295$ for unweighted graphs and $0.71295-\varepsilon$ for weighted graphs, using near-linear space with an explicit charge for weight precision. Both approximation ratios hold for bipartite and general graphs. The algorithm does not require the stream length or the weight range in advance. The main structural ingredient is a historical deletion inequality for weighted matchings. The deletion price of a vertex set is the decrease in maximum matching weight when that set is removed. We bound the sum of these prices for pairwise disjoint vertex sets, even when each price is evaluated at a different stage as edges are added to the graph. Applied to the usual unfolding of integer weights, it transfers a bipartite cardinality certificate to an original weighted matching, even when the original graph is not bipartite. This transfer preserves the approximation coefficient. We combine this transfer with a refined analysis of fractional matchings in the two auxiliary graphs arising in the transfer theorem. An exact rational linear-programming certificate proves the stated constant for every feasible graph profile. The approximation guarantees and the new structural results are formally verified in Lean.
Problem
The problem is one-pass maximum matching when the edges of a fixed graph arrive in uniformly random order, using near-linear space. The best previous guarantees were 2/3+ε0 for unweighted graphs and 2/3-ε for weighted graphs.
Approach
The algorithm keeps a sparse shared graph in the integer-weight unfolding together with a bank of phase graphs that retain later edges with positive insertion gain. The key structural result is a historical deletion inequality: it bounds the sum of deletion prices of disjoint vertex sets, each evaluated at a different stage of graph growth, via a submodular marked-pair function. This inequality transfers bipartite cardinality certificates to weighted general graphs. The approximation constant comes from an exact rational LP certificate over graph profiles, checked in Lean using only the standard axioms.
Results
The algorithm achieves a 0.71295 approximation for unweighted graphs and 0.71295-ε for weighted graphs, for both bipartite and general graphs. It uses near-linear space and needs no advance knowledge of the stream length or weight range. The Lean sources and an independent rational checker are publicly available.
| Setting | Previous | This paper |
|---|
| Unweighted bipartite | 2/3+ε0 | 0.71295 |
| Unweighted general | 2/3+ε0 | 0.71295 |
| Weighted bipartite | 2/3-ε | 0.71295-ε |
| Weighted general | 2/3-ε | 0.71295-ε |
One-pass random-order matching guarantees