Ask Your Question

Jeff Stroomer's profile - activity

2021-05-07 19:56:33 +0200 received badge  Notable Question (source)
2021-05-07 19:56:33 +0200 received badge  Popular Question (source)
2010-12-16 10:03:13 +0200 received badge  Nice Question (source)
2010-12-15 09:02:10 +0200 received badge  Student (source)
2010-12-12 18:51:06 +0200 asked a question How to add term order to free module?

I am working with a free module over a ring of polynomials, and need more than what's available in FreeModule. To be specific, I want to define an order on the terms in the module (think term orders for Grobner bases), and then to be able to obtain leading monomials of module elements.

I tried to augment sage.modules.free_module_element.FreeModuleElement.__bases__ with my own mix-in as described in the tutorial, but apparently FreeModuleElement cannot be augmented in this way.

Presumably I could also put together derived classes for FreeModule and FreeModuleElement, but I'm somewhat up in the air as how to do this.

I considered augmenting my ring of polynomials with extra variables as a back-door way to produce my free module, but the term orders available in polynomial rings are not general enough for my application.

Any suggestions? So far I have worked around the problem, but it's ugly.