File: Mathlib/CategoryTheory/Limits/Bicones.lean

full_name: CategoryTheory.Bicone.diagram
code: /-- Given a category `J`, construct a walking `Bicone J` by adjoining two elements. -/
inductive Bicone (J : Type u₁)
  | left : Bicone J
  | right : Bicone J
  | diagram (val : J) : Bicone J
  deriving DecidableEq
goal: CategoryTheory.Bicone J

full_name: CategoryTheory.Bicone
code: /-- Given a category `J`, construct a walking `Bicone J` by adjoining two elements. -/
inductive Bicone (J : Type u₁)
  | left : Bicone J
  | right : Bicone J
  | diagram (val : J) : Bicone J
  deriving DecidableEq
goal: Type u₁

full_name: CategoryTheory.Bicone.right
code: /-- Given a category `J`, construct a walking `Bicone J` by adjoining two elements. -/
inductive Bicone (J : Type u₁)
  | left : Bicone J
  | right : Bicone J
  | diagram (val : J) : Bicone J
  deriving DecidableEq
goal: CategoryTheory.Bicone J

full_name: CategoryTheory.Bicone.left
code: /-- Given a category `J`, construct a walking `Bicone J` by adjoining two elements. -/
inductive Bicone (J : Type u₁)
  | left : Bicone J
  | right : Bicone J
  | diagram (val : J) : Bicone J
  deriving DecidableEq
goal: CategoryTheory.Bicone J

full_name: CategoryTheory.instInhabitedBicone
code: instance : Inhabited (Bicone J) 
goal: Inhabited (CategoryTheory.Bicone J)

full_name: CategoryTheory.finBicone
code: instance finBicone [Fintype J] : Fintype (Bicone J) 
goal: Fintype (CategoryTheory.Bicone J)

full_name: CategoryTheory.BiconeHom.right
code: /-- The homs for a walking `Bicone J`. -/
inductive BiconeHom : Bicone J → Bicone J → Type max u₁ v₁
  | left_id : BiconeHom Bicone.left Bicone.left
  | right_id : BiconeHom Bicone.right Bicone.right
  | left (j : J) : BiconeHom Bicone.left (Bicone.diagram j)
  | right (j : J) : BiconeHom Bicone.right (Bicone.diagram j)
  | diagram {j k : J} (f : j ⟶ k) : BiconeHom (Bicone.diagram j) (Bicone.diagram k)
goal: CategoryTheory.BiconeHom J CategoryTheory.Bicone.right (CategoryTheory.Bicone.diagram j)

full_name: CategoryTheory.BiconeHom.left_id
code: /-- The homs for a walking `Bicone J`. -/
inductive BiconeHom : Bicone J → Bicone J → Type max u₁ v₁
  | left_id : BiconeHom Bicone.left Bicone.left
  | right_id : BiconeHom Bicone.right Bicone.right
  | left (j : J) : BiconeHom Bicone.left (Bicone.diagram j)
  | right (j : J) : BiconeHom Bicone.right (Bicone.diagram j)
  | diagram {j k : J} (f : j ⟶ k) : BiconeHom (Bicone.diagram j) (Bicone.diagram k)
goal: CategoryTheory.BiconeHom J CategoryTheory.Bicone.left CategoryTheory.Bicone.left

full_name: CategoryTheory.BiconeHom
code: /-- The homs for a walking `Bicone J`. -/
inductive BiconeHom : Bicone J → Bicone J → Type max u₁ v₁
  | left_id : BiconeHom Bicone.left Bicone.left
  | right_id : BiconeHom Bicone.right Bicone.right
  | left (j : J) : BiconeHom Bicone.left (Bicone.diagram j)
  | right (j : J) : BiconeHom Bicone.right (Bicone.diagram j)
  | diagram {j k : J} (f : j ⟶ k) : BiconeHom (Bicone.diagram j) (Bicone.diagram k)
goal: CategoryTheory.Bicone J → CategoryTheory.Bicone J → Type (max u₁ v₁)

