l3lab/ntp-mathlib huggingface dataset:
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      

Proof state:
case inr.mpr
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : b • x ∈ s
⊢ a • x ∈ s

Next tactic:
rw [← inv_mul_cancel_right₀ hb a]
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      rw [← inv_mul_cancel_right₀ hb a]] <;>
    · 

Proof state:
case inr.mp
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : a • x ∈ s
⊢ (b * a⁻¹ * a) • x ∈ s

Next tactic:
rw [← smul_eq_mul, smul_assoc]
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      rw [← inv_mul_cancel_right₀ hb a]] <;>
    · rw [← smul_eq_mul, smul_assoc]
      

Proof state:
case inr.mp
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : a • x ∈ s
⊢ (b * a⁻¹) • a • x ∈ s

Next tactic:
refine' hs.smul_mem _ h'
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      rw [← inv_mul_cancel_right₀ hb a]] <;>
    · rw [← smul_eq_mul, smul_assoc]
      refine' hs.smul_mem _ h'
      

Proof state:
case inr.mp
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : a • x ∈ s
⊢ ‖b * a⁻¹‖ ≤ 1

Next tactic:
simp [← h, ha]
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      rw [← inv_mul_cancel_right₀ hb a]] <;>
    · 

Proof state:
case inr.mpr
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : b • x ∈ s
⊢ (a * b⁻¹ * b) • x ∈ s

Next tactic:
rw [← smul_eq_mul, smul_assoc]
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      rw [← inv_mul_cancel_right₀ hb a]] <;>
    · rw [← smul_eq_mul, smul_assoc]
      

Proof state:
case inr.mpr
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : b • x ∈ s
⊢ (a * b⁻¹) • b • x ∈ s

Next tactic:
refine' hs.smul_mem _ h'
theorem Balanced.mem_smul_iff (hs : Balanced 𝕜 s) (h : ‖a‖ = ‖b‖) : a • x ∈ s ↔ b • x ∈ s := by
  obtain rfl | hb := eq_or_ne b 0
  · rw [norm_zero, norm_eq_zero] at h
    rw [h]
  have ha : a ≠ 0 := norm_ne_zero_iff.1 (ne_of_eq_of_ne h <| norm_ne_zero_iff.2 hb)
  constructor <;> intro h' <;> [rw [← inv_mul_cancel_right₀ ha b];
      rw [← inv_mul_cancel_right₀ hb a]] <;>
    · rw [← smul_eq_mul, smul_assoc]
      refine' hs.smul_mem _ h'
      

Proof state:
case inr.mpr
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
h : ‖a‖ = ‖b‖
hb : b ≠ 0
ha : a ≠ 0
h' : b • x ∈ s
⊢ ‖a * b⁻¹‖ ≤ 1

Next tactic:
simp [← h, ha]
theorem Balanced.neg_mem_iff (hs : Balanced 𝕜 s) : -x ∈ s ↔ x ∈ s := by
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
⊢ -x ∈ s ↔ x ∈ s

Next tactic:
convert hs.mem_smul_iff (x := x) (norm_neg 1) using 0
theorem Balanced.neg_mem_iff (hs : Balanced 𝕜 s) : -x ∈ s ↔ x ∈ s := by
  convert hs.mem_smul_iff (x := x) (norm_neg 1) using 0;
  

Proof state:
case a
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Balanced 𝕜 s
⊢ (-x ∈ s ↔ x ∈ s) ↔ (-1 • x ∈ s ↔ 1 • x ∈ s)

Next tactic:
simp only [neg_smul, one_smul 𝕜 x]
theorem Absorbs.inter (hs : Absorbs 𝕜 s u) (ht : Absorbs 𝕜 t u) : Absorbs 𝕜 (s ∩ t) u := by
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
hs : Absorbs 𝕜 s u
ht : Absorbs 𝕜 t u
⊢ Absorbs 𝕜 (s ∩ t) u

Next tactic:
obtain ⟨a, ha, hs⟩ := hs
theorem Absorbs.inter (hs : Absorbs 𝕜 s u) (ht : Absorbs 𝕜 t u) : Absorbs 𝕜 (s ∩ t) u := by
  obtain ⟨a, ha, hs⟩ := hs
  

Proof state:
case intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a✝ b : 𝕜
ht : Absorbs 𝕜 t u
a : ℝ
ha : 0 < a
hs : ∀ (a_1 : 𝕜), a ≤ ‖a_1‖ → u ⊆ a_1 • s
⊢ Absorbs 𝕜 (s ∩ t) u

