Documentation

CslibFrontier.Probability.MoserTardos.Parallel

Parallel Moser–Tardos algorithm #

This module formalizes the parallel resampling algorithm for the variable-model Lovász Local Lemma ([MoserTardos2010, Algorithm 1.2, Section 4, Theorem 1.3]).

In each parallel round, an admissible selection rule psel inspects the current assignment current vbl T w and selects a maximal independent set of occurring bad events:

  1. every selected event occurs at current vbl T w (IsValidParallelRule.mem);
  2. selected events are pairwise non-adjacent (¬Adj vbl i j), i.e., distinct and defined on disjoint variable sets (IsValidParallelRule.pairwise);
  3. every occurring event shares at least one variable with (or equals) some selected event (IsValidParallelRule.max).

In particular, psel T w = [] holds if and only if no bad event occurs at current vbl T w. Resampling all events in the chosen batch in sequence appends them onto the cumulative log w (parallelRun), preserving IsLog. Any event resampled in round k yields a witness structure of depth k and size at least k + 1 ([MoserTardos2010, Lemma 4.1]). Summing the resulting tail bounds Pr[parallelRounds ≥ k + 1] ≤ min 1 ((1 - ε)^(k+1) * ∑ i, x i / (1 - x i)) yields the logarithmic expected round bound ((max 0 (Real.log M) + 1) / ε) of Theorem 1.3.

Termination needs no slack. Every prefix of the parallel run is a valid log, so the bound of Theorem 1.2 for all valid logs (lintegral_iSup_count_le) applies to it. Under the plain hypothesis Pr[A i] ≤ x i * ∏ j ∈ Γ i, (1 - x j), almost surely every admissible rule reaches an empty batch, and the whole run performs at most ∑ i, x i / (1 - x i) resamplings in expectation. The slack ε is needed only for the round bound.

Main definitions #

Main results #

References #

structure Cslib.Probability.MoserTardos.IsValidParallelRule {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) :

A parallel selection rule for the Moser–Tardos algorithm chooses, from the table T and the current log w, a maximal independent subset of the events occurring at current vbl T w. Returning [] indicates that no bad event occurs.

  • mem (T : (p : V × ℕ) → α p.1) (w : List ι) (i : ι) : i ∈ psel T w → current vbl T w ∈ A i

    Every chosen event occurs in the current assignment.

  • pairwise (T : (p : V × ℕ) → α p.1) (w : List ι) : List.Pairwise (fun (i j : ι) => ¬Adj vbl i j) (psel T w)

    Distinct steps in a batch have disjoint variable sets (in particular, no duplicates).

  • max (T : (p : V × ℕ) → α p.1) (w : List ι) (i : ι) : current vbl T w ∈ A i → ∃ j ∈ psel T w, Adj vbl i j

    Every occurring event shares at least one variable with some chosen event.

