This is the part in sage, f1,f2,f3 are 3 polynomials and I have to
reduce them by I, the ideal in the line 8. This ideal is a vanishing
ideal of some points.
R = GF(3)['x1,x2,x3,x4'];
R.<x1,x2,x3> = PolynomialRing(GF(3), order='degrevlex')
x1,x2,x3 = R.gens();
f1=-x1^3+x1^2*x3-x1^2+x1*x3-x1;
f2=x1^3-x1^2*x3+x1^2-x1*x3+x1+1;
f3=-x1^3-x1^2*x3-x1^2-x1*x3-x1+1;
I=R.ideal([  x1+x2-1,x2*x3-x3^2+x2-x3,x2^2-x3^2+x2-x3,x1^3-x1 ,x2^3-
x2 ,x3^3-x3  ]);
gf=I.groebner_fan();
gf.weight_vectors();

This is the part in singular, this because I have to change the term
order (in sage is not possible).
LIB "decodegb.lib";
LIB "polymake.lib";
LIB "standard.lib";
ring rin=3,(x(1..3)),Wp(1,2,2);
poly f1=-x(1)^3+x(1)^2*x(3)-x(1)^2+x(1)*x(3)-x(1);
poly f2= x(1)^3-x(1)^2*x(3)+x(1)^2-x(1)*x(3)+x(1)+1;
poly f3=-x(1)^3-x(1)^2*x(3)-x(1)^2-x(1)*x(3)-x(1)+1;
ideal tot=ideal([x(1)+x(2)-1,x(2)*x(3)-x(3)^2+x(2)-x(3),x(2)^2-
x(3)^2+x(2)-x(3),x(3)^3-x(3),x(1)^3-x(1),x(2)^3-x(2)]);
reduce(f1,std(tot));
reduce(f2,std(tot));
reduce(f3,std(tot));

Thank you!
Bye!



On Apr 6, 2:18 pm, Marshall Hampton <hampto...@gmail.com> wrote:
> Can you post the system you are working with?  Or if its very large,
> post a link to a file?  I don't work over finite fields myself, so the
> current implementation is probably very biased towards QQ.  It would
> help me to see a "real life" example.
>
> Thanks,
> Marshall Hampton
>
> On Apr 6, 2:04 am, Andrea Gobbi <andreamat...@gmail.com> wrote:
>
> > Thank you for the answer...I have some question:
> > -I have gf=I.groebner_fan(); where I is a 0-dimentional ideal. Now gf
> > has the function gf.weight_vectors(); This returns the weight vectors
> > corresponding to the reduced Groebner bases. I try to call
> > polyedralfan() but it raises an error...maybe because I' in
> > characteristic p prime? Anyway if i can associate the polyedralfan and
> > i call rays I obtain the same of gf.weight_vectors()?.
> > -now I' thinking that I'm working in finite fields...maybe I can't
> > consider the Grobner fan...I have to study more about it....
>
> > I will post news when i'm sure of what i'm doing....
> > Thanks!!
>
> > On Apr 1, 5:48 pm, Marshall Hampton <hampto...@gmail.com> wrote:
>
> > > Unfortunately I don't think this is easy to do right now.
>
> > > If you have a Groebnerfan object for your ideal - lets call it G -
> > > then you can get the associated polyhedral fan:
>
> > > Gp = G.polyhedralfan()
>
> > > This object has a method Gp.rays() that will give you the weight
> > > vectors of the faces of the Groebner fan.  You'd like to use those to
> > > define a term-order; unfortunately that isn't wrapped in a real
> > > convenient way in Sage but it is possible.  If you read the help in:
>
> > > sage.rings.polynomial.term_order?
>
> > > it tells you that you can pass a term-ordering directly to Singular.
> > > For that you need the information at:
>
> > >http://www.singular.uni-kl.de/Manual/3-1-0/sing_31.htm
>
> > > ...I think you'd want:
> > > Wp( intvec_expression )
>
> > > but I am not sure.
>
> > > Right now the PolyhedralFan object doesn't know which of the lower-
> > > dimensional faces of the Groebner fan correspond to distinct bases.
> > > That information must be available from Gfan somehow but I don't know
> > > offhand how to extract it.
>
> > > Thanks for writing in with this question - I am more interested in
> > > working on the interface knowing that someone is actually trying to
> > > use it!  My apologies for its limitations.
>
> > > -Marshall Hampton
>
> > > On Apr 1, 2:10 am, Andrea Gobbi <andreamat...@gmail.com> wrote:> 
> > > Hi!!!!!!!!!
> > > >  How can I use
> > > > the function grobnerfan(ideal)?
> > > >  I have to reduce a polynomial
> > > > f(x_1,....,x_n) using all possible grobner basis in F_p. This is too
> > > > long, and so i decided to look only the grobner fan. But I can go
> > > > over...i have a list (of what???) given by grobnerfan, and also a list
> > > > of weight...but i don't understand how i can reduce the polynomial.
>
> > > > I means, if i have a term order, degrvlex for exmaple, i calculate the
> > > > grobner fan (the term order is not important). With the function
> > > > grobnerfan i obtain a lot of possible generators of the ideal,
> > > > depending for the term order...but if i want to reduce a polynomial
> > > > seems that i'm using the base term order, in my case degrevlex...or
> > > > not?
>
> > > >  I hope I was clear ( I'm italian and my english is very bad!!!!)...
> > > >  Thanks!!!

-- 
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

To unsubscribe, reply using "remove me" as the subject.

Reply via email to