Progress accounting on arbitrary finite routes. A progress step is an actual change of holdings by one improving bilateral transfer. Waiting steps are allowed, including arbitrarily many meetings that execute no trade.
Equations
- MindFormal.A595Trade.Improving N h h' = ∃ s ∈ h, ∃ b < N, b ∉ h ∧ s < b ∧ h' = MindFormal.A595Trade.transfer h s b
Instances For
Equations
- MindFormal.A595Trade.Protected N h = ∀ (m : ℕ), h (m + 1) = h m ∨ MindFormal.A595Trade.Improving N (h m) (h (m + 1))
Instances For
Equations
- MindFormal.A595Trade.progressCount h m = ∑ j ∈ Finset.range m, if h (j + 1) = h j then 0 else 1
Instances For
theorem
MindFormal.A595Trade.improving_range
{N : ℕ}
{h h' : Finset ℕ}
(hi : Improving N h h')
(hr : h ⊆ Finset.range N)
:
h' ⊆ Finset.range N
theorem
MindFormal.A595Trade.protected_valid
{N K : ℕ}
{h : ℕ → Finset ℕ}
(hp : Protected N h)
(hc : (h 0).card = K)
(hr : h 0 ⊆ Finset.range N)
(m : ℕ)
: