% polynomial part 12.2.91 hk
% non-commutative polynomials 18.3.92 hk

\section{Non-commutative Solvable Polynomial System} %---------------

\label{ncalg.sec}
\index{computing in solvable polynomial rings}
\index{solvable polynomial ring, computing in}

A solvable polynomial ring is an ordinary commutative polynomial ring 
$R = \K\lbrack X_1,$ $\ldots,$ $X_n\rbrack$
equipped with a new non-commutative multiplication $*$.
The field $\K$ is assumed to be commutative and to commute 
with the indeterminates $X_1, \ldots, X_n$.
The set $T$ of terms (power-products of indeterminates)
is supposed to be linearly ordered by an admissible order $<_T$ such that 
the order is compatible with the new multiplication $*$. 
The axioms of solvable polynomial rings are discussed in 
section \ref{ncaxiom.sec} and where first defined by \cite{KW88}. 
In the implementation we use the ordinary commutative 
distributive polynomial representation.  The non-commutative 
product $*$ is defined via relations, which are elements of a 
free associative algebra.\index{implementation}
These relations are represented as triples 
$$ 
  (u, v, p)
$$ 
of commutative terms $u, v \in T$ and a commutative polynomial 
$p \in R$, such that 
$$
  u * v = p
$$ 
and $p$ is of the form 
$$
  c \cdot u \cdot v + p'
$$ 
with $0 \neq c \in \K$ and $p' \in R$, where $p' <_T u \cdot v$. 
A table (implemented as list) of these relations is required as 
input parameter for most algorithms for solvable polynomials. 


\subsection{Algorithms} %---------------------

\label{ncdip.alg}
The programs of the most important non-commutative solvable type 
distributive polynomial algorithms are summarized in the following.
Only rational polynomial programs are discussed.

As the definition of the solvable polynomial ring 
and the distributive representation suggests 
the algorithms will be constructed in the following way:
\begin{enumerate}
\item Loop on the monomials in the polynomials:
      \begin{enumerate}
      \item perform operations on exponent vectors by recursive 
            application of the non-commutative product algorithm,
            using and updating the relation table,
      \item perform operations on the base coefficients of the 
            term and the non-commutative product polynomial,
      \end{enumerate}
      Construct resulting polynomials.
\item Return the results. 
\end{enumerate}

The complexity of polynomial algorithms will 
therefore depend mainly on five factors:
\begin{enumerate}
\item the size of the base coefficients of the polynomials,
\item the size of the base coefficients of the commutator relations, 
\item the number of terms of the polynomials, 
\item the degree and the number of terms of the commutator relations, 
\item the number of variables. 
\end{enumerate}
These quantities are as defined in the section on the
recursive representation algorithms.
We will continue to write $L(a)$ for $O(L(a))$, 
that means we will not count for constant factors.
The computing time functions $t, \tma, \tmi, \ta$ 
are defined as before in section \ref{secCOMPL}.
\index{complexity}

\def\DIR{{\cal DR}}
\def\DI{{\cal D}}
\def\B{{\cal B}}
\def\CR{{\cal CR}}
Let
$\A$ be the set of atoms,
$\A^{+}$ be the set of non-negative atoms,
$\L$ be the set of lists,
$\O = \A \cup \L$ be the set of objects,
$R = \{ x \in \O: \ x$ represents an element of ${\rm \bf Q} \}$ 
be the set of rational numbers, 
$\B = \{ x \in \O: \ x$ represents an element of a 
         base coefficient ring $\}$ 
be the set of base coefficients, 
$\DI_r = \{ x \in \O: \ x$ represents a multivariate polynomial 
         in $r$ variables $\}$ 
be the set of distributive polynomials,
$\DIR_r = \{ x \in \O: \ x$ represents a multivariate polynomial over
           ${\rm \bf Q}$ in $r$ variables $\}$ 
be the set of distributive rational polynomials. 
$\CR_r = \{ x \in \O: \ x$ represents triples of multivariate polynomials 
           over ${\rm \bf Q}$ in $r$ variables $\}$ 
be the set of commutator relations of distributive rational polynomials. 
\index{rational polynomial}\index{rational number}
\index{polynomial}\index{distributive polynomial}
\index{commutator relation}

The programs are summarized in the following table

\begin{deflist}{$C \gets DINPPR(T,A,B)$}
\item[$C \gets DINPPR(T,A,B)$] $T \in \CR_r$, $A, B, C \in \DIR_r$.
     $C = A * B$ is the non-commutative product of $A$ and $B$ 
     in a solvable polynomial ring with commutator relations $T$. 
     \index{DINPPR}
\item[$C \gets DINCCO(T,A,B)$] $T \in \CR_r$, $A, B, C \in \DIR_r$.
     $C = A * B - B * A$ is the commutator of $A$ and $B$ 
     in a solvable polynomial ring with commutator relations $T$. 
     \index{DINCCO}
\item[$B \gets DINPEX(T,A,n)$] $T \in \CR_r$, $A, B \in \DIR_r$, 
     $n \in \A$.
     $B = A^n$ is the non-commutative $n$-th power of $A$ 
     in a solvable polynomial ring with commutator relations $T$. 
     \index{DINPEX}
