AFTD Auto-Formalizing Theoretical Domains

OnlineLearning.arbitraryMixedStrategy

defimported Lean

A concrete mixed strategy used only to prove that the type of mixed strategies is nonempty. It puts all mass on one arbitrary action.

Statement

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
open Real Finset BigOperators in
noncomputable def OnlineLearning.arbitraryMixedStrategy (n : ℕ) [NeZero n] : MixedStrategy n
Defined in
TCSlib, `OnlineLearning.arbitraryMixedStrategy`
Lean proof
By Karim Abdel Sadek, Mark Bedaywi, from github.com/Shilun-Allan-Li/tcslib at c8a02591b1e5 (Copyright (c) 2026 Karim Abdel Sadek and Mark Bedaywi. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.25.0.
Verified
07 Oct 2026
Axioms
none listed
Built on 1
  • MixedStrategyA mixed strategy over $n$ actions is a record consisting of a weight function $w : \mathrm{Fin}\,n \to \mathbb{R}$ together with…
Used by 1

Lean source view module on GitHub

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
open Real Finset BigOperators in
/-- A concrete mixed strategy used only to prove that the type of mixed strategies is nonempty. It puts all mass on one arbitrary action. -/
noncomputable def OnlineLearning.arbitraryMixedStrategy (n : ℕ) [NeZero n] : MixedStrategy n where
  weights i := if i = Classical.choice inferInstance then 1 else 0
  nonneg i := by
    split <;> positivity
  sum_one := by
    classical
    let i₀ : Fin n := Classical.choice inferInstance
    change ∑ i : Fin n, (if i = i₀ then (1 : ℝ) else 0) = 1
    rw [Finset.sum_eq_single i₀]
    · simp
    · intro b _ hb
      simp [hb]
    · intro h
      exact False.elim (h (Finset.mem_univ _))
See it in the graphDiscuss this resultChallenge it