Example #1
0
    def points(self):
        """
        Return a list of the generating points in this Mordell-Weil
        group.

        OUTPUT:

        (list) A list of lists of length 3, each holding the
        primitive integer coordinates `[x,y,z]` of a generating
        point.

        EXAMPLES::

            sage: E = mwrank_EllipticCurve([0,0,1,-7,6])
            sage: EQ = mwrank_MordellWeil(E)
            sage: EQ.search(1)
            P1 = [0:1:0]	 is torsion point, order 1
            P1 = [-3:0:1]	  is generator number 1
            ...
            P4 = [12:35:27]	 = 1*P1 + -1*P2 + -1*P3 (mod torsion)
            sage: EQ.points()
            [[1, -1, 1], [-2, 3, 1], [-14, 25, 8]]

        """
        from sage.misc.all import preparse
        from sage.rings.all import Integer
        return eval(preparse(self.__mw.getbasis().replace(":", ",")))
Example #2
0
    def points(self):
        """
        Return a list of the generating points in this Mordell-Weil
        group.

        OUTPUT:

        (list) A list of lists of length 3, each holding the
        primitive integer coordinates `[x,y,z]` of a generating
        point.

        EXAMPLES::

            sage: E = mwrank_EllipticCurve([0,0,1,-7,6])
            sage: EQ = mwrank_MordellWeil(E)
            sage: EQ.search(1)
            P1 = [0:1:0]	 is torsion point, order 1
            P1 = [-3:0:1]	  is generator number 1
            ...
            P4 = [12:35:27]	 = 1*P1 + -1*P2 + -1*P3 (mod torsion)
            sage: EQ.points()
            [[1, -1, 1], [-2, 3, 1], [-14, 25, 8]]

        """
        from sage.misc.all import preparse
        from sage.rings.all import Integer

        return eval(preparse(self.__mw.getbasis().replace(":", ",")))
Example #3
0
    def gens(self):
        """
        Return a list of the generators for the Mordell-Weil group.  

        EXAMPLES::
        
            sage: E = mwrank_EllipticCurve([0, 0, 1, -1, 0])
            sage: E.gens()
            [[0, -1, 1]]
        """
        self.saturate()
        from sage.misc.all import preparse
        from sage.rings.all import Integer
        return eval(preparse(self.__two_descent_data().getbasis().replace(":",",")))