category_theory.pempty
⟷
Mathlib.CategoryTheory.PEmpty
The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(last sync)
mathlib commit https://github.com/leanprover-community/mathlib/commit/3365b20c2ffa7c35e47e5209b89ba9abdddf3ffe
@@ -26,15 +26,15 @@ namespace Functor
variable (C : Type u) [Category.{v} C]
-#print CategoryTheory.Functor.emptyEquivalence /-
+#print CategoryTheory.emptyEquivalence /-
/-- Equivalence between two empty categories. -/
-def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
+def CategoryTheory.emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
Equivalence.mk
{ obj := PEmpty.elim ∘ Discrete.as
map := fun x => x.as.elim }
{ obj := PEmpty.elim ∘ Discrete.as
map := fun x => x.as.elim } (by tidy) (by tidy)
-#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalence
+#align category_theory.functor.empty_equivalence CategoryTheory.emptyEquivalence
-/
#print CategoryTheory.Functor.empty /-
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce64cd319bb6b3e82f31c2d38e79080d377be451
@@ -3,7 +3,7 @@ Copyright (c) 2018 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Bhavik Mehta
-/
-import Mathbin.CategoryTheory.DiscreteCategory
+import CategoryTheory.DiscreteCategory
#align_import category_theory.pempty from "leanprover-community/mathlib"@"23aa88e32dcc9d2a24cca7bc23268567ed4cd7d6"
mathlib commit https://github.com/leanprover-community/mathlib/commit/8ea5598db6caeddde6cb734aa179cc2408dbd345
@@ -2,14 +2,11 @@
Copyright (c) 2018 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Bhavik Mehta
-
-! This file was ported from Lean 3 source module category_theory.pempty
-! leanprover-community/mathlib commit 23aa88e32dcc9d2a24cca7bc23268567ed4cd7d6
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathbin.CategoryTheory.DiscreteCategory
+#align_import category_theory.pempty from "leanprover-community/mathlib"@"23aa88e32dcc9d2a24cca7bc23268567ed4cd7d6"
+
/-!
# The empty category
mathlib commit https://github.com/leanprover-community/mathlib/commit/9fb8964792b4237dac6200193a0d533f1b3f7423
@@ -29,6 +29,7 @@ namespace Functor
variable (C : Type u) [Category.{v} C]
+#print CategoryTheory.Functor.emptyEquivalence /-
/-- Equivalence between two empty categories. -/
def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
Equivalence.mk
@@ -37,6 +38,7 @@ def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
{ obj := PEmpty.elim ∘ Discrete.as
map := fun x => x.as.elim } (by tidy) (by tidy)
#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalence
+-/
#print CategoryTheory.Functor.empty /-
/-- The canonical functor out of the empty category. -/
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -29,12 +29,6 @@ namespace Functor
variable (C : Type u) [Category.{v} C]
-/- warning: category_theory.functor.empty_equivalence -> CategoryTheory.Functor.emptyEquivalence is a dubious translation:
-lean 3 declaration is
- CategoryTheory.Equivalence.{u1, u2, u1, u2} (CategoryTheory.Discrete.{u1} PEmpty.{succ u1}) (CategoryTheory.discreteCategory.{u1} PEmpty.{succ u1}) (CategoryTheory.Discrete.{u2} PEmpty.{succ u2}) (CategoryTheory.discreteCategory.{u2} PEmpty.{succ u2})
-but is expected to have type
- CategoryTheory.Equivalence.{u1, u2, u1, u2} (CategoryTheory.Discrete.{u1} PEmpty.{succ u1}) (CategoryTheory.Discrete.{u2} PEmpty.{succ u2}) (CategoryTheory.discreteCategory.{u1} PEmpty.{succ u1}) (CategoryTheory.discreteCategory.{u2} PEmpty.{succ u2})
-Case conversion may be inaccurate. Consider using '#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalenceₓ'. -/
/-- Equivalence between two empty categories. -/
def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
Equivalence.mk
mathlib commit https://github.com/leanprover-community/mathlib/commit/3ade05ac9447ae31a22d2ea5423435e054131240
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Bhavik Mehta
! This file was ported from Lean 3 source module category_theory.pempty
-! leanprover-community/mathlib commit c9c9fa15fec7ca18e9ec97306fb8764bfe988a7e
+! leanprover-community/mathlib commit 23aa88e32dcc9d2a24cca7bc23268567ed4cd7d6
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -13,6 +13,9 @@ import Mathbin.CategoryTheory.DiscreteCategory
/-!
# The empty category
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
Defines a category structure on `pempty`, and the unique functor `pempty ⥤ C` for any category `C`.
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
@@ -26,6 +26,12 @@ namespace Functor
variable (C : Type u) [Category.{v} C]
+/- warning: category_theory.functor.empty_equivalence -> CategoryTheory.Functor.emptyEquivalence is a dubious translation:
+lean 3 declaration is
+ CategoryTheory.Equivalence.{u1, u2, u1, u2} (CategoryTheory.Discrete.{u1} PEmpty.{succ u1}) (CategoryTheory.discreteCategory.{u1} PEmpty.{succ u1}) (CategoryTheory.Discrete.{u2} PEmpty.{succ u2}) (CategoryTheory.discreteCategory.{u2} PEmpty.{succ u2})
+but is expected to have type
+ CategoryTheory.Equivalence.{u1, u2, u1, u2} (CategoryTheory.Discrete.{u1} PEmpty.{succ u1}) (CategoryTheory.Discrete.{u2} PEmpty.{succ u2}) (CategoryTheory.discreteCategory.{u1} PEmpty.{succ u1}) (CategoryTheory.discreteCategory.{u2} PEmpty.{succ u2})
+Case conversion may be inaccurate. Consider using '#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalenceₓ'. -/
/-- Equivalence between two empty categories. -/
def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
Equivalence.mk
@@ -35,31 +41,39 @@ def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty :=
map := fun x => x.as.elim } (by tidy) (by tidy)
#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalence
+#print CategoryTheory.Functor.empty /-
/-- The canonical functor out of the empty category. -/
def empty : Discrete.{w} PEmpty ⥤ C :=
Discrete.functor PEmpty.elim
#align category_theory.functor.empty CategoryTheory.Functor.empty
+-/
variable {C}
+#print CategoryTheory.Functor.emptyExt /-
/-- Any two functors out of the empty category are isomorphic. -/
def emptyExt (F G : Discrete.{w} PEmpty ⥤ C) : F ≅ G :=
Discrete.natIso fun x => x.as.elim
#align category_theory.functor.empty_ext CategoryTheory.Functor.emptyExt
+-/
+#print CategoryTheory.Functor.uniqueFromEmpty /-
/-- Any functor out of the empty category is isomorphic to the canonical functor from the empty
category.
-/
def uniqueFromEmpty (F : Discrete.{w} PEmpty ⥤ C) : F ≅ empty C :=
emptyExt _ _
#align category_theory.functor.unique_from_empty CategoryTheory.Functor.uniqueFromEmpty
+-/
+#print CategoryTheory.Functor.empty_ext' /-
/-- Any two functors out of the empty category are *equal*. You probably want to use
`empty_ext` instead of this.
-/
theorem empty_ext' (F G : Discrete.{w} PEmpty ⥤ C) : F = G :=
Functor.ext (fun x => x.as.elim) fun x _ _ => x.as.elim
#align category_theory.functor.empty_ext' CategoryTheory.Functor.empty_ext'
+-/
end Functor
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
Also moves the definition of van Kampen colimits from CategoryTheory/Extensive.lean
into a new file.
Co-authored-by: Andrew Yang <36414270+erdOne@users.noreply.github.com> Co-authored-by: Mario Carneiro <di.gama@gmail.com>
@@ -13,29 +13,42 @@ import Mathlib.CategoryTheory.DiscreteCategory
Defines a category structure on `PEmpty`, and the unique functor `PEmpty ⥤ C` for any category `C`.
-/
-universe w v u
+universe w v v' u u'
-- morphism levels before object levels. See note [CategoryTheory universes].
namespace CategoryTheory
-namespace Functor
+variable (C : Type u) [Category.{v} C] (D : Type u') [Category.{v'} D]
+
+instance (α : Type*) [IsEmpty α] : IsEmpty (Discrete α) := Function.isEmpty Discrete.as
+
+/-- The (unique) functor from an empty category. -/
+def functorOfIsEmpty [IsEmpty C] : C ⥤ D where
+ obj := isEmptyElim
+ map := fun {X} ↦ isEmptyElim X
+ map_id := fun {X} ↦ isEmptyElim X
+ map_comp := fun {X} ↦ isEmptyElim X
+
+variable {C D}
-variable (C : Type u) [Category.{v} C]
+/-- Any two functors out of an empty category are isomorphic. -/
+def Functor.isEmptyExt [IsEmpty C] (F G : C ⥤ D) : F ≅ G :=
+ NatIso.ofComponents isEmptyElim (fun {X} ↦ isEmptyElim X)
+
+variable (C D)
+
+/-- The equivalence between two empty categories. -/
+def equivalenceOfIsEmpty [IsEmpty C] [IsEmpty D] : C ≌ D where
+ functor := functorOfIsEmpty C D
+ inverse := functorOfIsEmpty D C
+ unitIso := Functor.isEmptyExt _ _
+ counitIso := Functor.isEmptyExt _ _
+ functor_unitIso_comp := isEmptyElim
/-- Equivalence between two empty categories. -/
-def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty where
- functor :=
- { obj := PEmpty.elim ∘ Discrete.as
- map := fun {X} _ _ => X.as.elim }
- inverse :=
- { obj := PEmpty.elim ∘ Discrete.as
- map := fun {X} _ _ => X.as.elim }
- unitIso :=
- { hom := { app := fun X => X.as.elim }
- inv := { app := fun X => X.as.elim } }
- counitIso :=
- { hom := { app := fun X => X.as.elim }
- inv := { app := fun X => X.as.elim } }
-#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalence
+def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty := equivalenceOfIsEmpty _ _
+#align category_theory.functor.empty_equivalence CategoryTheory.emptyEquivalence
+
+namespace Functor
/-- The canonical functor out of the empty category. -/
def empty : Discrete.{w} PEmpty ⥤ C :=
@@ -2,14 +2,11 @@
Copyright (c) 2018 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Bhavik Mehta
-
-! This file was ported from Lean 3 source module category_theory.pempty
-! leanprover-community/mathlib commit 2738d2ca56cbc63be80c3bd48e9ed90ad94e947d
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathlib.CategoryTheory.DiscreteCategory
+#align_import category_theory.pempty from "leanprover-community/mathlib"@"2738d2ca56cbc63be80c3bd48e9ed90ad94e947d"
+
/-!
# The empty category
Adds a global Aesop cases
rule for the Discrete
category. This rule was previously added locally in several places.
@@ -16,8 +16,6 @@ import Mathlib.CategoryTheory.DiscreteCategory
Defines a category structure on `PEmpty`, and the unique functor `PEmpty ⥤ C` for any category `C`.
-/
--- Porting note: this file stressed Lean a good deal despite its length
-
universe w v u
-- morphism levels before object levels. See note [CategoryTheory universes].
namespace CategoryTheory
@@ -25,33 +25,21 @@ namespace CategoryTheory
namespace Functor
variable (C : Type u) [Category.{v} C]
-/- Porting note: `aesop_cat` could not close any of the goals `tidy` did.
-Switched to more explicit construction -/
+
/-- Equivalence between two empty categories. -/
def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty where
functor :=
{ obj := PEmpty.elim ∘ Discrete.as
- map := fun {X} _ _ => X.as.elim
- map_comp := fun {X} _ _ _ _ => X.as.elim }
+ map := fun {X} _ _ => X.as.elim }
inverse :=
{ obj := PEmpty.elim ∘ Discrete.as
- map := fun {X} _ _ => X.as.elim
- map_comp := fun {X} _ _ _ _ => X.as.elim }
+ map := fun {X} _ _ => X.as.elim }
unitIso :=
- { hom :=
- { app := fun X => X.as.elim
- naturality := fun {X} _ _ => X.as.elim }
- inv :=
- { app := fun X => X.as.elim
- naturality := fun {X} _ _ => X.as.elim } }
+ { hom := { app := fun X => X.as.elim }
+ inv := { app := fun X => X.as.elim } }
counitIso :=
- { hom :=
- { app := fun X => X.as.elim
- naturality := fun {X} _ _ => X.as.elim }
- inv :=
- { app := fun X => X.as.elim
- naturality := fun {X} _ _ => X.as.elim } }
- functor_unitIso_comp := fun X => X.as.elim
+ { hom := { app := fun X => X.as.elim }
+ inv := { app := fun X => X.as.elim } }
#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalence
/-- The canonical functor out of the empty category. -/
I ran codespell Mathlib
and got tired halfway through the suggestions.
@@ -26,7 +26,7 @@ namespace Functor
variable (C : Type u) [Category.{v} C]
/- Porting note: `aesop_cat` could not close any of the goals `tidy` did.
-Switched to more explict construction -/
+Switched to more explicit construction -/
/-- Equivalence between two empty categories. -/
def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty where
functor :=
vscode is already configured by .vscode/settings.json
to trim these on save. It's not clear how they've managed to stick around.
By doing this all in one PR now, it avoids getting random whitespace diffs in PRs later.
This was done with a regex search in vscode,
@@ -25,33 +25,33 @@ namespace CategoryTheory
namespace Functor
variable (C : Type u) [Category.{v} C]
-/- Porting note: `aesop_cat` could not close any of the goals `tidy` did.
+/- Porting note: `aesop_cat` could not close any of the goals `tidy` did.
Switched to more explict construction -/
/-- Equivalence between two empty categories. -/
-def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty where
- functor :=
+def emptyEquivalence : Discrete.{w} PEmpty ≌ Discrete.{v} PEmpty where
+ functor :=
{ obj := PEmpty.elim ∘ Discrete.as
- map := fun {X} _ _ => X.as.elim
+ map := fun {X} _ _ => X.as.elim
map_comp := fun {X} _ _ _ _ => X.as.elim }
- inverse :=
+ inverse :=
{ obj := PEmpty.elim ∘ Discrete.as
- map := fun {X} _ _ => X.as.elim
+ map := fun {X} _ _ => X.as.elim
map_comp := fun {X} _ _ _ _ => X.as.elim }
- unitIso :=
- { hom :=
- { app := fun X => X.as.elim
+ unitIso :=
+ { hom :=
+ { app := fun X => X.as.elim
naturality := fun {X} _ _ => X.as.elim }
- inv :=
- { app := fun X => X.as.elim
+ inv :=
+ { app := fun X => X.as.elim
naturality := fun {X} _ _ => X.as.elim } }
- counitIso :=
- { hom :=
- { app := fun X => X.as.elim
+ counitIso :=
+ { hom :=
+ { app := fun X => X.as.elim
naturality := fun {X} _ _ => X.as.elim }
- inv :=
- { app := fun X => X.as.elim
+ inv :=
+ { app := fun X => X.as.elim
naturality := fun {X} _ _ => X.as.elim } }
- functor_unitIso_comp := fun X => X.as.elim
+ functor_unitIso_comp := fun X => X.as.elim
#align category_theory.functor.empty_equivalence CategoryTheory.Functor.emptyEquivalence
/-- The canonical functor out of the empty category. -/
@@ -83,4 +83,3 @@ theorem empty_ext' (F G : Discrete.{w} PEmpty ⥤ C) : F = G :=
end Functor
end CategoryTheory
-
All dependencies are ported!