l3lab/ntp-mathlib huggingface dataset:
/-- `Set.preimage` as a complete lattice homomorphism.

See also `sSupHom.setImage`. -/
def setPreimage (f : α → β) : CompleteLatticeHom (Set β) (Set α)
    where
  toFun := preimage f
  map_sSup' s := preimage_sUnion.trans <| by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set β)
⊢ ⋃ t ∈ s, (fun x => f x) ⁻¹' t =
    sSup
      ({ toFun := preimage f, map_sInf' := (_ : ∀ (s : Set (Set β)), f ⁻¹' ⋂₀ s = sInf (preimage f '' s)) }.toFun '' s)

Next tactic:
simp only [Set.sSup_eq_sUnion, Set.sUnion_image]
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
⊢ f '' sSup s = sSup (image f '' s)

Next tactic:
ext b
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  ext b
  

Proof state:
case h
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
b : β
⊢ b ∈ f '' sSup s ↔ b ∈ sSup (image f '' s)

Next tactic:
simp only [sSup_eq_sUnion, mem_image, mem_sUnion, exists_prop, sUnion_image, mem_iUnion]
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  ext b
  simp only [sSup_eq_sUnion, mem_image, mem_sUnion, exists_prop, sUnion_image, mem_iUnion]
  

Proof state:
case h
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
b : β
⊢ (∃ x, (∃ t ∈ s, x ∈ t) ∧ f x = b) ↔ ∃ i ∈ s, ∃ x ∈ i, f x = b

Next tactic:
constructor
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  ext b
  simp only [sSup_eq_sUnion, mem_image, mem_sUnion, exists_prop, sUnion_image, mem_iUnion]
  constructor
  · 

Proof state:
case h.mp
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
b : β
⊢ (∃ x, (∃ t ∈ s, x ∈ t) ∧ f x = b) → ∃ i ∈ s, ∃ x ∈ i, f x = b

Next tactic:
rintro ⟨a, ⟨t, ht₁, ht₂⟩, rfl⟩
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  ext b
  simp only [sSup_eq_sUnion, mem_image, mem_sUnion, exists_prop, sUnion_image, mem_iUnion]
  constructor
  · rintro ⟨a, ⟨t, ht₁, ht₂⟩, rfl⟩
    

Proof state:
case h.mp.intro.intro.intro.intro
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
a : α
t : Set α
ht₁ : t ∈ s
ht₂ : a ∈ t
⊢ ∃ i ∈ s, ∃ x ∈ i, f x = f a

Next tactic:
exact ⟨t, ht₁, a, ht₂, rfl⟩
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  ext b
  simp only [sSup_eq_sUnion, mem_image, mem_sUnion, exists_prop, sUnion_image, mem_iUnion]
  constructor
  · rintro ⟨a, ⟨t, ht₁, ht₂⟩, rfl⟩
    exact ⟨t, ht₁, a, ht₂, rfl⟩
  · 

Proof state:
case h.mpr
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
b : β
⊢ (∃ i ∈ s, ∃ x ∈ i, f x = b) → ∃ x, (∃ t ∈ s, x ∈ t) ∧ f x = b

Next tactic:
rintro ⟨t, ht₁, a, ht₂, rfl⟩
theorem Set.image_sSup {f : α → β} (s : Set (Set α)) : f '' sSup s = sSup (image f '' s) := by
  ext b
  simp only [sSup_eq_sUnion, mem_image, mem_sUnion, exists_prop, sUnion_image, mem_iUnion]
  constructor
  · rintro ⟨a, ⟨t, ht₁, ht₂⟩, rfl⟩
    exact ⟨t, ht₁, a, ht₂, rfl⟩
  · rintro ⟨t, ht₁, a, ht₂, rfl⟩
    

Proof state:
case h.mpr.intro.intro.intro.intro
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
f : α → β
s : Set (Set α)
t : Set α
ht₁ : t ∈ s
a : α
ht₂ : a ∈ t
⊢ ∃ x, (∃ t ∈ s, x ∈ t) ∧ f x = f a

Next tactic:
exact ⟨a, ⟨t, ht₁, ht₂⟩, rfl⟩
/-- An equivalence of types yields an order isomorphism between their lattices of subsets. -/
@[simps]
def Equiv.toOrderIsoSet (e : α ≃ β) : Set α ≃o Set β
    where
  toFun s := e '' s
  invFun s := e.symm '' s
  left_inv s := by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
e : α ≃ β
s : Set α
⊢ (fun s => ⇑e.symm '' s) ((fun s => ⇑e '' s) s) = s

