Definition:Operation/Operation on Set

Definition
An $n$-ary operation on a set $S$ is an $n$-ary operation where:
 * the domain is the cartesian space $S^n$
 * the codomain is $S$:


 * $\odot: S^n \to S: \forall \left({s_1, s_2, \ldots, s_n}\right) \in S^n: \odot \left({s_1, s_2, \ldots, s_n}\right) \in S$

That is:
 * an $n$-ary operation on $S$ needs to be defined for all tuples in $S^n$
 * the image of $\odot$ is itself in $S$.

Also see

 * General Operation from Binary Operation, where it is shown that this can be defined recursively as:


 * $\forall \left({s_1, s_2, \ldots, s_n}\right) \in S^n: \odot \left({s_1, s_2, \ldots, s_n}\right) = \begin{cases}

s_1 & : n = 1 \\ \odot \left({s_1, s_2, \ldots, s_{n - 1} }\right) \odot s_n & : n > 1 \end{cases}$

where $\odot \left({s_1, s_2, \ldots, s_{n - 1} }\right)$ is the $n - 1$-ary operation defined in the same way.

Hence:
 * $\forall \left({s_1, s_2, \ldots, s_n}\right) \in S^n: \odot \left({s_1, s_2, \ldots, s_n}\right) := \left({\cdots\left({\left({s_1 \odot s_2}\right) \odot s_3}\right) \odot \cdots}\right) \odot s_n$


 * Definition:Composite (Abstract Algebra): the specific element of $S$ to which $\odot \left({s_1, s_2, \ldots, s_n}\right)$ maps for a given $\left({s_1, s_2, \ldots, s_n}\right) \in S^n$