Suppose I have three rational points $(x_1,y_1),(x_2,y_2),(x_3,y_3)$ on certain elliptic curve. Then they are linearly independent if and only if the determinant of matrix $(<P_i,P_j>)_{i,j}$ is non zero where $<\_,\_ >$ is Neron-Tate height pairing.

How to write a code in Sage or Pari to compute this determinant. Note that I don't want to write an equation of my elliptic curve in the code to compute rational points first. Rather I know my rational points and want to directly put rational points and compute the determinant.

  • 2
    $\begingroup$ If you do not provide the equation of the curve, how do you compare its Neron-Tate height? Given three points on the plane, you can always write down an elliptic curve which passes through all three which make the points dependent. $\endgroup$ – Hw Chu Jan 20 at 20:39
  • $\begingroup$ @Hw Chu Yes. Mistake! So in general, how do we write a code in Sage to find that determinant. Can you please illustrate me though some example. $\endgroup$ – ersh Jan 20 at 21:28
  • $\begingroup$ Try asking this question in the coding branch of Stack Exchange. $\endgroup$ – BadAtGeometry Jan 21 at 19:18

In SageMath this can be accomplished using the command height_pairing_matrix. For example:

sage: E = EllipticCurve([1, 0, 0, 0, 1])
sage: E
Elliptic Curve defined by y^2 + x*y = x^3 + 1 over Rational Field
sage: pts = E.gens()
sage: pts
[(-1 : 1 : 1), (0 : -1 : 1)]
sage: M = E.height_pairing_matrix(points = pts)
sage: M
[0.541484699372469 0.161800998136433]
[0.161800998136433 0.463307138146013]
sage: M.det()

You can find more information, including many examples, in the documentation.

  • $\begingroup$ 3000, So using above code, sage will first generate these rational points, right? What If I already know my rational points, I don't want Sage to generate the points because it would take my time. How should I write a code in that case? $\endgroup$ – ersh Jan 21 at 18:09
  • 1
    $\begingroup$ If you already have a list of the points, you can input it as points = in the height_pairing_matrix function. I tried to show this in my example; I could've just put E.height_pairing_matrix() and it would've computed the generators automatically. $\endgroup$ – André 3000 Jan 21 at 18:12

Something similar was already asked at Independence of points on Elliptic curve the answers there are the same as above but maybe a little more extensive.

Edit: I just noticed the question asker is the same as the previous question. So maybe this question really is trying to ask something different. The height of a point will depend on the elliptic curve itself so you will need to put the equation of the curve somewhere.

  • $\begingroup$ Yes, I was actually expecting you to comment as I had worked with your answer you provided me last time. You are right my question is different from the last one. I wanted to feed Sage only may rational points even including the equation of elliptic curve. But I don't want sage to compute the rational points. I already have a rational points in my hand and I want to compute determinant for my specific rational points. $\endgroup$ – ersh Jan 21 at 19:46
  • 1
    $\begingroup$ If you give sage the equation of and elliptical curve it will not compute any rational points by default. You can write P = E((1,0)) to define a point with coordinates (1,0) on E if you know it. Then a list of such can be given to height_pairing_matrix . you will have go define the elliptic curve though as the matrix depends on the equation of the curve. $\endgroup$ – Alex J Best Jan 21 at 20:11
  • $\begingroup$ Thanks for more clarification. $\endgroup$ – ersh Jan 21 at 20:25

I am not a sage expert. But I know you can call pari within sage and here you can compute the Gram/height matrix from the points and determine its determinant. Suppose you e is your elliptic curve (in pari this created by ellinit) and suppose P1,P2,P3 are your points then you just use the following commands:

m = ellheightmatrix(e,v);

If the last line is $0$ then your points are dependent. Either something similar is done in sage or just call pari commands from sage.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.