Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

(7): under Assumption B, the average total cost 1L+1∑iSR(i)\frac{1}{L+1}\sum_i S_R(i)L+11​∑i​SR​(i) is a cycle cost of the chain with the adjoined state −1-1−1

Proved
DermanSeqDecisions.LinProg.total_cost_eq_cycle

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

markov-decision-processp2o-batch-pfp1ap2o-gran-per-chapterp2o-plan-paperp2o-v1taboo-probabilitytotal-cost

Consider Problem 2: stochastic chance laws qij(k)q_{ij}(k)qij​(k) on {0,…,L}\{0, \dots, L\}{0,…,L}, the state LLL absorbing under every decision, wLk=0w_{Lk} = 0wLk​=0, wik>0w_{ik} > 0wik​>0 for i≠Li \ne Li=L, and Assumption B: for every procedure of C′C'C′, the state LLL is reached from every state with probability 111. Adjoin the state −1-1−1, from which the chain moves to each of 0,…,L0, \dots, L0,…,L with probability 1/(L+1)1/(L+1)1/(L+1), and send LLL to −1-1−1 with probability 111; set w−1,k=0w_{-1,k} = 0w−1,k​=0.

Let D∈C′D \in C'D∈C′, extended to −1-1−1 by any decision probabilities, let π\piπ be a stationary distribution of the augmented chain, and put f(j)=∑kDjkwjkf(j) = \sum_k D_{jk} w_{jk}f(j)=∑k​Djk​wjk​ (so f(−1)=0f(-1) = 0f(−1)=0). Then π−1>0\pi_{-1} > 0π−1​>0, the taboo series converge, and

1L+1∑i=0LSR(i)=∑t=0∞∑j=−1L−1p−1,j(t) f(j)=1π−1∑j=−1Lπjf(j).\frac{1}{L+1}\sum_{i=0}^{L} S_R(i) = \sum_{t=0}^{\infty}\sum_{j=-1}^{L} {}_{-1}p^{(t)}_{-1,j}\, f(j) = \frac{1}{\pi_{-1}}\sum_{j=-1}^{L} \pi_j f(j).L+11​i=0∑L​SR​(i)=t=0∑∞​j=−1∑L​−1​p−1,j(t)​f(j)=π−1​1​j=−1∑L​πj​f(j).

This turns the average of the total costs into a ratio of two linear functions of the state-action frequencies, which is the program (9).

Formalization Note. L+1L+1L+1 is the number of original states. Assumption B is stated as reachability of LLL from every state (∃t, piL(t)>0\exists t,\ p^{(t)}_{iL} > 0∃t, piL(t)​>0); for a finite chain in which LLL is absorbing this is equivalent to absorption with probability 111. The paper assumes wik>0w_{ik} > 0wik​>0 (p. 17) and wLk=0w_{Lk} = 0wLk​=0 in Problem 2; the consistent reading wik>0w_{ik} > 0wik​>0 for i≠Li \ne Li=L is used. SR(i)S_R(i)SR​(i) takes values in [0,∞][0, \infty][0,∞]; the right-hand sides are nonnegative reals.

Preamble
import Mathlib
import Definitions.Def_JewellMRP_InfiniteStep_Model
import Definitions.Def_DermanSeqDecisions_LinProg_Model

open Matrix

open scoped ENNReal
Formal statement
namespace DermanSeqDecisions.LinProg

/-- (7), p. 21 (Derman, *On Sequential Decisions and Markov Chains*, Management Science 9(1):16–24 (1962), DOI 10.1287/mnsc.9.1.16, §3, proof of Theorem 2, display (7)).

Problem 2 under Assumption B: the chance laws are stochastic, `L` is absorbing under every decision,
`w_{Lk} = 0`, `w_{ik} > 0` for `i ≠ L`, and for every procedure of `C′` the state `L` is
reachable from every state. Adjoin the state `−1` (`none`) as on p. 21. For every `D ∈ C′`
(extended to `−1` by any decision probabilities `D₀`) and every stationary vector `π` of the
augmented chain `P`, with `f(j) = ∑_k D_{jk} w_{jk}` (`f(−1) = 0`):
`π_{−1} > 0`, the taboo probabilities `_{−1}p^{(t)}_{−1,j}` are summable in `t`, and
$$\frac{1}{L+1}\sum_{i=0}^{L} S_R(i) = \sum_{t=0}^{\infty}\sum_{j=-1}^{L} {}_{-1}p^{(t)}_{-1,j} f(j)
  = \frac{1}{\pi_{-1}}\sum_{j=-1}^{L}\pi_j f(j).$$

**Formalization Note.** `L + 1` is `Fintype.card S`. Assumption B ("`L` is accessible from
`0, ⋯, L − 1` within a finite number of transitions with probability 1") is stated as
reachability, `∀ i, ∃ t, 0 < (P_D^t)_{iL}`: for a finite chain in which `L` is absorbing,
reaching `L` with probability 1 from every state is equivalent to `L` being reachable from every
state. The paper states `w_{ik} > 0` on p. 17 and `w_{Lk} = 0` in Problem 2; the consistent reading
`w_{ik} > 0` for `i ≠ L` is used. `S_R(i)` is `totalCost` in `ℝ≥0∞`; the right-hand sides are
nonnegative reals. -/
theorem total_cost_eq_cycle {S Act : Type*} [Fintype S] [DecidableEq S] [Fintype Act]
    (q : S → Act → S → ℝ) (w : S → Act → ℝ) (L : S) (hq : IsTransitionLaw q)
    (hL : ∀ a, q L a L = 1) (hwL : ∀ a, w L a = 0) (hw : ∀ i a, i ≠ L → 0 < w i a)
    (hB : ∀ D : S → Act → ℝ, IsStationaryRandomized D → ∀ i, ∃ t : ℕ, 0 < (chainMatrix q D ^ t) i L)
    (D : S → Act → ℝ) (hD : IsStationaryRandomized D)
    (D₀ : Act → ℝ) (hD₀ : (∀ a, 0 ≤ D₀ a) ∧ ∑ a, D₀ a = 1)
    (π : Option S → ℝ)
    (hπ : JewellMRP.InfiniteStep.IsStationary (chainMatrix (augLaw q L) (augProc D D₀)) π) :
    0 < π none ∧
    (∀ j, Summable (fun t : ℕ => tabooProb (chainMatrix (augLaw q L) (augProc D D₀)) none t j)) ∧
    (1 / (Fintype.card S : ℝ≥0∞)) * ∑ i, totalCost q w D i =
      ENNReal.ofReal (∑' t : ℕ, ∑ j, tabooProb (chainMatrix (augLaw q L) (augProc D D₀)) none t j *
        ∑ a, augProc D D₀ j a * augCost w j a) ∧
    ∑' t : ℕ, ∑ j, tabooProb (chainMatrix (augLaw q L) (augProc D D₀)) none t j *
        ∑ a, augProc D D₀ j a * augCost w j a =
      (1 / π none) * ∑ j, π j * ∑ a, augProc D D₀ j a * augCost w j a := by sorry

end DermanSeqDecisions.LinProg
Source
Derman, On Sequential Decisions and Markov Chains, Management Science 9(1):16–24 (1962), DOI 10.1287/mnsc.9.1.16, p. 21, §3, proof of Theorem 2, display (7)
Human review
  • Endorsed by Shuze Chen · Oct 4, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 4, 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