On 8/10/07, John Cremona <[EMAIL PROTECTED]> wrote:
>
> Two comments, neither about memory management as such:
>
> (1) Why do you need to store all the primes and curves?  Why don't you
> loop through primes?
>
> (2) EllipticCurve([0,-1,1,0,0]).aplist(10000) gives you almost what
> you want (just replace the i'th entry ap by 1+p-ap where p is the ith
> prime):
>
> e=EllipticCurve([0,-1,1,0,0]);
> ap=e.aplist(10000);
> plist=prime_range(10000);
> [1+plist[i]-ap[i] for i in range(prime_pi(10000))]

Moreover, even EllipticCurve([0,-1,1,0,0]).aplist(1000000)
will finish in a reasonable amount of time -- i.e., it's very very optimized
(thank you PARI).   You can also do the following, which is basically
the same as above and even faster:
   sage: e = EllipticCurve([0,1,-1,0,0])
   sage: v = [e.Np(p) for p in primes(10000)]

William

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/
-~----------~----~----~----~------~----~------~--~---

Reply via email to