Compiled minimum-cut programs from an output law #
The basic Karger and recursive Karger–Stein programs share the same final step: compile a structured code whose observed word has a law supported on non-trivial cut weights. This module transports that law to halted configurations, retaining supported-path halt and random-call bounds, bounded data and the exact memory frame. Their amplification loops also share the update of the best cut weight after each trial.
Main results #
Cslib.Algorithms.WordRAM.Karger.program_of_law: compiled halt, call, cut and probability contracts from the existingExecRandLaw.Cslib.Algorithms.WordRAM.Karger.program_failure_le_inv_n: unconditional1 / nfailure probability bound for compiled amplified minimum-cut programs.Cslib.Algorithms.WordRAM.Karger.minUpdate_exec: the running-minimum update on any registers, with its register frame.
References #
Extracted unchanged from the Karger word-RAM endpoint proof; the algorithm-specific mathematics belongs to its specification law.
A compiled program whose output word has the law μ, supported on the weights of non-trivial
cuts of W, halts on every path with such a weight, and outputs minCut W with at least the
probability that μ gives it; it fails to do so with at most the probability that μ gives the
other values.
Unconditional 1 / n failure-probability bound for a compiled minimum-cut program c.program out: for n < 2 the right-hand side 1 / n is at least 1; for 2 ≤ n, the program's miss
probability is bounded by μ.toOuterMeasure {v | v ≠ minCut W}, which is 0 when minCut W = 0
and μ is supported on {0}, and at most 1 / (2 * n) ≤ 1 / n when 0 < minCut W.
The running-minimum update shared by the amplification loops, on any registers: on the first
trial (trial equal to the zero register) it records val in best, and afterwards the smaller
of val and best. It runs within five instructions and changes no other register or memory.