File: Mathlib/CategoryTheory/Monoidal/OfChosenFiniteProducts/Basic.lean

full_name: CategoryTheory.Limits.BinaryFan.swap
code: /-- Swap the two sides of a `BinaryFan`. -/
def BinaryFan.swap {P Q : C} (t : BinaryFan P Q) : BinaryFan Q P 
goal: CategoryTheory.Limits.BinaryFan Q P

full_name: CategoryTheory.Limits.BinaryFan.swap_fst
code: @[simp]
theorem BinaryFan.swap_fst {P Q : C} (t : BinaryFan P Q) : t.swap.fst = t.snd 
goal: t.swap.fst = t.snd

full_name: CategoryTheory.Limits.BinaryFan.swap_snd
code: @[simp]
theorem BinaryFan.swap_snd {P Q : C} (t : BinaryFan P Q) : t.swap.snd = t.fst 
goal: t.swap.snd = t.fst

full_name: CategoryTheory.Limits.IsLimit.swapBinaryFan_lift
code: /-- If a binary fan `t` over `P Q` is a limit cone, then `t.swap` is a limit cone over `Q P`.
-/
@[simps]
def IsLimit.swapBinaryFan {P Q : C} {t : BinaryFan P Q} (I : IsLimit t) : IsLimit t.swap 
goal: I.swapBinaryFan.lift s = I.lift (CategoryTheory.Limits.BinaryFan.swap s)

full_name: CategoryTheory.Limits.IsLimit.swapBinaryFan
code: /-- If a binary fan `t` over `P Q` is a limit cone, then `t.swap` is a limit cone over `Q P`.
-/
@[simps]
def IsLimit.swapBinaryFan {P Q : C} {t : BinaryFan P Q} (I : IsLimit t) : IsLimit t.swap 
goal: CategoryTheory.Limits.IsLimit t.swap

full_name: CategoryTheory.Limits.HasBinaryProduct.swap
code: /-- Construct `HasBinaryProduct Q P` from `HasBinaryProduct P Q`.
This can't be an instance, as it would cause a loop in typeclass search.
-/
theorem HasBinaryProduct.swap (P Q : C) [HasBinaryProduct P Q] : HasBinaryProduct Q P 
goal: CategoryTheory.Limits.HasBinaryProduct Q P

full_name: CategoryTheory.Limits.BinaryFan.braiding
code: /-- Given a limit cone over `X` and `Y`, and another limit cone over `Y` and `X`, we can construct
an isomorphism between the cone points. Relative to some fixed choice of limits cones for every
pair, these isomorphisms constitute a braiding.
-/
def BinaryFan.braiding {X Y : C} {s : BinaryFan X Y} (P : IsLimit s) {t : BinaryFan Y X}
    (Q : IsLimit t) : s.pt ≅ t.pt 
goal: s.pt ≅ t.pt

full_name: CategoryTheory.Limits.BinaryFan.assoc
code: /-- Given binary fans `sXY` over `X Y`, and `sYZ` over `Y Z`, and `s` over `sXY.X Z`,
if `sYZ` is a limit cone we can construct a binary fan over `X sYZ.X`.

This is an ingredient of building the associator for a cartesian category.
-/
def BinaryFan.assoc {X Y Z : C} {sXY : BinaryFan X Y} {sYZ : BinaryFan Y Z} (Q : IsLimit sYZ)
    (s : BinaryFan sXY.pt Z) : BinaryFan X sYZ.pt 
goal: CategoryTheory.Limits.BinaryFan X sYZ.pt

full_name: CategoryTheory.Limits.BinaryFan.assoc_fst
code: @[simp]
theorem BinaryFan.assoc_fst {X Y Z : C} {sXY : BinaryFan X Y} {sYZ : BinaryFan Y Z}
    (Q : IsLimit sYZ) (s : BinaryFan sXY.pt Z) : (BinaryFan.assoc Q s).fst = s.fst ≫ sXY.fst 
goal: (CategoryTheory.Limits.BinaryFan.assoc Q s).fst = CategoryTheory.CategoryStruct.comp s.fst sXY.fst

