@@ -3,6 +3,7 @@ Copyright (c) 2024 Yoh Tanimoto. All rights reserved.
3
3
Released under Apache 2.0 license as described in the file LICENSE.
4
4
Authors: Yoh Tanimoto
5
5
-/
6
+ import Mathlib.Algebra.Order.Module.PositiveLinearMap
6
7
import Mathlib.Topology.Algebra.Order.Support
7
8
import Mathlib.Topology.ContinuousMap.ZeroAtInfty
8
9
@@ -488,14 +489,42 @@ end SemilatticeInf
488
489
489
490
section Lattice
490
491
491
- instance [Lattice β] [TopologicalSpace β] [TopologicalLattice β] [Zero β] :
492
+ variable [TopologicalSpace β]
493
+
494
+ instance [Lattice β] [TopologicalLattice β] [Zero β] :
492
495
Lattice C_c(α, β) :=
493
496
DFunLike.coe_injective.lattice _ coe_sup coe_inf
494
497
498
+ instance instMulLeftMono [PartialOrder β] [MulZeroClass β] [ContinuousMul β] [MulLeftMono β] :
499
+ MulLeftMono C_c(α, β) :=
500
+ ⟨fun _ _ _ hg₁₂ x => mul_le_mul_left' (hg₁₂ x) _⟩
501
+
502
+ instance instMulRightMono [PartialOrder β] [MulZeroClass β] [ContinuousMul β] [MulRightMono β] :
503
+ MulRightMono C_c(α, β) :=
504
+ ⟨fun _ _ _ hg₁₂ x => mul_le_mul_right' (hg₁₂ x) _⟩
505
+
506
+ instance instAddLeftMono [PartialOrder β] [AddZeroClass β] [ContinuousAdd β] [AddLeftMono β] :
507
+ AddLeftMono C_c(α, β) :=
508
+ ⟨fun _ _ _ hg₁₂ x => add_le_add_left (hg₁₂ x) _⟩
509
+
510
+ instance instAddRightMono [PartialOrder β] [AddZeroClass β] [ContinuousAdd β] [AddRightMono β] :
511
+ AddRightMono C_c(α, β) :=
512
+ ⟨fun _ _ _ hg₁₂ x => add_le_add_right (hg₁₂ x) _⟩
513
+
495
514
-- TODO transfer this lattice structure to `BoundedContinuousFunction`
496
515
497
516
end Lattice
498
517
518
+ section IsOrderedAddMonoid
519
+
520
+ variable [TopologicalSpace β] [AddCommMonoid β] [ContinuousAdd β]
521
+ variable [PartialOrder β] [IsOrderedAddMonoid β]
522
+
523
+ instance : IsOrderedAddMonoid C_c(α, β) where
524
+ add_le_add_left _ _ hfg c := add_le_add_left hfg c
525
+
526
+ end IsOrderedAddMonoid
527
+
499
528
/-! ### `C_c` as a functor
500
529
501
530
For each `β` with sufficient structure, there is a contravariant functor `C_c(-, β)` from the
@@ -764,68 +793,83 @@ lemma nnrealPart_neg_toReal_eq (f : C_c(α, ℝ≥0)) : nnrealPart (-toReal f) =
764
793
section toNNRealLinear
765
794
766
795
/-- For a positive linear functional `Λ : C_c(α, ℝ) → ℝ`, define a `ℝ≥0`-linear map. -/
767
- noncomputable def toNNRealLinear (Λ : C_c(α, ℝ) →ₗ [ℝ] ℝ) (hΛ : ∀ f, 0 ≤ f → 0 ≤ Λ f ) :
796
+ noncomputable def toNNRealLinear (Λ : C_c(α, ℝ) →ₚ [ℝ] ℝ) :
768
797
C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 where
769
- toFun f := ⟨Λ (toRealLinearMap f), hΛ _ <| by simp⟩
798
+ toFun f := ⟨Λ (toRealLinearMap f), Λ.map_nonneg ( by simp) ⟩
770
799
map_add' f g := by ext; simp
771
800
map_smul' a f := by ext; simp [NNReal.smul_def]
772
801
773
802
@[simp]
774
- lemma toNNRealLinear_apply (Λ : C_c(α, ℝ) →ₗ [ℝ] ℝ) (hΛ ) (f : C_c(α, ℝ≥0 )) :
775
- toNNRealLinear Λ hΛ f = Λ (toReal f) := rfl
803
+ lemma toNNRealLinear_apply (Λ : C_c(α, ℝ) →ₚ [ℝ] ℝ) (f : C_c(α, ℝ≥0 )) :
804
+ toNNRealLinear Λ f = Λ (toReal f) := rfl
776
805
777
806
@[simp]
778
- lemma toNNRealLinear_inj (Λ₁ Λ₂ : C_c(α, ℝ) →ₗ [ℝ] ℝ) (hΛ₁ hΛ₂ ) :
779
- toNNRealLinear Λ₁ hΛ₁ = toNNRealLinear Λ₂ hΛ ₂ ↔ Λ₁ = Λ₂ := by
780
- simp only [LinearMap.ext_iff, NNReal.eq_iff, toNNRealLinear_apply]
781
- refine ⟨ fun h f ↦ ?_, fun h f ↦ by rw [LinearMap. ext h]⟩
807
+ lemma toNNRealLinear_inj (Λ₁ Λ₂ : C_c(α, ℝ) →ₚ [ℝ] ℝ) :
808
+ toNNRealLinear Λ₁ = toNNRealLinear Λ₂ ↔ Λ₁ = Λ₂ := by
809
+ refine ⟨ fun h ↦ ?_, fun h ↦ by rw [h]⟩
810
+ ext f
782
811
rw [← nnrealPart_sub_nnrealPart_neg f]
812
+ simp only [LinearMap.ext_iff, NNReal.eq_iff, toNNRealLinear_apply] at h
783
813
simp_rw [map_sub, h]
784
814
785
815
end toNNRealLinear
786
816
787
- section toRealLinear
788
-
789
- /-- For a positive linear functional `Λ : C_c(α, ℝ≥0) → ℝ≥0`, define a `ℝ`-linear map. -/
790
- noncomputable def toRealLinear (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) : C_c(α, ℝ) →ₗ[ℝ] ℝ where
791
- toFun := fun f => Λ (nnrealPart f) - Λ (nnrealPart (- f))
792
- map_add' f g := by
793
- simp only [neg_add_rev]
794
- obtain ⟨h, hh⟩ := exists_add_nnrealPart_add_eq f g
795
- rw [← add_zero ((Λ (f + g).nnrealPart).toReal - (Λ (-g + -f).nnrealPart).toReal),
796
- ← sub_self (Λ h).toReal, sub_add_sub_comm, ← NNReal.coe_add, ← NNReal.coe_add,
797
- ← LinearMap.map_add, ← LinearMap.map_add, hh.1 , add_comm (-g) (-f), hh.2 ]
798
- simp only [map_add, NNReal.coe_add]
799
- ring
800
- map_smul' a f := by
801
- rcases le_total 0 a with ha | ha
802
- · rw [RingHom.id_apply, smul_eq_mul, ← (smul_neg a f), nnrealPart_smul_pos f ha,
803
- nnrealPart_smul_pos (-f) ha]
804
- simp [sup_of_le_left ha, mul_sub]
805
- · simp only [RingHom.id_apply, smul_eq_mul, ← (smul_neg a f),
806
- nnrealPart_smul_neg f ha, nnrealPart_smul_neg (-f) ha, map_smul,
807
- NNReal.coe_mul, Real.coe_toNNReal', neg_neg, sup_of_le_left (neg_nonneg.mpr ha)]
808
- ring
809
-
810
- lemma toRealLinear_apply {Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 } (f : C_c(α, ℝ)) :
811
- toRealLinear Λ f = Λ (nnrealPart f) - Λ (nnrealPart (-f)) := rfl
812
-
813
- lemma toRealLinear_nonneg (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) (g : C_c(α, ℝ)) (hg : 0 ≤ g) :
814
- 0 ≤ toRealLinear Λ g := by
815
- simp [toRealLinear_apply, nnrealPart_neg_eq_zero_of_nonneg hg]
817
+ section toRealPositiveLinear
818
+
819
+ /-- For a positive linear functional `Λ : C_c(α, ℝ≥0) → ℝ≥0`, define a positive `ℝ`-linear map. -/
820
+ noncomputable def toRealPositiveLinear (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) : C_c(α, ℝ) →ₚ[ℝ] ℝ :=
821
+ PositiveLinearMap.mk₀
822
+ { toFun := fun f => Λ (nnrealPart f) - Λ (nnrealPart (- f))
823
+ map_add' f g := by
824
+ simp only [neg_add_rev]
825
+ obtain ⟨h, hh⟩ := exists_add_nnrealPart_add_eq f g
826
+ rw [← add_zero ((Λ (f + g).nnrealPart).toReal - (Λ (-g + -f).nnrealPart).toReal),
827
+ ← sub_self (Λ h).toReal, sub_add_sub_comm, ← NNReal.coe_add, ← NNReal.coe_add,
828
+ ← LinearMap.map_add, ← LinearMap.map_add, hh.1 , add_comm (-g) (-f), hh.2 ]
829
+ simp only [map_add, NNReal.coe_add]
830
+ ring
831
+ map_smul' a f := by
832
+ rcases le_total 0 a with ha | ha
833
+ · rw [RingHom.id_apply, smul_eq_mul, ← (smul_neg a f), nnrealPart_smul_pos f ha,
834
+ nnrealPart_smul_pos (-f) ha]
835
+ simp [sup_of_le_left ha, mul_sub]
836
+ · simp only [RingHom.id_apply, smul_eq_mul, ← (smul_neg a f),
837
+ nnrealPart_smul_neg f ha, nnrealPart_smul_neg (-f) ha, map_smul,
838
+ NNReal.coe_mul, Real.coe_toNNReal', neg_neg, sup_of_le_left (neg_nonneg.mpr ha)]
839
+ ring }
840
+ (fun g hg ↦ by simp [nnrealPart_neg_eq_zero_of_nonneg hg])
841
+
842
+ lemma toRealPositiveLinear_apply {Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 } (f : C_c(α, ℝ)) :
843
+ toRealPositiveLinear Λ f = Λ (nnrealPart f) - Λ (nnrealPart (-f)) := rfl
816
844
817
845
@[simp]
818
- lemma eq_toRealLinear_toReal (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) (f : C_c(α, ℝ≥0 )) :
819
- toRealLinear Λ (toReal f) = Λ f := by
820
- simp [toRealLinear_apply ]
846
+ lemma eq_toRealPositiveLinear_toReal (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) (f : C_c(α, ℝ≥0 )) :
847
+ toRealPositiveLinear Λ (toReal f) = Λ f := by
848
+ simp [toRealPositiveLinear_apply ]
821
849
822
850
@[simp]
823
- lemma eq_toNNRealLinear_toRealLinear (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) :
824
- toNNRealLinear (toRealLinear Λ) (toRealLinear_nonneg Λ) = Λ := by
851
+ lemma eq_toNNRealLinear_toRealPositiveLinear (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) :
852
+ toNNRealLinear (toRealPositiveLinear Λ) = Λ := by
825
853
ext f
826
854
simp
827
855
828
- end toRealLinear
856
+ @[deprecated (since := "2025-08-08")]
857
+ alias toRealLinear := toRealPositiveLinear
858
+
859
+ @[deprecated (since := "2025-08-08")]
860
+ alias toRealLinear_apply := toRealPositiveLinear_apply
861
+
862
+ @[deprecated map_nonneg (since := "2025-08-08")]
863
+ lemma toRealLinear_nonneg (Λ : C_c(α, ℝ≥0 ) →ₗ[ℝ≥0 ] ℝ≥0 ) (g : C_c(α, ℝ)) (hg : 0 ≤ g) :
864
+ 0 ≤ toRealPositiveLinear Λ g := map_nonneg _ hg
865
+
866
+ @[deprecated (since := "2025-08-08")]
867
+ alias eq_toRealLinear_toReal := eq_toRealPositiveLinear_toReal
868
+
869
+ @[deprecated (since := "2025-08-08")]
870
+ alias eq_toNNRealLinear_toRealLinear := eq_toNNRealLinear_toRealPositiveLinear
871
+
872
+ end toRealPositiveLinear
829
873
830
874
end CompactlySupportedContinuousMap
831
875
0 commit comments