What is the identity element of 4 If $*$ is a binary operation taking the greater of two distinct numbers, construct a table for the operation on the set $S=\{1,2,3,4,5\}$. What is the identity element of 4? Is the operation commutative?
 A: Let $S=\{1,2,3,4,5\}$ and let $*$ be a binary operation:
$$
a*b:=\max(a,b).
$$
The operation $*$ is a binary operation on $S$ trivially, since $\max(a,b)$ is either $a$ or $b$ so $\max(a,b)\in S$ for all $a,b\in S$.
It is commutative since
$$
\max(b,a)=\max(a,b)
$$
for all $a,b\in S$.
Its Cayley table:
\begin{array}{c|ccccc}
* & 1 & 2 & 3 & 4 & 5\\
\hline
1 & \color{blue}{1} & \color{blue}{2} & \color{blue}{3} & \color{blue}{4} & \color{blue}{5}\\
2 & \color{blue}{2} & 2 & 3 & 4 & 5\\
3 & \color{blue}{3} & 3 & 3 & 4 & 5\\
4 & \color{blue}{4} & 4 & 4 & 4 & 5\\
5 & \color{blue}{5} & 5 & 5 & 5 & 5\\
\end{array}
is indeed symmetric.
The identity element (unique) exists, it is $1$, left and right identity as highlighted in blue in the table.
Finally, $4$ has no left or right inverse, so it has no inverse: the identity $1$ does not appear in the line or column of the table labeled by $4$ and this is consistent with the fact that it does not exists any $x\in A$ such that
$$
\max(4,x)=1=\max(x,4).
$$
This $(S,*)$ seems to me to be a commutative monoid but not a group (as we said, no inverse for $4$): being finite, of order $5$, cancellation holds if and only if division holds and indeed none of the two holds here. We see also this properties on the table since some elements are missing in some lines (columns) and, consequently, some are repeated.
Uh, I said monoid but I actually didn't mention associativity...can you prove that the operation is associative too?
