sd22 -- greenberg -- gamma0 modsym

584 days ago by wstein

I would like Sage to give me a basis m_1, ..., m_2g of the space of cuspidal modular symbols for ModularSymbols(N,2).cuspidal_subspace() such that m_i is a sum of symbols of the form {Infinity, g.Infinity} for g in Gamma0(N), as in Theorem 10.7 of your book.  If there a command for this?

def gamsym(N): """ Return a list of pairs (g, {oo,g(oo)}) such that the symbols {oo,g(oo)} are a basis over QQ for the cuspidal subspace. Over QQ ! Not over ZZ. """ G = Gamma0(N) gens = G.gens() s = gens[0] M = ModularSymbols(N,2) B = [(g, M([oo, g[0,0]/g[1,0] if g[1,0] else oo])) for g in gens] C = [x.element() for _,x in B] P = matrix(C).pivot_rows() return [B[i] for i in P] 
       
gamsym(11) 
       
[([-5 -1]
[11  2], -(1,9)), ([-7 -1]
[22  3], (1,8) - (1,9))]
[([-5 -1]
[11  2], -(1,9)), ([-7 -1]
[22  3], (1,8) - (1,9))]
time gamsym(23) 
       
[([-11  -1]
[ 23   2], -(1,21)), ([-15  -1]
[ 46   3], (1,17) - (1,19) + (1,20) - (1,21)), ([-17  -1]
[ 69   4], (1,17)), ([-19  -1]
[115   6], (1,19))]
Time: CPU 0.51 s, Wall: 1.15 s
[([-11  -1]
[ 23   2], -(1,21)), ([-15  -1]
[ 46   3], (1,17) - (1,19) + (1,20) - (1,21)), ([-17  -1]
[ 69   4], (1,17)), ([-19  -1]
[115   6], (1,19))]
Time: CPU 0.51 s, Wall: 1.15 s