overloaded notation

This phrase usually applies to a symbol or a name for a function that takes on different meanings depending on which type of element it is evaluated at. Such a function is also called polymorphic.

Example 1 The identity function is a polymorphic name; in the usual formalism there is a different identity function on each set.

Example 2 A familiar example is the symbol $\times$, which is overloaded in college mathematics courses. When $a$ and $b$ are numbers, $a\times b$ is their product. When $A$ and $B$ are matrices, $A \times B$ is the matrix product. When $v$ and $w$ are 3-vectors, $v \times w$ is their vector product.

Example 3 Another example is the common treatment of the image for arbitrary functions: Let $F\colon S \to T$ be a function.

a) If $x \in S$, $F(x)$ is the value of $F$ applied to $x$. It is called the image of $x$ under $F$.

b) If $A$ is a subset of $S$, then $F(A) = \{F(x) \mid x \in A\}$ (see setbuilder notation). It is called the image of $A$ under $F$.

c) The image of $F$ is the set of all $t$ in $T$ for which there is an $x \in S$ such that $F(x) = t$, which is the image in the sense of (2) of the domain of $F$. The word “range” is also used for this meaning.

Remark 1 The preceding example is in a way fake. One could simply stipulate that every function $F\colon S \to T$ has values defined for every element of $S$ and (in the way illustrated above) for every subset of $S$. However, the phrase “the image of $F$” would still overload the word “image”.

Example 4 A functor $F$ from a category $\mathcal{C}$ to a category $\mathcal{D}$ is defined on both objects and arrows of $\mathcal{C}$. This, too is a fake example, since the value of the functor at identity arrows determines its value on objects.

Example 5 A text on vector spaces will very likely use + for addition of vectors in every vector space. Similarly, some texts on group theory will use $e$ or 1 for the identity element for any group and juxtaposition for the binary operation of any group.

Remark 2 Example 5 illustrates the common case of using the same symbol in every model for a particular operation in an axiomatically defined mathematical structure.

Remark 3 The operation $\times$ does not require the same algorithm on matrices as it does on 3-vectors. This is the sort of phenomenon computer scientists call ad-hoc polymorphism. It is contrasted with parametric polymorphism, an example of which is the algorithm “swap the two entries in an ordered pair”, which applies to ordered pairs of any type of element. (The parameter that gives rise to the name “parametric” is the type of element.) See algorithm. The identity function provides a trivial example of parametric polymorphism.

Many mathematicians think and speak informally of a parametrically polymorphic function as one single function. (“$\ldots$ the identity function is injective”).

Remark 4 The concept “overloaded” is natural in computing science because operations on different data types are typically implemented differently. For example, addition of integers is implemented differently from addition of floating point numbers in most computer languages. The concept is less natural in mathematics, where you could define the operation on the disjoint union of all the sets under consideration (for $\times$, the set might be $\mathbb{R}$ plus the set of all 3-dimensional real vectors plus the set of all $n\times n$ real matrices for each $n$). Even there, however, the implementation algorithm differs for some of the subsets. (See cases.)

See also superscript.

Citations: (248)

Pages 189–191 of the book (PDF).