#6837: Implementation of twisting modular forms by Dirichlet characters
---------------------------+------------------------------------------------
Reporter: ljpk | Owner: craigcitro
Type: enhancement | Status: new
Priority: minor | Milestone: sage-4.1.2
Component: modular forms | Keywords:
Reviewer: | Author:
Merged: |
---------------------------+------------------------------------------------
In Koblitz's book "Introduction to Elliptic Curves and Modular Forms",
Proposition III.3.17, it is proved that if f(q)=sum_{n=0}^infinity a_n q^n
is the Fourier expansion of a modular form in M_k(Gamma_0(M),chi) and
chi_1 is a primitive Dirichlet character modulo N, then
f_chi(q)=sum_{n=0}^infinity \chi_1(n) a_n q^n is a modular form in
M_k(\Gamma_0(MN^2),\chi\chi_1^2). This is a proposed method for objects of
type 'sage.modular.modform.element.ModularFormElement' which will create
f_\chi given f and chi.
{{{
def twist(f,chi):
r"""
This function returns the twist of the modular form f by the
Dirichlet character chi
INPUT:
- ``f`` - a modular form
- ``chi`` - a Dirichlet character
OUTPUT:
f_\chi, the twist of f by chi; if f(q)=sum_{n=0}^infty a_n q^n,
then f_chi(q)=sum_{n=0}^infty chi(n) a_n q^n ([Koblitz]).
EXAMPLES:
Here is a basic example:
::
sage: f=CuspForms(11,2).0
sage: f.q_expansion(6)
q - 2*q^2 - q^3 + 2*q^4 + q^5 + O(q^6)
sage: eps=DirichletGroup(3).0
sage: f.twist(eps)
q + 2*q^2 + 2*q^4 - q^5 + O(q^6)
::
NOTES:
This function is rather slow when chi is not a quadratic
character; this may be improved with a new definition of the Sturm bound.
REFERENCES:
- [Koblitz], Neal Koblitz, "Introduction to Elliptic Curves and
Modular Forms", Springer GTM 97, 1993, Proposition III.3.17.
AUTHORS:
- L. J. P. Kilford (2009-08-28)
"""
DG_MNsq=DirichletGroup(f.level()*chi.modulus()^2)
basering=DG_MNsq.base_ring()
M_k_MNsq=ModularForms(DG_MNsq(self.character())*DG_MNsq(chi)^2,self.weight(),base_ring=basering)
bound=M_k_MNsq.sturm_bound()+1
PSR.<q>=PowerSeriesRing(DG_MNsq.base_ring())
f_twist=PSR([self[i]*chi(i) for i in
xrange(0,bound+2)])+O(q^bound)
return M_k_MNsq(f_twist)
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/6837>
Sage <http://sagemath.org/>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en
-~----------~----~----~----~------~----~------~--~---