Difference between revisions of "ApCoCoA-1:SB.TermRepr"
(New page: <command> <title>SB.TermRepr</title> <short_description>Computes a representation of a term in other terms if it exists.</short_description> <syntax> SB.TermRepr(Term:POLY,TermList:...) |
|||
Line 57: | Line 57: | ||
<type>poly</type> | <type>poly</type> | ||
</types> | </types> | ||
+ | <key>term</key> | ||
<key>TermRepr</key> | <key>TermRepr</key> | ||
<key>SB.TermRepr</key> | <key>SB.TermRepr</key> |
Revision as of 13:38, 20 May 2010
SB.TermRepr
Computes a representation of a term in other terms if it exists.
Syntax
SB.TermRepr(Term:POLY,TermList:LIST of POLY):LIST of INT SB.TermRepr(Term:POLY,TermList:LIST of POLY,ReprType:INT):LIST of INT
Description
This functions tries to compute a term representation of the given term Term in terms of the list TermList. If it is not possible to get such a representation NULL will be returned. If a representation exists a list of integers will be returned which gives the exponents of the power product of the term in the other terms, e.g. for the term Term=x^2y and the list of terms TermList=[x,y] the function will return [2,1] as the representation.
With the optional parameter ReprType it is possible to choose between different ways of getting a possible representation.
@param Term A term in the current ring.
@param TermList A list of terms in the current ring.
@return A list of integers, which gives the representation, or NULL.
The following parameter is optional:
@param ReprType Either 0,1 or 2. With this parameter it is possible to choose between different ways of getting the representation: By ReprType=0 a toric ideal is used to compute the representation. This is also the default value. By ReprType=1 algebra homomorphisms are used, by ReprType=2 a system of diophantine equations is used to compute the representation.
Example
Use R::=QQ[x,y]; SB.TermRepr(x^2y^2,[x,y]); SB.TermRepr(x^2y^2,[xy^2,x,y]); [2, 2] ------------------------------- [1, 1, 0] ------------------------------- -- Done. -------------------------------
Example
Use R::=QQ[x,y,z]; L:=[x^2y^4z^8,xy^3,z^5]; SB.TermRepr(xy^4z,L); -- for xy^4z no representation is existing T:=L[1]^3L[3]^2; -- T = (x^2y^4z^8)^3 * (xy^3)^0 * (z^5)^2 T; SB.TermRepr(T,L); NULL ------------------------------- x^6y^12z^34 ------------------------------- [3, 0, 2] ------------------------------- -- Done. -------------------------------