Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Section 2, Eq. (3) — closed form of p_i under R₁

Proved
RobbinsSeqDesign.StayOrSwitch.head_prob_closed_form

by mikedeng1 · Oct 6, 2026 · Mathlib 0df444a (Lean v4.33.1)

bandit-algorithmsmarkov-chainsp2o-batch-pfp2bp2o-gran-per-chapterp2o-plan-paperp2o-v1

Let coins AAA and BBB have head probabilities α,β∈[0,1]\alpha, \beta\in[0,1]α,β∈[0,1], not both 000 and not both 111, and let pip_ipi​ be the probability of heads on the iii-th toss under the rule R1R_1R1​. Then α+β≠2\alpha+\beta \neq 2α+β=2, and for every i≥1i\ge1i≥1,

pi=(α+β−1) i−1[p1−α+β−2αβ2−(α+β)]+α+β−2αβ2−(α+β).p_i = (\alpha+\beta-1)^{\,i-1}\left[p_1 - \frac{\alpha+\beta-2\alpha\beta}{2-(\alpha+\beta)}\right] + \frac{\alpha+\beta-2\alpha\beta}{2-(\alpha+\beta)} .pi​=(α+β−1)i−1[p1​−2−(α+β)α+β−2αβ​]+2−(α+β)α+β−2αβ​.

Since ∣α+β−1∣<1|\alpha+\beta-1|<1∣α+β−1∣<1 under the hypothesis, the first term decays geometrically; this gives the limit (4).

Formalization Note The exclusion "not both 000 or both 111" is the paper's standing hypothesis stated just before (2); it makes the denominator positive. At i=1i = 1i=1 the power is 00=10^0 = 100=1 when α+β=1\alpha+\beta = 1α+β=1, which is the reading the formula needs.

Preamble
import Mathlib
import Definitions.Def_RobbinsSeqDesign_StayOrSwitch_Rules

open MeasureTheory ProbabilityTheory Filter Topology
Formal statement
namespace RobbinsSeqDesign.StayOrSwitch

/-- Section 2, Eq. (3), p. 530: if `α, β` are not both `0` and not both `1`, then under rule
`R₁`, for every `i ≥ 1`,
`p_i = (α + β − 1)^{i−1} [p₁ − (α + β − 2αβ)/(2 − (α + β))] + (α + β − 2αβ)/(2 − (α + β))`. -/
theorem head_prob_closed_form (α β : unitInterval)
    (hnot0 : ¬((α : ℝ) = 0 ∧ (β : ℝ) = 0)) (hnot1 : ¬((α : ℝ) = 1 ∧ (β : ℝ) = 1))
    (i : ℕ) (hi : 1 ≤ i) :
    headProb ruleR1 α β i =
      ((α : ℝ) + β - 1) ^ (i - 1) *
          (headProb ruleR1 α β 1 - ((α : ℝ) + β - 2 * α * β) / (2 - ((α : ℝ) + β))) +
        ((α : ℝ) + β - 2 * α * β) / (2 - ((α : ℝ) + β)) := by sorry

end RobbinsSeqDesign.StayOrSwitch
Source
Robbins, Some aspects of the sequential design of experiments, Bull. Amer. Math. Soc. 58 (1952), p. 530, Section 2, Eq. (3)
Human review
  • Endorsed by Shuze Chen · Oct 6, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 6, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me