full_name: CategoryTheory.Limits.BinaryFan.assoc_snd
code: @[simp]
theorem BinaryFan.assoc_snd {X Y Z : C} {sXY : BinaryFan X Y} {sYZ : BinaryFan Y Z}
    (Q : IsLimit sYZ) (s : BinaryFan sXY.pt Z) :
    (BinaryFan.assoc Q s).snd = Q.lift (BinaryFan.mk (s.fst ≫ sXY.snd) s.snd) 
goal: (CategoryTheory.Limits.BinaryFan.assoc Q s).snd =
  Q.lift (CategoryTheory.Limits.BinaryFan.mk (CategoryTheory.CategoryStruct.comp s.fst sXY.snd) s.snd)

full_name: CategoryTheory.Limits.BinaryFan.assocInv
code: /-- Given binary fans `sXY` over `X Y`, and `sYZ` over `Y Z`, and `s` over `X sYZ.X`,
if `sYZ` is a limit cone we can construct a binary fan over `sXY.X Z`.

This is an ingredient of building the associator for a cartesian category.
-/
def BinaryFan.assocInv {X Y Z : C} {sXY : BinaryFan X Y} (P : IsLimit sXY) {sYZ : BinaryFan Y Z}
    (s : BinaryFan X sYZ.pt) : BinaryFan sXY.pt Z 
goal: CategoryTheory.Limits.BinaryFan sXY.pt Z

full_name: CategoryTheory.Limits.BinaryFan.assocInv_fst
code: @[simp]
theorem BinaryFan.assocInv_fst {X Y Z : C} {sXY : BinaryFan X Y} (P : IsLimit sXY)
    {sYZ : BinaryFan Y Z} (s : BinaryFan X sYZ.pt) :
    (BinaryFan.assocInv P s).fst = P.lift (BinaryFan.mk s.fst (s.snd ≫ sYZ.fst)) 
goal: (CategoryTheory.Limits.BinaryFan.assocInv P s).fst =
  P.lift (CategoryTheory.Limits.BinaryFan.mk s.fst (CategoryTheory.CategoryStruct.comp s.snd sYZ.fst))

full_name: CategoryTheory.Limits.BinaryFan.assocInv_snd
code: @[simp]
theorem BinaryFan.assocInv_snd {X Y Z : C} {sXY : BinaryFan X Y} (P : IsLimit sXY)
    {sYZ : BinaryFan Y Z} (s : BinaryFan X sYZ.pt) :
    (BinaryFan.assocInv P s).snd = s.snd ≫ sYZ.snd 
goal: (CategoryTheory.Limits.BinaryFan.assocInv P s).snd = CategoryTheory.CategoryStruct.comp s.snd sYZ.snd

full_name: CategoryTheory.Limits.IsLimit.assoc_lift
code: /-- If all the binary fans involved a limit cones, `BinaryFan.assoc` produces another limit cone.
-/
@[simps]
def IsLimit.assoc {X Y Z : C} {sXY : BinaryFan X Y} (P : IsLimit sXY) {sYZ : BinaryFan Y Z}
    (Q : IsLimit sYZ) {s : BinaryFan sXY.pt Z} (R : IsLimit s) : IsLimit (BinaryFan.assoc Q s) 
goal: (P.assoc Q R).lift t = R.lift (CategoryTheory.Limits.BinaryFan.assocInv P t)

full_name: CategoryTheory.Limits.IsLimit.assoc
code: /-- If all the binary fans involved a limit cones, `BinaryFan.assoc` produces another limit cone.
-/
@[simps]
def IsLimit.assoc {X Y Z : C} {sXY : BinaryFan X Y} (P : IsLimit sXY) {sYZ : BinaryFan Y Z}
    (Q : IsLimit sYZ) {s : BinaryFan sXY.pt Z} (R : IsLimit s) : IsLimit (BinaryFan.assoc Q s) 
goal: CategoryTheory.Limits.IsLimit (CategoryTheory.Limits.BinaryFan.assoc Q s)

full_name: CategoryTheory.Limits.BinaryFan.associator
code: /-- Given two pairs of limit cones corresponding to the parenthesisations of `X × Y × Z`,
we obtain an isomorphism between the cone points.
-/
abbrev BinaryFan.associator {X Y Z : C} {sXY : BinaryFan X Y} (P : IsLimit sXY)
    {sYZ : BinaryFan Y Z} (Q : IsLimit sYZ) {s : BinaryFan sXY.pt Z} (R : IsLimit s)
    {t : BinaryFan X sYZ.pt} (S : IsLimit t) : s.pt ≅ t.pt 
