Back to Forum  View unanswered posts  View active topics
Topic review  Groebner bases with vs without parameters 
Author 
Message 


Post subject: 
Groebner bases with vs without parameters 


Dear Singular Forum, I would like to perform polynomial division in a polynomial ring with parameters. Here is an example that I have in mind: Code: ring r=(0, y(1)),(z(1), z(2), z(3), z(4), z(5)),dp; ideal f = z(1)*z(2)*z(3)*z(4)*z(5)y(1)*z(2)^5+z(3)^5+z(4)^5+z(5)^5+z(1)^5; ideal j = jacob(f); ideal gb = groebner(j,"par2var"); poly p = 24*y(1)^4*z(2)^20; list q = division(p,j);
This yields (note result of the division is zero and there are rational expressions in the parameter) Code: q; [1]: _[1,1]=(24*y(1))/(78125*y(1)25)*z(1)^2*z(2)^6*z(3)*z(4)*z(5)^6 _[2,1]=(24*y(1)^3)/5*z(2)^16+(24*y(1)^2)/5*z(2)^11*z(5)^5+24/(390625*y(1)125)*z(1)^2*z(2)^3*z(3)^2*z(4)^2*z(5)^7+(24*y(1))/5*z(2)^6*z(5)^10+24/5*z(2)*z(5)^15 _[3,1]=(24*y(1))/(15625*y(1)5)*z(1)^5*z(2)^5*z(3)*z(5)^5 _[4,1]=(24*y(1))/(3125*y(1)1)*z(1)^4*z(2)^4*z(3)^4*z(5)^4 _[5,1]=(24*y(1)^3)/5*z(2)^15*z(5)+(120*y(1))/(3125*y(1)1)*z(1)^3*z(2)^3*z(3)^3*z(4)^3*z(5)^4+(24*y(1)^2)/5*z(2)^10*z(5)^6+24/125*z(1)^2*z(2)^2*z(3)^2*z(4)^2*z(5)^8+(24*y(1))/5*z(2)^5*z(5)^1124/25*z(1)*z(2)*z(3)*z(4)*z(5)^12 [2]: _[1]=0 [3]: _[1,1]=1
For efficiency reasons I would like to perform the same computation treating y(1) as a ring variable. I observed that with several parameters treated as ring variables the Groebner basis computation is much faster than if they are treated as parameters. So here is the same example as above Code: ring r = 0, (y(1), z(1), z(2), z(3), z(4), z(5)), dp; ideal f = z(1)*z(2)*z(3)*z(4)*z(5)y(1)*z(2)^5+z(3)^5+z(4)^5+z(5)^5+z(1)^5; int i; ideal j=diff(f,z(1)); for(i=2;i<=5;i=i+1){j=j,diff(f,z(i));}; ideal gb = groebner(j); poly p = 24*y(1)^4*z(2)^20; list q = division(p,j);
The result, however, is very different. In particular the result of the division is not zero anymore. Code: q; [1]: _[1,1]=0 _[2,1]=24/5*y(1)^3*z(2)^1624/25*y(1)^2*z(1)*z(2)^12*z(3)*z(4)*z(5)24/5*y(1)*z(2)^6*z(5)^10+24/5*z(2)*z(5)^15 _[3,1]=0 _[4,1]=0 _[5,1]=24/25*y(1)^2*z(1)*z(2)^11*z(3)*z(4)*z(5)^224/5*y(1)^2*z(2)^10*z(5)^6+24/5*y(1)*z(2)^5*z(5)^1124/5*z(5)^16 [2]: _[1]=24*z(5)^20 [3]: _[1,1]=1
How do I have to modify the code in order to reproduce the correct result of the division in the ring with parameter ? Thanks for the help in advance.
Dear Singular Forum,
I would like to perform polynomial division in a polynomial ring with parameters. Here is an example that I have in mind: [code] ring r=(0, y(1)),(z(1), z(2), z(3), z(4), z(5)),dp; ideal f = z(1)*z(2)*z(3)*z(4)*z(5)y(1)*z(2)^5+z(3)^5+z(4)^5+z(5)^5+z(1)^5; ideal j = jacob(f); ideal gb = groebner(j,"par2var"); poly p = 24*y(1)^4*z(2)^20; list q = division(p,j); [/code] This yields (note result of the division is zero and there are rational expressions in the parameter) [code] q; [1]: _[1,1]=(24*y(1))/(78125*y(1)25)*z(1)^2*z(2)^6*z(3)*z(4)*z(5)^6 _[2,1]=(24*y(1)^3)/5*z(2)^16+(24*y(1)^2)/5*z(2)^11*z(5)^5+24/(390625*y(1)125)*z(1)^2*z(2)^3*z(3)^2*z(4)^2*z(5)^7+(24*y(1))/5*z(2)^6*z(5)^10+24/5*z(2)*z(5)^15 _[3,1]=(24*y(1))/(15625*y(1)5)*z(1)^5*z(2)^5*z(3)*z(5)^5 _[4,1]=(24*y(1))/(3125*y(1)1)*z(1)^4*z(2)^4*z(3)^4*z(5)^4 _[5,1]=(24*y(1)^3)/5*z(2)^15*z(5)+(120*y(1))/(3125*y(1)1)*z(1)^3*z(2)^3*z(3)^3*z(4)^3*z(5)^4+(24*y(1)^2)/5*z(2)^10*z(5)^6+24/125*z(1)^2*z(2)^2*z(3)^2*z(4)^2*z(5)^8+(24*y(1))/5*z(2)^5*z(5)^1124/25*z(1)*z(2)*z(3)*z(4)*z(5)^12 [2]: _[1]=0 [3]: _[1,1]=1 [/code] For efficiency reasons I would like to perform the same computation treating y(1) as a ring variable. I observed that with several parameters treated as ring variables the Groebner basis computation is much faster than if they are treated as parameters. So here is the same example as above [code] ring r = 0, (y(1), z(1), z(2), z(3), z(4), z(5)), dp; ideal f = z(1)*z(2)*z(3)*z(4)*z(5)y(1)*z(2)^5+z(3)^5+z(4)^5+z(5)^5+z(1)^5; int i; ideal j=diff(f,z(1)); for(i=2;i<=5;i=i+1){j=j,diff(f,z(i));}; ideal gb = groebner(j); poly p = 24*y(1)^4*z(2)^20; list q = division(p,j); [/code] The result, however, is very different. In particular the result of the division is not zero anymore. [code] q; [1]: _[1,1]=0 _[2,1]=24/5*y(1)^3*z(2)^1624/25*y(1)^2*z(1)*z(2)^12*z(3)*z(4)*z(5)24/5*y(1)*z(2)^6*z(5)^10+24/5*z(2)*z(5)^15 _[3,1]=0 _[4,1]=0 _[5,1]=24/25*y(1)^2*z(1)*z(2)^11*z(3)*z(4)*z(5)^224/5*y(1)^2*z(2)^10*z(5)^6+24/5*y(1)*z(2)^5*z(5)^1124/5*z(5)^16 [2]: _[1]=24*z(5)^20 [3]: _[1,1]=1 [/code] How do I have to modify the code in order to reproduce the correct result of the division in the ring with parameter ?
Thanks for the help in advance.




Posted: Tue Sep 19, 2017 2:44 pm 





It is currently Sat Jul 21, 2018 12:16 am

