chore_insertion_allocation
Given an implicit number of agents n, an agent sequence σ : ℕ → Fin n, costs c : Fin n → ℕ → ℝ, and m : ℕ, chore_insertion_allocation σ c m : Fin m → Fin n is the allocation assigning each chore d : Fin m to agent σ k, where k < m is the unique slot holding d under chore_insertion_slots σ c m (or 0 if none exists).
Statement
noncomputable def chore_insertion_allocation {n : ℕ} (σ : ℕ → Fin n) (c : Fin n → ℕ → ℝ) (m : ℕ) : Fin m → Fin n
- Defined in
- arXiv:2611.00432, Algorithm 1
- Verified
- 03 Nov 2026
- Axioms
- none listed
- Built on 1
- chore_insertion_slotsGiven an implicit number of agents n, an agent sequence σ : ℕ → Fin n, and costs c : Fin n → ℕ → ℝ, chore_insertion_slots m : ℕ → ℕ…
- Used by 1
- chore_insertion_upgrade_recourseFor any number of agents n : ℕ, picking sequence σ : ℕ → Fin n, and chore costs c : Fin n → ℕ → ℝ, chore insertion satisfies upgrade…
Read back from the Lean
A definition of chore_insertion_allocation, which takes:
- an implicit number of agents n : ℕ,
- a sequence of agents σ : ℕ → Fin n associating each slot/round index with an agent,
- a cost function c : Fin n → ℕ → ℝ specifying the cost c i j to agent i of chore j,
- a number of chores m : ℕ,
and produces an allocation Fin m → Fin n. For each chore d : Fin m, if there exists an index k < m such that chore_insertion_slots σ c m k = d.val, chore d is allocated to agent σ k (where k is selected via Classical.choose); otherwise, chore d is allocated to σ 0.
Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.
Lean source view module on GitHub
/-- The allocation at time m under chore insertion. -/ noncomputable def chore_insertion_allocation {n : ℕ} (σ : ℕ → Fin n) (c : Fin n → ℕ → ℝ) (m : ℕ) : Fin m → Fin n := fun d => σ (if h : ∃ k < m, chore_insertion_slots σ c m k = d.val then Classical.choose h else 0)