Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
sagemath
GitHub Repository: sagemath/sagelib
Path: blob/master/sage/modular/abvar/lseries.py
4072 views
1
"""
2
`L`-series of modular abelian varieties
3
4
At the moment very little functionality is implemented -- this is mostly a
5
placeholder for future planned work.
6
7
AUTHOR:
8
9
- William Stein (2007-03)
10
11
TESTS::
12
13
sage: L = J0(37)[0].padic_lseries(5)
14
sage: loads(dumps(L)) == L
15
True
16
sage: L = J0(37)[0].lseries()
17
sage: loads(dumps(L)) == L
18
True
19
"""
20
21
###########################################################################
22
# Copyright (C) 2007 William Stein <[email protected]> #
23
# Distributed under the terms of the GNU General Public License (GPL) #
24
# http://www.gnu.org/licenses/ #
25
###########################################################################
26
27
from sage.structure.sage_object import SageObject
28
from sage.rings.all import Integer
29
30
class Lseries(SageObject):
31
"""
32
Base class for `L`-series attached to modular abelian varieties.
33
"""
34
def __init__(self, abvar):
35
"""
36
Called when creating an L-series.
37
38
INPUT:
39
40
- ``abvar`` -- a modular abelian variety
41
42
EXAMPLES::
43
44
sage: J0(11).lseries()
45
Complex L-series attached to Abelian variety J0(11) of dimension 1
46
sage: J0(11).padic_lseries(7)
47
7-adic L-series attached to Abelian variety J0(11) of dimension 1
48
"""
49
self.__abvar = abvar
50
51
def abelian_variety(self):
52
"""
53
Return the abelian variety that this `L`-series is attached to.
54
55
OUTPUT:
56
a modular abelian variety
57
58
EXAMPLES::
59
60
sage: J0(11).padic_lseries(7).abelian_variety()
61
Abelian variety J0(11) of dimension 1
62
"""
63
return self.__abvar
64
65
class Lseries_complex(Lseries):
66
"""
67
A complex `L`-series attached to a modular abelian variety.
68
69
EXAMPLES::
70
71
sage: A = J0(37)
72
sage: A.lseries()
73
Complex L-series attached to Abelian variety J0(37) of dimension 2
74
"""
75
def __call__(self, s):
76
"""
77
Evaluate this complex `L`-series at `s`.
78
79
INPUT:
80
81
- ``s`` -- complex number
82
83
OUTPUT:
84
a complex number L(A, s).
85
86
EXAMPLES:
87
This is not yet implemented::
88
89
sage: L = J0(37).lseries()
90
sage: L(2)
91
Traceback (most recent call last):
92
...
93
NotImplementedError
94
"""
95
raise NotImplementedError
96
97
def __cmp__(self, other):
98
"""
99
Compare this complex `L`-series to another one.
100
101
INPUT:
102
103
- ``other`` -- object
104
105
OUTPUT:
106
-1, 0, or 1
107
108
EXAMPLES::
109
110
sage: L = J0(37)[0].lseries(); M = J0(37)[1].lseries()
111
sage: cmp(L,M)
112
-1
113
sage: cmp(L,L)
114
0
115
sage: cmp(M,L)
116
1
117
"""
118
if not isinstance(other, Lseries_complex):
119
return cmp(type(self), type(other))
120
return cmp(self.abelian_variety(), other.abelian_variety())
121
122
123
def _repr_(self):
124
"""
125
String representation of `L`-series.
126
127
OUTPUT:
128
a string
129
130
EXAMPLES::
131
132
sage: L = J0(37).lseries()
133
sage: L._repr_()
134
'Complex L-series attached to Abelian variety J0(37) of dimension 2'
135
"""
136
return "Complex L-series attached to %s"%self.abelian_variety()
137
138
def rational_part(self):
139
"""
140
Return the rational part of this `L`-function at the central critical
141
value 1.
142
143
NOTE: This is not yet implemented.
144
145
EXAMPLES::
146
147
sage: J0(37).lseries().rational_part()
148
Traceback (most recent call last):
149
...
150
NotImplementedError
151
"""
152
raise NotImplementedError
153
154
155
class Lseries_padic(Lseries):
156
"""
157
A `p`-adic `L`-series attached to a modular abelian variety.
158
"""
159
def __init__(self, abvar, p):
160
"""
161
Create a `p`-adic `L`-series.
162
163
EXAMPLES::
164
165
sage: J0(37)[0].padic_lseries(389)
166
389-adic L-series attached to Simple abelian subvariety 37a(1,37) of dimension 1 of J0(37)
167
"""
168
Lseries.__init__(self, abvar)
169
p = Integer(p)
170
if not p.is_prime():
171
raise ValueError, "p (=%s) must be prime"%p
172
self.__p = p
173
174
def __cmp__(self, other):
175
"""
176
Compare this `p`-adic `L`-series to another one.
177
178
First the abelian varieties are compared; if they are the same,
179
then the primes are compared.
180
181
INPUT:
182
other -- object
183
184
OUTPUT:
185
-1, 0, or 1
186
187
EXAMPLES::
188
189
sage: L = J0(37)[0].padic_lseries(5); M = J0(37)[1].padic_lseries(5)
190
sage: K = J0(37)[0].padic_lseries(3)
191
sage: cmp(L,K)
192
1
193
sage: cmp(K,L)
194
-1
195
sage: K < L
196
True
197
sage: cmp(L,M)
198
-1
199
sage: cmp(M,L)
200
1
201
sage: cmp(L,L)
202
0
203
"""
204
if not isinstance(other, Lseries_padic):
205
return cmp(type(self), type(other))
206
return cmp((self.abelian_variety(), self.__p),
207
(other.abelian_variety(), other.__p))
208
209
def prime(self):
210
"""
211
Return the prime `p` of this `p`-adic `L`-series.
212
213
EXAMPLES::
214
215
sage: J0(11).padic_lseries(7).prime()
216
7
217
"""
218
return self.__p
219
220
def power_series(self, n=2, prec=5):
221
"""
222
Return the `n`-th approximation to this `p`-adic `L`-series as
223
a power series in `T`. Each coefficient is a `p`-adic number
224
whose precision is provably correct.
225
226
NOTE: This is not yet implemented.
227
228
EXAMPLES::
229
230
sage: L = J0(37)[0].padic_lseries(5)
231
sage: L.power_series()
232
Traceback (most recent call last):
233
...
234
NotImplementedError
235
sage: L.power_series(3,7)
236
Traceback (most recent call last):
237
...
238
NotImplementedError
239
"""
240
raise NotImplementedError
241
242
def _repr_(self):
243
"""
244
String representation of this `p`-adic `L`-series.
245
246
EXAMPLES::
247
248
sage: L = J0(37)[0].padic_lseries(5)
249
sage: L._repr_()
250
'5-adic L-series attached to Simple abelian subvariety 37a(1,37) of dimension 1 of J0(37)'
251
"""
252
return "%s-adic L-series attached to %s"%(self.__p, self.abelian_variety())
253
254
255