l3lab/ntp-mathlib huggingface dataset:
@[to_additive]
theorem innerContent_pos_of_is_mul_left_invariant [T2Space G] [Group G] [TopologicalGroup G]
    (h3 : ∀ (g : G) {K : Compacts G}, μ (K.map _ <| continuous_mul_left g) = μ K) (K : Compacts G)
    (hK : μ K ≠ 0) (U : Opens G) (hU : (U : Set G).Nonempty) : 0 < μ.innerContent U := by
  have : (interior (U : Set G)).Nonempty
  rwa [U.isOpen.interior_eq]
  rcases compact_covered_by_mul_left_translates K.2 this with ⟨s, hs⟩
  suffices μ K ≤ s.card * μ.innerContent U by
    exact (ENNReal.mul_pos_iff.mp <| hK.bot_lt.trans_le this).2
  have : (K : Set G) ⊆ ↑(⨆ g ∈ s, Opens.comap (Homeomorph.mulLeft g).toContinuousMap U) := by
    simpa only [Opens.iSup_def, Opens.coe_comap, Subtype.coe_mk]
  refine' (μ.le_innerContent _ _ this).trans _
  refine'
    (rel_iSup_sum μ.innerContent μ.innerContent_bot (· ≤ ·) μ.innerContent_iSup_nat _ _).trans _
  

Proof state:
case intro
G : Type w
inst✝³ : TopologicalSpace G
μ : Content G
inst✝² : T2Space G
inst✝¹ : Group G
inst✝ : TopologicalGroup G
h3 :
  ∀ (g : G) {K : Compacts G},
    (fun s => ↑(toFun μ s)) (Compacts.map (fun b => g * b) (_ : Continuous fun b => g * b) K) =
      (fun s => ↑(toFun μ s)) K
K : Compacts G
hK : (fun s => ↑(toFun μ s)) K ≠ 0
U : Opens G
hU : Set.Nonempty ↑U
this✝ : Set.Nonempty (interior ↑U)
s : Finset G
hs : K.carrier ⊆ ⋃ g ∈ s, (fun x => g * x) ⁻¹' ↑U
this : ↑K ⊆ ↑(⨆ g ∈ s, (Opens.comap (Homeomorph.toContinuousMap (Homeomorph.mulLeft g))) U)
⊢ (Finset.sum s fun d => innerContent μ ((Opens.comap (Homeomorph.toContinuousMap (Homeomorph.mulLeft d))) U)) ≤
    ↑(Finset.card s) * innerContent μ U

Next tactic:
simp only [μ.is_mul_left_invariant_innerContent h3, Finset.sum_const, nsmul_eq_mul, le_refl]
theorem le_outerMeasure_compacts (K : Compacts G) : μ K ≤ μ.outerMeasure K := by
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
K : Compacts G
⊢ (fun s => ↑(toFun μ s)) K ≤ ↑(Content.outerMeasure μ) ↑K

