Documentation

CslibFrontier.Probability.PMF.TwoBranch

Retained success across two probabilistic branches #

A first branch may establish success; a conditional second branch may recover from its failure. If each relevant branch hits with probability at least 1 / s and the second retains every first-branch success, the final hit probability is at least 2 / (s + 1). The continuation may depend on the first outcome, so no independence or finite ambient type is assumed.

Main results #

References #

Generalized from Renfei Zhou's Karger–Stein success rule over ProbComp. Runtime and query budgets are separate execution obligations.

theorem Cslib.Probability.PMF.one_sub_sq_one_sub_inv_ge {s : ℕ} (hs : 1 ≤ s) :
2 / ↑(s + 1) ≤ 1 - (1 - 1 / ↑s) ^ 2

Elementary recurrence 2 / (s + 1) ≤ 1 - (1 - 1 / s) ^ 2 in ℝ≥0∞ for 1 ≤ s, derived from (2 * s - 1) * (s + 1) = 2 * s ^ 2 + s - 1 ≥ 2 * s ^ 2.

theorem Cslib.Probability.PMF.two_branch_hit_prob_ge {α : Type u_1} {β : Type u_2} {γ : Type u_3} (m₁ : PMF α) (m₂ : α → PMF β) (f : α → β → γ) (hit₁ : Set α) (hit : Set γ) {s : ℕ} (hs : 1 ≤ s) (hb₁ : 1 / ↑s ≤ m₁.toOuterMeasure hit₁) (hprop₁ : ∀ a ∈ m₁.support, a ∈ hit₁ → ∀ b ∈ (m₂ a).support, f a b ∈ hit) (hb₂ : ∀ a ∈ m₁.support, a ∉ hit₁ → 1 / ↑s ≤ (PMF.map (f a) (m₂ a)).toOuterMeasure hit) :
2 / ↑(s + 1) ≤ (m₁.bind fun (a : α) => PMF.map (f a) (m₂ a)).toOuterMeasure hit

If the first branch hits with probability at least 1 / s, its hits are retained, and conditional recovery has the same lower bound on every supported miss, the two-stage result hits with probability at least 2 / (s + 1).