Next tactic:
obtain ⟨b, _hb, ht⟩ := ht
theorem Absorbs.inter (hs : Absorbs 𝕜 s u) (ht : Absorbs 𝕜 t u) : Absorbs 𝕜 (s ∩ t) u := by
  obtain ⟨a, ha, hs⟩ := hs
  obtain ⟨b, _hb, ht⟩ := ht
  

Proof state:
case intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a✝ b✝ : 𝕜
a : ℝ
ha : 0 < a
hs : ∀ (a_1 : 𝕜), a ≤ ‖a_1‖ → u ⊆ a_1 • s
b : ℝ
_hb : 0 < b
ht : ∀ (a : 𝕜), b ≤ ‖a‖ → u ⊆ a • t
⊢ Absorbs 𝕜 (s ∩ t) u

Next tactic:
have h : 0 < max a b := lt_max_of_lt_left ha
theorem Absorbs.inter (hs : Absorbs 𝕜 s u) (ht : Absorbs 𝕜 t u) : Absorbs 𝕜 (s ∩ t) u := by
  obtain ⟨a, ha, hs⟩ := hs
  obtain ⟨b, _hb, ht⟩ := ht
  have h : 0 < max a b := lt_max_of_lt_left ha
  

Proof state:
case intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a✝ b✝ : 𝕜
a : ℝ
ha : 0 < a
hs : ∀ (a_1 : 𝕜), a ≤ ‖a_1‖ → u ⊆ a_1 • s
b : ℝ
_hb : 0 < b
ht : ∀ (a : 𝕜), b ≤ ‖a‖ → u ⊆ a • t
h : 0 < max a b
⊢ Absorbs 𝕜 (s ∩ t) u

Next tactic:
refine' ⟨max a b, lt_max_of_lt_left ha, fun c hc => _⟩
theorem Absorbs.inter (hs : Absorbs 𝕜 s u) (ht : Absorbs 𝕜 t u) : Absorbs 𝕜 (s ∩ t) u := by
  obtain ⟨a, ha, hs⟩ := hs
  obtain ⟨b, _hb, ht⟩ := ht
  have h : 0 < max a b := lt_max_of_lt_left ha
  refine' ⟨max a b, lt_max_of_lt_left ha, fun c hc => _⟩
  

Proof state:
case intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a✝ b✝ : 𝕜
a : ℝ
ha : 0 < a
hs : ∀ (a_1 : 𝕜), a ≤ ‖a_1‖ → u ⊆ a_1 • s
b : ℝ
_hb : 0 < b
ht : ∀ (a : 𝕜), b ≤ ‖a‖ → u ⊆ a • t
h : 0 < max a b
c : 𝕜
hc : max a b ≤ ‖c‖
⊢ u ⊆ c • (s ∩ t)

Next tactic:
rw [smul_set_inter₀ (norm_pos_iff.1 <| h.trans_le hc)]
theorem Absorbs.inter (hs : Absorbs 𝕜 s u) (ht : Absorbs 𝕜 t u) : Absorbs 𝕜 (s ∩ t) u := by
  obtain ⟨a, ha, hs⟩ := hs
  obtain ⟨b, _hb, ht⟩ := ht
  have h : 0 < max a b := lt_max_of_lt_left ha
  refine' ⟨max a b, lt_max_of_lt_left ha, fun c hc => _⟩
  rw [smul_set_inter₀ (norm_pos_iff.1 <| h.trans_le hc)]
  

Proof state:
case intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a✝ b✝ : 𝕜
a : ℝ
ha : 0 < a
hs : ∀ (a_1 : 𝕜), a ≤ ‖a_1‖ → u ⊆ a_1 • s
b : ℝ
_hb : 0 < b
ht : ∀ (a : 𝕜), b ≤ ‖a‖ → u ⊆ a • t
h : 0 < max a b
c : 𝕜
hc : max a b ≤ ‖c‖
⊢ u ⊆ c • s ∩ c • t

Next tactic:
exact subset_inter (hs _ <| le_of_max_le_left hc) (ht _ <| le_of_max_le_right hc)
theorem absorbent_univ : Absorbent 𝕜 (univ : Set E) := by
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
⊢ Absorbent 𝕜 univ

