import YM.WilsonBulk.Solve.Ranks /-! # Appetite supplier for single- and dual-history propagation All previous costs enlargements polynomial in AGE. No transfer of mask tariffs. Use `Refill` with stage where `L` available at region post-pay. Calibration proof therefore still requires a pre-L ν, σ receipt (separate in `Land`). -/ set_option autoImplicit false noncomputable section namespace YM.WilsonBulk namespace Parapet.Shop open Function Filter Lattice Laurent RG Schedule Finset Precision Exterior Stationary Audience Recall Pert.Bulk Sheet Atelier Bloch Work.F08 open scoped Topology Classical ENNReal BigOperators variable {G : Gauge} {A : Levels G} {H : Horizon A} {ℓ i k n N N' e : ℕ} {x C θ δ : ℝ} {p q r : ℝ→ℝ} variable {U : Shop H} def refill (U : Shop H) (p : ℝ→ℝ) := fun x=>U.book x+p (x+U.book x) lemma refillCost (U : Shop H) (p : ℝ→ℝ) (h : Tariff p) : Tariff (refill U p):= U.ticket.add (h.composed (Tariff.one.add U.ticket)) lemma refilled (h : Tariff p) : Prizes U.book (refill U p) := prizes_right (h.composed (Tariff.one.add U.ticket)) lemma refill_orig (h : Tariff p) : Prizes p (refill U p) := by intro x hx; have ht := zero_le_one.trans hx; exact (h.2.1 x (x+U.book x) ht (le_add_of_nonneg_right (U.ticket.1 x ht))).trans (le_add_of_nonneg_left (U.ticket.1 x ht)) lemma refill_more (h : Prizes p q) : Prizes (refill U p) (refill U q):= by intro x hx; exact add_le_add_right (h _ (hx.trans (le_add_of_nonneg_right (U.ticket.1 x (zero_le_one.trans hx))))) _ namespace Land variable (h : Land U ℓ k x) include h lemma refill_neighbor (hp : Tariff p) (hi : ℓ ≤ i) : p (age A.S k x (i+1)) ≤ refill U p (age A.S k x i) := (hp.2.1 _ _ (zero_le_one.trans (h.wisdom _)) ((age_fade (k:=k) A.S i x).trans (add_le_add_right (h.sizes _ hi) _))).trans (le_add_of_nonneg_left (zero_le_one.trans (h.payload hi))) -- earlier grade receipts. cost pRefund majorizes both preflight and all requirements. At phase overlap use next step's δ ≥ current δ automatically; price C = announced cover growth at root. lemma past_income (hp : Tariff p) (hf : PriorGoods U p e n) (hi : ℓ ≤ i) (hN : i < N) (h' : N ≤ N') (ht : refill U p (age A.S k x i) ≤ C) : Intake (lawn (Cloth G)) (U.σ (i+1)) (U.fall (i+1) N) C (U.main N (i+1)) (U.main N' (i+1)) e n := fun j hj y hy hh hx=> ((hf j y ⟨hh,hj,hx⟩).1 ℓ k x h (i+1) N N' (by omega) hN h').more le_rfl ((h.refill_neighbor hp hi).trans ht) le_rfl lemma past_rest (hp : Tariff p) (hf : PriorGoods U p e n) (hi : ℓ ≤ i) (hN : i < N) (h' : N ≤ N') (ht : refill U p (age A.S k x i) ≤ C) : Rest (U.σ i) (U.fall (i+1) N) C e (U.raw N i) (U.raw N' i) := by intro j hj k'; by_cases he : k' ≤ j+2 · exact ((hf j k' ⟨he, hj.le,(by omega)⟩).2 ℓ k x h _ _ _ hi hN h').more (fall_ge h) ((refill_orig hp _ (h.wisdom i)).trans ht) le_rfl exact ((rankHuge U hp (lt_of_not_ge he)).2 ℓ k x h _ _ _ hi hN h').more (fall_ge h) ((refill_orig hp _ (h.wisdom i)).trans ht) le_rfl lemma Levied (hp : Tariff p) (hf : PriorGoods U p e (n+1)) (hi : ℓ ≤ i) (hN : i < N) (hs : G.Simple) (he : 0