Function composition

cosmos 18th November 2017 at 10:08pm
Category theory Function

Given two Functions f:XYf: X \to Y and g:YZg: Y \to Z, we define their composition:

gf:XZg \circ f: X \to Z

as (gf)(x)=g(f(x))(g \circ f)(x) = g(f(x))

Function composition satisfies Associativity so that h(gf)=(hg)f:=hgfh \circ (g \circ f) = (h \circ g) \circ f := h \circ g \circ f

More generally, we define the same thing for Morphisms/Arrows in a Category