goal: s.pt ≅ t.pt

full_name: CategoryTheory.Limits.BinaryFan.associatorOfLimitCone
code: /-- Given a fixed family of limit data for every pair `X Y`, we obtain an associator.
-/
abbrev BinaryFan.associatorOfLimitCone (L : ∀ X Y : C, LimitCone (pair X Y)) (X Y Z : C) :
    (L (L X Y).cone.pt Z).cone.pt ≅ (L X (L Y Z).cone.pt).cone.pt 
goal: (L (L X Y).cone.pt Z).cone.pt ≅ (L X (L Y Z).cone.pt).cone.pt

full_name: CategoryTheory.Limits.BinaryFan.leftUnitor
code: /-- Construct a left unitor from specified limit cones.
-/
@[simps]
def BinaryFan.leftUnitor {X : C} {s : Cone (Functor.empty.{0} C)} (P : IsLimit s)
    {t : BinaryFan s.pt X} (Q : IsLimit t) : t.pt ≅ X 
goal: t.pt ≅ X

full_name: CategoryTheory.Limits.BinaryFan.leftUnitor_hom
code: /-- Construct a left unitor from specified limit cones.
-/
@[simps]
def BinaryFan.leftUnitor {X : C} {s : Cone (Functor.empty.{0} C)} (P : IsLimit s)
    {t : BinaryFan s.pt X} (Q : IsLimit t) : t.pt ≅ X 
goal: (CategoryTheory.Limits.BinaryFan.leftUnitor P Q).hom = t.snd

full_name: CategoryTheory.Limits.BinaryFan.leftUnitor_inv
code: /-- Construct a left unitor from specified limit cones.
-/
@[simps]
def BinaryFan.leftUnitor {X : C} {s : Cone (Functor.empty.{0} C)} (P : IsLimit s)
    {t : BinaryFan s.pt X} (Q : IsLimit t) : t.pt ≅ X 
goal: (CategoryTheory.Limits.BinaryFan.leftUnitor P Q).inv =
  Q.lift
    (CategoryTheory.Limits.BinaryFan.mk (P.lift { pt := X, π := { app := fun x => x.as.elim, naturality := ⋯ } })
      (CategoryTheory.CategoryStruct.id { pt := X, π := { app := fun x => x.as.elim, naturality := ⋯ } }.pt))

full_name: CategoryTheory.Limits.BinaryFan.rightUnitor
code: /-- Construct a right unitor from specified limit cones.
-/
@[simps]
def BinaryFan.rightUnitor {X : C} {s : Cone (Functor.empty.{0} C)} (P : IsLimit s)
    {t : BinaryFan X s.pt} (Q : IsLimit t) : t.pt ≅ X 
goal: t.pt ≅ X

full_name: CategoryTheory.Limits.BinaryFan.rightUnitor_inv
code: /-- Construct a right unitor from specified limit cones.
-/
@[simps]
def BinaryFan.rightUnitor {X : C} {s : Cone (Functor.empty.{0} C)} (P : IsLimit s)
    {t : BinaryFan X s.pt} (Q : IsLimit t) : t.pt ≅ X 
goal: (CategoryTheory.Limits.BinaryFan.rightUnitor P Q).inv =
  Q.lift
    (CategoryTheory.Limits.BinaryFan.mk (CategoryTheory.CategoryStruct.id X)
      (P.lift { pt := X, π := { app := fun x => x.as.elim, naturality := ⋯ } }))

full_name: CategoryTheory.Limits.BinaryFan.rightUnitor_hom
code: /-- Construct a right unitor from specified limit cones.
-/
@[simps]
def BinaryFan.rightUnitor {X : C} {s : Cone (Functor.empty.{0} C)} (P : IsLimit s)
    {t : BinaryFan X s.pt} (Q : IsLimit t) : t.pt ≅ X 
