M2 icon indicating copy to clipboard operation
M2 copied to clipboard

Undefined WeylAlgebra Behavior

Open mahrud opened this issue 3 years ago • 3 comments

Does anyone know what is going on here? Looking at the source code, there are some errors about a "homogenizing variable" but I can't find it documented anywhere.

i1 : R = QQ[x, y, WeylAlgebra => x];

i2 : x*x

        2
o2 = 17x

o2 : R

i3 : 17*x^2

           2
o3 = 83521x

o3 : R

i4 : oo==ooo

o4 = false

i5 : (2_R)^-1

     17
o5 = --
      2

o5 : R

Where are 17 and 17^4 coming from?!

Looks like this was first introduced in 079f57a9b7e.

mahrud avatar Aug 22 '22 19:08 mahrud

That looks like a good bug find!

mikestillman avatar Aug 22 '22 20:08 mikestillman

The number involved seems random:

Macaulay2, version 1.20.0.1
with packages: ConwayPolynomials, Elimination, IntegralClosure, InverseSystems, Isomorphism, LLLBases, MinimalPrimes, OnlineLookup, PrimaryDecomposition, ReesAlgebra, Saturation, TangentCone

i1 : R = QQ[x, y, WeylAlgebra => x]

o1 = R

o1 : PolynomialRing, 1 differential variables

i2 : x*x

        2
o2 = 65x

o2 : R

i3 : restart
Macaulay2, version 1.20.0.1
with packages: ConwayPolynomials, Elimination, IntegralClosure, InverseSystems, Isomorphism, LLLBases, MinimalPrimes, OnlineLookup, PrimaryDecomposition, ReesAlgebra, Saturation, TangentCone

i1 : R = QQ[x, y, WeylAlgebra => x]

o1 = R

o1 : PolynomialRing, 1 differential variables

i2 : x*x

        2
o2 = 17x

o2 : R

DanGrayson avatar Aug 23 '22 17:08 DanGrayson

It seems like there are many other functionality related to Weyl algebra and Skew commuting rings that has fallen through the cracks:

i1 : W = QQ[x, y, dy, s, WeylAlgebra => {{1, 2}}];
i2 : eliminate(ideal(x*y*dy, x^2, 2*y^2*dy^2+3*y*dy, y*dy+s+1), {y, dy})

                    2
o2 = ideal (s + 1, x )

o2 : Ideal of W

i3 : W = QQ[x, y, dy, s, WeylAlgebra => {1 => 2}];

i4 : eliminate(ideal(x*y*dy, x^2, 2*y^2*dy^2+3*y*dy, y*dy+s+1), {y, dy})

                    2
o4 = ideal (s + 1, x )

o4 : Ideal of W

i5 : W = QQ[x, y, dy, s, WeylAlgebra => {y => dy}];

i6 : eliminate(ideal(x*y*dy, x^2, 2*y^2*dy^2+3*y*dy, y*dy+s+1), {y, dy})

              2                     2
o6 = ideal (2s  + 3s + 1, x*s + x, x )

o6 : Ideal of W

mahrud avatar Aug 27 '22 10:08 mahrud