Next tactic:
refine' fun x => ⟨1, zero_lt_one, fun a ha => _⟩
theorem absorbent_univ : Absorbent 𝕜 (univ : Set E) := by
  refine' fun x => ⟨1, zero_lt_one, fun a ha => _⟩
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a✝ b : 𝕜
x : E
a : 𝕜
ha : 1 ≤ ‖a‖
⊢ x ∈ a • univ

Next tactic:
rw [smul_set_univ₀ (norm_pos_iff.1 <| zero_lt_one.trans_le ha)]
theorem absorbent_univ : Absorbent 𝕜 (univ : Set E) := by
  refine' fun x => ⟨1, zero_lt_one, fun a ha => _⟩
  rw [smul_set_univ₀ (norm_pos_iff.1 <| zero_lt_one.trans_le ha)]
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁶ : NormedField 𝕜
inst✝⁵ : NormedRing 𝕝
inst✝⁴ : NormedSpace 𝕜 𝕝
inst✝³ : AddCommGroup E
inst✝² : Module 𝕜 E
inst✝¹ : SMulWithZero 𝕝 E
inst✝ : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a✝ b : 𝕜
x : E
a : 𝕜
ha : 1 ≤ ‖a‖
⊢ x ∈ univ

Next tactic:
exact trivial
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
⊢ Absorbent 𝕜 A

Next tactic:
intro x
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
⊢ ∃ r, 0 < r ∧ ∀ (a : 𝕜), r ≤ ‖a‖ → x ∈ a • A

Next tactic:
obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  

Proof state:
case intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
⊢ ∃ r, 0 < r ∧ ∀ (a : 𝕜), r ≤ ‖a‖ → x ∈ a • A

Next tactic:
have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  

Proof state:
case intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
⊢ ∃ r, 0 < r ∧ ∀ (a : 𝕜), r ≤ ‖a‖ → x ∈ a • A

Next tactic:
obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by 

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
⊢ 0 ∈ (fun t => t • x) ⁻¹' w

Next tactic:
rwa [mem_preimage, zero_smul]
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
  

Proof state:
case intro.intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
r : ℝ
hr₁ : r > 0
hr₂ : Metric.ball 0 r ⊆ (fun t => t • x) ⁻¹' w
⊢ ∃ r, 0 < r ∧ ∀ (a : 𝕜), r ≤ ‖a‖ → x ∈ a • A

Next tactic:
have hr₃ := inv_pos.mpr (half_pos hr₁)
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
  have hr₃ := inv_pos.mpr (half_pos hr₁)
  

Proof state:
case intro.intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
r : ℝ
hr₁ : r > 0
hr₂ : Metric.ball 0 r ⊆ (fun t => t • x) ⁻¹' w
hr₃ : 0 < (r / 2)⁻¹
⊢ ∃ r, 0 < r ∧ ∀ (a : 𝕜), r ≤ ‖a‖ → x ∈ a • A

Next tactic:
refine' ⟨(r / 2)⁻¹, hr₃, fun a ha₁ => _⟩
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
  have hr₃ := inv_pos.mpr (half_pos hr₁)
  refine' ⟨(r / 2)⁻¹, hr₃, fun a ha₁ => _⟩
  

Proof state:
case intro.intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a✝ b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
r : ℝ
hr₁ : r > 0
hr₂ : Metric.ball 0 r ⊆ (fun t => t • x) ⁻¹' w
hr₃ : 0 < (r / 2)⁻¹
a : 𝕜
ha₁ : (r / 2)⁻¹ ≤ ‖a‖
⊢ x ∈ a • A

Next tactic:
have ha₂ : 0 < ‖a‖ := hr₃.trans_le ha₁
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
  have hr₃ := inv_pos.mpr (half_pos hr₁)
  refine' ⟨(r / 2)⁻¹, hr₃, fun a ha₁ => _⟩
  have ha₂ : 0 < ‖a‖ := hr₃.trans_le ha₁
  

Proof state:
case intro.intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a✝ b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
r : ℝ
hr₁ : r > 0
hr₂ : Metric.ball 0 r ⊆ (fun t => t • x) ⁻¹' w
hr₃ : 0 < (r / 2)⁻¹
a : 𝕜
ha₁ : (r / 2)⁻¹ ≤ ‖a‖
ha₂ : 0 < ‖a‖
⊢ x ∈ a • A