goal: (CategoryTheory.Limits.BinaryFan.rightUnitor P Q).hom = t.fst

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj
code: /-- Implementation of the tensor product for `MonoidalOfChosenFiniteProducts`. -/
abbrev tensorObj (X Y : C) : C 
goal: C

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom
code: /-- Implementation of the tensor product of morphisms for `MonoidalOfChosenFiniteProducts`. -/
abbrev tensorHom {W X Y Z : C} (f : W ⟶ X) (g : Y ⟶ Z) : tensorObj ℬ W Y ⟶ tensorObj ℬ X Z 
goal: CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj ℬ W Y ⟶
  CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj ℬ X Z

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.tensor_id
code: theorem tensor_id (X₁ X₂ : C) : tensorHom ℬ (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj ℬ X₁ X₂) 
goal: CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ (CategoryTheory.CategoryStruct.id X₁)
    (CategoryTheory.CategoryStruct.id X₂) =
  CategoryTheory.CategoryStruct.id (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj ℬ X₁ X₂)

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.tensor_comp
code: theorem tensor_comp {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁)
    (g₂ : Y₂ ⟶ Z₂) : tensorHom ℬ (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom ℬ f₁ f₂ ≫ tensorHom ℬ g₁ g₂ 
goal: CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ (CategoryTheory.CategoryStruct.comp f₁ g₁)
    (CategoryTheory.CategoryStruct.comp f₂ g₂) =
  CategoryTheory.CategoryStruct.comp (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ f₁ f₂)
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ g₁ g₂)

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.pentagon
code: theorem pentagon (W X Y Z : C) :
    tensorHom ℬ (BinaryFan.associatorOfLimitCone ℬ W X Y).hom (𝟙 Z) ≫
        (BinaryFan.associatorOfLimitCone ℬ W (tensorObj ℬ X Y) Z).hom ≫
          tensorHom ℬ (𝟙 W) (BinaryFan.associatorOfLimitCone ℬ X Y Z).hom =
      (BinaryFan.associatorOfLimitCone ℬ (tensorObj ℬ W X) Y Z).hom ≫
        (BinaryFan.associatorOfLimitCone ℬ W X (tensorObj ℬ Y Z)).hom 
goal: CategoryTheory.CategoryStruct.comp
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ
      (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ W X Y).hom (CategoryTheory.CategoryStruct.id Z))
    (CategoryTheory.CategoryStruct.comp
      (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ W
          (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj ℬ X Y) Z).hom
      (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ (CategoryTheory.CategoryStruct.id W)
        (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ X Y Z).hom)) =
  CategoryTheory.CategoryStruct.comp
    (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ
        (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj ℬ W X) Y Z).hom
    (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ W X
        (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorObj ℬ Y Z)).hom

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.triangle
code: theorem triangle (X Y : C) :
    (BinaryFan.associatorOfLimitCone ℬ X 𝒯.cone.pt Y).hom ≫
        tensorHom ℬ (𝟙 X) (BinaryFan.leftUnitor 𝒯.isLimit (ℬ 𝒯.cone.pt Y).isLimit).hom =
      tensorHom ℬ (BinaryFan.rightUnitor 𝒯.isLimit (ℬ X 𝒯.cone.pt).isLimit).hom (𝟙 Y) 
goal: CategoryTheory.CategoryStruct.comp (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ X 𝒯.cone.pt Y).hom
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ (CategoryTheory.CategoryStruct.id X)
      (CategoryTheory.Limits.BinaryFan.leftUnitor 𝒯.isLimit (ℬ 𝒯.cone.pt Y).isLimit).hom) =
  CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ
    (CategoryTheory.Limits.BinaryFan.rightUnitor 𝒯.isLimit (ℬ X 𝒯.cone.pt).isLimit).hom
    (CategoryTheory.CategoryStruct.id Y)

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.leftUnitor_naturality
code: theorem leftUnitor_naturality {X₁ X₂ : C} (f : X₁ ⟶ X₂) :
    tensorHom ℬ (𝟙 𝒯.cone.pt) f ≫ (BinaryFan.leftUnitor 𝒯.isLimit (ℬ 𝒯.cone.pt X₂).isLimit).hom =
      (BinaryFan.leftUnitor 𝒯.isLimit (ℬ 𝒯.cone.pt X₁).isLimit).hom ≫ f 