\item[$P \gets NPREAD(T)$] $T \in \CR_r$, $P \in \L\DIR_r$. 
     A list of distributive rational polynomials 
     is read from the actual input stream. 
     All multiplications of variables mean the non-commutative
     $*$-product, even if $*$ is not explicitly written.
     The accepted syntax (with start symbol \verb/polylist/) is:

\begin{verbatim}
 polylist = "(" [ poly { "," poly } ] ")"
 poly     = "(" term { ("+"|"-") term } ")"
 term     = power { [ "*" ] power }
 power    = factor [ "**" atom ]
 factor   = ( rational | ident | "(" poly ")" )
\end{verbatim}

     With the context conditions:
     \begin{enumerate}
     \item the `\verb/atoms/' must be nonnegative,
     \item `\verb/ident/'s which appear in `\verb/poly/' must 
           be declared in the item `\verb/varlist/' of
           $PREAD$ during the input of $T$, 
     \end{enumerate}
     Examples will be discussed in the exercise section. 
     \index{NPREAD}
\item[$B \gets DINLNF(T,P,A)$] $T \in \CR_r$, $A, B \in \DIR_r$, 
     $P \in \L\DIR_r$.  $B$ is the left normal form of $A$ 
     with respect to $P$
     in a solvable polynomial ring with commutator relations $T$:
     $B = {\rm left-normalform}_P(A)$. 
     \index{DINLNF}
\item[$Q \gets LIRRSET(T,P)$] and 
\item[$Q \gets DINLIS(T,P)$] $T \in \CR_r$, $P, Q \in \L\DIR_r$. 
     $Q$ is the left irreducible set of $P$ 
     in a solvable polynomial ring with commutator relations $T$. 
     That means every $p \in Q$ is monic and irreducible with respect to 
     $Q \setminus \{ p \}$.
     \index{DINLIS}\index{LIRRSET}
\item[$G \gets LGBASE(T,P,t)$] and 
\item[$G \gets DINLGB(T,P,t)$] $T \in \CR_r$, $P, G \in \L\DIR_r$, 
     $t \in \{ 0, 1, 2 \}$. 
     $G$ is the left Gr\"obner base of $P$
     in a solvable polynomial ring with commutator relations $T$. 
     $t$ is the `trace flag', $t = 0$ if no intermediate 
     output is requred, $t = 1$ if the reduced S--polynomials 
     are to be listed and $t = 2$ for maximal information.
     \index{DINLGB}\index{LGBASE}
\item[$G \gets TSGBASE(T,P,t)$] and 
\item[$G \gets DINCGB(T,P,t)$] $T \in \CR_r$, $P, G \in \L\DIR_r$, 
     $t \in \{ 0, 1, 2 \}$. 
     $G$ is the two-sided Gr\"obner base of $P$
     in a solvable polynomial ring with commutator relations $T$. 
     $t$ is the `trace flag', $t = 0$ if no intermediate 
     output is requred, $t = 1$ if the reduced S--polynomials 
     are to be listed and $t = 2$ for maximal information.
     \index{DINCGB}\index{TSGBASE}

\item[$P \gets CenterPol(T,E)$] and 
\item[$P \gets DINCCPpre(T,E)$] $T \in \CR_r$, $E \in \L(\A^{+r})$, 
     $P \in \L\DIR_r$. 
     $P$ is a list of polynomials in $r$ variables, 
     where the terms are contained in $E$ ($T(p) \subseteq E$, $p \in P$) 
     and each $p \in P$ is in the center of a solvable polynomial ring 
     with commutator relations $T$. 
     Moreover the polynomials in $P$ are written to the actual 
     output stream. 
     \index{CenterPol}\index{DINCCPpre}
\item[$p \gets DINCCP(T,E)$] $T \in \CR_r$, $E \in \L(\A^{+r})$, 
     $p \in \L\DIR_{r+s}$. 
     $p$ is a polynomial in $r+s$ variables, $0 \leq s \leq \vert E \vert$,
     where the $s$ `new' variables indicate parametric coefficients,
     and the `old' terms are contained in $E$ ($T(p) \subseteq E$).
     For any specialization of the parameters to $\Q$, the specialized 
     polynomial $p$ is in the center of a solvable polynomial ring with 
     commutator relations $T$. 
     \index{DINCCP}
\item[$E \gets EVLGTD(r,d,L)$] $r, d \in \A^{+}$, $L \in \L(\A^{+r})$, 
     $E \in \L\L(\A^{+r})$.
     $r$ is the number of variables, $d$ is the total degree 
     and $L$ is a list of already computed terms (used for 
     internal recursion, and initially called with $L$ empty).
     It returns a list $E = (E_0, \ldots, E_d)$ where 
     each $E_i$, $1 \leq i \leq d$, is a list of exponents of 
     terms in $r$ variables of total degree exactly $i$. 
     \index{EVLGTD}
\item[$E \gets EVLGIL(D)$] $D \in \A^{+r}$, $E \in \L(\A^{+r})$.
     $D = (d_1, \ldots, d_r)$ is a list of non-negative atoms
     and $E$  is a list of of terms, such that for any 
     $(e_1, \ldots, e_r) \in E$, $0 \leq e_i \leq d_i$ holds 
     for $1 \leq i \leq r$. 
     \index{EVLGIL}
\end{deflist}

%\subsection{Example: Input and Gr\"obner bases} %----------------------
For examples see section \ref{ncex.sec}.  

\clearpage 




