l3lab/ntp-mathlib huggingface dataset:
theorem single_trans_of_mem (a : α) {b : β} {c : γ} {f : β ≃. γ} (h : c ∈ f b) :
    (single a b).trans f = single a c := by
  ext
  dsimp [single, PEquiv.trans]
  split_ifs <;> 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
a : α
b : β
c : γ
f : β ≃. γ
h : c ∈ f b
x✝ : α
a✝ : γ
h✝ : x✝ = a
⊢ a✝ ∈ Option.bind (some b) ⇑f ↔ a✝ ∈ some c

Next tactic:
simp_all
theorem single_trans_of_mem (a : α) {b : β} {c : γ} {f : β ≃. γ} (h : c ∈ f b) :
    (single a b).trans f = single a c := by
  ext
  dsimp [single, PEquiv.trans]
  split_ifs <;> 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
a : α
b : β
c : γ
f : β ≃. γ
h : c ∈ f b
x✝ : α
a✝ : γ
h✝ : ¬x✝ = a
⊢ a✝ ∈ Option.bind none ⇑f ↔ a✝ ∈ none

Next tactic:
simp_all
@[simp]
theorem single_subsingleton_eq_refl [Subsingleton α] (a b : α) : single a b = PEquiv.refl α := by
  

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b : α
⊢ single a b = PEquiv.refl α

Next tactic:
ext i j
@[simp]
theorem single_subsingleton_eq_refl [Subsingleton α] (a b : α) : single a b = PEquiv.refl α := by
  ext i j
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b i j : α
⊢ j ∈ (single a b) i ↔ j ∈ (PEquiv.refl α) i

Next tactic:
dsimp [single]
@[simp]
theorem single_subsingleton_eq_refl [Subsingleton α] (a b : α) : single a b = PEquiv.refl α := by
  ext i j
  dsimp [single]
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b i j : α
⊢ (j ∈ if i = a then some b else none) ↔ j ∈ some i

Next tactic:
rw [if_pos (Subsingleton.elim i a), Subsingleton.elim i j, Subsingleton.elim b j]
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
h : (PEquiv.symm f) b = none
⊢ PEquiv.trans f (single b c) = ⊥

Next tactic:
ext
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
h : (PEquiv.symm f) b = none
x✝ : δ
a✝ : γ
⊢ a✝ ∈ (PEquiv.trans f (single b c)) x✝ ↔ a✝ ∈ ⊥ x✝

Next tactic:
simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
x✝ : δ
a✝ : γ
h : ∀ (a : δ), ¬f a = some b
⊢ a✝ ∈ (PEquiv.trans f (single b c)) x✝ ↔ a✝ ∈ ⊥ x✝

Next tactic:
dsimp [PEquiv.trans, single]
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
  dsimp [PEquiv.trans, single]
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
x✝ : δ
a✝ : γ
h : ∀ (a : δ), ¬f a = some b
⊢ (a✝ ∈ Option.bind (f x✝) fun x => if x = b then some c else none) ↔ a✝ ∈ none

Next tactic:
simp only [mem_def, bind_eq_some, iff_false, not_exists, not_and]
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
  dsimp [PEquiv.trans, single]
  simp only [mem_def, bind_eq_some, iff_false, not_exists, not_and]
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
x✝ : δ
a✝ : γ
h : ∀ (a : δ), ¬f a = some b
⊢ ∀ (x : β), f x✝ = some x → ¬(if x = b then some c else none) = some a✝

Next tactic:
intros
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
  dsimp [PEquiv.trans, single]
  simp only [mem_def, bind_eq_some, iff_false, not_exists, not_and]
  intros
  

Proof state:
case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
x✝¹ : δ
a✝¹ : γ
h : ∀ (a : δ), ¬f a = some b
x✝ : β
a✝ : f x✝¹ = some x✝
⊢ ¬(if x✝ = b then some c else none) = some a✝¹

Next tactic:
split_ifs
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
  dsimp [PEquiv.trans, single]
  simp only [mem_def, bind_eq_some, iff_false, not_exists, not_and]
  intros
  split_ifs <;> 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