full_name: CategoryTheory.BiconeHom.right_id
code: /-- The homs for a walking `Bicone J`. -/
inductive BiconeHom : Bicone J → Bicone J → Type max u₁ v₁
  | left_id : BiconeHom Bicone.left Bicone.left
  | right_id : BiconeHom Bicone.right Bicone.right
  | left (j : J) : BiconeHom Bicone.left (Bicone.diagram j)
  | right (j : J) : BiconeHom Bicone.right (Bicone.diagram j)
  | diagram {j k : J} (f : j ⟶ k) : BiconeHom (Bicone.diagram j) (Bicone.diagram k)
goal: CategoryTheory.BiconeHom J CategoryTheory.Bicone.right CategoryTheory.Bicone.right

full_name: CategoryTheory.BiconeHom.diagram
code: /-- The homs for a walking `Bicone J`. -/
inductive BiconeHom : Bicone J → Bicone J → Type max u₁ v₁
  | left_id : BiconeHom Bicone.left Bicone.left
  | right_id : BiconeHom Bicone.right Bicone.right
  | left (j : J) : BiconeHom Bicone.left (Bicone.diagram j)
  | right (j : J) : BiconeHom Bicone.right (Bicone.diagram j)
  | diagram {j k : J} (f : j ⟶ k) : BiconeHom (Bicone.diagram j) (Bicone.diagram k)
goal: CategoryTheory.BiconeHom J (CategoryTheory.Bicone.diagram j) (CategoryTheory.Bicone.diagram k)

full_name: CategoryTheory.BiconeHom.left
code: /-- The homs for a walking `Bicone J`. -/
inductive BiconeHom : Bicone J → Bicone J → Type max u₁ v₁
  | left_id : BiconeHom Bicone.left Bicone.left
  | right_id : BiconeHom Bicone.right Bicone.right
  | left (j : J) : BiconeHom Bicone.left (Bicone.diagram j)
  | right (j : J) : BiconeHom Bicone.right (Bicone.diagram j)
  | diagram {j k : J} (f : j ⟶ k) : BiconeHom (Bicone.diagram j) (Bicone.diagram k)
goal: CategoryTheory.BiconeHom J CategoryTheory.Bicone.left (CategoryTheory.Bicone.diagram j)

full_name: CategoryTheory.instInhabitedBiconeHomLeft
code: instance : Inhabited (BiconeHom J Bicone.left Bicone.left) 
goal: Inhabited (CategoryTheory.BiconeHom J CategoryTheory.Bicone.left CategoryTheory.Bicone.left)

full_name: CategoryTheory.BiconeHom.decidableEq
code: instance BiconeHom.decidableEq {j k : Bicone J} : DecidableEq (BiconeHom J j k) 
goal: DecidableEq (CategoryTheory.BiconeHom J j k)

full_name: CategoryTheory.biconeCategoryStruct
code: @[simps]
instance biconeCategoryStruct : CategoryStruct (Bicone J) 
goal: CategoryTheory.CategoryStruct.{max u₁ v₁, u₁} (CategoryTheory.Bicone J)

full_name: CategoryTheory.biconeCategoryStruct_id
code: @[simps]
instance biconeCategoryStruct : CategoryStruct (Bicone J) 
goal: CategoryTheory.CategoryStruct.id j =
  CategoryTheory.Bicone.casesOn j CategoryTheory.BiconeHom.left_id CategoryTheory.BiconeHom.right_id fun k =>
    CategoryTheory.BiconeHom.diagram (CategoryTheory.CategoryStruct.id k)

full_name: CategoryTheory.biconeCategoryStruct_Hom
code: @[simps]
instance biconeCategoryStruct : CategoryStruct (Bicone J) 
goal: ∀ (a a_1 : CategoryTheory.Bicone J), (a ⟶ a_1) = CategoryTheory.BiconeHom J a a_1