Next tactic:
rw [Content.outerMeasure, inducedOuterMeasure_eq_iInf]
theorem le_outerMeasure_compacts (K : Compacts G) : μ K ≤ μ.outerMeasure K := by
  rw [Content.outerMeasure, inducedOuterMeasure_eq_iInf]
  · 

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
K : Compacts G
⊢ (fun s => ↑(toFun μ s)) K ≤ ⨅ t, ⨅ (ht : IsOpen t), ⨅ (_ : ↑K ⊆ t), innerContent μ { carrier := t, is_open' := ht }

Next tactic:
exact le_iInf fun U => le_iInf fun hU => le_iInf <| μ.le_innerContent K ⟨U, hU⟩
theorem le_outerMeasure_compacts (K : Compacts G) : μ K ≤ μ.outerMeasure K := by
  rw [Content.outerMeasure, inducedOuterMeasure_eq_iInf]
  · exact le_iInf fun U => le_iInf fun hU => le_iInf <| μ.le_innerContent K ⟨U, hU⟩
  · 

Proof state:
case PU
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
K : Compacts G
⊢ ∀ ⦃f : ℕ → Set G⦄, (∀ (i : ℕ), IsOpen (f i)) → IsOpen (⋃ i, f i)

Next tactic:
exact fun U hU => isOpen_iUnion hU
theorem le_outerMeasure_compacts (K : Compacts G) : μ K ≤ μ.outerMeasure K := by
  rw [Content.outerMeasure, inducedOuterMeasure_eq_iInf]
  · exact le_iInf fun U => le_iInf fun hU => le_iInf <| μ.le_innerContent K ⟨U, hU⟩
  · exact fun U hU => isOpen_iUnion hU
  · 

Proof state:
case msU
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
K : Compacts G
⊢ ∀ ⦃f : ℕ → Set G⦄ (hm : ∀ (i : ℕ), IsOpen (f i)),
    innerContent μ { carrier := ⋃ i, f i, is_open' := (_ : IsOpen (⋃ i, (fun i => f i) i)) } ≤
      ∑' (i : ℕ), innerContent μ { carrier := f i, is_open' := (_ : IsOpen (f i)) }

Next tactic:
exact μ.innerContent_iUnion_nat
theorem le_outerMeasure_compacts (K : Compacts G) : μ K ≤ μ.outerMeasure K := by
  rw [Content.outerMeasure, inducedOuterMeasure_eq_iInf]
  · exact le_iInf fun U => le_iInf fun hU => le_iInf <| μ.le_innerContent K ⟨U, hU⟩
  · exact fun U hU => isOpen_iUnion hU
  · exact μ.innerContent_iUnion_nat
  · 

Proof state:
case m_mono
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
K : Compacts G
⊢ ∀ ⦃s₁ s₂ : Set G⦄ (hs₁ : IsOpen s₁) (hs₂ : IsOpen s₂),
    s₁ ⊆ s₂ → innerContent μ { carrier := s₁, is_open' := hs₁ } ≤ innerContent μ { carrier := s₂, is_open' := hs₂ }

Next tactic:
exact μ.innerContent_mono
theorem outerMeasure_exists_compact {U : Opens G} (hU : μ.outerMeasure U ≠ ∞) {ε : ℝ≥0}
    (hε : ε ≠ 0) : ∃ K : Compacts G, (K : Set G) ⊆ U ∧ μ.outerMeasure U ≤ μ.outerMeasure K + ε := by
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
U : Opens G
hU : ↑(Content.outerMeasure μ) ↑U ≠ ⊤
ε : ℝ≥0
hε : ε ≠ 0
⊢ ∃ K, ↑K ⊆ ↑U ∧ ↑(Content.outerMeasure μ) ↑U ≤ ↑(Content.outerMeasure μ) ↑K + ↑ε

Next tactic:
rw [μ.outerMeasure_opens] at hU ⊢
theorem outerMeasure_exists_compact {U : Opens G} (hU : μ.outerMeasure U ≠ ∞) {ε : ℝ≥0}
    (hε : ε ≠ 0) : ∃ K : Compacts G, (K : Set G) ⊆ U ∧ μ.outerMeasure U ≤ μ.outerMeasure K + ε := by
  rw [μ.outerMeasure_opens] at hU ⊢
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
U : Opens G
hU : innerContent μ U ≠ ⊤
ε : ℝ≥0
hε : ε ≠ 0
⊢ ∃ K, ↑K ⊆ ↑U ∧ innerContent μ U ≤ ↑(Content.outerMeasure μ) ↑K + ↑ε

Next tactic:
rcases μ.innerContent_exists_compact hU hε with ⟨K, h1K, h2K⟩
theorem outerMeasure_exists_compact {U : Opens G} (hU : μ.outerMeasure U ≠ ∞) {ε : ℝ≥0}
    (hε : ε ≠ 0) : ∃ K : Compacts G, (K : Set G) ⊆ U ∧ μ.outerMeasure U ≤ μ.outerMeasure K + ε := by
  rw [μ.outerMeasure_opens] at hU ⊢
  rcases μ.innerContent_exists_compact hU hε with ⟨K, h1K, h2K⟩
  

Proof state:
case intro.intro
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
U : Opens G
hU : innerContent μ U ≠ ⊤
ε : ℝ≥0
hε : ε ≠ 0
K : Compacts G
h1K : ↑K ⊆ ↑U
h2K : innerContent μ U ≤ (fun s => ↑(toFun μ s)) K + ↑ε
⊢ ∃ K, ↑K ⊆ ↑U ∧ innerContent μ U ≤ ↑(Content.outerMeasure μ) ↑K + ↑ε

Next tactic:
exact ⟨K, h1K, le_trans h2K <| add_le_add_right (μ.le_outerMeasure_compacts K) _⟩
theorem outerMeasure_exists_open {A : Set G} (hA : μ.outerMeasure A ≠ ∞) {ε : ℝ≥0} (hε : ε ≠ 0) :
    ∃ U : Opens G, A ⊆ U ∧ μ.outerMeasure U ≤ μ.outerMeasure A + ε := by
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
hA : ↑(Content.outerMeasure μ) A ≠ ⊤
ε : ℝ≥0
hε : ε ≠ 0
⊢ ∃ U, A ⊆ ↑U ∧ ↑(Content.outerMeasure μ) ↑U ≤ ↑(Content.outerMeasure μ) A + ↑ε

Next tactic:
rcases inducedOuterMeasure_exists_set _ μ.innerContent_iUnion_nat μ.innerContent_mono hA
      (ENNReal.coe_ne_zero.2 hε) with
    ⟨U, hU, h2U, h3U⟩
theorem outerMeasure_exists_open {A : Set G} (hA : μ.outerMeasure A ≠ ∞) {ε : ℝ≥0} (hε : ε ≠ 0) :
    ∃ U : Opens G, A ⊆ U ∧ μ.outerMeasure U ≤ μ.outerMeasure A + ε := by
  rcases inducedOuterMeasure_exists_set _ μ.innerContent_iUnion_nat μ.innerContent_mono hA
      (ENNReal.coe_ne_zero.2 hε) with
    ⟨U, hU, h2U, h3U⟩
  

Proof state:
case intro.intro.intro
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
hA : ↑(Content.outerMeasure μ) A ≠ ⊤
ε : ℝ≥0
hε : ε ≠ 0
U : Set G
hU : IsOpen U
h2U : A ⊆ U
h3U :
  ↑(inducedOuterMeasure (fun s₁ hs₁ => innerContent μ { carrier := s₁, is_open' := hs₁ }) (_ : IsOpen ∅)
          (_ : innerContent μ ⊥ = 0))
      U ≤
    ↑(inducedOuterMeasure (fun s₁ hs₁ => innerContent μ { carrier := s₁, is_open' := hs₁ }) (_ : IsOpen ∅)
            (_ : innerContent μ ⊥ = 0))
        A +
      ↑ε
⊢ ∃ U, A ⊆ ↑U ∧ ↑(Content.outerMeasure μ) ↑U ≤ ↑(Content.outerMeasure μ) A + ↑ε

Next tactic:
exact ⟨⟨U, hU⟩, h2U, h3U⟩
theorem outerMeasure_preimage (f : G ≃ₜ G) (h : ∀ ⦃K : Compacts G⦄, μ (K.map f f.continuous) = μ K)
    (A : Set G) : μ.outerMeasure (f ⁻¹' A) = μ.outerMeasure A := by
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
f : G ≃ₜ G
h : ∀ ⦃K : Compacts G⦄, (fun s => ↑(toFun μ s)) (Compacts.map ⇑f (_ : Continuous ⇑f) K) = (fun s => ↑(toFun μ s)) K
A : Set G
⊢ ↑(Content.outerMeasure μ) (⇑f ⁻¹' A) = ↑(Content.outerMeasure μ) A

Next tactic:
refine' inducedOuterMeasure_preimage _ μ.innerContent_iUnion_nat μ.innerContent_mono _
    (fun _ => f.isOpen_preimage) _
theorem outerMeasure_preimage (f : G ≃ₜ G) (h : ∀ ⦃K : Compacts G⦄, μ (K.map f f.continuous) = μ K)
    (A : Set G) : μ.outerMeasure (f ⁻¹' A) = μ.outerMeasure A := by
  refine' inducedOuterMeasure_preimage _ μ.innerContent_iUnion_nat μ.innerContent_mono _
    (fun _ => f.isOpen_preimage) _
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
f : G ≃ₜ G
h : ∀ ⦃K : Compacts G⦄, (fun s => ↑(toFun μ s)) (Compacts.map ⇑f (_ : Continuous ⇑f) K) = (fun s => ↑(toFun μ s)) K
A : Set G
⊢ ∀ (s : Set G) (hs : IsOpen s),
    innerContent μ { carrier := ⇑f.toEquiv ⁻¹' s, is_open' := (_ : IsOpen (⇑f.toEquiv ⁻¹' s)) } =
      innerContent μ { carrier := s, is_open' := hs }

Next tactic:
intro s hs
theorem outerMeasure_preimage (f : G ≃ₜ G) (h : ∀ ⦃K : Compacts G⦄, μ (K.map f f.continuous) = μ K)
    (A : Set G) : μ.outerMeasure (f ⁻¹' A) = μ.outerMeasure A := by
  refine' inducedOuterMeasure_preimage _ μ.innerContent_iUnion_nat μ.innerContent_mono _
    (fun _ => f.isOpen_preimage) _
  intro s hs
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
f : G ≃ₜ G
h : ∀ ⦃K : Compacts G⦄, (fun s => ↑(toFun μ s)) (Compacts.map ⇑f (_ : Continuous ⇑f) K) = (fun s => ↑(toFun μ s)) K
A s : Set G
hs : IsOpen s
⊢ innerContent μ { carrier := ⇑f.toEquiv ⁻¹' s, is_open' := (_ : IsOpen (⇑f.toEquiv ⁻¹' s)) } =
    innerContent μ { carrier := s, is_open' := hs }

Next tactic:
convert μ.innerContent_comap f h ⟨s, hs⟩
theorem outerMeasure_lt_top_of_isCompact [WeaklyLocallyCompactSpace G]
    {K : Set G} (hK : IsCompact K) :
    μ.outerMeasure K < ∞ := by
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
inst✝ : WeaklyLocallyCompactSpace G
K : Set G
hK : IsCompact K
⊢ ↑(Content.outerMeasure μ) K < ⊤

Next tactic:
rcases exists_compact_superset hK with ⟨F, h1F, h2F⟩
theorem outerMeasure_lt_top_of_isCompact [WeaklyLocallyCompactSpace G]
    {K : Set G} (hK : IsCompact K) :
    μ.outerMeasure K < ∞ := by
  rcases exists_compact_superset hK with ⟨F, h1F, h2F⟩
  

Proof state:
case intro.intro
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
inst✝ : WeaklyLocallyCompactSpace G
K : Set G
hK : IsCompact K
F : Set G
h1F : IsCompact F
h2F : K ⊆ interior F
⊢ ↑(Content.outerMeasure μ) K < ⊤

Next tactic:
calc
    μ.outerMeasure K ≤ μ.outerMeasure (interior F) := OuterMeasure.mono' _ h2F
    _ ≤ μ ⟨F, h1F⟩ := by
      apply μ.outerMeasure_le ⟨interior F, isOpen_interior⟩ ⟨F, h1F⟩ interior_subset
    _ < ⊤ := μ.lt_top _
theorem outerMeasure_lt_top_of_isCompact [WeaklyLocallyCompactSpace G]
    {K : Set G} (hK : IsCompact K) :
    μ.outerMeasure K < ∞ := by
  rcases exists_compact_superset hK with ⟨F, h1F, h2F⟩
  calc
    μ.outerMeasure K ≤ μ.outerMeasure (interior F) := OuterMeasure.mono' _ h2F
    _ ≤ μ ⟨F, h1F⟩ := by
      

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
inst✝ : WeaklyLocallyCompactSpace G
K : Set G
hK : IsCompact K
F : Set G
h1F : IsCompact F
h2F : K ⊆ interior F
⊢ ↑(Content.outerMeasure μ) (interior F) ≤ (fun s => ↑(toFun μ s)) { carrier := F, isCompact' := h1F }

Next tactic:
apply μ.outerMeasure_le ⟨interior F, isOpen_interior⟩ ⟨F, h1F⟩ interior_subset
@[to_additive]
theorem is_mul_left_invariant_outerMeasure [Group G] [TopologicalGroup G]
    (h : ∀ (g : G) {K : Compacts G}, μ (K.map _ <| continuous_mul_left g) = μ K) (g : G)
    (A : Set G) : μ.outerMeasure ((g * ·) ⁻¹' A) = μ.outerMeasure A := by
  

Proof state:
G : Type w
inst✝³ : TopologicalSpace G
μ : Content G
inst✝² : T2Space G
inst✝¹ : Group G
inst✝ : TopologicalGroup G
h :
  ∀ (g : G) {K : Compacts G},
    (fun s => ↑(toFun μ s)) (Compacts.map (fun b => g * b) (_ : Continuous fun b => g * b) K) =
      (fun s => ↑(toFun μ s)) K
g : G
A : Set G
⊢ ↑(Content.outerMeasure μ) ((fun x => g * x) ⁻¹' A) = ↑(Content.outerMeasure μ) A

Next tactic:
convert μ.outerMeasure_preimage (Homeomorph.mulLeft g) (fun K => h g) A
theorem outerMeasure_caratheodory (A : Set G) :
    MeasurableSet[μ.outerMeasure.caratheodory] A ↔
      ∀ U : Opens G, μ.outerMeasure (U ∩ A) + μ.outerMeasure (U \ A) ≤ μ.outerMeasure U := by
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
⊢ MeasurableSet A ↔
    ∀ (U : Opens G),
      ↑(Content.outerMeasure μ) (↑U ∩ A) + ↑(Content.outerMeasure μ) (↑U \ A) ≤ ↑(Content.outerMeasure μ) ↑U

Next tactic:
rw [Opens.forall]
theorem outerMeasure_caratheodory (A : Set G) :
    MeasurableSet[μ.outerMeasure.caratheodory] A ↔
      ∀ U : Opens G, μ.outerMeasure (U ∩ A) + μ.outerMeasure (U \ A) ≤ μ.outerMeasure U := by
  rw [Opens.forall]
  

Proof state:
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
⊢ MeasurableSet A ↔
    ∀ (U : Set G) (hU : IsOpen U),
      ↑(Content.outerMeasure μ) (↑{ carrier := U, is_open' := hU } ∩ A) +
          ↑(Content.outerMeasure μ) (↑{ carrier := U, is_open' := hU } \ A) ≤
        ↑(Content.outerMeasure μ) ↑{ carrier := U, is_open' := hU }

Next tactic:
apply inducedOuterMeasure_caratheodory
theorem outerMeasure_caratheodory (A : Set G) :
    MeasurableSet[μ.outerMeasure.caratheodory] A ↔
      ∀ U : Opens G, μ.outerMeasure (U ∩ A) + μ.outerMeasure (U \ A) ≤ μ.outerMeasure U := by
  rw [Opens.forall]
  apply inducedOuterMeasure_caratheodory
  

Proof state:
case msU
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
⊢ ∀ ⦃f : ℕ → Set G⦄ (hm : ∀ (i : ℕ), IsOpen (f i)),
    innerContent μ { carrier := ⋃ i, f i, is_open' := (_ : ?P (⋃ i, f i)) } ≤
      ∑' (i : ℕ), innerContent μ { carrier := f i, is_open' := (_ : IsOpen (f i)) }
case m_mono
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
⊢ ∀ ⦃s₁ s₂ : Set G⦄ (hs₁ : IsOpen s₁) (hs₂ : IsOpen s₂),
    s₁ ⊆ s₂ → innerContent μ { carrier := s₁, is_open' := hs₁ } ≤ innerContent μ { carrier := s₂, is_open' := hs₂ }
case PU
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
⊢ ∀ ⦃f : ℕ → Set G⦄, (∀ (i : ℕ), IsOpen (f i)) → IsOpen (⋃ i, f i)

Next tactic:
apply innerContent_iUnion_nat
theorem outerMeasure_caratheodory (A : Set G) :
    MeasurableSet[μ.outerMeasure.caratheodory] A ↔
      ∀ U : Opens G, μ.outerMeasure (U ∩ A) + μ.outerMeasure (U \ A) ≤ μ.outerMeasure U := by
  rw [Opens.forall]
  apply inducedOuterMeasure_caratheodory
  apply innerContent_iUnion_nat
  

Proof state:
case m_mono
G : Type w
inst✝¹ : TopologicalSpace G
μ : Content G
inst✝ : T2Space G
A : Set G
⊢ ∀ ⦃s₁ s₂ : Set G⦄ (hs₁ : IsOpen s₁) (hs₂ : IsOpen s₂),
    s₁ ⊆ s₂ → innerContent μ { carrier := s₁, is_open' := hs₁ } ≤ innerContent μ { carrier := s₂, is_open' := hs₂ }

Next tactic:
apply innerContent_mono'
@[to_additive]
theorem outerMeasure_pos_of_is_mul_left_invariant [Group G] [TopologicalGroup G]
    (h3 : ∀ (g : G) {K : Compacts G}, μ (K.map _ <| continuous_mul_left g) = μ K) (K : Compacts G)
    (hK : μ K ≠ 0) {U : Set G} (h1U : IsOpen U) (h2U : U.Nonempty) : 0 < μ.outerMeasure U := by
  

Proof state:
G : Type w
inst✝³ : TopologicalSpace G
μ : Content G
inst✝² : T2Space G
inst✝¹ : Group G
inst✝ : TopologicalGroup G
h3 :
  ∀ (g : G) {K : Compacts G},
    (fun s => ↑(toFun μ s)) (Compacts.map (fun b => g * b) (_ : Continuous fun b => g * b) K) =
      (fun s => ↑(toFun μ s)) K
K : Compacts G
hK : (fun s => ↑(toFun μ s)) K ≠ 0
U : Set G
h1U : IsOpen U
h2U : Set.Nonempty U
⊢ 0 < ↑(Content.outerMeasure μ) U

Next tactic:
convert μ.innerContent_pos_of_is_mul_left_invariant h3 K hK ⟨U, h1U⟩ h2U
@[to_additive]
theorem outerMeasure_pos_of_is_mul_left_invariant [Group G] [TopologicalGroup G]
    (h3 : ∀ (g : G) {K : Compacts G}, μ (K.map _ <| continuous_mul_left g) = μ K) (K : Compacts G)
    (hK : μ K ≠ 0) {U : Set G} (h1U : IsOpen U) (h2U : U.Nonempty) : 0 < μ.outerMeasure U := by
  convert μ.innerContent_pos_of_is_mul_left_invariant h3 K hK ⟨U, h1U⟩ h2U
  

Proof state:
case h.e'_4
G : Type w
inst✝³ : TopologicalSpace G
μ : Content G
inst✝² : T2Space G
inst✝¹ : Group G
inst✝ : TopologicalGroup G
h3 :
  ∀ (g : G) {K : Compacts G},
    (fun s => ↑(toFun μ s)) (Compacts.map (fun b => g * b) (_ : Continuous fun b => g * b) K) =
      (fun s => ↑(toFun μ s)) K
K : Compacts G
hK : (fun s => ↑(toFun μ s)) K ≠ 0
U : Set G
h1U : IsOpen U
h2U : Set.Nonempty U
⊢ ↑(Content.outerMeasure μ) U = innerContent μ { carrier := U, is_open' := h1U }

Next tactic:
exact μ.outerMeasure_opens ⟨U, h1U⟩
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
⊢ S ≤ OuterMeasure.caratheodory (Content.outerMeasure μ)

Next tactic:
rw [@BorelSpace.measurable_eq G _ _]
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
⊢ borel G ≤ OuterMeasure.caratheodory (Content.outerMeasure μ)

Next tactic:
refine' MeasurableSpace.generateFrom_le _
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
⊢ ∀ t ∈ {s | IsOpen s}, MeasurableSet t

Next tactic:
intro U hU
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
⊢ MeasurableSet U

Next tactic:
rw [μ.outerMeasure_caratheodory]
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
⊢ ∀ (U_1 : Opens G),
    ↑(Content.outerMeasure μ) (↑U_1 ∩ U) + ↑(Content.outerMeasure μ) (↑U_1 \ U) ≤ ↑(Content.outerMeasure μ) ↑U_1

Next tactic:
intro U'
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
⊢ ↑(Content.outerMeasure μ) (↑U' ∩ U) + ↑(Content.outerMeasure μ) (↑U' \ U) ≤ ↑(Content.outerMeasure μ) ↑U'

Next tactic:
rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
⊢ innerContent μ { carrier := ↑U' ∩ U, is_open' := (_ : IsOpen (↑U' ∩ U)) } + ↑(Content.outerMeasure μ) (↑U' \ U) ≤
    ↑(Content.outerMeasure μ) ↑U'

Next tactic:
simp only [innerContent, iSup_subtype']
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
  simp only [innerContent, iSup_subtype']
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
⊢ (⨆ x, ↑(toFun μ ↑x)) + ↑(Content.outerMeasure μ) (↑U' \ U) ≤ ↑(Content.outerMeasure μ) ↑U'

Next tactic:
rw [Opens.coe_mk]
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
  simp only [innerContent, iSup_subtype']
  rw [Opens.coe_mk]
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
⊢ (⨆ x, ↑(toFun μ ↑x)) + ↑(Content.outerMeasure μ) (↑U' \ U) ≤ ↑(Content.outerMeasure μ) ↑U'

Next tactic:
haveI : Nonempty { L : Compacts G // (L : Set G) ⊆ U' ∩ U } := ⟨⟨⊥, empty_subset _⟩⟩
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
  simp only [innerContent, iSup_subtype']
  rw [Opens.coe_mk]
  haveI : Nonempty { L : Compacts G // (L : Set G) ⊆ U' ∩ U } := ⟨⟨⊥, empty_subset _⟩⟩
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
this : Nonempty { L // ↑L ⊆ ↑U' ∩ U }
⊢ (⨆ x, ↑(toFun μ ↑x)) + ↑(Content.outerMeasure μ) (↑U' \ U) ≤ ↑(Content.outerMeasure μ) ↑U'

Next tactic:
rw [ENNReal.iSup_add]
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
  simp only [innerContent, iSup_subtype']
  rw [Opens.coe_mk]
  haveI : Nonempty { L : Compacts G // (L : Set G) ⊆ U' ∩ U } := ⟨⟨⊥, empty_subset _⟩⟩
  rw [ENNReal.iSup_add]
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
this : Nonempty { L // ↑L ⊆ ↑U' ∩ U }
⊢ ⨆ b, ↑(toFun μ ↑b) + ↑(Content.outerMeasure μ) (↑U' \ U) ≤ ↑(Content.outerMeasure μ) ↑U'

Next tactic:
refine' iSup_le _
/-- For the outer measure coming from a content, all Borel sets are measurable. -/
theorem borel_le_caratheodory : S ≤ μ.outerMeasure.caratheodory := by
  rw [@BorelSpace.measurable_eq G _ _]
  refine' MeasurableSpace.generateFrom_le _
  intro U hU
  rw [μ.outerMeasure_caratheodory]
  intro U'
  rw [μ.outerMeasure_of_isOpen ((U' : Set G) ∩ U) (U'.isOpen.inter hU)]
  simp only [innerContent, iSup_subtype']
  rw [Opens.coe_mk]
  haveI : Nonempty { L : Compacts G // (L : Set G) ⊆ U' ∩ U } := ⟨⟨⊥, empty_subset _⟩⟩
  rw [ENNReal.iSup_add]
  refine' iSup_le _
  

Proof state:
G : Type w
inst✝² : TopologicalSpace G
μ : Content G
inst✝¹ : T2Space G
S : MeasurableSpace G
inst✝ : BorelSpace G
U : Set G
hU : U ∈ {s | IsOpen s}
U' : Opens G
this : Nonempty { L // ↑L ⊆ ↑U' ∩ U }
⊢ ∀ (i : { i // ↑i ⊆ ↑U' ∩ U }), ↑(toFun μ ↑i) + ↑(Content.outerMeasure μ) (↑U' \ U) ≤ ↑(Content.outerMeasure μ) ↑U'

Next tactic:
rintro ⟨L, hL⟩