\documentclass[amsthm]{elsart}
%\usepackage{yjsco}
\usepackage{natbib,url}
\usepackage{amsmath,amssymb,bbm}
\usepackage{tikz}
\usetikzlibrary{arrows}
\usetikzlibrary{cd}
\usepackage[all]{xy}

\newtheorem{theorem}{Theorem}[section]
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{corollary}[theorem]{Corollary}
\theoremstyle{definition}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{example}[theorem]{Example}
\theoremstyle{remark}
\newtheorem{remark}[theorem]{Remark}

\newcommand{\bq}[2]{\beta_{#1}^{(#2)}}
\newcommand{\C}{\mathcal{C}}
\newcommand{\cocoa}{\textsc{CoCoA}}
\newcommand{\cocoalib}{\textsc{CoCoALib}}
\newcommand{\ev}{\mathbf{e}}
\newcommand{\F}{\mathcal{F}}
\newcommand{\fv}{\mathbf{f}}
\newcommand{\G}{\mathcal{G}}
\newcommand{\gv}{\mathbf{g}}
\renewcommand{\H}{\mathcal{H}}
\newcommand{\hv}{\mathbf{h}}
\newcommand{\I}{\mathcal{I}}
\newcommand{\kv}{\mathbf{k}}
\newcommand{\kk}{\mathbbm{k}}
\newcommand{\lspan}[1]{\langle{#1}\rangle}
\newcommand{\ellv}{\boldsymbol{\ell}}
\newcommand{\M}{\mathcal{M}}
\newcommand{\mf}{\mathfrak{m}}
\newcommand{\mv}{\mathbf{m}}
\newcommand{\nv}{\mathbf{n}}
\newcommand{\mult}[2]{\X_{#1}(#2)}
\newcommand{\nmult}[2]{\overline{\X}_{#1}(#2)}
\renewcommand{\P}{\mathcal{P}}
\renewcommand{\S}{\mathcal{S}}
\newcommand{\Sv}{\mathbf{S}}
\newcommand{\syz}[2]{\mathrm{Syz}^{#1}{(#2)}}
\newcommand{\ten}{\otimes}
\newcommand{\U}{\mathcal{U}}
\newcommand{\V}{\mathcal{V}}
\newcommand{\vv}{\mathbf{v}}
\newcommand{\W}{\mathcal{W}}
\newcommand{\wv}{\mathbf{w}}
\newcommand{\X}{\mathcal{X}}
\newcommand{\ZZ}{\mathbbm{Z}}

\DeclareMathOperator{\cls}{cls}
\DeclareMathOperator{\codim}{codim}
\DeclareMathOperator{\crt}{crit}
\DeclareMathOperator{\im}{im}
\DeclareMathOperator{\lt}{lt}
\DeclareMathOperator{\ncrt}{ncrit}
\DeclareMathOperator{\nf}{nf}
\DeclareMathOperator{\pd}{pd}
\DeclareMathOperator{\reg}{reg}
\DeclareMathOperator{\supp}{supp}


\begin{document}
\begin{frontmatter}
\title{On the Free Resolution Induced by a Pommaret Basis}
\author[imka]{Mario Albert}
\ead{albert@mathematik.uni-kassel.de}
\author[imka]{Matthias Fetzer}
\ead{fetzer@mathematik.uni-kassel.de}
\author[rio]{Eduardo S\'aenz-de-Cabez\'on}
\ead{eduardo.saenz-de-cabezon@unirioja.es}
\author[imka]{Werner M. Seiler}
\ead{seiler@mathematik.uni-kassel.de}
\ead[url]{\url{www.mathematik.uni-kassel.de/~seiler}}
\address[imka]{Institut f\"ur Mathematik, Universit\"at Kassel, 34132 Kassel,
  Germany}
\address[rio]{Universidad de la Rioja, Logro\~no, Spain}
\begin{abstract}
  We combine the theory of Pommaret bases with a (slight generalisation of a)
  recent construction by Sk\"oldberg based on discrete Morse theory.  This
  combination allows us the explicit determination of a (generally
  non-minimal) free resolution for a graded polynomial module with the
  computation of only one Pommaret basis.  If only the Betti numbers are
  needed, one can considerably simplify the computations by determining only
  the constant part of the differential.  For the special case of a
  quasi-stable monomial ideal, we show that the induced resolution is a
  mapping cone resolution.  We present an implementation within the
  \cocoalib{} and test it with some common benchmark ideals.
\end{abstract}
\begin{keyword}
  Free resolutions; syzygies; Betti numbers; Pommaret bases; algebraic
  discrete Morse theory; mapping cones
\end{keyword}
\end{frontmatter}


\section{Introduction}

Free resolutions are of fundamental importance in commutative algebra and
algebraic geometry.  In particular, the minimal free resolution of a
homogeneous polynomial ideal encodes much relevant information about the ideal
and is related to many important invariants like the Betti numbers.  However,
the explicit determination of the minimal free resolution (or in fact of any
free resolution) is a computationally demanding task and only for certain
special cases closed-form expressions for a resolution are known.  Most
algorithms presented in the literature follow either a vertical or a
horizontal strategy, i.\,e.\ they construct the resolution either one
homological degree after the other or they proceed according to the symmetric
degree.  Discussions can be found in \citep{kr:cca2} or \citep{lss:minres}.

\citet{wms:comb2} showed that the (revlex) Pommaret basis of a polynomial
ideal or submodule induces a free resolution.  More precisely, via the
involutive form of the Schreyer theorem, one can read off the Pommaret basis
without any further computations the \emph{shape} of a free resolution
(leading to sharp upper bounds for the Betti numbers).  However, a closed form
of the \emph{differential} could be derived by \citet{wms:comb2} only for
quasi-stable monomial ideals.  In general, the induced resolution is not
minimal.  One obtains a minimal resolution (in generic coordinates), if and
only if the module is componentwise linear.

The free resolution induced by the Pommaret basis is highly structured
consisting of ``linear layers.''  Despite the fact that it is generally not
minimal, this structure allowed \cite{wms:comb2} to obtain important
homological invariants like the Castelnuovo-Mumford regularity or the
projective dimension from the Pommaret basis without further computations.
This article presents some new results from our ongoing analysis of this
resolution with emphasis on ``topological'' methods for its construction.

\citet{es:morse} and independently \citet{jw:morse} developed an algebraic
version of the \emph{discrete Morse theory} of \citet{rf:morse} and started to
apply it to the construction of resolutions.  More recently,
\citet{es:inlinsyz} derived the minimal free resolution for modules with
\emph{initially linear (minimal) syzygies} from a two-sided Koszul complex.
His definition of initially linear syzygies contains a minimality condition
which restricts the applicability of his results to componentwise linear
modules, but which is only needed for ensuring that the final resolution is
the minimal one.  Our first main result is that, after dropping this
condition, one can apply his construction to the Pommaret basis of a submodule
of a free module and obtains then a resolution isomorphic to the one presented
in \citep{wms:comb2}.  In particular, we show that his construction yields
then a Pommaret basis of each syzygy module.  Thus combining Sk\"oldberg's
work with Pommaret bases makes it fully effective and applicable to arbitrary
finitely presented polynomial modules, as the Pommaret bases lead
automatically to initially linear syzygies whereas in Sk\"oldberg's work even
the existence of such a presentation remains an open question.

In algebraic geometry it often suffices to obtain the (bigraded) Betti
numbers; the whole resolution is not really needed.  Our second main result
consists of showing that it is possible to extract directly the constant part
of Sk\"oldberg's differential without determining the remainder of the
resolution.  Then the determination of the Betti numbers is reduced to linear
algebra over the ground field.  This approach yields an algorithm which seems
to be faster than any other proposed in the literature so far.

For arbitrary \emph{monomial} ideals, a free resolution in closed form was
e.\,g.\ provided by \citet{dt:res}.  However, the problem of giving a closed
form minimal resolution for arbitrary monomial ideals is wide open and
different approaches to it have produced many interesting results, see e.\,g.\
\citep{MS04}.  One line of research in this area studies the minimal free
resolution of particular families of monomial ideals.  A seminal result in
this respect is the minimal resolution of stable ideals found by
\citet{ek:res}.

Pommaret bases only exist in generic coordinates.  For polynomial ideals, this
is not a fundamental problem.  However, in the case of monomial ideals, the
required coordinate transformations generally destroy the monomiality.  This
observation leads to the class of \emph{quasi-stable ideals} as those monomial
ideals possessing a monomial Pommaret basis.  In the literature, these ideals
have been called ideals of nested type by \citet{bg:scmr}, ideals of Borel
type by \citet{hpv:ext} or weakly stable ideals by \citet{cs:reg}.  Stable
ideals are now those monomial ideals where already the minimal basis is the
Pommaret basis \citep{mall:pom}.  In this case, the resolution induced by the
Pommaret basis is the Eliahou-Kervaire resolution, i.\,e.\ the minimal one.
For arbitrary quasi-stable ideals, the induced resolution is very similar to
the Eliahou-Kervaire resolution, but no longer minimal.

Another approach to the construction of---generally non-minimal---resolutions
that can be used for any monomial ideal consists of iterated \emph{mapping
  cones} and has been studied by various authors like \citet{ec:rescones} or
\citet{ht:rescones}.  In particular, it was shown that both the
Eliahou-Kervaire and the Taylor resolution can be obtained this way.  Our
third main result is that this is also the case for the resolutions of
quasi-stable ideals induced by their Pommaret bases.  The proof is based on
the recent observation \citep{wms:quasigen} that the notion of linear
quotients introduced by \citet{ht:rescones} is closely related to Pommaret
bases and the construction of a contracting homotopy for polynomial
resolutions via Gr\"obner bases \citep{wms:taylor}.

Section \ref{sec:pombas} briefly reviews Pommaret bases and describes the free
resolution induced by them.  The following section gives a brief survey over
algebraic discrete Morse theory and presents Sk\"oldberg's construction of a
resolution for modules with initially linear syzygies.  In Section
\ref{sec:skoeldpomm}, we combine this construction with the theory of Pommaret
bases and show that the two resolutions are isomorphic.  The next section
discusses a special case where the differential becomes much simpler and which
includes in particular monomial ideals.  Section \ref{sec:cocoa} describes our
implementation in \cocoa{} and discusses the efficient determination of Betti
numbers.  In Section \ref{sec:monom}, we specialise to quasi-stable monomial
ideals and show that here the Pommaret basis induces an iterated mapping cone
resolution.  Finally, some conclusions are given.


\section{Pommaret Bases and the Induced Resolution}
\label{sec:pombas}

Involutive bases are Gr\"obner bases with additional combinatorial properties.
They were introduced by \citet{gb:invbas,gb:minbas} who combined Gr\"obner
bases with ideas from the algebraic theory of partial differential equations
\citep{ja:lec,riq:edp}---see also related earlier works by \cite{ma:applweier}
and \cite{wu:invbas}.  A survey over their basic theory can be found in
\citep{wms:comb1} or \citep[Chapts.~3/4]{wms:invol}.  Pommaret bases represent
a special case which has turned out to be particularly useful in the context
of algebraic geometry, as the (revlex) Pommaret basis of an ideal reflects
many of its algebraic and homological properties---see \citep{wms:comb2} or
\citep[Chapt.~5]{wms:invol}.

Throughout this work, $\kk$ denotes a sufficiently large (preferably infinite)
field of arbitrary characteristic and $\P=\kk[x_{1},\dots,x_{n}]=\kk[\X]$ the
polynomial ring in $n$ variables over $\kk$ together with the standard
grading.  For notational simplicity, we will present much of the theory for a
homogeneous ideal $0\neq\I\lhd\P$ but everything extends straightforwardly to
a graded submodule $0\neq\U\subseteq\P^{t}$.  The homogeneous maximal ideal is
denoted by $\mf=\lspan{x_{1},\dots,x_{n}}$.  In contrast to the standard
conventions, we define the reverse lexicographic order for two terms of the
same degree by $x^{\mu}\prec_{\mathrm{revlex}} x^{\nu}$, if the first
non-vanishing entry of $\mu-\nu$ is positive (this corresponds to reverting
the ordering of the variables compared with the standard definition and thus
is equivalent).  If not explicitly stated otherwise, we always use revlex and
in the module case its TOP lift.

Given an exponent vector $\mu=[\mu_{1},\dots,\mu_{n}]\neq0$ (or the term
$x^{\mu}$ or a polynomial $f\in\P$ with $\lt{f}=x^{\mu}$ for some fixed term
order), we call $\min{\{i\mid\mu_{i}\neq0\}}$ the \emph{class} of $\mu$ (or
$x^{\mu}$ or $f$), denoted by $\cls{\mu}$ (or $\cls{x^{\mu}}$ or
$\cls{f}$). Then the \emph{multiplicative variables} of $x^{\mu}$ or $f$ are
$\mult{P}{x^{\mu}}=\mult{P}{f}=\{x_{1},\dots,x_{\cls{\mu}}\}$; the remaining
variables are the \emph{non-multiplicative ones}
$\nmult{P}{f}=\X\setminus\mult{P}{f}$.  We say that $x^{\mu}$ is an
\emph{involutive divisor} of another term $x^{\nu}$, if $x^{\mu}\mid x^{\nu}$
and $x^{\nu-\mu}\in\kk[x_{1},\dots,x_{\cls{\mu}}]$.  Given a finite set
$\F\subset\P$, we write $\deg{\F}$ for the maximal degree and $\cls{\F}$ for
the minimal class of an element of $\F$.

\begin{definition}\label{def:pombas}
  Assume first that the finite set $\H\subset\P$ consists only of terms.  $\H$
  is a \emph{Pommaret basis} of the monomial ideal $\I=\lspan{\H}$, if as a
  $\kk$-linear space
  \begin{equation}\label{eq:pombas}
    \bigoplus_{h\in\H}\kk[\mult{P}{h}]\cdot h=\I
  \end{equation}
  (in this case each term $x^{\nu}\in\I$ has a unique involutive divisor
  $x^{\mu}\in\H$).  A finite polynomial set $\H$ is a \emph{Pommaret basis} of
  the polynomial ideal $\I$ for the term order $\prec$, if all elements of
  $\H$ possess distinct leading terms and these terms form a Pommaret basis of
  the leading ideal $\lt{\I}$.
\end{definition}

As the simple example $\I=\lspan{x_{1}x_{2}}\lhd\kk[x_{1},x_{2}]$
demonstrates, not every ideal possesses a finite Pommaret basis.  One can show
that this is solely a problem of the used coordinate system: in generic
coordinates, every ideal has a finite Pommaret basis.  A deterministic
approach for constructing ``good'' coordinates can be found in
\citep{wms:delta}.  In the sequel, we always assume that such coordinates have
been chosen.  A monic, involutively autoreduced Pommaret
basis is unique \citep{gb:minbas}.

It is well-known that Pommaret bases can be characterised similarly to
Gr\"obner bases \citep{apel:hilbert,gb:invbas}.  However, \emph{involutive
  standard representations}, i.\,e.\ standard representation where each
coefficient contains only multiplicative variables for the corresponding
generator, are unique.  The $S$-polynomials in the theory of Gr\"obner bases
are replaced by products of the generators with one of their
\emph{non}-multiplicative variables.

\begin{proposition}{\cite[Thm.~5.4]{wms:comb1}}\label{prop:pbisr}
  The finite set $\H\subset\I$ is a Pommaret basis of the ideal $\I\lhd\P$ for
  the term order $\prec$, if and only if every polynomial $0\neq f\in\I$
  possesses a unique involutive standard representation
  $f=\sum_{h\in\H}P_{h}h$ where each non-zero coefficient
  $P_{h}\in\kk[\mult{P}{h}]$ satisfies $\lt{(P_{h}h)}\preceq\lt{(f)}$.
\end{proposition}

\begin{proposition}{\cite[Cor.~7.3]{wms:comb1}}\label{prop:pbcrit}
  Let $\H\subset\P$ be a finite set of polynomials and $\prec$ a term order
  such that no leading term in $\lt{\H}$ is an involutive divisor of another
  one.  The set $\H$ is a Pommaret basis of the ideal $\langle\H\rangle$ with
  respect to $\prec$, if and only if for every $h\in\H$ and every
  non-multiplicative index $\cls{h}<j\leq n$ the product $x_{j}h$ possesses an
  involutive standard representation with respect to $\H$.
\end{proposition}

The classical Schreyer Theorem \citep{fos:syz} describes how every Gr\"obner
basis induces a Gr\"obner basis of its syzygy module for a suitable chosen
term order.  If $\H=\{\hv_{1},\dots,\hv_{s}\}\subset\P^{t}$ is a finite subset
and $\prec$ a term order on $\P^{t}$, then the \emph{Schreyer order}
$\prec_{\H}$ is the term order on $\P^{s}$ defined by
$x^{\mu}\ev_{\alpha}\prec_{\H}x^{\nu}\ev_{\beta}$, if
$\lt{(x^{\mu}\hv_{\alpha})}\prec\lt{(x^{\nu}\hv_{\beta})}$ or if these leading
terms are equal and $\beta<\alpha$.

Obviously, the Schreyer order $\prec_{\H}$ depends on the ordering of the
elements of the set $\H$.  For the involutive version of the Schreyer Theorem,
we must order the elements of the Pommaret basis in a suitable manner.  For
this purpose, we recall some notions from \citep{wms:comb2}.  We associate a
directed graph with each Pommaret basis $\H$.  Its vertices are given by the
elements in $\H$.  If $x_{j}\in\nmult{\H,\prec}{\hv}$ for some generator
$\hv\in\H$, then, by definition of a Pommaret basis, $\H$ contains a unique
generator $\bar\hv$ such that $\lt{\bar\hv}$ is an involutive divisor of
$\lt{(x_j\hv)}$.  In this case we include a directed edge from $\hv$ to
$\bar\hv$.  The thus defined graph is called the \emph{$P$-graph} of the
Pommaret basis $\H$.  We order the elements of $\H$ as follows: whenever the
$P$-graph of $\H$ contains a path from $\hv_{\alpha}$ to $\hv_{\beta}$, then
we must have $\alpha<\beta$.  Any ordering satisfying this condition is called
a \emph{$P$-ordering}.  An explicit $P$-ordering can be described as follows:
we require that if either $\cls{\hv_\alpha}<\cls{\hv_\beta}$ or
$\cls{\hv_\alpha}=\cls{\hv_\beta}=k$ and and the last non-vanishing entry of
$\lt{\hv_\alpha}-\lt{\hv_\beta}$ is negative, then we must have
$\alpha<\beta$.  Thus we sort the generators $\hv_\alpha$ first by their class
and within each class lexicographically (according to our ``reverse''
conventions).

Assume that $\H=\{\hv_{1},\dots,\hv_{s}\}$ is a Pommaret basis of
$\U$.  According to Proposition \ref{prop:pbcrit}, for every
non-multiplicative variable $x_{k}$ of a generator $\hv_{\alpha}$ we have an
involutive standard representation
$x_{k}\hv_{\alpha}=\sum_{\beta=1}^{s}P^{(\alpha;k)}_{\beta}\hv_{\beta}$ and
thus a syzygy
\begin{equation}\label{eq:syzka}
  \Sv_{\alpha;k}=x_{k}\ev_{\alpha}-\sum_{\beta=1}^{s}P^{(\alpha;k)}_{\beta}\ev_{\beta}
\end{equation}
where $\{\ev_{1},\dots,\ev_{s}\}$ denotes the standard basis of $\P^{s}$.  Let
$\H_{\mathrm{Syz}}$ be the set of all these syzygies.

\begin{lemma}{\cite[Lemma~5.7]{wms:comb2}}\label{lem:ltsyzka}
  If the Pommaret basis $\H$ is $P$-ordered, then for all admissable values of
  $\alpha$ and $k$ we find with respect to the Schreyer order $\prec_{\H}$ that
  \begin{equation}\label{eq:ltsyzka}
    \lt{\Sv_{\alpha;k}}=x_{k}\ev_{\alpha}\,.
  \end{equation}
\end{lemma}

\begin{theorem}{\cite[Thm.~5.10]{wms:comb2}}\label{thm:pomschreyer}
  Let $\H$ be a $P$-ordered Pommaret basis of the polynomial submodule
  $\U\subseteq\P^{t}$.  Then $\H_{\mathrm{Syz}}$ is a Pommaret basis of
  $\syz{}{\H}$ with respect to the Schreyer order $\prec_{\H}$.
\end{theorem}

Like the classical Schreyer Theorem, we can iterate Theorem
\ref{thm:pomschreyer} and obtain then a free resolution of the submodule
$\U$.\footnote{Related results were obtained earlier by \cite{ma:applweier}
  who uses the terminology \emph{Weierstra\ss{} basis} instead of Pommaret
  basis.}  However, in constrast to the classical situation, the involutive
version yields the full shape of the arising resolution without any further
computations.  We present here a bigraded version of this result which is
obtained by a trivial extension of the arguments in \citep{wms:comb2}.  It
provides sharp upper bounds for the Betti numbers of $\U$.

\begin{theorem}{\cite[Thm.~6.1]{wms:comb2}}\label{thm:hilsyzpom}
  Let $\H$ be the Pommaret basis of the polynomial submodule
  $\U\subseteq\P^{t}$.  If we denote by $\bq{0,j}{k}$ the number of generators
  $\hv\in\H$ such that $\deg{\hv}=j$ and $\cls{\lt{\hv}}=k$ and by
  $d=\min\,\{k\mid\exists j:\bq{0,j}{k}>0\}$ the minimal class of a generator,
  then $\U$ possesses a finite free resolution
  \begin{equation}\label{eq:pomres}
    0\longrightarrow\bigoplus\P[-j]^{r_{n-d,j}}\longrightarrow\cdots
    \longrightarrow\bigoplus\P[-j]^{r_{1,j}}
    \longrightarrow\bigoplus\P[-j]^{r_{0,j}}\longrightarrow\U\longrightarrow0
  \end{equation}
  of length $n-d$ where the ranks of the free modules are given by
  \begin{equation}\label{eq:resrank}
    r_{i,j}=\sum_{k=1}^{n-i}\binom{n-k}{i}\bq{0,j-i}{k}\;.
  \end{equation}
\end{theorem}

For the proof of this result, one shows that the Pommaret basis $\H_{j}$ of
the $j$th syzygy module $\syz{j}{\H}$ with respect to the Schreyer order
$\prec_{\H_{j-1}}$ consists of the syzygies $\Sv_{\alpha;\kv}$ with an ordered
integer sequence $\kv=(k_{1},\dots,k_{j})$ where
$\cls{h_{\alpha}}<k_{1}<\cdots<k_{j}\leq n$.  These syzygies are defined
recursively.  We denote for any $1\leq i\leq j$ by $\kv_{i}$ the sequence
obtained by eliminating $k_{i}$ from $\kv$.  Now $\Sv_{\alpha;\kv}$ arises
from the involutive standard representation of
$x_{k_{j}}\Sv_{\alpha;\kv_{j}}$:
\begin{equation}\label{eq:highSyz}
  x_{k_{j}}\Sv_{\alpha;\kv_{j}}=
      \sum_{\beta=1}^p\sum_{\ellv} P_{\beta;\ellv}^{(\alpha;\kv)} \Sv_{\beta;\ellv}\;.
\end{equation}
Here the second sum is over all ordered integer sequences $\ellv$ of length
$j-1$ satisfying $\cls{\hv_\beta}<\ell_1<\cdots<\ell_{j-1}\leq n$.  Lemma
\ref{lem:ltsyzka} implies that
\begin{equation}\label{eq:ltsyzkja}
  \lt{\Sv_{\alpha;\kv}}=x_{k_{j}}\ev_{\alpha;\kv_{j}}
\end{equation}
---leading by a simple combinatorial computation to the ranks $r_{i,j}$---and
that the coefficient $P_{\beta;\ellv}^{(\alpha;\kv)}$ lies in
$\kk[x_{1},\dots,x_{\ell_{j-1}}]$.

One can furthermore show that the free resolution (\ref{eq:pomres}) is of
minimal length (i.\,e.\ $\pd{\U}=n-d$) \cite[Thm.~8.11]{wms:comb2} and that
$\reg{\U}=\deg{\H}$ \cite[Thm.~9.2]{wms:comb2}.  Nevertheless, it is generally
not minimal.  Assuming that we are in generic coordinates (more precisely, in
\emph{componentwise $\delta$-regular} coordinates
\cite[Def.~18]{wms:quasigen}), one can show \citep[Thm.~9.12]{wms:comb2} that
it is minimal, if and only if $\U$ is componentwise linear (see
\citep{hh:complin} for a definition of this notion).  We also note that it is
minimal, if and only if the first syzygies $\Sv_{\alpha;k}$ do not contain
constants \citep[Lemma~8.1]{wms:comb2}.  These observations lead to a simple
effective criterion for componentwise linearity.

For later use, we give an alternative description of the complex underlying
the resolution (\ref{eq:pomres}).  Let $\W=\bigoplus_{\alpha=1}^{s}
\P\wv_{\alpha}$ and $\V=\bigoplus_{i=1}^{n} \P\vv_{i}$ be two free
$\P$-modules whose ranks are given by the size of the Pommaret basis $\H$ and
by the number of variables in $\P$, respectively.  Then we set
$\C_{i}=\W\otimes_{\P}\Lambda_{i}\V$ where $\Lambda_{\bullet}$ denotes the
exterior product.  A $\P$-linear basis of $\C_{i}$ is provided by the elements
$\wv_{\alpha}\otimes\vv_{\kv}$ where
$\vv_{\kv}=\vv_{k_{1}}\wedge\cdots\wedge\vv_{k_{i}}$ for an ordered sequence
$\kv=(k_{1},\dots,k_{i})$ with $1\leq k_{1}<\cdots<k_{i}\leq n$.  Then the
free subcomplex $\S_{\bullet}\subset\C_{\bullet}$ generated by all elements
$\wv_{\alpha}\otimes\vv_{\kv}$ with $\cls{h_{\alpha}}<k_{1}$ corresponds to
(\ref{eq:pomres}) upon the identification $\ev_{\alpha;\kv}\leftrightarrow
\wv_{\alpha}\otimes\vv_{\kv}$.  The differential comes from
(\ref{eq:highSyz}),
\begin{equation}\label{eq:diffS}
  d_{\S}(\wv_{\alpha}\otimes\vv_{\kv,k_{j+1}})=
     x_{k_{j+1}} \wv_\alpha\otimes\vv_{\kv}-
     \sum_{\beta,\ellv} P_{\beta;\ellv}^{(\alpha;\kv,k_{j+1})}
            \wv_\beta\otimes\vv_{\ellv}\;,
\end{equation}
and thus requires the explicit determination of all the higher syzygies
(\ref{eq:highSyz}).


\section{Algebraic Discrete Morse Theory and Sk\"oldberg's
  Resolution}
\label{sec:morse}

Algebraic discrete Morse theory was mainly developed by \citet{es:morse} and
by \citet{jw:morse}.  It provides techniques to reduce a large complex to a
smaller one with the same homology.  We briefly recall the main concepts; for
further details and proofs we refer to the above cited works.

We consider a finite chain complex $C_\bullet$ of $\P$-modules 
\begin{equation}
  0 \longrightarrow C_p \longrightarrow C_{p-1} \longrightarrow\cdots
  \longrightarrow C_0 \longrightarrow 0
\end{equation}
where each module $C_m = \bigoplus_{a\in I_m} K_a$ is written as a direct sum
of $\kk$-linear spaces with disjoint index sets $I_m$ (Sk\"oldberg calls this
a \emph{based complex}).  To such a complex, we associate a directed graph
$\Gamma_{C_\bullet}$.  The set of vertices is $V=\sqcup_m I_m$ and the graph
contains the edge $a\rightarrow b$ if and only if $a\in I_{m+1}$, $b\in I_m$
and $d_{b,a}= \pi_b (d_{C}|_{{K_a}}) \not= 0$ where $d_C$ is the differential
in $C_\bullet$ and $\pi_b:C_m=\bigoplus_{c\in I_m}K_c \rightarrow K_b$ for
$b\in I_m$ the canonical projection.

A \emph{partial matching} on a directed graph $D= (V,E)$ with vertices $V$ and
edges $E$ is a subset $A\subseteq E$ of edges such that any vertex is incident
to at most one edge in $A$.  For such a partial matching $A$, we define a new
directed graph $D^A=(V,E^A)$ by reversing all the arrows contained in $A$:
thus the graph $D^A$ has the same vertices as $D$ and it contains the edge
$a\rightarrow b$ if and only if $(b \rightarrow a) \in A \vee \bigl((a
\rightarrow b) \in E \wedge (a\rightarrow b) \not\in A\bigr)$.  We define $A^+
\subseteq V$ to be the subset of those vertices that are the targets of the
reversed arrows in $A$ and $A^- \subseteq V$ as their sources; finally
$A^0\subseteq V$ contains all vertices which are not incident to any reversed
arrow.

\begin{definition}
  A \emph{Morse matching} on the directed graph $\Gamma_{C_\bullet}$ is a
  partial matching $A$ satisfying the following conditions:
  \begin{itemize}
  \item For every edge $a\rightarrow b$, the map $d_{b,a}$ is an isomorphism.
  \item Every index set $I_m$ possesses a well-founded partial order $\prec$
    such that for any $a,c \in I_m$ for which there is a path $a\rightarrow b
    \rightarrow c$ in $\Gamma_{C_\bullet}^A$ we have $c\prec a$.  We say that
    such an order $\prec$ \emph{respects the Morse matching} $A$.
  \end{itemize}
\end{definition}

The goal is to reduce the complex $C_\bullet$ to a smaller complex with the
same homology using a Morse matching $A$.  For the definition of the
differential in the smaller complex, we will use \emph{reduction paths} in
$\Gamma_{C_\bullet}^A$.  An \emph{elementary reduction path} is a ``zig-zag''
path $\alpha_0 \rightarrow \beta \rightarrow \alpha_1$ of length two in
$\Gamma_{C_\bullet}^A$ with $\alpha_0, \alpha_1 \in I_m$ that also satisfies
\begin{displaymath}
  \beta \in I_{m-1} \Longleftrightarrow \alpha_0 \in A^0 \cup A^+
  \quad\text{and}\quad
  \beta \in I_{m+1} \Longleftrightarrow \alpha_0 \in A^-\,.
\end{displaymath}
Note that there are also paths $\alpha_0 \rightarrow \beta \rightarrow
\alpha_1$ of length two in the graph $\Gamma_{C_\bullet}^A$ with $\alpha_0,
\alpha_1 \in I_m$ which are \emph{not} elementary reduction paths: a path with
$\beta \in I_{m-1}$ and $\alpha_0 \in A^-$ is considered by Sk\"oldberg not as
an elementary reduction path; we will see later that it would not make any
difference to include them.  For the elementary reduction path $\alpha_0
\rightarrow \beta \rightarrow \alpha_1$, we define the corresponding
\emph{elementary reduction} as the map
\begin{displaymath}
  \rho_{\alpha_1, \alpha_0} =
  \begin{cases}
    -d_{\beta, \alpha_1}^{-1} \circ d_{\beta, \alpha_0}  & 
        \mbox{if } \beta \in I_{m-1}\,,\\ 
    -d_{\alpha_1, \beta} \circ d_{\alpha_0, \beta}^{-1} & 
        \mbox{if } \beta \in I_{m+1}\,.
  \end{cases}
\end{displaymath}

A \emph{(general) reduction path} $p$ is a composition of elementary reduction
paths
\begin{displaymath}
  p=\alpha_0 \rightarrow \beta_1 \rightarrow \alpha_1 \rightarrow \cdots
    \rightarrow \beta_q \rightarrow \alpha_q
\end{displaymath}
where $q\geq 0$.  For two indices $\alpha, \alpha^* \in I_m$, there may exist
several reduction paths from $\alpha$ to $\alpha^*$; we write $[\alpha
\rightsquigarrow \alpha^*]$ for the set of all such paths.  For a general
reduction path $p$, the \emph{reduction} $\rho_p$ is given by
\begin{displaymath}
  \rho_p =\rho_{\alpha_q, \alpha_{q-1}} \circ \rho_{\alpha_{q-1},
    \alpha_{q-2}} \circ \cdots \circ \rho_{\alpha_1, \alpha_0}\,.
\end{displaymath}

\begin{definition}\label{def:ils}
  A graded polynomial module $\M$ has \emph{initially linear syzygies}, if
  $\M$ possesses a finite presentation
  \begin{equation}\label{eq:linsyz}
    0 \longrightarrow \ker{\eta} \longrightarrow 
    \W=\bigoplus_{\alpha=1}^{s} \P\wv_{\alpha}
    \stackrel{\eta}{\longrightarrow} \M \longrightarrow 0
  \end{equation}
  such that with respect to some term order $\prec$ on the free module $\W$
  the leading module $\lt{\ker{\eta}}$ is generated by terms of the form
  $x_{j}\wv_{\alpha}$.  We say that $\M$ has \emph{initially linear minimal
    syzygies}, if the presentation is minimal in the sense that
  $\ker{\eta}\subseteq\mf^{s}$.
\end{definition}

These notions go back to \cite{es:inlinsyz} who, however, does not consider
the non-minimal case.  In his work ``initially linear syzygies'' always means
initially linear \emph{minimal} syzygies.  His construction begins with the
following two-sided Koszul complex $(\F,d_{\F})$ defining a free resolution of
the module $\M$.  Let $\V$ be a $\kk$-linear space with basis
$\{\vv_{1},\dots,\vv_{n}\}$ (with $n$ still the number of variables) and set
$\F_{j}=\P\otimes_{\kk}\Lambda_{j}\V\otimes_{\kk}\M$ which obviously yields a
free $\P$-module.  Choosing a $\kk$-linear basis $\{m_{a}\mid a\in A\}$ of
$\M$, a $\P$-linear basis of $\F_{j}$ is given by the elements $1\otimes
v_{\kv}\otimes m_{a}$ with ordered sequences $\kv$ of length $j$.  The
differential is now defined by
\begin{equation}\label{eq:diffF}
  d_{\F}(1\otimes\vv_{\kv}\otimes m_{a})=
  \sum_{i=1}^{j}(-1)^{i+1}\bigl(x_{k_{i}}\otimes\vv_{\kv_{i}}\otimes m_{a}-
                             1\otimes\vv_{\kv_{i}}\otimes x_{k_{i}}m_{a}\bigr)
\end{equation}
where $\kv_{i}$ denotes the sequence $\kv$ without the element $k_{i}$.  Here
it should be noted that the second term on the right hand side is not yet
expressed in the chosen $\kk$-linear basis of $\M$.  For notational
simplicity, we will drop in the sequel the tensor sign $\otimes$ and leading
factors $1$ when writing elements of $\F_{\bullet}$.

Under the assumption that the module $\M$ has initially linear syzygies via a
presentation (\ref{eq:linsyz}), \cite{es:inlinsyz} constructs a Morse matching
leading to a smaller resolution $(\G,d_{\G})$.  He calls the variables
\begin{equation}\label{eq:crit}
  \crt{(\wv_{\alpha})}=\{x_{j}\mid x_{j}\wv_{\alpha}\in\lt{\ker{\eta}}\}\,;
\end{equation}
\emph{critical} for the generator $\wv_{\alpha}$; the remaining
\emph{non-critical} ones are contained in the set $\ncrt{(\wv_{\alpha})}$.  A
$\kk$-linear basis of $\M$ is then given by all elements $x^{\mu}\hv_{\alpha}$
with $\hv_{\alpha}=\eta(\wv_{\alpha})$ and
$x^{\mu}\in\kk[\ncrt{(\wv_{\alpha})}]$.

For each module element $m\in\M$, consider the following set of vertices
in the graph $\Gamma_{F_\bullet}$:
\begin{equation}
  V_m=\bigl\{ \vv_Ix^\mu \hv_\alpha\mid x^Ix^\mu \hv_\alpha=m\wedge 
              x^{\mu}\in\kk[\ncrt{\wv_{\alpha}}]\bigr\}\;.
\end{equation}
Then $V_m$ is not empty, if and only if $m$ is the product of some generator
$\hv_\alpha$ with a monomial.  Furthermore, we define
\begin{multline}\label{eq:matching}
  A_m=\bigl\{\vv_Ix^\mu\hv_\alpha \rightarrow \vv_{I\setminus i}x_ix^\mu
             \hv_\alpha\in \Gamma_{\F}|_{V_m}\mid \\
      i=\min{\{I \cap \ncrt{(\wv_\alpha)}\}} \land 
      i \leq \cls{ (x^\mu)}\bigr\}\,.
\end{multline}
\citet{es:inlinsyz} gives a slightly different definition for the sets $A_m$;
however, we think that our definition is more precise.  By \citep[Lemma
2]{es:inlinsyz}, the union $A=\bigcup_{m\in \M} A_m$ is a Morse matching on
the graph $\Gamma_{\F_\bullet}$.  A vertex $\vv_\kv \hv_\alpha$ is not
contained in $A$, if and only if $\kv \subseteq \crt{ (\wv_\alpha)}$; in
particular, all vertices of the form $\vv_I x^\mu \hv_\alpha$ with $\mu
\not=0$ appear in this Morse matching.  We now define $\G_{j}\subseteq\F_{j}$
as the free submodule generated by those vertices $\vv_{\kv}\hv_{\alpha}$
where the ordered sequences $\kv$ are of length $j$ and such that every entry
$k_{i}$ is critical for $\wv_{\alpha}$.  In particular, $\W\cong\G_{0}$ with
an isomorphism induced by $\wv_{\alpha}\mapsto\vv_{\emptyset}\hv_{\alpha}$.

\citet{es:inlinsyz} gives two descriptions of the differential $d_{\G}$ in the
reduced complex, a recursive one and an explicit one.  For our purposes, the
explicit one is better suited.  It is based on reduction paths in the
associated Morse graph and expresses the differential as a triple sum.  If we
assume that after expanding the right hand side of (\ref{eq:diffF}) in the
chosen $\kk$-linear basis of $\M$ the differential of the complex
$\F_{\bullet}$ can be expressed as
\begin{equation} \label{eq:diffFka}
  d_{\F}(\vv_{\kv}\hv_{\alpha})=
      \sum_{\mv,\mu,\gamma} 
          Q_{\mv,\mu,\gamma}^{\kv,\alpha}\vv_{\mv} (x^{\mu}\hv_{\gamma})\,,
\end{equation}
then $d_{\G}$ is defined by
\begin{equation}\label{eq:diffG}
  d_{\G}(\vv_{\kv}\hv_{\alpha})=
      \sum_{\ellv,\beta}
          \sum_{\mv,\mu,\gamma}
              \sum_{p} \rho_{p}\bigl( Q_{\mv,\mu,\gamma}^{\kv,\alpha}
                         \vv_{\mv} (x^{\mu}\hv_{\gamma})\bigr)
\end{equation}
where the first sum ranges over all ordered sequences $\ellv$ which consists
entirely of critical indices for $\wv_{\beta}$ and the second sum may be
restricted to all values such that a polynomial multiple of
$\vv_{\mv}(x^{\mu}\hv_{\gamma})$ effectively appears in
$d_{\F}(\vv_{\kv}\hv_{\alpha})$ and the third sum ranges over all reduction
paths $p$ going from $\vv_{\mv}(x^{\mu}\hv_{\gamma})$ to
$\vv_{\ellv}\hv_{\beta}$.  Finally, $\rho_{p}$ is the reduction associated
with the reduction path $p$ satisfying
$\rho_{p}\bigl(\vv_{\mv}(x^{\mu}\hv_{\gamma})\bigr)=c_{p}\vv_{\ellv}\hv_{\beta}$
for some polynomial $c_{p}\in\P$.  In Appendix~\ref{app:ex}, we show for a
concrete ideal how the evaluation of \eqref{eq:diffG} works in practice.

Sk\"oldberg's main result is that $(\G,d_{\G})$ is the \emph{minimal} free
resolution of $\M$, if one starts with initially linear \emph{minimal}
syzygies.  However, independent of this minimality assumption, his
construction always yields a free resolution.  We will show in the next
section that for a submodule of a free module, his resolution is isomorphic to
the resolution induced by a Pommaret basis.


\section{Sk\"oldberg's Construction and Pommaret Bases}
\label{sec:skoeldpomm}

We now combine Sk\"oldberg's construction with Pommaret bases.  Assume that
the considered graded module is presented as $\M=\P^{t}/\U$ for a graded
submodule $\U\subseteq\P^{t}$.  Obviously, a free resolution of $\U$
immediately yields one of $\M$.  Therefore we will restrict from now to the
construction of resolutions for such submodules $\U\subseteq\P^{t}$ given by a
Pommaret basis $\H=\{\hv_{1},\dots,\hv_{s}\}$.  Unless stated otherwise, we
will always assume that any Pommaret basis is enumerated according to a
$P$-ordering.  Furthermore, we extend the notion of class to positive
homological degrees by setting $\cls{ (\vv_\kv \hv_\alpha)}= \max{\kv}$ for
elements $\vv_\kv \hv_\alpha\in \G_{|\kv|}$ with $\kv \not= \emptyset$.  As an
immediate consequence of Lemma \ref{lem:ltsyzka}, we obtain the following
trivial assertion.

\begin{lemma}\label{lem:linsyz}
  The submodule $\U\subseteq\P^{t}$ has initially linear
  syzygies\footnote{Note that we apply here Definition \ref{def:ils} directly
    to $\U$ and not to $\M=\P^{t}/\U$, i.\,e.\ in \eqref{eq:linsyz} one must
    replace $\M$ by $\U$.} for the Schreyer order $\prec_{\H}$ and
  $\crt{(\wv_{\alpha})}=\nmult{P}{\hv_{\alpha}}$, i.\,e.\ the critical
  variables of the generator $\wv_{\alpha}$ are the non-multiplicative
  variables of $\hv_{\alpha}=\eta(\wv_{\alpha})$.
\end{lemma}

\citet[Cor.~4]{es:inlinsyz} proves that a module with initially linear minimal
syzygies is always componentwise linear.  It now follows from the above
mentioned results of \citep{wms:comb2} on componentwise linearity that the
converse is also true: modulo a coordinate transformation any componentwise
linear module has initially linear minimal syzygies.

\begin{corollary}
  If the graded polynomial module $\M$ is componentwise linear, then it can be
  presented as $\M=\P^{t}/\U$ such that the submodule $\U$ has initially
  linear minimal syzygies in componentwise $\delta$-regular coordinates.
\end{corollary}

For later use, we will now distinguish three types of elementary reduction
paths $p$ in the graph $\Gamma_{\F_{\bullet}}^A$.
\begin{description}
\item[Type 0:] In this case $p$ is a path $\alpha_0 \rightarrow \beta
  \rightarrow\alpha_1$ with $\alpha_0, \alpha_1 \in I_m$ and $\beta \in
  I_{m-1}$.  We will later see that these paths are irrelevant for the
  construction of the differential $d_\G$ of the reduced complex
  $\G_{\bullet}$.
\end{description}
All other elementary reduction paths are of the form
\begin{displaymath}
  \vv_\kv (x^\mu \hv_\alpha) \longrightarrow
  \vv_{\kv\cup i} (\frac{x^\mu}{x_i} \hv_\alpha) \longrightarrow 
  \vv_{\ellv} (x^\nu \hv_\beta)\,.
\end{displaymath}
Here $\kv \cup i$ is the ordered sequence which arises when $i$ is inserted
into $\kv$; likewise $\kv \setminus i$ stands for the removal of an index $i
\in \kv$.
\begin{description}
\item[Type 1:] Here $\ellv=(\kv \cup i)\backslash j$, $x^\nu
  =\frac{x^\mu}{x_i}$ and $\beta = \alpha$.  Note that $i=j$ is allowed. We
  define $\epsilon(i; \kv )=(-1)^{|\{j\in \kv\mid j>i\}|}$.  Then the
  corresponding reduction is
  \begin{displaymath}
    \rho (\vv_\kv x^\mu \hv_\alpha) = 
        \epsilon(i; \kv \cup i) \epsilon (j; \kv\cup i) 
        x_j\vv_{(\kv\cup i)\setminus j} \bigl(\frac{x^\mu}{x_i} \hv_\alpha\bigr)\,.
  \end{displaymath}
\item[Type 2:] Now $\ellv=(\kv \cup i)\setminus j$ and $x^\nu\hv_\beta$
  appears in the involutive standard representation of $\frac{x^\mu
    x_j}{x_i}\hv_\alpha$ with the coefficient
  $\lambda_{j,i,\alpha,\mu,\nu,\beta}\in\kk$.  In this case, by construction
  of the Morse matching, we have $i\not=j$. The reduction is
  \begin{displaymath}
    \rho (\vv_\kv x^\mu \hv_\alpha) = 
        - \epsilon(i; \kv \cup i) \epsilon (j; \kv\cup i) 
        \lambda_{j,i,\alpha,\mu,\nu,\beta} 
        \vv_{(\kv\cup i)\setminus j} (x^\nu \hv_\beta)\,.
  \end{displaymath}
\end{description}

These reductions follow from the differential (\ref{eq:diffF}): the summands
appearing there are either of the form $x_{k_{i}} \vv_{\kv_{i}} m_{a}$ or of
the form $\vv_{\kv_{i}} (x_{k_{i}}m_{a})$.  For each of these summands, we
have a directed edge in the graph $\Gamma_{\F_\bullet}^A$.  Thus for an
elementary reduction path
\begin{displaymath}
  \vv_\kv(x^\mu \hv_\alpha) \longrightarrow 
  \vv_{\kv\cup i} \bigl(\frac{x^\mu}{x_i} \hv_\alpha\bigr) \longrightarrow 
  \vv_{\ellv} (x^\nu \hv_\beta)\,,
\end{displaymath}
the second edge can originate from summands of either form.  For the first
form we then have an elementary reduction path of type 1 and for the second
form we have type 2.

For completeness, we note the following simple result which shows that the
free resolution $\G$ indeed extends the presentation (\ref{eq:linsyz}) and
hence yields essentially the same first syzygies as the Pommaret basis.

\begin{lemma}\label{lem:syz1}
  For an\footnote{For notational simplicity, we will often identify sets $X$
    of variables with sets of the corresponding indices and thus simply write
    $i\in X$ instead of $x_{i}\in X$.} $i\in \crt{(\hv_\alpha)}$ let
  $x_i\hv_\alpha= \sum_{\beta=1}^s P_\beta^{(\alpha; i)} \hv_\beta$ be the
  involutive standard representation.  Then we have $d_\G (\vv_i \hv_\alpha)=
  x_i\vv_\emptyset\hv_{\alpha} -\sum_{\beta=1}^s P_\beta^{(\alpha;i)}
  \vv_\emptyset \hv_\beta$.
\end{lemma}

\begin{proof}
  Looking at the different types of reduction paths, we immediately see that
  in the differential (\ref{eq:diffG}) we can only have concatenations of
  elementary reduction paths of type 1 which are of the form
  \begin{displaymath}
    \vv_\emptyset (x^\mu \hv_\alpha) \longrightarrow
    \vv_{i} \bigl(\frac{x^\mu}{x_i} \hv_\alpha\bigr) \longrightarrow 
    \vv_\emptyset \bigl(\frac{x^\mu}{x_i} \hv_\beta\bigr)\,.
  \end{displaymath}
  The corresponding reduction is $\rho (\vv_\emptyset x^\mu \hv_\alpha) =
  x_i\vv_{\emptyset} (\frac{x^\mu}{x_i} \hv_\alpha)\,$.  As $d_\F (\vv_i
  \hv_\alpha)= x_i\vv_\emptyset \hv_\alpha -\sum_{\beta=1}^s\vv_\emptyset
  P_\beta^{(\alpha; i)} \hv_\beta$, the reduction paths move the variables in a
  way that gives us the correct reduced differential $d_\G$.
\end{proof}

Our next result states that if one starts at a vertex $\vv_i(x^\mu\hv_\alpha)$
with $i\in\ncrt{(\hv_\alpha)}$ and follows through all possible reduction
paths in the graph, one will never get to a point where one must calculate an
involutive standard representation.  If there are no critical (i.\,e.\
non-multiplicative) variables present at the starting point, then this will
not change throughout any reduction path.  In order to generalise this lemma
to higher homological degrees, one must simply replace the conditions $i\in
\ncrt{ (\hv_\alpha)}$ and $j \in \ncrt{ (\hv_\beta)}$ by ordered sequences
$\kv, \ellv$ with $\kv\subseteq \ncrt{ (\hv_\alpha)}$ and $\ellv \subseteq
\ncrt{ (\hv_\beta)}$.

\begin{lemma}\label{lem:notype2}
  Assume that $i\cup\supp{(x^{\mu})} \subseteq \ncrt{(\hv_\alpha)}$.  Then for any
  reduction path $p=\vv_i(x^\mu \hv_\alpha) \rightarrow \cdots \rightarrow
  \vv_j(x^\nu \hv_\beta)$ we have $j \in \ncrt{(\hv_\beta)}$ and
  $\beta=\alpha$.  In particular, in this situation there is no reduction path
  $p=\vv_i (x^\mu \hv_\alpha) \rightarrow \cdots \rightarrow \vv_k \hv_\beta$
  with $k \in \crt{ (\hv_\beta)}$.
 \end{lemma}

\begin{proof}
  Assume first that $p$ is an elementary reduction path.  We distinguish two
  cases depending on the position of the starting point of $p$.
  \begin{description}
  \item[Case 1:] Here $\vv_i(x^\mu \hv_\alpha) \in A^0\cup A^+$.  Then the
    elementary reduction path must be of type 0 and $p$ is either of the form
    $\vv_i(x^\mu \hv_\alpha) \rightarrow \vv_\emptyset (x_ix^\mu \hv_\alpha)
    \rightarrow \vv_{\cls(x_ix^\mu)}(\frac{x_ix^\mu}{x_{\cls
      (x_ix^\mu)}}\hv_\alpha)$ or $\vv_i(x^\mu \hv_\alpha) \rightarrow x_i
    \vv_\emptyset (x^\mu \hv_\alpha) \rightarrow x_i
    \vv_{\cls(x^\mu)}(\frac{x^\mu}{x_{\cls (x^\mu)}}\hv_\alpha)$. Since by
    assumption $i\cup\supp{(x^{\mu})} \subseteq \ncrt{(\hv_\alpha)}$, we also have
    $\cls (x_ix^\mu)\in \ncrt{ (\hv_\alpha)}$ and $\cls (x^\mu) \in \ncrt
    {(\hv_\alpha)}$, resp., as claimed.
  \item[Case 2:] If $\vv_i(x^\mu \hv_\alpha) \in A^-$, then $p$ can be either
    of type 1 or type 2.
    \begin{description}
    \item[Type 1:] If $p$ is of the form $\vv_i(x^\mu \hv_\alpha) \rightarrow
      \vv_{i, \cls (x^\mu)}(\frac{x^\mu}{x_{\cls (x^\mu )}} \hv_\alpha)
      \rightarrow \vv_{i}(\frac{x^\mu}{x_{\cls (x^\mu)}}\hv_\alpha)$, then the
      statement is obvious.  If, however, $p$ is of the form $\vv_i(x^\mu
      \hv_\alpha) \rightarrow \vv_{i, \cls (x^\mu)}(\frac{x^\mu}{x_{\cls (x^\mu
        )}} \hv_\alpha) \rightarrow \vv_{\cls(x^\mu)}(\frac{x^\mu}{x_{\cls
        (x^\mu)}}\hv_\alpha)$, then the assumption $\supp{(x^{\mu})} \subseteq \ncrt{
        (\hv_\alpha)}$ entails that also $\cls (x^\mu) \in \ncrt{
        (\hv_\alpha)}$.
    \item[Type 2:] Here the path $p$ is of the form $\vv_i(x^\mu \hv_\alpha)
      \rightarrow \vv_{i, \cls (x^\mu)}(\frac{x^\mu}{x_{\cls (x^\mu )}}
      \hv_\alpha) \rightarrow \vv_{\cls (x^\mu)}(\frac{x_ix^\mu}{x_{\cls
          (x^\mu)}}\hv_\alpha)$.  As above $\cls (x^\mu) \in \ncrt{
        (\hv_\alpha)}$ and by assumption $i\in \ncrt{ (\hv_\alpha)}$.  Thus
      $\frac{x_ix^\mu}{x_{\cls (x^\mu)}}\hv_\alpha$ is already an involutive
      standard representation. (Which means that, while in general a reduction
      path of type 2 might introduce a $\hv_\beta$ for $\beta \not= \alpha$,
      this does not happen under the additional assumptions of this lemma).
    \end{description}
  \end{description} 
  For arbitrary reduction paths $p$, the claim now follows by an induction
  over the length of $p$.
\end{proof}

Now we can show the above claim that reduction paths of type 0 are irrelevant.
Implicitly, this statement is already contained in \citep[Lemma 5]{es:morse}.

\begin{lemma}\label{lem:diffGnotype0}
  In the differential (\ref{eq:diffG}), no reduction path appearing in the
  third sum contains an elementary reduction path of type 0; i.\,e.\ all
  reduction paths appearing in the third sum are concatenations of elementary
  reduction paths of type 1 or 2.
\end{lemma} 

\begin{proof}
  Let $p$ be a reduction path appearing in the sum in (\ref{eq:diffG}) ending
  at the vertex $\vv_j \hv_\gamma$ and $\vv_i(x^\mu \hv_\alpha) \rightarrow
  \vv_\emptyset (x^\nu \hv_\beta) \rightarrow
  \vv_{\cls(x^\nu)}(\frac{x^\nu}{\cls (x^\nu)}\hv_\beta)$ an elementary
  reduction path of type 0 appearing in $p$.  As in the proof of Lemma
  \ref{lem:notype2}, we then have $\cls (x^\nu)\in \ncrt{ (\hv_\beta)}$ and
  Lemma \ref{lem:notype2} implies that $j \in \ncrt (\hv_\gamma)$.  On the
  other hand, for any such reduction path appearing in (\ref{eq:diffG}), we
  must have $j \in \crt{ (\hv_\gamma)}$.
\end{proof}

%\begin{lemma}\label{lem:leadtermsredpaths}
%  Let $p=\vv_i(x^\mu \hv_\alpha) \rightarrow \cdots \rightarrow \vv_j(x^\nu
%  \hv_\beta)$ be a reduction path that appears in the differential
%  (\ref{eq:diffG}) (potentially as part of a longer path).  If
%  $\rho_p\bigl(\vv_i(x^\mu \hv_\alpha)\bigr) = x^\kappa
%  \vv_j(x^\nu\hv_\beta)$, then $\lt_{\prec_{\H_1}}{(x_jx^{\kappa+\nu}
%    \hv_\beta)} \preceq_{\H_1} \lt_{\prec_{\H_1}}{(x_ix^\mu\hv_\alpha)}$.
%\end{lemma}

% \begin{proof}
%   Again we prove the assertion only for an elementary reduction path $p$ and
%   the general case follows by induction over the path length.  If $p$ is of
%   type 1, then we have either $\rho_p\bigl(\vv_i(x^\mu \hv_\alpha)\bigr)=
%   x_k\vv_i (\frac{x^\mu}{x_k}\hv_\alpha)$ or $\rho_p\bigl(\vv_i(x^\mu
%   \hv_\alpha)\bigr)= x_i\vv_k (\frac{x^\mu}{x_k}\hv_\alpha)$ for an index
%   $k\in\supp{\mu}$.  If $p$ is of type 2, then there exists an index
%   $j\in\supp{\mu}$ (implying $j \in \ncrt{ (\hv_\alpha)}$ and $j \leq \cls{
%     (\hv_\alpha)}$, resp.), a multi index $\nu$ and a scalar $\lambda \in \kk$
%   such that $\rho_p \bigl(\vv_i(x^\mu \hv_\alpha)\bigr)= \lambda \vv_j(x^\nu
%   \hv_\gamma)$ where $x^\nu \hv_\gamma$ appears in the involutive standard
%   representation of $\frac{x^\mu x_i}{x_j}\hv_\alpha$ with a non-vanishing
%   coefficient.  Lemma \ref{lem:notype2} implies $j\in \crt{(\hv_\gamma)}$. By
%   construction, $\lt{(\frac{x_ix^\mu}{x_j}\hv_\alpha)} \succeq \lt{(x^\nu
%     \hv_\gamma)}$.

%   We must now distinguish two cases. If $\lt{(\frac{x_ix^\mu}{x_j}\hv_\alpha)}
%   = \lt{(x^\nu \hv_\gamma)}$, then we have $\cls{(\hv_\alpha)} \leq
%   \cls{(\hv_\gamma)}$.  Indeed, since the given generators form a Pommaret
%   basis, the leading term $\lt{(x_{i}\hv_{\alpha})}$ has a unique involutive
%   divisor $\lt{(\hv_{\delta})}$.  Then
%   $\cls{(\hv_{\delta})}\geq\cls{(\hv_{\alpha})}$ implies $\supp{(x^\mu)}
%   \subseteq \ncrt{(\hv_\alpha)} \subseteq \ncrt{(\hv_\delta)}$. Thus
%   $\lt{(\hv_{\delta})}$ is also the unique involutive divisor of
%   $\lt{(\frac{x^\mu}{x_j} x_i \hv_\alpha)}$ and we find
%   $x^{\nu}=\frac{x^\mu\lt{(\hv_{\alpha})}}{x_j\lt{(\hv_{\delta})}}$ and
%   $\gamma=\delta$ entailing $\cls{(\hv_\gamma)} = \cls{ (\hv_\delta)} \geq
%   \cls{ (\hv_\alpha)}$.  But then $j\in \ncrt (\hv_\alpha) \subseteq \ncrt
%   (\hv_\gamma)$.  Analogous to Lemma \ref{lem:diffGnotype0}, such reduction
%   paths do not appear in the diffential (\ref{eq:diffG}).

%   The second case is simpler: if $\lt{(\frac{x_ix^\mu }{x_j}\hv_\alpha)} \succ
%   \lt{(x^\nu \hv_\gamma)}$, then $\lt{(x_ix^\mu \hv_\alpha)}=
%   \lt{(x_j\frac{x^\mu x_i}{x_j} \hv_\alpha)} \succ \lt{(x_j x^\nu
%     \hv_\gamma)}$ which proves the claim.
% \end{proof}

The next results use Schreyer orders on the components of the complex $\G$.
We define $\H_0$ as the Pommaret basis of $d_\G (\G_1)\subseteq \G_0$ with
respect to the Schreyer order $\prec_\H$ induced by the term order $\prec$ on
$\P^t$ and $\H_{i}$ as the Pommaret basis of $d_\G (\G_{i+1})\subseteq\G_{i}$
for the Schreyer order $\prec_{\H_{i-1}}$.  For the next lemma, we further
remark that in order to apply there these Schreyer orders, we need to have
both $x^{\kappa +\mu}\vv_j \hv_\beta \in \G_1$ and $x^\nu \vv_i \hv_\alpha \in
\G_1$, i.e. $j \in \crt{(\hv_\beta)}$ and $i \in \crt{(\hv_\alpha)}$.  Indeed,
by Lemma \ref{lem:notype2}, $j \in \ncrt{(\hv_\beta)}$ and $i \in
\ncrt{(\hv_\alpha)}$, respectively, implies that the reduction path in
question cannot be part of a longer reduction path that ends in a $\vv_k
\hv_\gamma$ with $k\in \crt{(\hv_\gamma)}$ which would be necessary for the
reduction path to appear in \eqref{eq:diffG}.

\begin{lemma}\label{lem:leadtermsredpaths}
  Let $p=\vv_i(x^\mu \hv_\alpha) \rightarrow \cdots \rightarrow \vv_j(x^\nu
  \hv_\beta)$ be a reduction path that appears in the differential
  (\ref{eq:diffG}) (possibly as part of a longer path).  If
  $\rho_p\bigl(\vv_i(x^\mu \hv_\alpha)\bigr) = x^\kappa
  \vv_j(x^\nu\hv_\beta)$, then $\lt_{\prec_{\H_1}}{(x^{\kappa+\nu}
    \vv_j\hv_\beta)} \preceq_{\H_1}
  \lt_{\prec_{\H_1}}{(x^\mu\vv_i\hv_\alpha)}$.
\end{lemma}

\begin{proof}
  Again we prove the assertion only for an elementary reduction path $p$ and
  the general case follows by induction over the path length.  If $p$ is of
  type 1, then we have either $\rho_p\bigl(\vv_i(x^\mu \hv_\alpha)\bigr)=
  x_k\vv_i (\frac{x^\mu}{x_k}\hv_\alpha)$, where the claim is obvious, or
  $\rho_p\bigl(\vv_i(x^\mu \hv_\alpha)\bigr)= x_i\vv_k
  (\frac{x^\mu}{x_k}\hv_\alpha)$ for an index $k\in\supp{x^{\mu}}$, so $k \in
  \ncrt \hv_\alpha$. But by the same argument as in the proof of Lemma
  \ref{lem:diffGnotype0}, the last case cannot occur.

  If $p$ is of type 2, there exists an index $j\in\supp{x^{\mu}}$ (implying
  $j \in \ncrt{ (\hv_\alpha)}$ and thus $j \leq \cls{ (\hv_\alpha)}$), a multi
  index $\nu$ and a scalar $\lambda \in \kk$ such that $\rho_p
  \bigl(\vv_i(x^\mu \hv_\alpha)\bigr)= \lambda \vv_j(x^\nu \hv_\gamma)$ where
  $x^\nu \hv_\gamma$ appears in the involutive standard representation of
  $\frac{x^\mu x_i}{x_j}\hv_\alpha$ with a non-vanishing coefficient.  Lemma
  \ref{lem:notype2} implies $j\in \crt{(\hv_\gamma)}$. By construction,
  $\lt_\prec{(\frac{x_ix^\mu}{x_j}\hv_\alpha)} \succeq \lt_\prec{(x^\nu
    \hv_\gamma)}$.

  Here we must distinguish between equality and strict inequality. In the
  first case, $\lt_\prec{(\frac{x_ix^\mu}{x_j}\hv_\alpha)} = \lt_\prec{(x^\nu
    \hv_\gamma)}$ and hence $\cls{(\hv_\alpha)} \leq \cls{(\hv_\gamma)}$.  But
  then $j\in \ncrt (\hv_\alpha) \subseteq \ncrt (\hv_\gamma)$.  Analogously to
  Lemma~\ref{lem:diffGnotype0}, such reduction paths do not appear in the
  differential (\ref{eq:diffG}).  If in the second case the strict inequality
  $\lt_\prec{(\frac{x_ix^\mu }{x_j}\hv_\alpha)} \succ \lt_\prec{(x^\nu
    \hv_\gamma)}$ holds, then also $\lt_\prec{(x^\mu x_i\hv_\alpha)} \succ
  \lt_\prec{(x^\nu x_j\hv_\gamma)}$ and now, by definition of the Schreyer
  order, $\lt_{\prec_{\H_1}}{(x^\mu \vv_i\hv_\alpha)} \succ_{\H_1}
  \lt_{\prec_{\H_1}}{(x^\nu \vv_j \hv_\gamma)}$ which proves the claim.
\end{proof}

For notational simplicity, we formulate the two decisive corollaries only for
the special case of second syzygies, but they remain valid in any homological
degree.  The first one already indicates the great similarity between
Sk\"oldberg's resolution and the one induced by a Pommaret basis, as a
comparison with Lemma \ref{lem:ltsyzka} shows that there is a one-to-one
correspondence between the leading terms of the syzygies contained in the two
resolutions.

\begin{corollary}\label{cor:leadtermsdG}
  If $i<j$, then $\lt_{\prec_{\H_1}}{\bigl(d_\G(\vv_{i,j}\hv_\alpha)\bigr)} =
  x_j\vv_i\hv_\alpha$.
\end{corollary}

\begin{proof}
  As described in Section \ref{sec:pombas}, we assume that the elements of the
  given Pommaret basis are numbered according to a $P$-order.  Consider now
  the differential $d_\G$.  We first compare the terms $x_i\vv_j \hv_\alpha$
  and $x_j\vv_i\hv_\alpha$.  Lemma \ref{lem:notype2} (or the minimality of
  these terms with respect to any order respecting the used Morse matching)
  entails that there are no reduction paths $[\vv_j\hv_\alpha \rightsquigarrow
  \vv_k \hv_\delta]$ with $k\in \crt{(\hv_\delta)}$ (except trivial reduction
  paths of length 0), since $\vv_j \hv_\alpha \in A^0$; the same argument
  applies to $\vv_i \hv_\alpha$.  By definition of the Schreyer order, we have
  $x_i\vv_j \hv_\alpha \prec_{\H_1} x_j\vv_i\hv_\alpha$.

  Now consider any other term in the sum.  We will prove $x_j\vv_i\hv_\alpha
  \succ_{\H_1} x^\kappa\vv_i \hv_\beta$, where $x^\kappa \hv_\beta$
  effectively appears in the involutive standard representation of $x_j
  \hv_\alpha$.  The claim then follows from applying Lemma
  \ref{lem:leadtermsredpaths} with $ x_j\vv_i\hv_\alpha \succ_{\H_1}
  x^\kappa\vv_i \hv_\beta \succeq_{\H_1}
  \lt_{\prec_{\H_1}}{\bigl(\rho_p(\vv_ix^\kappa \hv_\beta)\bigr)}$.

  We always have $\lt_{\prec}{(x_jx_i \hv_\alpha)}\succeq \lt_{\prec}{(
    x^\kappa x_i \hv_\beta)}$.  If this is a strict inequality, then
  $x_j\vv_i\hv_\alpha \succ_{\H_1} x^\kappa \vv_i \hv_\beta$ follows at once
  by definition of the Schreyer order.  So now assume $\lt_{\prec}{(x_jx_i
    \hv_\alpha)}=\lt_{\prec}{(x^\kappa x_i \hv_\beta)}$.  By construction,
  $x^\kappa \in \kk[x_1,\dots,x_{\cls {(\hv_\beta)}}]$.  Again by definition
  of the Schreyer order, the claim follows, if we can prove
  $\lt_{\prec_{\H_0}} (x_jx_i \vv_\emptyset
  \hv_\alpha)\succ_{\H_0}\lt_{\prec_{\H_0}} (x^\kappa x_i \vv_\emptyset
  \hv_\beta)$.  Since $j\in \crt{(\hv_\alpha)}$ and
  $\lt_{\prec}{(x_j\hv_\alpha)}$ is involutively divisible by
  $\lt_{\prec}{(\hv_\beta)}$, we have $\alpha <\beta$, by definition of a
  $P$-ordering.  As we have here $\lt_\prec {(x_j\hv_\alpha)}=\lt_\prec{
    (x^\kappa \hv_\beta)}$, this implies the estimate $\lt_{\prec_{\H_0}}{
    (x_jx_i \vv_\emptyset \hv_\alpha)}\succ_{\H_0}\lt_{\prec_{\H_0}}{
    (x^\kappa x_i \vv_\emptyset \hv_\beta)}$ and therefore
  $\lt_{\prec_{\H_1}}{(x_j\vv_i\hv_\alpha)} \succ_{\H_1} \lt_{\prec_{\H_1}}
  {(x^\kappa \vv_i\hv_\beta)}$.
\end{proof}

\begin{corollary}\label{cor:PBfromMorse}
  The set $\bigl\{d_\G (v_\kv\otimes \hv_\alpha)\mid|\kv|=2; \kv\subseteq
  \crt{ (\wv_\alpha)}\bigr\}$ is a Pommaret basis with respect to the term
  order $\prec_{\H_0}$.
\end{corollary}

Based on these two corollaries, it is now comparatively straightforward to
prove our main result by explicitly constructing an isomorphism between the
two resolutions we consider.

\begin{theorem}\label{thm:isores}
  Assume the situation of Lemma \ref{lem:linsyz}, i.\,e.\ we have a submodule
  $\U\subseteq\P^{t}$ and the presentation comes from a $P$-ordered Pommaret
  basis $\H$ of $\U$.  Then the resolution $(\G,d_{\G})$ is isomorphic to the
  resolution induced by $\H$.
\end{theorem}

\begin{proof}
  First, we recall the alternative description of the resolution induced by a
  Pommaret basis given at the end of Section \ref{sec:pombas}, and especially
  the definition of the differential in the complex $\S_\bullet$ as in
  (\ref{eq:diffS}).  There, we start with $\W=\bigoplus_{\alpha=1}^{s}
  \P\wv_{\alpha}$ and $\V=\bigoplus_{i=1}^{n} \P\vv_{i}$.  Then we consider
  the modules $\C_{i}=\W\otimes_{\P}\Lambda_{i}\V$.  By identifying
  $\wv_\alpha= \wv_\alpha \otimes_\P \vv_\emptyset \in \C_0$ with $m_\alpha =
  d_\S (\wv_\alpha)\in \U$, we get the isomorphism
  \begin{displaymath}
    \C_i=\Bigl(\bigoplus_{\alpha=1}^{s}\P\wv_{\alpha}\Bigr) \otimes_{\P} 
         \Lambda_{i}\Bigl(\bigoplus_{j=1}^{n} \P\vv_{j}\Bigr) \cong 
         \P\otimes_\kk\Bigl(\bigoplus_{\alpha=1}^{s} \kk m_{\alpha}\Bigr) 
         \otimes_{\kk}\Lambda_{i}\Bigl(\bigoplus_{j=1}^{n} \kk\vv_{j}\Bigr)
         \subseteq \F_i
  \end{displaymath}
  and we can view $\C_i$ as a submodule of $\F_i$.  In the same way, we see
  that for the submodules $\S_i \subseteq \C_i$ and $\G_i\subseteq \F_i$ we
  have isomorphisms $\S_i \cong \G_i$.  Using these isomorphisms, we will
  identify $\S_i$ and $\G_i$ in the rest of this proof.
 
  We write the two resolutions as rows in a diagram denoting the components of
  $d_{\S}$ by $d_{i}$ and those of $d_{\G}$ by $d_{i}^{*}$:
  \begin{equation}\label{eq:iso}
    \xymatrix{
      {\cdots} \ar[r] & {\G_{2}} \ar[r]^{d_1} \ar@{-->}[d]^{\varphi_2} &
      {\G_{1}} \ar[r]^{d_{0}} \ar@{-->}[d]^{\varphi_1} &
      {\G_{0}} \ar[d]^{\varphi_0} \ar[r] & {\U} \ar[r] \ar@{=}[d] & {0} \\
      {\cdots} \ar[r] & {\G_{2}} \ar[r]^{d_1^*} & {\G_{1}} \ar[r]^{d_{0}^*} &
      {\G_{0}} \ar[r] &  {\U} \ar[r] & {0}
    }\,.
  \end{equation}
  Let $\{\ev_{i,1},\dots,\ev_{i,r_{i}}\}$ be the basis of the free module
  $\G_{i}$.  By Corollary \ref{cor:PBfromMorse}, the vectors
  $\hv_{i-1,\alpha}=d_{i}(\ev_{i,\alpha})$ define a Pommaret basis $\H_{i}$ of
  $\im{d_{i}}$.  Analogously, we obtain a Pommaret basis $\H_{i}^{*}$ of
  $\im{d_{i}^{*}}$.  Here we set $\H_{-1}=\H_{-1}^{*}=\H$, the given Pommaret
  basis of $\U$, and define the term orders $\prec_{i}$ on $\G_{i}$
  recursively as the Schreyer orders $\prec_{i}=\prec_{\H_{i-1}}$.  Because of
  Corollary \ref{cor:leadtermsdG}, we always have
  $\lt{\hv_{i,\alpha}}=\lt{\hv_{i,\alpha}^{*}}$ and hence also
  $\prec_{i}=\prec_{\H_{i-1}^{*}}$.

  Assume now that an automorphism $\varphi_{0}:\G_{0}\rightarrow\G_{0}$ is
  given which satisfies $\varphi_{0}(\im{d_{0}})=\im{d_{0}^{*}}$ and which
  preserves the term order $\prec_{0}$ in the sense that we have
  $\lt_{\prec_{0}}{\bigl(\varphi_{0}(\fv)\bigr)} = \lt_{\prec_{0}}{(\fv)}$ for
  all vectors $0\neq\fv\in\G_{0}$.  Obviously, the identity is such an
  automorphism.  We now show that $\varphi_{0}$ can be lifted to automorphisms
  $\varphi_{i}:\G_{i}\rightarrow\G_{i}$ preserving the term orders $\prec_{i}$
  such that the diagram (\ref{eq:iso}) commutes.

  If $\varphi_{0}(\hv_{0,\alpha}) =
  \sum_{\beta=1}^{r_{1}}P^{\beta}_{\alpha}\hv_{0,\beta}^{*}$ is an involutive
  standard representation with respect to the Pommaret basis $\H_{0}^{*}$,
  then we set $\varphi_{1}(\ev_{1,\alpha}) =
  \sum_{\beta=1}^{r_{1}}P^{\beta}_{\alpha}\ev_{1,\beta}$ and extend
  $\P$-linearly.  It is trivial that for this choice of $\varphi_{1}$ the
  rightmost square in the diagram (\ref{eq:iso}) becomes commutative.

  We temporarily renumber the elements of the Pommaret bases $\H_{0}$ and
  $\H_{0}^{*}$ so that now $\lt{\hv_\alpha} \prec_{0} \lt{\hv_\beta}$, if and
  only if $\alpha < \beta$.  By definition of an involutive standard
  representation, the matrix $(P_\alpha^\beta)$ is then an upper triangular
  matrix for this ordering and since $\varphi_{0}$ preserves the term order
  $\prec_{0}$ the elements $P^{\alpha}_{\alpha}$ on the diagonal are non
  vanishing constants.  This fact trivially implies that $\varphi_{1}$ is an
  automorphism.

  Finally, we must show that $\varphi_{1}$ preserves the term order
  $\prec_{1}$.  Obviously, it suffices to check this for terms.  By
  definition, $\varphi_{1}(x^{\kappa}\ev_{1,\alpha}) =
  x^{\kappa}\sum_{\beta=1}^{r_{1}}P^{\beta}_{\alpha}\ev_{1,\beta}$.  Using the
  definition of a Schreyer order and the fact that the coefficients
  $P^{\beta}_{\alpha}$ come from an involutive standard representation, we
  find that the equality
  \begin{displaymath}
    \lt_{\prec_{1}}{\varphi_{1}(x^{\kappa}\ev_{1,\alpha})} =
       \max_{\prec_{1}}{\bigl\{
           x^{\kappa}\lt_{\prec_{1}}{(P^{\beta}_{\alpha}\ev_{1,\beta})}\mid
                             \beta=1,\dots,r_{1}\bigr\}}
  \end{displaymath}
  is equivalent to the equality
  \begin{displaymath}
    \max_{\prec_{0}}{\bigl\{
           x^{\kappa}\lt_{\prec_{0}}{(P^{\beta}_{\alpha}\hv_{0,\beta}^{*})}\mid
                             \beta=1,\dots,r_{1}\bigr\}}
    = x^{\kappa}\lt_{\prec_{0}}{(\hv_{0,\alpha}^{*})}\,. 
  \end{displaymath}
  Using again the definition of a Schreyer order, we may now conclude that
  $\lt_{\prec_{1}}{\varphi_{1}(x^{\kappa}\ev_{1,\alpha})}
  =\lt_{\prec_{1}}{(x^{\kappa}\ev_{1,\alpha})}$ as required.

  Since $\varphi_{1}$ is an automorphism and the rows in the diagram
  (\ref{eq:iso}) are exact, we have $\varphi_{1}(\im{d_{1}})=\im{d_{1}^{*}}$.
  Thus we can iterate the construction and obtain automorphisms
  $\varphi_{i}:\G_{i}\rightarrow\G_{i}$ for all values of $i$.  Because of
  Lemma \ref{lem:syz1}, choosing the identity for $\varphi_{0}$ then proves
  our assertion.
\end{proof}

% We will now use Lemma \ref{cor:leadtermsdG} to construct an isomorphism
% between the resolution induced by the Pommaret basis $\H$ and the resolution
% $\G_{\bullet}$.  For this purpose, we consider the diagram
% \begin{displaymath}
%   \xymatrix{
%     {\cdots} \ar[r] & {\P^t} \ar[r]^{d_1} \ar@{-->}[d]^{\varphi_2} &
%     {\P ^r} \ar[r]^{d} \ar@{-->}[d]^{\varphi_1} & {\P^s} \ar[d]^{\varphi_0}\\
%     {\cdots} \ar[r] & {\P^t} \ar[r]^{d_1^*} & {\P^r} \ar[r]^{d^*} & {\P ^s}
%   }\,.
% \end{displaymath}
% where we assume that
% \begin{description}
% \item[(i)] $\P^s= \bigoplus_{\alpha=1}^s \P\ev_\alpha$, $\P^r=
%   \bigoplus_{\alpha=1}^r \P\fv_\alpha$ and $\P^t=\bigoplus_{\alpha=1}^t
%   \P\gv_\alpha$;
% \item[(ii)] $\prec$ is a term order on $\P^s$;
% \item[(iii)] $d(\P^r) \cong d^*(\P^r)$ ;
% \item[(iv)] $\varphi_0$ is an isomorphism and $\varphi_0 \bigl(d(\P^r)\bigr) =
%   d^*(\P^r)$;
% \item[(v)] if $x^\kappa\fv_i\prec x^\lambda \fv_j$, then $\varphi_{0}(x^\kappa
%   \fv_i)\prec \varphi_{0}(x^\lambda \fv_j)$ for all $x^\kappa \fv_i, x^\lambda
%   \fv_j\in \P^r$ (i.\,e.\ \emph{$\varphi_{0}$ preserves the term order
%     $\prec$});
% \item[(vi)] the elements $\hv_\alpha = d(\fv_\alpha)$ and $\hv_\alpha ^* =
%   d^*(\fv_\alpha)$, resp., form Pommaret bases $\H$ and $\H^{*}$ of $d(\P^r)$
%   and $d^*(\P^r)$, resp., which are both ordered according to the same
%   $P$-ordering.
% \end{description}
% Note that (v) implies that the leading modules of $d(\P^r)$ and $d^*(\P^r)$
% are identical\marginpar{wirklich?} and (vi) entails that the Schreyer orders
% $\prec_\H$ and $\prec_{\H^*}$ are the same.  Thus we will simply speak of
% ``the'' Schreyer order on $\P^r$ and denote it by $\prec_{\P^r}$.

% As a first step, we now construct an isomorphism $\varphi_1: \P^r \rightarrow
% \P^r$ such that the diagram is commutative with $\varphi_1$ preserving the
% term order $\prec_{\P^r}$.  Let $\varphi_0 (\hv_\alpha) = \sum_{\beta =1}^s
% P_\alpha^\beta \hv_\beta^*$ for $1\leq \alpha \leq s$ be the involutive
% standard representation with respect to the Pommaret basis $\H^*$.  Then we
% define $\varphi_1 (\fv_\alpha)= \sum_{\beta =1}^s P_\alpha^\beta\fv_\beta$.
% This obviously yields a commutative diagram, and we only have to check that
% $\varphi_1$ is an isomorphism that preserves the term order.

% In order to simplify the proof that $\varphi_1$ is an isomorphism, we
% temporarily reorder both Pommaret bases so that now $\lt{\hv_\alpha} \prec
% \lt{\hv_\beta}$, if and only if $\alpha < \beta$.  By definition of an
% involutive standard representation, the matrix $(P_\alpha^\beta)$ is then an
% upper triangular matrix for this ordering and because of (v) the elements on
% the diagonal cannot vanish.  This trivially implies the claim.

% Now assume that $x^\kappa \fv_\alpha\prec_{\P^r} x^\lambda \fv_\beta$.  By
% definition of the Schreyer order, this is equivalent to either
% $\lt_\prec{(x^\kappa\hv_\alpha)} \prec \lt_\prec{(x^\lambda\hv_\beta)}$ or
% $\lt_\prec{(x^\kappa\hv_\alpha)} = \lt_\prec{(x^\lambda\hv_\beta)}$ and
% $\beta>\alpha$.

% Then we have
% \begin{eqnarray*}
% &\varphi_1 (x^\kappa f_\alpha) \prec_{\P^r}\varphi_1(x^\lambda f_\beta)\\
% \Leftrightarrow & \varphi_1(x^\kappa(f_\alpha + \sum\limits_{\gamma=1}^{\alpha-1}P_\alpha^\gamma f_\gamma)) \prec_{\P^r} \varphi_1(x^\lambda (f_\beta + \sum\limits_{\delta=1}^{\beta-1}P_\beta^\delta f_\delta))\\ 
% \Leftrightarrow & \lt_\prec(x^\kappa(\hv_\alpha^*))=\lt_\prec(x^\kappa(\hv_\alpha^* + \sum\limits_{\gamma=1}^{\alpha-1}P_\alpha^\gamma \hv_\gamma^*)) \prec \lt_\prec(x^\lambda (\hv_\beta^* + \sum\limits_{\delta=1}^{\beta-1}P_\beta^\delta \hv_\delta^*)) = \lt_\prec(x^\lambda (\hv_\beta^*))\\ &\lor (\lt_\prec(x^\kappa(\hv_\alpha^*))= \lt_\prec(x^\lambda (\hv_\beta^*)) \land \beta>\alpha)\\ 
% \Leftrightarrow & \lt_\prec(x^\kappa(\hv_\alpha)) \prec \lt_\prec(x^\lambda (\hv_\beta))\lor (\lt_\prec(x^\kappa(\hv_\alpha))= \lt_\prec(x^\lambda (\hv_\beta)) \land \beta>\alpha) \\
% \Leftrightarrow &x^\kappa f_\alpha\prec_{\P^r} x^\lambda f_\beta.
% \end{eqnarray*}


% As $\varphi_1$ is an isomorphism, we have $\ker (d)\cong \ker (d^*)$. Taking a
% Pommaret basis $\H^1 =\{\hv_1^1,...,\hv_t^1\}$ of $\ker (d)$ for the term
% order $\prec_{\P^r}$ and a Pommaret basis $\H^{1*}
% =\{\hv_1^{1*},...,\hv_t^{1*}\}$ of $\ker (d^*)$, by iteration we may again
% find an isomorphism $\varphi_2 :\P^t \rightarrow \P^t$, where $d_1(g_\beta) =
% \hv_\beta^1$ resp. $d_1^*(g_\beta) = \hv_\beta^{1*}$, the diagram is
% commutative and $\varphi_2$ also respects the Schreyer-order $\prec_{\P^t}$
% (after again ordering $\H^1$ and $\H^{1*}$ in the same way according to
% leading terms).  So we can iterate this process, obtaining an isomorphism of
% chain complexes.


% Specifically, we can look at the following situation:
% $\xymatrix{
% \ar@{.}[r]&\P^r\ar[r]&\P^s \ar[r] \ar[d]^{{\rm id}_{\P^s}}&\U\ar[r]\ar[d]^{{\rm id}_{\U}} &0\ar[d]\\
% \ar@{.}[r]&\P^r\ar[r]&\P^s \ar[r] &\U\ar[r] &0
% }$
% where we have in top row the free resolution induced by a Pommaret-basis, and
% in the bottom row the free resolution $\G$. Using the construction above, we
% have now shown that those resolutions (which in general are not minimal) are
% isomorphic.



\section{A Simple Special Case}
\label{sec:simple}

Whenever a reduction path $p$ contains an elementary reduction of type $2$
which is reversed in the Morse matching, then in the situation of Lemma
\ref{lem:linsyz} a factor $P^{(\bullet;\bullet)}_{\bullet}$
(cf. (\ref{eq:syzka})) appears in the the differential $d_{\G}$ in the
coefficient $c_{p}$ associated with the reduction $\rho_{p}$.  A special case,
in which one obtains a much simpler expression for the differential $d_{\G}$
\citep[Thm.~2]{es:inlinsyz}, arises when \emph{no} appearing reduction path
contains an elementary reduction of type $2$.  Sk\"oldberg provides a simple
sufficient condition for being in this special case, namely when the module
$\M$ is \emph{crit-monotone}.

Translated into the situation of Lemma \ref{lem:linsyz}, a submodule $\U$ is
crit-monotone when on the right hand side of (\ref{eq:syzka}) only those
generators $\ev_{\beta}$ effectively appear which satisfy
$\cls{\hv_{\beta}}\geq\cls{\hv_{\alpha}}$.  It is very rare that submodules
satisfy this condition.  There exists one notable exception: it is always
satisfied for \emph{monomial} submodules possessing a Pommaret basis.  In
fact, the arising resolution is a simple generalisation of the closed-form
resolution obtained in \citep{wms:comb2} for such monomial submodules (see
Theorem \ref{thm:monres} below).  We provide now an independent proof of this
result which is also much simpler than the proof given in \citep{wms:comb2}
for the monomial case.

\begin{theorem}\label{thm:highsyz}
  Assume that in the syzygies (\ref{eq:syzka}) the coefficients
  $P^{(\alpha;k)}_{\beta}$ are non-zero only, if
  $\cls{\hv_{\beta}}\geq\cls{\hv_{\alpha}}$.  Then the Pommaret basis $\H_{j}$
  of the $j$th syzygy module consists of the syzygies\footnote{The
    Kronecker-Iversion symbol $[\cdot]$ is $1$, if the contained condition is
    true, and $0$ otherwise.}
  \begin{equation}\label{eq:syzkva}
    \Sv_{\alpha;\kv}=
        \sum_{\ell=1}^{j}(-1)^{j-\ell}\Bigl(x_{k_{\ell}}\ev_{\alpha,\kv_{\ell}}-
             \sum_{\beta=1}^{s}\bigl[(\kv_{\ell})_{1}>\cls{\hv_{\beta}}\bigr]
                             P^{(\alpha,k_{\ell})}_{\beta}
                             \ev_{\beta;\kv_{\ell}}\Bigr)
  \end{equation}
  where again $\kv=(k_{1},\dots,k_{j})$ is an integer sequence with
  $\cls{\hv_{\alpha}}<k_{1}<\cdots<k_{j}$.
\end{theorem}

\begin{proof}
  It suffices to consider the second syzygy module, as the assertion is then
  also true for all higher syzygy modules by iteration.  Since we have the
  right leading terms (with respect to the corresponding Schreyer order), it
  furthermore suffices to prove that (\ref{eq:syzkva}) is indeed a syzygy.
  Thus, with the short hand $[k,\beta]=[k>\cls{\hv_{\beta}}]$, there remains
  to show that for $\cls{\hv_{\alpha}}<k_{1}<k_{2}$
  \begin{equation}\label{eq:syz2}
    x_{k_{2}}\Sv_{\alpha;k_{1}}-
    \sum_{\beta=1}^{s}[k_{1},\beta]P^{(\alpha;k_{2})}_{\beta}\Sv_{\beta;k_{1}}=
    x_{k_{1}}\Sv_{\alpha;k_{2}}-
    \sum_{\beta=1}^{s}[k_{2},\beta]P^{(\alpha;k_{1})}_{\beta}\Sv_{\beta;k_{2}}\,.
  \end{equation}
  In order to see that this equation always holds after substitution of the
  first syzygies, we compare two different ways to determine a standard
  representation of $x_{k_{1}}x_{k_{2}}\hv_{\alpha}$: one time we first take
  the involutive standard representation of $x_{k_{2}}\hv_{\alpha}$ and then
  multiply it by $x_{k_{1}}$; the second time we revert the role of
  $x_{k_{1}}$ and $x_{k_{2}}$.  The first operation yields
  \begin{equation}\label{eq:isr2}
    \begin{aligned}
      x_{k_{1}}x_{k_{2}}\hv_{\alpha}=
          \sum_{\gamma=1}^{s}\Bigl(&[\cls{\hv_{\gamma}}\geq k_{1}]
              x_{k_{1}}P^{(\alpha,k_{2})}_{\gamma} + {}\\
              &\sum_{\beta=1}^{s}[\cls{\hv_{\beta}}<k_{1}]
                  P^{(\alpha,k_{2})}_{\beta}P^{(\beta,k_{1})}_{\gamma}\Bigr)
              \hv_{\gamma}\,;
    \end{aligned}
  \end{equation}
  the second one yields the same result with $k_{1}$ and $k_{2}$ swapped.  Due
  to our assumption on the coefficients $P^{(\alpha,k)}_{\beta}$, we obtain in
  both cases the \emph{involutive} standard representation which is unique by
  Proposition \ref{prop:pbisr}.  Hence both ways must lead to identical
  coefficients for each generator $\hv_{\gamma}$.  Substituting the obtained
  equalities into (\ref{eq:syz2}) yields the desired result.
\end{proof}

\begin{example}
  The condition in Theorem \ref{thm:highsyz}---and similar in
  \citep[Thm.~2]{es:inlinsyz}---is sufficient but not necessary for the
  conclusion.  The homogeneous ideal $\I\lhd\kk[x,y,z]$ generated by the
  Pommaret basis
  \begin{equation}\label{eq:cex}
    h_{1}=x^{2}y\,,\quad h_{2}=x^{2}z\,,\quad h_{3}=y^{2}+xz\,,\quad
    h_{4}=yz-xz\,,\quad h_{5}=z^{2}+xy
  \end{equation}
  provides a concrete instance where the assumptions of Theorem
  \ref{thm:highsyz} are \emph{not} satisfied, but the conclusion is
  nevertheless correct.  The Pommaret basis of the first syzygy module
  consists of
  \begin{subequations}
    \begin{align}
      \Sv_{1;3}&=z\ev_1-x\ev_2-x^2\ev_4\,,\\
      \Sv_{2;3}&=x\ev_1+z\ev_2-x^2\ev_5\,,\\
      \Sv_{3;3}&=\ev_1-\ev_2+z\ev_3-(x+y)\ev_4-x\ev_5\,,\\
      \Sv_{4;3}&=-\ev_1-\ev_2+x\ev_3+z\ev_4+(x-y)\ev_5\,,\\
      \Sv_{1;2}&=y\ev_1+x\ev_2-x^2\ev_3\,,\\
      \Sv_{2;2}&=(y-x)\ev_2-x^2\ev_4\,.
    \end{align}
  \end{subequations}
  Obviously, the syzygies $\Sv_{3;3}$ and $\Sv_{4;3}$ come from generators of
  class $2$ but contain basis vectors corresponding to generators of class
  $1$.  The Pommaret basis of the second syzygy module comprises
  \begin{subequations}
    \begin{align}
      \Sv_{1;2,3}&=z\ev_{1;2}-x\ev_{2;2}-y\ev_{1;3}-x\ev_{2;3}+x^{2}\ev_{3;3}\,,\\
      \Sv_{2;2,3}&=z\ev_{2;2}+x\ev_{1;2}-(y-x)\ev_{2;3}+x^{2}\ev_{4;3}
    \end{align}
  \end{subequations}
  which is exactly (\ref{eq:syzkva}).
\end{example}


\section{Implementation in \cocoalib}
\label{sec:cocoa}

We now describe an implementation of the above results in the computer algebra
library \cocoalib{} \citep{cocoalib}.\footnote{Our implementation is part of
  the official distribution of the \cocoalib{} and thus freely available.}  In
contrast to the remainder of this article, our implementation is based on the
standard conventions for the reverse lexicographic order in order to be
consistent with \cocoalib{}.  This also implies that a number of things like
the definitions of multiplicative or critical variables must be adapted.  The
change of convention means that everywhere the ordering of the variables must
be reverted: $x_{1},\dots,x_{n}$ becomes $x_{n},\dots,x_{1}$.  Our
implementation is currently restricted to ideals.

We want to construct the reduced complex $\G_{\bullet}$.  We first need the
two-sided Koszul complex $\F_{\bullet}$.  Because of the form of the reduced
differential \eqref{eq:diffG}, we only have to determine the differential
$d_\F$ for basis elements of the form $ \vv_{\kv} \hv_{\alpha}$ where $\kv
\subseteq \crt{\hv_{\alpha}}$, which is in principle straightforward with
\eqref{eq:diffF}.

The only problem which may occur is that we obtain in the right hand summands
a term $\vv_{\kv_{i}} (x_{k_i} \hv_{\alpha})$ where $k_{i} \notin
\ncrt{\hv_{\alpha}}$.  In this case, we determine the involutive standard
representation of $x_{k_i} \hv_{\alpha}$ and split the coefficients into
monomials:
\begin{equation*}
  x_{k_i} \hv_{\alpha} = \sum_{\beta = 1}^{s} \sum_{\mu}
                       Q^{\kv, \alpha}_{\kv_i, \mu, \beta} x^\mu\hv_{\beta}
\end{equation*}
with $\mu \subseteq \mult{P}{\hv_{\beta}}$ and scalars $Q^{\kv,
  \alpha}_{\kv_i, \mu, \beta} \in\kk$. So we can replace $\vv_{\kv_i} (x_{k_i}
\hv_{\alpha})$ by basis elements of the right form.  Thus we arrive at the
following, easily computable, explicit form of the differential $d_{\F}$ (we
assume that $\kv$ is of length $j$)
\begin{equation}\label{eq:algDiffF}
    d_\F(\vv_{\kv}  \hv_{\alpha}) =
        \sum_{i = 1}^j (-1)^{i + 1}\bigl(x_{k_i}  \vv_{\kv_i}  \hv_{\alpha} -
        \sum_{\beta = 1}^{s}\sum_{\mu}
            Q^{\kv, \alpha}_{\kv_i, \mu, \beta} \vv_{\kv_i} (x^\mu\hv_{\beta})\bigr)\;.
\end{equation}

Now we perform the Morse reduction.  Assume that we have an edge $\vv_\kv
\hv_{\alpha}\rightarrow\vv_\mv (x^{\mu} \hv_{\beta})$ in the graph
$\Gamma_{\F_\bullet}$ with $|\kv| = |\mv| + 1$ and $\mu \subseteq
\ncrt{\hv_{\beta}}$, e.\,g.\ $\vv_\kv \hv_{\alpha}$ maps to $Q^{\kv,
  \alpha}_{\mv, \mu, \beta} \vv_{\mv} (x^\mu \hv_\beta)$.  By
\eqref{eq:diffG}, the element $Q^{\kv, \alpha}_{\mv, \mu, \beta} \vv_{\mv}
(x^\mu \hv_\beta)$ must reduce to
\begin{displaymath}
  \sum_{\stackrel{\vv_{\ellv}  \hv_\gamma}{\ellv \subseteq \ncrt{\hv_\gamma}}}
  \sum_{p \in [\vv_{\mv}  (x^\mu \hv_\beta) \rightsquigarrow \vv_{\ellv}  \hv_\gamma]}
  \rho_p \bigl(Q^{\kv, \alpha}_{\mv, \mu, \beta} \vv_{\mv}  (x^\mu \hv_\beta)\bigr)\,.
\end{displaymath}
We see that the result of the reduction does not really depend on the starting
point $\vv_{\kv} \hv_\alpha$ of the path; it solely requires the knowledge of
its image.  It is furthermore possible to combine some reduction paths.
Assume that two reduction paths with starting points coming from the same
preimage pass at some later point through the same vertex $\vv_\kv (x^\mu
\hv_\beta)$.  Due to the fact that an elementary reduction path only depends
on its starting point, we can combine the two paths from this point on and
thus compute their remaining parts simultaneously.

We introduce now a partial order on the set of basis elements $\vv_\kv (x^\mu
\hv_\beta)$, as this considerably simplifies the determination of the
reduction $d_\G(\vv_\kv \hv_\alpha)$ from $d_\F(\vv_\kv \hv_\alpha)$.  We
first compute $d_\F(\vv_\kv \hv_\alpha)$ which is a $\P$-linear combination of
terms of the form $\vv_\mv (x^\mu \hv_\beta)$.  Then we pick the greatest term
according to our ordering and perform an elementary reduction which leads to a
new sum.  This process is iterated, until there are only elements of the form
$\vv_\mv \hv_\beta$ with $\mv \subseteq \crt{\hv_\beta}$ left which then form
the differential $d_\G(\vv_\kv \hv_\alpha)$.  Our next result explicitly
describes a useful partial order for this purpose.

\begin{proposition}\label{Algo::Prop::Sorting}
  Let $\vv_\kv (x^\mu \hv_\alpha)$ and $\vv_\mv (x^\nu \hv_\beta)$ be two
  basis elements such that $\supp{x^{\mu}} \subseteq \ncrt{\hv_\alpha}$ and
  $\supp{x^{\nu}} \subseteq \ncrt{\hv_\beta}$ and such that there is an
  elementary reduction path $\vv_\kv x^\mu \hv_\alpha \rightarrow \vv_\mv
  x^\nu \hv_\beta$.  If we set $\vv_\kv x^\mu \hv_\alpha > \vv_\mv x^\nu
  \hv_\beta$ whenever one of the conditions\footnote{$x_\kv$ denotes here the
    product of the $x_{k_i}$ with $k_i\in\kv$.}
  \begin{gather}
    |\kv| > |\mv|\,,\label{eq::Cmp1}\\
    |\kv| = |\mv| \quad\wedge\quad
    x_\kv x^{\mu} \lt{\hv_\alpha} \succ x_\mv x^{\nu} \lt{\hv_\beta}\,,
        \label{eq::Cmp2}\\
    |\kv| = |\mv| \quad\wedge\quad
    x_\kv x^{\mu} \lt{\hv_\alpha} = x_\mv x^{\nu} \lt{\hv_\beta} \quad 
    \wedge \quad x^{\mu} \lt{\hv_\alpha} \prec x^{\nu} \lt{\hv_\beta}
  \end{gather}
  is satisfied, then this defines a total order on the set which contains the
  basis elements of all the modules $\F_m$ for $m \geq 0$.
\end{proposition}

\begin{proof}
  Along every elementary reduction path we have $|\kv| = |\mv|$.  Assume that
  the path is an elementary reduction of type 1.  Then $\mv = (\kv \cup b)
  \setminus a$ and $x^\nu = x^\mu / x_b$ for some $a,b \in \{1, \dots, n\}$.
  Hence $\deg{x_\kv x^\mu} = \deg{x_\mv x^\nu} + 1$ entailing $x_\kv x^\mu
  \succ x_\mv x^\nu$ which leads to $\vv_\kv (x^\mu \hv_\alpha) < \vv_\mv
  (x^\nu \hv_\beta)$.

  Now we consider elementary reductions of type 2. There are two
  possibilities: either $x_\kv x^{\mu} \lt{\hv_\alpha} \succ x_\mv x^{\nu}
  \lt{\hv_\beta}$ or for at least one reduction of type 2, $x_\kv x^{\mu}
  \lt{\hv_\alpha} = x_\mv x^{\nu} \lt{\hv_\beta}$.  In the first case the
  statement is obvious.  For the second one, we note that
  \begin{equation*}
     x^\nu \lt{\hv_\beta} =  \frac{x_a x^\mu}{x_b}\lt{\hv_\alpha}\,,
  \end{equation*}
  where $a \in \kv$ and $b = \min{\supp{x^{\mu}}}$ and $b< \min \kv$, according
  to the construction of a Morse matching \eqref{eq:matching}.  Therefore $a >
  b$ and hence we can deduce with the reverse lexicographic order that
  \begin{equation*}
    x^\mu \lt{\hv_\alpha} < \frac{x_a x^\mu}{x_b}\lt{\hv_\alpha}\,,
  \end{equation*}
  which completes the proof.
\end{proof}

\begin{remark}
  The proof does not use the condition \eqref{eq::Cmp1}.  This condition is
  trivially satisfied.  But with the help of condition \eqref{eq::Cmp1}, we
  are able to store the complete complex $\F_{\bullet}$ in only one list.
  Then we can start the Morse reductions at the greatest element, lying in the
  last module of the free resolution, and proceed until the first module is
  reached.
\end{remark}

Based on these results, we are now able to formulate a novel algorithm for
computing a free resolution for an ideal $\I\unlhd\P$ given a Pommaret basis
$\H$ of it.  For the sake of completeness, we first discuss the determination
of the relevant part of the two-sided Koszul complex $\F_{\bullet}$.  It is a
straightforward application of \eqref{eq:algDiffF}.  Consider the map $d_{\F}$
restricted to the free submodule $\P\cdot\vv_\kv \hv_\alpha$. To calculate the
differential $d_\F(\vv_\kv \hv_\alpha)$, we at worst have to calculate $d_\F$
for all basis elements in $\F_{|\kv|}$ that are smaller than $\vv_\kv
\hv_\alpha$ with respect to the partial order introduced in
\ref{Algo::Prop::Sorting}.  As there are only finitely many smaller basis
elements in $\F_{|\kv|}$, we conclude that the computation terminates.

Usually the differentials are represented as a list of pairs (preimage,
image)---or (key, value) in computer science terminology---sorted according to
the preimages.  However, we sort the list first according to the images and
only the pairs with the same image value (we cannot expect our maps to be
injective) are then sorted by their preimage values.  In the sequel,
$M_{\vv_\nv (x^\xi \hv_\gamma)}$ denotes a set of pairs $\{\vv_\mv (x^\nu
\hv_\beta), p\}$ where the first component is the preimage and the polynomial
$p$ in the second component defines the image $0 \neq p \vv_\nv (x^\xi
\hv_\gamma)$.

Throughout the algorithm, basis elements are always sorted according to the
order defined in Proposition \ref{Algo::Prop::Sorting}.  We first compute the
partial differential of the complex $\F_{\bullet}$.  Then we reduce this
differential. Among the finitely many sets $M_{\vv_\nv (x^\xi \hv_\gamma)}$, we
start with the greatest element, e.\,g.\ the greatest element $\vv_\kv (
x^\mu \hv_\alpha) \in \F_m$ where $m$ is the largest index such that $\F_m \neq
0$.  If $\kv \subseteq \nmult{P}{\hv_\alpha}$ and $x^\mu = 1$, then this element
is also a generator of the complex $\G_{\bullet}$ and we do not need to
perform a reduction.  If this is not the case, then we check whether there are
possible elementary reductions of type 1 or 2 and perform them all.  If there
is no elementary reduction possible, then we remove this element.  It may
happen that for both the starting and the final point of a reduction path a
map exists such that each point has the same preimage under ``its'' map.  In
this case we simply add the reduced map to the second map and thus combine all
subsequent reduction steps.

The output consists of two sets $G$ and $M$ representing the complex
$\G_{\bullet}$ which defines a free resolution of the ideal $\I$.  The first
set contains the basis elements of free submodules $\G_{m}$ and the second
stores the differentials in the form of sets $M_{\vv_\nv (x^\xi \hv_\gamma)}$ as
introduced above.  The algorithm works for any ideal possessing a Pommaret
basis, even for non-homogeneous ideals.  In the homogeneous case, the obtained
resolution can subsequently be minimised.  Currently, we use for this purpose
the simple linear algebra algorithm described in \cite{clo:uag}.

Although the current implementation is still in a fairly early stage, it
contains already a number of optimisations.  As often involutive standard
representations of the same element are needed, these are stored after they
have been computed once.  Furthermore, we check for every element
$\vv_{\kv}(x^\mu \hv_\alpha)$ whether there is a possible reduction path even
before creating it.  The minimisation procedure has not yet been optimised.
Much more details on the implementation and the used optimisations can be
found in \citep{ma:freeres}.

For benchmarking the implementation, we used a number of standard
examples\footnote{For the benchmarks presented here, we specifically chose
  examples possessing Pommaret bases in the given coordinates.  In our
  experience, between 70\%{} and 80\%{} of the classical benchmark examples
  for Gr\"obner bases computations satisfy this condition.  This is to a
  considerable extent due to the fact that many of these examples are
  zero-dimensional and such ideals always possess a Pommaret basis.  We
  currently work on an implementation realising an efficient deterministic
  algorithm for constructing Pommaret bases for arbitrary ideals by making an
  appropriate linear change of coordinates which is as sparse as possible.  A
  description of this work will appear elsewhere.}  given in \citep{ginv}.  As
most of these ideals are not homogeneous, we homogenised them by adding a new
smallest variable, also we used always $\kk = \ZZ / 101 \ZZ$ as the base
field.  In addition, we used the following two examples where we always worked
over the base field $\kk = \ZZ / 101 \ZZ$.

\begin{example}\label{ex:conca}
  In the polynomial ring $\P = \kk[x_1, \dots, x_n]$ we consider the ideal $\I
  = \langle x_1^2, \dots , x_n^2, (x_1 + \cdots + x_n)^2 \rangle$ which
  possesses a homogeneous Pommaret basis.
\end{example}

\begin{example}\label{ex:tangent}
  Let $ 6 \leq g \in \mathbb{N}$ and $\P = \kk[x_0, \dots, x_{g-4}]$. Then we
  generate the ideal $\I$ by the following binomials with $2 \leq i \leq j
  \leq g - 2$
  \begin{align*}
    (i + j - 1)x_{i-2}x_{j-2} - (i \cdot j)x_{i + j - 3} x_{g -4}\,, \qquad&
        i + j \leq g - 1\,,\\
    (2 g - i - j - 1) x_{i - 2}x_{j - 2} - 
    (g - i) \cdot (g - j) x_{i + j - g} x_{g - 4}\,, \qquad&
        i + j > g - 1\,.
  \end{align*}
  This example was deduced from \cite[Ex.~6.4]{lss:minres}.  As their example
  leads to some negative indices, we modified it a bit so that we only get
  indices between $0$ and $g - 4$.  This ideal also possesses a homogeneous
  Pommaret basis.
\end{example}  

For the benchmarks presented in Table \ref{tab:res_benchmarks}, we used a
MacBook Pro with 2.53 GHz Intel Core 2 Duo processor and 4GB DDR3 main memory.
Besides the \cocoalib, we used \textsc{Macaulay2} \citep{mac2} and
\textsc{Singular} \citep{sing} for comparison.  For both systems we used the
standard resolution command \texttt{res} which uses La Scala's method
\citep{lss:minres} to compute the resolutions.  The running times are given in
seconds and we aborted computations after two hours.  A * marks when we run
out of time or memory.  The timings obtained with our implementation are split
into two parts: \emph{Red} gives the time need to compute the complex
$\G_{\bullet}$, i.\,e.\ the non-minimal resolution, and \emph{Minim} the time
required by the subsequent minimisation.

\begin{table}
  \centering
  \begin{tabular}{|l|r|r|r|r|r|}
    \hline
    ~                                  & \textbf{CoCoALib} & \textbf{Red.}& \textbf{Minim.} & \textbf{Macaulay2} & \textbf{Singular} \\ \hline
    Ex. \ref{ex:conca} ($n = 7$ )      & 17.777            & 2.383             & 15.394                & 4.527              & 593.780           \\ \hline
    Ex. \ref{ex:conca} ($n = 8$ )      & 928.853           & 22.338            & 906.515               & 483.931            & *                 \\ \hline
    Ex. \ref{ex:tangent} ($g = 11$)    & 3.273             & 0.584             & 2.689                 & 0.499              & 0.440             \\ \hline
    Ex. \ref{ex:tangent} ($g = 12$)    & 30.426            & 1.833             & 28.593                & 6.828              & 4.710             \\ \hline
    Reimer 5                           & 12.927            & 7.970             & 4.957                 & 8.756              & 0.880             \\ \hline
    Noon 5                             & 6.189             & 4.064             & 2.125                 & 0.252              & 0.130             \\ \hline
    Noon 6                             & 691.004           & 130.652           & 560.352               & 30.831             & 7.420             \\ \hline
    Redeco 7                           & 25.918            & 9.793             & 16.125                & 7.703              & 0.440             \\ \hline
    Redeco 8                           & 1\,270.735        & 168.005           & 1\,102.730            & 862.337            & 19.650            \\ \hline
    Eco 7                              & 31.914            & 15.727            & 16.187                & 138.369            & 23.490            \\ \hline
    Eco 8                              & 3\,024.956        & 365.836           & 2\,659.120            & *                  & 2\,370.020        \\ \hline
    Katsura 6                          & 133.124           & 49.585            & 84.539                & 161.985            & 26.670            \\ \hline
    Katsura 7                          & 6\,288.220        & 1\,146.260        & 5\,141.960            & *                  & 2\,439.710        \\ \hline
    Cyclic 6                           & 14.940            & 4.358             &10.582                 & 2.823              & 1\,413.320        \\ \hline
  \end{tabular}\\[\baselineskip]
  \caption{Timings for computing minimal free resolutions of some classical
    examples} 
  \label{tab:res_benchmarks}
\end{table}

Obviously, our current implementation is still generally slower than either
\textsc{Macaulay2} or \textsc{Singular}, although one can see that---at least
compared to \textsc{Macaulay2}---its relative performance improves the larger
the examples get.  The main reasons are the size of the complex $\G_{\bullet}$
(see Table \ref{tab:betti_benchmarks} below) and the still very naive
minimisation process.  In most examples, we need much more time to minimise
$\G_{\bullet}$ than to construct it.  There are a number of quite obvious
possible optimisations which should bring considerably savings.  We hope to
implement these in the near future.

The real power of our approach becomes apparent when one considers the problem
of determining the Betti numbers.  Often knowledge of the Betti numbers is
sufficient and one does not really need the whole resolution.  To our
knowlege, however, all current implementations compute Betti numbers via the
minimal resolution.  This also becomes evident by the fact that for both
\textsc{Macaulay2} and \textsc{Singular} the timings for the minimal
resolution and for the Betti numbers, respectively, hardly differ.

In our approach, it is easily possible to modify the above presented
algorithms so that they determine only the constant part of the complex
$\G_{\bullet}$.  If we perform an elementary reduction of type 2, then the
degree of the map does not change.  For an elementary reduction of type 1, the
degree increases by one.  Thus if we start with the constant part of the
two-sided Koszul complex $\F_{\bullet}$ and only apply reductions of type 2,
then we obtain the constant part of $\G_{\bullet}$.  It follows from the
explicit form \eqref{eq:algDiffF} of the differential $d_{\F}$ that the left
summand yields always elements of degree one and the right summand elements of
degree zero.  Hence, by simply skipping the left summands, we directly obtain
the constant part of $\G_{\bullet}$.

The Betti numbers of $\I$ are now easily computed.  Because of the above
proven isomorphy between the complex $\G_{\bullet}$ and the resolution induced
by the Pommaret basis, the bigraded ranks $r_{i,j}$ of the components of the
complex $\G_{\bullet}$ can be directly determined with \eqref{eq:resrank}.
Then, as described above, we construct (degreewise) the constant part of the
matrices of $d_{\G}$.  Subtracting their ranks from the corresponding
$r_{i,j}$ yields the Betti numbers $b_{i,j}$.  We emphasise that computing
these ranks requires only linear algebra over the base field $\kk$ and not
over the polynomial ring $\P$ as for a minimisation.  

\begin{table}
  \centering
  \begin{tabular}{|l|r|r|r|r|r|}
    \hline
    ~                              & $\boldsymbol{\Sigma}$\textbf{-PBetti}& $\boldsymbol{\Sigma}$\textbf{-Betti}  & \textbf{CoCoALib} & \textbf{Macaulay2} & \textbf{Singular} \\ \hline
    Ex. \ref{ex:conca} ($n = 8$ )   & 12066               & 3770           & 11.118            & 483.931            & *                 \\ \hline
    Ex. \ref{ex:conca} ($n = 9$ )    & 44322               & 7540          & 223.083           & *                  & *                 \\ \hline
    Ex. \ref{ex:tangent} ($g = 14$)  & 20482               & 9328           & 23.619            & 765.979            & 710.830          \\ \hline
    Ex. \ref{ex:tangent} ($g = 15$)  & 45058               & 19670          & 175.845           & *                  & *                \\ \hline
    Ex. \ref{ex:tangent} ($g = 16$)  & 98306               & 41466          & 1\,460.890        & *                  & *                \\ \hline
    Reimer 6                         & 5302                & 64            & 57.673            & 1\,908.11          & 283.900           \\ \hline
    Noon 6                          & 9558                & 322            & 15.010            & 30.831             & 7.420             \\ \hline
    Noon 7                          & 56666               & 770           & 372.791           & *                  & *                 \\ \hline
    Redeco 8                        & 6828                & 256            & 15.352            & 862.337            & 19.650            \\ \hline
    Redeco 9                         & 27308               & 512           & 248.092           & *                  & *                 \\ \hline
    Redeco 10                      & 109228              & 1024            & 6\,981.240        & *                  & *                 \\ \hline
    Eco 7                            & 1828                & 656           & 2.285             & 138.369            & 23.490            \\ \hline
    Eco 8                            & 6916                & 1248          & 31.204            & *                  & 2\,370.020        \\ \hline
    Eco 9                           & 28292               & 6188            & 406.463           & *                  & *                \\ \hline
    Katsura 6                        & 1812                & 128           & 3.883             & 161.985            & 26.670            \\ \hline
    Katsura 7                        & 6900                & 256           & 49.162            & *                  & 2\,439.710        \\ \hline
    Katsura 8                      & 27252               & 512            & 1\,169.300        & *                  & *                  \\ \hline
    Cyclic 6                        & 1060                & 320           & 1.158             & 2.823              & 1\,413.320         \\ \hline
    Cyclic 7                        & 10356                & 1688        & 107.591           & 2\,453.73          & *                  \\ \hline
  \end{tabular}\\[\baselineskip]
  \caption{Timings for computing Betti numbers of some classical examples}
  \label{tab:betti_benchmarks}
\end{table}

The benchmarks presented in Table \ref{tab:betti_benchmarks} show that our
approach is generally much faster than the standard methods requiring the
minimal free resolution (often by orders of magnitude) and it allows for the
treatment of considerably larger examples.  In particular, it scales much
better when examples are getting larger.  If one compares for instance the
timings for Eco 7 and Eco 8 or for Katsura 6 and Katsura 7, respectively, then
they increase in our approach by a factor of about 13 whereas
\textsc{Singular} needs roughly 100 times longer.  

In Table \ref{tab:betti_benchmarks} we also exhibit some data about the sizes
of the resolutions.  The considered benchmarks are too large to write down
their full Betti diagrams.  Therefore, as a simple measure for their sizes we
just include the total sum of all Betti numbers (column ``$\Sigma$-Betti'').
For comparison, we also show the corresponding values of the resolution
induced by the Pommaret basis (column ``$\Sigma$-PBetti'').  One can see that
for some examples the non-minimal resolution is up to 100 times larger,
whereas for other examples the factor is as low as 2.  In some families of
examples the factor seems to remain about constant when moving to larger
members, in other families the factor grows considerably.  To some extent
these observations can be explained from the combinatorial structure of the
differential \eqref{eq:diffG}, but we have not yet performed a detailed
analysis.


\section{The Monomial Case}
\label{sec:monom}

We call a monomial ideal $\I$ \emph{quasi-stable}, if it possesses a finite
monomial Pommaret basis.  Such ideals can be characterised by a combinatorial
condition generalising the definition of stable ideals.\footnote{See
  \citep[Prop.~4.4]{wms:comb2} for a number of equivalent characterisations of
  these ideals independent of Pommaret bases.}  Another explanation of the
terminology is given by the fact that for any degree $q\geq\reg{\I}$ the
truncation $\I_{\geq q}$ is stable.

Let $\H=\{h_{1},\dots,h_{s}\}$ be the Pommaret basis of $\I$.  For any
generator $h_{\alpha}$ and any non-multiplicative variable
$x_{k}\in\nmult{P}{h_{\alpha}}$ there exists a unique index $\Delta(\alpha,k)$
and a unique term $t_{\alpha;k}\in\kk[\mult{P}{h_{\Delta(\alpha,k)}}]$ such
that $x_{k}h_{\alpha}=t_{\alpha;k}h_{\Delta(\alpha,k)}$.  With these notations
one can now give a simplified version of Theorem \ref{thm:highsyz} which
entails that a weighted version of the $P$-graph with the terms $t_{\alpha;k}$
as weight on the edge from $h_{\alpha}$ to $h_{\Delta(\alpha,k)}$ contains all
necessary information about the resolution.

\begin{theorem}{\citep[Thm.~7.2]{wms:comb2}}\label{thm:monres}
  Let $\I$ be a quasi-stable monomial ideal with Pommaret basis
  $\H=\{h_{1},\dots,h_{s}\}$.  A Pommaret basis $\H_{j}$ of the $j$th syzygy
  module $\syz{j}{\H}$ with respect to the Schreyer order $\prec_{\H_{j-1}}$
  is given by
  \begin{equation}\label{eq:monsyz}
    \Sv_{\alpha;\kv}=
        \sum_{\ell=1}^j(-1)^{j-\ell}\bigl(x_{k_\ell}\ev_{\alpha;\kv_\ell}-
                    t_{\alpha,k_\ell}\ev_{\Delta(\alpha,k_{\ell});\kv_\ell}\bigr)\,.
  \end{equation}
\end{theorem}

\citet{ht:rescones} introduced the notion of \emph{linear quotients}.  In our
``reverse'' conventions, a monomial ideal $\I$ has linear quotients with
respect to an ordered basis $\{h_{1},\dots,h_{r}\}$, if the colon ideals
$\lspan{h_{k+1},\dots,h_{r}}:h_{k}$ are all generated by a subset
$\X_{k}\subseteq\X$.  The following result exhibits the relation of this
notion to Pommaret bases.
 
\begin{proposition}{\citep[Prop.~26]{wms:quasigen}}\label{prop:linquot}
  Let $\H=\{h_{1},\dots,h_{s}\}$ be a $P$-ordered monomial Pommaret basis of
  the quasi-stable monomial ideal $\I\lhd\P$.  Then $\I$ possesses linear
  quotients with respect to the basis $\H$ and
  \begin{equation}\label{eq:colon}
    \lspan{h_{\alpha+1},\dots,h_{s}}:h_{\alpha}=\lspan{\nmult{P}{h_{\alpha}}}
    \qquad \alpha=1,\dots s-1\;.
  \end{equation}
  Conversely, assume that $\H=\{h_{1},\dots,h_{s}\}$ is a monomial generating
  set of the monomial ideal $\I\lhd\P$ such that (\ref{eq:colon}) is satisfied
  and $\cls{h_{s}}=n$.  Then $\I$ is quasi-stable and $\H$ its Pommaret basis.
\end{proposition}

Let the ordered set $\{m_1,\dots,m_s\}$ generate an ideal $\I\lhd\P$ and
consider the following short exact sequence
\begin{equation}\label{ses}
  0\rightarrow \P/\tilde{\I}\stackrel{\cdot m_1}{\longrightarrow}
  \P/\I'\longrightarrow \P/\I\rightarrow 0
\end{equation}
where $\tilde{\I}=\I: m_1$ and $\I'=\lspan{m_2,\dots,m_s}$.  A free resolution
of $\I$ can now always be obtained as a mapping cone of resolutions of
$\tilde{\I}$ and $\I'$.  We first note the following simple consequences of
Proposition \ref{prop:linquot} and the definition of a $P$-ordering.

\begin{lemma}\label{lem:I12}
  Let $\I\lhd\P$ be a quasi-stable monomial ideal and $\H=\{h_1,\dots,h_s\}$ a
  $P$-ordered Pommaret basis of it.  Then
  \begin{enumerate}
  \item $\tilde{\I}=\lspan{x_k,\dots,x_n}$, where $k=\cls{h_1}$, and
  \item $\I'$ is again a quasi-stable ideal with Pommaret basis
    $\{h_2,\dots,h_s\}$.
  \end{enumerate}
\end{lemma}

Since $\tilde{I}$ is generated by a subset of the variables, it is minimally
resolved by a Koszul complex.  By adding one element of $\H$ in each
iteration, we can construct a resolution of $\I$ as an iterated mapping cone.

\begin{theorem}\label{thm:mapcone}
  Let $\H=\{h_{1},\dots,h_{s}\}$ be a $P$-ordered Pommaret basis of the
  quasi-stable monomial ideal $\I\lhd\P$ and the complex $(\C,d)$ the iterated
  mapping cone produced by the short exact sequences
  \begin{equation}\label{eq:diag}
    \S_\alpha:\;  0\rightarrow \P/\tilde{\I}_\alpha
             \stackrel{\cdot h_\alpha}{\longrightarrow} 
             \P/\I'_\alpha\longrightarrow \P/\I_\alpha\rightarrow 0
  \end{equation}
  with ideals $\I_\alpha=\lspan{h_{\alpha},\dots,h_s}$,
  $\I'_i=\lspan{h_{\alpha+1},\dots,h_s}$ and
  $\tilde{\I}_\alpha=\lspan{x_{k_{\alpha}},\cdots,x_n}$ where
  $k_{\alpha}=\cls{h_\alpha}$.  Then $(\C,d)$ is isomorphic to the resolution
  of $\I$ induced by the Pommaret basis $\H$.
\end{theorem}

\begin{proof}
  It is clear that we obtain a resolution, so it only remains to prove that it
  is the same as the one induced by the Pommaret basis $\H$.  The proof
  proceeds by induction on $s$, the number of generators in $\H$.

  For $s=2$, the result is easily proven.  In this case, $h_2=x_n^a$ for some
  $a\in\mathbb{N}$ and $h_1=x_{n-1}^bx_n^{a-1}$ for some $b\in\mathbb{N}$ and
  this ideal is stable.  Now the assertion follows from the already mentioned
  fact that in this case the Eliahou-Kervaire resolution coincides with the
  resolution induced by the Pommaret basis.

  Assume that the result is true for all $s-1\geq2$. We are now in the
  situation of the sequence (\ref{ses}).  We have the following diagram where
  $\phi$ is some chain complex morphism that lifts the map given by
  multiplication with $h_\alpha$:
  \begin{center}\begin{tikzpicture}
      \node (1) at (0,0) {\(\F'_2\)} ;
      \node (2) at (2,0) {\(\F'_1\)} ;
      \node (3) at (4,0) {\(\P\)} ;
      \node (4) at (6,0) {\(\P/\I'\)} ;
      \node (5) at (0,1.5) {\(\tilde{\F}_2\)} ;
      \node (6) at (2,1.5) {\(\tilde{\F}_1\)} ;
      \node (7) at (4,1.5) {\(\P\)} ;
      \node (8) at (6,1.5) {\(\P/\tilde{\I}\)} ;
      \node at (7.3,0) {$0$};   
      \node at (7.3,1.5) {$0$};                               

      \begin{scope} [->, font = \footnotesize]
        \draw (1) -- node [above] {\(d'_2\)} (2) ;
        \draw (2) -- node [above] {\(d'_1\)} (3) ;
        \draw (3) -- node [above] {\( \)} (4) ;
        \draw (5) -- node [above] {\(\tilde{d}_2\)} (6) ;
        \draw (6) -- node [above] {\(\tilde{d}_1\)} (7) ;
        \draw (7) -- node [above] {\( \)} (8) ;
        \draw [dashed] (-1,0) -- node [above] {\(\)} (1) ;
        \draw [dashed] (-1,1.5) -- node [above] {\(\)} (5) ;
        \draw  (4) -- node [above] {\(\)} (7,0) ;
        \draw  (8) -- node [above] {\(\)} (7,1.5) ;
        
        \draw (8) -- node [right] {\( \cdot h_\alpha \)} (4) ;
        \draw (7) -- node [right] {\( \cdot h_\alpha \)} (3) ;
        \draw (6) -- node [right] {\( \phi_1 \)} (2) ;
        \draw (5) -- node [right] {\( \phi_2 \)} (1) ;
      \end{scope}
  \end{tikzpicture}\end{center}
  Each module in the mapping cone is given by
  $\C_j=\F'_j\oplus\tilde{\F}_{j-1}$ and the differential is given by
  $d_j=\begin{pmatrix} d'_j & \phi_{j-1}\\ 0& -\tilde{d}_{j-1} \end{pmatrix}$.
  Given a generator $\ev_\alpha\otimes\kv$ of the $j$th module of the mapping
  cone complex, its differential is given by
  $d(\ev_\alpha\otimes\kv)=\phi_{j-1}-\tilde{d}_j(\ev_\alpha\otimes\kv)$.  We
  make here explicit use of the correspondence
  $\ev_\alpha\otimes\kv\leftrightarrow\ev_{\alpha;\kv}$. On the other hand, by
  Theorem \ref{thm:monres}, the differential of the resolution induced by the
  Pommaret basis $\H$ is given by
  \begin{align*}\label{eq:differential}
    \delta(\ev_\alpha\otimes \kv)&=
      \sum_{\ell=1}^j (-1)^{\sigma(\ell,\kv)}x_{k_\ell}\ev_\alpha\otimes\kv_\ell -
      \sum_{\ell=1}^j (-1)^{\sigma(\ell,\kv)}t_{\alpha,k_\ell}\ev_{\Delta(\alpha,k_\ell)}\otimes\kv_\ell\\
    &= A+B\,,
  \end{align*}
  where ${\sigma(l,\kv)}$ is the place of $l$ in $\kv$. One easily sees that
  $\tilde{d}_j(\ev_\alpha\otimes\kv)=-A$, so we only have to prove that
  $\phi_j(\ev_\alpha\otimes\kv)=B$.

  Let $\psi_j:\F'_{j-1}\mapsto\F'_j$ be a contracting homotopy for
  $d'_j$. Then $\phi_{j}=\psi_j\phi_{j-1}\tilde{d}_j$.  According to
  \citep[Thm.~5.2]{wms:taylor}, a contracting homotopy $\psi_j$ consists
  essentially of computing the involutive normal form with respect to the
  Pommaret basis of $\F'_i$ which is given by the $j$th syzygies induced by
  the Pommaret basis $\H$ of $I$.

  Now we proceed by induction on $j$. For $j=1$ and $j=2$, we obtain as a
  corollary to \citep[Lemma~7.1]{wms:comb2} by direct computation that
  \begin{displaymath}
    \phi_j\bigl(\sum_{\ell=1}^j
    (-1)^{\sigma(l,\kv)}x_{k_\ell}\ev_\alpha\otimes\kv_\ell\bigr)=B\,.
  \end{displaymath}

  For the general case, observe that $\tilde{d}_j(\ev_\alpha\otimes\kv)=
  \sum_{\ell=1}^j (-1)^{\sigma(\ell,\kv)}x_{k_\ell}\ev_\alpha\otimes\kv_\ell$.
  Assuming that $\phi_h\bigl(\sum_{\ell=1}^h
  (-1)^{\sigma(\ell,\kv_\ell)}x_{k_\ell}\ev_\alpha\otimes\kv_\ell\bigr)=B$ for
  all $h<j$ and computing $B$ explicitly, we find that
  \begin{multline}
    \phi_{j-1}\tilde{d}_j(\ev_\alpha\otimes\kv)=\\
    \sum_{\ell=1}^j(-1)^{\sigma(\ell,\kv)}x_{k_\ell}\Bigl( 
        \sum_{\substack{k\in\kv_\ell\\
            \cls{\kv_{k\ell}}>\cls{w_{\Delta(1,k)}}}} 
            (-1)^{\sigma(k,\kv_\ell)+1}
            t_{1,k}\ev_{\Delta(1,k)}\otimes\kv_{\ell k} \Bigr)\,.
  \end{multline}
  Using normal form computations, we have that
  \begin{equation}\label{eq:psiphidelta}
    \psi_j\phi_{j-1}\tilde{d}_j(\ev_\alpha\otimes\kv)=
    \sum_{\ell=1}^j(-1)^{\sigma(\ell,\kv)} 
        \sum_{\substack{k\in\kv_\ell\\ 
              \cls{\kv_{k\ell}}>\cls{w_{\Delta(1,k)}}\\ 
              \cls{x_{k_\ell}}>\cls{\kv_{\ell k}}}} 
          (-1)^{\sigma(k,\kv_\ell)+1} t_{1,k}\ev_{\Delta(1,k)}\otimes\kv_{k}\,.
  \end{equation}
  Finally, in order to see that the expression in equation
  (\ref{eq:psiphidelta}) equals $B$, observe that $t_{1,k}$ is always
  multiplicative for $\ev_{\Delta(1,k)}\otimes\kv_k$ and hence the right hand
  side of equation (\ref{eq:psiphidelta}) is involutively autoreduced.
\end{proof}


\section{Conclusions}

In the first part, we combined the construction of a free resolution for
polynomial modules due to \citet{es:inlinsyz} with the theory of Pommaret
bases as given in \citep{wms:comb2}.  This combination makes Sk\"oldberg's
approach via algebraic discrete Morse theory fully algorithmic, as Pommaret
bases provide us with a systematic method for generating presentations with
initially linear syzygies: the existence of such presentations can be seen as
one of the core ideas underlying the theory of Pommaret bases.

A distinctive feature of our algorithm compared to other approaches for
constructing resolutions is the fact that only \emph{one} Pommaret basis
(namely for the given submodule $\U$) is needed whereas usually several
Gr\"obner bases (typically the number is given by $\pd{\U}$) have to be
computed.  Although the evaluation of the closed formula for the differential
might appear very complicated, it requires mainly very cheap operations.  The
only polynomial operations are some involutive normal forms of products
$x^{\mu}\hv_{\alpha}$ for generators $\hv_{\alpha}$ in the Pommaret basis of
$\U$.  As we observed that the same product often appears many times,
significant savings could be achieved by simply storing these.

The main reasons for the not yet satisfactory timings are our currently still
very naive implementation of the minimisation process and the sometimes
extreme difference in the sizes of the non-minimal and the minimal resolution,
respectively.  Here one can expect on one side substantial improvements just
by optimisations of the code.  On the other hand, it is obvious that a
decisive factor is simply the size of the complex $\G_{\bullet}$.  While this
size is completely determined by the Pommaret basis of $\U$, it can be
affected by linear coordinate transformations.  In a forthcoming work, we will
present a deterministic approach to construct generally fairly sparse
coordinate transformations such that the leading module $\lt{\U}$ is not only
quasi-stable but stable (or even strongly stable).  Then the complex
$\G_{\bullet}$ should be considerably smaller; more precisely, it will have
the same size as the minimal resolution of $\lt{\U}$.  Finally, our current
approach first determines the full complex $\G_{\bullet}$ and then minimises
it.  Probably very significant gains in efficiency are possible by
interweaving the construction of this complex with the minimisation process
(as it is done by classical algorithms to compute minimal resolutions).

The full power of our approach becomes already now apparent, if one does not
need the whole resolution but only the Betti numbers.  To our knowledge we
presented here the first method to compute them which does not require the
minimal resolution.  As Table \ref{tab:betti_benchmarks} demonstrates, for all
examples save one our implementation was the fastest to compute the Betti
numbers, often even by orders of magnitude.  The main reasons are of course
that, due to the knowledge of a closed form of the differential, we can
construct directly only the constant part of the resolution and the subsequent
``minimisations'' require only linear algebra over the base field $\kk$ and
not over the polynomial ring $\P$.  Obviously, similar techniques should exist
for tackling other questions where only certain parts of the minimal
resolution are relevant like an analysis of the linear part of the resolution
or its linear strand.

In the second part of this work, we specialised to a particular class of
monomial ideals, the quasi-stable ideals.  We proved that the resolution
induced by the Pommaret basis is also obtainable via iterated mapping cones.
Thus we showed that this interesting property of the Eliahou-Kervaire
resolution remains valid for our generalisation of it to quasi-stable ideals.
An interesting question here is whether further nice properties of the
Eliahou-Kervaire resolution like the fact that it is a cellular resolution
\citep{M10} also extend to the resolution induced by a Pommaret basis.


\appendix
\section{A Detailed Example}\label{app:ex}

We elaborate on some of the notions introduced in Section \ref{sec:morse}.
Our starting point is the ideal $\I=\langle x_1^2, x_0^2,x_2+x_0\rangle \unlhd
\P = \kk [x_0,x_1,x_2]$ over the base field $\kk = \mathbb{Z}/ 2 \mathbb{Z}$.
A Pommaret basis $\H$ for $\I$ is given by
\begin{displaymath}
  h_1= x_0^2,\ h_2=x_0^2x_1,\ h_3 = x_1^2,\ h_4 = x_2+x_0\,.
\end{displaymath}
We start with the two-sided Koszul complex $(\F, d_\F)$ induced by the
initially linear syzygies associated with the Pommaret basis $\H$, see Lemma
\ref{lem:linsyz}.  This complex has the shape
\begin{displaymath}
  0 \longrightarrow\F_3 = \P \otimes_\kk \Lambda_3 \V \otimes_\kk I 
  \longrightarrow \cdots \longrightarrow 
  \F_0 =\P \otimes_\kk \Lambda_0 \V \otimes_\kk I = \P \otimes_\kk I
\end{displaymath}
with the differential given by \eqref{eq:diffF}.

In order to construct the resolution $(\G, d_\G)$, more precisely its
differential defined by \eqref{eq:diffG}, we study the graph $\Gamma_\F$.  As
this graph is huge, we will only show how to find $d_\G (\vv_{1,2} h_2)$.  The
argument $\vv_{1,2} h_2$ is indeed an element of the module $G_2$ as $1,2 \in
\crt{(h_2)}$.  According to \eqref{eq:diffFka}, the first step is to calculate
the image $d_\F (\vv_{1,2} h_2) = \sum_{\mv, \mu, \gamma} Q_{\mv, \mu,
  \gamma}^{(1,2),2} \vv_{\mv} (x^\mu h_\gamma)$.  For each non-vanishing
coefficient $Q_{\mv, \mu, \gamma}^{(1,2),2}$, the graph $\Gamma_\F$ contains
the edge $\vv_{1,2} \otimes h_2 \rightarrow \vv_{\mv} (x^\mu h _\gamma)$.  By
the definition \eqref{eq:diffF} of the differential $d_{\F}$, we have
\begin{displaymath}
  d_\F (\vv_{1,2} h_2)=x_1 \vv_2 h_2 + \vv_2 x_0^2 h_3 +
      x_2 \vv_1 h_2 + \vv_1 x_0^2 x_1 h_4 +\vv_1 x_0 h_2
\end{displaymath}
So we get the top half of the following graph (which we want to be a subgraph
of $\Gamma_{\F_\bullet}^A$, see the subsequent discussion):
\tikzset{
  commutative diagrams/.cd,
  arrow style=tikz,
  diagrams={>=open triangle 45}}
\begin{equation}\label{eq:graph}
  \begin{tikzcd}[scale=10, column sep=huge, row sep=tiny, text height=0.75ex]
    & \vv_1 h_2 \\
    & \vv_2 h_2 \\
    \vv_{1,2} h_2  \ar[start anchor=real east, end anchor= text]{rdd}
                  \ar[start anchor=real east, end anchor= text]{rd}
                  \ar[start anchor=real east, end anchor= text]{r}
                  \ar[start anchor=real east, end anchor= text]{ru}[description]{x_1}
                  \ar[start anchor=real east, end anchor= text]{ruu}[description]{x_2}
    & {\vv_1(x_0^2 x_1 h_4) } \\
    \dots          \ar[dashed, leftarrow, start anchor=real east, end anchor= text]{ru}
    & {\vv_2( x_0^2 h_3) } \\
   \dots          \ar[dashed, leftarrow, start anchor=real east, end anchor= text]{ru}
    & {\vv_1(x_0 h_2)    } \\
    \vv_{0,1} h_2     \arrow[leftarrow, start anchor=10, end anchor= text]{ru}
                     \arrow[start anchor=real east, end anchor= text]{rdd}
                     \arrow[start anchor=real east, end anchor= text]{rd}[description]{x_1}
                     \arrow[start anchor=real east, end anchor= text]{r}[description]{x_0}
    & {\vv_1 h_2} \\
    & {\vv_0 h_2} \\
    & {\vv_0( x_0^2 h_3) }
  \end{tikzcd}
\end{equation}

According to \eqref{eq:diffG}, we search for reduction paths originating in
the vertices on the right side of the graph and therefore we must look at the
graph $\Gamma_{\F_\bullet}^A$, where $A$ is the Morse matching defined in
\eqref{eq:matching} and the paragraph following it.  It immediately follows
from \eqref{eq:matching} that no path (in $\Gamma_{\F_\bullet}$) ending in
$\vv_2 h_2$ or $\vv_1 h_2$, respectively, is contained in the Morse matching,
so there are no reduction paths originating in either of these two vertices.

For the other vertices, we look at $\vv_1(x_0 h_2)$ and note that there are
also reduction paths originating in the remaining vertices (indicated by the
dashed arrows).  The edge $\vv_{0,1} h_2 \rightarrow \vv_1(x_0 h_2)$ is
contained in the Morse matching $A$ or equivalently the graph
$\Gamma_{\F_\bullet} ^A$ contains the edge $\vv_1 x_0 h_2 \rightarrow
\vv_{0,1} h_2$.  Now we need to find the edges originating in $\vv_{0,1} h_2$,
i.\,e.\ to calculate $d_\F (\vv_{0,1} h_2)$.  Again, by \eqref{eq:diffF}, we
have
\begin{displaymath}
  d_\F (\vv_{0,1} h_2) = x_0 \vv_1 h_2 + \vv_1(x_{0}h_2) + x_1 \vv_0 h_2 +
      \vv_0(x_0^2 h_3)\,.
\end{displaymath}
This gives us the bottom half of the above graph.

Then we should reiterate this process for the three new vertices we just
constructed.  But this time, \eqref{eq:matching} tells us that no edges ending
in either of these three vertices are contained in the Morse matching.  So we
have found all reduction paths originating in $\vv_{1}(x_{0} h_2)$.

In order to find the associated reduction maps, we ``collect the
coefficients'' along each reduction path.  Note that in general, we would have
to pay a little more attention to signs and coefficients, which we have
avoided here by working in $\mathbb{Z}/ 2 \mathbb{Z}$.  For longer paths, all
coefficients along the path have to be multiplied.  Here, all paths are
elementary reduction paths, so we can also look at their types.

The paths $\vv_1(x_0 h_2)\rightarrow\vv_{0,1}  h_2 \rightarrow \vv_1 h_2$ and
$\vv_1(x_0 h_2)\rightarrow\vv_{0,1} h_2 \rightarrow \vv_0 h_2$, respectively,
are of type 1.  Essentially the  only things that happen are variables/indices
being  moved around  towards components  more to  the left  within the  tensor
product.   This is  due to  the fact  that those  paths are  coming from  left
summands  in \eqref{eq:diffF}  of  the differential  in  the two-sided  Koszul
complex.

The right summands in \eqref{eq:diffF} yield the path $\vv_1 (x_0h_2)
\rightarrow\vv_{0,1} h_2 \rightarrow\vv_0 (x_0^2 h_3)$, which accordingly is of
type 2.  Here we take the product of an element of the Pommaret basis with a
critical variable, $x_1 h_2$.  The vertex comes from the involutive standard
representation of this product.

However, for the differential $d_\G (\vv_{1,2} h_{2})$, only one of these
reduction paths is relevant, as the restrictions of the sums in
\eqref{eq:diffG} require that only those reduction paths appear that end in a
vertex $\vv_{\ellv}h_\beta$ where $\ellv \subseteq \crt{(h_\beta)}$.  Of the
reduction paths in our example, only the path ending in $\vv_1 h_2$ satisfies
this condition.  The final result is then
\begin{displaymath}
  d_\G (\vv_{1,2} h_{2})= (x_2+x_0) \vv_1 h_2 + x_1 \vv_2 h_2 +x_0^2 \vv_2 h_3
\end{displaymath}
and we have explicitly demonstrated the construction of all terms in it except
the last one which stems from one of the dashed pathes in \eqref{eq:graph}.


\bibliography{PommResol}
\bibliographystyle{elsarticle-harv}

\end{document}