[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b c : α
⊢ Intersecting {a} ↔ a ≠ ⊥
[PROOFSTEP]
simp [Intersecting]
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b c : α
hs : Intersecting s
ha : a ≠ ⊥
h : ∀ (b : α), b ∈ s → ¬Disjoint a b
⊢ Intersecting (insert a s)
[PROOFSTEP]
rintro b (rfl | hb) c (rfl | hc)
[GOAL]
case inl.inl
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
b c✝ : α
hs : Intersecting s
c : α
ha : c ≠ ⊥
h : ∀ (b : α), b ∈ s → ¬Disjoint c b
⊢ ¬Disjoint c c
[PROOFSTEP]
rwa [disjoint_self]
[GOAL]
case inl.inr
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
b✝ c✝ : α
hs : Intersecting s
b : α
ha : b ≠ ⊥
h : ∀ (b_1 : α), b_1 ∈ s → ¬Disjoint b b_1
c : α
hc : c ∈ s
⊢ ¬Disjoint b c
[PROOFSTEP]
exact h _ hc
[GOAL]
case inr.inl
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
b✝ c✝ : α
hs : Intersecting s
b : α
hb : b ∈ s
c : α
ha : c ≠ ⊥
h : ∀ (b : α), b ∈ s → ¬Disjoint c b
⊢ ¬Disjoint b c
[PROOFSTEP]
exact fun H => h _ hb H.symm
[GOAL]
case inr.inr
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b✝ c✝ : α
hs : Intersecting s
ha : a ≠ ⊥
h : ∀ (b : α), b ∈ s → ¬Disjoint a b
b : α
hb : b ∈ s
c : α
hc : c ∈ s
⊢ ¬Disjoint b c
[PROOFSTEP]
exact hs hb hc
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b c : α
⊢ Intersecting s ↔ (Set.Pairwise s fun a b => ¬Disjoint a b) ∧ s ≠ {⊥}
[PROOFSTEP]
refine' ⟨fun h => ⟨fun a ha b hb _ => h ha hb, _⟩, fun h a ha b hb hab => _⟩
[GOAL]
case refine'_1
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b c : α
h : Intersecting s
⊢ s ≠ {⊥}
[PROOFSTEP]
rintro rfl
[GOAL]
case refine'_1
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
t : Set α
a b c : α
h : Intersecting {⊥}
⊢ False
[PROOFSTEP]
exact intersecting_singleton.1 h rfl
[GOAL]
case refine'_2
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
h : (Set.Pairwise s fun a b => ¬Disjoint a b) ∧ s ≠ {⊥}
a : α
ha : a ∈ s
b : α
hb : b ∈ s
hab : Disjoint a b
⊢ False
[PROOFSTEP]
have := h.1.eq ha hb (Classical.not_not.2 hab)
[GOAL]
case refine'_2
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
h : (Set.Pairwise s fun a b => ¬Disjoint a b) ∧ s ≠ {⊥}
a : α
ha : a ∈ s
b : α
hb : b ∈ s
hab : Disjoint a b
this : a = b
⊢ False
[PROOFSTEP]
rw [this, disjoint_self] at hab
[GOAL]
case refine'_2
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
h : (Set.Pairwise s fun a b => ¬Disjoint a b) ∧ s ≠ {⊥}
a : α
ha : a ∈ s
b : α
hb : b ∈ s
hab : b = ⊥
this : a = b
⊢ False
[PROOFSTEP]
rw [hab] at hb
[GOAL]
case refine'_2
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
h : (Set.Pairwise s fun a b => ¬Disjoint a b) ∧ s ≠ {⊥}
a : α
ha : a ∈ s
b : α
hb : ⊥ ∈ s
hab : b = ⊥
this : a = b
⊢ False
[PROOFSTEP]
exact h.2 (eq_singleton_iff_unique_mem.2 ⟨hb, fun c hc => not_ne_iff.1 fun H => h.1 hb hc H.symm disjoint_bot_left⟩)
[GOAL]
α : Type u_1
inst✝² : SemilatticeInf α
inst✝¹ : OrderBot α
s✝ t : Set α
a b c : α
inst✝ : Subsingleton α
s : Set α
⊢ Intersecting s ↔ s = ∅
[PROOFSTEP]
refine'
  subsingleton_of_subsingleton.intersecting.trans
    ⟨not_imp_comm.2 fun h => subsingleton_of_subsingleton.eq_singleton_of_mem _, _⟩
[GOAL]
case refine'_1
α : Type u_1
inst✝² : SemilatticeInf α
inst✝¹ : OrderBot α
s✝ t : Set α
a b c : α
inst✝ : Subsingleton α
s : Set α
h : ¬s = ∅
⊢ ⊥ ∈ s
[PROOFSTEP]
obtain ⟨a, ha⟩ := nonempty_iff_ne_empty.2 h
[GOAL]
case refine'_1.intro
α : Type u_1
inst✝² : SemilatticeInf α
inst✝¹ : OrderBot α
s✝ t : Set α
a✝ b c : α
inst✝ : Subsingleton α
s : Set α
h : ¬s = ∅
a : α
ha : a ∈ s
⊢ ⊥ ∈ s
[PROOFSTEP]
rwa [Subsingleton.elim ⊥ a]
[GOAL]
case refine'_2
α : Type u_1
inst✝² : SemilatticeInf α
inst✝¹ : OrderBot α
s✝ t : Set α
a b c : α
inst✝ : Subsingleton α
s : Set α
⊢ s = ∅ → s ≠ {⊥}
[PROOFSTEP]
rintro rfl
[GOAL]
case refine'_2
α : Type u_1
inst✝² : SemilatticeInf α
inst✝¹ : OrderBot α
s t : Set α
a b c : α
inst✝ : Subsingleton α
⊢ ∅ ≠ {⊥}
[PROOFSTEP]
exact (Set.singleton_nonempty _).ne_empty.symm
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b c : α
hs : Intersecting s
h : ∀ (t : Set α), Intersecting t → s ⊆ t → s = t
⊢ IsUpperSet s
[PROOFSTEP]
classical
rintro a b hab ha
rw [h (Insert.insert b s) _ (subset_insert _ _)]
· exact mem_insert _ _
exact hs.insert (mt (eq_bot_mono hab) <| hs.ne_bot ha) fun c hc hbc => hs ha hc <| hbc.mono_left hab
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a b c : α
hs : Intersecting s
h : ∀ (t : Set α), Intersecting t → s ⊆ t → s = t
⊢ IsUpperSet s
[PROOFSTEP]
rintro a b hab ha
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
hs : Intersecting s
h : ∀ (t : Set α), Intersecting t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ s
⊢ b ∈ s
[PROOFSTEP]
rw [h (Insert.insert b s) _ (subset_insert _ _)]
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
hs : Intersecting s
h : ∀ (t : Set α), Intersecting t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ s
⊢ b ∈ insert b s
[PROOFSTEP]
exact mem_insert _ _
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s t : Set α
a✝ b✝ c : α
hs : Intersecting s
h : ∀ (t : Set α), Intersecting t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ s
⊢ Intersecting (insert b s)
[PROOFSTEP]
exact hs.insert (mt (eq_bot_mono hab) <| hs.ne_bot ha) fun c hc hbc => hs ha hc <| hbc.mono_left hab
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a b c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ IsUpperSet ↑s
[PROOFSTEP]
classical
rintro a b hab ha
rw [h (Insert.insert b s) _ (Finset.subset_insert _ _)]
· exact mem_insert_self _ _
rw [coe_insert]
exact hs.insert (mt (eq_bot_mono hab) <| hs.ne_bot ha) fun c hc hbc => hs ha hc <| hbc.mono_left hab
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a b c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ IsUpperSet ↑s
[PROOFSTEP]
rintro a b hab ha
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ b ∈ ↑s
[PROOFSTEP]
rw [h (Insert.insert b s) _ (Finset.subset_insert _ _)]
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ b ∈ ↑(insert b s)
[PROOFSTEP]
exact mem_insert_self _ _
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ Intersecting ↑(insert b s)
[PROOFSTEP]
rw [coe_insert]
[GOAL]
α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ Intersecting (insert b ↑s)
[PROOFSTEP]
exact hs.insert (mt (eq_bot_mono hab) <| hs.ne_bot ha) fun c hc hbc => hs ha hc <| hbc.mono_left hab
[GOAL]
α : Type u_1
inst✝ : BooleanAlgebra α
s : Finset α
hs : Intersecting ↑s
⊢ Disjoint s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)
[PROOFSTEP]
rw [Finset.disjoint_left]
[GOAL]
α : Type u_1
inst✝ : BooleanAlgebra α
s : Finset α
hs : Intersecting ↑s
⊢ ∀ ⦃a : α⦄, a ∈ s → ¬a ∈ map { toFun := compl, inj' := (_ : Function.Injective compl) } s
[PROOFSTEP]
rintro x hx hxc
[GOAL]
α : Type u_1
inst✝ : BooleanAlgebra α
s : Finset α
hs : Intersecting ↑s
x : α
hx : x ∈ s
hxc : x ∈ map { toFun := compl, inj' := (_ : Function.Injective compl) } s
⊢ False
[PROOFSTEP]
obtain ⟨x, hx', rfl⟩ := mem_map.mp hxc
[GOAL]
case intro.intro
α : Type u_1
inst✝ : BooleanAlgebra α
s : Finset α
hs : Intersecting ↑s
x : α
hx' : x ∈ s
hx : ↑{ toFun := compl, inj' := (_ : Function.Injective compl) } x ∈ s
hxc :
  ↑{ toFun := compl, inj' := (_ : Function.Injective compl) } x ∈
    map { toFun := compl, inj' := (_ : Function.Injective compl) } s
⊢ False
[PROOFSTEP]
exact hs.not_compl_mem hx' hx
[GOAL]
α : Type u_1
inst✝¹ : BooleanAlgebra α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
⊢ 2 * card s ≤ Fintype.card α
[PROOFSTEP]
classical
refine' (s.disjUnion _ hs.disjoint_map_compl).card_le_univ.trans_eq' _
rw [two_mul, card_disjUnion, card_map]
[GOAL]
α : Type u_1
inst✝¹ : BooleanAlgebra α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
⊢ 2 * card s ≤ Fintype.card α
[PROOFSTEP]
refine' (s.disjUnion _ hs.disjoint_map_compl).card_le_univ.trans_eq' _
[GOAL]
α : Type u_1
inst✝¹ : BooleanAlgebra α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
⊢ 2 * card s =
    card
      (disjUnion s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)
        (_ : Disjoint s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)))
[PROOFSTEP]
rw [two_mul, card_disjUnion, card_map]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
⊢ (∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t) ↔ 2 * card s = Fintype.card α
[PROOFSTEP]
classical
refine'
  ⟨fun h => _, fun h t ht hst =>
    Finset.eq_of_subset_of_card_le hst <| le_of_mul_le_mul_left (ht.card_le.trans_eq h.symm) two_pos⟩
suffices s.disjUnion (s.map ⟨compl, compl_injective⟩) hs.disjoint_map_compl = Finset.univ by
  rw [Fintype.card, ← this, two_mul, card_disjUnion, card_map]
rw [← coe_eq_univ, disjUnion_eq_union, coe_union, coe_map, Function.Embedding.coeFn_mk,
  image_eq_preimage_of_inverse compl_compl compl_compl]
refine' eq_univ_of_forall fun a => _
simp_rw [mem_union, mem_preimage]
by_contra' ha
refine' s.ne_insert_of_not_mem _ ha.1 (h _ _ <| s.subset_insert _)
rw [coe_insert]
refine' hs.insert _ fun b hb hab => ha.2 <| (hs.isUpperSet' h) hab.le_compl_left hb
rintro rfl
have := h {⊤} (by rw [coe_singleton]; exact intersecting_singleton.2 top_ne_bot)
rw [compl_bot] at ha
rw [coe_eq_empty.1 ((hs.isUpperSet' h).not_top_mem.1 ha.2)] at this
exact Finset.singleton_ne_empty _ (this <| Finset.empty_subset _).symm
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
⊢ (∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t) ↔ 2 * card s = Fintype.card α
[PROOFSTEP]
refine'
  ⟨fun h => _, fun h t ht hst =>
    Finset.eq_of_subset_of_card_le hst <| le_of_mul_le_mul_left (ht.card_le.trans_eq h.symm) two_pos⟩
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ 2 * card s = Fintype.card α
[PROOFSTEP]
suffices s.disjUnion (s.map ⟨compl, compl_injective⟩) hs.disjoint_map_compl = Finset.univ by
  rw [Fintype.card, ← this, two_mul, card_disjUnion, card_map]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
this :
  disjUnion s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)
      (_ : Disjoint s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)) =
    Finset.univ
⊢ 2 * card s = Fintype.card α
[PROOFSTEP]
rw [Fintype.card, ← this, two_mul, card_disjUnion, card_map]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ disjUnion s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)
      (_ : Disjoint s (map { toFun := compl, inj' := (_ : Function.Injective compl) } s)) =
    Finset.univ
[PROOFSTEP]
rw [← coe_eq_univ, disjUnion_eq_union, coe_union, coe_map, Function.Embedding.coeFn_mk,
  image_eq_preimage_of_inverse compl_compl compl_compl]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ ↑s ∪ compl ⁻¹' ↑s = univ
[PROOFSTEP]
refine' eq_univ_of_forall fun a => _
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a : α
⊢ a ∈ ↑s ∪ compl ⁻¹' ↑s
[PROOFSTEP]
simp_rw [mem_union, mem_preimage]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a : α
⊢ a ∈ ↑s ∨ aᶜ ∈ ↑s
[PROOFSTEP]
by_contra' ha
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a : α
ha : ¬a ∈ ↑s ∧ ¬aᶜ ∈ ↑s
⊢ False
[PROOFSTEP]
refine' s.ne_insert_of_not_mem _ ha.1 (h _ _ <| s.subset_insert _)
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a : α
ha : ¬a ∈ ↑s ∧ ¬aᶜ ∈ ↑s
⊢ Intersecting ↑(insert a s)
[PROOFSTEP]
rw [coe_insert]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a : α
ha : ¬a ∈ ↑s ∧ ¬aᶜ ∈ ↑s
⊢ Intersecting (insert a ↑s)
[PROOFSTEP]
refine' hs.insert _ fun b hb hab => ha.2 <| (hs.isUpperSet' h) hab.le_compl_left hb
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a : α
ha : ¬a ∈ ↑s ∧ ¬aᶜ ∈ ↑s
⊢ a ≠ ⊥
[PROOFSTEP]
rintro rfl
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
ha : ¬⊥ ∈ ↑s ∧ ¬⊥ᶜ ∈ ↑s
⊢ False
[PROOFSTEP]
have := h {⊤} (by rw [coe_singleton]; exact intersecting_singleton.2 top_ne_bot)
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
ha : ¬⊥ ∈ ↑s ∧ ¬⊥ᶜ ∈ ↑s
⊢ Intersecting ↑{⊤}
[PROOFSTEP]
rw [coe_singleton]
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
ha : ¬⊥ ∈ ↑s ∧ ¬⊥ᶜ ∈ ↑s
⊢ Intersecting {⊤}
[PROOFSTEP]
exact intersecting_singleton.2 top_ne_bot
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
ha : ¬⊥ ∈ ↑s ∧ ¬⊥ᶜ ∈ ↑s
this : s ⊆ {⊤} → s = {⊤}
⊢ False
[PROOFSTEP]
rw [compl_bot] at ha
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
ha : ¬⊥ ∈ ↑s ∧ ¬⊤ ∈ ↑s
this : s ⊆ {⊤} → s = {⊤}
⊢ False
[PROOFSTEP]
rw [coe_eq_empty.1 ((hs.isUpperSet' h).not_top_mem.1 ha.2)] at this
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
ha : ¬⊥ ∈ ↑s ∧ ¬⊤ ∈ ↑s
this : ∅ ⊆ {⊤} → ∅ = {⊤}
⊢ False
[PROOFSTEP]
exact Finset.singleton_ne_empty _ (this <| Finset.empty_subset _).symm
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
have := hs.card_le
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
this : 2 * card s ≤ Fintype.card α
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
rw [mul_comm, ← Nat.le_div_iff_mul_le' two_pos] at this
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
hs : Intersecting ↑s
this : card s ≤ Fintype.card α / 2
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
revert hs
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
this : card s ≤ Fintype.card α / 2
⊢ Intersecting ↑s → ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
refine' s.strongDownwardInductionOn _ this
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s : Finset α
this : card s ≤ Fintype.card α / 2
⊢ ∀ (t₁ : Finset α),
    (∀ {t₂ : Finset α},
        card t₂ ≤ Fintype.card α / 2 →
          t₁ ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t) →
      card t₁ ≤ Fintype.card α / 2 → Intersecting ↑t₁ → ∃ t, t₁ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
rintro s ih _hcard hs
[GOAL]
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
by_cases h : ∀ t : Finset α, (t : Set α).Intersecting → s ⊆ t → s = t
[GOAL]
case pos
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
exact ⟨s, Subset.rfl, hs.is_max_iff_card_eq.1 h, hs⟩
[GOAL]
case neg
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
h : ¬∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
push_neg at h
[GOAL]
case neg
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
h : ∃ t, Intersecting ↑t ∧ s ⊆ t ∧ s ≠ t
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
obtain ⟨t, ht, hst⟩ := h
[GOAL]
case neg.intro.intro
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
t : Finset α
ht : Intersecting ↑t
hst : s ⊆ t ∧ s ≠ t
⊢ ∃ t, s ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
[PROOFSTEP]
refine' (ih _ (_root_.ssubset_iff_subset_ne.2 hst) ht).imp fun u => And.imp_left hst.1.trans
[GOAL]
case neg.intro.intro
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
t : Finset α
ht : Intersecting ↑t
hst : s ⊆ t ∧ s ≠ t
⊢ card t ≤ Fintype.card α / 2
[PROOFSTEP]
rw [Nat.le_div_iff_mul_le' two_pos, mul_comm]
[GOAL]
case neg.intro.intro
α : Type u_1
inst✝² : BooleanAlgebra α
inst✝¹ : Nontrivial α
inst✝ : Fintype α
s✝ : Finset α
this : card s✝ ≤ Fintype.card α / 2
s : Finset α
ih :
  ∀ {t₂ : Finset α},
    card t₂ ≤ Fintype.card α / 2 →
      s ⊂ t₂ → Intersecting ↑t₂ → ∃ t, t₂ ⊆ t ∧ 2 * card t = Fintype.card α ∧ Intersecting ↑t
_hcard : card s ≤ Fintype.card α / 2
hs : Intersecting ↑s
t : Finset α
ht : Intersecting ↑t
hst : s ⊆ t ∧ s ≠ t
⊢ 2 * card t ≤ Fintype.card α
[PROOFSTEP]
exact ht.card_le


[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
⊢ (X_1 : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj X).obj X_1 ⟶ (Functor.empty C).obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
⊢ (X_1 : Discrete PEmpty) → (Functor.empty C).obj X_1 ⟶ ((Functor.const (Discrete PEmpty)).obj X).obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
⊢ (X : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj Y).obj X ⟶ F.obj X
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
⊢ ∀ ⦃X Y_1 : Discrete PEmpty⦄ (f : X ⟶ Y_1),
    ((Functor.const (Discrete PEmpty)).obj Y).map f ≫ id (Discrete.casesOn Y_1 fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X fun as => False.elim (_ : False)) ≫ F.map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
t : IsLimit { pt := Y, π := NatTrans.mk fun X => id (Discrete.casesOn X fun as => False.elim (_ : False)) }
X : C
⊢ (X_1 : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj X).obj X_1 ⟶ F.obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
t : IsLimit { pt := Y, π := NatTrans.mk fun X => id (Discrete.casesOn X fun as => False.elim (_ : False)) }
X : C
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    ((Functor.const (Discrete PEmpty)).obj X).map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ F.map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
t : IsLimit { pt := Y, π := NatTrans.mk fun X => id (Discrete.casesOn X fun as => False.elim (_ : False)) }
X : C
f : X ⟶ Y
⊢ (X_1 : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj X).obj X_1 ⟶ F.obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
t : IsLimit { pt := Y, π := NatTrans.mk fun X => id (Discrete.casesOn X fun as => False.elim (_ : False)) }
X : C
f : X ⟶ Y
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    ((Functor.const (Discrete PEmpty)).obj X).map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ F.map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
t : IsLimit { pt := Y, π := NatTrans.mk fun X => id (Discrete.casesOn X fun as => False.elim (_ : False)) }
X : C
f : X ⟶ Y
⊢ ∀ (j : Discrete PEmpty),
    f ≫
        NatTrans.app { pt := Y, π := NatTrans.mk fun X => id (Discrete.casesOn X fun as => False.elim (_ : False)) }.π
          j =
      NatTrans.app { pt := X, π := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }.π
        j
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
⊢ Function.LeftInverse (fun u => IsLimit.mk fun s => default) fun t X =>
    {
      toInhabited :=
        {
          default :=
            IsLimit.lift t
              { pt := X, π := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) } },
      uniq :=
        (_ :
          ∀ (f : X ⟶ Y),
            f =
              IsLimit.lift t
                { pt := X, π := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }) }
[PROOFSTEP]
dsimp [Function.LeftInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
⊢ ∀ (x : IsLimit { pt := Y, π := NatTrans.mk fun X => False.elim (_ : False) }),
    (IsLimit.mk fun s => IsLimit.lift x { pt := s.pt, π := NatTrans.mk fun X_1 => False.elim (_ : False) }) = x
[PROOFSTEP]
intro x
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
x : IsLimit { pt := Y, π := NatTrans.mk fun X => False.elim (_ : False) }
⊢ (IsLimit.mk fun s => IsLimit.lift x { pt := s.pt, π := NatTrans.mk fun X_1 => False.elim (_ : False) }) = x
[PROOFSTEP]
simp only [eq_iff_true_of_subsingleton]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
⊢ Function.RightInverse (fun u => IsLimit.mk fun s => default) fun t X =>
    {
      toInhabited :=
        {
          default :=
            IsLimit.lift t
              { pt := X, π := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) } },
      uniq :=
        (_ :
          ∀ (f : X ⟶ Y),
            f =
              IsLimit.lift t
                { pt := X, π := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }) }
[PROOFSTEP]
dsimp [Function.RightInverse, Function.LeftInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
⊢ ∀ (x : (X : C) → Unique (X ⟶ Y)),
    (fun X => { toInhabited := { default := default }, uniq := (_ : ∀ (f : X ⟶ Y), f = default) }) = x
[PROOFSTEP]
intro u
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
u : (X : C) → Unique (X ⟶ Y)
⊢ (fun X => { toInhabited := { default := default }, uniq := (_ : ∀ (f : X ⟶ Y), f = default) }) = u
[PROOFSTEP]
funext X
[GOAL]
case h
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
Y : C
u : (X : C) → Unique (X ⟶ Y)
X : C
⊢ { toInhabited := { default := default }, uniq := (_ : ∀ (f : X ⟶ Y), f = default) } = u X
[PROOFSTEP]
simp only
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
⊢ (X_1 : Discrete PEmpty) → F.obj X_1 ⟶ ((Functor.const (Discrete PEmpty)).obj X).obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    F.map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ ((Functor.const (Discrete PEmpty)).obj X).map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X✝ : C
t : IsColimit { pt := X✝, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }
X : C
⊢ (X_1 : Discrete PEmpty) → F.obj X_1 ⟶ ((Functor.const (Discrete PEmpty)).obj X).obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X✝ : C
t : IsColimit { pt := X✝, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }
X : C
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    F.map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ ((Functor.const (Discrete PEmpty)).obj X).map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X✝ : C
t : IsColimit { pt := X✝, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }
X : C
f : X✝ ⟶ X
⊢ (X_1 : Discrete PEmpty) → F.obj X_1 ⟶ ((Functor.const (Discrete PEmpty)).obj X).obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X✝ : C
t : IsColimit { pt := X✝, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }
X : C
f : X✝ ⟶ X
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    F.map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ ((Functor.const (Discrete PEmpty)).obj X).map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X✝ : C
t : IsColimit { pt := X✝, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }
X : C
f : X✝ ⟶ X
⊢ ∀ (j : Discrete PEmpty),
    NatTrans.app { pt := X✝, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) }.ι
          j ≫
        f =
      NatTrans.app { pt := X, ι := NatTrans.mk fun X_2 => id (Discrete.casesOn X_2 fun as => False.elim (_ : False)) }.ι
        j
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
⊢ Function.LeftInverse (fun u => IsColimit.mk fun s => default) fun t X_1 =>
    {
      toInhabited :=
        {
          default :=
            IsColimit.desc t
              { pt := X_1, ι := NatTrans.mk fun X_2 => id (Discrete.casesOn X_2 fun as => False.elim (_ : False)) } },
      uniq :=
        (_ :
          ∀ (f : X ⟶ X_1),
            f =
              IsColimit.desc t
                { pt := X_1, ι := NatTrans.mk fun X_2 => id (Discrete.casesOn X_2 fun as => False.elim (_ : False)) }) }
[PROOFSTEP]
dsimp [Function.LeftInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
⊢ ∀ (x : IsColimit { pt := X, ι := NatTrans.mk fun X_1 => False.elim (_ : False) }),
    (IsColimit.mk fun s => IsColimit.desc x { pt := s.pt, ι := NatTrans.mk fun X_2 => False.elim (_ : False) }) = x
[PROOFSTEP]
intro
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
x✝ : IsColimit { pt := X, ι := NatTrans.mk fun X_1 => False.elim (_ : False) }
⊢ (IsColimit.mk fun s => IsColimit.desc x✝ { pt := s.pt, ι := NatTrans.mk fun X_2 => False.elim (_ : False) }) = x✝
[PROOFSTEP]
simp only [eq_iff_true_of_subsingleton]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
⊢ Function.RightInverse (fun u => IsColimit.mk fun s => default) fun t X_1 =>
    {
      toInhabited :=
        {
          default :=
            IsColimit.desc t
              { pt := X_1, ι := NatTrans.mk fun X_2 => id (Discrete.casesOn X_2 fun as => False.elim (_ : False)) } },
      uniq :=
        (_ :
          ∀ (f : X ⟶ X_1),
            f =
              IsColimit.desc t
                { pt := X_1, ι := NatTrans.mk fun X_2 => id (Discrete.casesOn X_2 fun as => False.elim (_ : False)) }) }
[PROOFSTEP]
dsimp [Function.RightInverse, Function.LeftInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
⊢ ∀ (x : (Y : C) → Unique (X ⟶ Y)),
    (fun X_1 => { toInhabited := { default := default }, uniq := (_ : ∀ (f : X ⟶ X_1), f = default) }) = x
[PROOFSTEP]
intro
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
x✝ : (Y : C) → Unique (X ⟶ Y)
⊢ (fun X_1 => { toInhabited := { default := default }, uniq := (_ : ∀ (f : X ⟶ X_1), f = default) }) = x✝
[PROOFSTEP]
funext
[GOAL]
case h
C : Type u₁
inst✝ : Category.{v₁, u₁} C
F : Discrete PEmpty ⥤ C
X : C
x✝¹ : (Y : C) → Unique (X ⟶ Y)
x✝ : C
⊢ { toInhabited := { default := default }, uniq := (_ : ∀ (f : X ⟶ x✝), f = default) } = x✝¹ x✝
[PROOFSTEP]
simp only
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X Y : C
t : IsTerminal X
f g : Y ⟶ X
⊢ ∀ (j : Discrete PEmpty), f ≫ NatTrans.app (asEmptyCone X).π j = g ≫ NatTrans.app (asEmptyCone X).π j
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X Y : C
t : IsInitial X
f g : X ⟶ Y
⊢ ∀ (j : Discrete PEmpty), NatTrans.app (asEmptyCocone X).ι j ≫ f = NatTrans.app (asEmptyCocone X).ι j ≫ g
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X Y : C
t : IsTerminal X
f : X ⟶ Y
⊢ Mono f
[PROOFSTEP]
haveI := t.isSplitMono_from f
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X Y : C
t : IsTerminal X
f : X ⟶ Y
this : IsSplitMono f
⊢ Mono f
[PROOFSTEP]
infer_instance
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X Y : C
t : IsInitial X
f : Y ⟶ X
⊢ Epi f
[PROOFSTEP]
haveI := t.isSplitEpi_to f
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X Y : C
t : IsInitial X
f : Y ⟶ X
this : IsSplitEpi f
⊢ Epi f
[PROOFSTEP]
infer_instance
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
hl : IsLimit c₁
c₂ : Cone F₂
hi : c₁.pt ≅ c₂.pt
c : Cone F₂
⊢ (X : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj c.pt).obj X ⟶ F₁.obj X
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
hl : IsLimit c₁
c₂ : Cone F₂
hi : c₁.pt ≅ c₂.pt
c : Cone F₂
⊢ ∀ ⦃X Y : Discrete PEmpty⦄ (f : X ⟶ Y),
    ((Functor.const (Discrete PEmpty)).obj c.pt).map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X fun as => False.elim (_ : False)) ≫ F₁.map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
hl : IsLimit c₁
c₂ : Cone F₂
hi : c₁.pt ≅ c₂.pt
c : Cone F₂
f : c.pt ⟶ c₂.pt
x✝ : ∀ (j : Discrete PEmpty), f ≫ NatTrans.app c₂.π j = NatTrans.app c.π j
⊢ f =
    (fun c =>
        IsLimit.lift hl
            { pt := c.pt, π := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) } ≫
          hi.hom)
      c
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
hl : IsLimit c₁
c₂ : Cone F₂
hi : c₁.pt ≅ c₂.pt
c : Cone F₂
f : c.pt ⟶ c₂.pt
x✝ : ∀ (j : Discrete PEmpty), f ≫ NatTrans.app c₂.π j = NatTrans.app c.π j
⊢ f = IsLimit.lift hl { pt := c.pt, π := NatTrans.mk fun X_1 => False.elim (_ : False) } ≫ hi.hom
[PROOFSTEP]
rw [← hl.uniq _ (f ≫ hi.inv) _]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
hl : IsLimit c₁
c₂ : Cone F₂
hi : c₁.pt ≅ c₂.pt
c : Cone F₂
f : c.pt ⟶ c₂.pt
x✝ : ∀ (j : Discrete PEmpty), f ≫ NatTrans.app c₂.π j = NatTrans.app c.π j
⊢ f = (f ≫ hi.inv) ≫ hi.hom
[PROOFSTEP]
simp only [Category.assoc, Iso.inv_hom_id, Category.comp_id]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
hl : IsLimit c₁
c₂ : Cone F₂
hi : c₁.pt ≅ c₂.pt
c : Cone F₂
f : c.pt ⟶ c₂.pt
x✝ : ∀ (j : Discrete PEmpty), f ≫ NatTrans.app c₂.π j = NatTrans.app c.π j
⊢ ∀ (j : Discrete PEmpty),
    (f ≫ hi.inv) ≫ NatTrans.app c₁.π j =
      NatTrans.app { pt := c.pt, π := NatTrans.mk fun X_1 => False.elim (_ : False) }.π j
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
⊢ Function.LeftInverse (fun hl => isLimitChangeEmptyCone C hl c₁ h.symm) fun hl => isLimitChangeEmptyCone C hl c₂ h
[PROOFSTEP]
dsimp [Function.LeftInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
⊢ ∀ (x : IsLimit c₁), isLimitChangeEmptyCone C (isLimitChangeEmptyCone C x c₂ h) c₁ h.symm = x
[PROOFSTEP]
intro
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
x✝ : IsLimit c₁
⊢ isLimitChangeEmptyCone C (isLimitChangeEmptyCone C x✝ c₂ h) c₁ h.symm = x✝
[PROOFSTEP]
simp only [eq_iff_true_of_subsingleton]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
⊢ Function.RightInverse (fun hl => isLimitChangeEmptyCone C hl c₁ h.symm) fun hl => isLimitChangeEmptyCone C hl c₂ h
[PROOFSTEP]
dsimp [Function.LeftInverse, Function.RightInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
⊢ ∀ (x : IsLimit c₂), isLimitChangeEmptyCone C (isLimitChangeEmptyCone C x c₁ h.symm) c₂ h = x
[PROOFSTEP]
intro
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
x✝ : IsLimit c₂
⊢ isLimitChangeEmptyCone C (isLimitChangeEmptyCone C x✝ c₁ h.symm) c₂ h = x✝
[PROOFSTEP]
funext
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cone F₁
c₂ : Cone F₂
h : c₁.pt ≅ c₂.pt
x✝ : IsLimit c₂
⊢ isLimitChangeEmptyCone C (isLimitChangeEmptyCone C x✝ c₁ h.symm) c₂ h = x✝
[PROOFSTEP]
simp only [eq_iff_true_of_subsingleton]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
h : HasLimit F₁
⊢ (X : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj (limit F₁)).obj X ⟶ F₂.obj X
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
h : HasLimit F₁
⊢ ∀ ⦃X Y : Discrete PEmpty⦄ (f : X ⟶ Y),
    ((Functor.const (Discrete PEmpty)).obj (limit F₁)).map f ≫
        id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X fun as => False.elim (_ : False)) ≫ F₂.map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
hl : IsColimit c₁
c₂ : Cocone F₂
hi : c₁.pt ≅ c₂.pt
c : Cocone F₂
⊢ (X : Discrete PEmpty) → F₁.obj X ⟶ ((Functor.const (Discrete PEmpty)).obj c.pt).obj X
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
hl : IsColimit c₁
c₂ : Cocone F₂
hi : c₁.pt ≅ c₂.pt
c : Cocone F₂
⊢ ∀ ⦃X Y : Discrete PEmpty⦄ (f : X ⟶ Y),
    F₁.map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X fun as => False.elim (_ : False)) ≫ ((Functor.const (Discrete PEmpty)).obj c.pt).map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
hl : IsColimit c₁
c₂ : Cocone F₂
hi : c₁.pt ≅ c₂.pt
c : Cocone F₂
f : c₂.pt ⟶ c.pt
x✝ : ∀ (j : Discrete PEmpty), NatTrans.app c₂.ι j ≫ f = NatTrans.app c.ι j
⊢ f =
    (fun c =>
        hi.inv ≫
          IsColimit.desc hl
            { pt := c.pt, ι := NatTrans.mk fun X_1 => id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) })
      c
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
hl : IsColimit c₁
c₂ : Cocone F₂
hi : c₁.pt ≅ c₂.pt
c : Cocone F₂
f : c₂.pt ⟶ c.pt
x✝ : ∀ (j : Discrete PEmpty), NatTrans.app c₂.ι j ≫ f = NatTrans.app c.ι j
⊢ f = hi.inv ≫ IsColimit.desc hl { pt := c.pt, ι := NatTrans.mk fun X_1 => False.elim (_ : False) }
[PROOFSTEP]
rw [← hl.uniq _ (hi.hom ≫ f) _]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
hl : IsColimit c₁
c₂ : Cocone F₂
hi : c₁.pt ≅ c₂.pt
c : Cocone F₂
f : c₂.pt ⟶ c.pt
x✝ : ∀ (j : Discrete PEmpty), NatTrans.app c₂.ι j ≫ f = NatTrans.app c.ι j
⊢ f = hi.inv ≫ hi.hom ≫ f
[PROOFSTEP]
simp only [Iso.inv_hom_id_assoc]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
hl : IsColimit c₁
c₂ : Cocone F₂
hi : c₁.pt ≅ c₂.pt
c : Cocone F₂
f : c₂.pt ⟶ c.pt
x✝ : ∀ (j : Discrete PEmpty), NatTrans.app c₂.ι j ≫ f = NatTrans.app c.ι j
⊢ ∀ (j : Discrete PEmpty),
    NatTrans.app c₁.ι j ≫ hi.hom ≫ f =
      NatTrans.app { pt := c.pt, ι := NatTrans.mk fun X_1 => False.elim (_ : False) }.ι j
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
⊢ Function.LeftInverse (fun hl => isColimitChangeEmptyCocone C hl c₁ h.symm) fun hl =>
    isColimitChangeEmptyCocone C hl c₂ h
[PROOFSTEP]
dsimp [Function.LeftInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
⊢ ∀ (x : IsColimit c₁), isColimitChangeEmptyCocone C (isColimitChangeEmptyCocone C x c₂ h) c₁ h.symm = x
[PROOFSTEP]
intro
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
x✝ : IsColimit c₁
⊢ isColimitChangeEmptyCocone C (isColimitChangeEmptyCocone C x✝ c₂ h) c₁ h.symm = x✝
[PROOFSTEP]
simp only [eq_iff_true_of_subsingleton]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
⊢ Function.RightInverse (fun hl => isColimitChangeEmptyCocone C hl c₁ h.symm) fun hl =>
    isColimitChangeEmptyCocone C hl c₂ h
[PROOFSTEP]
dsimp [Function.LeftInverse, Function.RightInverse]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
⊢ ∀ (x : IsColimit c₂), isColimitChangeEmptyCocone C (isColimitChangeEmptyCocone C x c₁ h.symm) c₂ h = x
[PROOFSTEP]
intro
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
x✝ : IsColimit c₂
⊢ isColimitChangeEmptyCocone C (isColimitChangeEmptyCocone C x✝ c₁ h.symm) c₂ h = x✝
[PROOFSTEP]
funext
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
c₁ : Cocone F₁
c₂ : Cocone F₂
h : c₁.pt ≅ c₂.pt
x✝ : IsColimit c₂
⊢ isColimitChangeEmptyCocone C (isColimitChangeEmptyCocone C x✝ c₁ h.symm) c₂ h = x✝
[PROOFSTEP]
simp only [eq_iff_true_of_subsingleton]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
h : HasColimit F₁
⊢ (X : Discrete PEmpty) → F₂.obj X ⟶ ((Functor.const (Discrete PEmpty)).obj (colimit F₁)).obj X
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
F₁ : Discrete PEmpty ⥤ C
F₂ : Discrete PEmpty ⥤ C
h : HasColimit F₁
⊢ ∀ ⦃X Y : Discrete PEmpty⦄ (f : X ⟶ Y),
    F₂.map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X fun as => False.elim (_ : False)) ≫
        ((Functor.const (Discrete PEmpty)).obj (colimit F₁)).map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
h : IsTerminal X
F : Discrete PEmpty ⥤ C
⊢ (X_1 : Discrete PEmpty) → ((Functor.const (Discrete PEmpty)).obj X).obj X_1 ⟶ F.obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
h : IsTerminal X
F : Discrete PEmpty ⥤ C
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    ((Functor.const (Discrete PEmpty)).obj X).map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ F.map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
h : IsInitial X
F : Discrete PEmpty ⥤ C
⊢ (X_1 : Discrete PEmpty) → F.obj X_1 ⟶ ((Functor.const (Discrete PEmpty)).obj X).obj X_1
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
X : C
h : IsInitial X
F : Discrete PEmpty ⥤ C
⊢ ∀ ⦃X_1 Y : Discrete PEmpty⦄ (f : X_1 ⟶ Y),
    F.map f ≫ id (Discrete.casesOn Y fun as => False.elim (_ : False)) =
      id (Discrete.casesOn X_1 fun as => False.elim (_ : False)) ≫ ((Functor.const (Discrete PEmpty)).obj X).map f
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : HasTerminal C
P Q : C
f : P ⟶ Q
⊢ f ≫ from Q = from P
[PROOFSTEP]
aesop
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : HasInitial C
P Q : C
f : P ⟶ Q
⊢ to P ≫ f = to Q
[PROOFSTEP]
aesop
[GOAL]
C✝ : Type u₁
inst✝³ : Category.{v₁, u₁} C✝
J : Type u_1
inst✝² : Category.{u_3, u_1} J
C : Type u_2
inst✝¹ : Category.{u_4, u_2} C
inst✝ : HasTerminal C
j : J
⊢ limitConstTerminal.inv ≫ limit.π ((Functor.const J).obj (⊤_ C)) j = terminal.from (⊤_ C)
[PROOFSTEP]
aesop_cat
[GOAL]
C✝ : Type u₁
inst✝³ : Category.{v₁, u₁} C✝
J : Type u_1
inst✝² : Category.{u_3, u_1} J
C : Type u_2
inst✝¹ : Category.{u_4, u_2} C
inst✝ : HasInitial C
j : J
⊢ colimit.ι ((Functor.const J).obj (⊥_ C)) j ≫ colimitConstInitial.hom = initial.to (⊥_ C)
[PROOFSTEP]
aesop_cat
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : InitialMonoClass C
I X : C
hI : IsInitial I
f : I ⟶ X
⊢ Mono f
[PROOFSTEP]
rw [hI.hom_ext f (hI.to X)]
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : InitialMonoClass C
I X : C
hI : IsInitial I
f : I ⟶ X
⊢ Mono (to hI X)
[PROOFSTEP]
apply InitialMonoClass.isInitial_mono_from
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
I : C
hI : IsInitial I
h : ∀ (X : C), Mono (IsInitial.to hI X)
I' X : C
hI' : IsInitial I'
⊢ Mono (IsInitial.to hI' X)
[PROOFSTEP]
rw [hI'.hom_ext (hI'.to X) ((hI'.uniqueUpToIso hI).hom ≫ hI.to X)]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
I : C
hI : IsInitial I
h : ∀ (X : C), Mono (IsInitial.to hI X)
I' X : C
hI' : IsInitial I'
⊢ Mono ((IsInitial.uniqueUpToIso hI' hI).hom ≫ IsInitial.to hI X)
[PROOFSTEP]
apply mono_comp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
j j' : J
k : j ⟶ j'
⊢ ((Functor.const J).obj (F.obj X)).map k ≫ (fun j => F.map (IsInitial.to tX j)) j' =
    (fun j => F.map (IsInitial.to tX j)) j ≫ F.map k
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
j j' : J
k : j ⟶ j'
⊢ 𝟙 (F.obj X) ≫ F.map (IsInitial.to tX j') = F.map (IsInitial.to tX j) ≫ F.map k
[PROOFSTEP]
rw [← F.map_comp, Category.id_comp, tX.hom_ext (tX.to j ≫ k) (tX.to j')]
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
⊢ m = (fun s => NatTrans.app s.π X) s
[PROOFSTEP]
conv_lhs => dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
| m
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
| m
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
| m
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
⊢ m = (fun s => NatTrans.app s.π X) s
[PROOFSTEP]
simp_rw [← w X, coneOfDiagramInitial_π_app, tX.hom_ext (tX.to X) (𝟙 _)]
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
⊢ m = m ≫ F.map (𝟙 X)
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsInitial X
F : J ⥤ C
s : Cone F
m : s.pt ⟶ (coneOfDiagramInitial tX F).pt
w : ∀ (j : J), m ≫ NatTrans.app (coneOfDiagramInitial tX F).π j = NatTrans.app s.π j
⊢ m = m ≫ F.map (𝟙 X)
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
X : J
hX : IsTerminal X
F : J ⥤ C
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ ∀ ⦃X_1 Y : J⦄ (f : X_1 ⟶ Y),
    ((Functor.const J).obj (F.obj X)).map f ≫ (fun i => inv (F.map (IsTerminal.from hX i))) Y =
      (fun i => inv (F.map (IsTerminal.from hX i))) X_1 ≫ F.map f
[PROOFSTEP]
intro i j f
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
X : J
hX : IsTerminal X
F : J ⥤ C
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
i j : J
f : i ⟶ j
⊢ ((Functor.const J).obj (F.obj X)).map f ≫ (fun i => inv (F.map (IsTerminal.from hX i))) j =
    (fun i => inv (F.map (IsTerminal.from hX i))) i ≫ F.map f
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
X : J
hX : IsTerminal X
F : J ⥤ C
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
i j : J
f : i ⟶ j
⊢ 𝟙 (F.obj X) ≫ inv (F.map (IsTerminal.from hX j)) = inv (F.map (IsTerminal.from hX i)) ≫ F.map f
[PROOFSTEP]
simp only [IsIso.eq_inv_comp, IsIso.comp_inv_eq, Category.id_comp, ← F.map_comp, hX.hom_ext (hX.from i) (f ≫ hX.from j)]
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
j j' : J
k : j ⟶ j'
⊢ F.map k ≫ (fun j => F.map (IsTerminal.from tX j)) j' =
    (fun j => F.map (IsTerminal.from tX j)) j ≫ ((Functor.const J).obj (F.obj X)).map k
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
j j' : J
k : j ⟶ j'
⊢ F.map k ≫ F.map (IsTerminal.from tX j') = F.map (IsTerminal.from tX j) ≫ 𝟙 (F.obj X)
[PROOFSTEP]
rw [← F.map_comp, Category.comp_id, tX.hom_ext (k ≫ tX.from j') (tX.from j)]
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
s : Cocone F
m : (coconeOfDiagramTerminal tX F).pt ⟶ s.pt
w : ∀ (j : J), NatTrans.app (coconeOfDiagramTerminal tX F).ι j ≫ m = NatTrans.app s.ι j
⊢ m = (fun s => NatTrans.app s.ι X) s
[PROOFSTEP]
conv_rhs =>
  dsimp
    -- Porting note: why do I need this much firepower?
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
s : Cocone F
m : (coconeOfDiagramTerminal tX F).pt ⟶ s.pt
w : ∀ (j : J), NatTrans.app (coconeOfDiagramTerminal tX F).ι j ≫ m = NatTrans.app s.ι j
| (fun s => NatTrans.app s.ι X) s
[PROOFSTEP]
dsimp
    -- Porting note: why do I need this much firepower?
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
s : Cocone F
m : (coconeOfDiagramTerminal tX F).pt ⟶ s.pt
w : ∀ (j : J), NatTrans.app (coconeOfDiagramTerminal tX F).ι j ≫ m = NatTrans.app s.ι j
| (fun s => NatTrans.app s.ι X) s
[PROOFSTEP]
dsimp
    -- Porting note: why do I need this much firepower?
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
s : Cocone F
m : (coconeOfDiagramTerminal tX F).pt ⟶ s.pt
w : ∀ (j : J), NatTrans.app (coconeOfDiagramTerminal tX F).ι j ≫ m = NatTrans.app s.ι j
| (fun s => NatTrans.app s.ι X) s
[PROOFSTEP]
dsimp
  -- Porting note: why do I need this much firepower?
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
s : Cocone F
m : (coconeOfDiagramTerminal tX F).pt ⟶ s.pt
w : ∀ (j : J), NatTrans.app (coconeOfDiagramTerminal tX F).ι j ≫ m = NatTrans.app s.ι j
⊢ m = NatTrans.app s.ι X
[PROOFSTEP]
rw [← w X, coconeOfDiagramTerminal_ι_app, tX.hom_ext (tX.from X) (𝟙 _)]
[GOAL]
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
J : Type u
inst✝ : Category.{v, u} J
X : J
tX : IsTerminal X
F : J ⥤ C
s : Cocone F
m : (coconeOfDiagramTerminal tX F).pt ⟶ s.pt
w : ∀ (j : J), NatTrans.app (coconeOfDiagramTerminal tX F).ι j ≫ m = NatTrans.app s.ι j
⊢ m = F.map (𝟙 X) ≫ m
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
X : J
hX : IsInitial X
F : J ⥤ C
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ ∀ ⦃X_1 Y : J⦄ (f : X_1 ⟶ Y),
    F.map f ≫ (fun i => inv (F.map (IsInitial.to hX i))) Y =
      (fun i => inv (F.map (IsInitial.to hX i))) X_1 ≫ ((Functor.const J).obj (F.obj X)).map f
[PROOFSTEP]
intro i j f
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
X : J
hX : IsInitial X
F : J ⥤ C
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
i j : J
f : i ⟶ j
⊢ F.map f ≫ (fun i => inv (F.map (IsInitial.to hX i))) j =
    (fun i => inv (F.map (IsInitial.to hX i))) i ≫ ((Functor.const J).obj (F.obj X)).map f
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
X : J
hX : IsInitial X
F : J ⥤ C
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
i j : J
f : i ⟶ j
⊢ F.map f ≫ inv (F.map (IsInitial.to hX j)) = inv (F.map (IsInitial.to hX i)) ≫ 𝟙 (F.obj X)
[PROOFSTEP]
simp only [IsIso.eq_inv_comp, IsIso.comp_inv_eq, Category.comp_id, ← F.map_comp, hX.hom_ext (hX.to i ≫ f) (hX.to j)]
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝ : HasLimit F
⊢ limit.π F j ≫ limit.lift F (coneOfDiagramInitial I F) = 𝟙 (limit F)
[PROOFSTEP]
ext
[GOAL]
case w
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝ : HasLimit F
j✝ : J
⊢ (limit.π F j ≫ limit.lift F (coneOfDiagramInitial I F)) ≫ limit.π F j✝ = 𝟙 (limit F) ≫ limit.π F j✝
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝ : HasLimit F
⊢ limit.lift F (coneOfDiagramInitial I F) ≫ limit.π F j = 𝟙 (F.obj j)
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsTerminal j
F : J ⥤ C
inst✝¹ : HasLimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ limit.π F j ≫ limit.lift F (coneOfDiagramTerminal I F) = 𝟙 (limit F)
[PROOFSTEP]
ext
[GOAL]
case w
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsTerminal j
F : J ⥤ C
inst✝¹ : HasLimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
j✝ : J
⊢ (limit.π F j ≫ limit.lift F (coneOfDiagramTerminal I F)) ≫ limit.π F j✝ = 𝟙 (limit F) ≫ limit.π F j✝
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsTerminal j
F : J ⥤ C
inst✝¹ : HasLimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ limit.lift F (coneOfDiagramTerminal I F) ≫ limit.π F j = 𝟙 (F.obj j)
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
j : J
I : IsTerminal j
F : J ⥤ C
inst✝ : HasColimit F
⊢ colimit.ι F j ≫ colimit.desc F (coconeOfDiagramTerminal I F) = 𝟙 (F.obj j)
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
j : J
I : IsTerminal j
F : J ⥤ C
inst✝ : HasColimit F
⊢ colimit.desc F (coconeOfDiagramTerminal I F) ≫ colimit.ι F j = 𝟙 (colimit F)
[PROOFSTEP]
ext
[GOAL]
case w
C : Type u₁
inst✝² : Category.{v₁, u₁} C
J : Type u
inst✝¹ : Category.{v, u} J
j : J
I : IsTerminal j
F : J ⥤ C
inst✝ : HasColimit F
j✝ : J
⊢ colimit.ι F j✝ ≫ colimit.desc F (coconeOfDiagramTerminal I F) ≫ colimit.ι F j = colimit.ι F j✝ ≫ 𝟙 (colimit F)
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ colimit.ι F j ≫ colimit.desc F (coconeOfDiagramInitial I F) = 𝟙 (F.obj j) ∧
    colimit.desc F (coconeOfDiagramInitial I F) ≫ colimit.ι F j = 𝟙 (colimit F)
[PROOFSTEP]
refine ⟨?_, by ext; simp⟩
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ colimit.desc F (coconeOfDiagramInitial I F) ≫ colimit.ι F j = 𝟙 (colimit F)
[PROOFSTEP]
ext
[GOAL]
case w
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
j✝ : J
⊢ colimit.ι F j✝ ≫ colimit.desc F (coconeOfDiagramInitial I F) ≫ colimit.ι F j = colimit.ι F j✝ ≫ 𝟙 (colimit F)
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ colimit.ι F j ≫ colimit.desc F (coconeOfDiagramInitial I F) = 𝟙 (F.obj j)
[PROOFSTEP]
dsimp
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ colimit.ι F j ≫ colimit.desc F (coconeOfDiagramInitial I F) = 𝟙 (F.obj j)
[PROOFSTEP]
simp only [colimit.ι_desc, coconeOfDiagramInitial_pt, coconeOfDiagramInitial_ι_app, Functor.const_obj_obj,
  IsInitial.to_self, Functor.map_id]
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ inv (𝟙 (F.obj j)) = 𝟙 (F.obj j)
[PROOFSTEP]
dsimp [inv]
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ Classical.choose (_ : ∃ inv, 𝟙 (F.obj j) ≫ inv = 𝟙 (F.obj j) ∧ inv ≫ 𝟙 (F.obj j) = 𝟙 (F.obj j)) = 𝟙 (F.obj j)
[PROOFSTEP]
simp only [Category.id_comp, Category.comp_id, and_self]
[GOAL]
C : Type u₁
inst✝³ : Category.{v₁, u₁} C
J : Type u
inst✝² : Category.{v, u} J
j : J
I : IsInitial j
F : J ⥤ C
inst✝¹ : HasColimit F
inst✝ : ∀ (i j : J) (f : i ⟶ j), IsIso (F.map f)
⊢ Classical.choose (_ : ∃ x, (fun x => x = 𝟙 (F.obj j)) x) = 𝟙 (F.obj j)
[PROOFSTEP]
apply @Classical.choose_spec _ (fun x => x = 𝟙 F.obj j) _


[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P : PresheafOfModules R
X : Cᵒᵖ
⊢ map P (𝟙 X) = id'
[PROOFSTEP]
ext
[GOAL]
case h
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P : PresheafOfModules R
X : Cᵒᵖ
x✝ : ↑(obj P X)
⊢ ↑(map P (𝟙 X)) x✝ = ↑id' x✝
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P : PresheafOfModules R
X Y Z : Cᵒᵖ
f : X ⟶ Y
g : Y ⟶ Z
⊢ map P (f ≫ g) = comp (map P g) (map P f)
[PROOFSTEP]
ext
[GOAL]
case h
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P : PresheafOfModules R
X Y Z : Cᵒᵖ
f : X ⟶ Y
g : Y ⟶ Z
x✝ : ↑(obj P X)
⊢ ↑(map P (f ≫ g)) x✝ = ↑(comp (map P g) (map P f)) x✝
[PROOFSTEP]
simp
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R✝ : Cᵒᵖ ⥤ RingCat
P Q R : PresheafOfModules R✝
f : Hom P Q
g : Hom Q R
x✝² : Cᵒᵖ
x✝¹ : ↑(R✝.obj x✝²)
x✝ : ↑(P.presheaf.obj x✝²)
⊢ ↑(NatTrans.app (f.hom ≫ g.hom) x✝²) (x✝¹ • x✝) = x✝¹ • ↑(NatTrans.app (f.hom ≫ g.hom) x✝²) x✝
[PROOFSTEP]
simp [Hom.map_smul]
[GOAL]
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P Q : PresheafOfModules R
f g : P ⟶ Q
w : ∀ (X : Cᵒᵖ), app f X = app g X
⊢ f = g
[PROOFSTEP]
cases f
[GOAL]
case mk
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P Q : PresheafOfModules R
g : P ⟶ Q
hom✝ : P.presheaf ⟶ Q.presheaf
map_smul✝ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)), ↑(NatTrans.app hom✝ X) (r • x) = r • ↑(NatTrans.app hom✝ X) x
w : ∀ (X : Cᵒᵖ), app { hom := hom✝, map_smul := map_smul✝ } X = app g X
⊢ { hom := hom✝, map_smul := map_smul✝ } = g
[PROOFSTEP]
cases g
[GOAL]
case mk.mk
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P Q : PresheafOfModules R
hom✝¹ : P.presheaf ⟶ Q.presheaf
map_smul✝¹ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)),
    ↑(NatTrans.app hom✝¹ X) (r • x) = r • ↑(NatTrans.app hom✝¹ X) x
hom✝ : P.presheaf ⟶ Q.presheaf
map_smul✝ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)), ↑(NatTrans.app hom✝ X) (r • x) = r • ↑(NatTrans.app hom✝ X) x
w : ∀ (X : Cᵒᵖ), app { hom := hom✝¹, map_smul := map_smul✝¹ } X = app { hom := hom✝, map_smul := map_smul✝ } X
⊢ { hom := hom✝¹, map_smul := map_smul✝¹ } = { hom := hom✝, map_smul := map_smul✝ }
[PROOFSTEP]
congr
[GOAL]
case mk.mk.e_hom
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P Q : PresheafOfModules R
hom✝¹ : P.presheaf ⟶ Q.presheaf
map_smul✝¹ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)),
    ↑(NatTrans.app hom✝¹ X) (r • x) = r • ↑(NatTrans.app hom✝¹ X) x
hom✝ : P.presheaf ⟶ Q.presheaf
map_smul✝ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)), ↑(NatTrans.app hom✝ X) (r • x) = r • ↑(NatTrans.app hom✝ X) x
w : ∀ (X : Cᵒᵖ), app { hom := hom✝¹, map_smul := map_smul✝¹ } X = app { hom := hom✝, map_smul := map_smul✝ } X
⊢ hom✝¹ = hom✝
[PROOFSTEP]
ext X x
[GOAL]
case mk.mk.e_hom.w.h.w
C : Type u₁
inst✝ : Category.{v₁, u₁} C
R : Cᵒᵖ ⥤ RingCat
P Q : PresheafOfModules R
hom✝¹ : P.presheaf ⟶ Q.presheaf
map_smul✝¹ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)),
    ↑(NatTrans.app hom✝¹ X) (r • x) = r • ↑(NatTrans.app hom✝¹ X) x
hom✝ : P.presheaf ⟶ Q.presheaf
map_smul✝ :
  ∀ (X : Cᵒᵖ) (r : ↑(R.obj X)) (x : ↑(P.presheaf.obj X)), ↑(NatTrans.app hom✝ X) (r • x) = r • ↑(NatTrans.app hom✝ X) x
w : ∀ (X : Cᵒᵖ), app { hom := hom✝¹, map_smul := map_smul✝¹ } X = app { hom := hom✝, map_smul := map_smul✝ } X
X : Cᵒᵖ
x : ↑(P.presheaf.obj X)
⊢ ↑(NatTrans.app hom✝¹ X) x = ↑(NatTrans.app hom✝ X) x
[PROOFSTEP]
exact LinearMap.congr_fun (w X) x


[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
a : R
h : a ∈ closure s
b : R
ih : ∃ L, (∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) ∧ List.sum (List.map List.prod L) = b
L1 : List (List R)
h1 : ∀ (l : List R), l ∈ L1 → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
x✝ : AddGroup.InClosure (Monoid.Closure s) (List.sum (List.map List.prod L1))
⊢ List.sum (List.map List.prod (List.map (List.cons (-1)) L1)) = -List.sum (List.map List.prod L1)
[PROOFSTEP]
simp only [List.map_map, (· ∘ ·), List.prod_cons, neg_one_mul]
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
a : R
h : a ∈ closure s
b : R
ih : ∃ L, (∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) ∧ List.sum (List.map List.prod L) = b
L1 : List (List R)
h1 : ∀ (l : List R), l ∈ L1 → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
x✝ : AddGroup.InClosure (Monoid.Closure s) (List.sum (List.map List.prod L1))
⊢ List.sum (List.map (fun x => -List.prod x) L1) = -List.sum (List.map List.prod L1)
[PROOFSTEP]
refine' List.recOn L1 neg_zero.symm fun hd tl ih ↦ _
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
a : R
h : a ∈ closure s
b : R
ih✝ : ∃ L, (∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) ∧ List.sum (List.map List.prod L) = b
L1 : List (List R)
h1 : ∀ (l : List R), l ∈ L1 → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
x✝ : AddGroup.InClosure (Monoid.Closure s) (List.sum (List.map List.prod L1))
hd : List R
tl : List (List R)
ih : List.sum (List.map (fun x => -List.prod x) tl) = -List.sum (List.map List.prod tl)
⊢ List.sum (List.map (fun x => -List.prod x) (hd :: tl)) = -List.sum (List.map List.prod (hd :: tl))
[PROOFSTEP]
rw [List.map_cons, List.sum_cons, ih, List.map_cons, List.sum_cons, neg_add]
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
a : R
h : a ∈ closure s
r1 r2 : R
ih1 : ∃ L, (∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) ∧ List.sum (List.map List.prod L) = r1
ih2 : ∃ L, (∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) ∧ List.sum (List.map List.prod L) = r2
L1 : List (List R)
h1 : ∀ (l : List R), l ∈ L1 → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
L2 : List (List R)
h2 : ∀ (l : List R), l ∈ L2 → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
x✝¹ : AddGroup.InClosure (Monoid.Closure s) (List.sum (List.map List.prod L1))
x✝ : AddGroup.InClosure (Monoid.Closure s) (List.sum (List.map List.prod L2))
⊢ List.sum (List.map List.prod (L1 ++ L2)) = List.sum (List.map List.prod L1) + List.sum (List.map List.prod L2)
[PROOFSTEP]
rw [List.map_append, List.sum_append]
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
x : R
hx : x ∈ closure s
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
⊢ C x
[PROOFSTEP]
have h0 : C 0 := add_neg_self (1 : R) ▸ ha h1 hneg1
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
x : R
hx : x ∈ closure s
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
⊢ C x
[PROOFSTEP]
rcases exists_list_of_mem_closure hx with ⟨L, HL, rfl⟩
[GOAL]
case intro.intro
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hx : List.sum (List.map List.prod L) ∈ closure s
⊢ C (List.sum (List.map List.prod L))
[PROOFSTEP]
clear hx
[GOAL]
case intro.intro
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
⊢ C (List.sum (List.map List.prod L))
[PROOFSTEP]
induction' L with hd tl ih
[GOAL]
case intro.intro.nil
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
HL : ∀ (l : List R), l ∈ [] → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
⊢ C (List.sum (List.map List.prod []))
[PROOFSTEP]
exact h0
[GOAL]
case intro.intro.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
tl : List (List R)
ih : (∀ (l : List R), l ∈ tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) → C (List.sum (List.map List.prod tl))
HL : ∀ (l : List R), l ∈ hd :: tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
⊢ C (List.sum (List.map List.prod (hd :: tl)))
[PROOFSTEP]
rw [List.forall_mem_cons] at HL
[GOAL]
case intro.intro.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
tl : List (List R)
ih : (∀ (l : List R), l ∈ tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) → C (List.sum (List.map List.prod tl))
HL : (∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1) ∧ ∀ (x : List R), x ∈ tl → ∀ (x_1 : R), x_1 ∈ x → x_1 ∈ s ∨ x_1 = -1
⊢ C (List.sum (List.map List.prod (hd :: tl)))
[PROOFSTEP]
suffices C (List.prod hd) by
  rw [List.map_cons, List.sum_cons]
  exact ha this (ih HL.2)
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
tl : List (List R)
ih : (∀ (l : List R), l ∈ tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) → C (List.sum (List.map List.prod tl))
HL : (∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1) ∧ ∀ (x : List R), x ∈ tl → ∀ (x_1 : R), x_1 ∈ x → x_1 ∈ s ∨ x_1 = -1
this : C (List.prod hd)
⊢ C (List.sum (List.map List.prod (hd :: tl)))
[PROOFSTEP]
rw [List.map_cons, List.sum_cons]
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
tl : List (List R)
ih : (∀ (l : List R), l ∈ tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) → C (List.sum (List.map List.prod tl))
HL : (∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1) ∧ ∀ (x : List R), x ∈ tl → ∀ (x_1 : R), x_1 ∈ x → x_1 ∈ s ∨ x_1 = -1
this : C (List.prod hd)
⊢ C (List.prod hd + List.sum (List.map List.prod tl))
[PROOFSTEP]
exact ha this (ih HL.2)
[GOAL]
case intro.intro.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
tl : List (List R)
ih : (∀ (l : List R), l ∈ tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) → C (List.sum (List.map List.prod tl))
HL : (∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1) ∧ ∀ (x : List R), x ∈ tl → ∀ (x_1 : R), x_1 ∈ x → x_1 ∈ s ∨ x_1 = -1
⊢ C (List.prod hd)
[PROOFSTEP]
replace HL := HL.1
[GOAL]
case intro.intro.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
tl : List (List R)
ih : (∀ (l : List R), l ∈ tl → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1) → C (List.sum (List.map List.prod tl))
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
⊢ C (List.prod hd)
[PROOFSTEP]
clear ih tl
[GOAL]
case intro.intro.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
⊢ C (List.prod hd)
[PROOFSTEP]
suffices ∃ L, (∀ x ∈ L, x ∈ s) ∧ (List.prod hd = List.prod L ∨ List.prod hd = -List.prod L)
  by
  rcases this with ⟨L, HL', HP | HP⟩ <;> rw [HP] <;> clear HP HL
  · induction' L with hd tl ih
    · exact h1
    rw [List.forall_mem_cons] at HL'
    rw [List.prod_cons]
    exact hs _ HL'.1 _ (ih HL'.2)
  · induction' L with hd tl ih
    · exact hneg1
    rw [List.prod_cons, neg_mul_eq_mul_neg]
    rw [List.forall_mem_cons] at HL'
    exact hs _ HL'.1 _ (ih HL'.2)
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
this : ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod hd = List.prod L ∨ List.prod hd = -List.prod L)
⊢ C (List.prod hd)
[PROOFSTEP]
rcases this with ⟨L, HL', HP | HP⟩
[GOAL]
case intro.intro.inl
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod hd = List.prod L
⊢ C (List.prod hd)
[PROOFSTEP]
rw [HP]
[GOAL]
case intro.intro.inr
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod hd = -List.prod L
⊢ C (List.prod hd)
[PROOFSTEP]
rw [HP]
[GOAL]
case intro.intro.inl
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod hd = List.prod L
⊢ C (List.prod L)
[PROOFSTEP]
clear HP HL
[GOAL]
case intro.intro.inr
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod hd = -List.prod L
⊢ C (-List.prod L)
[PROOFSTEP]
clear HP HL
[GOAL]
case intro.intro.inl
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
⊢ C (List.prod L)
[PROOFSTEP]
induction' L with hd tl ih
[GOAL]
case intro.intro.inl.nil
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
HL' : ∀ (x : R), x ∈ [] → x ∈ s
⊢ C (List.prod [])
[PROOFSTEP]
exact h1
[GOAL]
case intro.intro.inl.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
hd : R
tl : List R
ih : (∀ (x : R), x ∈ tl → x ∈ s) → C (List.prod tl)
HL' : ∀ (x : R), x ∈ hd :: tl → x ∈ s
⊢ C (List.prod (hd :: tl))
[PROOFSTEP]
rw [List.forall_mem_cons] at HL'
[GOAL]
case intro.intro.inl.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
hd : R
tl : List R
ih : (∀ (x : R), x ∈ tl → x ∈ s) → C (List.prod tl)
HL' : hd ∈ s ∧ ∀ (x : R), x ∈ tl → x ∈ s
⊢ C (List.prod (hd :: tl))
[PROOFSTEP]
rw [List.prod_cons]
[GOAL]
case intro.intro.inl.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
hd : R
tl : List R
ih : (∀ (x : R), x ∈ tl → x ∈ s) → C (List.prod tl)
HL' : hd ∈ s ∧ ∀ (x : R), x ∈ tl → x ∈ s
⊢ C (hd * List.prod tl)
[PROOFSTEP]
exact hs _ HL'.1 _ (ih HL'.2)
[GOAL]
case intro.intro.inr
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
⊢ C (-List.prod L)
[PROOFSTEP]
induction' L with hd tl ih
[GOAL]
case intro.intro.inr.nil
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
HL' : ∀ (x : R), x ∈ [] → x ∈ s
⊢ C (-List.prod [])
[PROOFSTEP]
exact hneg1
[GOAL]
case intro.intro.inr.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
hd : R
tl : List R
ih : (∀ (x : R), x ∈ tl → x ∈ s) → C (-List.prod tl)
HL' : ∀ (x : R), x ∈ hd :: tl → x ∈ s
⊢ C (-List.prod (hd :: tl))
[PROOFSTEP]
rw [List.prod_cons, neg_mul_eq_mul_neg]
[GOAL]
case intro.intro.inr.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
hd : R
tl : List R
ih : (∀ (x : R), x ∈ tl → x ∈ s) → C (-List.prod tl)
HL' : ∀ (x : R), x ∈ hd :: tl → x ∈ s
⊢ C (hd * -List.prod tl)
[PROOFSTEP]
rw [List.forall_mem_cons] at HL'
[GOAL]
case intro.intro.inr.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ L : List R
HL'✝ : ∀ (x : R), x ∈ L → x ∈ s
hd : R
tl : List R
ih : (∀ (x : R), x ∈ tl → x ∈ s) → C (-List.prod tl)
HL' : hd ∈ s ∧ ∀ (x : R), x ∈ tl → x ∈ s
⊢ C (hd * -List.prod tl)
[PROOFSTEP]
exact hs _ HL'.1 _ (ih HL'.2)
[GOAL]
case intro.intro.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod hd = List.prod L ∨ List.prod hd = -List.prod L)
[PROOFSTEP]
induction' hd with hd tl ih
[GOAL]
case intro.intro.cons.nil
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd : List R
HL✝ : ∀ (x : R), x ∈ hd → x ∈ s ∨ x = -1
HL : ∀ (x : R), x ∈ [] → x ∈ s ∨ x = -1
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod [] = List.prod L ∨ List.prod [] = -List.prod L)
[PROOFSTEP]
exact ⟨[], List.forall_mem_nil _, Or.inl rfl⟩
[GOAL]
case intro.intro.cons.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : ∀ (x : R), x ∈ hd :: tl → x ∈ s ∨ x = -1
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
rw [List.forall_mem_cons] at HL
[GOAL]
case intro.intro.cons.cons
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
rcases ih HL.2 with ⟨L, HL', HP | HP⟩
[GOAL]
case intro.intro.cons.cons.intro.intro.inl
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = List.prod L
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
cases' HL.1 with hhd hhd
[GOAL]
case intro.intro.cons.cons.intro.intro.inr
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = -List.prod L
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
cases' HL.1 with hhd hhd
[GOAL]
case intro.intro.cons.cons.intro.intro.inl.inl
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = List.prod L
hhd : hd ∈ s
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
exact ⟨hd :: L, List.forall_mem_cons.2 ⟨hhd, HL'⟩, Or.inl <| by rw [List.prod_cons, List.prod_cons, HP]⟩
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = List.prod L
hhd : hd ∈ s
⊢ List.prod (hd :: tl) = List.prod (hd :: L)
[PROOFSTEP]
rw [List.prod_cons, List.prod_cons, HP]
[GOAL]
case intro.intro.cons.cons.intro.intro.inl.inr
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = List.prod L
hhd : hd = -1
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
exact ⟨L, HL', Or.inr <| by rw [List.prod_cons, hhd, neg_one_mul, HP]⟩
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = List.prod L
hhd : hd = -1
⊢ List.prod (hd :: tl) = -List.prod L
[PROOFSTEP]
rw [List.prod_cons, hhd, neg_one_mul, HP]
[GOAL]
case intro.intro.cons.cons.intro.intro.inr.inl
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = -List.prod L
hhd : hd ∈ s
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
exact
  ⟨hd :: L, List.forall_mem_cons.2 ⟨hhd, HL'⟩, Or.inr <| by rw [List.prod_cons, List.prod_cons, HP, neg_mul_eq_mul_neg]⟩
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = -List.prod L
hhd : hd ∈ s
⊢ List.prod (hd :: tl) = -List.prod (hd :: L)
[PROOFSTEP]
rw [List.prod_cons, List.prod_cons, HP, neg_mul_eq_mul_neg]
[GOAL]
case intro.intro.cons.cons.intro.intro.inr.inr
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = -List.prod L
hhd : hd = -1
⊢ ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod (hd :: tl) = List.prod L ∨ List.prod (hd :: tl) = -List.prod L)
[PROOFSTEP]
exact ⟨L, HL', Or.inl <| by rw [List.prod_cons, hhd, HP, neg_one_mul, neg_neg]⟩
[GOAL]
R : Type u
inst✝¹ : Ring R
cR : Type u
inst✝ : CommRing cR
s : Set R
C : R → Prop
h1 : C 1
hneg1 : C (-1)
hs : ∀ (z : R), z ∈ s → ∀ (n : R), C n → C (z * n)
ha : ∀ {x y : R}, C x → C y → C (x + y)
h0 : C 0
L✝ : List (List R)
HL✝¹ : ∀ (l : List R), l ∈ L✝ → ∀ (x : R), x ∈ l → x ∈ s ∨ x = -1
hd✝ : List R
HL✝ : ∀ (x : R), x ∈ hd✝ → x ∈ s ∨ x = -1
hd : R
tl : List R
ih :
  (∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1) →
    ∃ L, (∀ (x : R), x ∈ L → x ∈ s) ∧ (List.prod tl = List.prod L ∨ List.prod tl = -List.prod L)
HL : (hd ∈ s ∨ hd = -1) ∧ ∀ (x : R), x ∈ tl → x ∈ s ∨ x = -1
L : List R
HL' : ∀ (x : R), x ∈ L → x ∈ s
HP : List.prod tl = -List.prod L
hhd : hd = -1
⊢ List.prod (hd :: tl) = List.prod L
[PROOFSTEP]
rw [List.prod_cons, hhd, HP, neg_one_mul, neg_neg]
[GOAL]
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
⊢ ↑f '' closure s = closure (↑f '' s)
[PROOFSTEP]
refine'
  le_antisymm _ (closure_subset (RingHom.isSubring_image _ closure.isSubring) <| Set.image_subset _ subset_closure)
[GOAL]
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
⊢ ↑f '' closure s ≤ closure (↑f '' s)
[PROOFSTEP]
rintro _ ⟨x, hx, rfl⟩
[GOAL]
case intro.intro
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ ↑f x ∈ closure (↑f '' s)
[PROOFSTEP]
apply AddGroup.InClosure.recOn (motive := fun {x} _ ↦ f x ∈ closure (f '' s)) hx _
[GOAL]
case intro.intro.zero
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ ↑f 0 ∈ closure (↑f '' s)
[PROOFSTEP]
intros
[GOAL]
case intro.intro.neg
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ ∀ {a : R}, AddGroup.InClosure (Monoid.Closure s) a → ↑f a ∈ closure (↑f '' s) → ↑f (-a) ∈ closure (↑f '' s)
[PROOFSTEP]
intros
[GOAL]
case intro.intro.add
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ ∀ {a b : R},
    AddGroup.InClosure (Monoid.Closure s) a →
      AddGroup.InClosure (Monoid.Closure s) b →
        ↑f a ∈ closure (↑f '' s) → ↑f b ∈ closure (↑f '' s) → ↑f (a + b) ∈ closure (↑f '' s)
[PROOFSTEP]
intros
[GOAL]
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ ∀ {a : R} (a_1 : a ∈ Monoid.Closure s),
    (fun {x} x_1 => ↑f x ∈ closure (↑f '' s)) (_ : AddGroup.InClosure (Monoid.Closure s) a)
[PROOFSTEP]
intros
[GOAL]
case intro.intro.zero
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ ↑f 0 ∈ closure (↑f '' s)
[PROOFSTEP]
rw [f.map_zero]
[GOAL]
case intro.intro.zero
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ 0 ∈ closure (↑f '' s)
[PROOFSTEP]
apply closure.isSubring.zero_mem
[GOAL]
case intro.intro.neg
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : AddGroup.InClosure (Monoid.Closure s) a✝¹
a_ih✝ : ↑f a✝¹ ∈ closure (↑f '' s)
⊢ ↑f (-a✝¹) ∈ closure (↑f '' s)
[PROOFSTEP]
rw [f.map_neg]
[GOAL]
case intro.intro.neg
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : AddGroup.InClosure (Monoid.Closure s) a✝¹
a_ih✝ : ↑f a✝¹ ∈ closure (↑f '' s)
⊢ -↑f a✝¹ ∈ closure (↑f '' s)
[PROOFSTEP]
apply closure.isSubring.neg_mem
[GOAL]
case intro.intro.neg
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : AddGroup.InClosure (Monoid.Closure s) a✝¹
a_ih✝ : ↑f a✝¹ ∈ closure (↑f '' s)
⊢ ↑f a✝¹ ∈ closure (↑f '' s)
[PROOFSTEP]
assumption
[GOAL]
case intro.intro.add
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝² b✝ : R
a✝¹ : AddGroup.InClosure (Monoid.Closure s) a✝²
a✝ : AddGroup.InClosure (Monoid.Closure s) b✝
a_ih✝¹ : ↑f a✝² ∈ closure (↑f '' s)
a_ih✝ : ↑f b✝ ∈ closure (↑f '' s)
⊢ ↑f (a✝² + b✝) ∈ closure (↑f '' s)
[PROOFSTEP]
rw [f.map_add]
[GOAL]
case intro.intro.add
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝² b✝ : R
a✝¹ : AddGroup.InClosure (Monoid.Closure s) a✝²
a✝ : AddGroup.InClosure (Monoid.Closure s) b✝
a_ih✝¹ : ↑f a✝² ∈ closure (↑f '' s)
a_ih✝ : ↑f b✝ ∈ closure (↑f '' s)
⊢ ↑f a✝² + ↑f b✝ ∈ closure (↑f '' s)
[PROOFSTEP]
apply closure.isSubring.add_mem
[GOAL]
case intro.intro.add.a
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝² b✝ : R
a✝¹ : AddGroup.InClosure (Monoid.Closure s) a✝²
a✝ : AddGroup.InClosure (Monoid.Closure s) b✝
a_ih✝¹ : ↑f a✝² ∈ closure (↑f '' s)
a_ih✝ : ↑f b✝ ∈ closure (↑f '' s)
⊢ ↑f a✝² ∈ closure (↑f '' s)
case intro.intro.add.a
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝² b✝ : R
a✝¹ : AddGroup.InClosure (Monoid.Closure s) a✝²
a✝ : AddGroup.InClosure (Monoid.Closure s) b✝
a_ih✝¹ : ↑f a✝² ∈ closure (↑f '' s)
a_ih✝ : ↑f b✝ ∈ closure (↑f '' s)
⊢ ↑f b✝ ∈ closure (↑f '' s)
[PROOFSTEP]
assumption'
[GOAL]
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : a✝¹ ∈ Monoid.Closure s
⊢ ↑f a✝¹ ∈ closure (↑f '' s)
[PROOFSTEP]
apply AddGroup.mem_closure
[GOAL]
case a
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : a✝¹ ∈ Monoid.Closure s
⊢ ↑f a✝¹ ∈ Monoid.Closure (↑f '' s)
[PROOFSTEP]
rw [← Monoid.image_closure f.to_isMonoidHom]
[GOAL]
case a
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : a✝¹ ∈ Monoid.Closure s
⊢ ↑f a✝¹ ∈ ↑f '' Monoid.Closure s
[PROOFSTEP]
apply Set.mem_image_of_mem
[GOAL]
case a.h
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : a✝¹ ∈ Monoid.Closure s
⊢ a✝¹ ∈ Monoid.Closure s
[PROOFSTEP]
assumption