The fingerprint method — replace big objects by tiny random projections: Freivalds, Schwartz–Zippel, Karp–Rabin; then universal and perfect hashing, Tutte matrices and the Isolation Lemma.
Course 2-INF-135/15 Pravdepodobnostné algoritmy, LS 2025/26.
Source slides: 04_metody23.pdf, slides 5–34. Continues the methods block;
part 1 (§1–§4) was eliminating the adversary. This part is the second method —
fingerprints (odtlačky) — and its biggest customers, hashing and matching.
Where we are
Part 1 was the first design method: randomize your strategy so the adversary has no
fixed target. This part is the second method: fingerprints. The slogan is one line:
Don’t compare the giant objects — compare tiny random summaries of them.
We will see the same trick wear five different costumes (matrix products, polynomials,
branching programs, text search, graph isomorphism), then watch it grow into the theory
of universal hashing, and finally into the Isolation Lemma, which turns “does a
matching exist?” into a determinant and makes the matching unique so parallel machines
can agree on it.
5. The fingerprint method (metóda odtlačkov)
We want to decide equality / equivalence of two complex objectsO1,O2 — objects
so big that comparing them directly is expensive (matrices, polynomials in normal form,
long strings, function tables). The idea:
Take a familyM of maps from the full representation down to a small partial
one. Pick one at random, h∈RM, and compare the fingerprintsh(O1)=?h(O2).
If h(O1)=h(O2): report “(probably) equivalent.”
If h(O1)=h(O2): report “definitely not equivalent.”
Three requirements make this an algorithm rather than a wish:
h is efficiently computable;
the comparison h(O1)=?h(O2) is efficient (fingerprints are small);
soundness in one direction:
O1=O2⇒h(O1)=h(O2)(always),O1=O2⇒h(O1)=h(O2)for *enough* h∈M.
The error is one-sided. Different objects always differ; equal objects never
differ. The only mistake is a false positive — two different objects that happen
to collide on this particular random h. Requirement 3 guarantees only a small
fraction of h’s collide, so the failure probability is small. This is exactly a
co-RP / Monte-Carlo flavour: an “unequal” verdict is gospel, an “equal” verdict
is probably true, and we amplify by repeating with fresh h. (Ties back to Lecture 3’s
one-sided error classes.)
The whole rest of this section is: pick the right family M for the objects at hand.
6. Freivalds — verifying a matrix product in O(n2)
The problem. Someone claims A⋅B=C for n×n matrices. Checking by
recomputing AB costs O(n3) naively (or O(n2.37) with fast multiplication —
complicated and constant-heavy). Can we verify a claimed product faster than computing
one? Yes — in O(n2), the cost of barely touching the matrices.
The fingerprint. Project everything through a random 0/1 vector
α∈R{0,1}n:
checkA(Bα)=?Cα.
Computed right-to-left: Bα is a matrix–vector product (O(n2)), then
A(Bα) another (O(n2)), and Cα another. Total O(n2) — never form AB.
Correctness. The fingerprint of a matrix X is the vector Xα.
If AB=C then A(Bα)=(AB)α=Cαalways (requirement 3, the safe side).
If AB=C, let D=AB−C=0. We need Pr[Dα=0]≤21.
The one-line heart.D=0 has some nonzero entry dij. Look at row i:
(Dα)i=∑kdikαk=dijαj+(terms not involving αj).
Reveal every coordinate of αexceptαj first (principle of deferred
decisions). Now (Dα)i=0 forces αj to one specific value. But αj
is a fair coin over {0,1}, so it hits that value with probability ≤21.
Hence Pr[(Dα)i=0]≤21, so Pr[Dα=0]≤21.
Pr[A(Bα)=Cα∣AB=C]≤21.
Repeat with t independent α’s to drive the error to 2−t.
Punchline. Verifying a product is strictly easier than computing it — and the proof
never needed anything about A,B,C beyond “D=0 has a nonzero entry.” A random
linear projection cannot kill a nonzero matrix more than half the time. (Exam-critical:
the “matrix match” fingerprint, exam-1 Q1 / exam-3 Q1.)
7. Polynomial identity testing & the Schwartz–Zippel lemma
Freivalds is the matrix face of a much bigger idea: two objects are equal iff a certain
polynomial is identically zero, and a nonzero polynomial is rarely zero at a random point.
Univariate warm-up
To test p1(x)=?p2(x): form q=p1−p2. If p1=p2 then q≡0
has degree ≤n, so at most n roots. Pick α∈RS for a large set S⊆F:
Pr[q(α)=0∣p1=p2]≤∣S∣n.
Deterministically you’d expand to normal form — possibly exponential time. Randomly
you just evaluate at one point. This single idea powers perfect matching (§14),
read-once branching programs (§8), and pattern matching (§9).
Schwartz–Zippel (the multivariate engine)
Lemma (Schwartz–Zippel). Let Q(x1,…,xn)∈F[x1,…,xn] have total
degreed, let S⊆F, and pick α1,…,αn∈RS independently.
Then
Pr[Q(α1,…,αn)=0∣Q≡0]≤∣S∣d.
The univariate fact (“degree d⇒≤d roots”) is the n=1 case; this lifts
it to many variables at the same rate d/∣S∣.
Proof — induction on the number of variables n.
Base n=1: a nonzero univariate polynomial of degree ≤d has ≤d roots, so
Pr≤d/∣S∣.
Step n>1: let k≤d be the highest power of x1 appearing in Q, and peel
x1 out:
Q(x1,…,xn)=i=0∑kx1iQi(x2,…,xn),
where the leading coefficient Qk≡0 is a polynomial in x2,…,xn of
total degree ≤d−k. Now Q(α)=0 splits into two cases over the tail
variables α′=(α2,…,αn):
(a) Qk(α′)=0. By the induction hypothesis on the (n−1)-variable,
degree-(d−k) polynomial Qk:
Pr[Qk(α′)=0]≤∣S∣d−k.
(b) Qk(α′)=0. Then q(x1):=Q(x1,α′) is a genuine univariate
polynomial of degree exactly k (its top coefficient Qk(α′)=0), so
Pr[q(α1)=0∣Qk(α′)=0]≤∣S∣k.
Glue with Pr[A]≤Pr[B]+Pr[A∣B] (here B = “case (a)”):
Pr[Q(α)=0]≤∣S∣d−k+∣S∣k=∣S∣d.■
The deep point. Peeling off the highest-degree variable lets the induction split the
degree budgetd=(d−k)+k exactly between “the leading coefficient vanishes” and
“the leading coefficient survives but the univariate slice vanishes.” Neither case can be
bad more than its share, and they add up to the full degree. That clean additivity is why
the bound stays d/∣S∣ no matter how many variables.
Variant: counting roots over Zp
A sibling lemma counts roots directly. If Q(x1,…,xn) over Zp has
per-variable degree ≤d, then it has at most ndpn−1 roots — so a uniform
random point in Zpn is a root with probability ≤nd/p. (Same induction:
either all the Qi vanish — (n−1)dpn−1 roots by induction — or some Qj=0
and the univariate slice contributes ≤kpn−1; together ≤ndpn−1.)
8. Read-once branching programs (1BP equivalence)
A beautiful application: deciding whether two branching programs compute the same
Boolean function, with no known efficient deterministic algorithm — but an easy
fingerprint one.
1BP (read-once branching program): an acyclic graph; each internal vertex is labelled
by a variable; each has two out-edges labelled 0 and 1. To evaluate on input
α∈{0,1}n, start at the root and at each vertex follow the edge labelled by the
tested variable’s value. Read-once = every variable is tested at most once on any
path. A 1-path runs from the root to the “1”-leaf; P(BP) is the set of
1-paths. The program represents f if P(BP) is exactly the set of α with
f(α)=1.
Equivalence is a polynomial identity. Turn each 1-path y=x1v1x2v2⋯
into a monomial that is 1 exactly on that path’s inputs:
On any Boolean input α, exactly one path’s monomial is 1 (the path the input
follows) and the rest are 0, so QBP(α)=f(α) on the whole cube.
Because each QBP is multilinear, it is determined by its values on
{0,1}n. Hence
BP1≡BP2⟺f1=f2 on {0,1}n⟺QBP1=QBP2 as polynomials.
Now test QBP1−QBP2≡?0 with Schwartz–Zippel:
evaluate both at a random point over a large field S (going beyond{0,1} to get a
real probability gap). Example monomial sum:
Q(x1,x2,x3)=(1−x1)x2x3+(1−x1)(1−x2)(1−x3)+x1x2.
Why this is striking. We never expand the function table (2n entries). We compare
two programs by one random evaluation of their arithmetizations. The same “Boolean
function → multilinear polynomial” move (“arithmetization”) is the seed of the whole
IP=PSPACE story.
9. Pattern matching — Karp–Rabin fingerprints
The problem. Text X=x1…xn, pattern Y=y1…ym (bits). Find an
occurrence: a position j with X(j):=xjxj+1…xj+m−1=Y.
The fingerprint = remainder modulo a random prime. Read each m-bit window as a number.
Pick a random prime p∈R{primes≤τ} (with τ a function of m,n to
be tuned), and compare remainders:
Op(X(j)):=X(j)modp,Op(Y):=Ymodp,report j if Op(X(j))=Op(Y).
Why it’s fast — the rolling hash.Op(Y) is computed once. Each window fingerprint is
obtained from the previous one in O(1) arithmetic operations (O(logp) bit-ops): drop
the top bit, shift, add the new bit, all mod p:
Op(X(k))=(2⋅Op(X(k−1))−xk−12m+xk+m−1)modp.
Total time O(n+m) instead of O(nm) for naive matching.
Error analysis. A false match at j means p∣∣X(j)−Y∣, where ∣X(j)−Y∣ is an
m-bit number, hence <2m, hence has fewer than m prime divisors. The number of
primes ≤τ is ≈τ/lnτ (prime number theorem). So per position
Pr[false match]≤τ/lnτm, and summing over the ≤n positions:
MC: on each fingerprint match, verify by direct character comparison — total extra
O(n+m), error ≤2/n.
LV: verify every reported match; on a false match, restart with a fresh prime.
Expected work stays O(n+m) and Pr[more than k restarts]≤1/nk.
Punchline. A whole m-bit window is crushed to a number mod a small prime, and the
rolling update means the fingerprint of the next window is one cheap step from the
current — turning O(nm) into O(n+m). The error is one-sided and verifiable, so the
Monte-Carlo algorithm upgrades to Las-Vegas for free.
10. Fingerprints across a conversation — interactive proofs
The fingerprint idea generalizes from “one random check” to a dialogue. An
interactive protocol is a pair (P,V):
Prover P (dôkaz / student)
Verifier V (verifikácia / teacher)
power
unbounded computation
polynomial-time, randomized
sees
the public messages
its own random bits (P does not)
They exchange messages; the verifier has the last word. We want:
x∈L⇒∃P:V(P,x)=1(a true claim has a convincing prover — *completeness*),x∈/L⇒∀P:Pr[V(P,x)=1]≤21(a false claim survives only by luck — *soundness*).
IP is the class of languages with such a protocol.
For non-isomorphism we have no short certificate — how do you exhibit a proof that
no permutation works? Interaction + randomness gives one:
Protocol (verifier V moves first):
V secretly flips i∈R{1,2} and picks a random permutation τ.
V computes H=τ(Gi) and sends H to P.
P answers with j∈{1,2} — its guess for which graph H came from.
V accepts “G1,G2 non-isomorphic” iff i=j.
Theorem. If G1,G2 are non-isomorphic, an honest P convinces V with certainty.
If they are isomorphic, any (even cheating) P convinces V with probability
≤21.
Why it works — the intuition.
Non-isomorphic:H is isomorphic to exactly one of G1,G2. The all-powerful P
can simply test which, so j=ialways⇒V accepts.
Isomorphic: now H is isomorphic to both, and a random relabelling τ of G1
has exactly the same distribution as a random relabelling of G2. So H leaks
zero information about the secret i — P can only guess, Pr[i=j]≤21.
The deep point. Randomness lets the verifier pose a question whose answer P knows
iff the claim is true: “tell apart two graphs” is possible only when they really are
different. The verifier’s hidden coin is the fingerprint P cannot fake. This is the
entry point to IP=PSPACE — interaction + randomness buys “proofs”
that ordinary coNP certificates seem unable to give.
11. Hashing I — linear probing and balls-in-boxes
Fingerprints meet data structures: a hash function is a fingerprint we store things by.
Before the theory, two concrete analyses.
Linear probing in space n=3m has O(1) expected FIND
Store m keys in a table T of size n=3m (load factor 31). On a collision at
slot h(x), probe h(x)+1,h(x)+2,… until a free slot. Claim: expected probe length
is O(1).
Proof gadget — a binary tree over the table. Build a complete binary tree whose leaves
are the table slots. A vertex v at height k covers 2k consecutive slots. Say a key
xhashes into v if h(x) lands in v’s subtree. The expected number of keys hashing
into v is
μ=nm⋅2k=32k.
Call vdangerous if at least 2μ keys hash into it. By Chernoff
(Pr[X≥(1+δ)μ]≤(eδ/(1+δ)1+δ)μ with δ=1):
Pr[#keys≥2μ]≤(4e)μ.
Since e/4<1, dangerous vertices are exponentially unlikely in their height. A long
run (cluster) B of length b∈{2ℓ,…,2ℓ+1} forces at least one of
∼3 subtrees of height ℓ−2 covering it to be dangerous, so
The combinatorial core (“a long run needs a dangerous subtree”) is a capacity / pigeonhole
argument: if all three covering subtrees of height ℓ−2 were safe (each holding
<2μ keys), they could not supply enough keys to fill a contiguous run that long — there
would be a hole (empty slot) inside it, contradicting that it is one unbroken run.
Deep point. The slack load factor 31 is doing the work: at every height the
expected fill is a third of capacity, so being double the mean (dangerous) is a large
deviation, and Chernoff makes it vanish fast enough that the expected cluster length —
hence expected FIND — is a constant independent of m.
Balls in boxes (guličky a krabice)
Throw m balls uniformly into n boxes. Three staples:
Load:X = balls in a fixed box, E[X]=m/n.
Empty boxes:Zi=1 iff box i is empty; E[Zi]=(1−n1)m≈e−m/n,
so E[Z]=ne−m/n. For m=n: E[Z]≈n/e (about a third of the boxes stay
empty even with as many balls as boxes).
First collision (birthday): with k balls,
Pr[no collision]=i=1∏k−1(1−ni)≤i=1∏k−1e−i/n=e−k(k−1)/(2n).
This drops below 21 once k(k−1)/(2n)≥ln2, i.e. k∼n.
The n threshold (birthday paradox) is the single most-reused fact in hashing:
collisions become likely at k≈n items, which is exactly why a table that
wants no collisions among m keys needs ∼m2 slots (§13).
12. Universal hash families
Setup. Universe U={0,…,m−1}, table T={0,…,n−1}, hash h:U→T.
For any single fixedh there is a bad input (some set of keys that all collide). The
adversary wins against any fixed function. Solution — randomize the function: keep a
familyH={h} and pick h∈RH. This is “eliminate the adversary” (part 1)
applied to the hash function itself — and it yields a good deterministic structure for a
static dictionary (fix the lucky h once).
Definitions
For m≥n and a family H of functions U→T:
Property
Condition (for all distinctx1,…,xk; h∈RH)
universal
Pr[h(x)=h(y)]≤n1 for x=y
k-universal
Pr[h(x1)=⋯=h(xk)]≤nk−11
strongly k-universal (k-independent)
∀y1,…,yk:Pr[h(x1)=y1,…,h(xk)=yk]=nk1
Universal = “collisions no more likely than for a truly random function.” Strongly
k-universal = “on any k inputs the outputs look fully independent and uniform.”
Counting collisions with a 2-universal family
Let S={x1,…,xm}, Xij=1 iff h(xi)=h(xj), and X=∑i<jXij
the number of colliding pairs:
E[X]=i<j∑Pr[h(xi)=h(xj)]≤(2m)n1≤2nm2.
A box holding Y keys creates (2Y)≈Y2/2 collisions, so by MarkovPr[X≥m2/n]≤21, giving Pr[Y≥m2/n]≤21; for m=n,
Pr[max load≥2n]≤21. Good enough for one level — but the
max bin is still ∼n, which §13 fixes.
Lemma.H is 2-universal: Pr[ha,b(x1)=ha,b(x2)]≤n1 for x1=x2.
Proof. First, x1=x2⇒ax1+b≡ax2+b(modp) (since
a=0). For fixed x1=x2, the map $(a,b) \mapsto (u, v) = (a x_1 + b,\ a x_2 + b)
\bmod p$ is a bijection onto pairs (u,v) with u=v (solve the 2×2 system —
x1=x2 makes it invertible). A collision means u≡v(modn) with u=v.
For each u there are at most ⌈p/n⌉−1≤(p−1)/n values v=u with
v≡u(modn). So the number of colliding pairs is ≤p⋅np−1, and
Pr[collision]≤p(p−1)p(p−1)/n=n1.■
Strongly 2-universal families
Scalar version.U=T={0,…,p−1}, p prime, ha,b(x)=(ax+b)modp,
H={ha,b:0≤a,b≤p−1}, ∣H∣=p2.
Lemma.Pr[h(x1)=y1,h(x2)=y2]=1/p2 for distinct x1,x2.
Because the linear system ax1+b=y1,ax2+b=y2(modp) has a unique solution
(a,b) (Vandermonde, x1=x2). So exactly one of the p2 functions sends
x1↦y1,x2↦y2 — probability 1/p2.
Vector version.U={0,…,pk−1}, T={0,…,p−1}, identify
u↔(u0,…,uk−1)∈{0,…,p−1}k, and
ha,b(u)=(i=0∑k−1aiui+b)modp.
If u1=u2 they differ in some coordinate i; fixing the other aj, the two equations
aiu1,i+b=…,aiu2,i+b=… pin down (ai,b) uniquely among p2
choices, giving Pr[h(u1)=y1∧h(u2)=y2]=1/p2. Still strongly 2-universal.
Why “strongly” matters. Universal controls collisions; strongly 2-universal controls
the actual output distribution on any two points — and that is what limited-independence
derandomization needs (Lecture 2’s pairwise independence is exactly strong 2-universality).
13. Perfect hashing — O(1) worst-case lookups
A static dictionary S (∣S∣=m) wants O(1)worst-case FIND, not just expected.
With 2-universal H and chaining, the expected bin size is great but the max bin is
∼n — too slow in the worst case. We want a perfect hash: no collisions on S.
First: expected bin size
Lemma. For h from a 2-universal family and X=∣bin(h(x))∣,
E[X]={m/n,1+(m−1)/n,x∈/S,x∈S.
(Indicators Xi=1 iff h(x)=h(si); E[Xi]=1/n for si=x, plus the certain
self-term when x∈S.) For n=m this is E[X]≤2 — but somewhere a bin still has
∼n keys. So average is fine, worst case is not.
Perfect hashing in O(m2) space
If n≥m2 then Pr[h is perfect on S]≥21.
With X=∑i<jXij counting collisions, E[X]≤(2m)/n<m2/(2n)≤21,
so by Markov Pr[X≥1]≤21⇒Pr[no collision]≥21.
Find one by Las Vegas: try random h’s; E[#tries]=2. Lookup is then O(1)
worst case — but space is a wasteful O(m2).
Two-level perfect hashing in O(m) — the FKS scheme
Lemma. Two-level hashing gives perfect hashing in O(m) space.
Level 1: a 2-universal h into n=m bins; bin i gets bi keys.
Level 2: each bin i gets its own perfect hash table of quadratic sizebi2
(perfect within the bin w.p. ≥21 by the O(m2) result above).
The only worry is total second-level space ∑ibi2. Pick a level-1 h whose collision
count satisfies X=∑i(2bi)≤m (possible since E[X]≤m2/(2n)=m/2, so
Pr[X≥m]≤21). Then, using b2=2(2b)+b,
i∑bi2=2i∑(2bi)+i∑bi≤2m+m=3m=O(m).
Punchline (FKS, Fredman–Komlós–Szemerédi).O(m) space, O(1)worst-case lookup,
for a static set — optimal. The trick is fractal: the same “quadratic table ⇒
no collisions” idea is applied once globally (to bound ∑bi2) and once inside each
bin (to make each bin perfect). The birthday n threshold from §11 is why quadratic
is exactly the right size at each level.
14. Matchings via matrices — Tutte and the Isolation Lemma
The grand finale: fingerprints decide whether a graph has a perfect matching, and the
Isolation Lemma makes that matching unique so we can even compute it in parallel.
Tutte matrix — matching existence is a polynomial identity
For a graph G on n vertices, the Tutte matrixA has an indeterminate per edge:
Theorem (Tutte).G has a perfect matching ⟺det(A)≡0 (as a polynomial
in the xij).
Why. Expand
det(A)=π∈Sn∑(−1)sgn(π)i=1∏nA(i,π(i)),
and read each permutation π as a cycle cover of G.
Odd-length cycles cancel: reversing the orientation of an odd cycle flips that term’s
sign, so π and its reversed partner add to 0. Permutations with any odd cycle
contribute nothing.
Even cycles survive (reversal keeps the sign), and an all-even cycle cover yields a
perfect matching (take alternate edges of each even cycle).
So det(A)≡0⟺ some surviving (all-even, in particular the matching) term
exists ⟺G has a perfect matching. Testing det(A)≡0 is polynomial
identity testing — by Lovász, substitute random values xij∈RZp with
p=Ω(n2) and apply Schwartz–Zippel: if a matching exists, det=0 with high
probability.
Exam-critical. “Matching exists” ≡ “this determinant is a nonzero polynomial”
≡ “a random evaluation is nonzero.” The fingerprint method decides a combinatorial
property through a numeric check.
Making the minimum matching unique (toward the algorithm)
Existence is not enough if we want to output a matching — and in parallel we cannot just
“pick one.” So put random weights on edges and aim for a unique minimum matching.
Replace xij↦±2wij:
Theorem. If G has a unique minimum-weight perfect matching M of weight W, then
det(B)=0 and 22W is the largest power of 2 dividingdet(B).
Each π contributes val(π)=∏iB(i,π(i)) with
∣val(π)∣=2(sum of edge weights used). Odd cycles cancel. An
even-cycle cover decomposes into two matchings M1,M2, contributing
2W(M1)+W(M2). The special “doubled M” permutation (each matched edge as a 2-cycle)
contributes 22W. Because M is the unique minimum, every other even permutation
has W(M1)+W(M2)>2W, so the term 22W is the lowest power of 2 and cannot
cancel (it is alone at that level). Hence v2(detB)=2W exactly.
Theorem (read off the edges). With M the unique minimum matching of weight W,
(i,j)∈M⟺22Wdet(Bij)2wij is odd,
where Bij is the minor deleting row i, column j.
The minor isolates permutations sending i↦j; if (i,j)∈M, exactly one even
cycle contributes at the minimal level 22W (odd ratio); if (i,j)∈/M, every
contribution is ≥22W+1 (even ratio). One determinant per edge tells you membership.
The Isolation Lemma — where the uniqueness comes from
But how do we guarantee a unique minimum matching? Random weights — and the reason is
completely general, nothing to do with graphs:
Isolation Lemma. Let (X,F) be a set system, X={x1,…,xm},
F={S1,…,Sk} with Si⊆X, and weights w(S)=∑x∈Sw(x).
If each w(xi)∈R{1,…,2m} independently, then
Pr[∃ a unique minimum-weight set in F]≥21.
(For matching: X = edges, F = perfect matchings. So random edge weights isolate a
unique minimum perfect matching w.p. ≥21.)
Proof — the threshold trick. Reveal the weights one element at a time. Fix all weights
except w(xi) and define the thresholdαi=(min weight of a set not containing xi)−(min weight of a set containing xi, with w(xi) set to 0).
Both terms are independent of w(xi). Now compare:
if w(xi)<αi: including xi is strictly cheaper ⇒xi is in
every minimum-weight set;
if w(xi)>αi: excluding xi is strictly cheaper ⇒xi is in
no minimum-weight set;
if w(xi)=αi: a tie — xi is ambiguous (“uncertain”).
The first two cases force xi’s membership; only the tie leaves it undecided. Since
αi does not depend on w(xi),
Pr[xi ambiguous]=Pr[w(xi)=αi]≤2m1.
Union bound over the m elements:
Pr[∃ ambiguous element]≤m⋅2m1=21.
If no element is ambiguous, every element’s membership in the minimum set is forced —
so the minimum-weight set is unique. Hence Pr[unique minimum]≥21. ■
The deep point. Uniqueness can fail only if some element lands exactly on its own
threshold — and that threshold was fixed before its weight was drawn, so it is a bullseye
hit with probability ≤1/2m. The weights need only be drawn from a range of size 2m
(linear in the ground set), independent of how many — possibly exponentially many — sets
F contains. That is the magic: we tame an exponential family with O(m)-range
random weights.
15. RNC perfect matching — the payoff
Put it together. Perfect matching ∈RNC (randomized poly-log parallel time):
Input:G(V,E) containing a perfect matching.
For every edge e, choose a random weight w(i,j)∈R{1,…,2m}.
Build the weighted matrix B (B(i,j)=±2w(i,j)).
Compute det(B).
Find the largest W with 22W∣det(B) — the minimum matching weight.
Compute the adjugate adj(B)=det(B)⋅B−1 (all minors at once).
For every edge, r(i,j)=det(Bij)2w(i,j)/22W.
Put (i,j)∈M iff r(i,j) is odd.
By the Isolation Lemma, step 1 yields a unique minimum perfect matching w.p. ≥21;
steps 3, 5 (determinant and adjugate) are in NC (parallelizable). The only
randomness is the weights.
Punchline (Mulmuley–Vazirani–Vazirani). The hard part of parallel matching is not
finding a matching but agreeing on one — independent processors computing in parallel
have no way to coordinate a choice among many matchings. The Isolation Lemma dissolves the
problem: random weights make the minimum matching unique, so it becomes a canonical
object every processor computes the same way, read off edge-by-edge from one determinant
and its minors. Randomness here buys not speed but coordination.
Recurring themes from this part
Theme
Where it appeared
Fingerprint = small random projection of a big object
Eliminate the adversary, hashing edition (random h from a family)
universal families (§12)
Birthday n threshold sets the table size
balls-in-boxes (§11) → FKS quadratic tables (§13)
Chernoff “double the mean is rare”
linear probing dangerous vertices (§11)
Combinatorial property decided by a numeric determinant
Tutte matrix (§14)
Randomness for coordination, not speed (make the answer unique)
Isolation Lemma → RNC matching (§14–§15)
The one sentence tying it together:
Stop comparing the elephants — compare their shadows. A random projection (a vector,
a prime, a field point, a hash) shrinks an intractable equality test to a cheap one with
only one-sided error; pushed further, the same idea hashes data in O(1), decides matching
through a determinant, and — via the Isolation Lemma — isolates a single canonical
solution that even parallel machines can agree on.