Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 4 — HHH is increasing and convex on [0,∞)[0,\infty)[0,∞) with asymptotic slope hp/(h+p)hp/(h + p)hp/(h+p)

Proved
ZhengQR.EOQHeuristic.hFun_props

by mikedeng1 · Sep 27, 2026 · Mathlib 0df444a (Lean v4.33.1)

convexityinventoryp2o-batch-p100ap2o-gran-per-chapterp2o-plan-paperp2o-v1qr-policy

In the stochastic (Q,r)(Q, r)(Q,r) model (as in Lemma 2, with K>0K > 0K>0), let H(Q)=G(r(Q))H(Q) = G(r(Q))H(Q)=G(r(Q)) for Q>0Q > 0Q>0 and H(0)=G(y0)H(0) = G(y^0)H(0)=G(y0). Then

  1. HHH is strictly increasing on [0,∞)[0, \infty)[0,∞);
  2. HHH is convex on [0,∞)[0, \infty)[0,∞);
  3. HHH is right-continuous at 000, i.e. lim⁡Q→0+G(r(Q))=G(y0)\lim_{Q \to 0^+} G(r(Q)) = G(y^0)limQ→0+​G(r(Q))=G(y0);
  4. every chord of HHH on [0,∞)[0,\infty)[0,∞) has slope at most hp/(h+p)hp/(h+p)hp/(h+p): for 0≤Q<Q′0 \le Q < Q'0≤Q<Q′,
H(Q′)−H(Q)≤hph+p (Q′−Q);H(Q') - H(Q) \le \frac{hp}{h+p}\,(Q' - Q);H(Q′)−H(Q)≤h+php​(Q′−Q);
lim⁡Q→∞H(Q)Q=hph+p.\lim_{Q \to \infty} \frac{H(Q)}{Q} = \frac{hp}{h+p}.Q→∞lim​QH(Q)​=h+php​.

The paper states: "H(Q)H(Q)H(Q) is an increasing convex function with asymptotic slope hp/(h+p)hp/(h+p)hp/(h+p) as Q↑∞Q \uparrow \inftyQ↑∞". The slope hp/(h+p)hp/(h+p)hp/(h+p) is exactly the slope of the EOQ model's counterpart HdH_dHd​, which makes this lemma the basis of every comparison between the two models.

Formalization Note "Increasing" is read as strictly increasing (the proof shows H′>0H' > 0H′>0). "Asymptotic slope hp/(h+p)hp/(h+p)hp/(h+p)" is read as items 4 and 5: the proof shows H′(Q)↑hp/(h+p)H'(Q) \uparrow hp/(h+p)H′(Q)↑hp/(h+p), and later proofs use it as the bound H′(Q)≤hp/(h+p)H'(Q) \le hp/(h+p)H′(Q)≤hp/(h+p); for a convex HHH without assumed differentiability, the chord bound plus the limit of H(Q)/QH(Q)/QH(Q)/Q express exactly this. Item 3 is the content of the paper's "H(0)=deflim⁡Q→0+G(r(Q))=G(y0)H(0) \stackrel{\text{def}}{=} \lim_{Q\to0+} G(r(Q)) = G(y^0)H(0)=deflimQ→0+​G(r(Q))=G(y0)" (p. 91), since here H(0)H(0)H(0) is defined as G(y0)G(y^0)G(y0).

Preamble
import Mathlib
import Definitions.Def_ZhengQR_EOQHeuristic_qrCost
import Definitions.Def_ZhengQR_EOQHeuristic_costCurves
import Definitions.Def_ZhengQR_EOQHeuristic_stochasticModel
open MeasureTheory Filter Topology
Formal statement
namespace ZhengQR.EOQHeuristic

theorem hFun_props {lam L K h p : ℝ} {μ : Measure ℝ} (hM : IsQRModel lam L h p μ) (hK : 0 < K) :
    StrictMonoOn (hFun (newsvendorCost μ h p) lam K) (Set.Ici 0) ∧
    ConvexOn ℝ (Set.Ici 0) (hFun (newsvendorCost μ h p) lam K) ∧
    ContinuousWithinAt (hFun (newsvendorCost μ h p) lam K) (Set.Ici 0) 0 ∧
    (∀ Q Q' : ℝ, 0 ≤ Q → Q < Q' → hFun (newsvendorCost μ h p) lam K Q' - hFun (newsvendorCost μ h p) lam K Q ≤ h * p / (h + p) * (Q' - Q)) ∧
    Tendsto (fun Q : ℝ => hFun (newsvendorCost μ h p) lam K Q / Q) atTop (𝓝 (h * p / (h + p))) := by sorry

