Documentation

LeanPool.FullyDynamicMatching.FD1D.MeasureBridge

Measure Bridge #

Finite laws as measures #

This file connects the project's elementary FiniteLaw API to Mathlib probability measures. It also transfers bounds indexed by a finite count state to arbitrary random spatial configurations having that count pushforward.

def FD1D.FiniteLaw.toPMF {α : Type u_1} [Fintype α] (μ : FiniteLaw α) :
PMF α

The probability mass function represented by a FiniteLaw.

Equations
Instances For
    @[simp]
    theorem FD1D.FiniteLaw.toPMF_apply {α : Type u_1} [Fintype α] (μ : FiniteLaw α) (x : α) :
    noncomputable def FD1D.FiniteLaw.toMeasure {α : Type u_1} [Fintype α] [MeasurableSpace α] (μ : FiniteLaw α) :

    The probability measure represented by a FiniteLaw.

    On a finite type it is enough to assume measurable singletons: this already makes every function from the type measurable.

    Equations
    Instances For
      @[simp]
      theorem FD1D.FiniteLaw.integral_toMeasure_eq_expect {α : Type u_1} [Fintype α] [MeasurableSpace α] [MeasurableSingletonClass α] (μ : FiniteLaw α) (f : α → ℝ) :
      ∫ (x : α), f x ∂μ.toMeasure = μ.expect f

      Integration against the associated measure is FiniteLaw.expect.

      Every real observable is integrable under a finite law's measure.

      theorem FD1D.FiniteLaw.integral_le_expect_of_map_eq {α : Type u_1} {Ω : Type u_3} [Fintype α] [MeasurableSpace α] [MeasurableSingletonClass α] [MeasurableSpace Ω] (P : MeasureTheory.Measure Ω) (μ : FiniteLaw α) (X : Ω → α) (cost : Ω → ℝ) (bound : α → ℝ) (hX : AEMeasurable X P) (hcost : MeasureTheory.Integrable cost P) (hpoint : ∀ᵐ (ω : Ω) ∂P, cost ω ≤ bound (X ω)) (hmap : MeasureTheory.Measure.map X P = μ.toMeasure) :
      ∫ (ω : Ω), cost ω ∂P ≤ μ.expect bound

      A generic pushforward bridge. If X has finite law μ, then any integrable random cost bounded by a state observable has expectation bounded by the corresponding FiniteLaw.expect.

      theorem FD1D.FiniteLaw.integral_le_of_map_eq_of_expect_le {α : Type u_1} {Ω : Type u_3} [Fintype α] [MeasurableSpace α] [MeasurableSingletonClass α] [MeasurableSpace Ω] (P : MeasureTheory.Measure Ω) (μ : FiniteLaw α) (X : Ω → α) (cost : Ω → ℝ) (bound : α → ℝ) (B : ℝ) (hX : AEMeasurable X P) (hcost : MeasureTheory.Integrable cost P) (hpoint : ∀ᵐ (ω : Ω) ∂P, cost ω ≤ bound (X ω)) (hmap : MeasureTheory.Measure.map X P = μ.toMeasure) (hbound : μ.expect bound ≤ B) :
      ∫ (ω : Ω), cost ω ∂P ≤ B

      A convenient final-bound form of integral_le_expect_of_map_eq.

      def FD1D.FiniteKernel.rowLaw {α : Type u_1} [Fintype α] (K : FiniteKernel α) (x : α) :

      The probability law represented by one row of a finite kernel.

      Equations
      • K.rowLaw x = { mass := K.trans x, mass_nonneg := ⋯, sum_mass := ⋯ }
      Instances For
        @[simp]
        theorem FD1D.FiniteKernel.rowLaw_mass {α : Type u_1} [Fintype α] (K : FiniteKernel α) (x y : α) :
        (K.rowLaw x).mass y = K.trans x y

        A project FiniteKernel, viewed as a Mathlib Markov kernel.

        Equations
        Instances For
          noncomputable def FD1D.HierarchicalDynamics.actualConfigurationCost {L m : ℕ} (a : ℝ) (hm : 0 < m) (C : SupplyConfiguration L m) :

          The actual one-period cost of a concrete spatial configuration.

          Equations
          Instances For
            theorem FD1D.HierarchicalDynamics.integral_actualConfigurationCost_le_expect {L m : ℕ} {Ω : Type u_1} [MeasurableSpace Ω] [MeasurableSpace (InventoryState (DyadicNode L) m)] [MeasurableSingletonClass (InventoryState (DyadicNode L) m)] (a : ℝ) (ha : 0 < a) (hm : 0 < m) (P : MeasureTheory.Measure Ω) (μ : FiniteLaw (InventoryState (DyadicNode L) m)) (C : Ω → SupplyConfiguration L m) (hstate : AEMeasurable (fun (ω : Ω) => (C ω).countState) P) (hcost : MeasureTheory.Integrable (fun (ω : Ω) => actualConfigurationCost a hm (C ω)) P) (hmap : MeasureTheory.Measure.map (fun (ω : Ω) => (C ω).countState) P = μ.toMeasure) :

            An arbitrary spatial law is bounded by the finite-law expectation of the canonical Haar pointwise majorant whenever its count-state pushforward is the given finite law.

            theorem FD1D.HierarchicalDynamics.stationary_actualConfigurationCost_equation_three {L m : ℕ} {Ω : Type u_1} [MeasurableSpace Ω] [MeasurableSpace (InventoryState (DyadicNode L) m)] [MeasurableSingletonClass (InventoryState (DyadicNode L) m)] (a : ℝ) (ha : 0 < a) (hm : 0 < m) (P : MeasureTheory.Measure Ω) (μ : FiniteLaw (InventoryState (DyadicNode L) m)) (C : Ω → SupplyConfiguration L m) (hstate : AEMeasurable (fun (ω : Ω) => (C ω).countState) P) (hcost : MeasureTheory.Integrable (fun (ω : Ω) => actualConfigurationCost a hm (C ω)) P) (hmap : MeasureTheory.Measure.map (fun (ω : Ω) => (C ω).countState) P = μ.toMeasure) (hμ : (kernel a ha hm).IsStationary μ) :
            ∫ (ω : Ω), actualConfigurationCost a hm (C ω) ∂P ≤ 1 / ↑(2 ^ L) + a / √6 * √((μ.expect fun (x : InventoryState (DyadicNode L) m) => stateHazardEnergy a x L) - 1 / ↑m ^ 2)

            Stationary equation (3) for an arbitrary random spatial configuration. Only the count pushforward is required to be stationary; configurations in the same count-state fiber may have any distribution.

            The stationary 6a/m result transferred from a finite count law to an arbitrary random law of actual spatial configurations.