theorem Cslib.Probability.MoserTardos.IsValidParallelRule.eq_nil_iff {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] {vbl : ι → Finset V} {A : ι → Set ((v : V) → α v)} {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (h : IsValidParallelRule vbl A psel) (T : (p : V × ℕ) → α p.1) (w : List ι) :
psel T w = [] ↔ ∀ (i : ι), current vbl T w ∉ A i

A valid parallel rule returns [] if and only if no bad event occurs in the current assignment.

def Cslib.Probability.MoserTardos.parallelRun {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) (T : (p : V × ℕ) → α p.1) :
ℕ → List ι

The cumulative resampling log (latest step first) after n rounds of the parallel algorithm using selection rule psel on table T.

@[simp]
theorem Cslib.Probability.MoserTardos.parallelRun_zero {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) (T : (p : V × ℕ) → α p.1) :
parallelRun psel T 0 = []
theorem Cslib.Probability.MoserTardos.parallelRun_succ {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) (T : (p : V × ℕ) → α p.1) (n : ℕ) :
parallelRun psel T (n + 1) = psel T (parallelRun psel T n) ++ parallelRun psel T n
theorem Cslib.Probability.MoserTardos.parallelRun_eq_of_eq_nil {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} {T : (p : V × ℕ) → α p.1} {n : ℕ} (hn : psel T (parallelRun psel T n) = []) {m : ℕ} :
n ≤ m → parallelRun psel T m = parallelRun psel T n

Once a round returns [], all subsequent logs remain unchanged.

theorem Cslib.Probability.MoserTardos.psel_parallelRun_eq_nil_of_le {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} {T : (p : V × ℕ) → α p.1} {n m : ℕ} (hn : psel T (parallelRun psel T n) = []) (hnm : n ≤ m) :
psel T (parallelRun psel T m) = []

Once a round returns [], all subsequent rounds return [].

theorem Cslib.Probability.MoserTardos.isLog_parallelRun {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) (T : (p : V × ℕ) → α p.1) (n : ℕ) :
IsLog vbl A T (parallelRun psel T n)

Every finite prefix parallelRun psel T n produced by a valid parallel selection rule is a valid log.

noncomputable def Cslib.Probability.MoserTardos.parallelRounds {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) (T : (p : V × ℕ) → α p.1) :

The number of non-empty parallel resampling rounds performed by psel on T (⊤ if no round ever returns []).

theorem Cslib.Probability.MoserTardos.parallelRounds_le_of_eq_nil {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} {T : (p : V × ℕ) → α p.1} {n : ℕ} (hn : psel T (parallelRun psel T n) = []) :
parallelRounds psel T ≤ ↑n

If round n returns [], at most n rounds are non-empty.

theorem Cslib.Probability.MoserTardos.succ_le_parallelRounds_iff {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) (T : (p : V × ℕ) → α p.1) (k : ℕ) :
↑k + 1 ≤ parallelRounds psel T ↔ psel T (parallelRun psel T k) ≠ []
theorem Cslib.Probability.MoserTardos.exists_eq_nil_of_parallelRounds_ne_top {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) {T : (p : V × ℕ) → α p.1} (hfin : parallelRounds psel T ≠ ⊤) :
∃ (n : ℕ), psel T (parallelRun psel T n) = []
theorem Cslib.Probability.MoserTardos.parallelRounds_eq_tsum {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} (psel : ((p : V × ℕ) → α p.1) → List ι → List ι) (T : (p : V × ℕ) → α p.1) :
parallelRounds psel T = ∑' (k : ℕ), if psel T (parallelRun psel T k) ≠ [] then 1 else 0
def Cslib.Probability.MoserTardos.greedyIndependentSubset {V : Type u_1} {ι : Type u_2} [DecidableEq V] [DecidableEq ι] (vbl : ι → Finset V) (P : ι → Bool) :
List ι → List ι

Greedy maximal independent subset of candidates cand satisfying Boolean predicate P, scanning right-to-left and accepting each candidate that satisfies P and is distinct from and variable-disjoint from all already-selected elements.

def Cslib.Probability.MoserTardos.greedyParallelList {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] [DecidableEq ι] (vbl : ι → Finset V) (cand : List ι) (occur : ((v : V) → α v) → ι → Bool) (T : (p : V × ℕ) → α p.1) (w : List ι) :
List ι

Computable greedy maximal independent set parallel selection rule over an explicit candidate list cand and Boolean event detector occur.

theorem Cslib.Probability.MoserTardos.isValidParallelRule_greedyParallelList {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] [DecidableEq ι] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (cand : List ι) (hcand : ∀ (i : ι), i ∈ cand) (occur : ((v : V) → α v) → ι → Bool) (hoccur : ∀ (a : (v : V) → α v) (i : ι), occur a i = true ↔ a ∈ A i) :
noncomputable def Cslib.Probability.MoserTardos.greedyParallel {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] [DecidableEq ι] [Fintype ι] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (T : (p : V × ℕ) → α p.1) (w : List ι) :
List ι

Noncomputable canonical greedy maximal independent set parallel selection rule for finite event index types ι.

theorem Cslib.Probability.MoserTardos.isValidParallelRule_greedyParallel {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] [DecidableEq ι] [Fintype ι] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) :
theorem Cslib.Probability.MoserTardos.parallel_witness_depth {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [DecidableEq V] [DecidableEq ι] [Fintype ι] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) (T : (p : V × ℕ) → α p.1) (k : ℕ) {i : ι} {pref suff : List ι} (hsplit : psel T (parallelRun psel T k) = pref ++ i :: suff) :
have S := witness vbl i (suff ++ parallelRun psel T k); S ∈ shapes vbl i k ∧ Proper vbl S ∧ Check vbl A S T ∧ (∃ p ∈ S, p.2 = k) ∧ k + 1 ≤ S.card

