SHARE
TWEET

Untitled

a guest Jul 18th, 2019 124 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. sage: E = EllipticCurve( GF(13), [3, 8] )
  2. sage: E
  3. Elliptic Curve defined by y^2 = x^3 + 3*x + 8 over Finite Field of size 13
  4. sage: E.order().factor()
  5. 3^2
  6. sage: for P in E.points():
  7. ....:     print "Point %8s of order %s" % (P.xy() if P != E(0) else 'ZERO', P.order())
  8. ....:
  9. Point     ZERO of order 1
  10. Point   (1, 5) of order 9
  11. Point   (1, 8) of order 9
  12. Point   (2, 3) of order 9
  13. Point  (2, 10) of order 9
  14. Point   (9, 6) of order 3
  15. Point   (9, 7) of order 3
  16. Point  (12, 2) of order 9
  17. Point (12, 11) of order 9
  18. sage: E.gens()
  19. ((12 : 11 : 1),)
  20. sage: G = E.gens()[0]    # the generator
  21. sage: G.order()
  22. 9
  23.      
  24. sage: E.division_polynomial(3).factor()
  25. (3) * (x + 4) * (x^3 + 9*x^2 + 9*x + 9)
  26.      
  27. sage: F.<a> = GF( 13^3, modulus = x^3 + 9*x^2 + 9*x + 9 )
  28. sage: F
  29. Finite Field in a of size 13^3
  30. sage: F.modulus()
  31. x^3 + 9*x^2 + 9*x + 9
  32. sage: a.minpoly()
  33. x^3 + 9*x^2 + 9*x + 9
  34. sage: # we consider the base change of E from GF(13) to F = GF(13^3)
  35. sage: EF = E.base_extend(F)
  36. sage: EF
  37. Elliptic Curve defined by y^2 = x^3 + 3*x + 8 over Finite Field in a of size 13^3
  38. sage: EF.base_field()
  39. Finite Field in a of size 13^3
  40. sage: EF.base_field() == F
  41. True
  42.      
  43. sage: EF.order().factor()
  44. 2^2 * 3^4 * 7
  45.      
  46. sage: for P in EF.points():
  47. ....:     if P.order() == 3:
  48. ....:         print P
  49. ....:        
  50. (9 : 6 : 1)
  51. (9 : 7 : 1)
  52. (a : 2*a + 5 : 1)
  53. (a : 11*a + 8 : 1)
  54. (4*a^2 + 3*a : 5*a^2 + 7*a + 8 : 1)
  55. (4*a^2 + 3*a : 8*a^2 + 6*a + 5 : 1)
  56. (9*a^2 + 9*a + 4 : 5*a^2 + 5*a : 1)
  57. (9*a^2 + 9*a + 4 : 8*a^2 + 8*a : 1)
  58. sage:
  59.      
  60. sage: for f, multiplicity in E.division_polynomial(9).factor():
  61. ....:     print f
  62. ....:    
  63. x + 1
  64. x + 4
  65. x + 11
  66. x + 12
  67. x^3 + 4*x^2 + 8*x + 7
  68. x^3 + 8*x^2 + x + 6
  69. x^3 + 9*x^2 + 9*x + 9
  70. x^9 + 2*x^7 + 5*x^6 + 11*x^5 + x^4 + 12*x^3 + 11*x^2 + 7*x + 9
  71. x^9 + 6*x^8 + 7*x^7 + x^6 + x^5 + 10*x^4 + 9*x^3 + 2*x^2 + 7*x + 7
  72. x^9 + 10*x^8 + 6*x^7 + 7*x^6 + 3*x^5 + 3*x^4 + 7*x^3 + 9*x^2 + 7*x + 10
  73.      
  74. sage: EL = E.base_extend(L)
  75. sage: for bb in b.minpoly().roots(ring=L, multiplicities=False):
  76. ....:     ybb = sqrt( bb^3 + 3*bb + 8 )
  77. ....:     P = EL.point( (bb, ybb) )
  78. ....:     print "Order %s for point with components:n%sn%sn" % (P.order(), P.xy()[0], P.xy()[1])
  79. ....:    
  80. Order 9 for point with components:
  81. b
  82. 11*b^8 + 7*b^7 + 5*b^6 + 2*b^4 + 10*b^3 + 7*b^2 + 6*b + 11
  83.  
  84. Order 9 for point with components:
  85. 3*b^8 + 4*b^7 + 4*b^6 + 3*b^5 + b^4 + 9*b^3 + 9*b
  86. 8*b^8 + 12*b^7 + 5*b^6 + 11*b^5 + 9*b^4 + 2*b^3 + 2*b^2 + 12*b + 12
  87.  
  88. Order 9 for point with components:
  89. 11*b^8 + 5*b^7 + 7*b^6 + 2*b^5 + 7*b^4 + 7*b^2 + b + 12
  90. 2*b^8 + 6*b^7 + 2*b^6 + 7*b^5 + 5*b^4 + 6*b^3 + 5*b^2 + 11
  91.  
  92. Order 9 for point with components:
  93. 4*b^8 + 9*b^7 + 4*b^5 + b^4 + 6*b^3 + b^2 + 11
  94. b^8 + b^7 + 5*b^6 + b^5 + 12*b^4 + 2*b^2 + 5*b + 7
  95.  
  96. Order 9 for point with components:
  97. 6*b^8 + 10*b^7 + 3*b^6 + 8*b^5 + 2*b^4 + 10*b^3 + 3*b + 11
  98. 10*b^8 + 5*b^7 + 3*b^6 + 3*b^5 + 3*b^4 + 7*b^3 + b^2 + 7*b + 11
  99.  
  100. Order 9 for point with components:
  101. 5*b^8 + 6*b^7 + b^6 + 6*b^5 + 8*b^4 + 2*b^2 + 9*b + 10
  102. 7*b^8 + 3*b^7 + 6*b^6 + b^5 + 11*b^4 + 9*b^3 + 2*b^2 + 5*b + 4
  103.  
  104. Order 9 for point with components:
  105. 8*b^8 + 10*b^7 + 5*b^5 + 6*b^3 + 12*b^2 + b + 9
  106. 2*b^7 + 2*b^6 + 3*b^5 + 5*b^4 + 12*b^3 + 10*b^2 + 6*b + 5
  107.  
  108. Order 9 for point with components:
  109. 6*b^8 + b^7 + 7*b^6 + 3*b^5 + 6*b^4 + 2*b^3 + 10*b + 6
  110. 11*b^8 + 9*b^7 + 4*b^6 + 4*b^5 + 12*b^4 + 5*b + 10
  111.  
  112. Order 9 for point with components:
  113. 9*b^8 + 7*b^7 + 4*b^6 + 8*b^5 + b^4 + 6*b^3 + 4*b^2 + 5*b + 6
  114. 2*b^8 + 5*b^7 + b^6 + 5*b^5 + 7*b^4 + 6*b^3 + 4*b + 5
  115.  
  116. sage:
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top