3089
Comment:
|
3115
|
Deletions are marked like this. | Additions are marked like this. |
Line 1: | Line 1: |
#Use the following command to attach the eulerprod package (after downloading it from Purple Sage) |
#Use the following command to attach the eulerprod package (after downloading it from Purple Sage): |
Line 7: | Line 6: |
#Auxiliary functions that will be called later on | #Auxiliary functions that will be called later on: |
Line 23: | Line 22: |
#Defining the LSeriesTripleProduct class | #Here is where we start defining the LSeriesTripleProduct class: |
Line 95: | Line 94: |
L(RealField(5)(2)) #This command current returns a RunTime Error ("Unable to create L-series, due to precision or other limits in PARI") | L(RealField(5)(2)) #This command currently returns a RunTime Error ("Unable to create L-series, due to precision or other limits in PARI") |
attach /users/lola/desktop/eulerprod.py
#Auxiliary functions that will be called later on:
R_cdf = CDF['x']
def quad_roots(a, p):
- t = R_cdf([p, -a, 1]).roots() return (t[0][0], t[1][0])
def init(self, N, f, g, h):
- self._N = ZZ(N)
if not (self._N.is_squarefree() and self._N > 0):
raise ValueError, "N (=%s) must be a squarefree positive integer"%self._N
#Here is where we start defining the LSeriesTripleProduct class:
class LSeriesTripleProduct(LSeriesAbstract):
def init(self, N, f, g, h):
- self._N = ZZ(N) self._f = f self._g = g self._h = h self._newforms = [f, g, h]
LSeriesAbstract.init(self, conductor = N**10, hodge_numbers = [-1,-1,-1,0,0,0,0,1], weight = 4, epsilon = self._compute_epsilon(), poles = [], residues = [], base_field = QQ, is_selfdual = True) self._gen = RDF['X'].gen() self._genC = CDF['X'].gen() self._series = RDF'X'
- if p is None:
- # Right below equation (1.11) in [Gross-Kudla] return -prod(self._compute_epsilon(p) for p in self._N.prime_divisors())
- if not ZZ(p).is_prime():
raise ValueError, "p must be prime"
raise ValueError, "p must divide the level"
- return cmp((self._N, self._f, self._g, self._h), (right._N, right._f, right._g, right._h))
def repr(self):
- return "L-series triple product of %s" %self._f %self._g %self._h
- return charpoly(self, P)
def call(self, s):
- return self._function(prec(s))(s)
- Y = self._genC a = [quad_roots(f[p], p) for f in self._newforms] L = 1 for n in range(8):
- d = ZZ(n).digits(2) d = [0]*(3-len(d)) + d L *= 1 - prod(a[i][d[i]] for i in range(3))*Y
- X = self._gen a_p, b_p, c_p = [f[p] for f in self._newforms] return (1 - a_p*b_p*c_p * X) * (1 - a_p*b_p*c_p*p*X)**2
- if self._N % p == 0:
- return self._charpoly_bad(p)
- return self._charpoly_good(p)
- self._N = ZZ(N) self._f = f self._g = g self._h = h self._newforms = [f, g, h]
# Examples
L = TripleProductLseries(11, f, f, f)
f = E.anlist(10**7)
L = LSeriesTripleProduct(11, f, f, f)
L.anlist(7)
L.number_of_coefficients(5)
L(RealField(5)(2)) #This command currently returns a RunTime Error ("Unable to create L-series, due to precision or other limits in PARI")