goal: CategoryTheory.CategoryStruct.comp
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ (CategoryTheory.CategoryStruct.id 𝒯.cone.pt) f)
    (CategoryTheory.Limits.BinaryFan.leftUnitor 𝒯.isLimit (ℬ 𝒯.cone.pt X₂).isLimit).hom =
  CategoryTheory.CategoryStruct.comp (CategoryTheory.Limits.BinaryFan.leftUnitor 𝒯.isLimit (ℬ 𝒯.cone.pt X₁).isLimit).hom
    f

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.rightUnitor_naturality
code: theorem rightUnitor_naturality {X₁ X₂ : C} (f : X₁ ⟶ X₂) :
    tensorHom ℬ f (𝟙 𝒯.cone.pt) ≫ (BinaryFan.rightUnitor 𝒯.isLimit (ℬ X₂ 𝒯.cone.pt).isLimit).hom =
      (BinaryFan.rightUnitor 𝒯.isLimit (ℬ X₁ 𝒯.cone.pt).isLimit).hom ≫ f 
goal: CategoryTheory.CategoryStruct.comp
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ f (CategoryTheory.CategoryStruct.id 𝒯.cone.pt))
    (CategoryTheory.Limits.BinaryFan.rightUnitor 𝒯.isLimit (ℬ X₂ 𝒯.cone.pt).isLimit).hom =
  CategoryTheory.CategoryStruct.comp
    (CategoryTheory.Limits.BinaryFan.rightUnitor 𝒯.isLimit (ℬ X₁ 𝒯.cone.pt).isLimit).hom f

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.associator_naturality
code: theorem associator_naturality {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃) :
    tensorHom ℬ (tensorHom ℬ f₁ f₂) f₃ ≫ (BinaryFan.associatorOfLimitCone ℬ Y₁ Y₂ Y₃).hom =
      (BinaryFan.associatorOfLimitCone ℬ X₁ X₂ X₃).hom ≫ tensorHom ℬ f₁ (tensorHom ℬ f₂ f₃) 
goal: CategoryTheory.CategoryStruct.comp
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ
      (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ f₁ f₂) f₃)
    (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ Y₁ Y₂ Y₃).hom =
  CategoryTheory.CategoryStruct.comp (CategoryTheory.Limits.BinaryFan.associatorOfLimitCone ℬ X₁ X₂ X₃).hom
    (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ f₁
      (CategoryTheory.MonoidalOfChosenFiniteProducts.tensorHom ℬ f₂ f₃))

full_name: CategoryTheory.monoidalOfChosenFiniteProducts
code: /-- A category with a terminal object and binary products has a natural monoidal structure. -/
def monoidalOfChosenFiniteProducts : MonoidalCategory C 
goal: CategoryTheory.MonoidalCategory C

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.MonoidalOfChosenFiniteProductsSynonym
code: /-- A type synonym for `C` carrying a monoidal category structure corresponding to
a fixed choice of limit data for the empty functor, and for `pair X Y` for every `X Y : C`.

This is an implementation detail for `SymmetricOfChosenFiniteProducts`.
-/
-- Porting note(#5171): linter `has_nonempty_instance` not ported yet
-- @[nolint has_nonempty_instance]
@[nolint unusedArguments]
def MonoidalOfChosenFiniteProductsSynonym (_𝒯 : LimitCone (Functor.empty.{0} C))
    (_ℬ : ∀ X Y : C, LimitCone (pair X Y)) 
goal: Type u

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.instCategoryMonoidalOfChosenFiniteProductsSynonym
code: instance : Category (MonoidalOfChosenFiniteProductsSynonym 𝒯 ℬ) 
goal: CategoryTheory.Category.{v, u} (CategoryTheory.MonoidalOfChosenFiniteProducts.MonoidalOfChosenFiniteProductsSynonym 𝒯 ℬ)

full_name: CategoryTheory.MonoidalOfChosenFiniteProducts.instMonoidalCategoryMonoidalOfChosenFiniteProductsSynonym
code: instance : MonoidalCategory (MonoidalOfChosenFiniteProductsSynonym 𝒯 ℬ) 
goal: CategoryTheory.MonoidalCategory
  (CategoryTheory.MonoidalOfChosenFiniteProducts.MonoidalOfChosenFiniteProductsSynonym 𝒯 ℬ)