
// Make newform 6041.2.a.c in Magma, downloaded from the LMFDB on 19 April 2024.
// To make the character of type GrpDrchElt, type "MakeCharacter_6041_a();"
// To make the Hecke irreducible modular symbols subspace (type ModSym)
// containing the newform, type "MakeNewformModSym_6041_2_a_c();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose line below.
// The default sign is -1.  You can change this with the optional parameter "sign".
// To make the character of type GrpDrchElt, type "MakeCharacter_6041_a();"
function MakeCharacter_6041_a()
    N := 6041;
    order := 1;
    char_gens := [864, 4320];
    v := [1, 1];
    // chi(gens[i]) = zeta^v[i]
    assert UnitGenerators(DirichletGroup(N)) eq char_gens;
    F := CyclotomicField(order);
    chi := DirichletCharacterFromValuesOnUnitGenerators(DirichletGroup(N,F),[F|F.1^e:e in v]);
    return MinimalBaseRingCharacter(chi);
end function;

function MakeCharacter_6041_a_Hecke(Kf)
    return MakeCharacter_6041_a();
end function;


// To make the Hecke irreducible modular symbols subspace (type ModSym)
// containing the newform, type "MakeNewformModSym_6041_2_a_c();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose line below.
// The default sign is -1.  You can change this with the optional parameter "sign".
function MakeNewformModSym_6041_2_a_c( : sign := -1)
    R<x> := PolynomialRing(Rationals());
    chi := MakeCharacter_6041_a();
    // SetVerbose("ModularSymbols", true);
    Snew := NewSubspace(CuspidalSubspace(ModularSymbols(chi,2,sign)));
    Vf := Kernel([<2,R![-299, 24130, -393045, -2039044, 66864949, -59734303, -3415425086, 5166253661, 92840284518, -127546065410, -1604857449911, 1712164040914, 19229375509566, -14381407341872, -168194451595321, 77803845344873, 1112718246429157, -244873133933715, -5716355018904223, 97911037054702, 23276542803859826, 3559726914017724, -76371125648986643, -22691293402357434, 204639280322846332, 86308082082973623, -452800181593292103, -241042266718931164, 834910454601079791, 529058687660495367, -1292431950680509707, -943707272197834164, 1689471499274385927, 1395930250556223668, -1873041815788179507, -1735815660690983401, 1765928275552004091, 1832424067701999822, -1417035196446980629, -1654325688122918370, 966135045155128112, 1284412145485876294, -556634927766637095, -861174281101520418, 267734685804215469, 500146498266653978, -104711200259655465, -252115463698704286, 31181009436533306, 110424085768258543, -5533051414251651, -42029229097943287, -596355145461151, 13890007880240792, 992618130977813, -3978281592050423, -491717683778680, 984408265546799, 169623097389594, -209476259536846, -45939370247718, 38082401787766, 10151161926776, -5860437578326, -1855965802551, 753357465911, 281620400952, -79308801820, -35329872229, 6619793600, 3629423704, -411904760, -300488895, 16244910, 19565838, -103069, -964839, -34220, 33869, 2369, -754, -75, 8, 1]>],Snew);
    return Vf;
end function;