% LESSON NINE
          
\documentclass{amsart}
\thispagestyle{empty}
\theoremstyle{definition}
\newtheorem*{dfn}{Definition}
\newtheorem*{notation}{Notation}
\begin{document}
             
\begin{center}
	\textbf{Lesson Nine: Arrows and Functions}
\end{center}  

We have a wide range of arrows in our quiver, a small sample of which appears below.
$$\Rightarrow \quad \leftarrow \quad \longleftarrow \quad \uparrow \quad 
\Downarrow \quad \swarrow \quad \mapsto \quad \leftrightarrow$$
% Note that arrow names beginning with capitals letters are double arrows.
% Recall from Lesson Six that \quad is a horizontal spacing command.

\begin{dfn}
A function $f\colon A\to B$ is \emph{injective} or \emph{one-to-one} if and 
only if whenever $f(a_1)=f(a_2)$, then $a_1=a_2$.
\end{dfn}
% Note that the spacing of \colon is preferred over that produced by using f: A\to B.

\begin{notation}
If $f$ is injective, we write $f\colon A\xrightarrow{\text{1-1}} B$.\\
% \xrightarrow is a stretchable arrow that will change in length depending on
%   what appears above or below it. \xleftarrow works similarly.
% The braces { } contain the expression to appear above the arrow.
\end{notation}

\begin{dfn}
A function $f\colon A\to B$ is \emph{surjective} or \emph{onto} if and only if
for every $b\in B$, there exists $a\in A$ such that $f(a)=b$.
\end{dfn}

\begin{notation}
If $f$ is surjective, we write $f\colon A\xrightarrow[\text{onto}]{} B$.\\
% The brackets [ ] contain the expression to appear above the arrow.
% The argument in brackets is optional, but the argument in braces
%   is required; thus, in this case, we use {} to indicate an empty argument.
\end{notation}

% Note that while the command \overrightarrow exists,
%   the command \vec is preferred for vectors.

Some books use the symbol $\overset{\text{def}}{=}$ when defining a function.
% The format is \overset{raised symbol}{main symbol}.
% \underset works similarly.
For instance, we have the \textbf{identity function} on a set $A$, which sends 
each element of $A$ to itself.
$$I_A(x)\overset{\text{def}}{=}x$$

\end{document} 
