next | previous | forward | backward | up | top | index | toc | Macaulay2 website
FourTiTwo :: toricGraver

toricGraver -- calculates the Graver basis of the toric ideal; invokes "graver" from 4ti2

Synopsis

Description

The Graver basis for any toric ideal $I_A$ contains (properly) the union of all reduced Groebner basis of $I_A$. Any element in the Graver basis of the ideal is called a primitive binomial.

i1 : A = matrix "1,1,1,1; 1,2,3,4"

o1 = | 1 1 1 1 |
     | 1 2 3 4 |

              2        4
o1 : Matrix ZZ  <--- ZZ
i2 : toricGraver(A)

o2 = | 1 -2 1  0 |
     | 2 -3 0  1 |
     | 1 -1 -1 1 |
     | 0 1  -2 1 |
     | 1 0  -3 2 |

              5        4
o2 : Matrix ZZ  <--- ZZ

If we prefer to store the ideal instead, we may use:

i3 : R = QQ[a..d]

o3 = R

o3 : PolynomialRing
i4 : toricGraver(A,R)

               2           3    2                   2           3      2
o4 = ideal (- b  + a*c, - b  + a d, - b*c + a*d, - c  + b*d, - c  + a*d )

o4 : Ideal of R

Note that this last ideal equals the toric ideal $I_A$ since every Graver basis element is actually in $I_A$.

Ways to use toricGraver :

For the programmer

The object toricGraver is a method function.