Next tactic:
refine' (mem_smul_set_iff_inv_smul_mem₀ (norm_pos_iff.mp ha₂) _ _).2 (hw₁ <| hr₂ _)
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
  have hr₃ := inv_pos.mpr (half_pos hr₁)
  refine' ⟨(r / 2)⁻¹, hr₃, fun a ha₁ => _⟩
  have ha₂ : 0 < ‖a‖ := hr₃.trans_le ha₁
  refine' (mem_smul_set_iff_inv_smul_mem₀ (norm_pos_iff.mp ha₂) _ _).2 (hw₁ <| hr₂ _)
  

Proof state:
case intro.intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a✝ b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
r : ℝ
hr₁ : r > 0
hr₂ : Metric.ball 0 r ⊆ (fun t => t • x) ⁻¹' w
hr₃ : 0 < (r / 2)⁻¹
a : 𝕜
ha₁ : (r / 2)⁻¹ ≤ ‖a‖
ha₂ : 0 < ‖a‖
⊢ a⁻¹ ∈ Metric.ball 0 r

Next tactic:
rw [Metric.mem_ball, dist_zero_right, norm_inv]
/-- Every neighbourhood of the origin is absorbent. -/
theorem absorbent_nhds_zero (hA : A ∈ 𝓝 (0 : E)) : Absorbent 𝕜 A := by
  intro x
  obtain ⟨w, hw₁, hw₂, hw₃⟩ := mem_nhds_iff.mp hA
  have hc : Continuous fun t : 𝕜 => t • x := continuous_id.smul continuous_const
  obtain ⟨r, hr₁, hr₂⟩ :=
    Metric.isOpen_iff.mp (hw₂.preimage hc) 0 (by rwa [mem_preimage, zero_smul])
  have hr₃ := inv_pos.mpr (half_pos hr₁)
  refine' ⟨(r / 2)⁻¹, hr₃, fun a ha₁ => _⟩
  have ha₂ : 0 < ‖a‖ := hr₃.trans_le ha₁
  refine' (mem_smul_set_iff_inv_smul_mem₀ (norm_pos_iff.mp ha₂) _ _).2 (hw₁ <| hr₂ _)
  rw [Metric.mem_ball, dist_zero_right, norm_inv]
  

Proof state:
case intro.intro.intro.intro.intro
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x✝ : E
a✝ b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : A ∈ 𝓝 0
x : E
w : Set E
hw₁ : w ⊆ A
hw₂ : IsOpen w
hw₃ : 0 ∈ w
hc : Continuous fun t => t • x
r : ℝ
hr₁ : r > 0
hr₂ : Metric.ball 0 r ⊆ (fun t => t • x) ⁻¹' w
hr₃ : 0 < (r / 2)⁻¹
a : 𝕜
ha₁ : (r / 2)⁻¹ ≤ ‖a‖
ha₂ : 0 < ‖a‖
⊢ ‖a‖⁻¹ < r

Next tactic:
calc
    ‖a‖⁻¹ ≤ r / 2 := (inv_le (half_pos hr₁) ha₂).mp ha₁
    _ < r := half_lt_self hr₁
/-- The union of `{0}` with the interior of a balanced set is balanced. -/
theorem balanced_zero_union_interior (hA : Balanced 𝕜 A) :
    Balanced 𝕜 ((0 : Set E) ∪ interior A) := by
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : Balanced 𝕜 A
⊢ Balanced 𝕜 (0 ∪ interior A)

Next tactic:
intro a ha
/-- The union of `{0}` with the interior of a balanced set is balanced. -/
theorem balanced_zero_union_interior (hA : Balanced 𝕜 A) :
    Balanced 𝕜 ((0 : Set E) ∪ interior A) := by
  intro a ha
  

Proof state:
𝕜 : Type u_1
𝕝 : Type u_2
E : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝⁸ : NormedField 𝕜
inst✝⁷ : NormedRing 𝕝
inst✝⁶ : NormedSpace 𝕜 𝕝
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module 𝕜 E
inst✝³ : SMulWithZero 𝕝 E
inst✝² : IsScalarTower 𝕜 𝕝 E
s t u v A B : Set E
x : E
a✝ b : 𝕜
inst✝¹ : TopologicalSpace E
inst✝ : ContinuousSMul 𝕜 E
hA : Balanced 𝕜 A
a : 𝕜
ha : ‖a‖ ≤ 1
⊢ a • (0 ∪ interior A) ⊆ 0 ∪ interior A

Next tactic:
obtain rfl | h := eq_or_ne a 0