
// Make newform 726.6.a.bb in Magma, downloaded from the LMFDB on 12 May 2024.
// To make the character of type GrpDrchElt, type "MakeCharacter_726_a();"
// To make the coeffs of the qexp of the newform in the Hecke field type "qexpCoeffs();"
// To make the newform (type ModFrm), type "MakeNewformModFrm_726_6_a_bb();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose lines below.
// The precision argument determines an initial guess on how many Fourier coefficients to use.
// This guess is increased enough to uniquely determine the newform.
// To make the Hecke irreducible modular symbols subspace (type ModSym)
// containing the newform, type "MakeNewformModSym_726_6_a_bb();".
// 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 ConvertToHeckeField(input: pass_field := false, Kf := [])
    if not pass_field then
        poly := [20131, 0, -288, 0, 1];
        Kf := NumberField(Polynomial([elt : elt in poly]));
        AssignNames(~Kf, ["nu"]);
    end if;
    Rf_num := [[1, 0, 0, 0], [155, 44, -1, 0], [731, -310, -5, 2], [-143, 0, 1, 0]];
    Rf_basisdens := [1, 22, 22, 2];
    Rf_basisnums := ChangeUniverse([[z : z in elt] : elt in Rf_num], Kf);
    Rfbasis := [Rf_basisnums[i]/Rf_basisdens[i] : i in [1..Degree(Kf)]];
    inp_vec := Vector(Rfbasis)*ChangeRing(Transpose(Matrix([[elt : elt in row] : row in input])),Kf);
    return Eltseq(inp_vec);
end function;


// To make the character of type GrpDrchElt, type "MakeCharacter_726_a();"
function MakeCharacter_726_a()
    N := 726;
    order := 1;
    char_gens := [485, 607];
    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_726_a_Hecke(Kf)
    return MakeCharacter_726_a();
end function;


