Skip to content

Functors

Note to self

A Functor is a design pattern that evolves from category theory in mathematics. Fundamentally it’s a mapping between categories that preserves the structure of the original categories involved. It satisfies two laws: -

  1. Identity law: F(id⁡A)=id⁡F(A)\small{F(\operatorname{id}_A) = \operatorname{id}_{F(A)}}
  2. Composition law: F(g∘f)=F(g)∘F(f)\small{F(g \circ f) = F(g) \circ F(f)}

Reading list

Thanks for reading.

Follow the RSS feed · Say hi on LinkedIn

Human Agent