Pathwise invariants of : supplier rule on , , , , and the continuation charge (Lemma 7)
ProvedOWMR.fifo_engine_invariantsFix a network satisfying the standing assumptions, a valid initial state , FIFO choices with and (no optimality is assumed), and a deterministic demand path . Write for retailer 's initial net inventory plus its prescribed pipeline, for the prescribed supplier pipeline, and . Let the activation flag be
the start rule of Appendix B. Let the aggregate position be
Let the request positions be before activation and in the first active period, and afterwards , where if and otherwise. (The statement quantifies over any functions satisfying these recursions; they are unique.) Then, for the supplier orders and dispatches of along , for all , and :
- ;
- warehouse stock is nonnegative, ;
- retailer 's position after dispatches, , satisfies ;
- ;
- (Lemma 7) with the pre-request position,
Items 3 and 4 are the queue invariants (23), with and ; item 5 is the continuation charge (26), with .
import Definitions.Def_owmr_fifo_policy open scoped ENNReal NNReal
namespace OWMR
theorem fifo_engine_invariants {n : ℕ} (N : Network n) (hN : N.Standing) (x : InitState n)
(hx : x.Valid) (c : FIFOChoice n) (hsS : ∀ i, c.s i ≤ c.S i) (hs0 : c.s0 ≤ c.S0)
(d : ℕ → DemandVec n) (act : ℕ → Prop) [DecidablePred act]
(hact : ∀ t, act t ↔ (N.Tpipe ≤ t + 1 ∧ ∀ i, x.I i + ∑ s ∈ Finset.range (N.L i), x.retPipe i s
- ∑ s ∈ Finset.range t, ((d s i : ℝ≥0) : ℝ) ≤ c.S i))
(Yp : ℕ → ℝ)
(hY0 : Yp 0 = x.W + ∑ s ∈ Finset.range N.L0, x.supPipe s
+ ∑ i, (x.I i + ∑ s ∈ Finset.range (N.L i), x.retPipe i s - c.a i))
(hY : ∀ t, Yp (t + 1) = (if act t ∧ Yp t ≤ c.s0 then c.S0 else Yp t)
- ∑ i, ((d t i : ℝ≥0) : ℝ))
(Ph : ℕ → Fin n → ℝ)
(hPh0 : ∀ i, Ph 0 i = if act 0 then c.S i else x.I i + ∑ s ∈ Finset.range (N.L i), x.retPipe i s)
(hPh : ∀ t i, Ph (t + 1) i = if act (t + 1) then
(if act t then (if Ph t i - ((d t i : ℝ≥0) : ℝ) ≤ c.s i then c.S i
else Ph t i - ((d t i : ℝ≥0) : ℝ)) else c.S i)
else x.I i + ∑ s ∈ Finset.range (N.L i), x.retPipe i s
- ∑ s ∈ Finset.range (t + 1), ((d s i : ℝ≥0) : ℝ)) :
(∀ t, (fifoPolicy N x c).toPolicy.order t () d
= if act t ∧ Yp t ≤ c.s0 then c.S0 - Yp t else 0) ∧
(∀ t, 0 ≤ Policy.whStock N x (fifoPolicy N x c).toPolicy () d t) ∧
(∀ t i, x.I i + ∑ s ∈ Finset.range (N.L i), x.retPipe i s
+ ∑ r ∈ Finset.range (t + 1), (fifoPolicy N x c).toPolicy.dispatch r () d i
- ∑ r ∈ Finset.range t, ((d r i : ℝ≥0) : ℝ) ≤ Ph t i) ∧
(∀ t, Policy.whStock N x (fifoPolicy N x c).toPolicy () d t
* ∑ i, (Ph t i - (x.I i + ∑ s ∈ Finset.range (N.L i), x.retPipe i s
+ ∑ r ∈ Finset.range (t + 1), (fifoPolicy N x c).toPolicy.dispatch r () d i
- ∑ r ∈ Finset.range t, ((d r i : ℝ≥0) : ℝ))) = 0) ∧
(∀ T, ∑ t ∈ Finset.range T, ∑ i, N.K i
* (if 0 < (fifoPolicy N x c).toPolicy.dispatch t () d i then 1 else 0)
≤ ∑ t ∈ Finset.range T, (if 0 < t ∧ act (t - 1) then ∑ i, N.K i
* (if Ph (t - 1) i - ((d (t - 1) i : ℝ≥0) : ℝ) ≤ c.s i
∧ Ph (t - 1) i - ((d (t - 1) i : ℝ≥0) : ℝ) < c.S i then 1 else 0) else 0)
+ N.Kmax * (n + N.L0 + ∑ t ∈ Finset.range T,
(if 0 < (fifoPolicy N x c).toPolicy.order t () d then 1 else 0))) := by sorry
end OWMR