What does functor definition in category theory mean?

You're right, $F$ really is two functions. If you were being very formal, you might say a functor $F : \mathcal{C} \to \mathcal{D}$ is a pair $F=(F_0, F_1)$, where $F_0 : \mathrm{ob}(\mathcal{C}) \to \mathrm{ob}(\mathcal{D})$ and $F_1 : \mathrm{mor}(\mathcal{C}) \to \mathrm{mor}(\mathcal{D})$ are functions satsifying

  • If $f : X \to Y$ in $\mathcal{C}$, then $F_1(f) : F_0(X) \to F_0(Y)$ in $\mathcal{D}$;
  • $F_1(\mathrm{id}_X) = \mathrm{id}_{F_0(X)}$ for all $X \in \mathrm{ob}(\mathcal{C})$; and
  • $F_1(g \circ f) = F_1(g) \circ F_1(f)$ for all $X \xrightarrow{f} Y \xrightarrow{g} Z$ in $\mathcal{C}$.

There are various encoding tricks you could use to completely remove ambiguity, but in day-to-day life there is no problem with just writing $F$ to denote both $F_0$ and $F_1$. But when using a proof assistant, say, the distinction has to be made.


Don't forget a category $\mathcal C$ is made up of two sorts of data: a class of objects, and for each pair of objects, a set of arrows. Therefore, it is natural that a functor from the category $\mathcal C$ to another category has, so to say, two components: a function on the class of objects, and functions on each set of arrows.


If you extract the set1 $Ob(C)$ of objects from the category $C$ and the set $Ar(C)$ of arrows, then given any functor $F : C \to D$, you can indeed construct two functions $$ Ob(C) \to Ob(D) : X \mapsto F(X) $$ $$ Ar(C) \to Ar(D) : f \mapsto F(f) $$ satisfying the stated properties. And conversely, given any two functions satisfying the properties, there exists a corresponding functor.

You can think of the functor as being a pair of functions, but it is probably better to instead think of that as a way to represent functors. You want to think of a functor as being a thing in its own right, rather than being shackled to that particular representation.

For example, you can do the usual thing of promoting evaluation to a binary operator. In set theory, there is a set $Y^X$ of all functions from $X$ to $Y$, and you can consider evaluation a function $Y^X \times X \to Y$.

You can do the same thing with functors; there is a category $D^C$ whose objects are functors from $C$ to $D$ (and whose arrows are natural transformations), and evaluation is itself a functor $D^C \times C \to D$.

Another potentially interesting point is that categories don't just have point-shaped and arrow-shaped elements. They have elements in the shape of any diagram: for example, they have commutative-square-shaped elements, and the functor $F$ also maps commutative-square-shaped elements of $C$ to commutative-square-shaped elements of $D$.

That a functor preserves composition of morphisms can actually be phrased in terms of the functor acting on the commutative-triangle-shaped elements.

(all of the information of a category is in its arrows so we can reduce all various-shaped elements to arrows and equations between them, but we don't have to)

1: Replace "set" with other notions as needed or to taste