Functor.agda 665 B

12345678910111213141516
  1. module Functor where
  2. open import Category as Cat
  3. record Functor (ℂ ⅅ : Cat) : Set1 where
  4. field
  5. F : Cat.Obj ℂ -> Cat.Obj ⅅ
  6. map : {A B : Cat.Obj ℂ} -> Cat._─→_ ℂ A B -> Cat._─→_ ⅅ (F A) (F B)
  7. mapEq : {A B : Cat.Obj ℂ}{f g : Cat._─→_ ℂ A B} -> Category._==_ ℂ f g ->
  8. Category._==_ ⅅ (map f) (map g)
  9. mapId : {A : Cat.Obj ℂ} -> Category._==_ ⅅ (map (Cat.id ℂ {A})) (Cat.id ⅅ)
  10. mapCompose : {A B C : Cat.Obj ℂ}{f : Cat._─→_ ℂ B C}{g : Cat._─→_ ℂ A B} ->
  11. Category._==_ ⅅ (map (Cat._∘_ ℂ f g)) (Cat._∘_ ⅅ (map f) (map g))