Next tactic:
simp only [← image_comp, Equiv.symm_comp_self, id.def, image_id']
/-- An equivalence of types yields an order isomorphism between their lattices of subsets. -/
@[simps]
def Equiv.toOrderIsoSet (e : α ≃ β) : Set α ≃o Set β
    where
  toFun s := e '' s
  invFun s := e.symm '' s
  left_inv s := by simp only [← image_comp, Equiv.symm_comp_self, id.def, image_id']
  right_inv s := by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
e : α ≃ β
s : Set β
⊢ (fun s => ⇑e '' s) ((fun s => ⇑e.symm '' s) s) = s

Next tactic:
simp only [← image_comp, Equiv.self_comp_symm, id.def, image_id']
/-- An equivalence of types yields an order isomorphism between their lattices of subsets. -/
@[simps]
def Equiv.toOrderIsoSet (e : α ≃ β) : Set α ≃o Set β
    where
  toFun s := e '' s
  invFun s := e.symm '' s
  left_inv s := by simp only [← image_comp, Equiv.symm_comp_self, id.def, image_id']
  right_inv s := by simp only [← image_comp, Equiv.self_comp_symm, id.def, image_id']
  map_rel_iff' :=
    ⟨fun h => by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
e : α ≃ β
a✝ b✝ : Set α
h :
  { toFun := fun s => ⇑e '' s, invFun := fun s => ⇑e.symm '' s,
        left_inv := (_ : ∀ (s : Set α), ⇑e.symm '' (⇑e '' s) = s),
        right_inv := (_ : ∀ (s : Set β), ⇑e '' (⇑e.symm '' s) = s) }
      a✝ ≤
    { toFun := fun s => ⇑e '' s, invFun := fun s => ⇑e.symm '' s,
        left_inv := (_ : ∀ (s : Set α), ⇑e.symm '' (⇑e '' s) = s),
        right_inv := (_ : ∀ (s : Set β), ⇑e '' (⇑e.symm '' s) = s) }
      b✝
⊢ a✝ ≤ b✝

Next tactic:
simpa using @monotone_image _ _ e.symm _ _ h
/-- The map `(a, b) ↦ a ⊔ b` as a `sSupHom`. -/
def supsSupHom : sSupHom (α × α) α where
  toFun x := x.1 ⊔ x.2
  map_sSup' s := by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
inst✝ : CompleteLattice α
x : α × α
s : Set (α × α)
⊢ (fun x => x.1 ⊔ x.2) (sSup s) = sSup ((fun x => x.1 ⊔ x.2) '' s)

Next tactic:
simp_rw [Prod.fst_sSup, Prod.snd_sSup, sSup_image, iSup_sup_eq]
/-- The map `(a, b) ↦ a ⊓ b` as an `sInfHom`. -/
def infsInfHom : sInfHom (α × α) α where
  toFun x := x.1 ⊓ x.2
  map_sInf' s := by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
ι : Sort u_6
κ : ι → Sort u_7
inst✝ : CompleteLattice α
x : α × α
s : Set (α × α)
⊢ (fun x => x.1 ⊓ x.2) (sInf s) = sInf ((fun x => x.1 ⊓ x.2) '' s)

Next tactic:
simp_rw [Prod.fst_sInf, Prod.snd_sInf, sInf_image, iInf_inf_eq]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  

Proof state:
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
ax : FieldAxiom
⊢ K ⊨ toSentence ax ↔ toProp K ax

Next tactic:
cases ax
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case addAssoc
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence addAssoc ↔ toProp K addAssoc

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case zeroAdd
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence zeroAdd ↔ toProp K zeroAdd

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case addLeftNeg
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence addLeftNeg ↔ toProp K addLeftNeg

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case mulAssoc
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence mulAssoc ↔ toProp K mulAssoc

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case mulComm
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence mulComm ↔ toProp K mulComm

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case oneMul
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence oneMul ↔ toProp K oneMul

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case existsInv
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence existsInv ↔ toProp K existsInv

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case leftDistrib
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence leftDistrib ↔ toProp K leftDistrib

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*}
    [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K]
    (ax : FieldAxiom) :
    (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
  cases ax <;>
  

Proof state:
case existsPairNE
K✝ : Type u_1
K : Type u_2
inst✝⁵ : Add K
inst✝⁴ : Mul K
inst✝³ : Neg K
inst✝² : Zero K
inst✝¹ : One K
inst✝ : CompatibleRing K
⊢ K ⊨ toSentence existsPairNE ↔ toProp K existsPairNE

Next tactic:
simp [Sentence.Realize, Formula.Realize, Fin.snoc]
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      

Proof state:
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ ∀ φ ∈ Theory.field, K ⊨ φ

Next tactic:
simp only [Theory.field, Set.mem_range, exists_imp]
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      

Proof state:
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ ∀ (φ : Sentence ring) (x : FieldAxiom), toSentence x = φ → K ⊨ φ

Next tactic:
rintro φ a rfl
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      

Proof state:
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
a : FieldAxiom
⊢ K ⊨ toSentence a

Next tactic:
rw [a.realize_toSentence_iff_toProp (K := K)]
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      

Proof state:
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
a : FieldAxiom
⊢ toProp K a

Next tactic:
cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      | mulComm => exact mul_comm
      | oneMul => exact one_mul
      | leftDistrib => exact mul_add
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      

Proof state:
case existsPairNE
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K existsPairNE

Next tactic:
| existsPairNE => exact exists_pair_ne K
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => 

Proof state:
case existsPairNE
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K existsPairNE

Next tactic:
exact exists_pair_ne K
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      

Proof state:
case existsInv
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K existsInv

Next tactic:
| existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => 

Proof state:
case existsInv
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K existsInv

Next tactic:
exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      

Proof state:
case addAssoc
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K addAssoc

Next tactic:
| addAssoc => exact add_assoc
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => 

Proof state:
case addAssoc
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K addAssoc

Next tactic:
exact add_assoc
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      

Proof state:
case zeroAdd
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K zeroAdd

Next tactic:
| zeroAdd => exact zero_add
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => 

Proof state:
case zeroAdd
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K zeroAdd

Next tactic:
exact zero_add
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      

Proof state:
case addLeftNeg
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K addLeftNeg

Next tactic:
| addLeftNeg => exact add_left_neg
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => 

Proof state:
case addLeftNeg
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K addLeftNeg

Next tactic:
exact add_left_neg
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      

Proof state:
case mulAssoc
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K mulAssoc

Next tactic:
| mulAssoc => exact mul_assoc
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => 

Proof state:
case mulAssoc
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K mulAssoc

Next tactic:
exact mul_assoc
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      

Proof state:
case mulComm
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K mulComm

Next tactic:
| mulComm => exact mul_comm
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      | mulComm => 

Proof state:
case mulComm
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K mulComm

Next tactic:
exact mul_comm
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      | mulComm => exact mul_comm
      

Proof state:
case oneMul
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K oneMul

Next tactic:
| oneMul => exact one_mul
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      | mulComm => exact mul_comm
      | oneMul => 

Proof state:
case oneMul
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K oneMul

Next tactic:
exact one_mul
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      | mulComm => exact mul_comm
      | oneMul => exact one_mul
      

Proof state:
case leftDistrib
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K leftDistrib

Next tactic:
| leftDistrib => exact mul_add
instance [Field K] [CompatibleRing K] : Theory.field.Model K :=
  { realize_of_mem := by
      simp only [Theory.field, Set.mem_range, exists_imp]
      rintro φ a rfl
      rw [a.realize_toSentence_iff_toProp (K := K)]
      cases a with
      | existsPairNE => exact exists_pair_ne K
      | existsInv => exact fun x hx0 => ⟨x⁻¹, mul_inv_cancel hx0⟩
      | addAssoc => exact add_assoc
      | zeroAdd => exact zero_add
      | addLeftNeg => exact add_left_neg
      | mulAssoc => exact mul_assoc
      | mulComm => exact mul_comm
      | oneMul => exact one_mul
      | leftDistrib => 

Proof state:
case leftDistrib
K : Type u_1
inst✝¹ : Field K
inst✝ : CompatibleRing K
⊢ toProp K leftDistrib

Next tactic:
exact mul_add
theorem hasFiniteIntegral_prod_mk_left (a : α) {s : Set (β × γ)} (h2s : (κ ⊗ₖ η) a s ≠ ∞) :
    HasFiniteIntegral (fun b => (η (a, b) (Prod.mk b ⁻¹' s)).toReal) (κ a) := by
  

Proof state:
α : Type u_1
β : Type u_2
γ : Type u_3
E : Type u_4
mα : MeasurableSpace α
mβ : MeasurableSpace β
mγ : MeasurableSpace γ
inst✝² : NormedAddCommGroup E
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a✝ a : α
s : Set (β × γ)
h2s : ↑↑((κ ⊗ₖ η) a) s ≠ ⊤
⊢ HasFiniteIntegral fun b => ENNReal.toReal (↑↑(η (a, b)) (Prod.mk b ⁻¹' s))

Next tactic:
let t := toMeasurable ((κ ⊗ₖ η) a) s