On May 2, 5:55 pm, simon.k...@uni-jena.de wrote:
> Dear John,
>
> On 2 Mai, 18:39, John Cremona <john.crem...@gmail.com> wrote:
>
> > When an elliptic curve is created the code in the __init__ function in
> > ell_generic.py (lines 164-5) do cause a multivariate polynomial ring
> > to be created.  In this case it's a new ring each time as the base
> > field is always a new field.
>
> How is the multivariate polynomial ring created?

First the projective plane is constructed, effectively by
PP=ProjectiveSpace(2,K), and then the ring by PP.coordinate_ring(),
which calls
 PolynomialRing(self.base_ring(),
                               self.variable_names(),
self.dimension_relative()+1)
so in effect we call PolynomialRing(K).

John

>
> I remember that recently Martin Albrecht was fixing some bug: Here, a
> multivariate polynomial ring was created without using the
> PolynomialRing constructor, violating uniqueness of parents.
>
> But if, in your case, you create a polynomial ring, work with it, and
> then want it to be garbage collected, then perhaps it would be a good
> idea to *not* use the PolynomialRing constructor: If the resulting
> ring is cached (-> uniqueness of Parent Structures) then it would not
> be garbage collected, or would it?
>
> Best regards,
>     Simon
--~--~---------~--~----~------------~-------~--~----~
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
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to