full_name: CategoryTheory.biconeCategoryStruct_comp
code: @[simps]
instance biconeCategoryStruct : CategoryStruct (Bicone J) 
goal: ∀ {X Y Z : CategoryTheory.Bicone J} (f : X ⟶ Y) (g : Y ⟶ Z),
  CategoryTheory.CategoryStruct.comp f g =
    CategoryTheory.BiconeHom.casesOn (motive := fun a a_1 x => X = a → Y = a_1 → HEq f x → (X ⟶ Z)) f
      (fun h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) → Y = CategoryTheory.Bicone.left → HEq f CategoryTheory.BiconeHom.left_id → (X ⟶ Z))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (Y ⟶ Z) →
                (f : CategoryTheory.Bicone.left ⟶ Y) →
                  HEq f CategoryTheory.BiconeHom.left_id → (CategoryTheory.Bicone.left ⟶ Z))
              (fun g f h => g) ⋯ g f)
          ⋯ f)
      (fun h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) → Y = CategoryTheory.Bicone.right → HEq f CategoryTheory.BiconeHom.right_id → (X ⟶ Z))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (Y ⟶ Z) →
                (f : CategoryTheory.Bicone.right ⟶ Y) →
                  HEq f CategoryTheory.BiconeHom.right_id → (CategoryTheory.Bicone.right ⟶ Z))
              (fun g f h => g) ⋯ g f)
          ⋯ f)
      (fun j h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) → Y = CategoryTheory.Bicone.diagram j → HEq f (CategoryTheory.BiconeHom.left j) → (X ⟶ Z))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (Y ⟶ Z) →
                (f : CategoryTheory.Bicone.left ⟶ Y) →
                  HEq f (CategoryTheory.BiconeHom.left j) → (CategoryTheory.Bicone.left ⟶ Z))
              (fun g f h =>
                CategoryTheory.BiconeHom.casesOn (motive := fun a a_1 t =>
                  CategoryTheory.Bicone.diagram j = a → Z = a_1 → HEq g t → (CategoryTheory.Bicone.left ⟶ Z)) g
                  (fun h => CategoryTheory.Bicone.noConfusion h) (fun h => CategoryTheory.Bicone.noConfusion h)
                  (fun j_1 h => CategoryTheory.Bicone.noConfusion h) (fun j_1 h => CategoryTheory.Bicone.noConfusion h)
                  (fun {j_1 k} f h =>
                    CategoryTheory.Bicone.noConfusion h fun val_eq =>
                      Eq.ndrec (motive := fun {j_2} =>
                        (f : j_2 ⟶ k) →
                          Z = CategoryTheory.Bicone.diagram k →
                            HEq g (CategoryTheory.BiconeHom.diagram f) → (CategoryTheory.Bicone.left ⟶ Z))
                        (fun f h =>
                          Eq.ndrec (motive := fun {Z} =>
                            (g : CategoryTheory.Bicone.diagram j ⟶ Z) →
                              HEq g (CategoryTheory.BiconeHom.diagram f) → (CategoryTheory.Bicone.left ⟶ Z))
                            (fun g h => CategoryTheory.BiconeHom.left k) ⋯ g)
                        val_eq f)
                  ⋯ ⋯ ⋯)
              ⋯ g f)
          ⋯ f)
      (fun j h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) → Y = CategoryTheory.Bicone.diagram j → HEq f (CategoryTheory.BiconeHom.right j) → (X ⟶ Z))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (Y ⟶ Z) →
                (f : CategoryTheory.Bicone.right ⟶ Y) →
                  HEq f (CategoryTheory.BiconeHom.right j) → (CategoryTheory.Bicone.right ⟶ Z))
              (fun g f h =>
                CategoryTheory.BiconeHom.casesOn (motive := fun a a_1 t =>
                  CategoryTheory.Bicone.diagram j = a → Z = a_1 → HEq g t → (CategoryTheory.Bicone.right ⟶ Z)) g
                  (fun h => CategoryTheory.Bicone.noConfusion h) (fun h => CategoryTheory.Bicone.noConfusion h)
                  (fun j_1 h => CategoryTheory.Bicone.noConfusion h) (fun j_1 h => CategoryTheory.Bicone.noConfusion h)
                  (fun {j_1 k} f h =>
                    CategoryTheory.Bicone.noConfusion h fun val_eq =>
                      Eq.ndrec (motive := fun {j_2} =>
                        (f : j_2 ⟶ k) →
                          Z = CategoryTheory.Bicone.diagram k →
                            HEq g (CategoryTheory.BiconeHom.diagram f) → (CategoryTheory.Bicone.right ⟶ Z))
                        (fun f h =>
                          Eq.ndrec (motive := fun {Z} =>
                            (g : CategoryTheory.Bicone.diagram j ⟶ Z) →
                              HEq g (CategoryTheory.BiconeHom.diagram f) → (CategoryTheory.Bicone.right ⟶ Z))
                            (fun g h => CategoryTheory.BiconeHom.right k) ⋯ g)
                        val_eq f)
                  ⋯ ⋯ ⋯)
              ⋯ g f)
          ⋯ f)
      (fun {j k} f_1 h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) → Y = CategoryTheory.Bicone.diagram k → HEq f (CategoryTheory.BiconeHom.diagram f_1) → (X ⟶ Z))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (Y ⟶ Z) →
                (f : CategoryTheory.Bicone.diagram j ⟶ Y) →
                  HEq f (CategoryTheory.BiconeHom.diagram f_1) → (CategoryTheory.Bicone.diagram j ⟶ Z))
              (fun g f h =>
                CategoryTheory.BiconeHom.casesOn (motive := fun a a_1 x =>
                  CategoryTheory.Bicone.diagram k = a → Z = a_1 → HEq g x → (CategoryTheory.Bicone.diagram j ⟶ Z)) g
                  (fun h => CategoryTheory.Bicone.noConfusion h) (fun h => CategoryTheory.Bicone.noConfusion h)
                  (fun j_1 h => CategoryTheory.Bicone.noConfusion h) (fun j_1 h => CategoryTheory.Bicone.noConfusion h)
                  (fun {j_1 k_1} g_1 h =>
                    CategoryTheory.Bicone.noConfusion h fun val_eq =>
                      Eq.ndrec (motive := fun {j_2} =>
                        (g_2 : j_2 ⟶ k_1) →
                          Z = CategoryTheory.Bicone.diagram k_1 →
                            HEq g (CategoryTheory.BiconeHom.diagram g_2) → (CategoryTheory.Bicone.diagram j ⟶ Z))
                        (fun g_2 h =>
                          Eq.ndrec (motive := fun {Z} =>
                            (g : CategoryTheory.Bicone.diagram k ⟶ Z) →
                              HEq g (CategoryTheory.BiconeHom.diagram g_2) → (CategoryTheory.Bicone.diagram j ⟶ Z))
                            (fun g h => CategoryTheory.BiconeHom.diagram (CategoryTheory.CategoryStruct.comp f_1 g_2)) ⋯
                            g)
                        val_eq g_1)
                  ⋯ ⋯ ⋯)
              ⋯ g f)
          ⋯ f)
      ⋯ ⋯ ⋯