end ZhengQR.EOQHeuristic
Source
Zheng, On Properties of Stochastic Inventory Systems, Management Science 38(1), 1992, p. 91, Lemma 4 (and the definition of H(0) under Eq. (6))
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

Setting. Let λ,L,K,h,p\lambda, L, K, h, pλ,L,K,h,p be real numbers and μ\muμ a measure on R\mathbb{R}R. Assume the model hypotheses:

  • λ,L,h,p>0\lambda, L, h, p > 0λ,L,h,p>0;
  • μ\muμ is a probability measure with finite first moment and mean λL\lambda LλL;
  • μ\muμ is concentrated on x≥0x\ge0x≥0 almost everywhere;
  • G(y)=∫(h(y−x)++p(x−y)+) dμ(x)G(y) = \int \big(h(y-x)^+ + p(x-y)^+\big)\,d\mu(x)G(y)=∫(h(y−x)++p(x−y)+)dμ(x) has a unique global minimizer, called y0y^0y0.

Assume also K>0K > 0K>0.

Notation.

  • r(Q)r(Q)r(Q) is a chosen minimizer over real rrr of (λK+∫rr+QG)/Q\big(\lambda K + \int_r^{r+Q} G\big)/Q(λK+∫rr+Q​G)/Q, or 000 if none exists.
  • H(Q)=G(r(Q))H(Q) = G(r(Q))H(Q)=G(r(Q)) for Q>0Q > 0Q>0, and H(Q)=G(y0)H(Q) = G(y^0)H(Q)=G(y0) for Q≤0Q \le 0Q≤0.

Claim. All five of the following hold:

  1. HHH is strictly increasing on [0,∞)[0,\infty)[0,∞): if 0≤Q<Q′0 \le Q < Q'0≤Q<Q′ then H(Q)<H(Q′)H(Q) < H(Q')H(Q)<H(Q′).
  2. HHH is convex on [0,∞)[0,\infty)[0,∞).
  3. HHH is continuous at 000 from the right: H(Q)→H(0)=G(y0)H(Q) \to H(0) = G(y^0)H(Q)→H(0)=G(y0) as Q→0Q \to 0Q→0 with Q≥0Q \ge 0Q≥0.
  4. For all Q,Q′Q, Q'Q,Q′ with 0≤Q<Q′0 \le Q < Q'0≤Q<Q′:
H(Q′)−H(Q)  ≤  hph+p (Q′−Q).H(Q') - H(Q) \;\le\; \frac{hp}{h+p}\,(Q'-Q).H(Q′)−H(Q)≤h+php​(Q′−Q).
  1. The ratio has a limit at infinity:
lim⁡Q→+∞H(Q)Q  =  hph+p.\lim_{Q\to+\infty} \frac{H(Q)}{Q} \;=\; \frac{hp}{h+p}.Q→+∞lim​QH(Q)​=h+php​.

Degenerate cases. Items 1, 2 and 4 include Q=0Q = 0Q=0, where HHH takes the value G(y0)G(y^0)G(y0). Values for Q<0Q<0Q<0 are not constrained. Since h,p>0h,p>0h,p>0, the constant hp/(h+p)hp/(h+p)hp/(h+p) involves no division by zero. The hypotheses can all hold, for example with μ\muμ the point mass at λL\lambda LλL.

Human review
  • Endorsed by Shuze Chen · Sep 27, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Sep 27, 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