Note that to avoid universe inconsistancies we duplicate the definition of Setoid used to define | |
the type of categories. |
{ SCarrier | :> | Type | |
; SEquiv | : | SCarrier → SCarrier → Prop | |
; is_SEquiv | : | Equivalence SEquiv }. |
Arguments mkObj | {_ _} _. | |
Arguments SEquiv | {_} _ _. |
{ map | :> | A → B | |
; cong | : | ∀ {x y}, SEquiv x y → SEquiv (map x) (map y) }. |
Arguments mkMorphism | {_ _ _} _. | |
Arguments map | {_ _} _ _. | |
Arguments cong | {_ _} _ {_ _ _}. |
Setoid.make | ⦃ Carrier | ≔ Morphism A B | |
; Equiv | ≔ λ f g ∙ ∀ x y, SEquiv x y → SEquiv (f x) (g y) ⦄. |
Setoids.make | ⦃ Carrier | ≔ A ⟨×⟩ B | |
; Equiv | ≔ λ S₁ S₂ ∙ fst S₁ ∼ fst S₂ ∧ snd S₁ ∼ snd S₂ ⦄. |
- intros [a | b]; split; reflexivity. |
BinaryProduct.make | ⦃ Category | ≔ 𝑺𝒆𝒕𝒐𝒊𝒅 | |
; _×_ | ≔ product | ||
; ⟨_,_⟩ | ≔ @product_mor _ _ | ||
; π₁ | ≔ proj_l | ||
; π₂ | ≔ proj_r ⦄. |