\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{tabls}
\usepackage{tikz}
\usepackage{bbding}
%TCIDATA{OutputFilter=latex2.dll}
%TCIDATA{Version=5.50.0.2960}
%TCIDATA{LastRevised=Tuesday, December 20, 2022 20:54:48}
%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
\usetikzlibrary{arrows.meta}
\usetikzlibrary{chains}
\usetikzlibrary{shapes}
\usetikzlibrary{decorations.pathmorphing}
\newcounter{exer}
\newcounter{exera}
\theoremstyle{definition}
\newtheorem{theo}{Theorem}[subsection]
\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}
\newcommand\arxiv[1]{\href{http://www.arxiv.org/abs/#1}{\texttt{arXiv:#1}}}
\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{\are}{\ar@{-}}
\newcommand{\arebi}[1][]{\ar@{<-}@/_/[#1] \ar@/^/[#1]}
\newcommand{\numboxed}[2]{\underbrace{\boxed{#1}}_{\text{box } #2}}
\newcommand{\of}{\text{ of }}
\definecolor{darkgreen}{rgb}{0,.5,0}
\newtheoremstyle{plainsl}
{8pt plus 2pt minus 4pt}
{8pt plus 2pt minus 4pt}
{\slshape}
{0pt}
{\bfseries}
{.}
{5pt plus 1pt minus 1pt}
{}
\theoremstyle{plainsl}
\ihead{Lecture 29, version \today}
\ohead{page \thepage}
\cfoot{}
\begin{document}
\section*{Math 222 Fall 2022, Lecture 29: Lattice paths}

\textbf{website:}
\texttt{\href{https://www.cip.ifi.lmu.de/~grinberg/t/22fco}{\texttt{https://www.cip.ifi.lmu.de/\symbol{126}%
grinberg/t/22fco}}}

\setcounter{section}{4}

\section{\label{chap.lps}Lattice paths and Catalan numbers}

In this short chapter, we shall briefly survey the topics of \textbf{lattice
paths} and of \textbf{Catalan numbers}. Both topics have books written about
them (\cite{Kratte17} for lattice paths, \cite{Stanle15} or \cite{Roman15} for
Catalan numbers); we will only have time for the most elementary results.

\subsection{Lattice paths}

Lattice paths are paths in the integer lattice. We begin by defining the latter:

\begin{definition}
\label{def.lps.lat}The \textbf{integer lattice} (or, for short,
\textbf{lattice}) is the set $\mathbb{Z}^{2}=\mathbb{Z}\times\mathbb{Z}$ of
all pairs of integers.

Its elements (i.e., the pairs of integers) are called \textbf{points}; indeed,
every element $\left(  a,b\right)  \in\mathbb{Z}^{2}$ can be identified with
the point with Cartesian coordinates $a$ and $b$ in the plane.

Points can be added and subtracted entrywise: i.e., we set%
\begin{align*}
\left(  a,b\right)  +\left(  c,d\right)   &  =\left(  a+c,\ \ b+d\right)
\ \ \ \ \ \ \ \ \ \ \text{and}\\
\left(  a,b\right)  -\left(  c,d\right)   &  =\left(  a-c,\ \ b-d\right)
\end{align*}
for any $\left(  a,b\right)  \in\mathbb{Z}^{2}$ and $\left(  c,d\right)
\in\mathbb{Z}^{2}$.
\end{definition}

The integer lattice is countably infinite, but here is a picture of a small
piece of it:%
\[%
%TCIMACRO{\TeXButton{tikz lattice}{\begin{tikzpicture}
%\draw[help lines] (-2.2, -2.2) grid (5.2, 3.2);
%\draw[line width=2pt,-] (-2.2, 0) edge (5.2, 0);
%\draw[line width=2pt,-] (0, -2.2) edge (0, 3.2);
%\foreach\x in {-2, -1, 0, 1, 2, 3, 4, 5} {
%\foreach\y in {-2, -1, 0, 1, 2, 3} {
%\draw[fill=blue] (\x, \y) circle (0.1);
%};
%};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-2.2, -2.2) grid (5.2, 3.2);
\draw[line width=2pt,-] (-2.2, 0) edge (5.2, 0);
\draw[line width=2pt,-] (0, -2.2) edge (0, 3.2);
\foreach\x in {-2, -1, 0, 1, 2, 3, 4, 5} {
\foreach\y in {-2, -1, 0, 1, 2, 3} {
\draw[fill=blue] (\x, \y) circle (0.1);
};
};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
(Here, the thick black lines are the x-axis and the y-axis; the other lines
are parallels to the axes at integer levels (i.e., lines of the form $x=n$ or
$y=n$ for $n\in\mathbb{Z}$), and the blue circles are the points of the lattice.)

Next, we define the notion of lattice paths. There are actually several
different notions of lattice paths, but the following one is the simplest (and
also the most useful)\footnote{Various other notions are discussed in
\cite{Kratte17}.}:

\begin{definition}
\label{def.lps.lp}Let $\left(  a,b\right)  \in\mathbb{Z}^{2}$ and $\left(
c,d\right)  \in\mathbb{Z}^{2}$ be two points. Then, a \textbf{lattice path}
(for short: \textbf{LP}) from $\left(  a,b\right)  $ to $\left(  c,d\right)  $ is

\begin{itemize}
\item informally understood to be a path from $\left(  a,b\right)  $ to
$\left(  c,d\right)  $ in the plane that uses only the following two kinds of steps:

\begin{itemize}
\item \textquotedblleft\textbf{up-steps}\textquotedblright\ (denoted
\textquotedblleft$U$\textquotedblright) that go from a point $\left(
p,q\right)  $ to $\left(  p,q+1\right)  $;

\item \textquotedblleft\textbf{right-steps}\textquotedblright\ (denoted
\textquotedblleft$R$\textquotedblright) that go from a point $\left(
p,q\right)  $ to $\left(  p+1,q\right)  $.
\end{itemize}

\item rigorously defined to be a tuple $\left(  v_{0},v_{1},\ldots
,v_{n}\right)  $ of points $v_{0},v_{1},\ldots,v_{n}\in\mathbb{Z}^{2}$ such
that%
\begin{align*}
v_{0}  &  =\left(  a,b\right)  \ \ \ \ \ \ \ \ \ \ \text{and}%
\ \ \ \ \ \ \ \ \ \ v_{n}=\left(  c,d\right)  \ \ \ \ \ \ \ \ \ \ \text{and}\\
v_{i}-v_{i-1}  &  \in\left\{  \left(  0,1\right)  ,\ \ \left(  1,0\right)
\right\}  \ \ \ \ \ \ \ \ \ \ \text{for each }i\in\left[  n\right]  .
\end{align*}
If $\left(  v_{0},v_{1},\ldots,v_{n}\right)  $ is a LP from $\left(
a,b\right)  $ to $\left(  c,d\right)  $, then the differences $v_{i}-v_{i-1}$
(for $i\in\left[  n\right]  $) are called the \textbf{steps} of this LP. The
pair $\left(  0,1\right)  $ is called an \textbf{up-step} and is denoted by
$U$; the pair $\left(  1,0\right)  $ is called a \textbf{right-step} and is
denoted by $R$. If $\left(  v_{0},v_{1},\ldots,v_{n}\right)  $ is an LP, then
the sequence
\[
\left(  v_{1}-v_{0},\ \ v_{2}-v_{1},\ \ v_{3}-v_{2},\ \ \ldots,\ \ v_{n}%
-v_{n-1}\right)
\]
of all its steps is called the \textbf{step sequence} of this LP.
\end{itemize}

An LP from $\left(  a,b\right)  $ to $\left(  c,d\right)  $ is also called an
LP that \textbf{starts} at $\left(  a,b\right)  $ and \textbf{ends} at
$\left(  c,d\right)  $.
\end{definition}

Of course, any LP $\left(  v_{0},v_{1},\ldots,v_{n}\right)  $ can be drawn by
marking the points $v_{0},v_{1},\ldots,v_{n}$ on the Cartesian plane and
connecting each of them by a line segment to the next one.

\begin{example}
\label{exa.lps.lp.1}The following picture shows a LP from $\left(  0,
0\right)  $ to $\left(  5,3\right)  $:%
\[%
%TCIMACRO{\TeXButton{tikz RURRRUUR lattice path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (4, 3) (4, 3) edge (5, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 0\right)$}};
%\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(5,3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (4, 3) (4, 3) edge (5, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 0\right)$}};
\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(5,3\right)$}};
\end{tikzpicture}%
%EndExpansion
\]
Formally speaking, this LP is the $9$-tuple%
\[
\left(  \left(  0,0\right)  ,\ \ \left(  1,0\right)  ,\ \ \left(  1,1\right)
,\ \ \left(  2,1\right)  ,\ \ \left(  3,1\right)  ,\ \ \left(  4,1\right)
,\ \ \left(  4,2\right)  ,\ \ \left(  4,3\right)  ,\ \ \left(  5,3\right)
\right)  .
\]
Its step sequence is $\left(  R,U,R,R,R,U,U,R\right)  $ (meaning that its
first step is a right-step, its second step is an up-step, its third step is a
right-step, and so on).
\end{example}

We agree to omit the commas and the parentheses when writing down the step
sequence of a LP. Thus, the LP from Example \ref{exa.lps.lp.1} has step
sequence $RURRRUUR$.

Note that any LP is uniquely determined by its starting point and its step sequence.

\bigskip

A counting problem immediately suggests itself: How many LPs are there from a
given point to a given point? Here is the answer, in two equivalent forms:

\begin{proposition}
\label{prop.lps.num}Let $\left(  a,b\right)  \in\mathbb{Z}^{2}$ and $\left(
c,d\right)  \in\mathbb{Z}^{2}$ be two points. Then,%
\begin{align}
&  \left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right) \nonumber\\
&  =%
\begin{cases}
\dbinom{c-a+d-b}{c-a}, & \text{if }c\geq a\text{ and }d\geq b;\\
0, & \text{otherwise}%
\end{cases}
\label{eq.prop.lps.num.1}\\
&  =%
\begin{cases}
\dbinom{c-a+d-b}{c-a}, & \text{if }c+d\geq a+b;\\
0, & \text{otherwise.}%
\end{cases}
\label{eq.prop.lps.num.2}%
\end{align}

\end{proposition}

\begin{proof}
[Proof sketch.]We shall first focus on proving (\ref{eq.prop.lps.num.1}).

We are in one of the following three cases:

\textit{Case 1:} We have $c\geq a$ and $d\geq b$.

\textit{Case 2:} We have $d<b$.

\textit{Case 3:} We have $c<a$.

Let us first consider Case 1. In this case, we have $c\geq a$ and $d\geq b$.

If $\mathbf{v}$ is any LP from $\left(  a,b\right)  $ to $\left(  c,d\right)
$, then the step sequence of $\mathbf{v}$ must contain exactly $c-a$ many
right-steps\footnote{Indeed, the x-coordinate of a point increases by $1$ when
we move it along a right-step, and doesn't change when we move it along an
up-step. Thus, in order to get from $\left(  a,b\right)  $ to $\left(
c,d\right)  $, we need to make $c-a$ right-steps (since the x-coordinate has
to grow from $a$ to $c$).} and exactly $d-b$ many up-steps\footnote{for an
analogous reason}. In other words, this step sequence must contain $c-a$ many
$R$'s and $d-b$ many $U$'s. Hence, this step sequence must be an
anagram\footnote{See Definition 2.10.9 in Lecture 23 for the concept of
\textquotedblleft anagram\textquotedblright\ that we are using here.} of the
tuple
\[
\left(  \underbrace{R,R,\ldots,R}_{c-a\text{ times}},\underbrace{U,U,\ldots
,U}_{d-b\text{ times}}\right)  .
\]


Thus, there is a map
\begin{align*}
&  \text{from }\left\{  \text{LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right\} \\
&  \text{to }\left\{  \text{anagrams of }\left(  \underbrace{R,R,\ldots
,R}_{c-a\text{ times}},\underbrace{U,U,\ldots,U}_{d-b\text{ times}}\right)
\right\}
\end{align*}
which sends each LP to its step sequence. This map is easily seen to be
injective (since an LP is uniquely determined by its starting point and its
step sequence) and surjective (since any sequence of $c-a$ right-steps and
$d-b$ up-steps starting at the point $\left(  a,b\right)  $ will lead to
$\left(  c,d\right)  $). Thus, it is a bijection. Hence, the bijection
principle yields%
\begin{align}
&  \left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right) \nonumber\\
&  =\left(  \text{\# of anagrams of }\left(  \underbrace{R,R,\ldots
,R}_{c-a\text{ times}},\underbrace{U,U,\ldots,U}_{d-b\text{ times}}\right)
\right) \nonumber\\
&  =\left(  \text{\# of anagrams of }\left(  \underbrace{1,1,\ldots
,1}_{c-a\text{ times}},\underbrace{2,2,\ldots,2}_{d-b\text{ times}}\right)
\right) \nonumber\\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(  \text{here, we have
relabelled the }R\text{'s and the }U\text{'s as }1\text{'s and }%
2\text{'s}\right) \nonumber\\
&  =\dbinom{\left(  c-a\right)  +\left(  d-b\right)  }{c-a,\ d-b}
\label{pf.prop.lps.num.4}%
\end{align}
(by Theorem 2.10.11 in Lecture 23, applied to $n=\left(  c-a\right)  +\left(
d-b\right)  $ and $k=2$ and $n_{1}=c-a$ and $n_{2}=d-b$ and $\alpha=\left(
\underbrace{1,1,\ldots,1}_{c-a\text{ times}},\underbrace{2,2,\ldots
,2}_{d-b\text{ times}}\right)  $).

However, if $k$ and $\ell$ are any two nonnegative integers, then
$\dbinom{k+\ell}{k,\ell}=\dbinom{k+\ell}{k}$ (by Proposition 2.10.3 in Lecture
22, applied to $n=k+\ell$). Applying this to $k=c-a$ and $\ell=d-b$, we obtain
$\dbinom{\left(  c-a\right)  +\left(  d-b\right)  }{c-a,\ d-b}=\dbinom{\left(
c-a\right)  +\left(  d-b\right)  }{c-a}=\dbinom{c-a+d-b}{c-a}$. Hence, we can
rewrite (\ref{pf.prop.lps.num.4}) as%
\[
\left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right)  =\dbinom{c-a+d-b}{c-a}.
\]
This proves (\ref{eq.prop.lps.num.1}) in Case 1 (since $c\geq a$ and $d\geq b$).

Let us now consider Case 2. In this case, we have $d<b$. Thus, $d-b<0$. Just
as in Case 1, we can see that if $\mathbf{v}$ is any LP from $\left(
a,b\right)  $ to $\left(  c,d\right)  $, then the step sequence of
$\mathbf{v}$ must contain exactly $d-b$ many up-steps. However, this is
actually impossible, since $d-b<0$. Thus, there is no LP from $\left(
a,b\right)  $ to $\left(  c,d\right)  $. In other words,
\[
\left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right)  =0.
\]
This proves (\ref{eq.prop.lps.num.1}) in Case 2 (since we don't have $c\geq a$
and $d\geq b$).

The proof of (\ref{eq.prop.lps.num.1}) in Case 3 is similar (but now we need
to use $c-a<0$ instead of $d-b<0$).

Thus, we have proved (\ref{eq.prop.lps.num.1}) in all three Cases 1, 2 and 3.
This completes the proof of (\ref{eq.prop.lps.num.1}).

It remains to prove (\ref{eq.prop.lps.num.2}). To this purpose, it suffices to
show (since (\ref{eq.prop.lps.num.1}) has already been proven) that
\begin{equation}
\dbinom{c-a+d-b}{c-a}=0 \label{pf.prop.lps.num.end}%
\end{equation}
whenever we have $c+d\geq a+b$ but not $\left(  c\geq a\text{ and }d\geq
b\right)  $. This is rather easy: Assume that we have $c+d\geq a+b$, but we
don't have $\left(  c\geq a\text{ and }d\geq b\right)  $. Hence, we have
either $c<a$ or $d<b$. If $c<a$, then (\ref{pf.prop.lps.num.end}) is obvious
(since $c<a$ entails $c-a\notin\mathbb{N}$). If $d<b$, then
(\ref{pf.prop.lps.num.end}) is easily verified as well (by Proposition 1.3.5
in Lecture 5, since $c-a+d-b\in\mathbb{N}$ and $c-a>c-a+d-b$). Thus,
(\ref{pf.prop.lps.num.end}) holds in either case, and this completes our proof
of Proposition \ref{prop.lps.num}.
\end{proof}

We can ask a slightly subtler counting question:

\begin{definition}
\label{def.lps.contains}Let $\mathbf{v}=\left(  v_{0},v_{1},\ldots
,v_{n}\right)  $ be a LP from a point $\left(  a,b\right)  $ to a point
$\left(  c,d\right)  $. Let $p\in\mathbb{Z}^{2}$ be a point. We say that
$p\in\mathbf{v}$ (in words: $p$ \textbf{lies on} $\mathbf{v}$) if
$p\in\left\{  v_{0},v_{1},\ldots,v_{n}\right\}  $.
\end{definition}

For example, if $\mathbf{v}$ is the LP in Example~\ref{exa.lps.lp.1}, then
$\left(  4,2\right)  \in\mathbf{v}$, but $\left(  3,2\right)  $ does not lie
on $\mathbf{v}$.

\begin{exercise}
\label{exe.lps.through22}Find the \# of LPs $\mathbf{v}$ from $\left(
0,0\right)  $ to $\left(  6,6\right)  $ such that $\left(  2,2\right)
\in\mathbf{v}$.
\end{exercise}

\begin{proof}
[Solution sketch.]Each such LP $\mathbf{v}$ consists of a LP from $\left(
0,0\right)  $ to $\left(  2,2\right)  $ and a LP from $\left(  2,2\right)  $
to $\left(  6,6\right)  $. Thus, the product rule yields%
\begin{align*}
&  \left(  \text{\# of LPs }\mathbf{v}\text{ from }\left(  0,0\right)  \text{
to }\left(  6,6\right)  \text{ such that }\left(  2,2\right)  \in
\mathbf{v}\right) \\
&  =\underbrace{\left(  \text{\# of LPs from }\left(  0,0\right)  \text{ to
}\left(  2,2\right)  \right)  }_{\substack{=\dbinom{2-0+2-0}{2-0}\\\text{(by
Proposition \ref{prop.lps.num})}}}\cdot\underbrace{\left(  \text{\# of LPs
from }\left(  2,2\right)  \text{ to }\left(  6,6\right)  \right)
}_{\substack{=\dbinom{6-2+6-2}{6-2}\\\text{(by Proposition \ref{prop.lps.num}%
)}}}\\
&  =\dbinom{2-0+2-0}{2-0}\cdot\dbinom{6-2+6-2}{6-2}=\dbinom{4}{2}\cdot
\dbinom{8}{4}=420.
\end{align*}

\end{proof}

\subsection{Catalan paths}

More interesting counting problems concern lattice paths whose points are
restricted by some requirements:

\begin{definition}
\label{def.lps.cat}A LP $\mathbf{v}$ is said to be \textbf{Catalan} if each
$\left(  x,y\right)  \in\mathbf{v}$ satisfies $x\geq y$.
\end{definition}

In other words, a LP $\mathbf{v}$ is Catalan if and only if it lies entirely
in the halfplane below the diagonal given by the equation $x=y$ (including the
diagonal itself). In yet other words, a LP $\mathbf{v}$ is Catalan if it never
strays above this diagonal.\footnote{The name \textquotedblleft
Catalan\textquotedblright\ refers not to the province of Catalonia, nor to its
language, but to the Belgian mathematician Eug\`{e}ne Charles Catalan, who did
not actually study LPs but rather counted an equivalent class of objects (the
\textquotedblleft legal words of parentheses\textquotedblright\ briefly
discussed below) in 1838.}

\begin{example}
\label{exa.lps.cat.1}The following picture shows a Catalan LP from $\left(
0,0\right)  $ to $\left(  4,4\right)  $:%
\[%
%TCIMACRO{\TeXButton{tikz RURRUURU catalan path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.2, -0.2) -- (4.2, 4.2) -- (4.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (4.2, 4.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (3, 2) (3, 2) edge (3, 3) (3, 3) edge (4, 3) (4, 3) -- (4, 4);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (4, 4) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(4, 4\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.2, -0.2) -- (4.2, 4.2) -- (4.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (4.2, 4.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (3, 2) (3, 2) edge (3, 3) (3, 3) edge (4, 3) (4, 3) -- (4, 4);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (4, 4) circle (0.1) node[above right] {\textcolor
{blue}{$\left(4, 4\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
(Here, the region shaded cyan is the set of all $\left(  x,y\right)
\in\mathbb{R}^{2}$ satisfying $x\geq y$; this is the region in which a Catalan
LP must stay.)

The following LP from $\left(  0,0\right)  $ to $\left(  4,4\right)  $ is
\textbf{not} Catalan:%
\begin{equation}%
%TCIMACRO{\TeXButton{tikz RUURRRUU non-catalan path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.2, -0.2) -- (4.2, 4.2) -- (4.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (4.2, 4.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (1, 2) (1, 2) edge (2, 2) (2, 2) edge (3, 2) (3, 2) edge (4, 2) (4, 2) edge (4, 3) (4, 3) -- (4, 4);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (4, 4) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(4, 4\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.2, -0.2) -- (4.2, 4.2) -- (4.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (4.2, 4.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (1, 2) (1, 2) edge (2, 2) (2, 2) edge (3, 2) (3, 2) edge (4, 2) (4, 2) edge (4, 3) (4, 3) -- (4, 4);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (4, 4) circle (0.1) node[above right] {\textcolor
{blue}{$\left(4, 4\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ . \label{eq.exa.lps.cat.1.noncat}%
\end{equation}

\end{example}

For another example, the LP $\mathbf{v}$ in Example \ref{exa.lps.lp.1} is
Catalan, whereas the LP with starting point $\left(  0,0\right)  $ and step
sequence $RUUR$ is not (since it contains the point $\left(  1,2\right)  $).

\begin{definition}
\label{def.lps.Lnm}If $n,m\in\mathbb{Z}$, then we set%
\[
L_{n,m}:=\left(  \text{\# of Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  n,m\right)  \right)  .
\]

\end{definition}

Here is a table of some of the values of $L_{n,m}$:%
\[%
\begin{tabular}
[c]{|c||c|c|c|c|c|c|}\hline
$L_{n,m}$ & $m=0$ & $m=1$ & $m=2$ & $m=3$ & $m=4$ & $m=5$\\\hline\hline
$n=0$ & $1$ & $0$ & $0$ & $0$ & $0$ & $0$\\\hline
$n=1$ & $1$ & $1$ & $0$ & $0$ & $0$ & $0$\\\hline
$n=2$ & $1$ & $2$ & $2$ & $0$ & $0$ & $0$\\\hline
$n=3$ & $1$ & $3$ & $5$ & $5$ & $0$ & $0$\\\hline
$n=4$ & $1$ & $4$ & $9$ & $14$ & $14$ & $0$\\\hline
$n=5$ & $1$ & $5$ & $14$ & $28$ & $42$ & $42$\\\hline
\end{tabular}
\ \ .
\]


How can $L_{n,m}$ be computed? Several answers are given in the following theorem:

\begin{theorem}
\label{thm.lps.Lnm.formulas}\textbf{(a)} We have $L_{n,m}=L_{n-1,m}+L_{n,m-1}$
for any $n\in\mathbb{Z}$ and $m\in\mathbb{Z}$ satisfying $n\geq m$ and
$\left(  n,m\right)  \neq\left(  0,0\right)  $.

\textbf{(b)} If $n\in\mathbb{Z}$ and $m\in\mathbb{Z}$ satisfy $n<m$, then
$L_{n,m}=0$.

\textbf{(c)} If $n\in\mathbb{N}$ and $m\in\mathbb{N}$ satisfy $n\geq m-1$,
then%
\[
L_{n,m}=\dbinom{n+m}{m}-\dbinom{n+m}{m-1}.
\]


\textbf{(d)} If $n\in\mathbb{N}$ and $m\in\mathbb{N}$ satisfy $n\geq m-1$,
then%
\[
L_{n,m}=\dfrac{n+1-m}{n+1}\dbinom{n+m}{m}.
\]


\textbf{(e)} If $n\in\mathbb{N}$, then%
\[
L_{n,n}=\dfrac{1}{n+1}\dbinom{2n}{n}.
\]

\end{theorem}

A straightforward inductive proof of Theorem \ref{thm.lps.Lnm.formulas} can be
found in \cite[Exercise 2]{18s-mt2s} (where Catalan LPs are called
\textquotedblleft legal LPs\textquotedblright).\footnote{All parts of Theorem
\ref{thm.lps.Lnm.formulas} except for part \textbf{(b)} are proved there. But
part \textbf{(b)} is obvious, since a point $\left(  n,m\right)  $ with $n<m$
cannot lie on a Catalan LP by definition.} Let us, however, prove a more
general version of Theorem \ref{thm.lps.Lnm.formulas} \textbf{(c)}, counting
the Catalan LPs between any two points $\left(  a,b\right)  $ and $\left(
c,d\right)  $:

\begin{theorem}
\label{thm.lps.catabcd}Let $a,b,c,d\in\mathbb{Z}$ satisfy $a\geq b$ and $c\geq
d-1$ and $c+d\geq a+b$. Then,%
\begin{align*}
&  \left(  \text{\# of Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  c,d\right)  \right) \\
&  =\dbinom{c-a+d-b}{c-a}-\dbinom{c-a+d-b}{d-a-1}.
\end{align*}

\end{theorem}

Note that if any of the conditions \textquotedblleft$a\geq b$ and $c\geq d-1$
and $c+d\geq a+b$\textquotedblright\ is violated, then we simply have $\left(
\text{\# of Catalan LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right)  =0$, since no Catalan LPs from $\left(  a,b\right)  $ to
$\left(  c,d\right)  $ exist (check this!). Theorem \ref{thm.lps.catabcd} is
\cite[Theorem 10.3.1]{Kratte17}, and the below proof is similar to the one
given in \cite{Kratte17}.

\begin{proof}
[Proof of Theorem \ref{thm.lps.catabcd} (sketched).]The difference rule
yields
\begin{align*}
&  \left(  \text{\# of Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  c,d\right)  \right) \\
&  =\left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right) \\
&  \ \ \ \ \ \ \ \ \ \ -\left(  \text{\# of non-Catalan LPs from }\left(
a,b\right)  \text{ to }\left(  c,d\right)  \right)
\end{align*}
(where \textquotedblleft non-Catalan\textquotedblright\ means
\textquotedblleft not Catalan\textquotedblright). Since
(\ref{eq.prop.lps.num.2}) yields that
\[
\left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
c,d\right)  \right)  =\dbinom{c-a+d-b}{c-a},
\]
it remains only to show that
\begin{equation}
\left(  \text{\# of non-Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  c,d\right)  \right)  \overset{?}{=}\dbinom{c-a+d-b}{d-a-1}.
\label{pf.thm.lps.Lnm.formulas.c.goal}%
\end{equation}


The very form of this equality suggests that we should be looking for a
bijection. Specifically, a bijection
\begin{align*}
&  \text{from }\left\{  \text{non-Catalan LPs from }\left(  a,b\right)  \text{
to }\left(  c,d\right)  \right\} \\
&  \text{to }\left\{  \text{all LPs from }\left(  a,b\right)  \text{ to
}\left(  d-1,c+1\right)  \right\}
\end{align*}
would yield (\ref{pf.thm.lps.Lnm.formulas.c.goal}), since
(\ref{eq.prop.lps.num.2}) easily yields that
\[
\left(  \text{\# of all LPs from }\left(  a,b\right)  \text{ to }\left(
d-1,c+1\right)  \right)  =\dbinom{c-a+d-b}{d-a-1}.
\]


Such a bijection indeed exists, and its construction is rather peculiar:

The \textbf{transpose} of a pair $\left(  i,j\right)  $ shall mean the pair
$\left(  j,i\right)  $. Thus, the transpose of an up-step is a right-step, and
vice versa.

The entries $v_{0},v_{1},\ldots,v_{k}$ of a LP $\left(  v_{0},v_{1}%
,\ldots,v_{k}\right)  $ shall be called its \textbf{vertices}. A point
$\left(  x,y\right)  $ will be called \textbf{illegal} if it satisfies $x<y$.
Thus, a LP is non-Catalan if and only if it has an illegal vertex. (For
instance, the LP shown in (\ref{eq.exa.lps.cat.1.noncat}) has the illegal
vertex $\left(  1,2\right)  $.)

Let $\mathbf{v}=\left(  v_{0},v_{1},\ldots,v_{k}\right)  $ be a non-Catalan LP
starting at $\left(  a,b\right)  $. Let $v_{i}=\left(  x_{i},y_{i}\right)  $
be its \textbf{first} illegal vertex. Hence, we must have $x_{i}=y_{i}-1$,
since otherwise the previous vertex $v_{i-1}$ of $\mathbf{v}$ would also be
illegal\footnote{Let us explain this argument in some more detail. First, we
observe that $v_{i}$ is illegal, but $v_{0}$ is not (since $v_{0}=\left(
a,b\right)  $ satisfies $a\geq b$). Thus, $v_{i}\neq v_{0}$ and therefore
$i\neq0$. Hence, $v_{i-1}$ is well-defined. Furthermore, $v_{i-1}$ cannot be
illegal (since $v_{i}$ is the \textbf{first} illegal vertex of $\mathbf{v}$,
but $v_{i-1}$ comes before $v_{i}$).
\par
Write $v_{i-1}$ in the form $v_{i-1}=\left(  x_{i-1},y_{i-1}\right)  $. Then,
$x_{i-1}\geq y_{i-1}$ (since $v_{i-1}$ is not illegal). Note also that
$x_{i}<y_{i}$ (since $\left(  x_{i},y_{i}\right)  =v_{i}$ is illegal). Hence,
$x_{i}\leq y_{i}-1$ (since $x_{i}$ and $y_{i}$ are integers).
\par
From $v_{i}=\left(  x_{i},y_{i}\right)  $ and $v_{i-1}=\left(  x_{i-1}%
,y_{i-1}\right)  $, we obtain $v_{i}-v_{i-1}=\left(  x_{i}-x_{i-1}%
,\ y_{i}-y_{i-1}\right)  $.
\par
However, $v_{i}-v_{i-1}$ is either an up-step or a right-step (since $v_{i}$
follows $v_{i-1}$ on the LP $\mathbf{v}$). In other words, $v_{i}-v_{i-1}$ is
either $\left(  0,1\right)  $ or $\left(  1,0\right)  $. In view of
$v_{i}-v_{i-1}=\left(  x_{i}-x_{i-1},\ y_{i}-y_{i-1}\right)  $, we can rewrite
this as follows:%
\[
\left(  x_{i}-x_{i-1},\ y_{i}-y_{i-1}\right)  \text{ is either }\left(
0,1\right)  \text{ or }\left(  1,0\right)  .
\]
Hence, in particular, $x_{i}-x_{i-1}$ is either $0$ or $1$, whereas
$y_{i}-y_{i-1}$ is either $1$ or $0$. Thus, in particular, $x_{i}-x_{i-1}%
\geq0$ and $y_{i}-y_{i-1}\leq1$. Now,%
\begin{align*}
y_{i}-1  &  \leq y_{i-1}\ \ \ \ \ \ \ \ \ \ \left(  \text{since }y_{i}%
-y_{i-1}\leq1\right) \\
&  \leq x_{i-1}\ \ \ \ \ \ \ \ \ \ \left(  \text{since }x_{i-1}\geq
y_{i-1}\right) \\
&  \leq x_{i}\ \ \ \ \ \ \ \ \ \ \left(  \text{since }x_{i}-x_{i-1}%
\geq0\right)  .
\end{align*}
Combining this with $x_{i}\leq y_{i}-1$, we obtain $x_{i}=y_{i}-1$, qed.}. In
other words, $v_{i}$ is \textquotedblleft just above\textquotedblright\ the
diagonal line with equation $x=y$. From $x_{i}=y_{i}-1$, we obtain
$x_{i}-y_{i}=-1$.

Note that the LP $\mathbf{v}$ takes $i$ steps to get from the point
$v_{0}=\left(  a,b\right)  $ to the point $v_{i}=\left(  x_{i},y_{i}\right)
$. In its remaining $k-i$ steps, it then proceeds from $v_{i}$ on to $v_{k}$.

We now define a new LP $\mathbf{v}^{\prime}$, which again starts at $\left(
a,b\right)  $ and which again has $k$ steps, as follows:

\begin{itemize}
\item Its first $i$ steps are precisely the first $i$ steps of $\mathbf{v}$.
(These $i$ steps take it to the point $v_{i}=\left(  x_{i},y_{i}\right)  $.)

\item Its remaining $k-i$ steps are the transposes of the last $k-i$ steps of
$\mathbf{v}$.
\end{itemize}

In other words, the path $\mathbf{v}^{\prime}$ makes the same first $i$ steps
as $\mathbf{v}$, but afterwards it makes a right-step whenever $\mathbf{v}$
makes an up-step and vice versa.\footnote{Geometrically, this can be viewed as
reflecting the part of $\mathbf{v}$ that comes after the point $v_{i}$ across
the line through $v_{i}$ with slope $1$. For this reason, what we are doing
right now is sometimes called the \textquotedblleft reflection
trick\textquotedblright\ or the \textquotedblleft reflection
principle\textquotedblright.}

Let us illustrate the definition of $\mathbf{v}^{\prime}$ on an example:

\begin{example}
Let $\mathbf{v}$ be the non-Catalan LP from $\left(  0,0\right)  $ to $\left(
6,4\right)  $ shown in the following picture:%
\[%
%TCIMACRO{\TeXButton{tikz v}{\begin{tikzpicture}
%\fill
%[cyan!25] (-0.2, -0.2) -- (4.2, 4.2) -- (6.2, 4.2) -- (6.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (6.2, 4.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) --(1, 2);
%\draw
%[line width=2pt,-stealth,blue] (1, 2) edge (2, 2) (2, 2) edge (3, 2) (3, 2) edge (3, 3) (3, 3) edge (3, 4) (3, 4) edge (4, 4) (4, 4) edge (5, 4) (5, 4) -- (6, 4);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (6, 4) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(6, 4\right)$}};
%\draw[fill=red] (1, 2) circle (0.1) node[above left] {\textcolor{blue}%
%{$\left(1, 2\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill
[cyan!25] (-0.2, -0.2) -- (4.2, 4.2) -- (6.2, 4.2) -- (6.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (6.2, 4.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) --(1, 2);
\draw
[line width=2pt,-stealth,blue] (1, 2) edge (2, 2) (2, 2) edge (3, 2) (3, 2) edge (3, 3) (3, 3) edge (3, 4) (3, 4) edge (4, 4) (4, 4) edge (5, 4) (5, 4) -- (6, 4);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (6, 4) circle (0.1) node[above right] {\textcolor
{blue}{$\left(6, 4\right)$}};
\draw[fill=red] (1, 2) circle (0.1) node[above left] {\textcolor{blue}%
{$\left(1, 2\right)$}};
\end{tikzpicture}%
%EndExpansion
\]
(we will soon explain why some steps of $\mathbf{v}$ have been painted blue).
Then, the first illegal vertex of $\mathbf{v}$ is the point $\left(
1,2\right)  $ (circled in red in the above picture). The LP $\mathbf{v}$ makes
$3$ steps before reaching this point (these are the black steps), and
subsequently makes $7$ further steps (these are the blue steps). To construct
$\mathbf{v}^{\prime}$, we thus need to leave the first $3$ steps of
$\mathbf{v}$ (that is, the black steps) unchanged but replace the remaining
$7$ steps (that is, the blue steps) by their transposes. Thus, $\mathbf{v}%
^{\prime}$ is the following LP:%
\[%
%TCIMACRO{\TeXButton{tikz v'}{\begin{tikzpicture}
%\fill[cyan!25] (-0.2, -0.2) -- (3.2, 3.2) -- (3.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (3.2, 7.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) -- (1, 2);
%\draw
%[line width=2pt,-stealth, blue] (1, 2) edge (1, 3) (1, 3) edge (1, 4) (1, 4) edge (2, 4) (2, 4) edge (3, 4) (3, 4) edge (3, 5) (3, 5) edge (3, 6) (3, 6) -- (3, 7);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (3, 7) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(3, 7\right)$}};
%\draw[fill=red] (1, 2) circle (0.1) node[above left] {\textcolor{blue}%
%{$\left(1, 2\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.2, -0.2) -- (3.2, 3.2) -- (3.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (3.2, 7.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) -- (1, 2);
\draw
[line width=2pt,-stealth, blue] (1, 2) edge (1, 3) (1, 3) edge (1, 4) (1, 4) edge (2, 4) (2, 4) edge (3, 4) (3, 4) edge (3, 5) (3, 5) edge (3, 6) (3, 6) -- (3, 7);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (3, 7) circle (0.1) node[above right] {\textcolor
{blue}{$\left(3, 7\right)$}};
\draw[fill=red] (1, 2) circle (0.1) node[above left] {\textcolor{blue}%
{$\left(1, 2\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
This is an LP from $\left(  0,0\right)  $ to $\left(  3,7\right)  $.
\end{example}

Back to the general case. We observe some properties of $\mathbf{v}^{\prime}$:

\begin{enumerate}
\item If the LP $\mathbf{v}$ ends at $\left(  c,d\right)  $, then the LP
$\mathbf{v}^{\prime}$ ends at $\left(  d-1,c+1\right)  $.

\textit{Proof:} Assume that the LP $\mathbf{v}$ ends at $\left(  c,d\right)  $.

Before reaching the point $v_{i}$, the LP $\mathbf{v}$ makes $x_{i}-a$
right-steps (since it goes from $\left(  a,b\right)  $ to $v_{i}=\left(
x_{i},y_{i}\right)  $) and $y_{i}-b$ up-steps (for the same reason). The LP
$\mathbf{v}^{\prime}$ contains all of these steps (by its definition).

After reaching the point $v_{i}$, the LP $\mathbf{v}$ makes $c-x_{i}$
right-steps (since it goes from $v_{i}=\left(  x_{i},y_{i}\right)  $ to
$\left(  c,d\right)  $) and $d-y_{i}$ up-steps (for the same reason). The LP
$\mathbf{v}^{\prime}$ contains the transposes of all these steps (by its
definition), so it contains $c-x_{i}$ up-steps and $d-y_{i}$ right-steps after
reaching the point $v_{i}$.

Altogether, the LP $\mathbf{v}^{\prime}$ therefore contains $\left(
x_{i}-a\right)  +\left(  d-y_{i}\right)  $ right-steps and $\left(
y_{i}-b\right)  +\left(  c-x_{i}\right)  $ up-steps. Since it starts at
$\left(  a,b\right)  $, it therefore ends at%
\begin{align*}
&  \left(  \underbrace{a+\left(  x_{i}-a\right)  +\left(  d-y_{i}\right)
}_{\substack{=d+x_{i}-y_{i}\\=d+\left(  x_{i}-y_{i}\right)  }%
},\ \ \underbrace{b+\left(  y_{i}-b\right)  +\left(  c-x_{i}\right)
}_{\substack{=c-x_{i}+y_{i}\\=c-\left(  x_{i}-y_{i}\right)  }}\right) \\
&  =\left(  d+\underbrace{\left(  x_{i}-y_{i}\right)  }_{=-1}%
,\ c-\underbrace{\left(  x_{i}-y_{i}\right)  }_{=-1}\right)  =\left(
d+\left(  -1\right)  ,\ c-\left(  -1\right)  \right)  =\left(  d-1,c+1\right)
.
\end{align*}


\item If the LP $\mathbf{v}$ ends at $\left(  d-1,c+1\right)  $, then the LP
$\mathbf{v}^{\prime}$ ends at $\left(  c,d\right)  $.

\textit{Proof:} This is proved just like the previous observation, except that
$c$ and $d$ are replaced by $d-1$ and $c+1$.

\item The LP $\mathbf{v}^{\prime}$ is non-Catalan, and its first illegal
vertex is precisely the first illegal vertex of $\mathbf{v}$ (that is, $v_{i}$).

\textit{Proof:} The first $i$ steps of $\mathbf{v}^{\prime}$ have been copied
over from $\mathbf{v}$ unchanged, so it is clear that $v_{i}$ still lies on
$\mathbf{v}^{\prime}$ and is furthermore the first illegal vertex of
$\mathbf{v}^{\prime}$.
\end{enumerate}

Now, forget that we fixed $\mathbf{v}$. Thus, for each non-Catalan LP
$\mathbf{v}$ starting at $\left(  a,b\right)  $, we have constructed a
non-Catalan LP $\mathbf{v}^{\prime}$ starting at $\left(  a,b\right)  $.
Moreover, if the former LP $\mathbf{v}$ ends at $\left(  c,d\right)  $, then
the latter LP $\mathbf{v}^{\prime}$ ends at $\left(  d-1,c+1\right)  $. This
gives us a map%
\begin{align*}
&  \text{from }\left\{  \text{non-Catalan LPs from }\left(  a,b\right)  \text{
to }\left(  c,d\right)  \right\} \\
&  \text{to }\left\{  \text{non-Catalan LPs from }\left(  a,b\right)  \text{
to }\left(  d-1,c+1\right)  \right\}  ,
\end{align*}
which sends each $\mathbf{v}$ to $\mathbf{v}^{\prime}$.

I claim that this map is a bijection. Indeed, its inverse is given by the same
rule: It, too, sends each $\mathbf{v}$ to $\mathbf{v}^{\prime}$. Why? Consider
any non-Catalan LP $\mathbf{v}=\left(  v_{0},v_{1},\ldots,v_{k}\right)  $
starting at $\left(  a,b\right)  $. As we have seen, the first illegal vertex
of $\mathbf{v}^{\prime}$ is precisely the first illegal vertex of $\mathbf{v}%
$. Let $v_{i}$ be this first illegal vertex. As we recall, $\mathbf{v}%
^{\prime}$ is obtained from $\mathbf{v}$ by replacing the last $k-i$ steps by
their transposes (while the first $i$ steps stay unchanged). Since $v_{i}$ is
the first illegal vertex of $\mathbf{v}^{\prime}$ as well, we see likewise
that $\mathbf{v}^{\prime\prime}$ is obtained from $\mathbf{v}^{\prime}$ by
replacing the last $k-i$ steps by their transposes (while the first $i$ steps
stay unchanged). Thus, as we pass from $\mathbf{v}$ to $\mathbf{v}^{\prime}$
and then further to $\mathbf{v}^{\prime\prime}$, the last $k-i$ steps get
replaced by their transposes \textbf{twice} in succession. Since the transpose
of the transpose of a step is the same step, this twofold replacement ends up
returning them to their original values. Hence, $\mathbf{v}^{\prime\prime}$
has the same steps as $\mathbf{v}$. Therefore, $\mathbf{v}^{\prime\prime
}=\mathbf{v}$ (since $\mathbf{v}^{\prime\prime}$ and $\mathbf{v}$ both start
at $\left(  a,b\right)  $).

Forget that we fixed $\mathbf{v}$. We thus have shown that $\mathbf{v}%
^{\prime\prime}=\mathbf{v}$ for each non-Catalan LP $\mathbf{v}=\left(
v_{0},v_{1},\ldots,v_{k}\right)  $ starting at $\left(  a,b\right)  $. Hence,
the map
\begin{align*}
&  \text{from }\left\{  \text{non-Catalan LPs from }\left(  a,b\right)  \text{
to }\left(  c,d\right)  \right\} \\
&  \text{to }\left\{  \text{non-Catalan LPs from }\left(  a,b\right)  \text{
to }\left(  d-1,c+1\right)  \right\}
\end{align*}
that sends each $\mathbf{v}$ to $\mathbf{v}^{\prime}$ has an inverse, and this
inverse is given by the same rule (viz., sending $\mathbf{v}$ to
$\mathbf{v}^{\prime}$). Therefore, this map is a bijection. By the bijection
principle, we thus obtain%
\begin{align*}
&  \left(  \text{\# of non-Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  c,d\right)  \right) \\
&  =\left(  \text{\# of non-Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  d-1,c+1\right)  \right)  .
\end{align*}


However, \textbf{all} LPs from $\left(  a,b\right)  $ to $\left(
d-1,c+1\right)  $ are non-Catalan, since their ending point $\left(
d-1,c+1\right)  $ does not satisfy $d-1\geq c+1$ (because $c+1>c\geq d-1$) and
therefore cannot lie on any Catalan LP. Thus,%
\begin{align*}
&  \left(  \text{\# of non-Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  d-1,c+1\right)  \right) \\
&  =\left(  \text{\# of LPs from }\left(  a,b\right)  \text{ to }\left(
d-1,c+1\right)  \right) \\
&  =\dbinom{\left(  d-1\right)  -a+\left(  c+1\right)  -b}{\left(  d-1\right)
-a}\\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{by (\ref{eq.prop.lps.num.2}) (applied to }d-1\text{ and }c+1\text{
instead of }c\text{ and }d\text{),}\\
\text{since }\left(  d-1\right)  +\left(  c+1\right)  =c+d\geq a+b
\end{array}
\right) \\
&  =\dbinom{c-a+d-b}{d-a-1}\ \ \ \ \ \ \ \ \ \ \left(  \text{by
straightforward simplifications}\right)  .
\end{align*}
Hence,%
\begin{align*}
&  \left(  \text{\# of non-Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  c,d\right)  \right) \\
&  =\left(  \text{\# of non-Catalan LPs from }\left(  a,b\right)  \text{ to
}\left(  d-1,c+1\right)  \right)  =\dbinom{c-a+d-b}{d-a-1}.
\end{align*}
This proves (\ref{pf.thm.lps.Lnm.formulas.c.goal}), thus completing our proof
of Theorem \ref{thm.lps.catabcd}.
\end{proof}

From Theorem \ref{thm.lps.catabcd}, we can easily derive parts \textbf{(c)},
\textbf{(d)} and \textbf{(e)} of Theorem \ref{thm.lps.Lnm.formulas}:

\begin{proof}
[Proof of Theorem \ref{thm.lps.Lnm.formulas} parts \textbf{(c)}, \textbf{(d)}
and \textbf{(e)} (sketched).]\textbf{(c)}. Let $n\in\mathbb{N}$ and
$m\in\mathbb{N}$ satisfy $n\geq m-1$. Then, the definition of $L_{n,m}$ yields%
\begin{align*}
L_{n,m}  &  =\left(  \text{\# of Catalan LPs from }\left(  0,0\right)  \text{
to }\left(  n,m\right)  \right) \\
&  =\dbinom{n-0+m-0}{n-0}-\dbinom{n-0+m-0}{m-0-1}\\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{by Theorem \ref{thm.lps.catabcd},}\\
\text{applied to }a=0\text{, }b=0\text{, }c=n\text{ and }d=m
\end{array}
\right) \\
&  =\underbrace{\dbinom{n+m}{n}}_{\substack{=\dbinom{n+m}{\left(  n+m\right)
-n}\\\text{(by the symmetry of BCs}\\\text{(Lecture 6, Theorem 1.3.9))}%
}}-\dbinom{n+m}{m-1}=\dbinom{n+m}{\left(  n+m\right)  -n}-\dbinom{n+m}{m-1}\\
&  =\dbinom{n+m}{m}-\dbinom{n+m}{m-1}.
\end{align*}
This proves Theorem \ref{thm.lps.Lnm.formulas} \textbf{(c)}.\medskip

\textbf{(d)} Let $n\in\mathbb{N}$ and $m\in\mathbb{N}$ satisfy $n\geq m-1$. It
is easy to see that
\begin{equation}
\dbinom{n+m}{m-1}=\dfrac{m}{n+1}\dbinom{n+m}{m}.
\label{pf.thm.lps.Lnm.formulas.d.1}%
\end{equation}
(Indeed, this follows easily from the definition of binomial
coefficients\footnote{The case $m=0$ needs to be considered separately, but
this case is trivial.}.) Now, Theorem \ref{thm.lps.Lnm.formulas} \textbf{(c)}
yields%
\begin{align*}
L_{n,m}  &  =\dbinom{n+m}{m}-\dbinom{n+m}{m-1}\\
&  =\dbinom{n+m}{m}-\dfrac{m}{n+1}\dbinom{n+m}{m}\ \ \ \ \ \ \ \ \ \ \left(
\text{by (\ref{pf.thm.lps.Lnm.formulas.d.1})}\right) \\
&  =\dfrac{n+1-m}{n+1}\dbinom{n+m}{m}.
\end{align*}
Thus, Theorem \ref{thm.lps.Lnm.formulas} \textbf{(d)} follows. \medskip

\textbf{(e)} Let $n\in\mathbb{N}$. Applying Theorem \ref{thm.lps.Lnm.formulas}
\textbf{(d)} to $m=n$, we obtain%
\[
L_{n,n}=\dfrac{n+1-n}{n+1}\dbinom{n+n}{n}=\dfrac{1}{n+1}\dbinom{2n}{n}.
\]
Thus Theorem \ref{thm.lps.Lnm.formulas} \textbf{(e)}.
\end{proof}

\subsection{Catalan numbers}

Using parts \textbf{(d)} and \textbf{(e)} of Theorem
\ref{thm.lps.Lnm.formulas}, we can make the following definition:

\begin{definition}
\label{def.catalan.cat}For any $n\in\mathbb{N}$, the number%
\[
L_{n,n}=\dfrac{1}{n+1}\dbinom{2n}{n}=\dbinom{2n}{n}-\dbinom{2n}{n-1}%
\]
is called the $n$\textbf{-th Catalan number}, and is denoted by $C_{n}$.
\end{definition}

At least two books (\cite{Roman15} and \cite{Stanle15}) have been written
about \href{https://en.wikipedia.org/wiki/Catalan_number}{these numbers}, and
their history involves some of the most famous mathematicians of the last 4
centuries (including Euler, Goldbach and Cayley; see \cite{Pak15} for a
survey\footnote{Drew Armstrong's talk slides
\url{https://www.math.miami.edu/~armstrong/Talks/Story_of_Catalan.pdf} give a
quick overview.
\par
Yes, Euler's work predates Catalan's by almost 90 years. But you wouldn't want
to call them \textquotedblleft Euler numbers\textquotedblright, would you?}).
By now, they have found uses all over mathematics. We will soon see some of
their appearances\footnote{See also Richard Stanley's talk slides
\url{https://math.mit.edu/~rstan/transparencies/china.pdf} .}. First, let us
give a table of the first $10$ Catalan numbers:%
\[%
\begin{tabular}
[c]{|c||c|c|c|c|c|c|c|c|c|c|c}\hline
$n$ & $0$ & $1$ & $2$ & $3$ & $4$ & $5$ & $6$ & $7$ & $8$ & $9$ &
$\ \ \ \ \ \ \cdots\ \ \ \ \ \ $\\\hline
$C_{n}$ & $1$ & $1$ & $2$ & $5$ & $14$ & $42$ & $132$ & $429$ & $1430$ &
$4862$ & $\ \ \ \ \ \ \cdots\ \ \ \ \ \ $\\\hline
\end{tabular}
\ \ \ \ \ \ \ \ \ .
\]


Apart from their explicit definition, the Catalan numbers satisfy a recursion:

\begin{theorem}
[Segner's recurrence]\label{thm.catalan.rec}For any integer $n>0$, we have%
\[
C_{n}=\sum_{k=1}^{n}C_{k-1}C_{n-k}.
\]

\end{theorem}

\begin{proof}
[Proof sketch.]Let $n>0$ be an integer. Consider the Catalan LPs from $\left(
0,0\right)  $ to $\left(  n,n\right)  $. If $\mathbf{v}$ is such an LP, then
we define the \textbf{first return} of $\mathbf{v}$ to be the smallest
$k\in\left[  n\right]  $ satisfying $\left(  k,k\right)  \in\mathbf{v}$. (This
is always well-defined, since $\left(  n,n\right)  \in\mathbf{v}$ by
definition. Note that $k$ cannot be $0$, since $k$ should be positive. The
word \textquotedblleft first return\textquotedblright\ is short for
\textquotedblleft first return to the diagonal $x=y$\textquotedblright.)

For example, if $n=7$, then the Catalan LP shown in%
\begin{equation}%
%TCIMACRO{\TeXButton{tikz catalan path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.2, -0.2) -- (7.2, 7.2) -- (7.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (7.2, 7.2);
%\draw[line width=2pt,-stealth, red] (0, 0) -- (1, 0);
%\draw
%[line width=2pt,-stealth, black] (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) -- (3, 2);
%\draw[line width=2pt,-stealth, green!50!black] (3, 2) -- (3, 3);
%\draw
%[line width=2pt,-stealth, blue] (3, 3) edge (4, 3) (4, 3) edge (4, 4) (4, 4) edge (5, 4) (5, 4) edge (6, 4) (6, 4) edge (6, 5) (6, 5) edge (7, 5) (7, 5) edge (7, 6) (7, 6) -- (7, 7);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (7, 7) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(n, n\right)$}};
%\draw[fill=blue] (3, 3) circle (0.1) node[above left] {\textcolor{red}%
%{$\left(k, k\right)$}};
%\end{tikzpicture}} }%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.2, -0.2) -- (7.2, 7.2) -- (7.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (7.2, 7.2);
\draw[line width=2pt,-stealth, red] (0, 0) -- (1, 0);
\draw
[line width=2pt,-stealth, black] (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) -- (3, 2);
\draw[line width=2pt,-stealth, green!50!black] (3, 2) -- (3, 3);
\draw
[line width=2pt,-stealth, blue] (3, 3) edge (4, 3) (4, 3) edge (4, 4) (4, 4) edge (5, 4) (5, 4) edge (6, 4) (6, 4) edge (6, 5) (6, 5) edge (7, 5) (7, 5) edge (7, 6) (7, 6) -- (7, 7);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (7, 7) circle (0.1) node[above right] {\textcolor
{blue}{$\left(n, n\right)$}};
\draw[fill=blue] (3, 3) circle (0.1) node[above left] {\textcolor{red}%
{$\left(k, k\right)$}};
\end{tikzpicture}
%EndExpansion
\label{pf.thm.catalan.rec.exa}%
\end{equation}
has first return $3$ (since it contains the point $\left(  3,3\right)  $ but
neither $\left(  1,1\right)  $ nor $\left(  2,2\right)  $). (The colors of the
steps will be explained further below.)

Now, we claim the following:

\begin{statement}
\textit{Claim 1:} For each $k\in\left[  n\right]  $, we have%
\begin{align*}
&  \left(  \text{\# of Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  n,n\right)  \text{ with first return }k\right) \\
&  =C_{k-1}C_{n-k}.
\end{align*}

\end{statement}

Once Claim 1 is proved, Theorem \ref{thm.catalan.rec} will easily follow:%
\begin{align*}
C_{n}  &  =L_{n,n}\ \ \ \ \ \ \ \ \ \ \left(  \text{by the definition of
}C_{n}\right) \\
&  =\left(  \text{\# of Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  n,n\right)  \right)  \ \ \ \ \ \ \ \ \ \ \left(  \text{by the
definition of }L_{n,n}\right) \\
&  =\sum_{k=1}^{n}\underbrace{\left(  \text{\# of Catalan LPs from }\left(
0,0\right)  \text{ to }\left(  n,n\right)  \text{ with first return }k\right)
}_{\substack{=C_{k-1}C_{n-k}\\\text{(by Claim 1)}}}\\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(  \text{by the sum
rule}\right) \\
&  =\sum_{k=1}^{n}C_{k-1}C_{n-k}.
\end{align*}
Thus, it remains to prove Claim 1.

\textit{Proof of Claim 1:} Let $\mathbf{v}$ be a Catalan LP from $\left(
0,0\right)  $ to $\left(  n,n\right)  $ with first return $k$. What can we say
about it?

\begin{enumerate}
\item No point of the form $\left(  i,i\right)  $ with $0<i<k$ can lie on
$\mathbf{v}$ (since $k$ is the \textbf{first} return of $\mathbf{v}$).

\item The first step of $\mathbf{v}$ must be a right-step, leading to $\left(
1,0\right)  $. (Indeed, the only other option would be an up-step leading to
$\left(  0,1\right)  $, but then $\mathbf{v}$ would not be Catalan, since
$0<1$.) In the example (\ref{pf.thm.catalan.rec.exa}), this right-step has
been painted red.

\item The LP $\mathbf{v}$ must contain $\left(  k,k\right)  $ (since $k$ is
its first return), and thus must reach $\left(  k,k\right)  $ after $2k$ steps
(namely, $k$ up-steps and $k$ right-steps).

\item The LP $\mathbf{v}$ must arrive at $\left(  k,k\right)  $ either by an
up-step or by a right-step. However, if $\mathbf{v}$ would arrive at $\left(
k,k\right)  $ by a right-step, then the point on $\mathbf{v}$ preceding
$\left(  k,k\right)  $ would be $\left(  k-1,k\right)  $, which is impossible
(since $\mathbf{v}$ is Catalan and thus cannot contain $\left(  k-1,k\right)
$). Hence, $\mathbf{v}$ must arrive at $\left(  k,k\right)  $ by an up-step,
coming from the point $\left(  k,k-1\right)  $. This up-step must be the
$\left(  2k\right)  $-th step of $\mathbf{v}$ (since $\mathbf{v}$ reaches
$\left(  k,k\right)  $ after $2k$ steps). In the example
(\ref{pf.thm.catalan.rec.exa}), this up-step has been painted green.

\item So we know that the first step of $\mathbf{v}$ goes from $\left(
0,0\right)  $ to $\left(  1,0\right)  $, whereas the $\left(  2k\right)  $-th
step of $\mathbf{v}$ goes from $\left(  k,k-1\right)  $ to $\left(
k,k\right)  $. The $2k-2$ steps between these two steps must therefore form a
LP from $\left(  1,0\right)  $ to $\left(  k,k-1\right)  $. Let us denote this
LP by $\mathbf{v}^{\prime}$. (In the example (\ref{pf.thm.catalan.rec.exa}),
this LP $\mathbf{v}^{\prime}$ has been painted black.) Not only does this LP
$\mathbf{v}^{\prime}$ never stray above the diagonal with equation $x=y$
(since it is a piece of the LP $\mathbf{v}$, which is Catalan), but it also
never touches this diagonal (i.e., it contains no point of the form $\left(
i,i\right)  $), since no point of the form $\left(  i,i\right)  $ with $0<i<k$
can lie on $\mathbf{v}$. As a consequence, all points on this LP
$\mathbf{v}^{\prime}$ have the form $\left(  x,y\right)  $ with $x>y$ (not
only $x\geq y$), that is, with $x-1\geq y$. Hence, if we shift this LP
$\mathbf{v}^{\prime}$ to the left by $1$ (that is, if we replace each point
$\left(  x,y\right)  $ on $\mathbf{v}^{\prime}$ by $\left(  x-1,y\right)  $),
then we obtain a Catalan LP from $\left(  0,0\right)  $ to $\left(
k-1,k-1\right)  $. Let us denote this latter Catalan LP by $\mathbf{v}%
^{\prime\prime}$.

\item Now, let $\mathbf{v}^{\ast}$ be the part of the LP $\mathbf{v}$ after
the point $\left(  k,k\right)  $. (In the example
(\ref{pf.thm.catalan.rec.exa}), this LP $\mathbf{v}^{\ast}$ has been painted
blue.) This $\mathbf{v}^{\ast}$ is a Catalan LP from $\left(  k,k\right)  $ to
$\left(  n,n\right)  $. If we shift this LP $\mathbf{v}^{\ast}$ to the left by
$k$ and downwards by $k$ (that is, if we replace each point $\left(
x,y\right)  $ on $\mathbf{v}^{\ast}$ by $\left(  x-k,y-k\right)  $), then we
obtain a Catalan LP from $\left(  0,0\right)  $ to $\left(  n-k,n-k\right)  $.
We denote this latter LP by $\mathbf{v}^{\ast\ast}$.
\end{enumerate}

Thus, we have decomposed our LP $\mathbf{v}$ into

\begin{itemize}
\item a single right-step that takes us from $\left(  0,0\right)  $ to
$\left(  1,0\right)  $ (painted red in (\ref{pf.thm.catalan.rec.exa}));
followed by

\item an LP $\mathbf{v}^{\prime}$ from $\left(  1,0\right)  $ to $\left(
k,k-1\right)  $ (painted black in (\ref{pf.thm.catalan.rec.exa})) which, if we
shift it to the left by $1$, becomes a Catalan LP $\mathbf{v}^{\prime\prime}$
from $\left(  0,0\right)  $ to $\left(  k-1,k-1\right)  $; followed by

\item a single up-step that takes us from $\left(  k,k-1\right)  $ to $\left(
k,k\right)  $ (painted green in (\ref{pf.thm.catalan.rec.exa})); followed by

\item an LP $\mathbf{v}^{\ast}$ from $\left(  k,k\right)  $ to $\left(
n,n\right)  $ (painted blue in (\ref{pf.thm.catalan.rec.exa})) which, if we
shift it to the left by $k$ and downwards by $k$, becomes a Catalan LP
$\mathbf{v}^{\ast\ast}$ from $\left(  0,0\right)  $ to $\left(
n-k,n-k\right)  $.
\end{itemize}

This decomposition is defined for every $\mathbf{v}$. Hence, let us forget
that we fixed $\mathbf{v}$. We thus obtained a map%
\begin{align*}
&  \text{from }\left\{  \text{Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  n,n\right)  \text{ with first return }k\right\} \\
&  \text{to }\left\{  \text{Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  k-1,k-1\right)  \right\} \\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \times\left\{  \text{Catalan LPs
from }\left(  0,0\right)  \text{ to }\left(  n-k,n-k\right)  \right\}  ,
\end{align*}
which sends every Catalan LP $\mathbf{v}$ to the pair $\left(  \mathbf{v}%
^{\prime\prime},\mathbf{v}^{\ast\ast}\right)  $. This map is injective (since
we can reconstruct $\mathbf{v}$ from $\mathbf{v}^{\prime\prime}$ and
$\mathbf{v}^{\ast\ast}$) and surjective (check this!). Thus, it is a
bijection. Hence, the bijection principle (together with the product rule)
yields%
\begin{align*}
&  \left(  \text{\# of Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  n,n\right)  \text{ with first return }k\right) \\
&  =\underbrace{\left(  \text{\# of Catalan LPs from }\left(  0,0\right)
\text{ to }\left(  k-1,k-1\right)  \right)  }_{\substack{=L_{k-1,k-1}%
\\\text{(by the definition of }L_{k-1,k-1}\text{)}}}\\
&  \ \ \ \ \ \ \ \ \ \ \cdot\underbrace{\left(  \text{\# of Catalan LPs from
}\left(  0,0\right)  \text{ to }\left(  n-k,n-k\right)  \right)
}_{\substack{=L_{n-k,n-k}\\\text{(by the definition of }L_{n-k,n-k}\text{)}%
}}\\
&  =\underbrace{L_{k-1,k-1}}_{=C_{k-1}}\cdot\underbrace{L_{n-k,n-k}}%
_{=C_{n-k}}=C_{k-1}C_{n-k}.
\end{align*}
This proves Claim 1, thus completing the proof of Theorem
\ref{thm.catalan.rec}.
\end{proof}

\bigskip

As mentioned above, the Catalan numbers $C_{n}$ tend to appear in surprisingly
many different places in mathematics. Stanley's book \cite{Stanle15} lists
$214$ different counting problems whose answer is $C_{k}$ for some $k$. Here
are just a few of them:

\begin{itemize}
\item Let $n\in\mathbb{N}$. A permutation $\sigma\in S_{n}$ is said to be
\textbf{123-avoiding} if there exist no three elements $i<j<k$ of $\left[
n\right]  $ satisfying $\sigma\left(  i\right)  <\sigma\left(  j\right)
<\sigma\left(  k\right)  $ (that is, if the OLN\footnote{Recall:
\textquotedblleft OLN\textquotedblright\ is shorthand for \textquotedblleft
one-line notation\textquotedblright.} of $\sigma$ has no increasing
subsequence\footnote{Keep in mind that a subsequence doesn't have to be
contiguous. For example, $\left(  2,4,5\right)  $ is a subsequence of $\left(
2,1,6,3,4,5\right)  $.} of length $3$).

The \# of all 123-avoiding permutations $\sigma\in S_{n}$ is the Catalan
number $C_{n}$. (See \cite[Theorem 4.7]{Bona22} for a proof of this fact.)

\item Let $n\in\mathbb{N}$. A permutation $\sigma\in S_{n}$ is said to be
\textbf{132-avoiding} if there exist no three elements $i<j<k$ of $\left[
n\right]  $ satisfying $\sigma\left(  i\right)  <\sigma\left(  k\right)
<\sigma\left(  j\right)  $. (The name \textquotedblleft%
132-avoiding\textquotedblright\ is of course referring to the fact three such
elements lead to a subsequence of the OLN of $\sigma$ that \textquotedblleft
looks like\textquotedblright\ the triple $\left(  1,3,2\right)  $, in the
sense that its first entry is its smallest entry, its second entry is its
largest one, and its third entry is its mid-sized one.)

The \# of all 132-avoiding permutations $\sigma\in S_{n}$ is the Catalan
number $C_{n}$. (Yes, this is the same answer as for 123-avoiding
permutations! No really simple reason for this \textquotedblleft
coincidence\textquotedblright\ is known, although bijections between the
123-avoiding permutations and the 132-avoiding permutations have been found.
See \cite[proof of Lemma 4.4]{Bona22} for such a bijection.)

\item Let $n\in\mathbb{N}$. A permutation $\sigma\in S_{n}$ is said to be
\textbf{213-avoiding} if there exist no three elements $i<j<k$ of $\left[
n\right]  $ satisfying $\sigma\left(  j\right)  <\sigma\left(  i\right)
<\sigma\left(  k\right)  $. (At this point, the origin of this name should be clear.)

The \# of all 213-avoiding permutations $\sigma\in S_{n}$ is, once again,
$C_{n}$. (This fact, just like the previous two and the following three, is
proved in \cite[\S 4.2]{Bona22}.)

\item Let $n\in\mathbb{N}$. A permutation $\sigma\in S_{n}$ is said to be
\textbf{231-avoiding} if there exist no three elements $i<j<k$ of $\left[
n\right]  $ satisfying $\sigma\left(  k\right)  <\sigma\left(  i\right)
<\sigma\left(  j\right)  $.

The \# of all 231-avoiding permutations $\sigma\in S_{n}$ is (you guessed it)
$C_{n}$. (This is not hard to prove\footnote{Here is the idea of the proof:
\par
For any $n\in\mathbb{N}$, let $q_{n}$ denote the \# of all 231-avoiding
permutations $\sigma\in S_{n}$.
\par
Fix $n>0$. Also, fix $k\in\left[  n\right]  $. Consider some 231-avoiding
permutation $\sigma\in S_{n}$ with $\sigma\left(  k\right)  =n$. Thus, the
entry $n$ appears in the $k$-th position of the OLN of $\sigma$. The entries
in the first $k-1$ positions of this OLN will thus be called the
\textbf{pre-}$n$ \textbf{entries} of $\sigma$, whereas the entries in the last
$n-k$ positions will be called the \textbf{post-}$n$ \textbf{entries} of
$\sigma$. Since $\sigma$ is 231-avoiding, each of the pre-$n$ entries must be
smaller than each of the post-$n$ entries (why?). Hence, the pre-$n$ entries
must be $1,2,\ldots,k-1$ in some order (why?), whereas the post-$n$ entries
must be $k,k+1,\ldots,n-1$ in some order (why?). Moreover, the orders must
themselves be 231-avoiding. More precisely, the pre-$n$ entries form the OLN
of a 231-avoiding permutation of $\left[  k-1\right]  $, whereas the post-$n$
entries (once $k-1$ has been subtracted from them) form the OLN of a
231-avoiding permutation of $\left[  n-k\right]  $. Let us denote these two
permutations by $\sigma^{\prime}$ and $\sigma^{\prime\prime}$.
\par
Forget that we fixed $\sigma$. Thus, for each 231-avoiding permutation
$\sigma\in S_{n}$ with $\sigma\left(  k\right)  =n$, we have constructed a
231-avoiding permutation $\sigma^{\prime}\in S_{k-1}$ (whose OLN consists of
the pre-$n$ entries of $\sigma$) and a 231-avoiding permutation $\sigma
^{\prime\prime}\in S_{n-k}$ (whose OLN consists of the post-$n$ entries of
$\sigma$, each decreased by $k-1$). This results in a map%
\begin{align*}
&  \text{from }\left\{  \text{231-avoiding permutations }\sigma\in S_{n}\text{
with }\sigma\left(  k\right)  =n\right\} \\
&  \text{to }\left\{  \text{231-avoiding permutations in }S_{k-1}\right\}
\times\left\{  \text{231-avoiding permutations in }S_{n-k}\right\}  ,
\end{align*}
which sends each $\sigma$ to the pair $\left(  \sigma^{\prime},\sigma
^{\prime\prime}\right)  $. This map is easily seen to be a bijection (why?
surjectivity needs a bit of thought), and thus the bijection principle (and
the product rule) yields%
\begin{align*}
&  \left(  \text{\# of 231-avoiding permutations }\sigma\in S_{n}\text{ with
}\sigma\left(  k\right)  =n\right) \\
&  =\underbrace{\left(  \text{\# of 231-avoiding permutations in }%
S_{k-1}\right)  }_{=q_{k-1}}\cdot\underbrace{\left(  \text{\# of 231-avoiding
permutations in }S_{n-k}\right)  }_{=q_{n-k}}\\
&  =q_{k-1}q_{n-k}.
\end{align*}
\par
Now, forget that we fixed $k$. We have%
\begin{align*}
q_{n}  &  =\left(  \text{\# of 231-avoiding permutations }\sigma\in
S_{n}\right) \\
&  =\sum_{k=1}^{n}\underbrace{\left(  \text{\# of 231-avoiding permutations
}\sigma\in S_{n}\text{ with }\sigma\left(  k\right)  =n\right)  }%
_{\substack{=q_{k-1}q_{n-k}\\\text{(as we just proved)}}}\\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{by the sum rule, since }\sigma^{-1}\left(  n\right)  \text{ is uniquely
determined}\\
\text{for each }\sigma\in S_{n}%
\end{array}
\right) \\
&  =\sum_{k=1}^{n}q_{k-1}q_{n-k}.
\end{align*}
\par
This is exactly the same recurrent equation as Theorem \ref{thm.catalan.rec}
for the Catalan numbers $C_{n}$. Since we furthermore have $q_{0}=C_{0}$, we
thus conclude that $q_{n}=C_{n}$ holds for each $n\in\mathbb{N}$, qed.}.)

\item Let $n\in\mathbb{N}$. A permutation $\sigma\in S_{n}$ is said to be
\textbf{312-avoiding} if there exist no three elements $i<j<k$ of $\left[
n\right]  $ satisfying $\sigma\left(  j\right)  <\sigma\left(  k\right)
<\sigma\left(  i\right)  $.

The \# of all 312-avoiding permutations $\sigma\in S_{n}$ is $C_{n}$ (who
could have known?).

\item Let $n\in\mathbb{N}$. A permutation $\sigma\in S_{n}$ is said to be
\textbf{321-avoiding} if there exist no three elements $i<j<k$ of $\left[
n\right]  $ satisfying $\sigma\left(  k\right)  <\sigma\left(  j\right)
<\sigma\left(  i\right)  $.

The \# of all 321-avoiding permutations $\sigma\in S_{n}$ is $C_{n}$. (And
this time, you should really not be surprised: There is a simple bijection
between the 123-avoiding permutations and the 321-avoiding ones. Do you see it?)

At this point, it should be mentioned that there are also 1234-avoiding
permutations, and 1324-avoiding ones, and 51243-avoiding ones, and so on; more
generally, for any fixed permutation $\tau\in S_{m}$ (with arbitrary $m$), we
can define the notion of a \textquotedblleft$\tau$-avoiding
permutation\textquotedblright. These so-called \textquotedblleft pattern
avoidance classes\textquotedblright\ (along with their intersections) are the
subject of an active area of research that has
\href{https://permutationpatterns.com/}{a yearly conference} devoted to it. An
interested reader can find more on
\href{https://en.wikipedia.org/wiki/Permutation_pattern}{the Wikipedia page
for \textquotedblleft pattern avoidance\textquotedblright} and explore Bridget
Tenner's \href{https://math.depaul.edu/~bridget/patterns.html}{Database of
Permutation Pattern Avoidance}; much more can be learned from books like
\cite[Chapters 4--5]{Bona22} and \cite{Kitaev11}.

One disappointment, though: In general, the \# of all 1234-avoiding
permutations does not equal the \# of 1324-avoiding ones\footnote{Indeed, the
former number is smaller when $n\geq7$. This is proved in \cite[Theorem
4.29]{Bona22}.} (and neither of them equals $C_{n}$).

\item Fix $n\in\mathbb{N}$. Consider \textquotedblleft words\textquotedblright%
\ consisting of $n$ opening parentheses and $n$ closing parentheses.

For example, for $n=5$, one such word is \textquotedblleft$))()(()()($%
\textquotedblright.

Such a word is said to be \textbf{legal} if its parentheses can be matched
(i.e., we can match each opening parenthesis to a closing parenthesis that
lies somewhere to its right). For example, the word \textquotedblleft%
$(()(()))$\textquotedblright\ is legal, whereas the word \textquotedblleft%
$())((())$\textquotedblright\ is not.

How many legal words with $n$ opening and $n$ closing parentheses are there?
The answer is $C_{n}$.

This is not actually surprising if you think about it. Indeed, the step
sequence of a Catalan LP from $\left(  0,0\right)  $ to $\left(  n,n\right)  $
becomes a legal word if we replace each $R$ by an opening parenthesis and each
$U$ by a closing parenthesis (why?). It is not hard to see that this is a
bijection, and therefore the \# of legal words equals the \# of Catalan LPs
from $\left(  0,0\right)  $ to $\left(  n,n\right)  $, which we know to be
$C_{n}$. (See \url{https://math.stackexchange.com/questions/2991347} for details.)

\item Consider a sum of $4$ numbers:%
\[
a+b+c+d.
\]
How many ways are there to \textbf{fully parenthesize} it -- i.e., to put
parentheses around some of the numbers so that we never have to add more than
two numbers at the same time? A bit of experimentation shows that there are
$5$ ways:%
\begin{align*}
&  \left(  \left(  a+b\right)  +c\right)  +d,\ \ \ \ \ \ \ \ \ \ \left(
a+\left(  b+c\right)  \right)  +d,\\
&  \left(  a+b\right)  +\left(  c+d\right)  ,\ \ \ \ \ \ \ \ \ \ a+\left(
\left(  b+c\right)  +d\right)  ,\ \ \ \ \ \ \ \ \ \ a+\left(  b+\left(
c+d\right)  \right)  .
\end{align*}
(We are not allowing the numbers to be permuted.) Similarly, for a sum of $3$
numbers, there are $2$ ways (namely, $\left(  a+b\right)  +c$ and $a+\left(
b+c\right)  $). Similarly, for a sum of $5$ numbers, there are $14$ ways.

How many ways are there for a sum of $n$ numbers? The answer turns out to be
the Catalan number $C_{n-1}$. (See \cite{Reiner05} or \cite{Singma78} or
\cite[Theorem 1.5.1 (v)]{Stanle15} for various proofs, up to minor notational differences.)

\item Fix an integer $n\geq3$ and a convex $n$-gon $G_{n}$.

How many ways are there to triangulate $G_{n}$ -- i.e., to subdivide $G_{n}$
into triangles? Of course, the answer is \textquotedblleft infinitely
many\textquotedblright, since we can keep adding new internal vertices and
thus obtain new triangulations each time.

However, we can ask a better question: How many ways are there to triangulate
$G_{n}$ \textbf{without} introducing new vertices? For example, for $n=6$,
there are $14$ such triangulations:%
\begin{align*}
&
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (0:1) -- (2*360/6:1);
%\draw[blue] (0:1) -- (3*360/6:1);
%\draw[blue] (0:1) -- (4*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (0:1) -- (2*360/6:1);
\draw[blue] (0:1) -- (3*360/6:1);
\draw[blue] (0:1) -- (4*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (0:1) -- (2*360/6:1);
%\draw[blue] (0:1) -- (3*360/6:1);
%\draw[blue] (3*360/6:1) -- (5*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (0:1) -- (2*360/6:1);
\draw[blue] (0:1) -- (3*360/6:1);
\draw[blue] (3*360/6:1) -- (5*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (0:1) -- (2*360/6:1);
%\draw[blue] (2*360/6:1) -- (4*360/6:1);
%\draw[blue] (0:1) -- (4*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (0:1) -- (2*360/6:1);
\draw[blue] (2*360/6:1) -- (4*360/6:1);
\draw[blue] (0:1) -- (4*360/6:1);
\end{tikzpicture}%
%EndExpansion
\\
&
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (360/6:1) -- (3*360/6:1);
%\draw[blue] (0:1) -- (3*360/6:1);
%\draw[blue] (0:1) -- (4*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (360/6:1) -- (3*360/6:1);
\draw[blue] (0:1) -- (3*360/6:1);
\draw[blue] (0:1) -- (4*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (360/6:1) -- (4*360/6:1);
%\draw[blue] (360/6:1) -- (5*360/6:1);
%\draw[blue] (360/6:1) -- (3*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (360/6:1) -- (4*360/6:1);
\draw[blue] (360/6:1) -- (5*360/6:1);
\draw[blue] (360/6:1) -- (3*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (360/6:1) -- (4*360/6:1);
%\draw[blue] (0:1) -- (4*360/6:1);
%\draw[blue] (360/6:1) -- (3*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (360/6:1) -- (4*360/6:1);
\draw[blue] (0:1) -- (4*360/6:1);
\draw[blue] (360/6:1) -- (3*360/6:1);
\end{tikzpicture}%
%EndExpansion
\\
&
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (3*360/6:1) -- (5*360/6:1);
%\draw[blue] (360/6:1) -- (5*360/6:1);
%\draw[blue] (360/6:1) -- (3*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (3*360/6:1) -- (5*360/6:1);
\draw[blue] (360/6:1) -- (5*360/6:1);
\draw[blue] (360/6:1) -- (3*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (360/6:1) -- (4*360/6:1);
%\draw[blue] (360/6:1) -- (5*360/6:1);
%\draw[blue] (2*360/6:1) -- (4*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (360/6:1) -- (4*360/6:1);
\draw[blue] (360/6:1) -- (5*360/6:1);
\draw[blue] (2*360/6:1) -- (4*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (2*360/6:1) -- (4*360/6:1);
%\draw[blue] (2*360/6:1) -- (5*360/6:1);
%\draw[blue] (2*360/6:1) -- (0*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (2*360/6:1) -- (4*360/6:1);
\draw[blue] (2*360/6:1) -- (5*360/6:1);
\draw[blue] (2*360/6:1) -- (0*360/6:1);
\end{tikzpicture}%
%EndExpansion
\\
&
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (2*360/6:1) -- (4*360/6:1);
%\draw[blue] (2*360/6:1) -- (5*360/6:1);
%\draw[blue] (5*360/6:1) -- (1*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (2*360/6:1) -- (4*360/6:1);
\draw[blue] (2*360/6:1) -- (5*360/6:1);
\draw[blue] (5*360/6:1) -- (1*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (2*360/6:1) -- (5*360/6:1);
%\draw[blue] (2*360/6:1) -- (0*360/6:1);
%\draw[blue] (3*360/6:1) -- (5*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (2*360/6:1) -- (5*360/6:1);
\draw[blue] (2*360/6:1) -- (0*360/6:1);
\draw[blue] (3*360/6:1) -- (5*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (3*360/6:1) -- (5*360/6:1);
%\draw[blue] (3*360/6:1) -- (0*360/6:1);
%\draw[blue] (3*360/6:1) -- (1*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (3*360/6:1) -- (5*360/6:1);
\draw[blue] (3*360/6:1) -- (0*360/6:1);
\draw[blue] (3*360/6:1) -- (1*360/6:1);
\end{tikzpicture}%
%EndExpansion
\\
&
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (4*360/6:1) -- (0*360/6:1);
%\draw[blue] (4*360/6:1) -- (1*360/6:1);
%\draw[blue] (4*360/6:1) -- (2*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (4*360/6:1) -- (0*360/6:1);
\draw[blue] (4*360/6:1) -- (1*360/6:1);
\draw[blue] (4*360/6:1) -- (2*360/6:1);
\end{tikzpicture}%
%EndExpansion
\ \ \ \ \ \ \ \ \ \
%TCIMACRO{\TeXButton{tikz ABCDEF}{\begin{tikzpicture}
%\draw(0:1) node[anchor=west] {$A$}
%-- (360/6:1) node[anchor=south] {$B$}
%-- (2*360/6:1) node[anchor=south east] {$C$}
%-- (3*360/6:1) node[anchor=east] {$D$}
%-- (4*360/6:1) node[anchor=north] {$E$}
%-- (5*360/6:1) node[anchor=north] {$F$}
%-- cycle;
%\draw[blue] (5*360/6:1) -- (1*360/6:1);
%\draw[blue] (5*360/6:1) -- (2*360/6:1);
%\draw[blue] (5*360/6:1) -- (3*360/6:1);
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw(0:1) node[anchor=west] {$A$}
-- (360/6:1) node[anchor=south] {$B$}
-- (2*360/6:1) node[anchor=south east] {$C$}
-- (3*360/6:1) node[anchor=east] {$D$}
-- (4*360/6:1) node[anchor=north] {$E$}
-- (5*360/6:1) node[anchor=north] {$F$}
-- cycle;
\draw[blue] (5*360/6:1) -- (1*360/6:1);
\draw[blue] (5*360/6:1) -- (2*360/6:1);
\draw[blue] (5*360/6:1) -- (3*360/6:1);
\end{tikzpicture}%
%EndExpansion
\end{align*}


For a general $n$, the answer (found by Euler) is $C_{n-2}$. (See
\cite[Theorem 1.5.1 (i)]{Stanle15} for a proof.)

\item Let $n\in\mathbb{N}$. A \textbf{standard Young tableau of shape
}$\left(  n,n\right)  $ (this is just a particular case of a much more general
concept of \textquotedblleft standard Young tableau\textquotedblright) is
defined to be a $2\times n$-matrix $\left(
\begin{array}
[c]{cccc}%
a_{1} & a_{2} & \cdots & a_{n}\\
b_{1} & b_{2} & \cdots & b_{n}%
\end{array}
\right)  $ such that

\begin{itemize}
\item its entries $a_{1},a_{2},\ldots,a_{n},b_{1},b_{2},\ldots,b_{n}$ are the
$2n$ integers $1,2,\ldots,2n$ in some order;

\item its entries strictly increase along each row (i.e., we have $a_{1}%
<a_{2}<\cdots<a_{n}$ and $b_{1}<b_{2}<\cdots<b_{n}$);

\item its entries strictly increase down each column (i.e., we have
$a_{i}<b_{i}$ for each $i\in\left[  n\right]  $).
\end{itemize}

Then, the \# of standard Young tableaux\footnote{This is the plural of
\textquotedblleft tableau\textquotedblright\ (a loanword from French). That
said, you will also find \textquotedblleft tableaus\textquotedblright\ and
\textquotedblleft tableau\textquotedblright\ (as well as the even less
sensible use of \textquotedblleft tableaux\textquotedblright\ for the singular
form) all over the Anglophone literature.} of shape $\left(  n,n\right)  $ is
the Catalan number $C_{n}$. This is due to a fairly simple bijection between
these tableaux and the Catalan LPs from $\left(  0,0\right)  $ to $\left(
n,n\right)  $, which you might enjoy finding\footnote{See \cite[Problem
168]{Stanle15} for the answer.}.
\end{itemize}

More interpretations of Catalan numbers can be found in \cite{Davis16},
\cite{Stanle15} and \cite{Roman15}.

\subsection{$k$-Catalan paths}

\begin{fineprint}
The Catalan LPs are (by definition) the LPs that never stray above the line
with equation $x=y$. We know (from Theorem \ref{thm.lps.catabcd}) how to count
such LPs between any two points $\left(  a,b\right)  $ and $\left(
c,d\right)  $.

What happens if we replace this line by a different line? One of the simplest
options is to replace it by the \textquotedblleft slanted
diagonal\textquotedblright\ $x=ky$ for a given $k\in\mathbb{N}$. This leads to
the following definition:

\begin{definition}
\label{def.lps.kcat}Let $k\in\mathbb{N}$. A LP $\mathbf{v}$ is said to be
$k$\textbf{-Catalan} if each $\left(  x,y\right)  \in\mathbf{v}$ satisfies
$x\geq ky$.
\end{definition}

In other words, a LP $\mathbf{v}$ is $k$-Catalan if and only if it lies
entirely in the halfplane below the straight line given by the equation $x=ky$.

\begin{example}
\label{exa.lps.kcat.1}The following picture shows a $2$-Catalan LP from
$\left(  0,0\right)  $ to $\left(  7,3\right)  $:%
\[%
%TCIMACRO{\TeXButton{tikz k-cat path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.4, -0.2) -- (7.2, 3.6) -- (7.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (7.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (5, 1) (5, 1) edge (5, 2) (5, 2) edge (6, 2) (6, 2) edge (7, 2) (7, 2) -- (7, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (7, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(7, 3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.4, -0.2) -- (7.2, 3.6) -- (7.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (7.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (5, 1) (5, 1) edge (5, 2) (5, 2) edge (6, 2) (6, 2) edge (7, 2) (7, 2) -- (7, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (7, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(7, 3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
(Here, the region shaded cyan is the set of all $\left(  x,y\right)
\in\mathbb{R}^{2}$ satisfying $x\geq ky$; this is the region in which a
$k$-Catalan LP must stay.)

The following LP from $\left(  0,0\right)  $ to $\left(  7,3\right)  $ is
\textbf{not} $2$-Catalan:%
\[%
%TCIMACRO{\TeXButton{tikz non-k-cat path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.4, -0.2) -- (7.2, 3.6) -- (7.2, -0.2) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (7.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (2, 2) (2, 2) edge (3, 2) (3, 2) edge (4, 2) (4, 2) edge (5, 2) (5, 2) edge (6, 2) (6, 2) edge (7, 2) (7, 2) -- (7, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (7, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(7, 3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.4, -0.2) -- (7.2, 3.6) -- (7.2, -0.2) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (7.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (2, 2) (2, 2) edge (3, 2) (3, 2) edge (4, 2) (4, 2) edge (5, 2) (5, 2) edge (6, 2) (6, 2) edge (7, 2) (7, 2) -- (7, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (7, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(7, 3\right)$}};
\end{tikzpicture}%
%EndExpansion
.
\]

\end{example}

Clearly, a LP is $1$-Catalan if and only if it is Catalan. The notion of a
$k$-Catalan LP thus generalizes that of a Catalan LP. The larger $k$ is, the
\textquotedblleft flatter\textquotedblright\ the line with equation $x=ky$ is
(its slope is $\dfrac{1}{k}$, after all), and the more restrictive the concept
of a $k$-Catalan LP becomes, at least if the starting point is $\left(
0,0\right)  $.

Encouraged by Theorem \ref{thm.lps.catabcd}, one might try to find a simple
formula for the \# of $k$-Catalan LPs from a given point $\left(  a,b\right)
$ to another given point $\left(  c,d\right)  $. Unfortunately, such a formula
doesn't seem to exist; the best formulas known involve summation signs (see
\cite[Theorem 10.4.7]{Kratte17}).

However, all is not lost. The particular case in which $\left(  a,b\right)
=\left(  0,0\right)  $ (that is, counting $k$-Catalan LPs that start at
$\left(  0,0\right)  $) still allows for nice formulas. To state them, we
introduce a notation generalizing the $L_{n,m}$ from Definition
\ref{def.lps.Lnm}:

\begin{definition}
\label{def.lps.Lnmk}Let $k\in\mathbb{N}$. If $n,m\in\mathbb{Z}$, then we set%
\[
L_{n,m,k}:=\left(  \text{\# of }k\text{-Catalan LPs from }\left(  0,0\right)
\text{ to }\left(  n,m\right)  \right)  .
\]

\end{definition}

Thus, in particular, $L_{n,m}=L_{n,m,1}$ for every $n,m\in\mathbb{Z}$. Also,
every LP starting at $\left(  0,0\right)  $ is $0$-Catalan, so that we have
$L_{n,m,0}=\dbinom{n+m}{m}$. Now, we can state the formulas for the general case:

\begin{theorem}
\label{thm.lps.Lnmk.formulas}Let $k\in\mathbb{N}$. Then:

\textbf{(a)} We have $L_{n,m,k}=L_{n-1,m,k}+L_{n,m-1,k}$ for any
$n\in\mathbb{Z}$ and $m\in\mathbb{Z}$ satisfying $n\geq km$ and $\left(
n,m\right)  \neq\left(  0,0\right)  $.

\textbf{(b)} If $n\in\mathbb{Z}$ and $m\in\mathbb{Z}$ satisfy $n<km$, then
$L_{n,m,k}=0$.

\textbf{(c)} If $n\in\mathbb{N}$ and $m\in\mathbb{N}$ satisfy $n\geq km-1$,
then%
\[
L_{n,m,k}=\dbinom{n+m}{m}-k\dbinom{n+m}{m-1}.
\]


\textbf{(d)} If $n\in\mathbb{N}$ and $m\in\mathbb{N}$ satisfy $n\geq km-1$,
then%
\[
L_{n,m,k}=\dfrac{n+1-km}{n+1}\dbinom{n+m}{m}.
\]


\textbf{(e)} If $m\in\mathbb{N}$, then%
\[
L_{km,m,k}=\dfrac{1}{km+1}\dbinom{\left(  k+1\right)  m}{m}.
\]

\end{theorem}

\begin{proof}
[Proof idea.]The straightforward inductive proof of Theorem
\ref{thm.lps.Lnm.formulas} in \cite[Exercise 2]{18s-mt2s} can be fairly
straightforwardly generalized from Catalan LPs to $k$-Catalan LPs.

Another proof of Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(d)} can be found
in \cite[Theorem 2]{GouSer03} (although the statement of \cite[Theorem
2]{GouSer03} differs from Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(d)} in
some insubstantial details\footnote{Namely, the LPs $\mathbf{v}$ counted in
\cite[Theorem 2]{GouSer03} are required to satisfy $y\geq kx$ (rather than
$x\geq ky$) for all $\left(  x,y\right)  \in\mathbf{v}$. However, this
difference does not affect their \#, since we can go from them to our
$k$-Catalan LPs by replacing each point $\left(  x,y\right)  $ by $\left(
y,x\right)  $. (Geometrically, this means that they are the reflections of our
$k$-Catalan LPs across the diagonal $y=x$.)}).

Other authors prove equivalent versions of Theorem \ref{thm.lps.Lnmk.formulas}
\textbf{(d)}:

In \cite{Renaul07}, Renault solves a related problem (the so-called
\textquotedblleft\textbf{ballot problem}\textquotedblright) in four different
ways. This problem asks for the \# of LPs $\mathbf{v}$ from $\left(
0,0\right)  $ to $\left(  n,m\right)  $ such that every point $\left(
x,y\right)  \in\mathbf{v}$ other than the starting point $\left(  0,0\right)
$ satisfies the \textbf{strict} inequality $x>ky$. We can call such LPs
\textbf{strictly }$k$\textbf{-Catalan}. The main result of \cite{Renaul07} is
that the \# of strictly $k$-Catalan LPs from $\left(  0,0\right)  $ to
$\left(  n,m\right)  $ is $\dfrac{n-km}{n+m}\dbinom{n+m}{m}$. However, it is
easy to find a bijection
\begin{align*}
&  \text{from }\left\{  \text{strictly }k\text{-Catalan LPs from }\left(
0,0\right)  \text{ to }\left(  n+1,m\right)  \right\} \\
&  \text{to }\left\{  k\text{-Catalan LPs from }\left(  0,0\right)  \text{ to
}\left(  n,m\right)  \right\}
\end{align*}
(indeed, this bijection removes the first step of a strictly $k$-Catalan LP,
and shifts the rest of the LP by $1$ to the left). Thus, the main result of
\cite{Renaul07} (applied to $n+1$ instead of $n$) yields Theorem
\ref{thm.lps.Lnmk.formulas} \textbf{(d)}, which provides four new proofs of
Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(d)}.

In \cite[Theorem 10.4.5]{Kratte17}, Krattenthaler proves an equivalent version
of Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(d)}: Namely, he shows that%
\[
L_{n,m,k}=\dfrac{n+1-km}{n+m+1}\dbinom{n+m+1}{m}.
\]
The equivalence between this and Theorem \ref{thm.lps.Lnmk.formulas}
\textbf{(d)} follows from easy manipulation of BCs.
\end{proof}

The numbers%
\[
L_{km,m,k}=\dfrac{1}{km+1}\dbinom{\left(  k+1\right)  m}{m}%
\]
from Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(e)} are known as the
\textbf{Fuss--Catalan numbers} (see, e.g., \cite[Problem A14]{Stanle15}), and
appear in many of the same contexts as the Catalan numbers (which are their
particular cases for $k=1$: namely, we have $C_{m}=L_{m,m,1}$). For instance,
just as the Catalan number $C_{n}$ counts the decompositions of an $\left(
n+2\right)  $-gon into triangles, the Fuss--Catalan number $L_{km,m,k}$ counts
the decompositions of a $\left(  km+2\right)  $-gon into $\left(  k+2\right)
$-gons. In \cite{HilPed91} (where the $L_{km,m,k}$ are uninventively called
\textquotedblleft generalized $m^{\text{th}}$ Catalan
numbers\textquotedblright), this and some other properties are proved.

\begin{remark}
It appears natural to study the counterpart of $k$-Catalan LPs in which the
inequality $x\geq ky$ has been replaced by the opposite inequality $x\leq ky$.
Thus, we fix an integer $k\in\mathbb{N}$, and we define a $k$%
\textbf{-anti-Catalan LP} to be a LP $\mathbf{v}$ such that each $\left(
x,y\right)  \in\mathbf{v}$ satisfies $x\leq ky$. For example, the following LP
from $\left(  0,0\right)  $ to $\left(  3,3\right)  $ is $2$-anti-Catalan:%
\[%
%TCIMACRO{\TeXButton{tikz k-anticat path}{\begin{tikzpicture}
%\fill
%[cyan!25] (-0.4, -0.2) -- (-0.4, 3.2) -- (3.2, 3.2) -- (3.2, 1.6) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (3.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (0, 1) (0, 1) edge (0, 2) (0, 2) edge (1, 2) (1, 2) edge (2, 2) (2, 2) edge (3, 2) (3, 2) -- (3, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (3, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(3, 3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill
[cyan!25] (-0.4, -0.2) -- (-0.4, 3.2) -- (3.2, 3.2) -- (3.2, 1.6) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (3.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (0, 1) (0, 1) edge (0, 2) (0, 2) edge (1, 2) (1, 2) edge (2, 2) (2, 2) edge (3, 2) (3, 2) -- (3, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (3, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(3, 3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
We define $L_{n,m,k}^{\prime}$ to be the \# of $k$-anti-Catalan LPs from
$\left(  0,0\right)  $ to $\left(  n,m\right)  $. One might now hope for a
nice formula for $L_{n,m,k}^{\prime}$, similar to the formula for $L_{n,m,k}$
given in Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(d)}. However, such a
formula doesn't seem to exist; I am only aware of some formulas that involve
summation signs. (Such formulas can be derived from \cite[Theorem
10.4.7]{Kratte17} or from \cite[Theorem 2]{FreSel01}.)
\end{remark}
\end{fineprint}

\subsection{Rational Catalan LPs}

\begin{fineprint}
Catalan LPs must not cross a line with slope $1$ (the line $y=x$). For
$k$-Catalan LPs, this line is replaced by a line with slope $k\in\mathbb{N}$
(the line $y=kx$).

Can we replace it by a line with rational slope? The simplest example of such
a line is the line $ax=by$, where $a$ and $b$ are two given integers. We can
WLOG assume that $a$ and $b$ are coprime\footnote{Recall that two integers $a$
and $b$ are said to be \textbf{coprime} if their greatest common divisor is
$1$. When $b\neq0$, this is tantamount to saying that the fraction $a/b$ is
reduced.}, since the line $ax=by$ doesn't change when we divide the numbers
$a$ and $b$ by their greatest common divisor. We also assume that $a$ and $b$
are positive. We now define:

\begin{definition}
Let $a$ and $b$ be two coprime positive integers. A LP $\mathbf{v}$ is said to
be $\left(  a,b\right)  $\textbf{-Catalan} if each $\left(  x,y\right)
\in\mathbf{v}$ satisfies $ax\geq by$.
\end{definition}

Thus, a LP is $\left(  a,b\right)  $-Catalan if it never strays above the
\textquotedblleft slanted\textquotedblright\ diagonal $ax=by$.

\begin{example}
Let $a=3$ and $b=5$. Here are two $\left(  a,b\right)  $-Catalan LPs from
$\left(  0,0\right)  $ to $\left(  b,a\right)  $:%
\[%
%TCIMACRO{\TeXButton{tikz 35-cat path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.5, -0.3) -- (5.5, 3.3) -- (5.5, -0.3) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (5, 1) (5, 1) edge (5, 2) (5, 2) -- (5, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(5,3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.5, -0.3) -- (5.5, 3.3) -- (5.5, -0.3) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (5, 1) (5, 1) edge (5, 2) (5, 2) -- (5, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(5,3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ \
\]
and%
\[%
%TCIMACRO{\TeXButton{tikz 35-cat path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.5, -0.3) -- (5.5, 3.3) -- (5.5, -0.3) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (3, 0) (3, 0) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (5, 2) (5, 2) -- (5, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(5,3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.5, -0.3) -- (5.5, 3.3) -- (5.5, -0.3) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (3, 0) (3, 0) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (5, 2) (5, 2) -- (5, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(5,3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
Here is an LP from $\left(  0,0\right)  $ to $\left(  b,a\right)  $ that is
not $\left(  a,b\right)  $-Catalan (since it contains the point $\left(
1,1\right)  $, which fails the $ax\geq by$ condition):%
\[%
%TCIMACRO{\TeXButton{tikz non-35-cat path}{\begin{tikzpicture}
%\fill[cyan!25] (-0.5, -0.3) -- (5.5, 3.3) -- (5.5, -0.3) -- cycle;
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (5, 2) (5, 2) -- (5, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(5,3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\fill[cyan!25] (-0.5, -0.3) -- (5.5, 3.3) -- (5.5, -0.3) -- cycle;
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (5, 2) (5, 2) -- (5, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(5,3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]

\end{example}

Of course, $\left(  a,b\right)  $-Catalan LPs are a generalization of
$k$-Catalan LPs (since a $k$-Catalan LP is the same as a $\left(  1,k\right)
$-Catalan LP). Once again, we are paying for the extra generality with some
lost simplicity: There is (to my knowledge) no analogue to Theorem
\ref{thm.lps.Lnmk.formulas} \textbf{(d)} for $\left(  a,b\right)  $-Catalan
LPs. There seems to be no simple formula for the \# of $\left(  a,b\right)
$-Catalan LPs from $\left(  0,0\right)  $ to a given point. However, there is
still a beautiful formula for the case when the ending point is $\left(
b,a\right)  $:

\begin{theorem}
\label{thm.lps.abcat.main}Let $a$ and $b$ be two coprime positive integers.
Then,%
\[
\left(  \text{\# of }\left(  a,b\right)  \text{-Catalan LPs from }\left(
0,0\right)  \text{ to }\left(  b,a\right)  \right)  =\dfrac{1}{a+b}%
\dbinom{a+b}{a}.
\]

\end{theorem}

A few words are in order before we prove this theorem. Theorem
\ref{thm.lps.abcat.main} is a celebrated result, appearing in \cite[Theorem
10.4.1]{Kratte17} and also (in a slightly restated form) in \cite[Theorem
12.1]{Loehr-2ed}. The number $\dfrac{1}{a+b}\dbinom{a+b}{a}$ on the right hand
side is called a \textbf{rational Catalan number}, and the word
\textquotedblleft rational\textquotedblright\ here is referring not to its
rationality (it is actually an integer, since it counts certain
LPs!\footnote{Fun exercise: Prove that $\dfrac{1}{a+b}\dbinom{a+b}{a}$ is an
integer \textbf{without} using Theorem \ref{thm.lps.abcat.main}! (Don't forget
to use the assumption that $a$ and $b$ are coprime, since this statement
doesn't hold otherwise.)}) but to the fact that the \textquotedblleft border
line\textquotedblright\ $ax=by$ has rational (as opposed to integer) slope.

\begin{proof}
[Proof of Theorem \ref{thm.lps.abcat.main} (sketched).]Let $\mathcal{L}$
denote the set of \textbf{all} LPs from $\left(  0,0\right)  $ to $\left(
b,a\right)  $ is $\dbinom{a+b}{a}$. Thus,%
\begin{align*}
\left\vert \mathcal{L}\right\vert  &  =\left(  \text{\# of \textbf{all} LPs
from }\left(  0,0\right)  \text{ to }\left(  b,a\right)  \right) \\
&  =\dbinom{a+b}{a}\ \ \ \ \ \ \ \ \ \ \left(  \text{by Proposition
\ref{prop.lps.num}}\right)  .
\end{align*}


For any LP $\mathbf{v}\in\mathcal{L}$, we define a new LP $S\left(
\mathbf{v}\right)  $, which is constructed as follows:

\begin{itemize}
\item The LP $S\left(  \mathbf{v}\right)  $ starts at $\left(  0,0\right)  $
(just like $\mathbf{v}$ does).

\item The $1$-st step of $S\left(  \mathbf{v}\right)  $ is the $2$-nd step of
$\mathbf{v}$.

\item The $2$-nd step of $S\left(  \mathbf{v}\right)  $ is the $3$-rd step of
$\mathbf{v}$.

\item The $3$-rd step of $S\left(  \mathbf{v}\right)  $ is the $4$-th step of
$\mathbf{v}$.

\item And so on, until we get to the last step.

\item The last step of $S\left(  \mathbf{v}\right)  $ is the first step of
$\mathbf{v}$.
\end{itemize}

Thus, the step sequence of $S\left(  \mathbf{v}\right)  $ is precisely the
step sequence of $\mathbf{v}$, rotated cyclically one step to the left (so
that the first step has become the last). This uniquely defines $S\left(
\mathbf{v}\right)  $ (since a LP is uniquely determined by its starting point
and its step sequence). Moreover, $S\left(  \mathbf{v}\right)  $ is again an
LP from $\left(  0,0\right)  $ to $\left(  b,a\right)  $ (since it has the
same steps as $\mathbf{v}$, just in a different order), and hence belongs to
$\mathcal{L}$. We call $S\left(  \mathbf{v}\right)  $ the \textbf{cyclic
shift} of $\mathbf{v}$.

\begin{example}
Assume that $\mathbf{v}$ is the LP from $\left(  0,0\right)  $ to $\left(
5,3\right)  $ whose step sequence is $RRURRUUR$. This LP looks as follows:%
\[
\mathbf{v}=%
%TCIMACRO{\TeXButton{tikz LP}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (4, 3) (4, 3) -- (5, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(5,3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (2, 0) (2, 0) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (4, 1) (4, 1) edge (4, 2) (4, 2) edge (4, 3) (4, 3) -- (5, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(5,3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ \ .
\]
Then, $S\left(  \mathbf{v}\right)  $ is the LP from $\left(  0,0\right)  $ to
$\left(  5,3\right)  $ whose step sequence is $RURRUURR$ (note that this is
just $RRURRUUR$, rotated cyclically one step to the left). This LP looks as
follows:%
\[
S\left(  \mathbf{v}\right)  =%
%TCIMACRO{\TeXButton{tikz LP}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (3, 2) (3, 2) edge (3, 3) (3, 3) edge (4, 3) (4, 3) -- (5, 3);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(5,3\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 0) (1, 0) edge (1, 1) (1, 1) edge (2, 1) (2, 1) edge (3, 1) (3, 1) edge (3, 2) (3, 2) edge (3, 3) (3, 3) edge (4, 3) (4, 3) -- (5, 3);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\draw[fill=blue] (5, 3) circle (0.1) node[above right] {\textcolor
{blue}{$\left(5,3\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ \ .
\]

\end{example}

Geometrically, $S\left(  \mathbf{v}\right)  $ can be obtained from
$\mathbf{v}$ by cut-and-pasting the first step of $\mathbf{v}$ to the very end
of $\mathbf{v}$ and then translating\footnote{To \textbf{translate} a LP by a
given pair $\left(  u,v\right)  \in\mathbb{Z}^{2}$ means to replace each point
$\left(  p,q\right)  $ of this LP by the point $\left(  p+u,q+v\right)  $.
Geometrically, this means that the LP undergoes a parallel translation by the
vector $\left(  u,v\right)  $. Clearly, any LP can be made to start at
$\left(  0,0\right)  $ by an appropriate translation.} the resulting LP to
make it start at $\left(  0,0\right)  $ again.

Thus, we have defined a map%
\begin{align*}
S:\mathcal{L}  &  \rightarrow\mathcal{L},\\
\mathbf{v}  &  \mapsto S\left(  \mathbf{v}\right)  .
\end{align*}


Note that each LP $\mathbf{v}$ in $\mathcal{L}$ is an LP from $\left(
0,0\right)  $ to $\left(  b,a\right)  $, and thus has $b+a=a+b$ steps. Hence,
if we rotate its step sequence cyclically $a+b$ times (each time rotating it
one step to the left), then we recover its original step sequence. Therefore,
$S^{a+b}\left(  \mathbf{v}\right)  =\mathbf{v}$ (since the step sequence of
$\mathbf{v}$ gets rotated $a+b$ times when we apply $S^{a+b}$). This holds for
every $\mathbf{v}\in\mathcal{L}$; thus, we conclude that $S^{a+b}%
=\operatorname*{id}$.

Hence, the map $S$ is bijective (with inverse $S^{a+b-1}$), and thus is a
permutation of the finite set $\mathcal{L}$. Consider the orbits of this
permutation. We claim the following:

\begin{statement}
\textit{Claim 1:} Each orbit of $S$ has size $a+b$.
\end{statement}

\begin{statement}
\textit{Claim 2:} Each orbit of $S$ contains exactly one $\left(  a,b\right)
$-Catalan LP.
\end{statement}

Once Claims 1 and 2 are proven, it will follow that exactly one in $a+b$ LPs
in $\mathcal{L}$ is $\left(  a,b\right)  $-Catalan (because each orbit of $S$
has exactly one $\left(  a,b\right)  $-Catalan LP among its $a+b$ many
elements), and therefore we will conclude that%
\[
\left(  \text{\# of }\left(  a,b\right)  \text{-Catalan LPs in }%
\mathcal{L}\right)  =\dfrac{1}{a+b}\left\vert \mathcal{L}\right\vert
=\dfrac{1}{a+b}\dbinom{a+b}{a}%
\]
(since $\left\vert \mathcal{L}\right\vert =\dbinom{a+b}{a}$). This will
immediately yield Theorem \ref{thm.lps.abcat.main} (since $\mathcal{L}$ is the
set of all LPs from $\left(  0,0\right)  $ to $\left(  b,a\right)  $). Thus,
it remains to prove Claims 1 and 2.

In order to prove both claims, let us fix an orbit $C$ of $S$. We must prove
that $\left\vert C\right\vert =a+b$ and that $C$ contains exactly one $\left(
a,b\right)  $-Catalan LP.

Choose any $\mathbf{v}\in C$. Then, $C$ is the orbit of $S$ containing
$\mathbf{v}$. In other words, $C=\left[  \mathbf{v}\right]  _{\sim}$, where
$\sim$ is the equivalence relation $\overset{S}{\sim}$. Hence,%
\begin{align}
C  &  =\left\{  S^{m}\left(  \mathbf{v}\right)  \ \mid\ m\in\mathbb{N}%
\right\}  \ \ \ \ \ \ \ \ \ \ \left(  \text{by Proposition 4.3.4 \textbf{(a)}
in Lecture 27}\right) \nonumber\\
&  =\left\{  S^{0}\left(  \mathbf{v}\right)  ,\ S^{1}\left(  \mathbf{v}%
\right)  ,\ \ldots,\ S^{a+b-1}\left(  \mathbf{v}\right)  \right\}
\label{pf.thm.lps.abcat.main.C=set}%
\end{align}
(since $S^{a+b}\left(  \mathbf{v}\right)  =\mathbf{v}$). We set out to show
the following claim (from which Claims 1 and 2 will easily follow):

\begin{statement}
\textit{Claim 3:} There is exactly one $i\in\left\{  0,1,\ldots,a+b-1\right\}
$ such that the LP $S^{i}\left(  \mathbf{v}\right)  $ is $\left(  a,b\right)
$-Catalan.
\end{statement}

The easiest way to prove Claim 3 is to regard the LPs $S^{0}\left(
\mathbf{v}\right)  ,S^{1}\left(  \mathbf{v}\right)  ,\ldots,S^{a+b-1}\left(
\mathbf{v}\right)  $ not as separate LPs, but rather as pieces of one longer
LP $\mathbf{w}$, which goes from $\left(  0,0\right)  $ to $\left(
2b,2a\right)  $ (and thus has twice as many steps as $\mathbf{v}$). We will
construct this longer LP by \textquotedblleft copy-pasting\textquotedblright%
\ the LP $\mathbf{v}$ and translating its copy by the vector $\left(
b,a\right)  $ (so that its starting point becomes $\left(  b,a\right)  $).

Here is this construction in detail. The LP $\mathbf{v}$ is a LP from $\left(
0,0\right)  $ to $\left(  b,a\right)  $; thus, it has $b$ right-steps and $a$
up-steps. Consequently, $\mathbf{v}$ has $b+a=a+b$ steps in total. Thus, we
can write $\mathbf{v}$ in the form $\mathbf{v}=\left(  v_{0},v_{1}%
,\ldots,v_{a+b}\right)  $. Let us do so. Thus, $v_{0}=\left(  0,0\right)  $
and $v_{a+b}=\left(  b,a\right)  $.

Let $\mathbf{v}^{\prime}$ be the LP $\mathbf{v}$ translated by the vector
$\left(  b,a\right)  $. That is, we set%
\begin{equation}
\mathbf{v}^{\prime}:=\left(  v_{0}+\left(  b,a\right)  ,\ v_{1}+\left(
b,a\right)  ,\ \ldots,\ v_{a+b}+\left(  b,a\right)  \right)  .
\label{pf.thm.lps.abcat.main.v'=1}%
\end{equation}
The starting point of this new LP $\mathbf{v}^{\prime}$ is $\underbrace{v_{0}%
}_{=\left(  0,0\right)  }+\left(  b,a\right)  =\left(  0,0\right)  +\left(
b,a\right)  =\left(  b,a\right)  =v_{a+b}$. Let us denote the remaining points
of $\mathbf{v}^{\prime}$ by $v_{a+b+1},v_{a+b+2},\ldots,v_{2a+2b}$,
respectively (since $v_{i}$ has so far been defined only for $i\in\left\{
0,1,\ldots,a+b\right\}  $). Thus,%
\begin{equation}
\mathbf{v}^{\prime}=\left(  v_{a+b},v_{a+b+1},\ldots,v_{2a+2b}\right)  .
\label{pf.thm.lps.abcat.main.v'=2}%
\end{equation}


Comparing this with (\ref{pf.thm.lps.abcat.main.v'=1}), we obtain%
\[
\left(  v_{a+b},v_{a+b+1},\ldots,v_{2a+2b}\right)  =\left(  v_{0}+\left(
b,a\right)  ,\ v_{1}+\left(  b,a\right)  ,\ \ldots,\ v_{a+b}+\left(
b,a\right)  \right)  .
\]
In other words,%
\begin{equation}
v_{a+b+i}=v_{i}+\left(  b,a\right)  \ \ \ \ \ \ \ \ \ \ \text{for each }%
i\in\left\{  0,1,\ldots,a+b\right\}  . \label{pf.thm.lps.abcat.main.va+b+i=}%
\end{equation}


Now, the LP $\mathbf{v}=\left(  v_{0},v_{1},\ldots,v_{a+b}\right)  $ ends at
the same point at which the LP $\mathbf{v}^{\prime}=\left(  v_{a+b}%
,v_{a+b+1},\ldots,v_{2a+2b}\right)  $ starts (namely, at $v_{a+b}$). Hence, we
can combine these two LPs into the LP%
\[
\mathbf{w}:=\left(  v_{0},v_{1},\ldots,v_{2a+2b}\right)  ,
\]
which has $2a+2b$ steps.

\begin{example}
\label{exa.pf.thm.lps.abcat.main.w}For example, let $a=3$ and $b=5$, and let
$\mathbf{v}$ be the following LP:%
\[%
%TCIMACRO{\TeXButton{tikz LP}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\node(v0) at (0, 0) {};
%\node(v1) at (1, 0) {};
%\node(v2) at (2, 0) {};
%\node(v3) at (2, 1) {};
%\node(v4) at (2, 2) {};
%\node(v5) at (3, 2) {};
%\node(v6) at (3, 3) {};
%\node(v7) at (4, 3) {};
%\node(v8) at (5, 3) {};
%\draw
%[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
%\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
%\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
%\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
%\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
%\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
%\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
%\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
%\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
%\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\node(v0) at (0, 0) {};
\node(v1) at (1, 0) {};
\node(v2) at (2, 0) {};
\node(v3) at (2, 1) {};
\node(v4) at (2, 2) {};
\node(v5) at (3, 2) {};
\node(v6) at (3, 3) {};
\node(v7) at (4, 3) {};
\node(v8) at (5, 3) {};
\draw
[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
\end{tikzpicture}%
%EndExpansion
\]
(a LP from $\left(  0,0\right)  $ to $\left(  5,3\right)  $). Then,
$\mathbf{w}$ is the following LP:%
\[%
%TCIMACRO{\TeXButton{tikz doubled LP}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (10.2, 6.2);
%\node(v0) at (0, 0) {};
%\node(v1) at (1, 0) {};
%\node(v2) at (2, 0) {};
%\node(v3) at (2, 1) {};
%\node(v4) at (2, 2) {};
%\node(v5) at (3, 2) {};
%\node(v6) at (3, 3) {};
%\node(v7) at (4, 3) {};
%\node(v8) at (5, 3) {};
%\node(v9) at (6, 3) {};
%\node(v10) at (7, 3) {};
%\node(v11) at (7, 4) {};
%\node(v12) at (7, 5) {};
%\node(v13) at (8, 5) {};
%\node(v14) at (8, 6) {};
%\node(v15) at (9, 6) {};
%\node(v16) at (10, 6) {};
%\draw
%[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
%\draw
%[line width=2pt,-stealth,red!50!black] (v8) edge (v9) (v9) edge (v10) (v10) edge (v11) (v11) edge (v12) (v12) edge (v13) (v13) edge (v14) (v14) edge (v15) (v15) -- (v16);
%\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
%\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
%\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
%\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
%\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
%\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
%\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
%\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
%\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
%\draw[fill=blue] (v9) circle (0.1) node[below] {\textcolor{blue}{$v_9$}};
%\draw[fill=blue] (v10) circle (0.1) node[below] {\textcolor{blue}{$v_{10}$}};
%\draw[fill=blue] (v11) circle (0.1) node[right] {\textcolor{blue}{$v_{11}$}};
%\draw[fill=blue] (v12) circle (0.1) node[left] {\textcolor{blue}{$v_{12}$}};
%\draw[fill=blue] (v13) circle (0.1) node[right] {\textcolor{blue}{$v_{13}$}};
%\draw[fill=blue] (v14) circle (0.1) node[above] {\textcolor{blue}{$v_{14}$}};
%\draw[fill=blue] (v15) circle (0.1) node[above] {\textcolor{blue}{$v_{15}$}};
%\draw[fill=blue] (v16) circle (0.1) node[above] {\textcolor{blue}{$v_{16}$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (10.2, 6.2);
\node(v0) at (0, 0) {};
\node(v1) at (1, 0) {};
\node(v2) at (2, 0) {};
\node(v3) at (2, 1) {};
\node(v4) at (2, 2) {};
\node(v5) at (3, 2) {};
\node(v6) at (3, 3) {};
\node(v7) at (4, 3) {};
\node(v8) at (5, 3) {};
\node(v9) at (6, 3) {};
\node(v10) at (7, 3) {};
\node(v11) at (7, 4) {};
\node(v12) at (7, 5) {};
\node(v13) at (8, 5) {};
\node(v14) at (8, 6) {};
\node(v15) at (9, 6) {};
\node(v16) at (10, 6) {};
\draw
[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
\draw
[line width=2pt,-stealth,red!50!black] (v8) edge (v9) (v9) edge (v10) (v10) edge (v11) (v11) edge (v12) (v12) edge (v13) (v13) edge (v14) (v14) edge (v15) (v15) -- (v16);
\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
\draw[fill=blue] (v9) circle (0.1) node[below] {\textcolor{blue}{$v_9$}};
\draw[fill=blue] (v10) circle (0.1) node[below] {\textcolor{blue}{$v_{10}$}};
\draw[fill=blue] (v11) circle (0.1) node[right] {\textcolor{blue}{$v_{11}$}};
\draw[fill=blue] (v12) circle (0.1) node[left] {\textcolor{blue}{$v_{12}$}};
\draw[fill=blue] (v13) circle (0.1) node[right] {\textcolor{blue}{$v_{13}$}};
\draw[fill=blue] (v14) circle (0.1) node[above] {\textcolor{blue}{$v_{14}$}};
\draw[fill=blue] (v15) circle (0.1) node[above] {\textcolor{blue}{$v_{15}$}};
\draw[fill=blue] (v16) circle (0.1) node[above] {\textcolor{blue}{$v_{16}$}};
\end{tikzpicture}%
%EndExpansion
\]
(where we painted all steps of $\mathbf{v}$ black and all steps of
$\mathbf{v}^{\prime}$ dark-red).
\end{example}

Back to the general case. For each $i\in\left\{  0,1,\ldots,2a+2b\right\}  $,
we let $\ell_{i}$ be the line\footnote{The word \textquotedblleft
line\textquotedblright\ always \textquotedblleft straight
line\textquotedblright\ in this proof.} with slope $\dfrac{a}{b}$ (that is,
parallel to the line with equation $ax=by$) passing through the point $v_{i}$.
Thus, $\ell_{0},\ell_{1},\ldots,\ell_{2a+2b}$ are $2a+2b+1$ parallel lines. We
will soon see that some of these lines coincide, while others don't. First, an example:

\begin{example}
If $a$, $b$ and $\mathbf{v}$ are as in Example
\ref{exa.pf.thm.lps.abcat.main.w}, then let us draw these $2a+2b+1$ lines in
red:%
\[%
%TCIMACRO{\TeXButton{tikz eight lines}{\begin{tikzpicture}
%\clip(-1.2, -1.2) rectangle (11.2, 7.2);
%\draw[help lines] (-1.2, -1.2) grid (11.2, 7.2);
%\node(v0) at (0, 0) {};
%\node(v1) at (1, 0) {};
%\node(v2) at (2, 0) {};
%\node(v3) at (2, 1) {};
%\node(v4) at (2, 2) {};
%\node(v5) at (3, 2) {};
%\node(v6) at (3, 3) {};
%\node(v7) at (4, 3) {};
%\node(v8) at (5, 3) {};
%\node(v9) at (6, 3) {};
%\node(v10) at (7, 3) {};
%\node(v11) at (7, 4) {};
%\node(v12) at (7, 5) {};
%\node(v13) at (8, 5) {};
%\node(v14) at (8, 6) {};
%\node(v15) at (9, 6) {};
%\node(v16) at (10, 6) {};
%\draw[red, line width=1pt] (v0)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v1)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v2)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v3)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v4)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v5)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v6)++(-10, -6) -- ++(20, 12);
%\draw[red, line width=1pt] (v7)++(-10, -6) -- ++(20, 12);
%\draw
%[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
%\draw
%[line width=2pt,-stealth,red!50!black] (v8) edge (v9) (v9) edge (v10) (v10) edge (v11) (v11) edge (v12) (v12) edge (v13) (v13) edge (v14) (v14) edge (v15) (v15) -- (v16);
%\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
%\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
%\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
%\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
%\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
%\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
%\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
%\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
%\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
%\draw[fill=blue] (v9) circle (0.1) node[below] {\textcolor{blue}{$v_9$}};
%\draw[fill=blue] (v10) circle (0.1) node[below] {\textcolor{blue}{$v_{10}$}};
%\draw[fill=blue] (v11) circle (0.1) node[right] {\textcolor{blue}{$v_{11}$}};
%\draw[fill=blue] (v12) circle (0.1) node[left] {\textcolor{blue}{$v_{12}$}};
%\draw[fill=blue] (v13) circle (0.1) node[right] {\textcolor{blue}{$v_{13}$}};
%\draw[fill=blue] (v14) circle (0.1) node[above] {\textcolor{blue}{$v_{14}$}};
%\draw[fill=blue] (v15) circle (0.1) node[above] {\textcolor{blue}{$v_{15}$}};
%\draw[fill=blue] (v16) circle (0.1) node[above] {\textcolor{blue}{$v_{16}$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\clip(-1.2, -1.2) rectangle (11.2, 7.2);
\draw[help lines] (-1.2, -1.2) grid (11.2, 7.2);
\node(v0) at (0, 0) {};
\node(v1) at (1, 0) {};
\node(v2) at (2, 0) {};
\node(v3) at (2, 1) {};
\node(v4) at (2, 2) {};
\node(v5) at (3, 2) {};
\node(v6) at (3, 3) {};
\node(v7) at (4, 3) {};
\node(v8) at (5, 3) {};
\node(v9) at (6, 3) {};
\node(v10) at (7, 3) {};
\node(v11) at (7, 4) {};
\node(v12) at (7, 5) {};
\node(v13) at (8, 5) {};
\node(v14) at (8, 6) {};
\node(v15) at (9, 6) {};
\node(v16) at (10, 6) {};
\draw[red, line width=1pt] (v0)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v1)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v2)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v3)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v4)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v5)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v6)++(-10, -6) -- ++(20, 12);
\draw[red, line width=1pt] (v7)++(-10, -6) -- ++(20, 12);
\draw
[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
\draw
[line width=2pt,-stealth,red!50!black] (v8) edge (v9) (v9) edge (v10) (v10) edge (v11) (v11) edge (v12) (v12) edge (v13) (v13) edge (v14) (v14) edge (v15) (v15) -- (v16);
\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
\draw[fill=blue] (v9) circle (0.1) node[below] {\textcolor{blue}{$v_9$}};
\draw[fill=blue] (v10) circle (0.1) node[below] {\textcolor{blue}{$v_{10}$}};
\draw[fill=blue] (v11) circle (0.1) node[right] {\textcolor{blue}{$v_{11}$}};
\draw[fill=blue] (v12) circle (0.1) node[left] {\textcolor{blue}{$v_{12}$}};
\draw[fill=blue] (v13) circle (0.1) node[right] {\textcolor{blue}{$v_{13}$}};
\draw[fill=blue] (v14) circle (0.1) node[above] {\textcolor{blue}{$v_{14}$}};
\draw[fill=blue] (v15) circle (0.1) node[above] {\textcolor{blue}{$v_{15}$}};
\draw[fill=blue] (v16) circle (0.1) node[above] {\textcolor{blue}{$v_{16}$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
Note that there are only $8=a+b$ distinct red lines here, and these are
(listed from top to bottom)%
\begin{align*}
\ell_{6}  &  =\ell_{14},\ \ \ \ \ \ \ \ \ \ \ell_{4}=\ell_{12}%
,\ \ \ \ \ \ \ \ \ \ \ell_{7}=\ell_{15},\ \ \ \ \ \ \ \ \ \ \ell_{5}=\ell
_{13},\\
\ell_{0}  &  =\ell_{8}=\ell_{16},\ \ \ \ \ \ \ \ \ \ \ell_{3}=\ell
_{11},\ \ \ \ \ \ \ \ \ \ \ell_{1}=\ell_{9},\ \ \ \ \ \ \ \ \ \ \ell_{2}%
=\ell_{10}.
\end{align*}

\end{example}

Some of the things you see in this example hold in full generality.

First of all, we have $\ell_{i}=\ell_{a+b+i}$ for each $i\in\left\{
0,1,\ldots,a+b\right\}  $\ \ \ \ \footnote{\textit{Proof.} Let $i\in\left\{
0,1,\ldots,a+b\right\}  $. Then, $v_{a+b+i}=v_{i}+\left(  b,a\right)  $ (by
(\ref{pf.thm.lps.abcat.main.va+b+i=})). Thus, the line joining the points
$v_{i}$ and $v_{a+b+i}$ has slope $\dfrac{a}{b}$. Therefore, the line with
slope $\dfrac{a}{b}$ passing through $v_{i}$ coincides with the line with
slope $\dfrac{a}{b}$ passing through $v_{a+b+i}$. But the former line has been
called $\ell_{i}$, while the latter has been called $\ell_{a+b+i}$. Thus,
$\ell_{i}$ coincides with $\ell_{a+b+i}$. In other words, $\ell_{i}%
=\ell_{a+b+i}$, qed.}. In other words, the sequence $\left(  \ell_{0},\ell
_{1},\ldots,\ell_{2a+2b}\right)  $ is periodic with period $a+b$. Therefore,
the $2a+2b+1$ lines $\ell_{0},\ell_{1},\ldots,\ell_{2a+2b}$ are just the $a+b$
lines $\ell_{0},\ell_{1},\ldots,\ell_{a+b-1}$, each repeated twice or (in the
case of $\ell_{0}$) thrice.

Next, we shall show that the $a+b$ lines $\ell_{0},\ell_{1},\ldots
,\ell_{a+b-1}$ are distinct.

[\textit{Proof:} Assume the contrary. Thus, two of these $a+b$ lines $\ell
_{0},\ell_{1},\ldots,\ell_{a+b-1}$ coincide. In other words, there exist two
elements $i<j$ of $\left\{  0,1,\ldots,a+b-1\right\}  $ such that $\ell
_{i}=\ell_{j}$. Consider these $i$ and $j$.

Write the points $v_{i}$ and $v_{j}$ as $v_{i}=\left(  x_{i},y_{i}\right)  $
and $v_{j}=\left(  x_{j},y_{j}\right)  $. Note that the path $\mathbf{w}$
takes $j-i$ steps to get from $v_{i}$ to $v_{j}$. Among these $j-i$ steps,
there must be exactly $x_{j}-x_{i}$ right-steps (since $v_{i}=\left(
x_{i},y_{i}\right)  $ and $v_{j}=\left(  x_{j},y_{j}\right)  $) and exactly
$y_{j}-y_{i}$ up-steps (for the same reason). Hence, we must have%
\begin{equation}
j-i=\left(  x_{j}-x_{i}\right)  +\left(  y_{j}-y_{i}\right)  .
\label{pf.thm.lps.abcat.main.distinct.pf.1}%
\end{equation}
Thus, $\left(  x_{j}-x_{i}\right)  +\left(  y_{j}-y_{i}\right)  =j-i>0$ (since
$i<j$), so that the two numbers $x_{j}-x_{i}$ and $y_{j}-y_{i}$ cannot both be
$0$. Their ratio $\dfrac{y_{j}-y_{i}}{x_{j}-x_{i}}$ is thus well-defined, if
we understand a fraction with zero denominator (but nonzero numerator) to be
the symbol $\infty$.

However, the line $\ell_{i}$ passes through $v_{i}$, whereas the line
$\ell_{j}$ passes through $v_{j}$. Since we have assumed that $\ell_{i}%
=\ell_{j}$, we thus conclude that the line $\ell_{i}=\ell_{j}$ passes through
both $v_{i}$ and $v_{j}$. The slope of this line must therefore be
$\dfrac{y_{j}-y_{i}}{x_{j}-x_{i}}$ (by the standard formula for the slope of
the line through two given points, since $v_{i}=\left(  x_{i},y_{i}\right)  $
and $v_{j}=\left(  x_{j},y_{j}\right)  $). Thus, $\dfrac{y_{j}-y_{i}}%
{x_{j}-x_{i}}=\dfrac{a}{b}$ (since the slope of the line $\ell_{i}=\ell_{j}$
is $\dfrac{a}{b}$ by the definition of this line). In other words, $b\left(
y_{j}-y_{i}\right)  =a\left(  x_{j}-x_{i}\right)  $. Hence, the product
$b\left(  y_{j}-y_{i}\right)  $ is divisible by $a$. In other words, $a\mid
b\left(  y_{j}-y_{i}\right)  $.

However, a classical number-theoretical fact (see, e.g., \cite[Theorem
2.10.6]{19s}, where I use the symbol \textquotedblleft$\perp$%
\textquotedblright\ for \textquotedblleft coprime to\textquotedblright) shows
that if some integer $c$ satisfies $a\mid bc$, then $a\mid c$ (since $a$ and
$b$ are coprime). Applying this to $c=y_{j}-y_{i}$, we obtain $a\mid
y_{j}-y_{i}$ (since $a\mid b\left(  y_{j}-y_{i}\right)  $). In other words,
$y_{j}-y_{i}=ma$ for some integer $m$. Consider this $m$. Hence, the equality
$b\left(  y_{j}-y_{i}\right)  =a\left(  x_{j}-x_{i}\right)  $ (which we proved
above) can be rewritten as $bma=a\left(  x_{j}-x_{i}\right)  $. Cancelling $a$
from this equality, we obtain $bm=x_{j}-x_{i}$ (since $a$ is positive and thus
nonzero). Hence, $x_{j}-x_{i}=bm$. Now,
(\ref{pf.thm.lps.abcat.main.distinct.pf.1}) becomes%
\[
j-i=\underbrace{\left(  x_{j}-x_{i}\right)  }_{=bm}+\underbrace{\left(
y_{j}-y_{i}\right)  }_{=ma}=bm+ma=m\left(  a+b\right)  .
\]
Since both numbers $j-i$ and $a+b$ in this equality are positive, the factor
$m$ must also be positive. Hence, $m\geq1$, so that $m\left(  a+b\right)  \geq
a+b$. Thus, $j-i=m\left(  a+b\right)  \geq a+b$.

However, from $i,j\in\left\{  0,1,\ldots,a+b-1\right\}  $, we obtain $i\geq0$
and $j\leq a+b-1<a+b$, so that $j-\underbrace{i}_{\geq0}\leq j<a+b$. This
contradicts $j-i\geq a+b$. This contradiction shows that our assumption was
false. Hence, we have proved that the $a+b$ lines $\ell_{0},\ell_{1}%
,\ldots,\ell_{a+b-1}$ are distinct.] \medskip

We note that the line $\ell_{0}$ is defined to be the line through
$v_{0}=\left(  0,0\right)  $ with slope $\dfrac{a}{b}$. In other words,
$\ell_{0}$ is the line with equation $ax=by$.

Now, we shall show the following:

\begin{statement}
\textit{Claim 4:} Let $i\in\left\{  0,1,\ldots,a+b-1\right\}  $. Then, the LP
$S^{i}\left(  \mathbf{v}\right)  $ is $\left(  a,b\right)  $-Catalan if and
only if the line $\ell_{i}$ is the highest\footnote{The lines $\ell_{0}%
,\ell_{1},\ldots,\ell_{a+b-1}$ are parallel, and their direction is not
vertical (since their slope is $\dfrac{a}{b}\neq\infty$). Thus, they can be
ranked by their height. (For example, you can define the height of a line as
the y-coordinate of the point where it intersects the y-axis.)} among the
parallel lines $\ell_{0},\ell_{1},\ldots,\ell_{a+b-1}$.
\end{statement}

[\textit{Proof of Claim 4:} We observe that the LP $S^{i}\left(
\mathbf{v}\right)  $ has starting point $\left(  0,0\right)  =v_{0}$.

Let $\mathbf{v}^{+i}$ be the LP $\left(  v_{i},v_{i+1},v_{i+2},\ldots
,v_{i+a+b}\right)  $. This LP $\mathbf{v}^{+i}$ is a piece of the LP
$\mathbf{w}=\left(  v_{0},v_{1},\ldots,v_{2a+2b}\right)  $, and thus its step
sequence consists of the last $a+b-i$ steps of $\mathbf{v}$ followed by the
first $i$ steps of $\mathbf{v}^{\prime}$ (since the path $\mathbf{w}$ is
obtained by combining $\mathbf{v}$ with $\mathbf{v}^{\prime}$). Since the
steps of $\mathbf{v}^{\prime}$ are precisely the steps of $\mathbf{v}$ (by the
definition of $\mathbf{v}^{\prime}$), we can restate this as follows: The step
sequence of $\mathbf{v}^{+i}$ consists of the last $a+b-i$ steps of
$\mathbf{v}$ followed by the first $i$ steps of $\mathbf{v}$. In other words,
the step sequence of $\mathbf{v}^{+i}$ is the step sequence of $\mathbf{v}$,
rotated $i$ steps to the left (so that the first $i$ steps are moved to the
end). But this is precisely how we characterized the step sequence of
$S^{i}\left(  \mathbf{v}\right)  $ above.\footnote{Here is an illustration
(for $i=2$): If $\mathbf{v}$ is the LP from Example
\ref{exa.pf.thm.lps.abcat.main.w}, then the LP $\mathbf{v}^{+2}$ consists of
the red steps in the following picture:%
\[%
%TCIMACRO{\TeXButton{tikz doubled LP}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (10.2, 6.2);
%\node(v0) at (0, 0) {};
%\node(v1) at (1, 0) {};
%\node(v2) at (2, 0) {};
%\node(v3) at (2, 1) {};
%\node(v4) at (2, 2) {};
%\node(v5) at (3, 2) {};
%\node(v6) at (3, 3) {};
%\node(v7) at (4, 3) {};
%\node(v8) at (5, 3) {};
%\node(v9) at (6, 3) {};
%\node(v10) at (7, 3) {};
%\node(v11) at (7, 4) {};
%\node(v12) at (7, 5) {};
%\node(v13) at (8, 5) {};
%\node(v14) at (8, 6) {};
%\node(v15) at (9, 6) {};
%\node(v16) at (10, 6) {};
%\draw[line width=2pt,-stealth] (v0) edge (v1) (v1) -- (v2);
%\draw
%[line width=2pt,-stealth,red] (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) edge (v8) (v8) edge (v9) (v9) -- (v10);
%\draw
%[line width=2pt,-stealth] (v10) edge (v11) (v11) edge (v12) (v12) edge (v13) (v13) edge (v14) (v14) edge (v15) (v15) -- (v16);
%\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
%\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
%\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
%\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
%\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
%\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
%\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
%\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
%\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
%\draw[fill=blue] (v9) circle (0.1) node[below] {\textcolor{blue}{$v_9$}};
%\draw[fill=blue] (v10) circle (0.1) node[below] {\textcolor{blue}{$v_{10}$}};
%\draw[fill=blue] (v11) circle (0.1) node[right] {\textcolor{blue}{$v_{11}$}};
%\draw[fill=blue] (v12) circle (0.1) node[left] {\textcolor{blue}{$v_{12}$}};
%\draw[fill=blue] (v13) circle (0.1) node[right] {\textcolor{blue}{$v_{13}$}};
%\draw[fill=blue] (v14) circle (0.1) node[above] {\textcolor{blue}{$v_{14}$}};
%\draw[fill=blue] (v15) circle (0.1) node[above] {\textcolor{blue}{$v_{15}$}};
%\draw[fill=blue] (v16) circle (0.1) node[above] {\textcolor{blue}{$v_{16}$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (10.2, 6.2);
\node(v0) at (0, 0) {};
\node(v1) at (1, 0) {};
\node(v2) at (2, 0) {};
\node(v3) at (2, 1) {};
\node(v4) at (2, 2) {};
\node(v5) at (3, 2) {};
\node(v6) at (3, 3) {};
\node(v7) at (4, 3) {};
\node(v8) at (5, 3) {};
\node(v9) at (6, 3) {};
\node(v10) at (7, 3) {};
\node(v11) at (7, 4) {};
\node(v12) at (7, 5) {};
\node(v13) at (8, 5) {};
\node(v14) at (8, 6) {};
\node(v15) at (9, 6) {};
\node(v16) at (10, 6) {};
\draw[line width=2pt,-stealth] (v0) edge (v1) (v1) -- (v2);
\draw
[line width=2pt,-stealth,red] (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) edge (v8) (v8) edge (v9) (v9) -- (v10);
\draw
[line width=2pt,-stealth] (v10) edge (v11) (v11) edge (v12) (v12) edge (v13) (v13) edge (v14) (v14) edge (v15) (v15) -- (v16);
\draw[fill=blue] (v0) circle (0.1) node[left] {\textcolor{blue}{$v_0$}};
\draw[fill=blue] (v1) circle (0.1) node[below] {\textcolor{blue}{$v_1$}};
\draw[fill=blue] (v2) circle (0.1) node[below] {\textcolor{blue}{$v_2$}};
\draw[fill=blue] (v3) circle (0.1) node[right] {\textcolor{blue}{$v_3$}};
\draw[fill=blue] (v4) circle (0.1) node[left] {\textcolor{blue}{$v_4$}};
\draw[fill=blue] (v5) circle (0.1) node[right] {\textcolor{blue}{$v_5$}};
\draw[fill=blue] (v6) circle (0.1) node[above] {\textcolor{blue}{$v_6$}};
\draw[fill=blue] (v7) circle (0.1) node[above] {\textcolor{blue}{$v_7$}};
\draw[fill=blue] (v8) circle (0.1) node[above] {\textcolor{blue}{$v_8$}};
\draw[fill=blue] (v9) circle (0.1) node[below] {\textcolor{blue}{$v_9$}};
\draw[fill=blue] (v10) circle (0.1) node[below] {\textcolor{blue}{$v_{10}$}};
\draw[fill=blue] (v11) circle (0.1) node[right] {\textcolor{blue}{$v_{11}$}};
\draw[fill=blue] (v12) circle (0.1) node[left] {\textcolor{blue}{$v_{12}$}};
\draw[fill=blue] (v13) circle (0.1) node[right] {\textcolor{blue}{$v_{13}$}};
\draw[fill=blue] (v14) circle (0.1) node[above] {\textcolor{blue}{$v_{14}$}};
\draw[fill=blue] (v15) circle (0.1) node[above] {\textcolor{blue}{$v_{15}$}};
\draw[fill=blue] (v16) circle (0.1) node[above] {\textcolor{blue}{$v_{16}$}};
\end{tikzpicture}%
%EndExpansion
\ \ ,
\]
whereas $S^{2}\left(  \mathbf{v}\right)  $ is the following LP:%
\[%
%TCIMACRO{\TeXButton{tikz LP}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
%\node(v0) at (0, 0) {};
%\node(v1) at (0, 1) {};
%\node(v2) at (0, 2) {};
%\node(v3) at (1, 2) {};
%\node(v4) at (1, 3) {};
%\node(v5) at (2, 3) {};
%\node(v6) at (3, 3) {};
%\node(v7) at (4, 3) {};
%\node(v8) at (5, 3) {};
%\draw
%[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
%\draw[fill=blue] (v0) circle (0.1);
%\draw[fill=blue] (v1) circle (0.1);
%\draw[fill=blue] (v2) circle (0.1);
%\draw[fill=blue] (v3) circle (0.1);
%\draw[fill=blue] (v4) circle (0.1);
%\draw[fill=blue] (v5) circle (0.1);
%\draw[fill=blue] (v6) circle (0.1);
%\draw[fill=blue] (v7) circle (0.1);
%\draw[fill=blue] (v8) circle (0.1);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (5.2, 3.2);
\node(v0) at (0, 0) {};
\node(v1) at (0, 1) {};
\node(v2) at (0, 2) {};
\node(v3) at (1, 2) {};
\node(v4) at (1, 3) {};
\node(v5) at (2, 3) {};
\node(v6) at (3, 3) {};
\node(v7) at (4, 3) {};
\node(v8) at (5, 3) {};
\draw
[line width=2pt,-stealth] (v0) edge (v1) (v1) edge (v2) (v2) edge (v3) (v3) edge (v4) (v4) edge (v5) (v5) edge (v6) (v6) edge (v7) (v7) -- (v8);
\draw[fill=blue] (v0) circle (0.1);
\draw[fill=blue] (v1) circle (0.1);
\draw[fill=blue] (v2) circle (0.1);
\draw[fill=blue] (v3) circle (0.1);
\draw[fill=blue] (v4) circle (0.1);
\draw[fill=blue] (v5) circle (0.1);
\draw[fill=blue] (v6) circle (0.1);
\draw[fill=blue] (v7) circle (0.1);
\draw[fill=blue] (v8) circle (0.1);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\]
}

Hence, the LPs $\mathbf{v}^{+i}$ and $S^{i}\left(  \mathbf{v}\right)  $ have
the same sequence. This does not mean that these two LPs are literally
identical, since they start at different points (unless $i=0$). However, it
does mean that the LP $\mathbf{v}^{+i}$ can be obtained from the LP
$S^{i}\left(  \mathbf{v}\right)  $ by a translation -- namely, by the
translation that sends the starting point $v_{0}$ of the latter LP to the
starting point $v_{i}$ of the former LP. Let $\tau$ denote this translation.
Thus, $\tau\left(  v_{0}\right)  =v_{i}$ and $\tau\left(  S^{i}\left(
\mathbf{v}\right)  \right)  =\mathbf{v}^{+i}$.

A translation sends any line to a line parallel to it. Hence, the image
$\tau\left(  \ell_{0}\right)  $ of the line $\ell_{0}$ under the translation
$\tau$ is a line parallel to $\ell_{0}$ and passing through the point
$\tau\left(  v_{0}\right)  $ (since $\ell_{0}$ passes through $v_{0}$). In
other words, $\tau\left(  \ell_{0}\right)  $ is a line parallel to $\ell_{0}$
and passing through $v_{i}$ (since $\tau\left(  v_{0}\right)  =v_{i}$). But
this means that it must be the line $\ell_{i}$ (since the line $\ell_{i}$ is
parallel to $\ell_{0}$ and passes through $v_{i}$). Thus, we have shown that
$\tau\left(  \ell_{0}\right)  =\ell_{i}$.

Now, recall that a LP is $\left(  a,b\right)  $-Catalan if and only if it
never strays above the line with equation $ax=by$. But this line is precisely
the line $\ell_{0}$. Hence, a LP is $\left(  a,b\right)  $-Catalan if and only
if it never strays above the line $\ell_{0}$.

Therefore, we have the following chain of logical equivalences:%
\begin{align*}
&  \ \ \ \ \ \ \ \ \ \left(  \text{the LP }S^{i}\left(  \mathbf{v}\right)
\text{ is }\left(  a,b\right)  \text{-Catalan}\right) \\
&  \Longleftrightarrow\ \left(  \text{the LP }S^{i}\left(  \mathbf{v}\right)
\text{ never strays above the line }\ell_{0}\right) \\
&  \Longleftrightarrow\ \left(  \text{the LP }\tau\left(  S^{i}\left(
\mathbf{v}\right)  \right)  \text{ never strays above the line }\tau\left(
\ell_{0}\right)  \right) \\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{since the translation }\tau\text{ preserves the}\\
\text{\textquotedblleft never strays above\textquotedblright\ relation}%
\end{array}
\right) \\
&  \Longleftrightarrow\ \left(  \text{the LP }\mathbf{v}^{+i}\text{ never
strays above the line }\ell_{i}\right)  \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{since }\tau\left(  S^{i}\left(  \mathbf{v}\right)  \right)
=\mathbf{v}^{+i}\\
\text{and }\tau\left(  \ell_{0}\right)  =\ell_{i}%
\end{array}
\right) \\
&  \Longleftrightarrow\ \left(  \text{none of the points }v_{i},v_{i+1}%
,v_{i+2},\ldots,v_{i+a+b}\text{ lies above the line }\ell_{i}\right) \\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(  \text{since }%
\mathbf{v}^{+i}=\left(  v_{i},v_{i+1},v_{i+2},\ldots,v_{i+a+b}\right)  \right)
\\
&  \Longleftrightarrow\ \left(  \text{none of the lines }\ell_{i},\ell
_{i+1},\ell_{i+2},\ldots,\ell_{i+a+b}\text{ is higher than the line }\ell
_{i}\right) \\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{since a point }v_{j}\text{ lies above the line }\ell_{i}\\
\text{if and only if the line }\ell_{j}\text{ is higher than }\ell_{i}\\
\text{(because }\ell_{j}\text{ is the line parallel to }\ell_{i}\text{ through
}v_{j}\text{)}%
\end{array}
\right) \\
&  \Longleftrightarrow\ \left(  \ell_{i}\text{ is the highest of the
}a+b+1\text{ lines }\ell_{i},\ell_{i+1},\ell_{i+2},\ldots,\ell_{i+a+b}\right)
\\
&  \Longleftrightarrow\ \left(  \ell_{i}\text{ is the highest of the
}2a+2b+1\text{ lines }\ell_{0},\ell_{1},\ldots,\ell_{2a+2b}\right) \\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{since }\left\{  \ell_{i},\ell_{i+1},\ell_{i+2},\ldots,\ell
_{i+a+b}\right\}  =\left\{  \ell_{0},\ell_{1},\ldots,\ell_{2a+2b}\right\}
\text{ as sets}\\
\text{(because the sequence }\left(  \ell_{0},\ell_{1},\ldots,\ell
_{2a+2b}\right)  \text{ is periodic}\\
\text{with period }a+b\text{, and thus any }a+b\text{ consecutive}\\
\text{entries of this sequence contain all its entries)}%
\end{array}
\right) \\
&  \Longleftrightarrow\ \left(  \ell_{i}\text{ is the highest of the
}a+b\text{ lines }\ell_{0},\ell_{1},\ldots,\ell_{a+b-1}\right) \\
&  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \left(  \text{for a similar reason
as the previous equivalence}\right) \\
&  \Longleftrightarrow\ \left(  \ell_{i}\text{ is the highest among the
parallel lines }\ell_{0},\ell_{1},\ldots,\ell_{a+b-1}\right)  .
\end{align*}
This proves Claim 4.] \medskip

Claims 1, 2 and 3 are now at arm's reach:

[\textit{Proof of Claim 3:} We must prove that there is exactly one
$i\in\left\{  0,1,\ldots,a+b-1\right\}  $ such that the LP $S^{i}\left(
\mathbf{v}\right)  $ is $\left(  a,b\right)  $-Catalan. In view of Claim 4,
this is equivalent to proving that there is exactly one $i\in\left\{
0,1,\ldots,a+b-1\right\}  $ such that the line $\ell_{i}$ is the highest among
the parallel lines $\ell_{0},\ell_{1},\ldots,\ell_{a+b-1}$. In other words, we
must prove that among the $a+b$ lines $\ell_{0},\ell_{1},\ldots,\ell_{a+b-1}$,
exactly one is the highest (i.e., there is no tie). But this follows from the
fact (proved above) that the $a+b$ lines $\ell_{0},\ell_{1},\ldots
,\ell_{a+b-1}$ are distinct (and thus have different heights). Thus, Claim 3
is proven.] \medskip

Now, Claim 3 says that there is exactly one $\left(  a,b\right)  $-Catalan LP
among the $a+b$ LPs $S^{0}\left(  \mathbf{v}\right)  ,\ S^{1}\left(
\mathbf{v}\right)  ,\ \ldots,\ S^{a+b-1}\left(  \mathbf{v}\right)  $.
Therefore, the set $\left\{  S^{0}\left(  \mathbf{v}\right)  ,\ S^{1}\left(
\mathbf{v}\right)  ,\ \ldots,\ S^{a+b-1}\left(  \mathbf{v}\right)  \right\}  $
contains exactly one $\left(  a,b\right)  $-Catalan LP. In view of
(\ref{pf.thm.lps.abcat.main.C=set}), this means that the set $C$ contains
exactly one $\left(  a,b\right)  $-Catalan LP.

Moreover, it is now easy to prove that the $a+b$ LPs $S^{0}\left(
\mathbf{v}\right)  ,\ S^{1}\left(  \mathbf{v}\right)  ,\ \ldots,\ S^{a+b-1}%
\left(  \mathbf{v}\right)  $ are distinct.

[\textit{Proof.} Assume the contrary. Thus, there exist two elements $p<q$ of
$\left\{  0,1,\ldots,a+b-1\right\}  $ such that $S^{p}\left(  \mathbf{v}%
\right)  =S^{q}\left(  \mathbf{v}\right)  $. Consider these $p$ and $q$.

The map $S$ is bijective, so its inverse $S^{-1}$ and its negative powers
$S^{k}$ for $k<0$ exist. Applying $S^{-p}$ to both sides of the equality
$S^{p}\left(  \mathbf{v}\right)  =S^{q}\left(  \mathbf{v}\right)  $, we obtain
$S^{-p}\left(  S^{p}\left(  \mathbf{v}\right)  \right)  =S^{-p}\left(
S^{q}\left(  \mathbf{v}\right)  \right)  =S^{-p+q}\left(  \mathbf{v}\right)
=S^{q-p}\left(  \mathbf{v}\right)  $. Hence, $S^{q-p}\left(  \mathbf{v}%
\right)  =S^{-p}\left(  S^{p}\left(  \mathbf{v}\right)  \right)  =\mathbf{v}$.

From $q\leq a+b-1$ and $p\geq0$, we obtain $q-\underbrace{p}_{\geq0}\leq q\leq
a+b-1$, so that $q-p\in\left[  a+b-1\right]  $ (since $p<q$ leads to $q-p>0$).

However, Claim 3 (with $i$ renamed as $k$) shows that there is exactly one
$k\in\left\{  0,1,\ldots,a+b-1\right\}  $ such that the LP $S^{k}\left(
\mathbf{v}\right)  $ is $\left(  a,b\right)  $-Catalan. Consider this $k$.

But $\mathbf{v}$ is just an arbitrary element of $C$. Now, $S^{k}\left(
\mathbf{v}\right)  $ is an element of $C$ as well (since $C=\left\{
S^{0}\left(  \mathbf{v}\right)  ,\ S^{1}\left(  \mathbf{v}\right)
,\ \ldots,\ S^{a+b-1}\left(  \mathbf{v}\right)  \right\}  $ clearly contains
$S^{k}\left(  \mathbf{v}\right)  $). Thus, we can apply Claim 3 to
$S^{k}\left(  \mathbf{v}\right)  $ instead of $\mathbf{v}$. We thus conclude
that there is exactly one $i\in\left\{  0,1,\ldots,a+b-1\right\}  $ such that
$S^{i}\left(  S^{k}\left(  \mathbf{v}\right)  \right)  $ is $\left(
a,b\right)  $-Catalan. Since $0$ is such an $i$ (because $S^{0}\left(
S^{k}\left(  \mathbf{v}\right)  \right)  =S^{k}\left(  \mathbf{v}\right)  $ is
$\left(  a,b\right)  $-Catalan), we thus conclude that $0$ is the
\textbf{only} such $i$. In other words, for any $i\in\left[  a+b-1\right]  $,
the LP $S^{i}\left(  S^{k}\left(  \mathbf{v}\right)  \right)  $ is
\textbf{not} $\left(  a,b\right)  $-Catalan. Applying this to $i=q-p$, we
conclude that $S^{q-p}\left(  S^{k}\left(  \mathbf{v}\right)  \right)  $ is
\textbf{not} $\left(  a,b\right)  $-Catalan (since $q-p\in\left[
a+b-1\right]  $).

However,
\[
S^{q-p}\left(  S^{k}\left(  \mathbf{v}\right)  \right)  =S^{\left(
q-p\right)  +k}\left(  \mathbf{v}\right)  =S^{k+\left(  q-p\right)  }\left(
\mathbf{v}\right)  =S^{k}\left(  \underbrace{S^{q-p}\left(  \mathbf{v}\right)
}_{=\mathbf{v}}\right)  =S^{k}\left(  \mathbf{v}\right)  ,
\]
which is $\left(  a,b\right)  $-Catalan (as we know). This contradicts the
fact that $S^{q-p}\left(  S^{k}\left(  \mathbf{v}\right)  \right)  $ is
\textbf{not} $\left(  a,b\right)  $-Catalan. This contradiction shows that our
assumption was false. Hence, we have shown that the $a+b$ LPs $S^{0}\left(
\mathbf{v}\right)  ,\ S^{1}\left(  \mathbf{v}\right)  ,\ \ldots,\ S^{a+b-1}%
\left(  \mathbf{v}\right)  $ are distinct.] \medskip

This entails that $\left\vert \left\{  S^{0}\left(  \mathbf{v}\right)
,\ S^{1}\left(  \mathbf{v}\right)  ,\ \ldots,\ S^{a+b-1}\left(  \mathbf{v}%
\right)  \right\}  \right\vert =a+b$. In other words, $\left\vert C\right\vert
=a+b$ (since $C=\left\{  S^{0}\left(  \mathbf{v}\right)  ,\ S^{1}\left(
\mathbf{v}\right)  ,\ \ldots,\ S^{a+b-1}\left(  \mathbf{v}\right)  \right\}
$). In other words, $C$ has size $a+b$. Recall also that $C$ contains exactly
one $\left(  a,b\right)  $-Catalan LP (as we have proved above).

Forget that we fixed $C$. We thus have shown that every orbit $C$ of $S$ has
size $a+b$ and contains exactly one $\left(  a,b\right)  $-Catalan LP. This
proves Claims 1 and 2. As explained above, this completes the proof of Theorem
\ref{thm.lps.abcat.main}.
\end{proof}

Recall that $k$-Catalan paths are the same as $\left(  1,k\right)  $-Catalan
paths. However, Theorem \ref{thm.lps.abcat.main} is specific to LPs from
$\left(  0,0\right)  $ to $\left(  b,a\right)  $, which are not very
interesting in the particular case when $a=1$. Thus, it may appear that
Theorem \ref{thm.lps.abcat.main} is unrelated to Theorem
\ref{thm.lps.Lnmk.formulas}. However, this appearance is deceptive. Thanks to
a subtle trick, we can actually derive Theorem \ref{thm.lps.Lnmk.formulas}
\textbf{(e)} from Theorem \ref{thm.lps.abcat.main}:

\begin{proof}
[Proof of Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(e)} using Theorem
\ref{thm.lps.abcat.main} (sketched).]Let $m\in\mathbb{N}$. WLOG assume that
$m>0$ (since otherwise, Theorem \ref{thm.lps.Lnmk.formulas} \textbf{(e)} is obvious).

The positive integers $m$ and $km+1$ are coprime (since basic properties of
the greatest common divisor yield $\gcd\left(  m,\ km+1\right)  =\gcd\left(
m,\ 1\right)  =1$). Hence, we can apply Theorem \ref{thm.lps.abcat.main} to
$a=m$ and $b=km+1$. Thus we obtain%
\begin{align*}
&  \left(  \text{\# of }\left(  m,\ km+1\right)  \text{-Catalan LPs from
}\left(  0,0\right)  \text{ to }\left(  km+1,\ m\right)  \right) \\
&  =\dfrac{1}{m+km+1}\dbinom{m+km+1}{m}\\
&  =\dfrac{1}{km+1}\dbinom{m+km}{m}\ \ \ \ \ \ \ \ \ \ \left(
\begin{array}
[c]{c}%
\text{by some easy manipulations using}\\
\text{the factorial formula for BCs}%
\end{array}
\right) \\
&  =\dfrac{1}{km+1}\dbinom{\left(  k+1\right)  m}{m}.
\end{align*}
It remains to relate the $\left(  m,\ km+1\right)  $-Catalan LPs from $\left(
0,0\right)  $ to $\left(  km+1,\ m\right)  $ to the $k$-Catalan LPs from
$\left(  0,0\right)  $ to $\left(  km,m\right)  $ (which are counted by
$L_{km,m,k}$).

It turns out that the former are just one step away from the latter
(literally): If $\mathbf{v}=\left(  v_{0},v_{1},\ldots,v_{n}\right)  $ is a
$k$-Catalan LP from $\left(  0,0\right)  $ to $\left(  km,m\right)  $, then%
\[
\mathbf{v}^{\prime}:=\left(  \left(  0,0\right)  ,\ \underbrace{v_{0}+\left(
1,0\right)  ,\ v_{1}+\left(  1,0\right)  ,\ \ldots,\ v_{n}+\left(  1,0\right)
}_{\text{This is just the LP }\mathbf{v}\text{, translated by the vector
}\left(  1,0\right)  }\right)
\]
is a $\left(  m,\ km+1\right)  $-Catalan LP from $\left(  0,0\right)  $ to
$\left(  km+1,\ m\right)  $ (check this!\footnote{This boils down to checking
that if a point $\left(  x,y\right)  \in\mathbf{v}$ satisfies $x\geq ky$, then
the corresponding translated point $\left(  x+1,y\right)  \in\mathbf{v}%
^{\prime}$ satisfies $m\left(  x+1\right)  \geq\left(  km+1\right)  y$. In
order to check this, observe that $y\leq m$ (why?).}). Essentially,
$\mathbf{v}^{\prime}$ is just the LP $\mathbf{v}$, shifted to the right by $1$
unit and reconnected to the old starting point $\left(  0,0\right)  $ by an
extra right-step inserted at the front. Thus, we obtain a map%
\begin{align*}
&  \text{from }\left\{  k\text{-Catalan LPs from }\left(  0,0\right)  \text{
to }\left(  km,m\right)  \right\} \\
&  \text{to }\left\{  \left(  m,\ km+1\right)  \text{-Catalan LPs from
}\left(  0,0\right)  \text{ to }\left(  km+1,\ m\right)  \right\}
\end{align*}
that sends each $\mathbf{v}$ to $\mathbf{v}^{\prime}$. This map is furthermore
bijective\footnote{Injectivity is obvious, but surjectivity is a bit tricky:
It is clear that every $\left(  m,\ km+1\right)  $-Catalan LP from $\left(
0,0\right)  $ to $\left(  km+1,\ m\right)  $ must start with a right-step and
thus has the form $\mathbf{v}^{\prime}$ for \textbf{some} LP $\mathbf{v}$ from
$\left(  0,0\right)  $ to $\left(  km,m\right)  $. What is less clear is that
this $\mathbf{v}$ must be $k$-Catalan. To show this, you need to prove that
each of its points $\left(  x,y\right)  \in\mathbf{v}$ satisfies $x\geq ky$;
you are given that $m\left(  x+1\right)  \geq\left(  km+1\right)  y$, since
$\mathbf{v}^{\prime}$ is $\left(  m,\ km+1\right)  $-Catalan. However,
$y\in\left\{  0,1,\ldots,m\right\}  $ (why?). If $y>0$, then dividing the
inequality $m\left(  x+1\right)  \geq\left(  km+1\right)  y$ by $m$ yields
$x+1\geq ky+\dfrac{y}{m}>ky$ and thus $x\geq ky$ (since $x$ and $ky$ are
integers). If $y=0$, then $x\geq ky$ holds anyway. Thus, in either case, we
get $x\geq ky$, as desired.}. Hence, by the bijection principle, we have%
\begin{align*}
&  \left(  \text{\# of }k\text{-Catalan LPs from }\left(  0,0\right)  \text{
to }\left(  km,m\right)  \right) \\
&  =\left(  \text{\# of }\left(  m,\ km+1\right)  \text{-Catalan LPs from
}\left(  0,0\right)  \text{ to }\left(  km+1,\ m\right)  \right) \\
&  =\dfrac{1}{km+1}\dbinom{\left(  k+1\right)  m}{m}.
\end{align*}
Since the left hand side of this equality is $L_{km,m,k}$ (by definition of
$L_{km,m,k}$), this yields precisely the claim of Theorem
\ref{thm.lps.Lnmk.formulas} \textbf{(e)}.
\end{proof}
\end{fineprint}

\subsection{Dyck paths}

\begin{fineprint}
So far, we have been discussing LPs that consist of up-steps and right-steps.
Many variations on this concept can be obtained by requiring other kinds of
steps. Here is one of the most popular ones:

\begin{definition}
\label{def.lps.diagp}Let $\left(  a,b\right)  \in\mathbb{Z}^{2}$ and $\left(
c,d\right)  \in\mathbb{Z}^{2}$ be two points. Then, a \textbf{diagonal path}
from $\left(  a,b\right)  $ to $\left(  c,d\right)  $ is

\begin{itemize}
\item informally understood to be a path from $\left(  a,b\right)  $ to
$\left(  c,d\right)  $ in the plane that uses only the following two kinds of steps:

\begin{itemize}
\item \textquotedblleft\textbf{positive steps}\textquotedblright\ (denoted
\textquotedblleft$P$\textquotedblright) that go from a point $\left(
p,q\right)  $ to $\left(  p+1,q+1\right)  $;

\item \textquotedblleft\textbf{negative steps}\textquotedblright\ (denoted
\textquotedblleft$N$\textquotedblright) that go from a point $\left(
p,q\right)  $ to $\left(  p+1,q-1\right)  $.
\end{itemize}

\item rigorously defined to be a tuple $\left(  v_{0},v_{1},\ldots
,v_{n}\right)  $ of points $v_{0},v_{1},\ldots,v_{n}\in\mathbb{Z}^{2}$ such
that%
\begin{align*}
v_{0}  &  =\left(  a,b\right)  \ \ \ \ \ \ \ \ \ \ \text{and}%
\ \ \ \ \ \ \ \ \ \ v_{n}=\left(  c,d\right)  \ \ \ \ \ \ \ \ \ \ \text{and}\\
v_{i}-v_{i-1}  &  \in\left\{  \left(  1,1\right)  ,\ \ \left(  1,-1\right)
\right\}  \ \ \ \ \ \ \ \ \ \ \text{for each }i\in\left[  n\right]  .
\end{align*}
If $\left(  v_{0},v_{1},\ldots,v_{n}\right)  $ is a diagonal path from
$\left(  a,b\right)  $ to $\left(  c,d\right)  $, then the differences
$v_{i}-v_{i-1}$ (for $i\in\left[  n\right]  $) are called the \textbf{steps}
of this path. The pair $\left(  1,1\right)  $ is called a \textbf{positive
step} and is denoted by $P$; the pair $\left(  1,-1\right)  $ is called a
\textbf{negative step} and is denoted by $N$.
\end{itemize}
\end{definition}

\begin{example}
Here is an example of a diagonal path from $\left(  0,2\right)  $ to $\left(
10,0\right)  $:%
\[%
%TCIMACRO{\TeXButton{tikz diagonal path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (10.2, 4.2);
%\draw
%[line width=2pt,-stealth] (0, 2) edge (1, 3) (1, 3) edge (2, 4) (2, 4) edge (3, 3) (3, 3) edge (4, 4) (4, 4) edge (5, 3) (5, 3) edge (6, 2) (6, 2) edge (7, 1) (7, 1) edge (8, 2) (8, 2) edge (9, 1) (9, 1) -- (10, 0);
%\draw[fill=blue] (0, 2) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 2\right)$}};
%\draw[fill=blue] (10, 0) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(10,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (10.2, 4.2);
\draw
[line width=2pt,-stealth] (0, 2) edge (1, 3) (1, 3) edge (2, 4) (2, 4) edge (3, 3) (3, 3) edge (4, 4) (4, 4) edge (5, 3) (5, 3) edge (6, 2) (6, 2) edge (7, 1) (7, 1) edge (8, 2) (8, 2) edge (9, 1) (9, 1) -- (10, 0);
\draw[fill=blue] (0, 2) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 2\right)$}};
\draw[fill=blue] (10, 0) circle (0.1) node[above right] {\textcolor
{blue}{$\left(10,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
Its steps are $P,P,N,P,N,N,N,P,N,N$.
\end{example}

\begin{definition}
Let $\mathbf{v}=\left(  v_{0},v_{1},\ldots,v_{n}\right)  $ be a diagonal path
from a point $\left(  a,b\right)  $ to a point $\left(  c,d\right)  $. Let
$p\in\mathbb{Z}^{2}$ be a point. We say that $p\in\mathbf{v}$ (in words: $p$
\textbf{lies on} $\mathbf{v}$) if $p\in\left\{  v_{0},v_{1},\ldots
,v_{n}\right\}  $.
\end{definition}

A fundamental observation about diagonal paths is the following:

\begin{proposition}
\label{prop.lps.diagp.color}Assume that all points $\left(  x,y\right)
\in\mathbb{Z}^{2}$ are colored in two colors: Namely, each point $\left(
x,y\right)  \in\mathbb{Z}^{2}$ is colored black if $x+y$ is even and white if
$x+y$ is odd. (This is called the \textbf{chessboard coloring}, for obvious reasons.)

Let $\mathbf{v}$ be a diagonal path. Then, all points on $\mathbf{v}$ have the
same color.
\end{proposition}

\begin{proof}
Left to the reader.
\end{proof}

We also leave it to the reader to find the \# of diagonal paths from a point
$\left(  a,b\right)  $ to a point $\left(  c,d\right)  $. (Note that this \#
will be $0$ if the numbers $a+b$ and $c+d$ have different parities, because of
Proposition \ref{prop.lps.diagp.color}.) We will instead focus on a special
kind of diagonal paths (compare to Catalan paths):

\begin{definition}
A diagonal path $\mathbf{v}$ is said to be \textbf{Dyck} if each $\left(
x,y\right)  \in\mathbf{v}$ satisfies $y\geq0$.
\end{definition}

In other words, a diagonal path is Dyck if and only if it never strays below
the x-axis.\footnote{Note that the name \textquotedblleft Dyck
path\textquotedblright\ does not have a standardized meaning across the
literature. Some authors instead use it for what we call Catalan paths, or
(like Loehr in \cite{Loehr-2ed}) for the reflections of the Catalan paths
across the $x=y$ diagonal. This is understandable, since all of these objects
are closely related (as we will soon see).
\par
What we call \textquotedblleft Dyck paths\textquotedblright, on the other
hand, is called \textquotedblleft mountain ranges\textquotedblright\ in some
sources (such as \cite[\S 1.2]{Davis16}).
\par
The name \textquotedblleft Dyck paths\textquotedblright\ honors the German
mathematician Walther Franz Anton von Dyck, who appears to have introduced
these paths as an equivalent concept to the so-called \textquotedblleft Dyck
words\textquotedblright\ (which are precisely the \textquotedblleft legal
sequences of parentheses\textquotedblright\ we discussed above).}

\begin{example}
Here are all Dyck paths from $\left(  0,0\right)  $ to $\left(  6,0\right)  $:%
\[%
%TCIMACRO{\TeXButton{tikz diagonal path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 2) (2, 2) edge (3, 3) (3, 3) edge (4, 2) (4, 2) edge (5, 1) (5, 1) -- (6, 0);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 0\right)$}};
%\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(6,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 2) (2, 2) edge (3, 3) (3, 3) edge (4, 2) (4, 2) edge (5, 1) (5, 1) -- (6, 0);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 0\right)$}};
\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
{blue}{$\left(6,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ ,
\]%
\[%
%TCIMACRO{\TeXButton{tikz diagonal path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 2) (2, 2) edge (3, 1) (3, 1) edge (4, 2) (4, 2) edge (5, 1) (5, 1) -- (6, 0);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 0\right)$}};
%\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(6,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 2) (2, 2) edge (3, 1) (3, 1) edge (4, 2) (4, 2) edge (5, 1) (5, 1) -- (6, 0);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 0\right)$}};
\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
{blue}{$\left(6,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ ,
\]%
\[%
%TCIMACRO{\TeXButton{tikz diagonal path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 0) (2, 0) edge (3, 1) (3, 1) edge (4, 2) (4, 2) edge (5, 1) (5, 1) -- (6, 0);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 0\right)$}};
%\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(6,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 0) (2, 0) edge (3, 1) (3, 1) edge (4, 2) (4, 2) edge (5, 1) (5, 1) -- (6, 0);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 0\right)$}};
\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
{blue}{$\left(6,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ ,
\]%
\[%
%TCIMACRO{\TeXButton{tikz diagonal path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 2) (2, 2) edge (3, 1) (3, 1) edge (4, 0) (4, 0) edge (5, 1) (5, 1) -- (6, 0);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 0\right)$}};
%\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(6,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 2) (2, 2) edge (3, 1) (3, 1) edge (4, 0) (4, 0) edge (5, 1) (5, 1) -- (6, 0);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 0\right)$}};
\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
{blue}{$\left(6,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ ,
\]%
\[%
%TCIMACRO{\TeXButton{tikz diagonal path}{\begin{tikzpicture}
%\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
%\draw
%[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 0) (2, 0) edge (3, 1) (3, 1) edge (4, 0) (4, 0) edge (5, 1) (5, 1) -- (6, 0);
%\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
%{$\left(0, 0\right)$}};
%\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
%{blue}{$\left(6,0\right)$}};
%\end{tikzpicture}}}%
%BeginExpansion
\begin{tikzpicture}
\draw[help lines] (-0.2, -0.2) grid (6.2, 3.2);
\draw
[line width=2pt,-stealth] (0, 0) edge (1, 1) (1, 1) edge (2, 0) (2, 0) edge (3, 1) (3, 1) edge (4, 0) (4, 0) edge (5, 1) (5, 1) -- (6, 0);
\draw[fill=blue] (0, 0) circle (0.1) node[below left] {\textcolor{blue}%
{$\left(0, 0\right)$}};
\draw[fill=blue] (6, 0) circle (0.1) node[above right] {\textcolor
{blue}{$\left(6,0\right)$}};
\end{tikzpicture}%
%EndExpansion
\ \ .
\]
In particular, there are $5$ of them.
\end{example}

The $5$ is not a random number here; it is the Catalan number $C_{3}$. This generalizes:

\begin{theorem}
\label{thm.lps.diagp.dyck-count}Let $n\in\mathbb{N}$. Then,%
\[
\left(  \text{\# of Dyck paths from }\left(  0,0\right)  \text{ to }\left(
2n,0\right)  \right)  =C_{n}.
\]

\end{theorem}

\begin{proof}
[Proof idea.]There is a map%
\begin{align*}
&  \text{from }\left\{  \text{Dyck paths from }\left(  0,0\right)  \text{ to
}\left(  2n,0\right)  \right\} \\
&  \text{to }\left\{  \text{Catalan paths from }\left(  0,0\right)  \text{ to
}\left(  n,n\right)  \right\}  ,
\end{align*}
which replaces each point $\left(  x,y\right)  $ on the Dyck path by $\left(
\dfrac{x+y}{2},\dfrac{x-y}{2}\right)  $. Check that this map is well-defined
(Proposition \ref{prop.lps.diagp.color} ensures that $\dfrac{x+y}{2}$ and
$\dfrac{x-y}{2}$ are integers!) and bijective (construct the inverse
explicitly!). Thus, the bijection principle yields%
\begin{align*}
&  \left(  \text{\# of Dyck paths from }\left(  0,0\right)  \text{ to }\left(
2n,0\right)  \right) \\
&  =\left(  \text{\# of Catalan paths from }\left(  0,0\right)  \text{ to
}\left(  n,n\right)  \right) \\
&  =L_{n,n}\ \ \ \ \ \ \ \ \ \ \left(  \text{by the definition of }%
L_{n,n}\right) \\
&  =C_{n}\ \ \ \ \ \ \ \ \ \ \left(  \text{by the definition of }C_{n}\right)
.
\end{align*}
Thus, Theorem \ref{thm.lps.diagp.dyck-count} follows.
\end{proof}

More generally, if $\left(  a,b\right)  $ and $\left(  c,d\right)  $ are two
black points in $\mathbb{Z}^{2}$ (where colors are defined as in Proposition
\ref{prop.lps.diagp.color}), then there is a canonical bijection
\begin{align*}
&  \text{from }\left\{  \text{Dyck paths from }\left(  a,b\right)  \text{ to
}\left(  c,d\right)  \right\} \\
&  \text{to }\left\{  \text{Catalan paths from }\left(  \dfrac{a+b}{2}%
,\dfrac{a-b}{2}\right)  \text{ to }\left(  \dfrac{c+d}{2},\dfrac{c-d}%
{2}\right)  \right\}  .
\end{align*}
A similar bijection exists for Dyck paths between two white points. Thus,
studying Dyck paths is equivalent to studying Catalan paths.
\end{fineprint}

\subsection{More surprising integralities}

\begin{fineprint}
For any $n\in\mathbb{N}$, the $n$-th Catalan number $C_{n}$ is given by%
\begin{align*}
C_{n}  &  =\dfrac{1}{n+1}\dbinom{2n}{n}\\
&  =\dfrac{1}{n+1}\cdot\dfrac{\left(  2n\right)  !}{n!n!}%
\ \ \ \ \ \ \ \ \ \ \left(  \text{by the factorial formula for BCs}\right) \\
&  =\dfrac{\left(  2n\right)  !}{\left(  n+1\right)  \cdot n!\cdot n!}%
=\dfrac{\left(  2n\right)  !}{\left(  n+1\right)  !\cdot n!}%
\ \ \ \ \ \ \ \ \ \ \left(  \text{since }\left(  n+1\right)  \cdot n!=\left(
n+1\right)  !\right)  .
\end{align*}
Thus, we conclude that the ratio $\dfrac{\left(  2n\right)  !}{\left(
n+1\right)  !\cdot n!}$ is an integer (since $C_{n}$ is an integer by its
definition). This is an instance of a class of remarkable results, which claim
that a certain ratio of factorials turns out to be an integer. Of course, an
even simpler result of this type is the integrality of the binomial
coefficient $\dbinom{n}{k}=\dfrac{n!}{k!\cdot\left(  n-k\right)  !}$ for all
$n\in\mathbb{N}$ and $k\in\left\{  0,1,\ldots,n\right\}  $. But there are also
subtler results in this family. Here is another striking result of the same nature:

\begin{proposition}
\label{prop.supercat.main}For any $m\in\mathbb{N}$ and $n\in\mathbb{N}$,
define a rational number $T\left(  m,n\right)  $ by%
\[
T\left(  m,n\right)  :=\dfrac{\left(  2m\right)  !\left(  2n\right)
!}{m!n!\left(  m+n\right)  !}.
\]


Then:

\textbf{(a)} We have $4T\left(  m,n\right)  =T\left(  m+1,n\right)  +T\left(
m,n+1\right)  $ for every $m\in\mathbb{N}$ and $n\in\mathbb{N}$.

\textbf{(b)} We have $T\left(  m,n\right)  \in\mathbb{N}$ for every
$m\in\mathbb{N}$ and $n\in\mathbb{N}$.

\textbf{(c)} If $m\in\mathbb{N}$ and $n\in\mathbb{N}$ are such that $\left(
m,n\right)  \neq\left(  0,0\right)  $, then the integer $T\left(  m,n\right)
$ is even.

\textbf{(d)} If $m\in\mathbb{N}$ and $n\in\mathbb{N}$ are such that $m+n$ is
odd and $m+n>1$, then $4\mid T\left(  m,n\right)  $.

\textbf{(e)} We have $T\left(  m,0\right)  =\dbinom{2m}{m}$ for every
$m\in\mathbb{N}$.

\textbf{(f)} We have $T\left(  m,n\right)  =\dfrac{\dbinom{2m}{m}\dbinom
{2n}{n}}{\dbinom{m+n}{m}}$ for every $m\in\mathbb{N}$ and $n\in\mathbb{N}$.

\textbf{(g)} We have $T\left(  m,n\right)  =T\left(  n,m\right)  $ for every
$m\in\mathbb{N}$ and $n\in\mathbb{N}$.

\textbf{(h)} Let $m\in\mathbb{N}$ and $n\in\mathbb{N}$. Let $p=\min\left\{
m,n\right\}  $. Then,%
\[
\sum_{k=-p}^{p}\left(  -1\right)  ^{k}\dbinom{m+n}{m+k}\dbinom{m+n}%
{n+k}=\dbinom{m+n}{m}.
\]


\textbf{(i)} Let $m\in\mathbb{N}$ and $n\in\mathbb{N}$. Let $p=\min\left\{
m,n\right\}  $. Then,%
\[
T\left(  m,n\right)  =\sum_{k=-p}^{p}\left(  -1\right)  ^{k}\dbinom{2m}%
{m+k}\dbinom{2n}{n-k}.
\]

\end{proposition}

This proposition is proved in \cite[Exercise 3.25]{detnotes}. The numbers
$T\left(  m,n\right)  $ introduced in it are the so-called
\textbf{super-Catalan numbers}\footnote{Unlike the Catalan numbers, they have
in fact been first discovered by Eug\`{e}ne Catalan (1874).}; much has been
written about them (e.g., \cite{Gessel92} and \cite{AleGhe14}). So far, no
good combinatorial interpretation has been found to \textquotedblleft
justify\textquotedblright\ their integrality (i.e., it is not clear what
$T\left(  m,n\right)  $ counts); the known proofs of $T\left(  m,n\right)  $
are either number-theoretical (such as the proof in \cite[solution to Exercise
5.3.5 \textbf{(a)}]{21f-lec5}, which proves an even more general result) or
algebraic (such as the proof in \cite[solution to Exercise 3.25]{detnotes}).

There are several other integrality results like this. As already mentioned,
\cite[Exercise 5.3.5 \textbf{(a)}]{21f-lec5} generalizes Proposition
\ref{prop.supercat.main} \textbf{(b)}. Yet another generalization of
Proposition \ref{prop.supercat.main} \textbf{(b)} is the following fact (which
I have learnt from Ira Gessel):

\begin{proposition}
Let $a,b,c\in\mathbb{N}$. Then, $\dfrac{\left(  a+2b\right)  !\left(
a+2c\right)  !}{a!b!c!\left(  a+b+c\right)  !}\in\mathbb{N}$.
\end{proposition}

\begin{proof}
This is not hard to do using the methods of \cite{21f-lec5} (comparing
$p$-valuations of numerator and denominator), although this is far from a nice
proof. Is there any combinatorial or algebraic approach?
\end{proof}

For other examples of ratios of factorials being unexpectedly integral, see
\cite{WarZud19}.

\bigskip

Incidentally, here is a somewhat unexpected number-theoretic property of
Catalan numbers:

\begin{proposition}
Let $n\in\mathbb{N}$. Then, the Catalan number $C_{n}$ is odd if and only if
$n+1$ is a power of $2$.
\end{proposition}

\begin{proof}
Exercise! (See \cite{KosSal06} for a short proof.)
\end{proof}
\end{fineprint}

\begin{thebibliography}{99999999}                                                                                         %


\bibitem[18s-mt2s]{18s-mt2s}Darij Grinberg, \textit{UMN Spring 2018 Math 4707
midterm \#2 with solutions}, \url{http://www.cip.ifi.lmu.de/~grinberg/t/18s/mt2s.pdf}

\bibitem[19s]{19s}Darij Grinberg, \textit{Introduction to Modern Algebra (UMN
Spring 2019 Math 4281 notes)}, 29 June 2019.\newline\url{http://www.cip.ifi.lmu.de/~grinberg/t/19s/notes.pdf}

\bibitem[21f-lec5]{21f-lec5}Darij Grinberg, \textit{Math 235: Mathematical
Problem Solving, Fall 2021, Worksheet 5: p-valuations}.\newline\url{http://www.cip.ifi.lmu.de/~grinberg/t/21f/lec5.pdf}

\bibitem[AleGhe14]{AleGhe14}%
\href{https://cs.uwaterloo.ca/journals/JIS/VOL17/Allen/gheo.html}{Emily Allen,
Irina Gheorghiciuc, \textit{A weighted interpretation for the super Catalan
numbers}, Journal of Integer Sequences, Vol. 17 (2014), Article 14.10.7}%
.\newline A preprint is
\href{https://arxiv.org/abs/1403.5246v2}{arXiv:1403.5246v2}.

\bibitem[Bona22]{Bona22}Miklos B\'{o}na, \textit{Combinatorics of
Permutations}, 3rd edition, Taylor\&Francis 2022.\newline\url{https://doi.org/10.1201/9780429274107}

\bibitem[Davis16]{Davis16}Tom Davis, \textit{Catalan Numbers}, 19 February
2016.\newline\url{http://www.geometer.org/mathcircles/catalan.pdf}

\bibitem[FreSel01]{FreSel01}%
\href{https://digitalcommons.cedarville.edu/science_and_mathematics_publications/42/}{Darrin
D. Frey, James A. Sellers, \textit{Generalizing Bailey's Generalization of the
Catalan Numbers}, Fibonacci Quarterly, 2001, pp. 142--148.}

\bibitem[Gessel92]{Gessel92}Ira M. Gessel, \textit{Super Ballot Numbers},
Journal of Symbolic Computation, Volume 14, Issues 2--3, August-September
1992, pp. 179--194.\newline\url{https://doi.org/10.1016/0747-7171(92)90034-2}

\bibitem[GouSer03]{GouSer03}%
\href{https://doi.org/10.1016/j.jcta.2003.09.004}{I. P. Goulden, Luis G.
Serrano, \textit{Maintaining the spirit of the reflection principle when the
boundary has arbitrary integer slope}, Journal of Combinatorial Theory, Series
A \textbf{104} (2003), pp. 317--326.}

\bibitem[Grinbe15]{detnotes}Darij Grinberg, \textit{Notes on the combinatorial
fundamentals of algebra}, 15 September 2022.\newline%
\url{http://www.cip.ifi.lmu.de/~grinberg/primes2015/sols.pdf} \newline The
numbering of theorems and formulas in this link might shift when the project
gets updated; for a \textquotedblleft frozen\textquotedblright\ version whose
numbering is guaranteed to match that in the citations above, see
\url{https://github.com/darijgr/detnotes/releases/tag/2022-09-15c} .

\bibitem[HilPed91]{HilPed91}%
\href{https://math.uakron.edu/~cossey/636papers/hilton and pedersen.pdf}{Peter
Hilton, Jean Pedersen, \textit{Catalan Numbers, Their Generalization, and
Their Uses}, Mathematical Intelligencer \textbf{13} (1991), no. 2, pp.
64--75.}

\bibitem[Kitaev11]{Kitaev11}%
\href{https://doi.org/10.1007/978-3-642-17333-2}{Sergey Kitaev,
\textit{Patterns in Permutations and Words}, Springer 2011.}

\bibitem[KosSal06]{KosSal06}%
\href{https://www.maa.org/sites/default/files/Koshy-CMJ-2006.pdf}{Thomas
Koshy, Mohammad Salmassi, \textit{Parity and Primality of Catalan Numbers},
The College Mathematics Journal \textbf{37} (2006), no. 1, pp. 52--53.}

\bibitem[Kratte17]{Kratte17}Christian Krattenthaler, \textit{Lattice Path
Enumeration}, arXiv:1503.05930v3, published in: Handbook of Enumerative
Combinatorics, M. B\'{o}na (ed.), Discrete Math. and Its Appl., CRC Press,
Boca Raton-London-New York, 2015, pp. 589--678.\newline\url{https://arxiv.org/abs/1503.05930v3}

\bibitem[Loehr17]{Loehr-2ed}%
\href{https://www.routledge.com/Combinatorics/Loehr/p/book/9781498780254}{Nicholas
A. Loehr, \textit{Combinatorics}, 2nd edition, CRC Press 2017.}

\bibitem[Pak15]{Pak15}%
\href{https://www.math.ucla.edu/~pak/papers/cathist4.pdf}{Igor Pak,
\textit{History of Catalan numbers}, an appendix to Richard Stanley, Catalan
Numbers, Cambridge Univ. Press, 2015, pp. 177--189.}

\bibitem[Reiner05]{Reiner05}Victor Reiner, \textit{An old, but cute, proof of
the Catalan formula}, 2005.\newline\url{https://www-users.cse.umn.edu/~reiner/Papers/MessingCatalan.pdf}

\bibitem[Renaul07]{Renaul07}%
\href{https://webspace.ship.edu/msrenault/ballotproblem/Four Proofs of the Ballot Theorem.pdf}{Marc
Renault, \textit{Four Proofs of the Ballot Theorem}, Mathematics Magazine
\textbf{80} (2007), no. 5, pp. 345--352}.

\bibitem[Roman15]{Roman15}%
\href{https://doi.org/10.1007/978-3-319-22144-1}{Steven Roman, \textit{An
Introduction to Catalan Numbers}, Birkh\"{a}user 2015}.

\bibitem[Singma78]{Singma78}%
\href{https://doi.org/10.1080/00029890.1978.11994597}{David Singmaster,
\textit{An Elementary Evaluation of the Catalan Numbers}, The American
Mathematical Monthly \textbf{85}, 1978, issue 5, pp. 366--368.}

\bibitem[Stanle15]{Stanle15}%
\href{https://doi.org/10.1017/CBO9781139871495}{Richard P. Stanley,
\textit{Catalan Numbers}, 1st edition 2015}.\newline See
\url{http://math.mit.edu/~rstan/catalan/} for errata.

\bibitem[WarZud19]{WarZud19}\href{https://arxiv.org/abs/1909.07045v1}{S. Ole
Warnaar, Wadim Zudilin, $\mathit{q}$\textit{-rious and }$\mathit{q}%
$\textit{-riouser}, arXiv:1909.07045v1}.
\end{thebibliography}


\end{document}