Macaulay2 » Documentation
Packages » Msolve :: msolveGB
next | previous | forward | backward | up | index | toc

msolveGB -- compute generators of a Groebner basis in GRevLex order

Synopsis

Description

This functions uses the F4 implementation in the msolve package to compute a Groebner basis, in GRevLex order, of a polynomial ideal with either rational coefficients or finite field coefficients with characteristic less than $2^{31}$. If the input ideal is a polynomial ring with monomial order other than GRevLex a GRevLex basis is returned (and no warning is given). The input ideal may also be given in a ring with integer coefficients, in this case a Groebner basis for the given ideal over the rationals will be computed, denominators will be cleared, and the output will be a Groebner basis over the rationals in GRevLex order with integer coefficients.

First an example over a finite field

i1 : R=ZZ/1073741827[z_1..z_3]

o1 = R

o1 : PolynomialRing
i2 : I=ideal(7*z_1*z_2+5*z_2*z_3+z_3^2+z_1+5*z_3+10,8*z_1^2+13*z_1*z_3+10*z_3^2+z_2+z_1)

                             2                    2               2
o2 = ideal (7z z  + 5z z  + z  + z  + 5z  + 10, 8z  + 13z z  + 10z  + z  +
              1 2     2 3    3    1     3         1      1 3      3    1  
     ------------------------------------------------------------------------
     z )
      2

o2 : Ideal of R
i3 : gB=msolveGB I

o3 = | z_1z_2-460175068z_2z_3-306783379z_3^2-306783379z_1-460175068z_3+
     ------------------------------------------------------------------------
     153391691 z_1^2+134217730z_1z_3+268435458z_3^2-402653185z_1-402653185z_2
     ------------------------------------------------------------------------
     z_1z_3^2+19173957z_2z_3^2-479349029z_3^3-402653186z_2^2+460175073z_1z_3+
     ------------------------------------------------------------------------
     134217729z_2z_3+153391693z_3^2+10z_1+402653185z_2-364305253z_3+268435458
     ------------------------------------------------------------------------
     z_2^2z_3^2+59398484z_2z_3^3+347252676z_3^4+516309900z_2^3+91382283z_2^2z
     ------------------------------------------------------------------------
     _3+27414685z_2z_3^2+223886594z_3^3-466049644z_2^2-68536713z_2z_3+
     ------------------------------------------------------------------------
     310699764z_3^2-310699763z_2+411220277z_3-68536709 |

             1      4
o3 : Matrix R  <-- R
i4 : lT=monomialIdeal leadTerm gB

                     2           2   2 2
o4 = monomialIdeal (z , z z , z z , z z )
                     1   1 2   1 3   2 3

o4 : MonomialIdeal of R
i5 : degree lT

o5 = 4
i6 : dim lT

o6 = 1

Now the same example over the rationals.

i7 : R=QQ[z_1..z_3]

o7 = R

o7 : PolynomialRing
i8 : I=ideal(7*z_1*z_2+5*z_2*z_3+z_3^2+z_1+5*z_3+10,8*z_1^2+13*z_1*z_3+10*z_3^2+z_2+z_1)

                             2                    2               2
o8 = ideal (7z z  + 5z z  + z  + z  + 5z  + 10, 8z  + 13z z  + 10z  + z  +
              1 2     2 3    3    1     3         1      1 3      3    1  
     ------------------------------------------------------------------------
     z )
      2

o8 : Ideal of R
i9 : gB=msolveGB I

o9 = | 7z_1z_2+5z_2z_3+z_3^2+z_1+5z_3+10 8z_1^2+13z_1z_3+10z_3^2+z_1+z_2
     ------------------------------------------------------------------------
     56z_1z_3^2-235z_2z_3^2+51z_3^3-49z_2^2+240z_1z_3+35z_2z_3+192z_3^2+560z_
     ------------------------------------------------------------------------
     1-7z_2+545z_3+70 235z_2^2z_3^2-11z_2z_3^3+8z_3^4+49z_2^3-35z_2^2z_3+13z_
     ------------------------------------------------------------------------
     2z_3^2+67z_3^3+14z_2^2-150z_2z_3+304z_3^2-69z_2+665z_3+790 |

             1      4
o9 : Matrix R  <-- R
i10 : (ideal gB)== ideal(groebnerBasis I)

o10 = true
i11 : lT=monomialIdeal leadTerm gB

                      2           2   2 2
o11 = monomialIdeal (z , z z , z z , z z )
                      1   1 2   1 3   2 3

o11 : MonomialIdeal of R
i12 : degree lT

o12 = 4
i13 : dim lT

o13 = 1

Ways to use msolveGB:

For the programmer

The object msolveGB is a method function with options.