The PPSZ algorithm on the randomized word RAM #
Cslib.Algorithms.WordRAM.PPSZ.ampProgram is the PPSZ k-SAT algorithm
Paturi, Pudlák, Saks, Zane with w-implication Hertli
and confidence c, as a program of the randomized word RAM. On the input
s :: a :: b :: c :: encode φ it computes the number of rounds
R = ppszRounds a b n c = 2 ^ ⌈a n / b⌉ c in a multiword counter, then runs up to R independent
rounds of PPSZ with the bound s (Cslib.Algorithms.WordRAM.PPSZ.roundProgram), stopping at the
first round whose assignment satisfies the formula. It halts with output 1, leaving a satisfying
assignment in memory, or with output 0 when every round failed.
The rational a / b is an upper bound on the exponent of the success probability of one round,
supplied with the input. The bound proved for satisfiable formulas with clauses of at most k ≥ 3
literals and s ≥ ∑ i < h, (k - 1) ^ i is 2 ^ (-(1 - qbar k h) n)
(Cslib.Complexity.PPSZ.round_success_of_satisfiable), and qbar k h is the value of an integral.
The program does not compute it: the failure bound
Cslib.Algorithms.WordRAM.PPSZ.ampProgram_failure_le_exp assumes 1 - qbar k h ≤ a / b. For
3-SAT, qbar 3 2 = 31 / 70 gives the choice (s, a, b) = (3, 39, 70)
(Cslib.Algorithms.WordRAM.PPSZ.ampProgram_failure_le_exp_three). With (a, b) = (k - 1, k), the
number of rounds is that of PPZ (Cslib.Algorithms.WordRAM.PPZ.ppzRounds).
The program reuses the amplified loop of PPZ (Cslib.Algorithms.WordRAM.PPZ.ampLoopWith) with the
round body of PPSZ (Cslib.Algorithms.WordRAM.PPSZ.roundCore_isRoundCore). The words that the
oracle reads after the order array, s and 2 s zero words, come before the counter.
Cslib.Algorithms.WordRAM.PPSZ.ampProgram_spec proves, at every word size w with
L + 2 n + 2 s + a n + b + 2 c + ppszCounterLen a b n c + 3 < 2 ^ w, where L is the input length
and ppszCounterLen a b n c = ⌈a n / b⌉ + 1 + (number of binary digits of c) bounds the number of
digits of R:
- the program halts on every path within
ampTime s a b c n Linstructions, which isR (n (impliedTime s L + 25) + 12 L + 41)plus a setup cost linear in the counter length; - it makes at most
2 n Rrandcalls; - an output
1always comes with a satisfying assignment, so the program never errs on unsatisfiable formulas; - the output is
1with exactly the law ofRindependent rounds of PPSZ, so it is0with probability exactly(1 - p) ^ R, wherepis the probability that one round finds a satisfying assignment.
The running time is O((s + 1)² (n + L) ^ (2 s + 1) 2 ^ ((a / b) n) (c + 1))
(Cslib.Algorithms.WordRAM.PPSZ.ampTime_le).
Main definitions #
Cslib.Algorithms.WordRAM.PPSZ.ppszExp,Cslib.Algorithms.WordRAM.PPSZ.ppszRounds: the number of rounds.Cslib.Algorithms.WordRAM.PPSZ.ampCode,Cslib.Algorithms.WordRAM.PPSZ.ampProgram: the amplified algorithm, structured and compiled.Cslib.Algorithms.WordRAM.PPSZ.ampTime: its instruction bound.
Main results #
Cslib.Algorithms.WordRAM.PPSZ.roundCore_isRoundCore: the round body of PPSZ in the amplified loop.Cslib.Algorithms.WordRAM.PPSZ.ampProgram_spec: halting, time andrandbounds, no false positives, and the exact law of the output.Cslib.Algorithms.WordRAM.PPSZ.ampProgram_failure_le_exp: on a satisfiable k-CNF the program fails with probability at moste ^ (-c).Cslib.Algorithms.WordRAM.PPSZ.ampProgram_failure_le_exp_three: the same for 3-CNF with(s, a, b) = (3, 39, 70).Cslib.Algorithms.WordRAM.PPSZ.ampProgram_failure_le_exp_limit: theε-form, for everya / b ≥ 1 - μ_k / (k - 1) + εwith a boundsdepending onkandε.Cslib.Algorithms.WordRAM.PPSZ.ampTime_le: the time bound.
References #
Registers #
The numerator a of the bound on the exponent, during the setup; shares register 6 with
sReg.
The denominator b of the bound on the exponent, during the setup; shares register 9 with
jR.
The round body #
The body of a round of PPSZ is a round body for Cslib.Complexity.PPSZ.implied φ s, on
rounds whose memory holds s and 2 s zero words just after the order array.
The number of rounds #
The exponent ⌈a n / b⌉ of the number of rounds.
The number of rounds of PPSZ with confidence c on n variables, for the bound a / b on
the exponent: 2 ^ ⌈a n / b⌉ c.
The binary digits of the number of rounds, as the setup computes them.
A bound on the number of digits of the number of rounds.
The setup #
Set up the registers on the input s :: a :: b :: c :: encode φ: the clauses start at address
6, the partial assignment is stored just after the input, then the order array; s is copied to
the word after the order array, the counter starts after the 2 s words that follow it, and
eReg = ⌈a n / b⌉.
The data after the setup on the input s :: a :: b :: c :: encode φ.
The memory after the setup: the input, then s at L + 1 + 2 n, and zero after it.
The setup establishes the frame of the rounds on the input s :: a :: b :: c :: encode φ.
The algorithm #
The PPSZ algorithm on the input s :: a :: b :: c :: encode φ.
The PPSZ algorithm on the input s :: a :: b :: c :: encode φ, halting with out.
The instruction bound of the PPSZ algorithm with the bound s, the bound a / b on the
exponent and confidence c, on n variables and an input of length L.
The PPSZ algorithm on the randomized word RAM. On the input s :: a :: b :: c :: encode φ
of length L, at any word size w with
L + 2 n + 2 s + a n + b + 2 c + ppszCounterLen a b n c + 3 < 2 ^ w, the program
- halts on every path within
ampTime s a b c n Linstructions; - makes at most
R (2 n)randcalls, whereR = ppszRounds a b n c; - outputs
0or1, and outputs1only with a satisfying assignment ofφstored at addressL + 1; - outputs
1with exactly the lawrepeatRoundWith (implied φ s) φ Rof up toRindependent rounds of PPSZ with the bounds.
The PPSZ bound for one round Hertli: on a satisfiable formula with clauses
of at most k ≥ 3 literals, one round of PPSZ with s ≥ ∑ i < h, (k - 1) ^ i succeeds with
probability at least 2 ^ (-(1 - qbar k h) n)
(Cslib.Complexity.PPSZ.round_success_of_satisfiable).
With R = ppszRounds a b n c rounds, R 2 ^ (-(a / b) n) is at least c.
Amplification from a bound on one round: if one round of PPSZ with the bound s succeeds
with probability at least 2 ^ (-(a / b) n), the program fails with probability at most
e ^ (-c).
The PPSZ algorithm succeeds with high probability
Paturi, Pudlák, Saks, Zane, Hertli. On a satisfiable
formula whose clauses have at most k ≥ 3 literals, with s ≥ ∑ i < h, (k - 1) ^ i and
1 - qbar k h ≤ a / b, the program outputs 1 except with probability at most e ^ (-c).
PPSZ for k-SAT on the randomized word RAM, ε-form
Paturi, Pudlák, Saks, Zane, Hertli. Let k ≥ 3 and
ε > 0. There is a bound s such that for every rational a / b ≥ 1 - μ_k / (k - 1) + ε, the
program with the bound s fails on any satisfiable formula whose clauses have at most k literals
with probability at most e ^ (-c), in time O((n + L) ^ (2 s + 1) 2 ^ ((a / b) n) (c + 1))
(ampTime_le). This uses Cslib.Complexity.PPSZ.round_success_limit, the ε-form of the bound
2 ^ (-(1 - μ_k / (k - 1)) n - o(n)) of the sources.
PPSZ for 3-SAT on the randomized word RAM. With s = 3 and the bound 39 / 70 on the
exponent, which is 1 - qbar 3 2, the program fails on a satisfiable 3-CNF with probability at
most e ^ (-c). It runs 2 ^ ⌈39 n / 70⌉ c rounds, about 1.471 ^ n c.
The running time of the PPSZ algorithm is
O((s + 1)² (n + L) ^ (2 s + 1) 2 ^ ((a / b) n) (c + 1)): explicitly, at most
600 (s + 1)² (n + L + 1) ^ (2 s + 1) 2 ^ ((a / b) n) (c + 1) instructions.