Ask Your Question

groebner_basis() algorithm

asked 2016-10-30 23:36:46 -0500

name1597852 gravatar image

How to define the default algorithm in the function groebner_basis()?

I only found "If only a system is given - e.g. ‘magma’ - the default algorithm is chosen for that system."

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted

answered 2016-11-04 12:44:11 -0500

updated 2016-11-04 12:46:51 -0500

The method groebner_basis for ideals in polynomial rings is documented at

This documentation can also be accessed by creating an ideal in a polynomial ring

sage: x, y = QQ['x, y'].gens()
sage: J = ideal(x^5 + y^4 - 1,  x^3 + y^3 - 1)

and typing

sage: J.groebner_basis?

The method groebner_basis takes an optional algorithm argument.

Choices for this argument are

  • ‘singular:groebner’
  • ‘singular:std’
  • ‘singular:stdhilb’
  • ‘singular:stdfglm’
  • ‘singular:slimgb’
  • ‘libsingular:groebner’
  • ‘libsingular:std’
  • ‘libsingular:slimgb’
  • ‘libsingular:stdhilb’
  • ‘libsingular:stdfglm’
  • ‘toy:buchberger’
  • ‘toy:buchberger2’
  • ‘toy:d_basis’
  • ‘macaulay2:gb’
  • ‘magma:GroebnerBasis’
  • ‘ginv:TQ’
  • ‘ginv:TQBlockHigh’
  • ‘ginv:TQBlockLow’
  • ‘ginv:TQDegree’
  • ‘giac:gbasis’

In other words, the algorithm is described by a string of the form '<system>:<command>' where <system> can be one of singular, libsingular, toy, macaulay2, magma, ginv, giac and each system has one or more possible <command> values.

The documentation says that "If only a system is given - e.g. ‘magma’ - the default algorithm is chosen for that system."

This means that

  • algorithm='magma' will work as algorithm='magma:GroebnerBasis'
  • algorithm='singular' will work as algorithm='singular:groebner'
  • algorithm='libsingular' will work as algorithm='libsingular:groebner'
  • algorithm='macaulay2' will work as algorithm='macaulay2:gb'
  • algorithm='toy' will work as algorithm='toy:buchberger2'
  • algorithm='giac' will work as algorithm='giac:gbasis'

One way to figure out which is the default algorithm for each system is to read the code for the method groebner_basis, which you can access by typing

sage: J.groebner_basis??
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2016-10-30 23:36:46 -0500

Seen: 41 times

Last updated: Nov 04 '16