The Hecke Algebra

HeckeBound(M) : ModSym -> RngIntElt
A positive integer n such that the Hecke operators T1, ..., Tn generate the Hecke algebra as a Z-module. When the character is trivial, the default bound is (k/12).[(SL)2(Z):Γ0(N)]. That this suffices follows from [Stu87], as is explained in [AS02]. When the character of the space of modular symbols M is nontrivial, the default bound is twice the above bound; however, it is not known that this bound is large enough in all cases in which the character is nontrivial, so one may wish to increase the bound using SetHeckeBound.
SetHeckeBound(M, n) : ModSym, RngIntElt -> RngIntElt
Many computations require a bound n such that T1, ..., Tn generate the Hecke algebra associated to the space of modular symbols M as a Z-module. This command allows you to set the bound that is used internally. Setting it too low can result in functions quickly producing incorrect results.
HeckeAlgebra(M : Bound) : ModSym -> AlgMat
The Hecke algebra associated to the space of modular symbols M. This is an algebra TQ over Q, such that Generators(TQ) is a set that generates the ring Z[T1, T2, T3, ... ], as a Z-module. If the optional integer parameter Bound is set, then HeckeAlgebra only computes the algebra generated by those Tn, with n≤ Bound.
DiscriminantOfHeckeAlgebra(M : Bound) : ModSym -> RngIntElt
The discriminant of the Hecke algebra associated to the space of modular symbols M. If the optional parameter Bound is set, then the discriminant of the algebra generated by only those Tn, with n≤ Bound, is computed instead.
HeckeEigenvalueRing(M : parameters) : ModSym -> Rng, Map
    Bound: RngIntElt                    Default: -1
The order generated by the Fourier coefficients of one of the q-expansions of a newform corresponding to the space of modular symbols M, along with a map from the ring containing the coefficients of qExpansion(A) to the order. If the optional parameter Bound is set, then the order generated only by those an, with n ≤ Bound, is computed.
HeckeEigenvalueField(M) : ModSym -> Fld, Map
The number field generated by the Fourier coefficients of one of the q-expansions of a newform corresponding to the space of modular symbols M, along with a map from the ring containing the coefficients of qExpansion(M) to the number field. We require that M be defined over Q.

Example ModSym_HeckeAlgebra (H142E17)

In this example, we compute the discriminant of the Hecke algebra of prime level 389.
> M := ModularSymbols(389,2,+1);
> C := CuspidalSubspace(M);
> DiscriminantOfHeckeAlgebra(C);
62967005472006188288017473632139259549820493155023510831104000000
> Factorization($1);
[ <2, 53>, <3, 4>, <5, 6>, <31, 2>, <37, 1>, <389, 1>, <3881, 1>,
<215517113148241, 1>, <477439237737571441, 1> ]
The prime 389 is the only prime p<10000 such that p divides the discriminant of the Hecke algebra associated to S20(p)). It is an open problem to decide whether or not there are any other such primes. Are there infinitely many?
V2.28, 13 July 2023