
% Copyright (c) 1991-2002, The Numerical ALgorithms Group Ltd.
% All rights reserved.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions are
% met:
%
%     - Redistributions of source code must retain the above copyright
%       notice, this list of conditions and the following disclaimer.
%
%     - Redistributions in binary form must reproduce the above copyright
%       notice, this list of conditions and the following disclaimer in
%       the documentation and/or other materials provided with the
%       distribution.
%
%     - Neither the name of The Numerical ALgorithms Group Ltd. nor the
%       names of its contributors may be used to endorse or promote products
%       derived from this software without specific prior written permission.
%
% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
% IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
% TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
% PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER
% OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
% EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
% PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES-- LOSS OF USE, DATA, OR
% PROFITS-- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
% LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
% NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
% SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.



\exptypeindex{DistributedMultivariatePolynomial}
\exptypeindex{HomogeneousDistributedMultivariatePolynomial}

\spadtype{DistributedMultivariatePolynomial} and
\spadtype{HomogeneousDistributedMultivariatePolynomial}, abbreviated
\spadtype{DMP} and \spadtype{HDMP}, respectively, are very similar to
\spadtype{MultivariatePolynomial} except that they are represented and
displayed in a non-recursive manner.
\xtc{
}{
\spadcommand{(d1,d2,d3) : DMP([z,y,x],FRAC INT) \bound{d1dec d2dec d3dec}}
}
\xtc{
The constructor
\spadtype{DMP} orders its monomials lexicographically while
\spadtype{HDMP} orders them by total order refined by reverse
lexicographic order.
}{
\spadcommand{d1 := -4*z + 4*y^2*x + 16*x^2 + 1 \bound{d1}\free{d1dec}}
}
\xtc{
}{
\spadcommand{d2 := 2*z*y^2 + 4*x + 1 \bound{d2}\free{d2dec}}
}
\xtc{
}{
\spadcommand{d3 := 2*z*x^2 - 2*y^2 - x \bound{d3}\free{d3dec}}
}
\xtc{
These constructors are mostly used in \texht{Gr\"{o}bner}{Groebner}
\index{Groebner basis@{Gr\protect\"{o}bner basis}}
basis calculations.
}{
\spadcommand{groebner [d1,d2,d3] \free{d1 d2 d3}}
}
\xtc{
}{
\spadcommand{(n1,n2,n3) : HDMP([z,y,x],FRAC INT) \bound{ndec}}
}
\xtc{
}{
\spadcommand{(n1,n2,n3) := (d1,d2,d3) \free{ndec}\bound{n}\free{d1 d2 d3}}
}
\xtc{
Note that we get a different
\texht{Gr\"{o}bner}{Groebner} basis
when we use the \spadtype{HDMP} polynomials, as expected.
}{
\spadcommand{groebner [n1,n2,n3] \free{n}}
}

\spadtype{GeneralDistributedMultivariatePolynomial} is somewhat
more flexible in the sense that as well as accepting a list of
variables to specify the variable ordering, it also takes a
predicate on exponent vectors to specify the term ordering.
With this polynomial type the user can experiment with the effect
of using completely arbitrary term orderings.
This flexibility is mostly important for algorithms such as
\texht{Gr\"{o}bner}{Groebner} basis calculations which can be very
sensitive to term ordering.
\exptypeindex{GeneralDistributedMultivariatePolynomial}

For more information on related topics, see
\spadref{ugIntroVariables},
\spadref{ugTypesConvert},
\xmpref{Polynomial},
\xmpref{UnivariatePolynomial}, and
\xmpref{MultivariatePolynomial}.
%
\showBlurb{DistributedMultivariatePolynomial}