Parallel witness-tree depth lemma [MoserTardos2010, Lemma 4.1]: if round k selects a non-empty batch containing i (with suffix suff after i in that batch), then the witness structure witness vbl i (suff ++ parallelRun psel T k) lies in shapes vbl i k, is proper, passes its check on T, and contains a vertex at depth k (hence has cardinality ≥ k + 1).

theorem Cslib.Probability.MoserTardos.table_succ_le_parallelRounds_le {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Fintype ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) {ε : ℝ} (hε : ε ∈ Set.Ioc 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ (1 - ε) * (x i * ∏ j ∈ Γ i, (1 - x j))) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) (k : ℕ) :
(table μ) {T : (p : V × ℕ) → α p.1 | ↑k + 1 ≤ parallelRounds psel T} ≤ ENNReal.ofReal ((1 - ε) ^ (k + 1) * ∑ i : ι, x i / (1 - x i))

Parallel Moser–Tardos tail bound ([MoserTardos2010, Section 4]): under Pr[A i] ≤ (1 - ε) * x i * ∏ j ∈ Γ i, (1 - x j) with ε ∈ (0, 1], for every admissible parallel selection rule psel, the probability that the algorithm performs at least k + 1 parallel rounds is at most (1 - ε) ^ (k + 1) * ∑ i, x i / (1 - x i).

theorem Cslib.Probability.MoserTardos.lintegral_parallelRounds_le {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Fintype ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) {ε : ℝ} (hε : ε ∈ Set.Ioc 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ (1 - ε) * (x i * ∏ j ∈ Γ i, (1 - x j))) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∫⁻ (T : (p : V × ℕ) → α p.1), parallelRounds psel T ∂table μ ≤ ENNReal.ofReal ((max 0 (Real.log (∑ i : ι, x i / (1 - x i))) + 1) / ε)

Parallel Moser–Tardos theorem [MoserTardos2010, Theorem 1.3]: under Pr[A i] ≤ (1 - ε) * x i * ∏ j ∈ Γ i, (1 - x j) with ε ∈ (0, 1], any admissible parallel selection rule terminates in at most (max 0 (Real.log (∑ i, x i / (1 - x i))) + 1) / ε expected parallel rounds.

The rule is not assumed measurable, so ∫⁻ is the lower Lebesgue integral. As in the sequential theorem, exists_measurable_ge_parallelRounds dominates parallelRounds psel for every valid parallel rule by a single measurable function of the table with the same expected bound.

theorem Cslib.Probability.MoserTardos.exists_measurable_ge_parallelRounds {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Fintype ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) {ε : ℝ} (hε : ε ∈ Set.Ioc 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ (1 - ε) * (x i * ∏ j ∈ Γ i, (1 - x j))) :
∃ (g : ((p : V × ℕ) → α p.1) → ENNReal), Measurable g ∧ ∫⁻ (T : (p : V × ℕ) → α p.1), g T ∂table μ ≤ ENNReal.ofReal ((max 0 (Real.log (∑ i : ι, x i / (1 - x i))) + 1) / ε) ∧ ∀ (psel : ((p : V × ℕ) → α p.1) → List ι → List ι), IsValidParallelRule vbl A psel → ∀ (T : (p : V × ℕ) → α p.1), parallelRounds psel T ≤ g T