x✝¹ : δ
a✝¹ : γ
h : ∀ (a : δ), ¬f a = some b
x✝ : β
a✝ : f x✝¹ = some x✝
h✝ : x✝ = b
⊢ ¬some c = some a✝¹

Next tactic:
simp_all
theorem trans_single_of_eq_none {b : β} (c : γ) {f : δ ≃. β} (h : f.symm b = none) :
    f.trans (single b c) = ⊥ := by
  ext
  simp only [eq_none_iff_forall_not_mem, Option.mem_def, f.eq_some_iff] at h
  dsimp [PEquiv.trans, single]
  simp only [mem_def, bind_eq_some, iff_false, not_exists, not_and]
  intros
  split_ifs <;> 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝² : DecidableEq α
inst✝¹ : DecidableEq β
inst✝ : DecidableEq γ
b : β
c : γ
f : δ ≃. β
x✝¹ : δ
a✝¹ : γ
h : ∀ (a : δ), ¬f a = some b
x✝ : β
a✝ : f x✝¹ = some x✝
h✝ : ¬x✝ = b
⊢ ¬False

Next tactic:
simp_all
instance instPartialOrderPEquiv : PartialOrder (α ≃. β) where
  le f g := ∀ (a : α) (b : β), b ∈ f a → b ∈ g a
  le_refl _ _ _ := id
  le_trans f g h fg gh a b := gh a b ∘ fg a b
  le_antisymm f g fg gf :=
    ext
      (by
        

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
f g : α ≃. β
fg : f ≤ g
gf : g ≤ f
⊢ ∀ (x : α), f x = g x

Next tactic:
intro a
instance instPartialOrderPEquiv : PartialOrder (α ≃. β) where
  le f g := ∀ (a : α) (b : β), b ∈ f a → b ∈ g a
  le_refl _ _ _ := id
  le_trans f g h fg gh a b := gh a b ∘ fg a b
  le_antisymm f g fg gf :=
    ext
      (by
        intro a
        

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
f g : α ≃. β
fg : f ≤ g
gf : g ≤ f
a : α
⊢ f a = g a

Next tactic:
cases' h : g a with b
instance instPartialOrderPEquiv : PartialOrder (α ≃. β) where
  le f g := ∀ (a : α) (b : β), b ∈ f a → b ∈ g a
  le_refl _ _ _ := id
  le_trans f g h fg gh a b := gh a b ∘ fg a b
  le_antisymm f g fg gf :=
    ext
      (by
        intro a
        cases' h : g a with b
        · 

Proof state:
case none
α : Type u
β : Type v
γ : Type w
δ : Type x
f g : α ≃. β
fg : f ≤ g
gf : g ≤ f
a : α
h : g a = none
⊢ f a = none

Next tactic:
exact eq_none_iff_forall_not_mem.2 fun b hb => Option.not_mem_none b <| h ▸ fg a b hb
instance instPartialOrderPEquiv : PartialOrder (α ≃. β) where
  le f g := ∀ (a : α) (b : β), b ∈ f a → b ∈ g a
  le_refl _ _ _ := id
  le_trans f g h fg gh a b := gh a b ∘ fg a b
  le_antisymm f g fg gf :=
    ext
      (by
        intro a
        cases' h : g a with b
        · exact eq_none_iff_forall_not_mem.2 fun b hb => Option.not_mem_none b <| h ▸ fg a b hb
        · 

Proof state:
case some
α : Type u
β : Type v
γ : Type w
δ : Type x
f g : α ≃. β
fg : f ≤ g
gf : g ≤ f
a : α
b : β
h : g a = some b
⊢ f a = some b

Next tactic:
exact gf _ _ h
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
⊢ a ∈ (fun b => if (PEquiv.symm f) b = (PEquiv.symm g) b then (PEquiv.symm f) b else none) b ↔
    b ∈ (fun a => if f a = g a then f a else none) a

Next tactic:
have hf := @mem_iff_mem _ _ f a b
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : a ∈ (PEquiv.symm f) b ↔ b ∈ f a
⊢ a ∈ (fun b => if (PEquiv.symm f) b = (PEquiv.symm g) b then (PEquiv.symm f) b else none) b ↔
    b ∈ (fun a => if f a = g a then f a else none) a

Next tactic:
have hg := @mem_iff_mem _ _ g a b
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : a ∈ (PEquiv.symm f) b ↔ b ∈ f a
hg : a ∈ (PEquiv.symm g) b ↔ b ∈ g a
⊢ a ∈ (fun b => if (PEquiv.symm f) b = (PEquiv.symm g) b then (PEquiv.symm f) b else none) b ↔
    b ∈ (fun a => if f a = g a then f a else none) a

Next tactic:
simp only [Option.mem_def] at *
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          

Proof state:
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
⊢ (if (PEquiv.symm f) b = (PEquiv.symm g) b then (PEquiv.symm f) b else none) = some a ↔
    (if f a = g a then f a else none) = some b

Next tactic:
split_ifs with h1 h2 h2
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = g a
⊢ (PEquiv.symm f) b = some a ↔ f a = some b

Next tactic:
try simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = g a
⊢ (PEquiv.symm f) b = some a ↔ f a = some b

Next tactic:
simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : ¬f a = g a
⊢ (PEquiv.symm f) b = some a ↔ False

Next tactic:
try simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : ¬f a = g a
⊢ (PEquiv.symm f) b = some a ↔ False

Next tactic:
simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : ¬(PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = g a
⊢ False ↔ f a = some b

Next tactic:
try simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : ¬(PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = g a
⊢ False ↔ f a = some b

Next tactic:
simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : ¬(PEquiv.symm f) b = (PEquiv.symm g) b
h2 : ¬f a = g a
⊢ False ↔ False

Next tactic:
try simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : ¬(PEquiv.symm f) b = (PEquiv.symm g) b
h2 : ¬f a = g a
⊢ False ↔ False

Next tactic:
simp [hf]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try simp [hf]
          · 

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : ¬f a = g a
⊢ ¬f a = some b

Next tactic:
contrapose! h2
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try simp [hf]
          · contrapose! h2
            

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = some b
⊢ f a = g a

Next tactic:
rw [h2]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try simp [hf]
          · contrapose! h2
            rw [h2]
            

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = some b
⊢ some b = g a

Next tactic:
rw [← h1, hf, h2] at hg
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try simp [hf]
          · contrapose! h2
            rw [h2]
            rw [← h1, hf, h2] at hg
            

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : some b = some b ↔ g a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = some b
⊢ some b = g a

Next tactic:
simp only [mem_def, true_iff_iff, eq_self_iff_true] at hg
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try simp [hf]
          · contrapose! h2
            rw [h2]
            rw [← h1, hf, h2] at hg
            simp only [mem_def, true_iff_iff, eq_self_iff_true] at hg
            

Proof state:
case neg
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
h1 : (PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = some b
hg : g a = some b
⊢ some b = g a

Next tactic:
rw [hg]
instance [DecidableEq α] [DecidableEq β] : SemilatticeInf (α ≃. β) :=
  { instPartialOrderPEquiv with
    inf := fun f g =>
      { toFun := fun a => if f a = g a then f a else none
        invFun := fun b => if f.symm b = g.symm b then f.symm b else none
        inv := fun a b => by
          have hf := @mem_iff_mem _ _ f a b
          have hg := @mem_iff_mem _ _ g a b
          simp only [Option.mem_def] at *
          split_ifs with h1 h2 h2 <;> try simp [hf]
          · contrapose! h2
            rw [h2]
            rw [← h1, hf, h2] at hg
            simp only [mem_def, true_iff_iff, eq_self_iff_true] at hg
            rw [hg]
          · 

Proof state:
case pos
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
src✝ : PartialOrder (α ≃. β) := instPartialOrderPEquiv
f g : α ≃. β
a : α
b : β
hf : (PEquiv.symm f) b = some a ↔ f a = some b
hg : (PEquiv.symm g) b = some a ↔ g a = some b
h1 : ¬(PEquiv.symm f) b = (PEquiv.symm g) b
h2 : f a = g a
⊢ ¬f a = some b

Next tactic:
contrapose! h1