function ExtendMultiplicatively(weight, aps, character)
    prec := NextPrime(NthPrime(#aps)) - 1; // we will able to figure out a_0 ... a_prec
    primes := PrimesUpTo(prec);
    prime_powers := primes;
    assert #primes eq #aps;
    log_prec := Floor(Log(prec)/Log(2)); // prec < 2^(log_prec+1)
    F := Universe(aps);
    FXY<X, Y> := PolynomialRing(F, 2);
    // 1/(1 - a_p T + p^(weight - 1) * char(p) T^2) = 1 + a_p T + a_{p^2} T^2 + ...
    R<T> := PowerSeriesRing(FXY : Precision := log_prec + 1);
    recursion := Coefficients(1/(1 - X*T + Y*T^2));
    coeffs := [F!0: i in [1..(prec+1)]];
    coeffs[1] := 1; //a_1
    for i := 1 to #primes do
        p := primes[i];
        coeffs[p] := aps[i];
        b := p^(weight - 1) * F!character(p);
        r := 2;
        p_power := p * p;
        //deals with powers of p
        while p_power le prec do
            Append(~prime_powers, p_power);
            coeffs[p_power] := Evaluate(recursion[r + 1], [aps[i], b]);
            p_power *:= p;
            r +:= 1;
        end while;    
    end for;
    Sort(~prime_powers);
    for pp in prime_powers do
        for k := 1 to Floor(prec/pp) do
            if GCD(k, pp) eq 1 then
                coeffs[pp*k] := coeffs[pp]*coeffs[k];
            end if;
        end for;
    end for;
    return coeffs;
end function;


function qexpCoeffs()
    // To make the coeffs of the qexp of the newform in the Hecke field type "qexpCoeffs();"
    weight := 6;
    raw_aps := [[-4, 0, 0, 0], [9, 0, 0, 0], [-38, 1, -1, 1], [11, 5, -1, 8], [0, 0, 0, 0], [117, -28, -12, -14], [-73, -17, 16, -34], [296, 75, 16, -8], [-1397, 29, 44, 235], [-290, -94, -98, -252], [-2385, -38, -37, -280], [915, -290, -218, -134], [-3657, -208, 105, 131], [8917, -335, 53, 80], [-5807, -121, -123, -781], [-6369, 65, 112, -1168], [-7748, -176, 825, 932], [20404, -272, 6, 925], [-22268, -743, -388, 76], [-20342, -1028, -1751, -1156], [13618, 1138, 488, 2076], [25223, 291, -355, 56], [-3311, 1023, 1436, -3185], [-42773, 828, -749, -535], [-75124, 2186, -308, -3173], [-10437, 248, -2449, 177], [298, -1464, 2164, 6688], [83829, -3283, 638, 1571], [11980, -816, 3622, 1790], [-117655, 4558, 2913, 7095], [114388, 3458, 212, -10268], [-27579, -191, 4007, 5967], [-55579, 9972, -1725, 281], [118197, 1656, -4977, 1926], [-94851, -8932, -8931, -7157], [18474, 6568, 9194, -10066], [-91224, 1740, -1500, -2466], [114111, 932, -493, -23418], [-132708, -9026, 2155, 92], [-100416, 5251, -7263, -40117], [-134415, -7453, 12408, 7175], [275221, 1268, 1014, -31390], [-572747, -3115, -4124, 2495], [12299, 1666, 8470, 763], [-525681, 4065, -5582, 14592], [-332687, -13375, -13071, 33616], [-149277, -6386, -483, 43802], [220523, 4907, 13521, -34794], [16829, 15605, -18942, 31213], [-459502, -27744, 3658, 10774], [-213808, 24167, 21353, 11331], [-754785, -6041, 16843, -9629], [-510400, -14672, 18018, -28000], [-142789, 10459, 25651, 8781], [-986056, 25037, 37121, 38443], [-641902, 7026, 40335, -25576], [-362546, 33892, 23886, -698], [-1161634, -26323, 762, 22902], [-76299, -2820, 616, 113401], [673074, -5078, 45668, 27856], [679794, 34568, 5474, -80836], [-557885, -43700, -58095, 34427], [-419477, 35424, -7897, -139998], [39635, -19463, -21644, -11061], [-478001, -51200, -13896, -53060], [-155031, 50536, 2545, -92933], [-403413, 44215, 44479, -84368], [-12336, -11678, -43208, 13656], [-1146692, -64790, -22216, 21154], [789863, -16004, 10594, 79796], [335548, 9570, 14520, -98954], [-1744718, 76664, 91482, 116088], [1042296, -53977, 52030, 158146], [428949, 87612, 36310, -26858], [449463, 98893, -32155, -22078], [111147, -201281, -4770, -9677], [199251, -44353, -43972, 100038], [2920853, -93886, -71438, -134042], [1867973, 18037, 31308, -106916], [1054508, -73650, -30040, 112262], [-851492, 39748, -33799, -97702], [1297266, -24130, -163954, -3181], [1032433, 173815, 24187, -108783], [2581886, 96888, 50120, 74028], [186487, -157475, -101517, -150462], [1310122, -148674, 66706, 88342], [-4965362, 26852, -49320, -130332], [-1400733, 68438, -24232, -417037], [1149294, 44393, -2377, -139133], [2750217, 72956, 46331, -193396], [1443579, -204471, -191838, -219373], [-2387991, 2423, 77665, -118705], [3428401, 33343, -11341, 158680], [-1483915, -144073, -202673, -213647], [1024392, -31673, -236154, 110028], [-2288752, -41224, -11732, 497586], [2388439, 44985, 119890, 428128], [-3990684, 142220, -80870, 7422], [-4712331, -62124, 149763, 37856], [-434076, 294340, 64278, 292455], [-177215, 87056, 377307, 243446], [-1092706, 95181, -69473, -472969], [-212523, 161653, -134664, 75199], [407608, -35494, 11164, 514508], [-861046, 201299, -3820, -254160], [-3437976, -212946, -193724, 406676], [-2404291, 41579, 142054, -507029], [2125336, 196693, -166873, 385871], [19460, 266078, 266032, 416284], [-5642399, 172102, 57882, -169884], [1266909, 83266, 302335, 590902], [5940386, -7724, -233044, -52654], [-1796185, 186502, 118367, 272823], [10206995, -12665, -176339, -191950], [4991979, 79514, 144831, 801900], [207128, -121367, 336263, 330049], [2601201, -124608, -495195, -24528], [-2795419, 356657, 187189, 209639], [2376603, -27595, -324098, -466176], [7429306, -462634, -320470, -393378], [6260129, -149812, -110848, -500949], [6059895, -355292, 67440, 717228], [-6227112, -304504, -2320, -11108], [-488939, 57615, 262522, 965735], [4045066, 233902, -175950, 270442], [-7268042, 254005, 10655, 817961], [2923343, -103592, 258720, 139957], [7464161, 174451, 71292, 656793], [4361355, 366402, -144245, -143156], [-4870362, -422962, 302718, -710022], [-4195649, -391111, -247529, -7832], [2314413, -421423, -579082, -1059081], [-8679246, 337315, -176432, -534448], [2661541, -274860, -274288, 174000], [-8585643, 271960, -221335, -432989], [-11949738, 263532, 105840, 793995], [-4522509, 83940, 129455, 473101], [4085926, 498382, 246942, 229666], [-21925012, 129352, -339290, -1045392], [9435278, 32703, -273249, -861685], [2647147, 44160, -707443, -688548], [20397339, -180852, 93315, 626553], [8807933, 341983, -152139, 741952], [20165446, -298236, 352368, 563242], [7264599, -387792, 384166, -681781], [-9024779, 419865, -21994, 558079], [3573493, 129110, 428652, 503722], [1205533, -719620, -578575, 26763], [-1958637, -310435, 555559, -452928], [-2683162, -232334, -44646, -1922756], [7829229, 11890, -164288, -2454094], [1397381, 235845, 441108, 1460824], [1815214, -483510, -15248, -873110], [28123091, 277093, 38654, 125329], [-9441778, -339591, -455906, -1238402], [-2321251, 1033141, 602446, 938189], [-2822943, -115809, -1011567, -477474], [13947853, -294786, -992403, 385117], [-10181845, 483164, 572008, 1623166], [2401435, 1397071, -379508, -220038], [-14878248, -805948, -181265, 513086], [17365872, 1910, -873898, -70710], [-14767594, -87077, -32362, 560180], [-23715742, -663474, 216380, -1067622], [2695219, -524592, -310825, -1487243], [-7189358, -974336, -154348, 1207352], [-15032392, 49893, -279664, -2779240], [-21520802, 591080, -27962, 914465], [-554023, 403366, 1467260, 1923835], [28925052, -892548, 37620, -48022], [27756280, -432810, -124599, 61798], [-25238243, -323720, -802122, -538575], [20808968, -427208, -198631, -1064526], [-24862050, 205540, -534566, 346976], [6875070, -1084128, 770130, -162654], [6865100, 388462, 786090, 2476716], [-4276112, 142048, -1439496, 176590], [74322, -579172, 372782, 621770], [-12312842, -494464, -549212, 932138], [5168246, -631274, 41292, 555972], [15245003, -510731, 928059, 2051790], [1453353, -290609, -1470916, -1717019], [-23625831, -728290, -833644, 2110658], [22987367, -734525, -1149490, -1333986], [-12327026, 662826, 640699, -1830800], [-11244284, 1633685, -337879, -1923909], [-14583532, -134142, -722734, -3526090], [-11827091, -606878, -569661, -250316], [3145212, -498314, -2083774, -1921585], [17386849, -1273525, 1431325, 2374985], [27454866, 1895650, 482308, -1786889], [27781279, 373593, 478662, -1544339], [-46385875, -908011, -624893, 589900], [1126694, 2336842, 535076, -233634], [34284584, 423864, -1105667, -816340], [14698671, -50617, -481396, 2428022], [-42212998, -638378, -742272, -159920], [-18463667, 2089818, 912824, 600669], [-8459666, 759232, 2388922, 929286], [28303654, 387790, -878949, -1058410], [-11078454, 306866, 1165240, 4304232], [3060566, 109058, -1130788, -2351134], [-46994214, 1234150, -61508, 823984], [21835457, -586058, 1347978, -674214], [-17841857, 648869, 358146, 2632267], [-8222043, 210541, 587990, -1808148], [36304858, -1465795, -1746660, -105028], [45802657, 471007, -8203, -2129929], [-13443903, 785630, 1347045, -2554151], [-32033422, 422840, -369426, -3763842], [36410468, -642612, 690578, 5974139], [-25780701, 2855062, 430197, 2918033], [2704140, 140900, 54510, 30178], [29433618, -10770, -1281960, 2948244], [-4271177, -1475699, -2388232, -1636079], [-28426495, -775274, 257048, 4006837], [-22050468, 99350, -471242, 502042], [16776336, -403267, 1864035, 531413], [45089667, -792265, 68640, 1513447], [-18230586, 779944, -272168, -1268390], [-39322769, -2920914, 303520, 570819], [-28471632, 8210, -1642666, -285396], [76731867, 924884, -409361, -2934313], [-7188094, 932193, 858676, -5655000], [32669224, -1464158, -122317, 827890], [79396211, 529468, 1284342, 1732898], [10057670, -3183761, 350517, -4189875], [26709073, 2723829, -1155208, -107429], [-50275123, 2550275, 1482293, 7406186], [-1914746, 610156, 351857, -427960], [-7836590, 828838, 475484, 7890200], [-9414827, 741624, -775301, -8727150], [-44488451, 2229731, 1785377, 2245628], [-49104614, -1411948, -1614812, -816438], [-7944454, 1028976, -43898, 8414724], [13368506, -2089950, -626276, 2554376], [17273849, -198210, -291162, -9638055], [-17441962, 2454556, 903708, 7763370], [76112110, 794132, -1727542, 684612], [-13114217, 1338381, 2932549, 3890137], [-1170914, -816888, -2007464, -527078], [8971328, 1884241, 1467320, 2119232], [-17292839, 17521, -732481, -234800], [-70598778, -465300, -836096, 160606], [4927068, 2375543, 485837, 718063], [45148713, 533559, -1301575, 2741595], [27225830, 359247, 275860, 139080], [35701362, -3333574, 1097690, 2819132], [54006141, 1279331, -610559, 3749890], [-17584452, 891058, 618438, -6905696], [-24624875, 2368562, -2770614, -3231141], [-20069054, 192527, 626619, -3847073], [13030696, 4202124, 2455822, -2320838], [279802, 1138922, -45532, -572998], [9783546, 403725, -1051555, 5746131], [57996223, 3592883, -1377530, 827045], [-4222881, 683768, -260176, 3764822], [112528524, 2067608, 2070450, -2967486], [3846065, 1824936, 631709, 535439], [35312715, 1277656, -610910, -5293781], [116780386, -291943, -105534, -1911046], [105671613, -996423, -465996, -3356373], [-19954742, -2943956, 48822, 6445149], [-62360159, -5811676, -340124, 3001189], [-90541414, -11197, -742541, 6619195], [-62871285, 4037289, -880443, 732546], [27517611, -4024204, -1692829, 2587269], [-30120390, -966534, -2576910, -6214178], [-27442060, 1233832, -122828, 3021200], [-78959513, -3148575, 547458, -6065078], [-48776504, -2845590, -431834, 10992928], [-155340400, 2129159, 722772, 2747058], [-97636057, 4073896, 4156980, 5245740], [82199124, -1950289, -3502412, -6627740], [-86537565, 4122276, -1969800, -5073384], [8207442, 1493797, 7194508, 4851934], [56491363, 6319005, 2446752, -5131285], [47079807, 1110976, 5496672, 946896], [-4595714, -1092808, 5594750, 3430721], [9913697, -1880725, -464020, 5177845], [75922163, 2775737, 1374183, -9269383], [-107874000, 1248008, -3512146, -11251812], [106272153, 5488177, -1250498, 422113], [-65870639, 2743380, 3261824, -96703], [-67694956, 2747872, 725938, 4540582], [-26946611, 2217049, -5208009, -5249071], [-144493733, 2990814, -683760, 3253449], [-5461467, -1752195, -4489954, -6612362], [-105316970, -2231640, 171372, 1806078], [-78242859, 305366, -732115, 9395203], [-26884054, 621667, 3108543, -3546243], [-32780212, 2287670, -1013802, 14465642], [-84033381, 2522696, 650383, 12485115], [-37575323, 5328125, -2755122, -8653455], [-209990097, 269036, -2393072, -6764579], [-25344167, -5480345, -5798878, 5650404], [-28351403, -10400623, 1588395, 184680], [53219093, -2962118, 4647623, 3451755], [21085902, -9099720, -3118639, -1201374], [90378314, 2570555, -2105718, 12048240], [-106371677, -1424386, 5454424, 507874], [59992925, 2175750, -751921, -16304605], [-55867599, 842300, -5325103, -7523236], [-122075996, -8086546, -6041757, 8065842], [17123231, -7805747, -616141, -1421926], [21124028, 5244230, 3588370, 1857064], [-69958318, 3932798, -1188660, -10575860], [-36171734, -519062, 2614672, -6407306], [13313607, 2735023, -27063, -4310429], [-111888632, -5230028, -2100820, -2334565], [48056368, -1592108, -6314809, 2263082], [-110275473, -9134406, -3304267, 9086739], [74000945, 3516847, -1034354, 17933480], [-77442993, 64306, -5652917, -1274740], [-65788323, -2368675, -4799242, -4132499], [-36293279, 11523966, 2709214, 7162789], [29097368, -4929716, -3861876, 7061946], [-211368869, 1526753, -1240336, 590733], [36656634, 5963176, -449980, -2041428], [-15321797, 340954, 7120857, 8441425], [107632380, 8272484, 2725996, -1710122], [-32134257, -3468700, -1954532, -13739136], [-52513389, 2088114, 2974729, -2343625], [132908839, -4075764, -2088193, -4855068], [24656249, 1713860, 3251689, -8650491], [76533488, 2143744, -4879656, 12122920], [-125958917, -4021894, -4789637, 8583140], [132736892, -7531543, -5974176, -10606768], [12025284, 2839158, -5372445, 6360646], [-209801868, 6789656, 3582032, 11366900], [-57768840, -6479852, 3168868, -5979986], [-49921628, -2199418, 798288, 937486], [44000829, -7653140, -2492037, -10379692], [73457008, -3658402, -4098356, 6597510], [-177579644, 730338, 23582, 9989042], [-43554533, 46553, 2750393, -5727605], [-225473327, 1150226, 7761162, -2728299], [-93702577, 2579370, 1519901, -20813365], [-54253814, 1715942, 4843456, 9361549], [16917828, -1309220, 4823668, 3691678], [53987395, 7303398, 10840914, 2683073], [1292055, -6576122, -7793579, -13109263], [84596210, 1178786, -115506, 3266908], [-131717131, -1458615, -975689, -21424494], [45788461, 9580358, -3179859, 10610841], [-23471494, -7936086, 6187108, -1447768], [93640457, -2746994, -7180438, -23679883], [137979682, -5373037, 6003372, 15843404], [-19071526, -8626010, 5436207, -3851718], [250432022, 1522838, 3957316, 4174448], [-207755902, 173250, -2984890, 2084572], [72580282, -3928324, -5860802, 12856264], [-157716385, -4895581, -6490068, -3581582], [24002255, 780691, -6738133, 13934314], [8020063, 12258742, 3932656, 174601], [191496870, -6454976, 4093120, 174376], [-131872358, 6017034, 5276344, 6601092], [142650260, -6241440, -4610629, -24537310], [164246148, 1866922, 6132596, 2027058], [49102780, 8775896, 3534693, 11914166], [79041906, 2814888, -7958108, 9076963], [-14238457, -11582918, -1170999, -11334189], [111027975, -1842665, 6785033, -4664937], [226928724, 884274, 376626, 2567980], [-17083371, -4001541, 3411347, -17555956], [221648270, -1371256, -2524700, 1167696], [137882411, -1393215, 6327212, -8796116], [79528474, 6197257, 11335946, -5427244], [-1176160, 2179878, -2750464, -13903858], [-81251413, -16234827, 1710647, -6138101], [68894494, 3162596, -199186, -4054496], [102594237, -9042265, -14961627, -16495957], [-79250742, -8451642, -3452820, 24209566], [-134544036, 9903034, 3927168, 4513104], [123111608, -3052290, -6738586, 18155357], [70196303, -9473729, -4136862, 14760051], [-19552361, -9437, -3984568, 31594115], [299977237, 7362234, 5956868, 7246524], [-247436144, 1033730, -9194398, -15640298], [151432091, -10848044, -3416340, -25202748], [-72251454, -19546908, -6130668, -1098440], [-52106635, 969668, 13099567, -19117769], [-89719871, -5260593, 6755575, 5326900], [106675490, 9047885, 1989597, -3959285], [184690860, 3838255, -960474, 16164690], [-51967671, 4279817, -3033927, 1089413], [-20197026, -5757862, 2045674, 7513558], [471648614, -1556278, -2614874, 1911813], [-58845347, -9745083, -9619939, -3776566], [139575215, 11645947, 1597189, -18934947], [74135228, -8683170, -7171592, 4929318], [252347577, 2359166, 7092797, 10136505], [59094343, 11571311, 1359863, -12940881], [172941171, 4843013, -7106321, -19196750], [170422663, -1140029, 13699887, 12898097], [-97134729, -623798, -8758700, -14939378], [70505014, 6844020, 11670338, -9155028], [290369531, 3517196, 1461759, -10620613], [168095868, -4952350, 609526, -21914618], [-202460148, -3550228, 17176768, -12998166], [145485584, -4251540, 7340462, 16383500], [38147153, -175035, -9748232, 13603928], [338205745, -17587973, -11416783, -26234812], [116740430, -14543085, -3520837, -4107817], [28530041, -2282526, 1128533, -22470227], [41824594, -17530756, 5812746, 13154762], [204702161, -16467654, -7056778, -31657015], [-126802017, 1005128, 4613789, 12853145], [264023672, 12447370, -2881880, 13969750], [115840980, 2950436, 381654, 7230784], [246362873, -2031736, 2069880, -28411149], [-3358222, -2368469, 2375319, -3365561], [-72656261, 9279453, 1125883, 29980321], [96760392, 591667, -13264936, 30824826], [462882857, 851374, -9486984, 6668856], [185502743, 1022059, 11176308, -209712], [-68744941, 5691483, 6157799, -38991547], [210939550, 15128218, 4790936, 37780], [225494660, 7360154, -6481284, 4285444], [-2118684, -10990668, -6431426, 17522588], [-142330686, -11293910, -5822506, -24446214], [-87589437, -20390442, -8973966, 17241448], [-295814280, -5358012, -4950934, 8493508], [-277453140, 9334032, 2582938, 18804008], [-174788822, -12914172, 9521766, -18475038], [44155912, -945690, 20321694, 17479024], [72855955, 2162343, -3320014, -30737141], [60043547, 19599647, 4798106, -10194392], [20237734, -7483297, -10079970, 4765256], [-182672359, 2775753, 7711516, 12649119]];
    aps := ConvertToHeckeField(raw_aps);
    chi := MakeCharacter_726_a_Hecke(Universe(aps));
    return ExtendMultiplicatively(weight, aps, chi);
end function;


// To make the newform (type ModFrm), type "MakeNewformModFrm_726_6_a_bb();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose lines below.
// The precision argument determines an initial guess on how many Fourier coefficients to use.
// This guess is increased enough to uniquely determine the newform.
function MakeNewformModFrm_726_6_a_bb(:prec:=4)
    chi := MakeCharacter_726_a();
    f_vec := qexpCoeffs();
    Kf := Universe(f_vec);
    // SetVerbose("ModularForms", true);
    // SetVerbose("ModularSymbols", true);
    S := CuspidalSubspace(ModularForms(chi, 6));
    S := BaseChange(S, Kf);
    maxprec := NextPrime(2999) - 1;
    while true do
        trunc_vec := Vector(Kf, [0] cat [f_vec[i]: i in [1..prec]]);
        B := Basis(S, prec + 1);
        S_basismat := Matrix([AbsEltseq(g): g in B]);
        if Rank(S_basismat) eq Min(NumberOfRows(S_basismat), NumberOfColumns(S_basismat)) then
            S_basismat := ChangeRing(S_basismat,Kf);
            f_lincom := Solution(S_basismat,trunc_vec);
            f := &+[f_lincom[i]*Basis(S)[i] : i in [1..#Basis(S)]];
            return f;
        end if;
        error if prec eq maxprec, "Unable to distinguish newform within newspace";
        prec := Min(Ceiling(1.25 * prec), maxprec);
    end while;
end function;


// To make the Hecke irreducible modular symbols subspace (type ModSym)
// containing the newform, type "MakeNewformModSym_726_6_a_bb();".
// 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_726_6_a_bb( : sign := -1)
    R<x> := PolynomialRing(Rationals());
    chi := MakeCharacter_726_a();
    // SetVerbose("ModularSymbols", true);
    Snew := NewSubspace(CuspidalSubspace(ModularSymbols(chi,6,sign)));
    Vf := Kernel([<5,R![-108779, 22350, 4503, 150, 1]>,<7,R![-5215195, 3358260, -51494, -68, 1]>],Snew);
    return Vf;
end function;