\documentclass[numbers=enddot,12pt,final,onecolumn,notitlepage]{scrartcl}%
\usepackage[headsepline,footsepline,manualmark]{scrlayer-scrpage}
\usepackage[all,cmtip]{xy}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{framed}
\usepackage{comment}
\usepackage{color}
\usepackage[breaklinks=True]{hyperref}
\usepackage[sc]{mathpazo}
\usepackage[T1]{fontenc}
\usepackage{needspace}
\usepackage{xr}
\usepackage{tabls}
\usepackage{ytableau}
\usepackage{tikz}
\usepackage{pgfplots}
\usepackage[type={CC}, modifier={zero}, version={1.0},]{doclicense}
%TCIDATA{OutputFilter=latex2.dll}
%TCIDATA{Version=5.50.0.2960}
%TCIDATA{LastRevised=Monday, September 28, 2026 19:12:00}
%TCIDATA{SuppressPackageManagement}
%TCIDATA{<META NAME="GraphicsSave" CONTENT="32">}
%TCIDATA{<META NAME="SaveForMode" CONTENT="1">}
%TCIDATA{BibliographyScheme=Manual}
%TCIDATA{Language=American English}
%BeginMSIPreambleData
\providecommand{\U}[1]{\protect\rule{.1in}{.1in}}
%EndMSIPreambleData
\pgfplotsset{compat=1.13}
\externaldocument{lec01-331}
\externaldocument{lec02-331}
\theoremstyle{definition}
\newtheorem{theo}{Theorem}[subsection]
\newtheorem{exer}{Exercise}[subsubsection]
\newenvironment{theorem}[1][]
{\begin{theo}[#1]\begin{leftbar}}
{\end{leftbar}\end{theo}}
\newtheorem{lem}[theo]{Lemma}
\newenvironment{lemma}[1][]
{\begin{lem}[#1]\begin{leftbar}}
{\end{leftbar}\end{lem}}
\newtheorem{prop}[theo]{Proposition}
\newenvironment{proposition}[1][]
{\begin{prop}[#1]\begin{leftbar}}
{\end{leftbar}\end{prop}}
\newtheorem{defi}[theo]{Definition}
\newenvironment{definition}[1][]
{\begin{defi}[#1]\begin{leftbar}}
{\end{leftbar}\end{defi}}
\newtheorem{remk}[theo]{Remark}
\newenvironment{remark}[1][]
{\begin{remk}[#1]\begin{leftbar}}
{\end{leftbar}\end{remk}}
\newtheorem{coro}[theo]{Corollary}
\newenvironment{corollary}[1][]
{\begin{coro}[#1]\begin{leftbar}}
{\end{leftbar}\end{coro}}
\newtheorem{conv}[theo]{Convention}
\newenvironment{convention}[1][]
{\begin{conv}[#1]\begin{leftbar}}
{\end{leftbar}\end{conv}}
\newtheorem{quest}[theo]{Question}
\newenvironment{question}[1][]
{\begin{quest}[#1]\begin{leftbar}}
{\end{leftbar}\end{quest}}
\newtheorem{warn}[theo]{Warning}
\newenvironment{warning}[1][]
{\begin{warn}[#1]\begin{leftbar}}
{\end{leftbar}\end{warn}}
\newtheorem{conj}[theo]{Conjecture}
\newenvironment{conjecture}[1][]
{\begin{conj}[#1]\begin{leftbar}}
{\end{leftbar}\end{conj}}
\newtheorem{exam}[theo]{Example}
\newenvironment{example}[1][]
{\begin{exam}[#1]\begin{leftbar}}
{\end{leftbar}\end{exam}}
\newtheorem{exmp}[exer]{Exercise}
\newenvironment{exercise}[1][]
{\begin{exmp}[#1]\begin{leftbar}}
{\end{leftbar}\end{exmp}}
\newenvironment{statement}{\begin{quote}}{\end{quote}}
\newenvironment{fineprint}{\begin{small}}{\end{small}}
\iffalse
\newenvironment{proof}[1][Proof]{\noindent\textbf{#1.} }{\ \rule{0.5em}{0.5em}}
\newenvironment{convention}[1][Convention]{\noindent\textbf{#1.} }{\ \rule{0.5em}{0.5em}}
\newenvironment{question}[1][Question]{\noindent\textbf{#1.} }{\ \rule{0.5em}{0.5em}}
\fi
\let\sumnonlimits\sum
\let\prodnonlimits\prod
\let\cupnonlimits\bigcup
\let\capnonlimits\bigcap
\renewcommand{\sum}{\sumnonlimits\limits}
\renewcommand{\prod}{\prodnonlimits\limits}
\renewcommand{\bigcup}{\cupnonlimits\limits}
\renewcommand{\bigcap}{\capnonlimits\limits}
\usetikzlibrary{arrows,arrows.meta,decorations.markings}
\setlength\tablinesep{3pt}
\setlength\arraylinesep{3pt}
\setlength\extrarulesep{3pt}
\setlength\textheight{22.5cm}
\setlength\textwidth{14.8cm}
\newenvironment{verlong}{}{}
\newenvironment{vershort}{}{}
\newenvironment{noncompile}{}{}
\excludecomment{verlong}
\includecomment{vershort}
\excludecomment{noncompile}
\newcommand{\defn}[1]{{\color{darkred}\emph{#1}}}
\newcommand{\CC}{\mathbb{C}}
\newcommand{\RR}{\mathbb{R}}
\newcommand{\QQ}{\mathbb{Q}}
\newcommand{\NN}{\mathbb{N}}
\newcommand{\ZZ}{\mathbb{Z}}
\newcommand{\KK}{\mathbb{K}}
\newcommand{\set}[1]{\left\{ #1 \right\}}
\newcommand{\abs}[1]{\left| #1 \right|}
\newcommand{\tup}[1]{\left( #1 \right)}
\newcommand{\ive}[1]{\left[ #1 \right]}
\newcommand{\floor}[1]{\left\lfloor #1 \right\rfloor}
\newcommand{\mono}{\hookrightarrow}
\newcommand{\epi}{\twoheadrightarrow}
\newcommand{\iso}{\overset{\cong}{\to}}
\newcommand{\arinj}{\ar@{_{(}->}}
\newcommand{\arinjrev}{\ar@{^{(}->}}
\newcommand{\arsurj}{\ar@{->>}}
\newcommand{\arelem}{\ar@{|->}}
\newcommand{\arback}{\ar@{<-}}
\newcommand{\Ker}{\operatorname{Ker}}
\newcommand{\Coker}{\operatorname{Coker}}
\newcommand{\incpdftexpic}[1]{{\def\svgwidth{\columnwidth} \input{#1} }}
\definecolor{dbluecolor}{rgb}{0.01,0.02,0.7}
\definecolor{dgreencolor}{rgb}{0.2,0.4,0.0}
\definecolor{darkred}{rgb}{0.7,0,0}
\newtheoremstyle{plainsl}
{8pt plus 2pt minus 4pt}
{8pt plus 2pt minus 4pt}
{\slshape}
{0pt}
{\bfseries}
{.}
{5pt plus 1pt minus 1pt}
{}
\theoremstyle{plainsl}
\ihead{Math 331, Fall 2026, Lecture 4, version \today}
\ohead{page \thepage}
\cfoot{}
\begin{document}
\section*{Math 331 Fall 2026, Lecture 4: Generalized associativity,
cancellation and powers}

\textbf{website:}
\texttt{\href{https://www.cip.ifi.lmu.de/~grinberg/t/26fa}{\texttt{https://www.cip.ifi.lmu.de/\symbol{126}%
grinberg/t/26fa/}}}

\setcounter{section}{1}\setcounter{subsection}{3}

\subsection{Generalized associativity}

So we are wondering if a \textquotedblleft multi-factor
product\textquotedblright\ of the form $a_{1}\ast a_{2}\ast\cdots\ast a_{n}$
in a semigroup has a well-defined value independent of its parenthesization.
We know that this is true for $n=3$ (by associativity) and for $n=4$ (we just
checked it); it is also true for $n=2$ (trivially) and for $n=1$ (even more
trivially: it is just $a_{1}$ in this case). But how can we generalize this to
higher $n$'s?

The first question is how to even formalize the claim: what \textbf{is} a
\textquotedblleft parenthesization\textquotedblright? We could answer this
using the language of planar binary trees, but let me instead give a simpler
formalization. Instead of defining parenthesizations, we will define the
\textquotedblleft product\textquotedblright\ $a_{1}\ast a_{2}\ast\cdots\ast
a_{n}$ using one specific parenthesization: namely, the parenthesization%
\[
a_{1}\ast\left(  a_{2}\ast\left(  a_{3}\ast\left(  \cdots\ast a_{n}\right)
\right)  \right)
\]
that corresponds to starting with $a_{n}$ and then iteratively multiplying
further and further factors from the left. This is very easy to define
recursively. Then, after it is defined, we will show that it equals%
\[
\left(  a_{1}\ast a_{2}\ast\cdots\ast a_{k}\right)  \ast\left(  a_{k+1}\ast
a_{k+2}\ast\cdots\ast a_{n}\right)
\]
for any $k\in\left\{  1,2,\ldots,n-1\right\}  $; this means that its top-level
parentheses can be moved to an arbitrary place (which means that their exact
position does not matter, and therefore, of course, the position of
parentheses at the lower levels does not matter either).

Here is our definition of $a_{1}\ast a_{2}\ast\cdots\ast a_{n}$ in its
recursive form:

\begin{definition}
\label{def.sg.genass}Let $\left(  S,\ast\right)  $ be a semigroup. We define a
\textquotedblleft product\textquotedblright\ $a_{1}\ast a_{2}\ast\cdots\ast
a_{n}$ for any $n$ elements $a_{1},a_{2},\ldots,a_{n}$ of $S$ (where $n$ is
any positive integer) by recursion on $n$:

\begin{itemize}
\item For $n=1$, we just define it to be $a_{1}$.

\item For $n>1$, we define%
\[
a_{1}\ast a_{2}\ast\cdots\ast a_{n}:=a_{1}\ast\underbrace{\left(  a_{2}\ast
a_{3}\ast\cdots\ast a_{n}\right)  }_{\substack{\text{this is defined by
the}\\\text{induction hypothesis}}}.
\]

\end{itemize}

If $\left(  S,\ast\right)  $ is a monoid (i.e., has a neutral element $e$),
then we also define the \textquotedblleft product\textquotedblright%
\ $a_{1}\ast a_{2}\ast\cdots\ast a_{n}$ for $n=0$ by setting it to be $e$.
\end{definition}

As we said, this recursive definition means that we define $a_{1}\ast
a_{2}\ast\cdots\ast a_{n}$ as%
\[
a_{1}\ast\left(  a_{2}\ast\left(  a_{3}\ast\left(  \cdots\ast a_{n}\right)
\right)  \right)  .
\]


Note that for $n=2$, our newly defined product $a_{1}\ast a_{2}\ast\cdots\ast
a_{n}$ from Definition \ref{def.sg.genass} is precisely the original
$a_{1}\ast a_{2}$, so we are not creating a clash of notation by overriding
the existing notation.

Now, the claim that \textquotedblleft multi-factor products\textquotedblright%
\ do not depend on their parenthesization takes the following form (which is
convenient both for proving it and for using it):

\begin{theorem}
[general associativity]\label{thm.sg.genass}Let $\left(  S,\ast\right)  $ be a semigroup.

\begin{enumerate}
\item[\textbf{(a)}] For any integers $0<k<n$ and any $n$ elements $a_{1}%
,a_{2},\ldots,a_{n}$ of $S$, we have%
\[
a_{1}\ast a_{2}\ast\cdots\ast a_{n}=\left(  a_{1}\ast a_{2}\ast\cdots\ast
a_{k}\right)  \ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}\right)  .
\]


\item[\textbf{(b)}] Assume that $\left(  S,\ast\right)  $ is a monoid (i.e.,
has a neutral element $e$). Then, for any integers $0\leq k\leq n$ and any $n$
elements $a_{1},a_{2},\ldots,a_{n}$ of $S$, we have%
\[
a_{1}\ast a_{2}\ast\cdots\ast a_{n}=\left(  a_{1}\ast a_{2}\ast\cdots\ast
a_{k}\right)  \ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}\right)  .
\]

\end{enumerate}
\end{theorem}

\begin{proof}
\textbf{(a)} We proceed by strong induction\footnote{Regular induction would
work just as well here, but I just want to show an example of strong induction
:)} on $n$.

\textit{Base case:} You don't need a base case when you do strong induction.
But if you want, the $n=1$ case is vacuously true, since there is no $0<k<1$.
And the $n=2$ case is obvious.

\textit{Induction step:} Fix a positive integer $n$. Assume that Theorem
\ref{thm.sg.genass} \textbf{(a)} is true for all positive integers smaller
than $n$ instead of $n$ (that is, roughly speaking, any \textquotedblleft
multi-factor product\textquotedblright\ of fewer than $n$ elements of $S$ can
already be re-parenthesized at will). Now let us prove it for our $n$. So we
fix an integer $0<k<n$ and $n$ elements $a_{1},a_{2},\ldots,a_{n}\in S$, and
we aim to show that%
\begin{align}
&  a_{1}\ast a_{2}\ast\cdots\ast a_{n}\nonumber\\
&  \overset{?}{=}\left(  a_{1}\ast a_{2}\ast\cdots\ast a_{k}\right)
\ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}\right)  .
\label{pf.thm.sg.genass.goal1}%
\end{align}
From $0<k<n$, we obtain $n>1$, and so Definition \ref{def.sg.genass} gives us%
\begin{equation}
a_{1}\ast a_{2}\ast\cdots\ast a_{n}=a_{1}\ast\left(  a_{2}\ast a_{3}\ast
\cdots\ast a_{n}\right)  . \label{pf.thm.sg.genass.3a}%
\end{equation}
Now, if $k=1$, then this is precisely our claim (\ref{pf.thm.sg.genass.goal1})
(since in this case, $a_{1}\ast a_{2}\ast\cdots\ast a_{k}=a_{1}$ and
$a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}=a_{2}\ast a_{3}\ast\cdots\ast a_{n}%
$), so we are done in this case.

So let us WLOG assume that $k>1$. (The word \textquotedblleft
WLOG\textquotedblright\ means \textquotedblleft without loss of
generality\textquotedblright.) Since $k>1$, we have%
\begin{equation}
a_{1}\ast a_{2}\ast\cdots\ast a_{k}=a_{1}\ast\left(  a_{2}\ast a_{3}\ast
\cdots\ast a_{k}\right)  \label{pf.thm.sg.genass.3b}%
\end{equation}
by Definition \ref{def.sg.genass}. Using (\ref{pf.thm.sg.genass.3a}) and
(\ref{pf.thm.sg.genass.3b}), we can rewrite the equality
(\ref{pf.thm.sg.genass.goal1}) (which we must prove) as%
\begin{align}
&  a_{1}\ast\left(  a_{2}\ast a_{3}\ast\cdots\ast a_{n}\right) \nonumber\\
&  \overset{?}{=}\left(  a_{1}\ast\left(  a_{2}\ast a_{3}\ast\cdots\ast
a_{k}\right)  \right)  \ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast
a_{n}\right)  . \label{pf.thm.sg.genass.goal2}%
\end{align}
So our goal is now to prove (\ref{pf.thm.sg.genass.goal2}). But our induction
hypothesis yields%
\begin{align*}
&  a_{2}\ast a_{3}\ast\cdots\ast a_{n}\\
&  =\left(  a_{2}\ast a_{3}\ast\cdots\ast a_{k}\right)  \ast\left(
a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}\right)
\end{align*}
(since the left-hand side is a \textquotedblleft multi-factor
product\textquotedblright\ with $n-1<n$ factors). Thus, the equality
(\ref{pf.thm.sg.genass.goal2}) rewrites as%
\begin{align}
&  a_{1}\ast\left(  \left(  a_{2}\ast a_{3}\ast\cdots\ast a_{k}\right)
\ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}\right)  \right)
\nonumber\\
&  \overset{?}{=}\left(  a_{1}\ast\left(  a_{2}\ast a_{3}\ast\cdots\ast
a_{k}\right)  \right)  \ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast
a_{n}\right)  , \label{pf.thm.sg.genass.goal3}%
\end{align}
which immediately follows from the regular associativity of $\ast$ (which we
assumed in the definition of a semigroup), applied to the three elements
$a_{1}$, $a_{2}\ast a_{3}\ast\cdots\ast a_{k}$ and $a_{k+1}\ast a_{k+2}%
\ast\cdots\ast a_{n}$. Thus, (\ref{pf.thm.sg.genass.goal2}) is proved. Hence,
(\ref{pf.thm.sg.genass.goal1}) follows, so our induction step is complete, and
we are done proving Theorem \ref{thm.sg.genass} \textbf{(a)}. \medskip

\textbf{(b)} Let $0\leq k\leq n$ be integers, and let $a_{1},a_{2}%
,\ldots,a_{n}$ be $n$ elements of $S$. We must prove the equality%
\begin{align}
&  a_{1}\ast a_{2}\ast\cdots\ast a_{n}\nonumber\\
&  \overset{?}{=}\left(  a_{1}\ast a_{2}\ast\cdots\ast a_{k}\right)
\ast\left(  a_{k+1}\ast a_{k+2}\ast\cdots\ast a_{n}\right)  .
\label{pf.thm.sg.genass.goal4}%
\end{align}
If $0<k<n$, then this equality follows from part \textbf{(a)}; thus, we only
need to handle the cases $k=0$ and $k=n$. But this is easy: For $k=0$, the
desired equality (\ref{pf.thm.sg.genass.goal4}) says that%
\[
a_{1}\ast a_{2}\ast\cdots\ast a_{n}=e\ast\left(  a_{1}\ast a_{2}\ast\cdots\ast
a_{n}\right)  ,
\]
whereas for $k=n$, it says that%
\[
a_{1}\ast a_{2}\ast\cdots\ast a_{n}=\left(  a_{1}\ast a_{2}\ast\cdots\ast
a_{n}\right)  \ast e;
\]
both of these follow from the neutrality of $e$. Thus, part \textbf{(b)} is proved.
\end{proof}

Thanks to Theorem \ref{thm.sg.genass}, we can now write \textquotedblleft
products\textquotedblright\ of multiple elements of a semigroup without
parentheses. We shall freely do this henceforth. Thus, some of the proofs in
Lecture 2 can be simplified: for example, one of the computations in the proof
of Theorem \ref{thm.monoid.inverse-rules} \textbf{(b)} simplifies to%
\[
b^{-1}\ast\underbrace{a^{-1}\ast a}_{=e}\ast\,b=b^{-1}\ast\underbrace{e\ast
b}_{=b}=b^{-1}\ast b=e.
\]


\subsection{Multiplicative notation}

There is a shorthand notation for semigroups:

\begin{definition}
\label{def.sg.mulnot}Let $\left(  S,\ast\right)  $ be a semigroup. Sometimes,
we will write the operation $\ast$ as $\cdot$, so that its values $a\ast b$
will be written as $a\cdot b$. We can also (optionally) omit the $\cdot$ sign,
so these values will simply become $ab$. Moreover, the neutral element $e$ of
$S$ (if it exists, i.e., if $\left(  S,\ast\right)  $ is a monoid) will be
written as $1$. This is called \textbf{multiplicative notation}, or
\textbf{writing }$S$ \textbf{multiplicatively}.
\end{definition}

When is this allowed? Whenever there is no other multiplication operation
defined on the set $S$ that would make this notation ambiguous. So, for
example, we cannot write the monoid $\left(  \mathbb{Z},+\right)  $
multiplicatively, since there is already a $\cdot$ operation on $\mathbb{Z}$
and we do not want $2\cdot3$ to suddenly be $5$ (nor do we want $23$ to be
$5$). A good example of a monoid for which multiplicative notation is
legitimate and perfectly reasonable is the monoid $\operatorname*{Map}\left(
A,A\right)  $ of maps from a given set $A$ to itself. In fact, mathematicians
often use multiplicative notation for composition of maps (i.e., they write
$fg$ for $f\circ g$), even when these maps are not part of a monoid. However,
in some situations, this is not a good idea; functions on $\mathbb{R}$ or
$\mathbb{C}$ are often multiplied pointwise, so $fg$ means the function that
sends each $x$ to $f\left(  x\right)  g\left(  x\right)  $ instead of the
composition $f\circ g$. When using notation like this, always look out for
what is standard in the specific field.

The main advantages of multiplicative notation are its brevity
(\textquotedblleft$ab$\textquotedblright\ is shorter than \textquotedblleft%
$a\ast b$\textquotedblright) and its familiarity (we have muscle memory for
manipulating products, some of which can be reused for \textquotedblleft
products\textquotedblright\ in arbitrary semigroups; we just need to be
careful not to assume too much based on analogy with numbers).

In particular, when using multiplicative notation in a monoid $S$, the
neutrality of its neutral element $e$ rewrites as \textquotedblleft$1a=a1=a$
for each $a\in S$\textquotedblright, which looks very natural.

When using multiplicative notation for a semigroup $\left(  S,\ast\right)  $,
we will refer to the operation $\ast$ as \textbf{multiplication} and to its
values as \textbf{products}, even if they have nothing to do with products of numbers.

\subsection{Cancellation and solving equations}

As you should have noticed by now, working in a monoid is much like working
with (products of) square matrices; and working in a group is correspondingly
like working with invertible matrices. You cannot swap factors in a product
(unless you have a specific justification for that), but you can invert and
move things from one side to the other:

\begin{theorem}
\label{thm.monoid.cancel}Let $S$ be a monoid, written multiplicatively.

Let $a,b,c\in S$ be three elements. Assume that $a$ has an inverse. (If $S$ is
a group, then this assumption is automatically satisfied.) Then:

\begin{enumerate}
\item[\textbf{(a)}] We have $ab=c$ if and only if $b=a^{-1}c$.

\item[\textbf{(b)}] We have $ba=c$ if and only if $b=ca^{-1}$.

\item[\textbf{(c)}] We have $ab=ac$ if and only if $b=c$.

\item[\textbf{(d)}] We have $ba=ca$ if and only if $b=c$.
\end{enumerate}
\end{theorem}

\begin{proof}
\textbf{(a)} $\Longrightarrow:$ If $ab=c$, then $a^{-1}\underbrace{c}%
_{=ab}=\underbrace{a^{-1}a}_{=1}b=1b=b$, so that $b=a^{-1}c$.

$\Longleftarrow:$ If $b=a^{-1}c$, then $ab=\underbrace{aa^{-1}}_{=1}c=1c=c$.
\medskip

\textbf{(b)} is analogous to \textbf{(a)} (in a very precise sense: you can
obtain a proof of part \textbf{(b)} by copying the above proof of part
\textbf{(a)} but reading each product right-to-left). \medskip

\textbf{(c)} $\Longrightarrow:$ If $ab=ac$, then we obtain $b=c$ by comparing
the two equalities $\underbrace{a^{-1}a}_{=1}b=b$ and $a^{-1}\underbrace{ab}%
_{=ac}=\underbrace{a^{-1}a}_{=1}c=c$.

$\Longleftarrow:$ If $b=c$, then $ab=ac$ obviously follows.

\textbf{(d)} is analogous to \textbf{(c)} (again by reading all products right-to-left).
\end{proof}

Theorem \ref{thm.monoid.cancel} codifies some important techniques that can be
used when computing in a group (and even in a monoid, as long as the
appropriate elements have inverses):

\begin{itemize}
\item Parts \textbf{(a)} and \textbf{(b)} let you solve equations of the form
$ax=c$ and $xa=c$ in a group (where $x$ is the unknown and $a$ and $c$ are
knowns). As a consequence, you can solve equations of the form $axb=c$ in a
group for the unknown $x$ (the solution is $x=a^{-1}cb^{-1}$).

\item Parts \textbf{(c)} and \textbf{(d)} let you cancel equal factors from
equalities in a group, but only if they either appear on the very left end of
both sides or on the very right end of both sides. Specifically, part
\textbf{(c)} lets you cancel the factor $a$ from $ab=ac$, while part
\textbf{(d)} lets you cancel it from $ba=ca$. But you cannot generally argue
that $ab=ca$ entails $b=c$.
\end{itemize}

\begin{corollary}
\label{cor.monoid.LaSa}Let $S$ be a monoid, written multiplicatively. Let
$a\in S$ be an element that has an inverse. Then, the maps%
\begin{align*}
L_{a}:S  &  \rightarrow S,\\
x  &  \mapsto ax
\end{align*}
and%
\begin{align*}
R_{a}:S  &  \rightarrow S,\\
x  &  \mapsto xa
\end{align*}
are bijective. (These maps are known as \textbf{left multiplication by }$a$
and \textbf{right multiplication by }$a$, respectively; this explains their names.)
\end{corollary}

\begin{proof}
We shall show that the map $L_{a}$ is bijective by checking that it is both
injective and surjective:

\begin{enumerate}
\item Injectivity of $L_{a}$ means that $ax=ay$ implies $x=y$. But this
follows from Theorem \ref{thm.monoid.cancel} \textbf{(c)} (applied to $b=x$
and $c=y$).

\item Surjectivity of $L_{a}$ means that each $s\in S$ can be written as
$s=ax$ for some $x\in S$. But this is true, since you can take $x=a^{-1}s$,
and then Theorem \ref{thm.monoid.cancel} \textbf{(a)} yields $ax=s$.
\end{enumerate}

So the map $L_{a}$ is both injective and surjective, thus bijective.
Alternatively, you can just show that $L_{a^{-1}}$ is an inverse to $L_{a}$,
and so the map $L_{a}$ is invertible, i.e., bijective.

Either way, we have shown that $L_{a}$ is bijective. Similarly, we can prove
the same for $R_{a}$. Its inverse is $R_{a^{-1}}$.
\end{proof}

Let us next formalize the notion of a multiplication table (we have already
seen a couple in Lecture 2):

\begin{definition}
\label{def.sg.multable}Let $S$ be a semigroup, written multiplicatively. Its
\textbf{multiplication table} is a square table whose rows are indexed by the
elements of $S$, whose columns are indexed by the elements of $S$, and whose
$\left(  x,y\right)  $-th entry (i.e., its entry in row $x$ and column $y$) is
the \textquotedblleft product\textquotedblright\ $xy$. (If the set $S$ is
infinite, then this is an infinite table, so we cannot write it down, but
mathematically it is still a meaningful object.)
\end{definition}

\begin{corollary}
\label{cor.monoid.sudoku}Let $G$ be a group. Then, all the maps $L_{a}$ and
$R_{a}$ (for $a\in G$) are bijective. In other words, in the multiplication
table of a group $G$, each row contains each element of $G$ exactly once, and
each column contains each element of $G$ exactly once (like in a sudoku).
\end{corollary}

\begin{proof}
The \textquotedblleft Then\textquotedblright\ claim follows from Corollary
\ref{cor.monoid.LaSa} (applied to $S=G$), since each $a\in G$ has an inverse.
The \textquotedblleft In other words\textquotedblright\ claim is just a
restatement of the \textquotedblleft Then\textquotedblright\ claim (since the
$a$-th row of the multiplication table of $G$ is a list of all values of
$L_{a}$, so that it contains each element of $G$ exactly once if and only if
$L_{a}$ is bijective; and the same holds for columns and $R_{a}$).
\end{proof}

Let us use this to determine all groups of size $3$:

\begin{example}
\label{exa.groups-size.3}Let $G$ be a group of size $3$. Thus, we can write
$G$ as $G=\left\{  1,f,g\right\}  $ where $1$ is the neutral element of $G$
(we write $G$ multiplicatively). What can its multiplication table look like?
We claim that it must necessarily look as follows:%
\[%
\begin{tabular}
[c]{|c||c|c|c|}\hline
$xy$ & $y=1$ & $y=f$ & $y=g$\\\hline\hline
$x=1$ & $1$ & $f$ & $g$\\\hline
$x=f$ & $f$ & $g$ & $1$\\\hline
$x=g$ & $g$ & $1$ & $f$\\\hline
\end{tabular}
\ \ .
\]
We have filled in these entries step by step: First, since $1$ is neutral, we
must have $1\cdot1=1$ and $1f=f$ and $1g=g$ and $f1=f$ and $g1=g$. Then, $fg$
cannot be $f$ (since Corollary \ref{cor.monoid.sudoku} shows that the $f$-row
of the multiplication table contains each element of $G$ exactly once, so it
cannot contain two $f$'s) and cannot be $g$ (since Corollary
\ref{cor.monoid.sudoku} shows that the $g$-column of the multiplication table
contains each element of $G$ exactly once, so it cannot contain two $g$'s), so
it must be $1$. That is, $fg=1$. Then, $ff$ must be $g$ (since Corollary
\ref{cor.monoid.sudoku} shows that the $f$-row of the multiplication table
contains each element of $G$ exactly once, but it already contains $1$ and
$f$), and similar reasoning shows $gf=1$ and $gg=f$.

This means that the operation (\textquotedblleft
multiplication\textquotedblright) of a group of size $3$ is uniquely
determined by knowing which of its elements is neutral. In more informal
language, this says that \textquotedblleft there is only one group of size
$3$\textquotedblright... of course, after you have convinced yourself that
there is such a group in the first place, i.e., that the above multiplication
table really does satisfy the axioms of a group. Later we will see why there
is a group of size $n$ for every positive integer $n$, so this will become trivial; but for now, we
can just check it by hand (associativity is the only part that requires a bit
of work).
\end{example}

What about groups with size $4$ or size $5$ or size $6$ ? Some foreshadowing:
there is more than one group of size $4$, but only one of size $5$ (upon relabelling).

\subsection{Powers}

We have defined the product of $n$ elements of a semigroup. If these $n$
elements are all equal to a single element $a$, this product is called a
power, just as for numbers. Again, just as for numbers, we can extend this
definition to $n=0$ when there is a neutral element, and to negative $n$ when
$a$ is invertible:

\begin{definition}
\label{def.sg.powers}Let $S$ be a semigroup (written multiplicatively), and
let $a\in S$ be arbitrary.

\begin{enumerate}
\item[\textbf{(a)}] For any positive integer $n$, we define
\[
a^{n}:=\underbrace{aa\cdots a}_{n\text{ times}}.
\]
(Thus, $a^{1}=a$ and $a^{2}=aa$ and $a^{3}=aaa$ and so on.)

\item[\textbf{(b)}] If $S$ is a monoid, then we define%
\[
a^{0}:=1\ \ \ \ \ \ \ \ \ \ \left(  \text{the neutral element of }S\right)  .
\]


Thus, in this case, $a^{n}$ is defined for all $n\in\mathbb{N}$.

\item[\textbf{(c)}] If $S$ is a monoid and $a$ has an inverse, then we define%
\[
a^{n}:=\left(  a^{-1}\right)  ^{-n}\ \ \ \ \ \ \ \ \ \ \text{for all negative
integers }n.
\]
Thus, in this case, $a^{n}$ is defined for all $n\in\mathbb{Z}$.
\end{enumerate}

We refer to $a^{n}$ as the $n$\textbf{-th power} of $a$.
\end{definition}

What rules do you expect the powers to satisfy? For powers of numbers, we know
the laws of exponents:

\begin{itemize}
\item We have $a^{n}a^{m}=a^{n+m}$.

\item We have $\left(  a^{n}\right)  ^{m}=a^{nm}$.

\item We have $a^{-n}=\left(  a^{-1}\right)  ^{n}$ (when $a$ has an inverse).

\item We have $\left(  ab\right)  ^{n}=a^{n}b^{n}$.
\end{itemize}

We will soon see which of these laws still hold for elements of a semigroup
(potentially assuming that an inverse exists). Not all of them do! Can you
tell which ones don't?
\end{document}