I have a several questions on the following problem.
Let X = {1,2}. There are 4 mappings from set X to itself, denoted End(X) and all the compositions betwen them are defined. If we denote f $\in$ End(X) as a 2-letter word (f(1), f(2)) (note: viewing images of mappings as words of length n, made from letters of an m-word alphapet, where a word is any combination of letters, was discussed in a previous exercise), then those 4 endomorphisms will be written as the following "words":
(1,1), (1,2) = $Id_X$, (2,1), (2,2)
The table for g $\circ$ f is below (g vertical and f horizontal):
\begin{array}{|c|c|c|c|} \hline g/f& (1,1) & (1,2) & (2,1) &(2,2) \\ \hline (1,1)& (1,1) & (1,1)& (1,1)&(1,1) \\ \hline (1,2)& (1,1) & (1,2)&(2,1) &(2,2) \\ \hline (2,1)& (2,2) &(2,1) &(1,2) &(1,1)\\ \hline (2,2)& (2,2) & (2,2)& (2,2)& (2,2)\\ \hline \end{array}
The first question is on the (f(1), f(2)) "word". It can output 4 different values: (1,1), (1,2), (2,1), (2,2), which are all the elements of the set End(X). However, I don't understand why only (1,1) and (1,2) are chosen in the definition, both relating to f(1)
(1,1), (1,2) = $Id_X$, (2,1), (2,2)
Also I don't get how the mapping works, e.g. when g = (2,1) and f = (1,1), g $\circ$ f = g( (1,1) ) = (2,2). In a function, g(f(1))= g(1) would be undefined, since there 1 is not in g's first coordinate. So I'm assuming the definition defines this, although I don't understand when either (1,1) or (1,2) equals either of $Id_X$/(2,1)/(2,2).