Definition:Mapping

A mapping (or a map) is a special kind of binary relation which relates a given element of one set to one element of another.

A mapping $$f$$ from $$S$$ to $$T$$ (or "on $$S$$ into $$T$$") is a relation $$f: S \times T$$ such that:


 * $$\forall x \in S: \left({x, y_1}\right) \in f \land \left({x, y_2}\right) \in f \implies y_1 = y_2$$

and


 * $$\forall x \in S: \exists y \in T: \left({x, y}\right) \in f$$

In the context of numbers, a mapping is usually referred to as a function. In some contexts, the term transformation is often used. The term operator is also seen.

Defined
A mapping $$f \subseteq S \times T$$ is defined at $$x \in S$$ iff:


 * $$\exists y \in T: \left({x, y}\right) \in f$$

If:


 * $$\exists x \in S: \forall y \in T: \left({x, y}\right) \notin f$$

then $$f$$ is not defined or (undefined) at $$x$$, and indeed, $$f$$ is not technically a mapping at all.

Thus, a mapping is a many-to-one relation which is defined for all elements in the domain.

Domain, Range, Image, Preimage
As a mapping is also a relation, all the results and definitions that we have established concerning relations also apply to mappings. For example, the concepts of domain and range carry over completely from their definition in the context of relations, as do the concepts of image and preimage.

The terms value and argument are sometimes seen for "image" and "preimage":

If $$\left({x, y}\right) \in f$$, then $$y$$ is the "value of $$f$$ for argument $$x$$", or simply, the "value of $$f$$ at $$x$$".

In the context of computability theory, the following terms are frequently found:

If $$\left({x, y}\right) \in f$$, then $$y$$ is often called the "output of $$f$$ for input $$x$$", or simply, the "output of $$f$$ at $$x$$".

Self-Map
A mapping whose domain and range are the same set is called a self-map.

Notation
The mapping $$f \subseteq S \times T$$ is usually denoted $$f: S \to T$$.

Thus, we write $$f: S \to T$$ to mean:


 * a mapping $$f$$ with domain $$S$$ and range $$T$$;
 * $$f$$ is a mapping of (or from) $$S$$ to (or into) $$T$$
 * $$f$$ maps $$S$$ to (or into) $$T$$.

For a mapping $$f$$ from $$S$$ into $$T$$, when $$x \in S, y \in T$$ a common form of notation is:


 * $$f: S \to T: f \left({x}\right) = y$$

where $$f \left({x}\right) = y$$ is interpreted to mean $$\left({x, y}\right) \in f$$.

Alternative notational forms of $$f \left({x}\right) = y$$ are:


 * $$f x = y$$
 * $$f: x \mapsto y$$
 * $$x f = y$$