[sage-support] Re: multivariate polynomial division

2011-02-28 Thread dmharvey
On Feb 27, 5:29 pm, Martin Albrecht wrote: > sage: R. = PolynomialRing(QQ) > sage: f = x0^2*x1 + x1^2*x2 + x2^2*x3 + x3^2*x0 > sage: (f0, f1, f2, f3) = [f.derivative(v) for v in [x0, x1, x2, x3]] > sage: I = R.ideal(f0, f1, f2, f3) > sage: h = x0^5 > sage: h.lift(I) > [-x0^2*x2 - 4/15*x0*x1*x3,

[sage-support] multivariate polynomial division

2011-02-27 Thread dmharvey
Hi, sage: R. = PolynomialRing(QQ) sage: f = x0^2*x1 + x1^2*x2 + x2^2*x3 + x3^2*x0 sage: (f0, f1, f2, f3) = [f.derivative(v) for v in [x0, x1, x2, x3]] sage: I = R.ideal(f0, f1, f2, f3) sage: h = x0^5 sage: h in I sage: True Now how do I compute polynomials g0, g1, g2, g3, such that g = g0*f0 + ..

[sage-support] Re: why does constructing this ring take forever?

2010-07-07 Thread dmharvey
On Jul 7, 4:56 am, Simon King wrote: > Hi! > > On 7 Jul., 09:48, luisfe wrote: > > > ... > > So, the > > time in constructing the PolynomialRing is in fact checking if > > 16219299585*2^16612 - 1 is a proven prime. > > ... which means that the user should be given the opportunity to > *assert* th

[sage-support] why does constructing this ring take forever?

2010-07-06 Thread dmharvey
sage: R. = PolynomialRing(Integers(16219299585*2^16612 - 1)) Maybe not literally forever, but I got sick of waiting. Should be instantaneous. david -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googl

[sage-support] Re: mismatched gfortran/gcc/g++ version

2010-03-06 Thread dmharvey
On Mar 5, 10:56 pm, David Kirkby wrote: > You might try > > $ which gfortran > > and see if there is gcc and g++ in that directory too. In which case > put that directory in your path earlier. It's impossible to build gcc > with just Fortran support, so I would suspect there is a gcc 4.2.1 and >

[sage-support] Re: mismatched gfortran/gcc/g++ version

2010-03-05 Thread dmharvey
> You should definitely get Arthur to install the right Fortran.   It's > just asking for trouble to use the wrong version. ok, thanks I will do that. david -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubsc

[sage-support] mismatched gfortran/gcc/g++ version

2010-03-04 Thread dmharvey
from source. See the errors above. make[1]: *** [installed/prereq-0.7] Error 1 make[1]: Leaving directory `/home/dmharvey/sage-4.3.2/spkg' In fact we have: alhambra$ gcc --version gcc (GCC) 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2) alhambra$ g++ --version g++ (GCC) 4.1.3 200

[sage-support] Re: how to cast finite field elements into p-adic ring

2010-02-07 Thread dmharvey
> > Please, keep sending these bugs and feature requests for p-adic   > > extensions.  I don't think the code has gotten much use, and I'd   > > like to see actual use cases. what about even just coercing from a p-adic field to its residue field? sage: R. = Zq(9) sage: K = R.residue_field() sage:

[sage-support] how to cast finite field elements into p-adic ring

2010-02-02 Thread dmharvey
Hi, After I create the residue field of a p-adic ring, how do I cast elements of the field back into the ring? Any lift is fine. The obvious thing doesn't work: sage: R. = Zq(9) sage: F = R.residue_class_field() sage: F Finite Field in z0 of size 3^2 sage: a = F.gen() sage: R(a) -

[sage-support] Re: Dealing with large finite fields?

2008-12-17 Thread dmharvey
On Dec 17, 5:32 pm, Alasdair wrote: > What facilities are available to me here?  For example, the following: > > p=211 > F.=GF(p)[] > G.=GF(p^17,name='a',modulus=x^17+2*x^2+1) > g=G.multiplicative_generator() > r=G.random_element() > discrete_log(r,g) > > ties up my computer for several minutes w