Attachment 'iwasawa_invariants.sage'
Download 1 """
2 Both of these should eventually become part of the pAdicLSeries class
3 (or at least the ordinary version) THey could also be defined for general
4 p-adic power series, but their usefulness in that setting is questionable
5 """
6
7 def powerseries_newton_polygon(self):
8 P = self
9 p = P.base_ring().prime()
10 aj = P.list()
11
12 """
13 when P has coefficnets like O(p^8) the sequence of commands
14 f = P.polynomial(); f.newton_polygon() does not work so I replace
15 O(p^8) with zero.
16 """
17 new_aj = []
18 for j in range(len(aj)):
19 if aj[j] == 0:
20 new_aj.append(0)
21 else:
22 new_aj.append(aj[j])
23 K = Qp(p)
24 R.<x> = K[]
25 f = R(new_aj)
26 newton = f.newton_polygon()
27 return newton
28
29 def powerseries_mu_lambda(self):
30 """
31 takes a power series over Qp and returns its mu invariant
32 the user is responsible for knowing whether they have given
33 enough precision in the power series for the answer to be
34 reasonable
35 """
36 P = self
37 newton_polygon = powerseries_newton_polygon(P)
38 mu_invariant = min([x[1] for x in newton_polygon])
39 lambda_invariant = min([x[0] for x in newton_polygon if x[1] == mu_invariant])
40 return (mu_invariant, lambda_invariant)
41
42 def X1_optimal_curve(self):
43 """
44 given an EllipticCurve, returns the curve
45 which is optimal for the X_1(N) parameterization. This is
46 given by the curve with the maximal area in its
47 fundamental parallelogram
48 """
49 E = self
50 isogeny_class = E.isogeny_class()[0]
51 li = [(e.period_lattice().complex_area(), e) for e in isogeny_class]
52 li.sort()
53 return li[len(li)-1][1]
54
55 def mu_invariant(self,p,N=None,X1_optimal=False):
56 """
57 self = an elliptic curve
58 p = a prime
59 N = integer which gives degree to which we compute
60 the p-adic L-series of E; higher N will give more sure answers
61 large N become heavy on the processor
62
63 Find the mu-invariant of E at p
64 N tells me how long to look before I just return something
65 To compute quickly, we recommend N = 3.
66
67 Example:
68 E = EllipticCurve('11a3')
69 p = 5
70 mu = mu_invariant(E,p,N=3)
71 """
72 E = self
73 correction = 0
74 #switch to the X1-optimal curve
75 if X1_optimal == True:
76 Enew = X1_optimal_curve(E)
77 correction = Enew.isogeny_degree(E).ord(p)
78 E = Enew
79 if N == None:
80 N = max(3, floor(5*log(10)/log(p)) - 1)
81 if E.has_bad_reduction(p) or E.anlist(p)[p] % p == 0:
82 raise ValueError, '%s does not have good ordinary reduction at %s' % (E.cremona_label(), p)
83 L = E.padic_lseries(p)
84 P = L.series(N)
85 return powerseries_mu_lambda(P)[0] + correction
86
87 def lambda_invariant(self,p,N=None,X1_optimal=False):
88 """
89 self = padic L-series attached to an elliptic curve
90
91 Find the lambda-invariant of E at p using the Newton polygon
92 If you want more accurate answers, you should raise N to compute more terms
93 in the E.padic_lseries(p). To compute quickly, we highly recommend
94 N = 3 (but less accurately)
95
96 Example:
97 E = EllipticCurve('11a3')
98 L = E.padic_lseries(5)
99 lambda_inv = lambda_invariant(L,N=3)
100 """
101 E = self
102 #switch to the X1-optimal curve
103 if X1_optimal == True:
104 E = X1_optimal_curve(E)
105
106 if N == None:
107 N = max(3, floor(5*log(10)/log(p)) - 1)
108 if E.has_bad_reduction(p) or E.anlist(p)[p] % p == 0:
109 raise ValueError, '%s does not have good ordinary reduction at %s' % (E.cremona_label(), p)
110 L = E.padic_lseries(p)
111 P = L.series(N)
112 return powerseries_mu_lambda(P)
Attached Files
To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.You are not allowed to attach a file to this page.