Maps are the mathematical formulation of a machine that gets inputs and generate outputs. On both sides, sets are needed for the domain and the codomain.

Click on an **arrow** to get a description of the connection!

Click on an **arrow** to get a description of the connection!

__Show requirements__

Concept |
Content |

Sets |
Sets are the basic building blocks for a lot of mathematics. In order to rigorously define numbers and doing real analysis, we need to know how to work with sets. |

__Show consequences__

**Definition 1** (Function or map). *Let \(X,Y\) be non-empty sets. A rule that
assigns to each **argument* \(x\in
X\) a unique *value* \(y\in
Y\) is called a *map* or *function* from \(X\) into \(Y\). One writes for this \(y\) usually \(f(x)\).

Notation:

\[\begin{aligned}
f:X &\rightarrow Y \\
x &\mapsto f(x)
\end{aligned}\] Here, \(X\) is
called *domain* of \(f\), and
\(Y\) is called
*codomain*.

**Attention 2** (Two arrows!). We use the arrow “ \(\to\) ” only between the sets, domain and
codomain, and “ \(\mapsto\) ” only
between the elements.

**Example 3**. \(f:\mathbb{N}
\rightarrow \mathbb{N}\) with \(f(x)=x^2\) maps each natural number to its
square.

**Well-definedness**

What can go wrong with the definition of a map? Sometimes, when
defining a function, it is not completely clear, if this makes sense.
Then one has to work and make this function well-defined.

**Example: the square-root**

Try to define a map \(a \to
\sqrt{a}\) in a mathematically rigorous way.

Naive definition: \[\begin{aligned}
\sqrt{\hphantom{x}} : \mathbb{R} &\to \mathbb{R}\\
a &\mapsto \mbox{ the solution of } x^2=a.
\end{aligned}\] Problem of well-definedness: As we all know, the
above equation has two (\(a>0\)),
one (\(a=0\)), or zero (\(a<0\)) solutions.

*First way*: restrict the domain of definition and the
codomain \[\mathbb{R}^+_0 = \{ a \in
\mathbb{R}: a \ge 0 \}\] Then: \[\begin{aligned}
\sqrt{\hphantom{x}} : \mathbb{R}^+_0 &\to \mathbb{R}^+_0\\
a &\mapsto \mbox{ the non-negative solution of } x^2=a.
\end{aligned}\] This yields the classical square-root.

#### Discuss your questions by typing below.