Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

THEOREM 2, p. 986 — under (i), (ii), (v), 0 < λ < ∞ and finite G⁺, G⁻: G and H exist and H = λG

Proved
HeymanStidham.HLG.theorem_2

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

h-equals-lambda-glittle-lawp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1queueingsample-path

Let 0≤t1≤t2≤⋯0 \le t_1 \le t_2 \le \cdots0≤t1​≤t2​≤⋯ be the arrival epochs of customers 1,2,…1, 2, \ldots1,2,…, and N(t)N(t)N(t) the number of nnn with tn≤tt_n \le ttn​≤t. Customer nnn carries a real-valued (possibly negative) function fnf_nfn​ on [0,∞)[0,\infty)[0,∞). Write fn+=max⁡[0,fn]f_n^+ = \max[0, f_n]fn+​=max[0,fn​], fn−=max⁡[0,−fn]f_n^- = \max[0, -f_n]fn−​=max[0,−fn​], gn=∫0∞fn dtg_n = \int_0^\infty f_n\,dtgn​=∫0∞​fn​dt, gn±=∫0∞fn± dtg_n^\pm = \int_0^\infty f_n^\pm\,dtgn±​=∫0∞​fn±​dt and h(t)=∑n=1∞fn(t)h(t) = \sum_{n=1}^\infty f_n(t)h(t)=∑n=1∞​fn​(t). Assume that for each nnn there is sn∈[0,∞)s_n \in [0,\infty)sn​∈[0,∞) such that

  1. (i) fn(t)=0f_n(t) = 0fn​(t)=0 for t∉[tn,tn+sn]t \notin [t_n, t_n + s_n]t∈/[tn​,tn​+sn​];
  2. (ii) sn/n→0s_n/n \to 0sn​/n→0;
  3. (v) ∫0∞∣fn(t)∣ dt<∞\int_0^\infty |f_n(t)|\,dt < \infty∫0∞​∣fn​(t)∣dt<∞.

If λ=lim⁡t→∞N(t)/t\lambda = \lim_{t\to\infty} N(t)/tλ=limt→∞​N(t)/t, G+=lim⁡N1N∑n=1Ngn+G^+ = \lim_N \frac1N\sum_{n=1}^N g_n^+G+=limN​N1​∑n=1N​gn+​ and G−=lim⁡N1N∑n=1Ngn−G^- = \lim_N \frac1N\sum_{n=1}^N g_n^-G−=limN​N1​∑n=1N​gn−​ exist, with 0<λ<∞0 < \lambda < \infty0<λ<∞, G+<∞G^+ < \inftyG+<∞ and G−<∞G^- < \inftyG−<∞, then G=lim⁡N1N∑n=1NgnG = \lim_N \frac1N\sum_{n=1}^N g_nG=limN​N1​∑n=1N​gn​ exists and equals G+−G−G^+ - G^-G+−G−, H=lim⁡T→∞1T∫0Th(t) dtH = \lim_{T\to\infty} \frac1T\int_0^T h(t)\,dtH=limT→∞​T1​∫0T​h(t)dt exists, and

H=λG.(1)H = \lambda G. \tag{1}H=λG.(1)

This is the main result of the paper: a sample-path relation between the time average of hhh and the customer average of the gng_ngn​, valid for signed fnf_nfn​ under the mild support condition (i)–(ii). It contains Theorem 1 (fn≥0f_n \ge 0fn​≥0) and Little's law L=λWL = \lambda WL=λW.

Formalization Note The statement is about one fixed sample path; the paper's "with probability one" is this statement applied to almost every path. Customers are 0-based in Lean, so (ii) reads sn/(n+1)→0s_n/(n+1) \to 0sn​/(n+1)→0; ties between arrival epochs are allowed. (v) is integrability of fnf_nfn​ on [0,∞)[0,\infty)[0,∞). The page's (1) speaks of GGG, which the hypotheses do not give directly; its existence and value G+−G−G^+ - G^-G+−G− (shown in the proof, display (6)) are the first part of the conclusion. "HHH exists" includes integrability of hhh on every [0,T][0,T][0,T], so a non-integrable hhh cannot have "time average" 000. hhh is the full infinite sum over all customers. N(t)N(t)N(t) is the cardinality of {n:tn≤t}\{n : t_n \le t\}{n:tn​≤t}, finite because λ>0\lambda > 0λ>0.

Preamble
import Mathlib
import Definitions.Def_HeymanStidham_HLG_Setting

open Filter Topology MeasureTheory
Formal statement
namespace HeymanStidham.HLG

/-- THEOREM 2, p. 986: under (i), (ii) and (v) `∫₀^∞ |fₙ| < ∞`, if `λ`, `G⁺`, `G⁻` exist
with `0 < λ < ∞` and `G⁺, G⁻ < ∞`, then `G = G⁺ − G⁻` exists, `H` exists, and
`H = λG` (1). -/
theorem theorem_2 (t : ℕ → ℝ) (ht : Monotone t) (ht0 : 0 ≤ t 0)
    (f : ℕ → ℝ → ℝ) (s : ℕ → ℝ) (hI : CondI t f s) (hII : CondII s)
    (lam : ℝ) (hlam : 0 < lam) (hrate : IsArrivalRate t lam)
    (hv : ∀ n, IntegrableOn (f n) (Set.Ici 0))
    (Gp Gm : ℝ)
    (hGp : IsCustomerAverage (custTotal (posPartFn f)) Gp)
    (hGm : IsCustomerAverage (custTotal (negPartFn f)) Gm) :
    IsCustomerAverage (custTotal f) (Gp - Gm) ∧
      IsTimeAverage (rate f) (lam * (Gp - Gm)) := by sorry

end HeymanStidham.HLG
Source
Heyman and Stidham, The relation between customer and time averages in queues, Oper. Res. 28 (1980), p. 986, THEOREM 2, with display (1) (p. 985) and (6) (p. 986)
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