Theorem 1.3 for the outer expectation [MT10]: under the slack local-lemma hypothesis there is a measurable function g of the table, with ∫⁻ g ≤ (max 0 (Real.log (∑ i, x i / (1 - x i))) + 1) / ε, that bounds parallelRounds psel for every valid parallel selection rule psel. So the bound holds for the upper (outer) expectation of the number of rounds as well, whether or not the rule is measurable.

theorem Cslib.Probability.MoserTardos.ae_exists_parallelRun_eq_nil_of_bound {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [DecidableEq V] [Finite ι] (μ : (v : V) → MeasureTheory.Measure (α v)) (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (hc : ∀ [inst : DecidableEq ι] (i : ι), ∫⁻ (T : (p : V × ℕ) → α p.1), ⨆ (w : List ι), ⨆ (_ : IsLog vbl A T w), ↑(List.count i w) ∂table μ ≠ ⊤) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∀ᵐ (T : (p : V × ℕ) → α p.1) ∂table μ, ∃ (n : ℕ), psel T (parallelRun psel T n) = []

Termination of the parallel algorithm, generic form. If every event's largest count in a valid log has finite expectation, then almost surely every admissible parallel rule reaches an empty batch after finitely many rounds. No slack is needed: the run's logs are valid (isLog_parallelRun) and grow in every non-empty round, while ae_exists_forall_isLog_length_le_of_bound bounds the length of every valid log.

theorem Cslib.Probability.MoserTardos.ae_exists_parallelRun_eq_nil {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Finite ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ x i * ∏ j ∈ Γ i, (1 - x j)) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∀ᵐ (T : (p : V × ℕ) → α p.1) ∂table μ, ∃ (n : ℕ), psel T (parallelRun psel T n) = []

Under the local-lemma hypothesis Pr[A i] ≤ x i * ∏ j ∈ Γ i, (1 - x j) of Theorem 1.2, without the slack 1 - ε that Theorem 1.3 needs for its round bound, almost surely every admissible parallel rule reaches an empty batch after finitely many rounds. This is a consequence of the valid-log bound lintegral_iSup_count_le through ae_exists_parallelRun_eq_nil_of_bound. Moser and Tardos make the same observation when they introduce Algorithm 1.2 [MoserTardos2010, Section 1]: the parallel algorithm "can be considered a special case of the sequential algorithm, so the statement of Theorem 1.2 applies to the parallel version too".

theorem Cslib.Probability.MoserTardos.ae_parallelRounds_ne_top {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Finite ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ x i * ∏ j ∈ Γ i, (1 - x j)) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∀ᵐ (T : (p : V × ℕ) → α p.1) ∂table μ, parallelRounds psel T ≠ ⊤

Under the local-lemma hypothesis of Theorem 1.2 (no slack), parallelRounds psel T < ⊤ almost surely for every admissible parallel rule psel.

theorem Cslib.Probability.MoserTardos.ae_exists_forall_notMem_parallelRun {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Finite ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ x i * ∏ j ∈ Γ i, (1 - x j)) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∀ᵐ (T : (p : V × ℕ) → α p.1) ∂table μ, ∃ (n : ℕ), ∀ (i : ι), current vbl T (parallelRun psel T n) ∉ A i

Under the local-lemma hypothesis of Theorem 1.2 (no slack), almost surely every admissible parallel rule reaches an assignment avoiding all bad events in finitely many parallel rounds.

theorem Cslib.Probability.MoserTardos.lintegral_iSup_length_parallelRun_le {V : Type u_1} {ι : Type u_2} {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [DecidableEq V] [Fintype ι] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) (hP : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ x i * ∏ j ∈ Γ i, (1 - x j)) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∫⁻ (T : (p : V × ℕ) → α p.1), ⨆ (n : ℕ), ↑(parallelRun psel T n).length ∂table μ ≤ ∑ i : ι, ENNReal.ofReal (x i / (1 - x i))

Under the local-lemma hypothesis of Theorem 1.2 (no slack), every admissible parallel rule performs at most ∑ i, x i / (1 - x i) resamplings in expectation over the whole run. This is a consequence of the valid-log bound lintegral_iSup_count_le: each prefix of the parallel run is a valid log (isLog_parallelRun), so its length is at most the measurable majorant ∑ i, ⨆ (w valid), w.count i (length_le_sum_iSup_count), whose integral lintegral_sum_iSup_count_le_of_bound bounds. Moser and Tardos note after introducing Algorithm 1.2 that Theorem 1.2 applies to the parallel version [MoserTardos2010, Section 1].

As for lintegral_parallelRounds_le, the rule is not assumed measurable and ∫⁻ is the lower Lebesgue integral. The theorem bounds that lower integral through the majorant; it does not identify it with the integral of the majorant.

theorem Cslib.Probability.MoserTardos.lintegral_parallelRounds_le_symmetric_of_pos {V : Type u_1} {ι : Type u_2} [DecidableEq V] [DecidableEq ι] [Fintype ι] {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) {d : ℕ} (hdpos : 1 ≤ d) (hd : ∀ (i : ι), {j : ι | j ≠ i ∧ ¬Disjoint (vbl i) (vbl j)}.card ≤ d) {q ε : ℝ} (hq : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ q) (hε : ε ∈ Set.Ioc 0 1) (hlll : Real.exp 1 * q * (↑d + 1) ≤ 1 - ε) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∫⁻ (T : (p : V × ℕ) → α p.1), parallelRounds psel T ∂table μ ≤ ENNReal.ofReal ((max 0 (Real.log (↑(Fintype.card ι) / ↑d)) + 1) / ε)

Symmetric parallel Moser–Tardos theorem (1 ≤ d): under e * q * (d + 1) ≤ 1 - ε with ε ∈ (0, 1], any admissible parallel selection rule terminates in at most (max 0 (Real.log (card ι / d)) + 1) / ε expected parallel rounds.

theorem Cslib.Probability.MoserTardos.lintegral_parallelRounds_le_symmetric {V : Type u_1} {ι : Type u_2} [DecidableEq V] [DecidableEq ι] [Fintype ι] {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) {d : ℕ} (hd : ∀ (i : ι), {j : ι | j ≠ i ∧ ¬Disjoint (vbl i) (vbl j)}.card ≤ d) {q ε : ℝ} (hq : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ q) (hε : ε ∈ Set.Ioc 0 1) (hlll : Real.exp 1 * q * (↑d + 1) ≤ 1 - ε) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∫⁻ (T : (p : V × ℕ) → α p.1), parallelRounds psel T ∂table μ ≤ ENNReal.ofReal ((max 0 (Real.log ↑(Fintype.card ι)) + 1) / ε)

Symmetric parallel Moser–Tardos theorem (all d : ℕ): under e * q * (d + 1) ≤ 1 - ε with ε ∈ (0, 1], any admissible parallel selection rule terminates in at most (max 0 (Real.log (card ι)) + 1) / ε expected parallel rounds.

theorem Cslib.Probability.MoserTardos.ae_exists_forall_notMem_parallelRun_symmetric {V : Type u_1} {ι : Type u_2} [DecidableEq V] [DecidableEq ι] [Fintype ι] {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] (μ : (v : V) → MeasureTheory.Measure (α v)) [∀ (v : V), MeasureTheory.IsProbabilityMeasure (μ v)] (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) {d : ℕ} (hd : ∀ (i : ι), {j : ι | j ≠ i ∧ ¬Disjoint (vbl i) (vbl j)}.card ≤ d) {q : ℝ} (hq : ∀ (i : ι), (MeasureTheory.Measure.pi μ).real (A i) ≤ q) (hlll : Real.exp 1 * q * (↑d + 1) ≤ 1) {psel : ((p : V × ℕ) → α p.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∀ᵐ (T : (p : V × ℕ) → α p.1) ∂table μ, ∃ (n : ℕ), ∀ (i : ι), current vbl T (parallelRun psel T n) ∉ A i

Almost sure termination and avoidance under the symmetric local-lemma hypothesis e * q * (d + 1) ≤ 1, with no slack, for every d : ℕ.

theorem Cslib.Probability.MoserTardos.lintegral_parallelRounds_le_pmfPi {V : Type u_1} {ι : Type u_2} [DecidableEq V] [Fintype ι] {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [∀ (v : V), Finite (α v)] [∀ (v : V), MeasurableSingletonClass (α v)] (p : (v : V) → PMF (α v)) (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) {ε : ℝ} (hε : ε ∈ Set.Ioc 0 1) (hAx : ∀ (i : ι), ((PMF.pi p).toOuterMeasure (A i)).toReal ≤ (1 - ε) * (x i * ∏ j ∈ Γ i, (1 - x j))) {psel : ((q : V × ℕ) → α q.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
(∫⁻ (T : (p : V × ℕ) → α p.1), parallelRounds psel T ∂table fun (v : V) => (p v).toMeasure) ≤ ENNReal.ofReal ((max 0 (Real.log (∑ i : ι, x i / (1 - x i))) + 1) / ε)

PMF.pi bridge for parallel Moser–Tardos expected rounds under the general asymmetric slack LLL hypothesis.

theorem Cslib.Probability.MoserTardos.ae_exists_forall_notMem_parallelRun_pmfPi {V : Type u_1} {ι : Type u_2} [DecidableEq V] {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [Finite ι] [∀ (v : V), Finite (α v)] [∀ (v : V), MeasurableSingletonClass (α v)] (p : (v : V) → PMF (α v)) (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) (Γ : ι → Finset ι) (hΓ : ∀ (i j : ι), j ≠ i → ¬Disjoint (vbl i) (vbl j) → j ∈ Γ i) {x : ι → ℝ} (hx : ∀ (i : ι), x i ∈ Set.Ico 0 1) (hAx : ∀ (i : ι), ((PMF.pi p).toOuterMeasure (A i)).toReal ≤ x i * ∏ j ∈ Γ i, (1 - x j)) {psel : ((q : V × ℕ) → α q.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
∀ᵐ (T : (p : V × ℕ) → α p.1) ∂table fun (v : V) => (p v).toMeasure, ∃ (n : ℕ), ∀ (i : ι), current vbl T (parallelRun psel T n) ∉ A i

PMF.pi bridge for almost-sure parallel Moser–Tardos termination and avoidance under the general asymmetric local-lemma hypothesis, with no slack.

theorem Cslib.Probability.MoserTardos.lintegral_parallelRounds_le_pmfPi_symmetric {V : Type u_1} {ι : Type u_2} [DecidableEq V] [DecidableEq ι] [Fintype ι] {α : V → Type u_3} [(v : V) → MeasurableSpace (α v)] [Fintype V] [∀ (v : V), Finite (α v)] [∀ (v : V), MeasurableSingletonClass (α v)] (p : (v : V) → PMF (α v)) (vbl : ι → Finset V) (A : ι → Set ((v : V) → α v)) (hAm : ∀ (i : ι), MeasurableSet (A i)) (hA : ∀ (i : ι), DependsOn (fun (x : (i : V) → α i) => x ∈ A i) ↑(vbl i)) {d : ℕ} (hd : ∀ (i : ι), {j : ι | j ≠ i ∧ ¬Disjoint (vbl i) (vbl j)}.card ≤ d) {q ε : ℝ} (hq : ∀ (i : ι), ((PMF.pi p).toOuterMeasure (A i)).toReal ≤ q) (hε : ε ∈ Set.Ioc 0 1) (hlll : Real.exp 1 * q * (↑d + 1) ≤ 1 - ε) {psel : ((q' : V × ℕ) → α q'.1) → List ι → List ι} (hrule : IsValidParallelRule vbl A psel) :
(∫⁻ (T : (p : V × ℕ) → α p.1), parallelRounds psel T ∂table fun (v : V) => (p v).toMeasure) ≤ ENNReal.ofReal ((max 0 (Real.log ↑(Fintype.card ι)) + 1) / ε)

PMF.pi bridge for symmetric parallel Moser–Tardos expected rounds (all d : ℕ).