full_name: CategoryTheory.biconeCategory
code: instance biconeCategory : Category (Bicone J) 
goal: CategoryTheory.Category.{max u₁ v₁, u₁} (CategoryTheory.Bicone J)

full_name: CategoryTheory.biconeMk_obj
code: /-- Given a diagram `F : J ⥤ C` and two `Cone F`s, we can join them into a diagram `Bicone J ⥤ C`.
-/
@[simps]
def biconeMk {C : Type u₁} [Category.{v₁} C] {F : J ⥤ C} (c₁ c₂ : Cone F) : Bicone J ⥤ C 
goal: (CategoryTheory.biconeMk J c₁ c₂).obj X = CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j

full_name: CategoryTheory.biconeMk
code: /-- Given a diagram `F : J ⥤ C` and two `Cone F`s, we can join them into a diagram `Bicone J ⥤ C`.
-/
@[simps]
def biconeMk {C : Type u₁} [Category.{v₁} C] {F : J ⥤ C} (c₁ c₂ : Cone F) : Bicone J ⥤ C 
goal: CategoryTheory.Functor (CategoryTheory.Bicone J) C

full_name: CategoryTheory.biconeMk_map
code: /-- Given a diagram `F : J ⥤ C` and two `Cone F`s, we can join them into a diagram `Bicone J ⥤ C`.
-/
@[simps]
def biconeMk {C : Type u₁} [Category.{v₁} C] {F : J ⥤ C} (c₁ c₂ : Cone F) : Bicone J ⥤ C 
goal: ∀ {X Y : CategoryTheory.Bicone J} (f : X ⟶ Y),
  (CategoryTheory.biconeMk J c₁ c₂).map f =
    CategoryTheory.BiconeHom.casesOn (motive := fun a a_1 x =>
      X = a →
        Y = a_1 →
          HEq f x →
            ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) X ⟶
              (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
      f
      (fun h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) →
            Y = CategoryTheory.Bicone.left →
              HEq f CategoryTheory.BiconeHom.left_id →
                ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) X ⟶
                  (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (f : CategoryTheory.Bicone.left ⟶ Y) →
                HEq f CategoryTheory.BiconeHom.left_id →
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) CategoryTheory.Bicone.left ⟶
                    (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
              (fun f h =>
                CategoryTheory.CategoryStruct.id
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) CategoryTheory.Bicone.left))
              ⋯ f)
          ⋯ f)
      (fun h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) →
            Y = CategoryTheory.Bicone.right →
              HEq f CategoryTheory.BiconeHom.right_id →
                ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) X ⟶
                  (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (f : CategoryTheory.Bicone.right ⟶ Y) →
                HEq f CategoryTheory.BiconeHom.right_id →
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) CategoryTheory.Bicone.right ⟶
                    (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
              (fun f h =>
                CategoryTheory.CategoryStruct.id
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) CategoryTheory.Bicone.right))
              ⋯ f)
          ⋯ f)
      (fun j h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) →
            Y = CategoryTheory.Bicone.diagram j →
              HEq f (CategoryTheory.BiconeHom.left j) →
                ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) X ⟶
                  (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (f : CategoryTheory.Bicone.left ⟶ Y) →
                HEq f (CategoryTheory.BiconeHom.left j) →
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) CategoryTheory.Bicone.left ⟶
                    (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
              (fun f h => c₁.π.app j) ⋯ f)
          ⋯ f)
      (fun j h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) →
            Y = CategoryTheory.Bicone.diagram j →
              HEq f (CategoryTheory.BiconeHom.right j) →
                ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) X ⟶
                  (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (f : CategoryTheory.Bicone.right ⟶ Y) →
                HEq f (CategoryTheory.BiconeHom.right j) →
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) CategoryTheory.Bicone.right ⟶
                    (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
              (fun f h => c₂.π.app j) ⋯ f)
          ⋯ f)
      (fun {j k} f_1 h =>
        Eq.ndrec (motive := fun {X} =>
          (f : X ⟶ Y) →
            Y = CategoryTheory.Bicone.diagram k →
              HEq f (CategoryTheory.BiconeHom.diagram f_1) →
                ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) X ⟶
                  (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
          (fun f h =>
            Eq.ndrec (motive := fun {Y} =>
              (f : CategoryTheory.Bicone.diagram j ⟶ Y) →
                HEq f (CategoryTheory.BiconeHom.diagram f_1) →
                  ((fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j)
                      (CategoryTheory.Bicone.diagram j) ⟶
                    (fun X => CategoryTheory.Bicone.casesOn X c₁.pt c₂.pt fun j => F.obj j) Y))
              (fun f h => F.map f_1) ⋯ f)
          ⋯ f)
      ⋯ ⋯ ⋯

full_name: CategoryTheory.finBiconeHom
code: instance finBiconeHom [FinCategory J] (j k : Bicone J) : Fintype (j ⟶ k) 
goal: Fintype (j ⟶ k)

full_name: CategoryTheory.biconeSmallCategory
code: instance biconeSmallCategory : SmallCategory (Bicone J) 
goal: CategoryTheory.SmallCategory (CategoryTheory.Bicone J)

full_name: CategoryTheory.biconeFinCategory
code: instance biconeFinCategory [FinCategory J] : FinCategory (Bicone J) 
goal: CategoryTheory.FinCategory (CategoryTheory.Bicone J)